Tangent II

I had a thought about another way to approach that ellipse and circles problem and thought I’d try it on a generalization. Suppose the circle is of arbitrary radius and sitting at an arbitrary point? (You can turn it into a unit radius just by rescaling, but let’s put the radius in explicitly. If nothing else it helps check for errors via dimensional analysis.)

This time instead of working with x and y let’s use the parametric equations

x=a\cos t

y=b\sin t

And now let’s write down the distance D between a point on the ellipse and the center (xc, yc) of the circle:

D(t) = \sqrt{(x-x_c)^2+(y-y_c)^2}=\sqrt{(a\cos t-x_c)^2+(b\sin t-y_c)^2}

The idea here is that if D(t) has a local extremum at t=tt and if D(tt)=r (the radius of the circle) then tt  corresponds to a tangent point. So the plan is to solve dD/dt=0 to get values of tt, and then solve D(tt)=r to get the relation between a and b required for tangency.

Well, easier said than done. The requirement dD/dt=0 leads to

(b^2-a^2)\sin t\cos t-by_c\cos t+ax_c\sin t=0

which I think can be solved in the sense that it can be converted to a cubic in cos t. Ah, no thanks.

So how about a milder generalization? Keep the arbitrary radius and the arbitrary xbut require the circle to sit on the x axis: yc=0. In that case

(b^2-a^2)\sin t\cos t+ax_c\sin t=0

with solutions

\sin t=0 (case [i]) or

\cos t=\frac{ax_c}{a^2-b^2} (case [ii])

(If sin t ≠0 and a2=b2, then the case [ii] formula doesn’t work. But if so, the ellipse is a circle, and dD/dt≠0 unless x= 0: both circles are concentric and every point on the “ellipse” is equidistant from the center of the other circle, and to make that distance be r you have to make the two circles be identical, which isn’t really what I mean by a tangent ellipse. So I’ll only consider a2≠b2.)

For case [i], plug sin t=0 and cos t=±1 into the formula for D and set it equal to r, and the legal (positive) values for a are |xc+r| and |xc–r|. Obviously if a has either of these values then the left or the right end of the ellipse will be tangent to the circle. To find out if it’s exterior or interior requires checking whether the extremum is a minimum or a maximum, for which you need the sign of the second derivative. I haven’t gone there yet. It looks messy.

Case [ii] starts messy and gets messier, until a whole lot of cancellation happens and you’re left with a simple answer. The equation to be solved is


which turns into


and when you solve for ausing the quadratic formula, amazingly everything under the radical sign except b4xccancels and the result is

a^2=b^2\frac{x_c^2\pm x_c^2+2(b^2-r^2)}{2(b^2-r^2)}

The minus sign just gives you a2=b2, which we saw above isn’t allowed for this case so we discard that, and the plus sign gives


which, if you set xc=r=1, reproduces the result I got previously. Note that this means if b2–ris negative then |xc| must be less than |b2–r2| to make a2 positive. This just says the y intercept of the circle, which is √(r2xc2), must be greater than b for the ellipse to fit inside the circle. That is, if the ellipse is shorter (vertically) than the circle, then the circle must be close to centered on the origin in order to get two point tangency:

elconstHere r is 5, b is 4, so |xc| must be less than 3 (and it’s about 2.9). Of course in the limit as the ellipse becomes infinitesimally narrow, xc approaches 3 with the tangent point going to (0, 4) and xc, the origin, and the tangent point approaching a right triangle.

Once again, for case [ii] generally, one has to test whether the extremum is a minimum or a maximum to determine if the tangent is interior or exterior. I wonder how horrible that is. I don’t want to find out right now.



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s