Table Of Contents

FFT Spectrum (Mag-Phase » Single-shot) (G Dataflow)

Version:
    Last Modified: January 9, 2017

    Computes the single-sided, scaled amplitude spectrum of a time-domain signal.

    connector_pane_image
    datatype_icon

    unwrap phase

    A Boolean specifying whether to unwrap the phase.

    True Unwraps the phase.
    False Does not unwrap the phase.

    Unwrapping eliminates discontinuities that have an absolute value greater than pi.

    Default: False

    datatype_icon

    signal

    The input time-domain signal, usually in volts.

    This input can be a 1D array of double-precision floating-point numbers or a 1D array of complex double-precision floating-point numbers.

    The time-domain record must contain at least three cycles of the signal for a valid estimate.

    datatype_icon

    error in

    Error conditions that occur before this node runs. The node responds to this input according to standard error behavior.

    Default: No error

    datatype_icon

    dt

    The sample period of the time-domain signal, usually in seconds.

    Set this input to 1/fs, where fs is the sampling frequency of the time-domain signal.

    Default: 1

    datatype_icon

    magnitude

    The magnitude of the single-sided power spectrum.

    datatype_icon

    phase

    The single-sided amplitude spectrum phase, in radians.

    datatype_icon

    error out

    Error information. The node produces this output according to standard error behavior.

    datatype_icon

    df

    The frequency interval of the power spectrum. The unit of this output is Hz if the sample period is in seconds.

    Algorithm for Calculating the Amplitude Spectrum

    To compute the single-sided, scaled amplitude spectrum, this node first uses the following equation to compute the two-sided amplitude spectrum:

    A ( i ) = X ( i ) N i = 0 , 1 , ... , N 1

    where

    • A is the two-sided amplitude spectrum
    • X is the discrete Fourier transform of signal
    • N is the number of points in signal

    Then, this node uses the following equation to convert the two-sided amplitude spectrum to the single-sided amplitude spectrum:

    B ( i ) = { A ( 0 ) i = 0 2 A ( i ) i = 1 , 2 , ... , N 2 1

    where B is the single-sided amplitude spectrum and   is the floor operation.

    This node computes the magnitude of the single-sided amplitude spectrum B as magnitude = B and the phase as phase(B).

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: Not supported


    Recently Viewed Topics