Drawing 3 D for 3 data sets

1 visualización (últimos 30 días)
Asma A Bder Muhmed
Asma A Bder Muhmed el 11 de Sept. de 2020
Respondida: Ameer Hamza el 12 de Sept. de 2020
How I can draw 3D for the data below to have as in tha attached photo
X = [65 70 75 80 85 90 95 100];
Y = [36 38 40 42 44 46 50 54];
Z = [1792.373894 1178.621038 685.7078009 416.4883705 365.9043439 450.2110549 700.8830089 1040.358032];
  2 comentarios
KSSV
KSSV el 11 de Sept. de 2020
With the given data you cannot plot as shown in the atatched image.
Asma A Bder Muhmed
Asma A Bder Muhmed el 11 de Sept. de 2020
Do u know what is the altranative way?

Iniciar sesión para comentar.

Respuesta aceptada

KSSV
KSSV el 11 de Sept. de 2020
Whay you get is this:
X = [65 70 75 80 85 90 95 100];
Y = [36 38 40 42 44 46 50 54];
Z = [1792.373894 1178.621038 685.7078009 416.4883705 365.9043439 450.2110549 700.8830089 1040.358032];
m = numel(X) ;
Z = repmat(Z,m,1) ;
surf(X,Y,Z)

Más respuestas (1)

Ameer Hamza
Ameer Hamza el 12 de Sept. de 2020
Try something like this
X = [65 70 75 80 85 90 95 100];
Y = [36 38 40 42 44 46 50 54];
Z = [1792.373894 1178.621038 685.7078009 416.4883705 365.9043439 450.2110549 700.8830089 1040.358032];
xv = linspace(min(X), max(X), 100);
yv = linspace(min(Y), max(Y), 100);
[xg, yg] = meshgrid(xv, yv);
zg = griddata(X, Y, Z, xg, yg);
mesh(xg, yg, zg);

Categorías

Más información sobre Lighting, Transparency, and Shading 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