0
$\begingroup$

I am trying to plot in spherical coordinates the ellipsoid defined as

$$(x/3a)^2+(y/2a)^2+(z/4c)^2=1$$

This is my code:

ParametricPlot3D[{Cos[u] Sin[v], Sin[u] Sin[v], (1/3 Cos[u] Sin[v])^2 + 
    (1/2 Sin[u] Sin[v])^2 + (1/4 Cos[v])^2 == 1}, {u, 0, 2 π}, {v, -π, π}]

What am I doing wrong? No errors are displayed and an empty frame is all I see.

$\endgroup$
2
  • $\begingroup$ Doing Solve[(1/3 Cos[u] Sin[v])^2 + (1/2 Sin[u] Sin[v])^2 + (1/4 Cos[v])^2 == 1, {u, v}] will shed some light on the problem. Mathematica can't get solution there. May be needs some assumptions. Try Reduce to see. $\endgroup$
    – Nasser
    Commented Oct 4, 2013 at 23:55
  • $\begingroup$ The third element of the vector you use makes no sense. In this form, it'll evaluate to True or False (as it's an equality test with ==), which doesn't bode well for plotting anything. $\endgroup$
    – kirma
    Commented Oct 5, 2013 at 7:15

1 Answer 1

5
$\begingroup$

Typically, the parametrization is a rescaling of spherical coordinates:

With[{a = 3, c = 2},
 ParametricPlot3D[{3 a Cos[u] Sin[v], 2 a Sin[u] Sin[v], 4 c Cos[v]},
   {u, 0, 2 π}, {v, -π, π}]
]

Mathematica graphics

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.