How to interpret FFT output signal?

34 views (last 30 days)
Hi,
我正在使用FFT分析信号以获得其频谱。原始数据如下所示。
机器应以0.316 Hz的频率测量。
Code spectral analysis:
x = t2(:,3);
%x = x-mean(x);
n = length(x);
dt = 3;
fs = 1/dt;
t =(0:n-1)*dt;
y = fft(x);
f = (0:n-1)*(fs/n);
功率= abs (y)。^ 2 / n;
figure()
plot(f,power)
Xlabel('Frequency [Hz]')
ylabel('Power')
网格
After spectral analysis I end up with two peaks: one at 0 Hz and one at 0.3316 Hz.
If you uncomment the second line you end up with this: a peak at 0.0017 and 0.3316 Hz.
My question is how to interpret the first peak? Has it a physical meaning? I've read somewhere that a large peak at zero frequency means that you have a massive DC offset. What does that mean? And could it be that through discretization the actual value (0.316 Hz) and found value (0.3316 Hz) are slightly different?
3 Comments
瑞娜·伯曼(Rena Berman)
(Answers Dev) Restored edit

Sign in to comment.

Answers (1)

Peng Li
Peng Li 上6 Aug 2020
Based on your code, your sampling frequency is 1/3 Hz. There is no way you can detect a component of 0.316 Hz using 1/3 Hz sampling frequency.
频谱对称为0 Hz。默认情况下,MATLAB给出了对称fs/2的偏移频谱。您可以fftshift,也可以简单地绘制上半场。右侧的第二个高峰不是您要检测到的。它只是左侧峰的镜子。

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

开始狩猎!