How to interpret the frequencies on a symmteric FFT plot.
5 views (last 30 days)
Show older comments
Hi there,
I've produced an FFT plot to determine the frequency of vortex shedding from a cylinder. I've done some research and now understand why my plot exhbits perfect symmetry about a central line (as seen in the diagram below), however I'm still unsure of how to interpret this mathematically.
It seems logical to me that this would simply represent a second harmonic, although I'm not sure whether this is true.
Thank you in advance for your help with this.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1537130/image.jpeg)
0 Comments
Accepted Answer
Star Strider
on 12 Nov 2023
You need to use the fftshift function to put the zero frequency (D-C or constant offset) value in the centre. Then, depending on whether the fft vector has even or odd length, the ‘Fv’ (frequency vector) would be:
Fv = linspace(-Fs/2, Fs/2-Fs/length(s), length(s)); % EVEN 'length(s)' (Asymmetric)
Fv = linspace(-Fs/2, Fs/2, length(s)); % ODD 'length(s)' (Symmetric)
where ‘Fs’ is the signal sampling frequency and ‘s’ is the fft vector. You can then determine the frequencies from that. (I always calculate a one-sided fft. It’s easier to interpret.)
6 Comments
More Answers (1)
Paul
on 12 Nov 2023
Hi John,
The very short, and loose, answer to your question is as follows. Suppose we have a signal, like x[n] = cos(2*pi/N*k*n) (k,n and N are integers with k<N, 2*pi/N*k is the "frequency" in rad/sample). x[n] can be expressed as a sum of complex exponentials:
x[n] = cos(2*pi/N*k*n) = exp(1j*2*pi/N*k*n)/2 + exp(1j*(-2*pi/N*k)*n)/2
This is bascially what the FFT does. It determines the coefficients (to within a scale factor), in this case 1/2 and 1/2, that can be used to recononstruct x[n] as a sum of scaled complex exponentials. For a real signal x[n], we'll always have symmetry between the amplitude of the coefficients of the pairs of exponentials that correspond to +2*pi*k/N and -2*pi*k/N. Basically, the original cos has been "split" into two complex exponentials of mirror frequencies.
Because the complex exponential is perodic with period 2*pi, we can add an integer multiple of 2*pi to the second term
x[n] = exp(1j*2*pi/N*k*n)/2 + exp(1j*(2*pi/N*(-k)*n + 2*pi*n))/2
x[n] = exp(1j*2*pi/N*k*n)/2 + exp(1j*(2*pi*(-k/N+1)*n))/2
x[n] = exp(1j*2*pi/N*k*n)/2 + exp(1j*(2*pi/N*(-k+N)*n))/2
Looking at the second term on the right, we see that an equivalent frequency to -2*pi*k/N is 2*pi*(-k+N)/N, which is postive because N > k by assumption. That's the effect you're seeing in the "symmetric" FFT plot.
See Also
Categories
Find more on Spectral Measurements in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!