Frequency analysis using FFT
18 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Thomas Leiw
el 11 de Sept. de 2015
Comentada: Star Strider
el 13 de Sept. de 2015
Dear colleagues, my question is How to analyse the frequencies and its corresponding magnitude within an array by using FFT function in MatLab?
I am certain that the values in the array have the following information:
- Already sampled at 1kHz
- Contains 30001 samples
- The sampled waveform is superimposed with multiple frequencies (e.g. 15Hz, 34Hz, etc)
I would like to analyse the magnitudes of each frequency band that is contained in the samples.
Thank you very much for any help!
Thomas
0 comentarios
Respuesta aceptada
Star Strider
el 12 de Sept. de 2015
The fft documentation has everything you need in the code between the first two plot images. Your Nyquist frequency is 500 Hz.
To get the peak values and frequencies, use the Signal Processing Toolbox findpeaks function. It has a number of name-value pair arguments that make it extremely flexible.
8 comentarios
Star Strider
el 13 de Sept. de 2015
It is correct, and entirely consistent with the previous version of the documentation on the fft function. (The documentation for fft changed in R2015b. The previous versions seemed to me to be more straightforward.) The single-sided fft in the documentation is correct, since it seems to have been taken from the R2015b fft documentation.
For your data, the amplitudes in my code at 16.3 Hz even with slightly revised code (corresponding to the R2015a fft documentation), are about 0.1 of those stated.
The only significant change in my code is:
[Pks,Frq] = findpeaks(2*abs(Fd(Iv)), Fv, 'MinPeakDistance', 0.25, 'MinPeakHeight',0.01);
Más respuestas (0)
Ver también
Categorías
Más información sobre Time-Frequency Analysis en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!