MATLAB求曲面相交所成空间曲线的图形曲面分别为x^2+y^2+z^2=9与x^2+z^2=4我只能画到这种程度最好是能在这之后加代码,t=0:0.1:pi;r=0:0.1:2*pi;[r,t]=meshgrid(r,t);x1=3*sin(t).*cos(r);y1=3*sin(t).*sin(r);z1=3*cos(t);u=0:0
来源:学生作业帮助网 编辑:作业帮 时间:2024/08/29 04:23:14
![MATLAB求曲面相交所成空间曲线的图形曲面分别为x^2+y^2+z^2=9与x^2+z^2=4我只能画到这种程度最好是能在这之后加代码,t=0:0.1:pi;r=0:0.1:2*pi;[r,t]=meshgrid(r,t);x1=3*sin(t).*cos(r);y1=3*sin(t).*sin(r);z1=3*cos(t);u=0:0](/uploads/image/z/15207487-7-7.jpg?t=MATLAB%E6%B1%82%E6%9B%B2%E9%9D%A2%E7%9B%B8%E4%BA%A4%E6%89%80%E6%88%90%E7%A9%BA%E9%97%B4%E6%9B%B2%E7%BA%BF%E7%9A%84%E5%9B%BE%E5%BD%A2%E6%9B%B2%E9%9D%A2%E5%88%86%E5%88%AB%E4%B8%BAx%5E2%2By%5E2%2Bz%5E2%3D9%E4%B8%8Ex%5E2%2Bz%5E2%3D4%E6%88%91%E5%8F%AA%E8%83%BD%E7%94%BB%E5%88%B0%E8%BF%99%E7%A7%8D%E7%A8%8B%E5%BA%A6%E6%9C%80%E5%A5%BD%E6%98%AF%E8%83%BD%E5%9C%A8%E8%BF%99%E4%B9%8B%E5%90%8E%E5%8A%A0%E4%BB%A3%E7%A0%81%2Ct%3D0%3A0.1%3Api%3Br%3D0%3A0.1%3A2%2Api%3B%5Br%2Ct%5D%3Dmeshgrid%28r%2Ct%29%3Bx1%3D3%2Asin%28t%29.%2Acos%28r%29%3By1%3D3%2Asin%28t%29.%2Asin%28r%29%3Bz1%3D3%2Acos%28t%29%3Bu%3D0%3A0)
MATLAB求曲面相交所成空间曲线的图形曲面分别为x^2+y^2+z^2=9与x^2+z^2=4我只能画到这种程度最好是能在这之后加代码,t=0:0.1:pi;r=0:0.1:2*pi;[r,t]=meshgrid(r,t);x1=3*sin(t).*cos(r);y1=3*sin(t).*sin(r);z1=3*cos(t);u=0:0
MATLAB求曲面相交所成空间曲线的图形
曲面分别为x^2+y^2+z^2=9与x^2+z^2=4
我只能画到这种程度
最好是能在这之后加代码,
t=0:0.1:pi;
r=0:0.1:2*pi;
[r,t]=meshgrid(r,t);
x1=3*sin(t).*cos(r);
y1=3*sin(t).*sin(r);
z1=3*cos(t);
u=0:0.1:2*pi;
v=-3:0.1:3;
[u,v]=meshgrid(u,v);
x2=2*cos(u);
y2=v;
z2=2*sin(u);
mesh(x1,y1,z1)
hold on
mesh(x2,y2,z2)
【只是为完成课程,个人兴趣不足】
MATLAB求曲面相交所成空间曲线的图形曲面分别为x^2+y^2+z^2=9与x^2+z^2=4我只能画到这种程度最好是能在这之后加代码,t=0:0.1:pi;r=0:0.1:2*pi;[r,t]=meshgrid(r,t);x1=3*sin(t).*cos(r);y1=3*sin(t).*sin(r);z1=3*cos(t);u=0:0
放在你程序后也可,单独运行也行;
t=-0.1:0.1:2*pi;
x=2*cos(t); % 交线参数方程
z=2*sin(t);
y1=sqrt(5)*ones(size(t));
plot3(x,y1,z,x,-y1,z) %画交线