Fast Fourier Transform Issue
Afficher commentaires plus anciens
Hello.
In the Matlab description of the FFT implementation (https://www.mathworks.com/help/matlab/ref/fft.html). There is this part where the vector Y is divided by the length L in order to compute the spectrum. I cannot understand why it is required to divide by L, if someone can maybe enlighten this point.
Compute the two-sided spectrum P2. Then compute the single-sided spectrum P1 based on P2 and the even-valued signal length L.
P2 = abs(Y/L);
P1 = P2(1:L/2+1);
P1(2:end-1) = 2*P1(2:end-1);
Thank you.
1 commentaire
dpb
le 8 Juil 2021
In short, it's simply to normalize the PSD peak to the amplitude of the input time series -- if don't then the magnitude is proportional to the length of the input.
Just had long discussion (amongst many over the years) a short time ago. The final comment I added at https://www.mathworks.com/matlabcentral/answers/847665-why-do-i-receive-results-mismatch-in-the-fft-signal-while-using-matlab-built-in-fft-function-how-ca?s_tid=srchtitle#comment_1593465 illustrates what happens if one doesn't normalize;
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Filter Analysis dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!