# Equation for making a circle in 3D space

I have a 3D space with axis $(x, y ,z)$ and I can make a circle in the $xy$-plane.

To make a circle in the xy-plane I currently use spherical coordinates $(r, \theta, \phi)$ where $r = 1$, $\theta = \pi/2$, and $\phi = [0, 2\pi]$ and this is converted to Cartesian coordinates $(x, y, z)$ using the equations:

$x = r\sin\theta$ $\cos\phi$

$y = r\sin\theta$ $\sin\phi$

$z = r\sin\theta$

How do I tile this circle around the y-axis ? so it can circle on any plane starting from the xy-plane to the zy-plane. I hope this all makes sense.

• Do you require your result to be in spherical coordinates again? Because giving a result in cartesian coordinates would be rather easy.
– MvG
Oct 17 '12 at 20:26
• @MvG cartesian coordinates is exactly what I need. I'm only using spherical coordinates because it made the equation easier. Oct 17 '12 at 20:27

You can simply rotate your setup: let $\phi\in[0,2\pi]$ parametrize your circle like you did, but use $\theta\in[0,\frac\pi2]$ to describe the rotation of your plane. Then you can use
For $\theta=0$ this gives a circle in the $xy$ plane, and for $\theta=\frac\pi2$ the circle lies in the $zy$ plane.