How do I make a cylinder with base (2,0,1) and radius 2?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Anna
am 16 Dez. 2014
Bearbeitet: Mohammad Abouali
am 16 Dez. 2014
Also how do I assign heights?
0 Kommentare
Akzeptierte Antwort
Mohammad Abouali
am 16 Dez. 2014
Bearbeitet: Mohammad Abouali
am 16 Dez. 2014
where radius=2; Then to move the base to (x0,y0,z0)=(2,0,1) and also make the height of the cylinder to be h=10 do this
% Radius =2
R=2;
%Base at (2,0,1)
x0=2;y0=0;z0=1;
% Height = 10
h=10
[x,y,z]=cylinder(R)
x=x+x0;
y=y+y0;
z=z*h+z0;
% to plot
surf(x,y,z)
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Surface and Mesh Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!