TFA Cohen (Complex) VI
- Updated2024-07-30
- 3 minute(s) read
Computes the Cohen's class time-frequency distribution of signal. kernel controls the properties of the resulting spectrogram. Wire data to the signal input to determine the polymorphic instance to use or manually select the instance.

Inputs/Outputs
signal
—
signal specifies the input signal.
time steps
—
time steps specifies the sampling period, in samples, along the time axis in the joint time-frequency domain. The default is -1, which specifies that this VI adjusts time steps automatically so that no more than 512 rows exist in spectrogram.
kernel
—
kernel specifies the upper half of a user-defined 2D kernel function. The number of rows in kernel determines the number of frequency bins, or the number of columns, in the resulting spectrogram. The number of rows in kernel must be a power of 2. The number of columns in kernel must be 2^(ceil(log2(Ls - 1))), where Ls is the length of signal.
error in (no error)
—
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
sampling rate
—
sampling rate specifies the sampling rate of signal in hertz. sampling rate must be greater than 0, or this VI sets sampling rate to 1 automatically. The default is 1.
spectrogram
—
spectrogram returns the quadratic time-frequency representation of the signal. Each row corresponds to the instantaneous power spectrum at a certain time.
scale info
—
scale info returns the time scale and the frequency scale information of the time-frequency representation, including the time offset, the time interval between every two contiguous rows, the frequency offset, and the frequency interval between every two contiguous columns of spectrogram. Use the TFA Get Time and Freq Scale Info VI to return detailed information about the time scale and the frequency scale.
error out
—
error out contains error information. This output provides standard error out functionality. |
TFA Cohen Details
For large values of the signal length, this VI requires a long computation time and more memory. National Instruments recommends that you limit signal to 15,000 samples.
Examples
Refer to the Pseudo Wigner-Ville Distribution VI in the labview\examples\Time Frequency Analysis\TFAFunctions directory for an example of using the TFA Cohen VI.
signal
—
time steps
—
kernel
—
error in (no error)
—
sampling rate
—
spectrogram
—
scale info
—
error out
—