Code covered by the BSD License  

Highlights from
Contemporary Communications Systems Matlab Files

image thumbnail

Contemporary Communications Systems Matlab Files

by

 

Matlab Files in this book

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

Contact us