0

IMAGE: Points between circle tangent lines

I have two circles C1 and C2. The outer tangent from C1 to C2 is the blue line that touches points A and B. The inner tangent from C1 to C2 is the red line that touches points C and D. I already have these points calculated (and their subsequent angles) using the tangent theorem. Therefore I already know the central co-ordinates of both circles and their radii.

However, I do not know how to find the straight line that cuts right between the outer and inner tangents, as approximated by the black line XY. This line (XY) must hit C2 exactly between B and D, and it must be tangent to C1.

How can I get the points X,Y and subsequently θ3? Any help would be much appreciated.

Cato
  • 11
  • Is it a silly question guys? Please let me know if I am missing something obvious.. – Cato Mar 29 '21 at 18:33
  • 1
    What exactly X is? What you mean by "exactly between"? Angle bisector? Middle of arc between the tangent touching points? Is XY goes through the middle of the bisected circle? XY is a segment - not an angle. Your question needs refinement. – Moti Mar 30 '21 at 02:12
  • Thank you for replying, I have reformulated the question and the image so hopefully it is clearer to understand now. Any ideas how to solve it? – Cato Mar 30 '21 at 07:09
  • The image shows AB, CD, XY as angles. We need three letters to describe angles – Isaac Brenig Mar 30 '21 at 07:58
  • Okay Isaac, how is that now? Each angle has a unique name – Cato Mar 30 '21 at 08:47
  • The same two lines apply to many different circles and as result this mean that you need the circles to get X and Y. – Moti Mar 31 '21 at 05:11
  • I already have the circles, I know their central positions and their radii. This is how I found the points of tangency A,B,C,D – Cato Mar 31 '21 at 10:26

1 Answers1

1

First, let's find the point $Y$ at the exact midpoint of the arc between $B$ and $D,$ where these points are known and the center and radius of circle $C_2$ also are known; say the center is $O_2 = (x_{2},y_{2})$ and the radius is $r_2.$

You may already know the directions from $O_2$ to $B$ and to $D$; if not, you can use a "direction" function defined as

$$ \operatorname{dir}(P,Q) = \operatorname{atan2}(q_x-p_x, q_y-p_y) $$

where $\operatorname{atan2}$ is the two-parameter arc tangent function (see this answer for a definition), $P$ is the point with coordinates $(p_x,p_y),$ $Q$ is the point with coordinates $(q_x,q_y),$ and $\operatorname{dir}(P,Q)$ gives the angular direction from $P$ to $Q$ measured in radians. (Note that this particular use of $\operatorname{atan2}$ uses the difference of $x$ coordinates as the first parameter rather than as the second parameter, which is opposite from the usual usage; this is so that it will produce angles that are measured clockwise from the $y$ axis, like the angles in the figure in the question, rather than counterclockwise from the $x$ axis as is the usual practice in mathematics. For the rest of this answer I will stick with this convention: positive angles are clockwise angles.)

Now let $\beta = \operatorname{dir}(O_2,B)$ and $\delta = \operatorname{dir}(O_2,D)$. Let $\operatorname{arc}(\theta)$ be defined by $$ \operatorname{arc}(\theta) = \theta + 2n\pi \quad \text{such that $n$ is an integer and $-\pi < \theta + 2n\pi \leq \pi$.} $$ In other words, if $-\pi < \theta \leq \pi$ then $\operatorname{arc}(\theta) = \theta$; otherwise we add or subtract $2\pi$ (repeatedly, if necessary) until the result is greater than $-\pi$ and less than or equal to $\pi,$ and this result is $\operatorname{arc}(\theta).$ (The function $\operatorname{arc}(\theta)$ is the same as the function $f(\theta)$ in this answer.)

Then $\operatorname{arc}(\delta - \beta)$ is the angle of the shorter arc from $B$ to $D$ (positive if that arc goes clockwise from $B$ to $D$, negative if it goes counterclockwise as shown in the figure in the question). Let $$ \phi = \beta + \frac12 \operatorname{arc}(\delta - \beta). $$ Then $\phi$ is exactly halfway between $\beta$ and $\delta$ in the direction of the shorter arc and we can write the coordinates of $Y$ as $$ Y = (y_x,y_y) = (x_2 + r_2 \sin\phi, y_2 + r_2 \cos\phi). $$

