I would like to know how to parametrize an ellipsoid not centered in the origin, but with its axes parallel to the main axes of the reference system.

The result I am looking for would be an expression of the distance of a point on the surface from the origin, given the azimuth and elevation (or any possible two angles of a spherical coordinate system).

I have found on wikipedia a similar formula for an ellipse. The given formula accounts also for rotation, which I don't necessarily need.


The parametrization for an ellipsoid is

$$\begin{align} x & = a \rho \sin(\theta) \sin(\varphi), \\ y & = b \rho \cos(\theta) \sin(\varphi), \\ z & = c \rho \cos(\varphi). \end{align}$$

To translate it parallel to the axes simply add $(x_0,y_0,z_0)$:

$$\begin{align} x & = x_0 + a \rho \sin(\theta) \sin(\varphi), \\ y & = y_0 + b \rho \cos(\theta) \sin(\varphi), \\ z & = z_0 + c \rho \cos(\varphi). \end{align}$$

We have

$$\frac{(x-x_0)^2}{a^2} + \frac{(y-y_0)^2}{b^2} + \frac{(z-z_0)^2}{c^2} = 1.$$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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