1

I have an ellipse defined as the following parametric equations:

$$x(t)=a\cos{(t+\phi_1)}$$ $$y(t)=b\cos{(t+\phi_2)}$$ $$0 \le t < 2\pi$$

I would like to know the length of the semi-major and semi-minor axes, and rotation angle, of this ellipse (in terms of $a$, $b$, $\phi_1$, and $\phi_2$). I have tried to transform these equations into the standard parametric form of an ellipse as given in this answer, but I have failed.

If we define $ϕ3=ϕ2+π/2$ then we have $x(t)=a\cos t\cosϕ_1−a\sin t\sinϕ_1$ and $y(t)=b\sin t\cosϕ_3+b\cos t\sinϕ_3$. Comparing coefficients with the linked answer, we then have $a\cosϕ_1=R_x\cosθ$, $a\sinϕ_1=R_y\sinθ$, $b\sinϕ_3=R_x\sinθ$, and $b\cosϕ_3=R_y\cosθ$.

This is where I'm stuck though, because I keep going in circles hereon out. I know that it should be solvable because I have four equations for three unknowns ($θ$, $R_x$, and $R_y$).

  • It would be helpful if you posted your calculations so we could help you figure out how to proceed further. – rogerl Feb 03 '23 at 18:44
  • 1
    Hint: $\cos(t+\phi_2)=\sin(t+\phi_2+\pi/2),.$ – Kurt G. Feb 03 '23 at 18:45
  • This is meaner than I thought it would be. Some guidance on what you've tried would help though – Dan Uznanski Feb 03 '23 at 18:59
  • If we define $\phi_3 = \phi_2 + \pi/2$ then we have $x(t)=a\cos{t}\cos{\phi_1}-a\sin{t}\sin{\phi_1}$ and $y(t)=b\sin{t}\cos{\phi_3} + b\cos{t}\sin{\phi_3}$. Comparing coefficients with the linked answer, we then have $a\cos{\phi_1} = R_x \cos{\theta}$, $a\sin{\phi_1} = R_y\sin{\theta}$, $b\sin{\phi_3} = R_x \cos{\theta}$, and $b\cos{\phi_3} = R_y \sin{\theta}$. – Plagioclase Feb 03 '23 at 19:00
  • This is where I'm stuck though, because I keep going in circles hereon out. I know that it should be solvable because I have four equations for three unknowns ($\theta$, $R_x$, and $R_y$). – Plagioclase Feb 03 '23 at 19:02
  • Sorry, the last two equations above should be $b\sin{\phi_3} = R_x \sin{\theta}$ and $b\cos{\phi_3} = R_y \cos{\theta}$ – Plagioclase Feb 03 '23 at 19:07
  • I have $a^2 \sin^2{\phi_1} + b^2 \cos^2{\phi_3} = R_y^2$, but I've tested this on a Desmos set-up, and it doesn't fit (https://www.desmos.com/calculator/1bdjcakgj7) – Plagioclase Feb 03 '23 at 19:12
  • 1
    So, neat trick: $(a\cos(t),b\cos(t+\phi_2-\phi_1))$ is the same ellipse with a different starting point... – Dan Uznanski Feb 03 '23 at 19:30
  • Thank you! Using that, I have $\tan{\theta} = \frac{b}{a}\cos{\phi_3}$, $R_x = a\sec{\theta}$, and $R_y = -\frac{b}{a}R_x \sin{\phi_3}$. I'll try to neaten that up, but that's seems to give me the right answer. Greatly appreciated! – Plagioclase Feb 03 '23 at 19:55
  • If you've gotten there, write an answer yourself – Dan Uznanski Feb 03 '23 at 20:05
  • Nevermind, it wasn't the right answer! – Plagioclase Feb 03 '23 at 20:28
  • Your curve is just a Lissajous figure of the same frequency. Please refer to my older post of mine here. – Ng Chung Tak Feb 04 '23 at 07:38

1 Answers1

4

The solution seems messy. One approach to finding the major and minor axes is to find the critical points of the squared-distance-to-origin function $$ f(t):=[a\cos t]^2 + [b\cos(t+\beta)]^2 ;\tag1 $$ to simplify a bit I've reparametrized so that $\phi_1=0$ and I've written $\beta$ in place of $\phi_2-\phi_1$. The critical points $t^*$ and $t^{**}$ between $0$ and $\pi$ where $f'(t)=0$ will be $\frac\pi2$ apart and will correspond to the semi-major and semi-minor axes. Their squared lengths will be obtained by plugging $t^*$ and $t^{**}$ back into (1). The rotation angle will be the inclination of the line segment from $(0,0)$ to $(x(t^*), y(t^*))$ [or $(x(t^{**}), y(t^{**}))$, take your pick].

To find the critical points, differentiate (1) and simplify: $$ \begin{align} f'(t)&=-2a^2\cos t\sin t - 2b^2 \cos(t+\beta)\sin(t+\beta)\\ &=-\left(a^2\sin(2t) + b^2\sin(2t+2\beta)\right)\\ &=-\left(\sin(2t)[a^2+b^2\cos(2\beta)]+\cos(2t)[b^2\sin(2\beta)]\right) \end{align} $$ so the critical points satisfy the equation $$\tan(2t)=-\frac{b^2\sin(2\beta)}{a^2+b^2\cos(2\beta)}. $$

grand_chat
  • 38,951