该命令的输入量(x,y,’s’)称为平面绘图三元组。他们分别指定平面曲线的几何位置、点形、线型和色彩。
(1)....例如:
plot(x,sin(x),'.b',x,cos(x),'+r')
legend(‘sin’,’cos’)这样可以把“.”标识为‘sin’,把“+”标识为“cos”
还可以用legend(…,’...示例代码:
x = 0:.2:12;
plot(x,sin(x),x,cos(x),x,tan(x));
legend('First','Second','Third');
legend('First...'Cucumbers','Eggplant')
x = -pi:pi/10:pi;
y = tan(sin(x)) - sin(tan(x));
plot(x,y,'--rs','LineWidth...); plot(sin(t),2*cos(t)); axis square; grid on %正方形的显示比例
figure(2)
subplot(1,2,1); plot(sin(t),2*cos