Borrar filtros
Borrar filtros

mesh from 1D (creating a matrix from a vector)

2 visualizaciones (últimos 30 días)
adam
adam el 1 de Nov. de 2012
Hello,
I have a vector A[-3:0.003:3] and a vector B whose values corresponding to those of A. I plotted B as a function of A ( it shows a curve like a gaussian). I would like now to plot in 3D using mesh. From vector A, i have to use two vectors x and y and I have to find a matrix from vector B.
Any help and I thank you in advance!
Adam

Respuestas (1)

Matt J
Matt J el 1 de Nov. de 2012
Sounds like MESHGRID or NDGRID is what you want.
  4 comentarios
adam
adam el 2 de Nov. de 2012
Hello, Thank you for your answer. But you didn't understand my question.
- I create two vectors x and y from the vector A provided that A=x.^2+y.^2.
- I have to create a matrix C from the vector B.
In this case i can plot mesh(x,y,C)
Thank you!
Matt J
Matt J el 2 de Nov. de 2012
Hello, Thank you for your answer. But you didn't understand my question.
Still don't...

Iniciar sesión para comentar.

Categorías

Más información sobre Surface and Mesh Plots en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by