1-Génération d’images sinusoidales 

clc
clear all; 
close all; 
figure(1)
N=256; 
Am=128; 
Phi=pi/4;
T=16; 
val_moy=0;
offset0=N/2+1
i=1:N;
j=i;
fl=(i-offset0);
fc=(j-offset0);
[Fl,Fc]=meshgrid(fl,fc);
Im = val_moy + Am*sin(2*pi*(1/T)*(Fl*cos(Phi)+Fc*sin(Phi)));
Im = floor(Im);
imshow(Im);
title('  img sin (T=32, Phi=pi/4)')