size=8;

img=zeros(size,size);
img(1:size,1:(size/2)-1)=28;
img(1:size,(size/2):size)=30;

%mesh(img);


disimg=zeros(size,size);
disimg(1:size,1:(size/2)+2)=28;
disimg(1:size,(size/2)+3:size)=30;


fimg=fftshift(fft2(fftshift(img)));
fdisimg=fftshift(fft2(fftshift(disimg)));

figure;
plot(abs(fimg));
title('abs F orig')

figure;
plot(abs(fdisimg));
title('abs F dis')

figure;
plot(angle(fimg));
title('angle F orig')

figure;
plot(angle(fdisimg));
title('angle F dis')

imagesc(img);

%mesh(fimg);

