how to plot a matrix values in 3d plot
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
abdelmadjid benrabah
le 26 Sep 2021
Commenté : Star Strider
le 26 Sep 2021
how to plot a matrix values in 3d plot
x=[0.2:0.5:0.8:1:1.5]
y=[0:0.2:0.4:0.6:0.8]
I got the matrix z=matrix(5x5) values from excel and each values correspond to x and y.
0 commentaires
Réponse acceptée
Star Strider
le 26 Sep 2021
It would be nice to have the ‘z’ matrix as well, however in its absence, I will create one.
x=[0.2;0.5;0.8;1;1.5];
y=[0;0.2;0.4;0.6;0.8];
z = x*y.';;
figure
surf(x, y, z)
grid on
xlabel('x')
ylabel('y')
Use semicolons (;) not colons (:) to do vertical concatenation. They are two entirely different operators, and are used for entirely different purpoases.
.
4 commentaires
Star Strider
le 26 Sep 2021
As always, my pleasure!
I will do my best to provied useful solutions.
.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Annotations dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


