how to plot multiple 3d on one graph ?

173 次查看(过去 30 天)
I've try hold on but that isn't work. It turns out to be 2d plot
interval = [-5:0.1:5];
x = -5:0.1:5;
y = -5:0.1:5;
[X,Y] = meshgrid(x,y);
z1 = acos((cos(interval)+cos((interval).')));
z2 = acos(-(cos(interval)+cos((interval).')));
figure(1);
plot3(X,Y,z2)
figure(2);
plot3(X,Y,z1)

采纳的回答

Ameer Hamza
Ameer Hamza 2020-11-5
Following code works fine
interval = [-5:0.1:5];
x = -5:0.1:5;
y = -5:0.1:5;
[X,Y] = meshgrid(x,y);
z1 = acos((cos(interval)+cos((interval).')));
z2 = acos(-(cos(interval)+cos((interval).')));
figure(1);
plot3(X,Y,z2)
hold on
plot3(X,Y,z1)

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Annotations 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by