题中有些信息贴的不全(可能是公式,贴不出来) 第1题t = 0:0.1:5*pi;
y1 = sin(t);
y2 = cos(t);
plot(t,y1,'r*',t,y2,'b-')
xlabel('t(deg)')
ylabel('magnitude')
title('sine wave from zero to 5pi')
text(pi/2,0.8,'这是我的程序运行结果!')
第2题t = linspace(0,2*pi,101);
a = 5;
b = 3;
x = a*cos(t);
y = b*sin(t);
plot(x,y)
axis equal