Je suis SAAD JAMAA %--------------------------------------------------------%-----> Visualisation graphique en 2D %--------------------------------------------------------x = -pi:pi/10:pi; y = tan(sin(x)) - sin(tan(x)); figure plot(x,y,'-rs','LineWidth',2,'MarkerEdgeColor','k','MarkerFaceColor','g','Ma rkerSize',10) grid % pour 2 courbes sur le même graphique t= 0:0.05:5; a=2; % amplitude w=3; % pulsation y1=a*sin(w*t); y2=a*cos(w*t); figure plot(t,y1,'bo',t,y2,'r+'),grid xlabel('temps'),ylabel('amplitude') title(' Courbe de sinus et cosinus') *RUN 5 : %--------------------------------------------------------%-----> Visualisation graphique en 3D %--------------------------------------------------------figure t = 0 : pi/1000 :10*pi ; plot3(sin(t),cos(t),t) ; xlabel('sin(t)'),ylabel('cos(t)'),zlabel('t') ; grid on axis square comet3(sin(t),cos(t),t) ; *RUN 4 : %--------------------------------------------------------%-----> Surfaces : mesh et surf %--------------------------------------------------------figure [X,Y] = meshgrid(-8 : .5 : 8) ; R = sqrt(X.^2 + Y.^2) + eps ; Z = sin(R)./R ; mesh(X,Y,Z) *RUN 3 : %--------------------------------------------------------%-----> Cylindre %--------------------------------------------------------[X,Y,Z] = cylinder(1,30) ; figure surf(X,Y,Z) R = ones(1,20) ; [X,Y,Z] = cylinder(R,30) ; surf(X,Y,Z) figure t = 0 : pi/10 : 2*pi ; R = 2 + cos(t) ; [X,Y,Z] = cylinder(R,30) ; surf(X,Y,Z) *RUN 1 : %--------------------------------------------------------%-----> Sphère %-------------------------------------------------------figure [X,Y,Z] = Sphère (30) ; surf(X,Y,Z) axis equal *RUN 2 :