早教吧 育儿知识 作业答案 考试题库 百科 知识分享

matlab仿真出错,关于subplot函数t=0:0.01:10;x1=10*sin(t);x2=5*cos(t);subplot(2 1 1)plot(x1)subplot(2 1 2)plot(x2)仿真时出错,还可以指点一下,谢谢

题目详情
matlab仿真出错,关于subplot函数
t=0:0.01:10;
x1=10*sin(t);
x2=5*cos(t);
subplot(2 1 1)
plot(x1)
subplot(2 1 2)
plot(x2)
仿真时出错,还可以指点一下,谢谢
▼优质解答
答案和解析
subplot(2 1 1)改为subplot(2,1,1);subplot(2 1 2)改为subplot(2,1,2)即可
t=0:0.01:10;
x1=10*sin(t);
x2=5*cos(t);
subplot(2,1,1)
plot(x1)
subplot(2,1,2)
plot(x2)