0
$\begingroup$

I have the general parametric equation of an ellipse.

$\begin{align*}x&=c_x+a\cos{t}\cos{\alpha}-b\sin{t}\sin{\alpha} \\ y&=c_y+a\cos{t}\sin{\alpha}+b\sin{t}\cos{\alpha}\end{align*}$

I need to find the value of $t$ when $x$ and $y$ are known. I tried solving the equation and ended up with

$t = \arccos{\frac{(x-c_x)\cos{\alpha} + (y-c_y)\sin{\alpha}}{a}}$

The first thing that bothers me about this equation is that it doesn't depend on $b$. The major issue is, it seems that the value of $t$ I get is more and more inaccurate with increasing $\alpha$.

Please check the demo here.

  • 0
    @J.M.: Please go ahead. I will produce an answer only if no one else seems to be doing it.2011-07-29

1 Answers 1

3

You are almost there. Eliminating the $b$-terms (by multiplying the first of the given equations with $\cos\alpha$, the second with $\sin\alpha$) you got the first of the following two equations; eliminating in the same way the $a$-terms you get the second: $\eqalign{ (x-c_x)\cos\alpha +(y-c_y)\sin\alpha&=a\cos t\ , \cr -(x-c_x)\sin\alpha+(y-c_y)\cos\alpha&=b\sin t\ .\cr}$ As $\ t=\arg(\cos t,\sin t)$ (mod $2\pi$) we obtain $t\ =\ \arg\Bigl({(x-c_x)\cos\alpha +(y-c_y)\sin\alpha\over a}\ ,\ {-(x-c_x)\sin\alpha+(y-c_y)\cos\alpha \over b}\Bigr)\ .$

  • 0
    Well it seems André's above tip works best in my case.2011-07-30