How can i plot a 3d curve ?

37 Ansichten (letzte 30 Tage)
Mallouli Marwa
Mallouli Marwa am 22 Jun. 2017
Kommentiert: Mallouli Marwa am 17 Jul. 2017
Hello
How can i plot a 3d curve like (Figure 3D) as attached ?
For example:
x1 = [1 2 3 4 5 6 7 8 9 10];
x2 = [5 4 2 7 15 12 26 84 95 78];
x3 = [12 41 51 62 142 185 192 202 256 275 ];
plot3d (x1,x2,x3)
Using this program, I have obtained a line not a surface.
Please help me.

Akzeptierte Antwort

Jan
Jan am 22 Jun. 2017
See patch and surf.
  4 Kommentare
Mallouli Marwa
Mallouli Marwa am 17 Jul. 2017
Please how can i add the colour This is my example:
y1 = [28 28.5 29 35 50];
y2 = [1e2 1e3 1e4];
y3 = [0.30566 0.31675837 0.3280565163 0.4793385 0.98557455 3.04709 3.157375 3.269625 4.77027 9.7606137 29.5405784 30.576361 31.628 45.4737503 88.77938];
[Y1,Y2]= meshgrid (y1*1e-3 , y2) ; %(20:20:100,0:0.2:1);
figure (2)
surf(Y1,Y2,y3)
xlabel ('Length of layers (mm)')
ylabel('Load resistance (\Omega)')
zlabel('Power (\muW/g^2)')
Mallouli Marwa
Mallouli Marwa am 17 Jul. 2017
All my curves are blue
How can i change their colour ?

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Tags

Noch keine Tags eingegeben.

Community Treasure Hunt

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

Start Hunting!

Translated by