plotting an implicitly defined function in 3 dimensions

I'm looking to graph the function x + y + z = 4 in three dimensions but am having difficulty. The code I used is as follows: [x,y,z] = meshgrid( linspace( -100, 100, 200 ) ); f = x + y + z; isosurface(x, y, z, f, 4) and a result is produced, but it's not what I'm looking for. Any advice?

 Respuesta aceptada

Something like this?
t = linspace( -100, 100, 50 );
[x y] = meshgrid(t);
surf(x,y,4-x-y)

Más respuestas (0)

Categorías

Más información sobre 2-D and 3-D Plots en Centro de ayuda y File Exchange.

Etiquetas

Preguntada:

el 3 de Feb. de 2017

Respondida:

el 3 de Feb. de 2017

Community Treasure Hunt

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

Start Hunting!

Translated by