ip_02_07.m
上传用户:loeagle
上传日期:2013-03-02
资源大小:1236k
文件大小:0k
源码类别:

通讯编程文档

开发平台:

Matlab

  1. % MATLAB script for Illustrative Problem 2.7.
  2. echo on
  3. N=256;                  % number of samples
  4. deltaf=0.1;             % frequency separation
  5. f=[0:deltaf:(N/2)*deltaf, -(N/2-1)*deltaf:deltaf:-deltaf];
  6.                         % Swap the first half.
  7. Sy=1./(1+(2*pi*f).^2);          % sampled spectrum
  8. Ry=ifft(Sy);                % autocorrelation of Y
  9. % Plotting command follows.
  10. plot(fftshift(real(Ry)));