How to get the matrix with the z values in cartesian coordinates from surface plot drawn in polar coordinates
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Mariia
el 23 de Abr. de 2018
Respondida: Mariia
el 24 de Abr. de 2018
I have a surface initialized in cartesian coordinates and later converted to polar coordinates.
N = 100; % number of small sectors in one segmen
row = 10; % number of segments
M = N*row;
x = 0:(1-0)/(N-1):1; % segment matrix cartesian
xx = repmat(x,M,row);
radius = 0:(2*pi-0)/(M-1):2*pi;
radius = repmat(radius,M,1);
radius = transpose (radius);
alfa = 0:1/(M-1):1;
alfa = repmat(alfa,M,1);
[X,Y,value] = pol2cart(radius,alfa,xx);
figure
h = mesh(X,Y,value);
colormap gray;
view(2);
I plot it in polar coordinates.

Now I need to get the data points from this surface (z-values only) arranged as square matrix (the same size as plot area) exactly as they look in the plot. How can I get them?
Thanks in advance.
2 comentarios
Respuesta aceptada
Más respuestas (0)
Ver también
Categorías
Más información sobre Surface and Mesh Plots en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

