Register to reply

Plotting a plane in Mathematica

by Pengwuino
Tags: mathematica, plane, plotting
Share this thread:
Pengwuino
#1
Nov28-05, 08:46 PM
PF Gold
Pengwuino's Avatar
P: 7,120
Hello ladies and gentlemen,

Does anyone know how to plot the plane y=2 in 3d? I'm looken for a curve of intersection with a surface and I don't seem to know how to plot the y=2 plane :)
Phys.Org News Partner Science news on Phys.org
Hoverbike drone project for air transport takes off
Earlier Stone Age artifacts found in Northern Cape of South Africa
Study reveals new characteristics of complex oxide surfaces
vaishakh
#2
Nov30-05, 07:57 PM
P: 342
What do you mean by plotting? You can understand that it contains all points in 3d space where the co-ordinate of y is 2. For example (0,2,0), (2,2,0) and (0,2,2). You must know that three non-collinear points define a plane. So it is the plane that consists of the following points
Pengwuino
#3
Nov30-05, 09:10 PM
PF Gold
Pengwuino's Avatar
P: 7,120
Well I needed to know how to enter that into Mathematica. I was trying parametric crap with t's and it just gave me a stupid line. I finally found out what i had to do though to get an actual plane to show up though.. thanks anyways.

loweaxerium
#4
May23-11, 12:48 PM
P: 1
Plotting a plane in Mathematica

hey having the same problem what u did to get the plane?
wil3
#5
May23-11, 04:13 PM
P: 181
Use the Plot3D command:

Plot3D[y = 2, {x, 0, 10}, {y, -2, 2}]

Nota bene: If you fail to express the equation as an equality, it automatically treats the first argument as equal to an unspecified z variable. So the function
Plot3D[y - 2, {x, 0, 10}, {y, -2, 2}] would *not* plot a y-plane, since it actually would end up plotting z = y - 2 (although the zero level set of that function would be your plane)
Bill Simpson
#6
May23-11, 09:13 PM
P: 1,028
Quote Quote by wil3 View Post
Use the Plot3D command: Plot3D[y = 2, {x, 0, 10}, {y, -2, 2}]
I believe that is plotting z=2 and not y=2. You can verify that with this
Plot3D[y = 2, {x,0,10}, {y,-2,2}, AxesLabel->{x,y,z}]
to label the axes so you can see if your plane is at 2 on the z axis or the y axis.

To plot in the y=2 plane I believe this might do what you want:
ParametricPlot3D[{x,2,z}, {x,-2,2}, {z,-2,2}, AxesLabel->{x,y,z}]

There is a nice tutorial I found using Google that you can use to learn this stuff.
http://www.math.uconn.edu/~hurley/ma...ocs/Planes.pdf
wil3
#7
May23-11, 09:20 PM
P: 181
I see what you mean... doesn't plotting y = 2 look the same as plotting z = 2, just with different axes labeling? And that's strange that even though y = 2 is explicitly stated, Mathematica interprets it as z = 2
Bill Simpson
#8
May23-11, 09:34 PM
P: 1,028
Quote Quote by wil3 View Post
And that's strange that even though y = 2 is explicitly stated, Mathematica interprets it as z = 2
Mathematica is very likely not the language you think it is or doing what you think it is doing.

When you put y=2 in there it created a definition that in the future if you ever used y it should be immediately replaced with 2, at least until you changed it, AND THEN the "value" of y=2 was also 2, so the "y" was gone by the time Plot3D got its hands on what you wrote. So what Plot3D "saw" was Plot3D[2, etc,etc,etc]. Now since Plot3D is expecting some sort of function giving the value of z for the various values of x and y it then plotted the plane z==2 and that was what you saw when you added axis labels.

Learning the strange way that Mathematica evaluates expressions is a serious undertaking. Even when you think you are finally getting the hang of it you are probably only getting close to ready to move up to the next level in the game.
wil3
#9
May23-11, 09:36 PM
P: 181
okay man. my bad


Register to reply

Related Discussions
Help with plotting in Mathematica Math & Science Software 13
Plotting in Mathematica Math & Science Software 9
Plotting in Mathematica Math & Science Software 6
Mathematica Plotting Question Math & Science Software 2
Help with plotting in Mathematica Math & Science Software 1