How to plot a paraboloid in Maple using spherical coordinates?

545 Views Asked by At

I am studying spherical coordinates.

Here is the equation of a paraboloid in rectangular coordinates $$z = x^2 + y^2$$

In spherical coordinates $$\rho \cos(\phi)=\rho^2 \sin^2(\phi) \implies \rho (\rho \sin^2(\phi)-\cos(\phi))=0$$

So here is what I believe the equation is in spherical coordinates $$\rho=\frac{cos(\phi)}{sin^2(\phi)}, 0 \leq \phi \leq \pi/2$$ When I try to plot this in Maple, I obtain a figure which does not correspond to a paraboloid.

The Maple command I run is roughly

plot3d(cos(phi)/sin^2(phi), phi=0..Pi/2, coords=spherical)

and I obtain enter image description here

Is there a mathematical mistake in my equation for a paraboloid, or is this a Maple-related issue?

Note that I obtain what looks like a correct result when I use the command implicitplot3d:

implicitplot3d(rho*cos(phi) = rho^2*sin(phi)^2, rho = 0 .. 10, theta = 0 .. 2*Pi, phi = 0 .. Pi/2, coords = spherical)

enter image description here

How come plotting the implicit equation differs from plotting the equation where I cancel one of the $\rho$ terms?

1

There are 1 best solutions below

0
On BEST ANSWER

You have overlooked the 2nd plotting variable.

The plot3d command doesn't care what names you use for the plotting variables. It doesn't distinguish between, say phi and theta by name. You can use any names you want for the polar angle and the azimuthal angle.

Maple distinguishes between the polar angle variable and the azimuthal angle variable by relative position in the calling sequence of the plotting command. It doesn't distinguish them by any special naming convention.

You only passed a single variable=range option to the plot3d command, and omitted the second. Maple is happy to provide the second for you, and it interprets the one you supplied as denoting the polar angle which comes first in this calling sequence.

These two produce a similar result (yours is the first, for which Maple fills in the second range for you). In both of these phi is taken as the polar angle, and theta as the azimuthal angle.

plot3d(cos(phi)/sin^2(phi),
       phi=0..Pi/2,
       coords=spherical)

plot3d(cos(phi)/sin(phi)^2,
       phi=0..Pi/2, theta=-Pi..Pi,
       coords=spherical);

But what you are looking for is the calling sequence where phi is the azimuthal angle, and so the calling sequence could be,

plot3d(cos(phi)/sin(phi)^2,
       theta=-Pi..Pi, phi=0..Pi/2,
       coords=spherical);

Naturally, you could also use theta=0..2*Pi for full polar rotation.

For comparison,

PP := plot3d(cos(phi)/sin(phi)^2,
         theta=0..2*Pi, phi=0..Pi/2,
         coords=spherical, color=blue):
PR := plot3d(x^2+y^2, x=-25..25, y=-25..25,
             color=red ):
plots:-display(PR, PP);

enter image description here