Plot a Cilinder or Sphere 3D

Hi To All !!!!
I have a new matrix (attached) with the values for Angles, Z and the data collected.
How can I plot the Matrix? It supouse to be a Cylinder or SPhere 3D.
Also, is there any way to interpolate the values? There are little values, I don't know how to improve the plot.
Thank you for any help!

 采纳的回答

Still not sure what the matrix represents, but here is something:
M = readmatrix('New Sphere 3D.txt');
angles = M(1,1:end-1);
z = M(2:end,1);
M(1,:) = [];
M(:,1) = [];
[x,y] = pol2cart(deg2rad(angles),M);
figure
plot3(x,y,z,'.')
figure
x_surf = x(:,[1:end 1]);
y_surf = y(:,[1:end 1]);
z_surf = z(:,ones(1,numel(angles)+1));
surf(x_surf,y_surf,z_surf)

更多回答(0 个)

类别

Community Treasure Hunt

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

Start Hunting!

Translated by