我这有个初程序不知对你有没有用 7!h>
< sx
clear MJrPI a[pN
dt=; %时间间隔 e$2P/6k>
s= %信号数组 M] +.xo+A
len=128; ,,+4d :8$
F=2*pi*(0:len/2)/len/dt; as('ZD.9
fs=fft(s,len); ;<thEWH;Y
p=fs.*conj(fs) RgW#z-PZF
p=p(1:len/2+1); 8ZqLGa]
plot(F,p) }S3 oX$
ylabel('power spectrum density ') F#M(#!)Y"
xlabel('sequence ') ;E[Q/
tr:w
title('03051171') 6/?onEL9_
参数自已改吧