Rotated ellipse tangent to circle

370 Views Asked by At

I need a formula that will locate the tangent point between a circle and a rotated ellipse.

Known:

  • Location and size of circle
  • Relative y coordinate of ellipse vs circle
  • Major/Minor radii of ellipse
  • Angle of rotation of ellipse

The only solutions I can come up with are either iterative or utilize the "Solver" function of Excel but what I really need is a formula. The attached sketch shows sample values.

Sketch

1

There are 1 best solutions below

2
On BEST ANSWER

Effort

We now can see a right-angled triangle (brown, maroon and red) with height $3$ and angle $80^{\circ}$ (brown). The hypotenuse of this triangle (part of red) is $2.8/\sin (80^{\circ}) \approx 2.843194513$ inches.

As the ratio of the major radii: minor radii is $6:1$. So before rotation and translation the ellipse has equation $y^2+\frac{x^2}{36}=\frac{1}{4}$.

The part of the major radii below the $x$-axis (yellow) has length of $3-\frac {2.8}{\sin (80^{\circ})} \approx 0.1568054867$ inches.

The base of this triangle (maroon) has length $\frac {2.8}{\cos 80^{\circ}}$.

Now for the translation. We want there to be exactly $3-\frac {2.8}{\sin (80^{\circ})}$ inches on the other side. So the new equation (totally disregarding the center) is $y^2+\frac{\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2}{36}=\frac{1}{4}$ or $36y^2+\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2=9$ (you can shift a graph $\alpha$ units to the right by replacing $x$ with $x-\alpha$). Time to make $y$ the subject.
$$36y^2=9-\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2$$
$$y^2=\frac 1{36} \left[ 9-\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2 \right]$$
$$y=\pm \frac {\sqrt {9-\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2}}6$$.

Let $y=f(x)$.
Whenever you rotate a curve $y=f(x)$ by $\theta ^{\circ}$ (measured anticlockwise), the new equation becomes:

$$y\cos \theta^{\circ} -x\sin \theta^{\circ}=f(y\sin \theta^{\circ}-x \cos \theta^{\circ})$$

Thanks Sen Zen!

Now, for $y=\pm \frac {\sqrt {9-\left(x-\frac{2.8}{\sin\ 80^{\circ}}\right)^2}}6$ is rotated $80^{\circ}$ anticlockwise, it becomes:
$$y \cos 80^{\circ} -x\sin 80^{\circ}=\pm \frac {\sqrt {9-\left(y \sin 80^{\circ} -x\cos 80^{\circ}-\frac{2.8}{\sin\ 80^{\circ}}\right)^2}}6$$.
I will not lie: this is confusing. Let us just simplify it to: $$36(y \sin 10^{\circ} - x \cos 10^{\circ})^2=9-\left(y \cos 10^{\circ}-x \sin 10^{\circ}-\frac {2.8}{\cos 10^{\circ}}\right)^2$$
I have verified that this is correct.
Now comes the simplest, albeit hardest part: translation. It may be wrong but anyway, here goes nothing: Verified!

Geogebra converted provides an approximate equation without trigonometric equations but has graphed $36(y \sin 10^{\circ} - x \cos 10^{\circ})^2=9-(y \cos 10^{\circ}-x \sin 10^{\circ}-\frac {2.8}{\cos 10^{\circ}})^2$. The major axis passes through the origin $(0, 0)$ and has gradient $\tan 80^{\circ}$.
$\therefore$ The major axis has equation $y=x\tan 80^{\circ}$ and the centre of the ellipse is $(\frac {2.8}{\sin 10^{\circ}}, 2.8)$.
The circle has equation $(x-a)^2+y^2=\frac 14$. Now here is the tricky part: when two equations intersect at one point, their gradients are equal (we don't yet know $a$). So we have two equations now:

$$(x-a)^2+y^2=\frac 14$$ $$36(y \sin 10^{\circ} - x \cos 10^{\circ})^2=9-(y \cos 10^{\circ}-x \sin 10^{\circ}-\frac {2.8}{\cos 10^{\circ}})^2$$

Now we differentiate the equations. Her is the one that I did:

$$\frac d{dx} (x-a)^2+y^2-\frac 14 = \frac {a-x}{\sqrt{2ax-x^2}}$$

Here is the one that Wolfram Alpha did:
Woah

($\frac {\pi}{18} rad=10^{\circ}$)

As the gradients are equal at the point where one is tangent to the other,

$$ \frac {1415182572 x \cos^2 10^{\circ} + 111767759 \sin 10^{\circ} - 1454493199 y \cos 10^{\circ} \sin 10^{\circ} + 39310627 x \sin^2 10^{\circ}}{(111767759 \cos 10^{\circ} - 39310627 y \cos^2 10^{\circ} + 1454493199 x \cos 10^{\circ} \sin10^{\circ} - 1415182572 y \sin^210^{\circ}}=\frac {a-x}{\sqrt{2ax-x^2}}$$

I presume it is possible to continue using a completely algebraic approach and find the possible value of $a$ relative to $x$ and $y$ and thus find an accurate value of $a$ but it was not quite possible for me to do it. I have found that $a \approx 0.73$ by trial and error but if you require a more accurate value, by all means go ahead and do it algebraically.

$a \approx 0.73$

Now that we see that we have to find the (only) point of intersection of the circle and thus by simple substitution, we find all that we require from a different perspective, a bit to the right than before.

$$\text{Equation of circle} \implies y^2+(x-0.73)^2=0.25$$ $$\text{Equation of ellipse} \implies 36(y \sin 10^{\circ} - x \cos 10^{\circ})^2=9-(y \cos 10^{\circ}-x \sin 10^{\circ}-\frac {2.8}{\cos 10^{\circ}})^2$$ $$\text {Coordinates of the point of intersection} \implies (0.28, 0.21)$$
$$\text {Equation of tangent} \implies y \approx 2.125x-0.38$$

Now if we have learned anything, that is how to shift. Now let us switch things back to the original frame of reference, by replacing $x$ with $x+a \approx x+0.73$.

$$\text{Equation of circle} \implies y^2+x^2=0.25$$ $$\text{Equation of ellipse} \implies 36(y \sin 10^{\circ} - (x+0.73) \cos 10^{\circ})^2=9-(y \cos 10^{\circ}-(x+0.73) \sin 10^{\circ}-\frac {2.8}{\cos 10^{\circ}})^2$$ $$\text {Coordinates of the point of intersection} \implies (-0.45, 0.21)$$
$$\text {Equation of tangent} \implies y \approx 2.125x+1.17125$$

As you asked for only the tangent point, (restating) it is:

$$(x, y) \approx (-0.45, 0.21)$$

My sincere apologies on not being able to include the exact answers. I may have done many unnecessary things and I am sorry if the first image is unclear (especially the brown and maroon). I have taken a very winded tour to the solution and may have made some mistakes. Thanks for taking the time to read it through and I sincerely hope it helps everyone.