% set up parameters N = 64; F = fft(eye(N)); RF = real(F); IF = imag(F); mn = -1; mx =1; %Fi = ifft(eye(N)); Fi = inv(F); RFi = real(Fi); IFi = imag(Fi); mni = -1/N; mxi =1/N; for i =1:N figure(1) D = RF; D(i,:)= mn*ones(1,N); subplot(2,2,1) imshow(D,[]); title('Analysis matrix (real part)') subplot(2,2,2) plot(1:N,RF(i,:),'r'); axis([1,N,mn,mx]); title('Analysis waveform (real part)') D=RFi; D(:,i)= mni*ones(N,1); subplot(2,2,3) imshow(D,[]); title('Synthesis matrix (real part)') subplot(2,2,4) plot(1:N,RFi(:,i),'r'); axis([1,N,mni,mxi]); title('Synthesis waveform (real part)') drawnow; pause(1); figure(2) D = IF; D(i,:)= mn*ones(1,N); subplot(2,2,1) imshow(D,[]); title('Analysis matrix (imaginary part)') subplot(2,2,2) plot(1:N,IF(i,:),'g'); axis([1,N,mn,mx]); title('Analysis waveform (imaginary part)') D=IFi; D(:,i)= mni*ones(N,1); subplot(2,2,3) imshow(D,[]); title('Synthesis matrix (imaginary part)') subplot(2,2,4) plot(1:N,IFi(:,i),'g'); axis([1,N,mni,mxi]); title('Synthesis waveform (imaginary part)') drawnow; pause(1); end;