Short-time Fourier transform, short-time Fourier transformation, sometimes called the window Fourier transform, the time window makes the signal only in a certain small interval, which avoids the traditional Fourier transform in the time-frequency local expression ability of the insufficiency, The Fourier transform has the ability of local localization. 1. Stft under the Spectrogram:matlab
How can I compute a short-time Fourier transform (STFT) in MATLAB?
Stft differs from ft in that it is more of a concept of time, to signal y=sin (128⋅π⋅t) +sin (256⋅π⋅t) y=\sin (128\cdot \pi\cdot t) +\sin (256\cdot\pi\cdot t) (2πft⇒f 2\ Pi Ft⇒f is a frequency) for short-time Fourier transforms with 64 and 1282 of these analog signals.
FS = +;
t = 0:1/fs:2;
y = sin (128*pi*t) + sin (256*pi*t);
Figure;
WIN_SZ =;
Han_win = Hanning (WIN_SZ); % Select Hamming window
nfft = WIN_SZ;
Nooverlap = win_sz-1;
[S, F, T] = spectrogram (y, window, Nooverlap, NFFT, FS);
Imagesc (T, F, LOG10 (ABS (S)))
set (GCA, ' ydir ', ' normal ')
Xlabel (' Time (secs) ')
ylabel (' Freq (Hz) ')
title (' Short time Fourier transform Spectrum ')
2. CWT: Continuous wavelet transform
Time-frequency analysis of modulated signals
Wavelet transform further expands the capability of local time-frequency analysis.
[Cfs,f] = cwt (quadchirp, ' bump ', FS);
Helpercwttimefreqplot (cfs,tquad,f, ' surf ', ' CWT ' of quadratic Chirp ', ' Seconds ', ' Hz ')
The choice is bump type wavelet , the reason for selecting this type is that when the signal oscillation is intense, and more attention is paid to the time-frequency analysis of the signal local transients.
Load Quadchirp;
FS = +;
[S,f,t] = Spectrogram (QUADCHIRP,100,98,128,FS);
Helpercwttimefreqplot (s,t,f, ' surf ', ' STFT of quadratic Chirp ', ' Seconds ', ' Hz ')
We can further compare the STFT (short time Fourier transform) and CWT (continuous wavelet transform) in the time-frequency analysis of the refinement of the characterization capabilities.