So we have found $Y$; next let's find $X$. Let $O_1 = (x_1,y_1)$ be the known center of circle $C_1.$ We know that $\triangle YXO_1$ is a right triangle with right angle at $X,$ so let $\alpha = \angle XYO_1 = \arcsin(XO_1/YO_1)$ where $XO_1 = r_1$ (the known radius of circle $C_1$) and $YO_1 = d_Y$ is the distance from the known point $Y$ to the known point $O_1.$ Let $\psi = \operatorname{dir}(Y,O_1)$; then the direction from $Y$ to $X$ is $$ \eta = \psi \pm \alpha $$ and the distance from $Y$ to $X$ is $d_Y \cos\alpha.$ Then $$ X = (y_x + d_Y \cos\alpha \sin\eta, y_y + d_Y \cos\alpha \cos\eta). $$

That gives you two possible locations for $X$, depending on whether you take the $+$ or $-$ sign in $\psi \pm \alpha$; choose the location that is on the shorter arc between $A$ and $C.$

The direction from $X$ to $Y$ is then $\theta_3 = \eta + \pi,$ that is, exactly $180$ degrees opposite the direction from $Y$ to $X.$


Old answer based on a less specific statement of the problem:

There are several ways to get a line "between" the inner and outer tangents (lines $AB$ and $CD$). Here are a few:

There are two lines that are angle bisectors of $AB$ and $CD.$ Each of these lines passes through the intersection of $AB$ and $CD$ (let's call this point $X_1$) and makes equal angles with $AB$ and $CD$. One of the angle bisectors passes through the center of circle $C_1$, so it presumably is not the line you want. The other angle bisector passes through the center of circle $C_2$ and intersects $C_2$ at two other points, one at the midpoint of the longer arc between $B$ and $D$ and one at the midpoint of the shorter arc between $B$ and $D$. That is, this second angle bisector is the line $X_1Y_1$ where $Y_1$ is midway between $B$ and $D$. However, the line $X_1Y_1$ does not touch circle $C_1.$

If $X_2$ is the midpoint of the shorter arc between $A$ and $C$ -- at or near the point you have labeled $X$ in your figure -- then the tangent to circle $C_1$ through $X_2$ is parallel to the line $X_1Y_1$ and therefore makes equal angles with the lines $AB$ and $CD$. Suppose this line first intersects circle $C_2$ at $Y_2.$ Since $X_2Y_2$ is parallel to $X_1Y_1$ and not equal to $X_1Y_1$ (one line is tangent to $C_1,$ the other is not), $Y_2$ is a different point than $Y_1$. Therefore $Y_2$ is not halfway between $B$ and $D$.

You could construct the line $X_2Y_1,$ which is a line from the point halfway between $A$ and $C$ to the point halfway between $B$ and $D$, but this line does not make equal angles with the lines $AB$ and $CD$ (only lines parallel to or perpendicular to $X_1Y_1$ and $X_2Y_2$ can do that) and it is not tangent to circle $C_1$ (of all lines through $X_2,$ only $X_2Y_2$ is tangent to $C_1$).

You could construct a line through $Y_1$ tangent to $C_1$ at a point $X_3$ between $A$ and $C$, but then $X_3$ will not be exactly midway between $A$ and $C$ and the line $X_3Y_1$ will not make equal angles with the lines $AB$ and $CD$.

If all you know is the lines $AB$ and $CD$ but you do not know where the centers of circles $C_1$ and $C_2$ are nor which points $A,B,C,D$ were the points of tangency, you cannot find any of the points $X_2, X_3, Y_1, Y_2,$ because there are infinitely many choices of circles that could have produced these same two lines as inner and outer tangents in the same way. So if the question is literally whether you can "get these points [...] simply by knowing the inner and outer tangents" then the answer is "no."

But you can construct the angle bisectors of the lines $AB$ and $CD$, so if $\theta_3$ is the angle of the line $X_1Y_1$ or $X_2Y_2$ you can find $\theta_3$ without identifying any of the points we have named.

If you know the points of tangency, $A,B,C,D,$ then you can reconstruct the centers of the circles $C_1$ and $C_2$ and thereby find $X_2$. The line $X_2Y_2$ has slope equal to the line $AC$ or one of the angle bisectors of $AB$ and $CD$, choose whichever method you like.

David K
  • 108,155
  • Thank you David, I already know the central positions of both circles and their radii. This is how I found the points of tangency A,B,C,D using the tangent theorem. Is there a simple way to get the vector XY (or points X,Y), e.g. using trigonometric functions? I'm afraid your talk of bisectors left me a little lost and I don't know how I would recreate that in code. – Cato Mar 31 '21 at 10:29
  • Most of this answer (so far) is exploring the ambiguities in what information is available and in what it means to "cut right between" the two tangents rather than delving into the details of how to compute things. The edited question seems to be asking for the points $Y_1$ and $X_3.$ Is that correct? – David K Apr 02 '21 at 03:17