1. 首页
  2. 数据库
  3. 其它
  4. hslogic算法仿真 信号的频谱分析

hslogic算法仿真 信号的频谱分析

上传者: 2021-04-17 13:40:58上传 ZIP文件 1.36KB 热度 17次
hslogic算法仿真-信号的频谱分析。function plotspec(x,Ts) N=length(x); % length of the signal x t=Ts*(1:N); % define a time vector ssf=(-N/2:N/2-1)/(Ts*N); % frequency vector fx=fft(x(1:N)); % do DFT/FFT fxs=fftshift(fx); % shift it for plotting figure; subplot(211), plot(x) subplot(212), plot(ssf,abs(fxs)) % plot magnitude spectrum xlabel('frequency'); ylabel('magnitude') % label the axes
下载地址
用户评论