# Describe the cylinder

1. Nov 4, 2012

### Mdhiggenz

1. The problem statement, all variables and given/known data

Describe the cylinder x2+y2=9
in terms of parameters theta and phi, where (p,theta,phi) are spherical coordinates of a point on the surface.

I'm a bit confused I know that spherical coords are

x=Psin(phi)cos(theta)=3sin(phi)cos(theta)

y=Psin(phi)sin(theta)=3sin(phi)sin(theta)

z= Pcos(phi)=3cos(phi)

But the answer is way off it's
x = 3 cos(theta) ; y = 3sin(theta) ; z = 3 cot(phi)

2. Relevant equations

3. The attempt at a solution

2. Nov 4, 2012

### Staff: Mentor

In your third equation you're thinking that P is the radius of the circle.

Slice the the cylinder with a plane containing X and Z axes and you'll see two vertical lines so a point on the cylinder is a vector from the origin to the point which makes a triangle with the P being the bottom side and the z value being the vertical side .

Now describe Z in terms of spherical coordinates phi angle.

3. Nov 4, 2012

### Mdhiggenz

Not really sure what you mean?

4. Nov 4, 2012

### Staff: Mentor

your eqn is a cylinder along the z axis, right?

So if you slice the cylinder with a plane containing the X and Z axes you'll see two vertical lines at x=3 and x=-3, right?

5. Nov 4, 2012

Indeed

6. Nov 4, 2012

### haruspex

jedishrfu is pointing out that there is some confusion regarding p (or P).
In the problem statement, p is the distance from the origin to a point on the cylinder. You have used P as the radius of the cylinder (=3). A point on the cylinder may be further than 3 from the XY plane, so z cannot be given by 3 cos(phi).

7. Nov 5, 2012

### HallsofIvy

Staff Emeritus
$\rho$, what you are calling "P", is the straight line distance from the origin to the point, (x, y, z). It is NOT $\sqrt{x^2+ y^2}$, the distance, in the xy-plane, to the projection (x, y, 0).

From $x= \rho cos(\theta)sin(\phi)$ and $y= \rho sin(\theta)sin(\phi)$, you can get $x^2+ y^2= \rho^2 cos^2(\theta) sin^2(\phi)+ \rho^2sin^2(\theta)sin^2(\phi)= \rho^2sin^2(\phi)$.