matlab中三维制图程序错哪里了all;t=-2:0.1:2;[x,y]=meshgrid(t,t);z=-(x.^2+y.^2)+250;surf(x,y,z)xlabel('x');ylabel('y');zlabel('z');hold on;t1=-2:0.001:2;h=plot3(t1,zeros(1,length(t1)),-t1.^2+250,'LineWidth',3);legend(h,'要旋转的曲线');
来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/18 20:06:22
matlab中三维制图程序错哪里了all;t=-2:0.1:2;[x,y]=meshgrid(t,t);z=-(x.^2+y.^2)+250;surf(x,y,z)xlabel('x');ylabel('y');zlabel('z');hold on;t1=-2:0.001:2;h=plot3(t1,zeros(1,length(t1)),-t1.^2+250,'LineWidth',3);legend(h,'要旋转的曲线');
matlab中三维制图程序错哪里了
all;
t=-2:0.1:2;
[x,y]=meshgrid(t,t);
z=-(x.^2+y.^2)+250;
surf(x,y,z)
xlabel('x');ylabel('y');zlabel('z');
hold on;
t1=-2:0.001:2;
h=plot3(t1,zeros(1,length(t1)),-t1.^2+250,'LineWidth',3);
legend(h,'要旋转的曲线');
set(gcf,'Units','Normalized','Position',[0,0,1,1]);
matlab中三维制图程序错哪里了all;t=-2:0.1:2;[x,y]=meshgrid(t,t);z=-(x.^2+y.^2)+250;surf(x,y,z)xlabel('x');ylabel('y');zlabel('z');hold on;t1=-2:0.001:2;h=plot3(t1,zeros(1,length(t1)),-t1.^2+250,'LineWidth',3);legend(h,'要旋转的曲线');
第一行,copy的时候考错了吧?将all;改为clear all;