# mathematica 7 :plot3d: plz help

• June 9th 2010, 09:58 AM
acied
mathematica 7 :plot3d: plz help
hi

how can i draw ( X^2+(Z-0.5)^2== 1 ) by using plot3d in mathematica 7
• June 9th 2010, 10:07 AM
undefined
Quote:

Originally Posted by acied
hi

how can i draw ( X^2+(Z-0.5)^2== 1 ) by using plot3d in mathematica 7

I have not had luck plotting non-functions in Mathematica. I would solve for z, resulting in

$z=\sqrt{1-x^2}+\frac{1}{2}$

OR

$z=-\sqrt{1-x^2}+\frac{1}{2}$

Then inputting

Code:

Plot3D[{Sqrt[1 - x^2] + 1/2, -Sqrt[1 - x^2] + 1/2}, {x, -10, 10}, {y, -10, 10}]
• June 9th 2010, 10:10 AM
Ackbeet
Or you could try a ParametricPlot3D command.
• July 14th 2010, 03:30 AM
scorpion007
Isn't that just a circle in the xz-plane?

Code:

ContourPlot[x^2 + (z - .5)^2 == 1, {x, -2, 2}, {z, -2, 2}]
• July 14th 2010, 04:04 AM
undefined
Quote:

Originally Posted by scorpion007
Isn't that just a circle in the xz-plane?

The surface is an infinitely long cylinder. The surface's intersection with the xz-plane is a circle.
• July 14th 2010, 04:22 AM
shawsend
Quote:

Originally Posted by acied
hi

how can i draw ( X^2+(Z-0.5)^2== 1 ) by using plot3d in mathematica 7

ContourPlot3D[x^2+(z-0.5)^2==1,{x,-5,5},{y,-5,5},{z,-5,5}]