matlab知道三个三维空间点的坐标,如何绘制这三个点构成的空间三角形,要求显示出空间直角坐标系。
三个空间点的坐标分别是Pc1=[-9.3225,-63.7486,199.4819]Pc2=[-50.7775,-52.8743,173.7286]Pc3=[-54.44...
三个空间点的坐标分别是Pc1 =[-9.3225,-63.7486,199.4819] Pc2=[ -50.7775,-52.8743,173.7286] Pc3=[-54.4475,-29.6580,192.3709
] 展开
] 展开
展开全部
Pc1 =[-9.3225,-63.7486,199.4819];
Pc2=[ -50.7775,-52.8743,173.7286];
Pc3=[-54.4475,-29.6580,192.3709];
x=[Pc1(1);Pc2(1);Pc3(1);Pc1(1)];
y=[Pc1(2);Pc2(2);Pc3(2);Pc1(2)];
z=[Pc1(3);Pc2(3);Pc3(3);Pc1(3)];
plot3(x,y,z)
xlabel('X')
ylabel('Y')
zlabel('Z')
grid on
有问题欢迎追问,满意请采纳,谢谢!
Pc2=[ -50.7775,-52.8743,173.7286];
Pc3=[-54.4475,-29.6580,192.3709];
x=[Pc1(1);Pc2(1);Pc3(1);Pc1(1)];
y=[Pc1(2);Pc2(2);Pc3(2);Pc1(2)];
z=[Pc1(3);Pc2(3);Pc3(3);Pc1(3)];
plot3(x,y,z)
xlabel('X')
ylabel('Y')
zlabel('Z')
grid on
有问题欢迎追问,满意请采纳,谢谢!
追问
我希望能看到坐标原点
追答
Pc1 =[-9.3225,-63.7486,199.4819];
Pc2=[ -50.7775,-52.8743,173.7286];
Pc3=[-54.4475,-29.6580,192.3709];
x=[Pc1(1);Pc2(1);Pc3(1);Pc1(1)];
y=[Pc1(2);Pc2(2);Pc3(2);Pc1(2)];
z=[Pc1(3);Pc2(3);Pc3(3);Pc1(3)];
plot3(x,y,z)
axis([-60,0,-70,0,0,210])
hold on%这句和下一句可注释,注释后就不会把原点画出来了
plot3(0,0,0,'.r','markersize',16)
xlabel('X')
ylabel('Y')
zlabel('Z')
grid on
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询