Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Frequency Response Function (Mag-Phase) VI

NI LabVIEW 8.6 Help
June 2008

NI Part Number:
371361E-01

»View Product Info

Owning Palette: Waveform Measurements VIs

Installed With: Full Development System

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

Details  Example

Use the pull-down menu to select an instance of this VI.

Frequency Response Function (Mag Phase) 1-1

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.
time signal X is the time waveform X.
time signal Y is the time waveform Y.
window is the time-domain window to apply to the time signal.
0Rectangle
1Hanning (default)
2Hamming
3Blackman-Harris
4Exact Blackman
5Blackman
6Flat Top
7Four Term Blackman-Harris
8Seven Term Blackman-Harris
9Low Sidelobe
11Blackman Nutall
30Triangle
60Kaiser
61Dolph-Chebyshev
62Gaussian
view defines how the different results from this VI are returned.
dB On specifies whether the magnitude results are expressed in decibels.
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.
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.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use exception control to treat what is normally an error as no error or to treat a warning as an error. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
averaging parameters defines how the averaging is computed.
averaging mode specifies the averaging mode.
0No averaging (default)
1Vector averaging
2RMS averaging
3Peak hold
weighting mode specifies the weighting mode for RMS and vector averaging.

0Linear
1Exponential (default)
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.
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.
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.
magnitude returns the magnitude of the averaged frequency response and the frequency scale.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
magnitude is the magnitude of the averaged frequency response.
phase returns the phase of the averaged frequency response and the frequency scale.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
phase is the phase of the averaged frequency response.
coherence returns the coherence and the frequency scale.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
coherence returns the coherence.
averages completed returns the number of averages completed by the VI at that time.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.

Frequency Response Function (Mag Phase) 1-N

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.
time signal X is the time waveform X.
time signals Y is the array of time waveforms Y.
window is the time-domain window to apply to the time signal.

0Rectangle
1Hanning (default)
2Hamming
3Blackman-Harris
4Exact Blackman
5Blackman
6Flat Top
7Four Term Blackman-Harris
8Seven Term Blackman-Harris
9Low Sidelobe
11Blackman Nutall
30Triangle
60Kaiser
61Dolph-Chebyshev
62Gaussian
view defines how the different results from this VI are returned.
dB On specifies whether the magnitude results are expressed in decibels.
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.
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.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use exception control to treat what is normally an error as no error or to treat a warning as an error. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
averaging parameters defines how the averaging is computed.
averaging mode specifies the averaging mode.

0No averaging (default)
1Vector averaging
2RMS averaging
3Peak hold
weighting mode specifies the weighting mode for RMS and vector averaging.

0Linear
1Exponential (default)
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.
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.
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.
magnitudes returns an array of the magnitudes of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
magnitude is the magnitude of the averaged frequency response.
phases returns an array of the phases of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
phase is the phase of the averaged frequency response.
coherences returns an array of the coherence functions of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
coherence returns the coherence.
averages completed returns the number of averages completed by the VI at that time.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.

Frequency Response Function (Mag Phase) N-1

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.
time signals X is the array of time waveforms X.
time signal Y is the time waveform Y.
window is the time-domain window to apply to the time signal.

0Rectangle
1Hanning (default)
2Hamming
3Blackman-Harris
4Exact Blackman
5Blackman
6Flat Top
7Four Term Blackman-Harris
8Seven Term Blackman-Harris
9Low Sidelobe
11Blackman Nutall
30Triangle
60Kaiser
61Dolph-Chebyshev
62Gaussian
view defines how the different results from this VI are returned.
dB On specifies whether the magnitude results are expressed in decibels.
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.
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.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use exception control to treat what is normally an error as no error or to treat a warning as an error. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
averaging parameters defines how the averaging is computed.
averaging mode specifies the averaging mode.

0No averaging (default)
1Vector averaging
2RMS averaging
3Peak hold
weighting mode specifies the weighting mode for RMS and vector averaging.

0Linear
1Exponential (default)
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.
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.
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.
magnitudes returns an array of the magnitudes of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
magnitude is the magnitude of the averaged frequency response.
phases returns an array of the phases of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
phase is the phase of the averaged frequency response.
coherences returns an array of the coherence functions of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
coherence returns the coherence.
averages completed returns the number of averages completed by the VI at that time.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.

Frequency Response Function (Mag Phase) N-M

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.
time signals X is the array of time waveforms X.
time signals Y is the array of time waveforms Y.
window is the time-domain window to apply to the time signal.

0Rectangle
1Hanning (default)
2Hamming
3Blackman-Harris
4Exact Blackman
5Blackman
6Flat Top
7Four Term Blackman-Harris
8Seven Term Blackman-Harris
9Low Sidelobe
11Blackman Nutall
30Triangle
60Kaiser
61Dolph-Chebyshev
62Gaussian
view defines how the different results from this VI are returned.
dB On specifies whether the magnitude results are expressed in decibels.
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.
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.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use exception control to treat what is normally an error as no error or to treat a warning as an error. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
averaging parameters defines how the averaging is computed.
averaging mode specifies the averaging mode.

0No averaging (default)
1Vector averaging
2RMS averaging
3Peak hold
weighting mode specifies the weighting mode for RMS and vector averaging.

0Linear
1Exponential (default)
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.
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.
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.
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.
magnitudes returns an array of the magnitudes of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
magnitude is the magnitude of the averaged frequency response.
phases returns an array of the phases of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
phase is the phase of the averaged frequency response.
coherences returns an array of the coherence functions of the averaged frequency responses and the frequency scales.
f0 returns the start frequency, in hertz, of the spectrum.
df returns the frequency resolution, in hertz, of the spectrum.
coherence returns the coherence.
averages completed returns the number of averages completed by the VI at that time.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.

Frequency Response Function (Mag-Phase) Details

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.

Example

Refer to the Frequency Analysis of a Filter Design VI in the labview\examples\measure\maxmpl.llb for an example of using the Frequency Response Function (Mag-Phase) VI.


Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit