塔里木大学 信息工程学院 surf543210420-2y-axis-4-4-2x-axis204clear all x=-3:0.1:3; y=-3:0.1:3;
[x,y]=meshgrid(-3:0.5:3); z=5./(1+x.*x+y.*y); mesh(x,y,z);
xlabel('x-axis'),ylabel('y-axis'),zlabel('z-axis'); title('mesh')
z-axis6
塔里木大学 信息工程学院 mesh543210420-2y-axis-4-4-2x-axis204z-axis
2.用stem绘制下列函数的杆图 (1)x?4sin(3n??/6)
clear all n=0:0.03:7; x=4*sin(3*n+pi/6); stem(n,x)
7
塔里木大学 信息工程学院 43210-1-2-3-401234567
(2)x?ejwn,w?3
clear all n=0:0.1:7; w=3;
x=exp(j*w*n); stem(n,x)
8
塔里木大学 信息工程学院 10.80.60.40.20-0.2-0.4-0.6-0.8-101234567
(3)x?clear all n=0:0.1:7; a=2; x=a.^n; stem(n,x)
an,a?2
9
塔里木大学 信息工程学院 14012010080604020001234567
3.绘制极坐标图: (1)??12?
clear all
theta=0:0.01:2*pi; rho=12./sqrt(theta); polar(theta,rho)
10