Computes the frequency response and the coherence based on the input signals. Results are returned as magnitude, phase, and coherence.


icon

Inputs/Outputs

  • cdbl.png window parameter

    window parameter specifies the beta parameter for a Kaiser window, the standard deviation for a Gaussian window, and the ratio, s, of the main lobe to the side lobe for a Dolph-Chebyshev window. If window is any other window, this VI ignores this input.

    The default value of window parameter is NaN, which sets beta to 0 for a Kaiser window, the standard deviation to 0.2 for a Gaussian window, and s to 60 for a Dolph-Chebyshev window.

  • cbool.png restart averaging (F)

    restart averaging specifies whether the VI restarts the selected averaging process. If restart averaging is TRUE, the VI restarts the selected averaging process. If restart averaging is FALSE, the VI does not restart the selected averaging process. The default is FALSE.

    When you call this VI for the first time, the averaging process restarts automatically. A typical case when you should restart averaging is when a major input change occurs in the middle of the averaging process.

  • c1dmsdt.png time signals X

    time signals X is the array of time waveforms X.

  • c1dmsdt.png time signals Y

    time signals Y is the array of time waveforms Y.

  • cu32.png window

    window (Hanning) is the time-domain window to apply to the time signal. The default window is Hanning.

    0Rectangle
    1Hanning (default)
    2Hamming
    3Blackman-Harris
    4Exact Blackman
    5Blackman
    6Flat Top
    74 Term B-Harris
    87 Term B-Harris
    9Low Sidelobe
    11Blackman Nutall
    30Triangle
    31Bartlett-Hanning
    32Bohman
    33Parzen
    34Welch
    60Kaiser
    61Dolph-Chebyshev
    62Gaussian
  • ccclst.png view

    view defines how the different results from this VI are returned.

  • cbool.png dB On (F)

    dB On specifies whether the results are expressed in decibels. The default is FALSE.

  • cbool.png unwrap phase (F)

    unwrap phase specifies whether to unwrap the phase. Unwrapping eliminates discontinuities that have an absolute value greater than pi. The default is FALSE, meaning the phase is not unwrapped.

    When unwrap phase is TRUE, the phase is unwrapped.

  • cbool.png convert to degree (F)

    convert to degree specifies whether the phase results are converted from radians to degrees. The default is FALSE, which means that results are expressed in radians.

  • cerrcodeclst.png error in (no error)

    error in describes error conditions that occur before this node runs. This input provides standard error in functionality.

  • cnclst.png averaging parameters

    averaging parameters defines how the averaging is computed. The specifications of the parameters include the type of averaging, the type of weighting, and the number of averages.

  • cenum.png averaging mode

    averaging mode specifies the averaging mode.

    0
    No averaging
    (default)
    1
    Vector averaging
    2
    RMS averaging
    3
    Peak hold
  • cenum.png weighting mode

    weighting mode specifies the weighting mode for RMS and vector averaging.

    0
    Linear
    1
    Exponential
    (default)
  • cu32.png number of averages

    number of averages specifies the number of averages used for RMS and vector averaging. If weighting mode is exponential, the averaging process is continuous. If weighting mode is linear, the averaging process stops after this VI computes the selected number of averages.

  • cenum.png FRF Mode

    FRF mode specifies how to compute the frequency response function (FRF).

    If you know that noise, which does not propagate through the system under test, infiltrates the input or output signals, you can select the method used for computing the frequency response function (H1, H2, H3) to minimize the measurement error.

    0H1 (default)—Select H1 to minimize errors in the result when extraneous noise contaminates the output signal.
    1H2—Select H2 to minimize errors in the result when extraneous noise contaminates the input signal.
    2H3—When noise contaminates both the input and output signals, H1 and H2 provide the lower and upper bounds of the true frequency response of the system. In this case, select H3, the average of H1 and H2.
  • cenum.png X-Y pairing

    X-Y pairing specifies how to handle multiple signals in each input.

    0ordered pairs (default)—Calculates the frequency response of the first channel in time signals X against the first channel in time signals Y, then the second channel in time signals X against the second channel in time signals Y, and so on.
    • If there is one channel in time signals X and one channel in time signals Y, the result is one output.
    • If there are multiple channels in time signals X and one channel in time signals Y, the analysis result is the first channel in time signals X against the single channel in time signals Y. LabVIEW ignores the rest of the channels in time signals X, and the VI returns a warning.
    • If there is one channel in time signals X and multiple channels in time signals Y, the analysis result is the single channel in time signals X against the first channel in time signals Y. LabVIEW ignores the rest of the channels in time signals Y, and the VI returns a warning.
    • If there are multiple channels in both time signals X and time signals Y, the analysis result is the first channel in time signals X against the first channel in time signals Y, the second channel in time signals X against the second channel in time signals Y, and so on. If there is a mismatched number of channels, the VI ignores unmatched channels and returns a warning.
    • If either input signal is empty, the result is empty, and the VI returns an error.
    1all cross pairs—Calculates the frequency response of the first channel in time signals X against each channel in time signals Y, then the second channel in time signals X against each channel in time signals Y, and so on.
    • If there is one channel in time signals X and one channel in time signals Y, the result is one output.
    • If there are multiple channels in time signals X and one channel in time signals Y, the analysis result is the first channel in time signals X against the single channel in time signals Y, then the second channel in time signals X against the single channel in time signals Y, and so on. The output contains the same number of signals as time signals X.
    • If there is one channel in time signals X and multiple channels in time signals Y, the analysis result is the single channel in time signals X against the first channel in time signals Y, then the single channel in time signals X against the second channel in time signals Y, and so on. The output contains the same number of signals as time signals Y.
    • If there are N channels in time signals X and M channels in time signals Y, the analysis result is the matrix set of time signals X versus time signals Y. LabVIEW returns the signals in the order 1 – 1, ..., 1 – M, 2 – 1, ..., 2 – M, ..., NM.
    • If either input signal is empty, the result is empty, and the VI returns an error.
  • ibool.png averaging done

    averaging done returns TRUE when averages completed is greater than or equal to the number of averages specified in averaging parameters. Otherwise, averaging done returns FALSE. averaging done is always TRUE if the selected averaging mode is No averaging.

  • i1dcclst.png magnitudes

    magnitudes returns an array of the magnitudes of the averaged frequency responses and the frequency scales.

  • idbl.png f0

    f0 returns the start frequency, in hertz, of the spectrum.

  • idbl.png df

    df returns the frequency resolution, in hertz, of the spectrum.

  • i1ddbl.png magnitude

    magnitude is the magnitude of the averaged frequency response.

  • i1dcclst.png phases

    phases returns an array of the phases of the averaged frequency responses and the frequency scales.

  • idbl.png f0

    f0 returns the start frequency, in hertz, of the spectrum.

  • idbl.png df

    df returns the frequency resolution, in hertz, of the spectrum.

  • i1ddbl.png phase

    phase is the phase of the averaged frequency response.

  • i1dcclst.png coherences

    coherences returns an array of the coherence functions of the averaged frequency responses and the frequency scales.

  • idbl.png f0

    f0 returns the start frequency, in hertz, of the spectrum.

  • idbl.png df

    df returns the frequency resolution, in hertz, of the spectrum.

  • i1ddbl.png coherence

    coherence returns the coherence.

  • idbl.png averages completed

    averages completed returns the number of averages completed by the VI at that time.

  • ierrcodeclst.png error out

    error out contains error information. This output provides standard error out functionality.

  • Typically, time signal X is the stimulus, and time signal Y is the response of the system. Each time waveform corresponds to a single FFT block. You have to pass each time waveform individually to this VI.

    Examples

    Refer to the following example files included with LabVIEW.

    • labview\examples\Signal Processing\Waveform Measurements\Frequency Analysis of a Filter Design.vi