Nonparametric estimate of spectrum using shorttime, fast Fourier transform (FFT) method
Transforms
dspxfrm3
The ShortTime FFT block computes a nonparametric estimate of the spectrum. The block buffers, applies a window, and zero pads the input signal. The block then takes the FFT of the signal, transforming it into the frequency domain.
Connect your singlechannel analysis window to the w(n) port. For the Analysis window length parameter, enter the length of the analysis window, W. The block buffers the input signal such that it has a frame length of W
Connect your singlechannel or multichannel input signal to the x(n) port. After the block buffers and windows this signal, it zeropads the signal before computing the FFT. For the FFT length parameter, enter the length to which the block pads the input signal. For the Overlap between consecutive windows (in samples) parameter, enter the number of samples to overlap each frame of the input signal.
The block outputs the complexvalued, singlechannel or multichannel shorttime FFT at port X(n,k).
The following diagram shows the data types used within the ShortTime FFT subsystem block for fixedpoint signals.
The settings for the fixedpoint parameters of the ArrayVector Multiply block in the diagram above are as follows:
Rounding Mode — Floor
Overflow Mode — Wrap
Product output — Inherit
via internal rule
Accumulator — Inherit
via internal rule
Output — Same
as first input
The settings for the fixedpoint parameters of the FFT block in the diagram above are as follows:
Rounding Mode — Floor
Overflow Mode — Wrap
Sine table — Same
word length as input
Product output — Inherit
via internal rule
Accumulator — Inherit
via internal rule
Output — Inherit
via internal rule
See the FFT and ArrayVector Multiply block reference pages for more information.
The dspstsa
example
illustrates how to use the ShortTime FFT and Inverse ShortTime FFT
blocks to remove the background noise from a speech signal. To open
the dspstsa
model, type dspstsa
in
the MATLAB^{®} command prompt.
Specify the frame length of the analysis window. The Analysis window length must be a positive integer value greater than one.
Enter the number of samples of overlap for each frame of the input signal.
Enter the length to which the block pads the input signal.
Specify how the block treats samplebased Mby1 column vectors and unoriented samplebased vectors of length M. You can select one of the following options:
One channel
— When
you select this option, the block treats Mby1
and unoriented samplebased inputs as a column vector (one channel).
M channels (this choice will be removed
– see release notes)
— When you select
this option, the block treats Mby1 and unoriented
samplebased inputs as a 1byM row vector.
Note: This parameter will be removed in a future release. See the DSP System Toolbox™ Release Notes for more information. 
Quatieri, Thomas E. DiscreteTime Speech Signal Processing. Englewood Cliffs, NJ: PrenticeHall, 2001.
Port  Supported Data Types 

x(n) 

w(n) 

X(n,k) 

Burg Method  DSP System Toolbox 
Inverse ShortTime FFT  DSP System Toolbox 
Magnitude FFT  DSP System Toolbox 
Periodogram  DSP System Toolbox 
Spectrum Analyzer  DSP System Toolbox 
Window Function  DSP System Toolbox 
YuleWalker Method  DSP System Toolbox 
pwelch  Signal Processing Toolbox 
See Spectral Analysisfor related information.