Peter Haider

Das Problem des Apollonios

Das Apollonische Problem (Problem des Apollonios) ist eines der berühmtesten Probleme der antiken Geometrie. Es geht darum, die Kreise zu konstruieren, die drei beliebige vorgegebene Kreise berühren.
Im folgenden wollen wir entartete Kreise ausschließen, also Kreise mit dem Radius 0 oder unendlich. Kreise mit Radius 0 wären Punkte und mit Radius unendlich Geraden.
Es gibt verschiedene Lösungsansätze, sowohl geometrische als auch analytische. Wir wollen einen analytischen Ansatz machen. Wir legen auf die drei gegebenen Kreise drei neue Kreise, d. h. mit identischen Mittelpunkten aber anderen Radien, so dass deren Schnittpunkt der Mittelpunkt des Lösungskreises ist. In manchen Fällen haben wir auch zwei Schnittpunkte, dann wenn sich nämlich alle drei Kreise in zwei Punkten schneiden. Dann haben wir also zwei Lösungskreise.
Die Überlegung zu diesem Ansatz soll die folgende Grafik veranschaulichen:

Apolloniuskreise Lösung Außen

Der Schnittpunkt der blauen Kreise ist der Mittelpunkt des Lösungskreises.
Hier ist nur 1 von 8 Lösungskreisen abgebildet, und zwar die Lösung, in der der Lösungskreis alle 3 gegebenen Kreise von außen berührt. Der Ansatz für diese Lösung ist:

$$(I_+)\quad(x-x_1)^2+(y-y_1)^2=(r+r_1)^2$$ $$(II_+)\quad(x-x_2)^2+(y-y_2)^2=(r+r_2)^2$$ $$(III_+)\quad(x-x_3)^2+(y-y_3)^2=(r+r_3)^2$$

Möchten wir, dass der Lösungskreis die 3 gegebenen Kreise von innen berührt, müssen wir folgenden Ansatz machen:

$$(I_-)\quad(x-x_1)^2+(y-y_1)^2=(r-r_1)^2$$ $$(II_-)\quad(x-x_2)^2+(y-y_2)^2=(r-r_2)^2$$ $$(III_-)\quad(x-x_3)^2+(y-y_3)^2=(r-r_3)^2$$

Die nächste Abbildung veranschaulicht diesen Ansatz:

Apolloniuskreise Lösung Innen

Es ergeben sich also 8 verschiedene Gleichungssysteme, je nachdem, wie man das Vorzeichen der Radien der gegebenen Kreise wählt.

Beim Lösen des Gleichungssystems ergibt sich, wie wir später sehen werden, eine quadratische Gleichung für den Radius $r$. In manchen Situationen ergeben sich also 2 Lösungen für den Radius $r$ (für ein Gleichungssystem). Im Folgenden ist eine Lösung für den Fall, in dem die 2 Lösungskreise die gegebenen 3 Kreise von außen berühren, abgebildet.

Apolloniuskreise 2 Radien

Der allgemeine Ansatz lautet also:

$$(I)\quad(x-x_1)^2+(y-y_1)^2=(r \pm r_1)^2$$ $$(II)\quad(x-x_2)^2+(y-y_2)^2=(r \pm r_2)^2$$ $$(III)\quad(x-x_3)^2+(y-y_3)^2=(r \pm r_3)^2$$

$(I)$, $(II)$ und $(III)$ ausmultiplizieren ergibt:
$$(I_1) \quad x^2-2xx_1+x_1^2+y^2-2yy_1+y_1^2=r_1^2+2(\pm r_1)r+r^2$$ $$(II_2) \quad x^2-2xx_2+x_2^2+y^2-2yy_2+y_2^2=r_2^2+2(\pm r_2)r+r^2$$ $$(III_3) \quad x^2-2xx_3+x_3^2+y^2-2yy_3+y_3^2=r_3^2+2(\pm r_3)r+r^2$$ $(I_1)-(II_2)$ und $(I_1)-(III_3)$ ergibt sortiert: $$2(x_1-x_2)x+2(y_1-y_2)y+2(\pm r_1-(\pm r_2))=(x_1^2+y_1^2-r_1^2)-(x_2^2+y_2^2-r_2^2)$$ $$2(x_1-x_3)x+2(y_1-y_3)y+2(\pm r_1-(\pm r_3))=(x_1^2+y_1^2-r_1^2)-(x_3^2+y_3^2-r_3^2)$$ mit: $$a_1=2(x_1-x_2)$$ $$b_1=2(y_1-y_2)$$ $$c_1=2(\pm r_1-\pm r_2)$$ $$d_1=(x_1^2+y_1^2-r_1^2)-(x_2^2+y_2^2-r_2^2)$$ $$a_2=2(x_1-x_3)$$ $$b_2=2(y_1-y_3)$$ $$c_2=2(\pm r_1-\pm r_3)$$ $$d_2=(x_1^2+y_1^2-r_1^2)-(x_2^2+y_2^2-r_2^2)$$ erhalten wir ein LGS mit zwei Gleichungen: $$(I_a) \quad a_1x+b_1y+c_1r = d_1$$ $$(I_b) \quad a_2x+b_2y+c_2r = d_2$$

Wir lösen das LGS zuerst für $y$ (wobei $r$ als konstant betrachtet wird):
Dazu multiplizieren wir die erste Gleichung mit $a_2$ und die zweite mit $a_1$

$$\quad a_1x+b_1y+c_1r = d_1 \quad |\cdot a_2$$ $$\quad a_2x+b_2y+c_2r = d_2 \quad |\cdot a_1$$

Wir erhalten:

$$\quad a_1 a_2 x + a_2 b_1 y + a_2 c_1 r = a_2 d_1$$ $$\quad a_1 a_2 x + a_1 b_2 y + a_1 c_2 r = a_1 d_2$$

Jetzt ziehen wir die erste von der zweiten Gleichung ab und eliminieren so $x$.

$$\underbrace{(a_1 b_2 - a_2 b_1)}_{=:k}y + \underbrace{( a_1 c_2 - a_2 c_1 )}_{=:-s_2} r = \underbrace{(a_1 d_2 - a_2 d_1)}_{=:m_2}$$ $$(K_y) \quad ky-s_2 r = m_2$$ $$\leftrightarrow y=\underbrace{\frac{m_2}{k}}_{=:C}+\underbrace{\frac{s_2}{k}}_{=:D}r$$

Man verfährt analog mit $x$ und erhält:

$$\quad a_1 b_2 x + b_1 b_2 y + b_2 c_1 r = b_2 d_1$$ $$\quad a_2 b_1 x + b_1 b_2 y + b_1 c_2 r = b_1 d_2$$

Jetzt ziehen wir die zweite von der ersten Gleichung ab und eliminieren so $y$.

$$\underbrace{(a_1 b_2 - a_2 b_1)}_{=:k}x + \underbrace{( b_2 c_1 - b_1 c_2 )}_{=:-s_1} r = \underbrace{(b_2 d_1 - b_1 d_2)}_{=:m_1}$$ $$(K_x) \quad kx-s_1 r = m_1$$ $$\leftrightarrow x=\underbrace{\frac{m_1}{k}}_{=:A}+\underbrace{\frac{s_1}{k}}_{=:B}r$$

Wir fassen zusammen:

$$(I_x) \quad x=A+Br$$ $$(I_y) \quad y=C+Dr$$

mit:

$$k:=a_1b_2-a_2b_1$$ $$m_1:=b_2d_1-b_1d_2$$ $$s_1:=b_1c_2-b_2c_1$$ $$m_2:=a_1d_2-a_2d_1$$ $$s_2:=a_2c_1-a_1c_2$$

wobei ($k\neq 0$):

$$A:=\frac{m_1}{k}$$ $$B:=\frac{s_1}{k}$$ $$C:=\frac{m_2}{k}$$ $$D:=\frac{s_2}{k}$$ $$E:=A-x_1$$ $$F:=C-y_1$$

Wir setzen $x$ und $y$ in (I) ein und lösen nach $r$ auf:

$$(A+Br-x_1)^2+(C+Dr-y_1)^2=(r\pm r_1)^2$$

mit $E=A-x_1$ und $F=C-y_1$ reduziert sich die Gleichung zu:

$$(E+Br)^2+(F+Dr)^2=(r\pm r_1)^2$$

Ausmultiplizieren:

$$\leftrightarrow \quad E^2+2EBr+B^2r^2+F^2+2FDr+D^2r^2=r^2\pm 2rr_1 +r_1^2$$

Sortieren:

$$(\underbrace{B^2+D^2-1}_{\alpha})r^2+(\underbrace{2(EB+FD-(\pm r_1))}_{\beta})r+\underbrace{F^2+E^2-r_1^2}_{\gamma}=0$$

Wir fassen zusammen und erhalten eine quadratische Gleichung mit der Unbekannten $r$.

$$\alpha r^2 + \beta r + \gamma = 0$$

mit:

$$\alpha=B^2+D^2-1$$ $$\beta=2(EB+FD-(\pm r_1))$$ $$\gamma=F^2+E^2-r_1^2$$

Man löse die quadratische Gleichung und erhält je nach Situation eine oder zwei Lösungen für den Radius. Die negativen Lösungen fallen weg, da es keine negativen Radien geben kann. Den/die Radius/Radien $r_1$ oder/und $r_2$ in $(I_x)$ und $(I_y)$ eingesetzt ergibt die Koordinaten des Mittelpunktes der/des Lösungskreise/s. Wenn man alle Kombinationen durchrechnet, muss man 8× die quadratische Gleichung lösen. Es ergeben sich aber trotzdem maximal 8 und nicht 16 Lösungen, da entweder, je nach Situation, die Diskriminante 0 wird, negative Lösungen wegfallen oder identische Lösungen auftreten.

Wenn der Fall $k=0 \land (s_1\neq 0 \lor s_2\neq 0)$ eintritt, dann liegen alle Mittelpunkte der gegebenen Kreise auf einer Linie, und wir haben 2 Lösungen, die symmetrisch sind. Also einen Radius $r$ für die Lösungskreise. Folgende Rechnung muss jetzt durchgeführt werden:
Wir betrachten nochmal die Gleichungen $(K_x)$ und $(K_y)$ von oben:

$$(K_x) \quad kx-s_1 r = m_1$$ $$(K_y) \quad ky-s_2 r = m_2$$

Wir setzen $k:=0$ und lösen nach $r$ auf:

$$r=\frac{-m_1}{s_1}$$

falls $s_1 \neq 0$. Ansonsten:

$$r=\frac{-m_2}{s_2}$$

(Es muss wegen der Bedingung oben jetzt $s_2 \neq 0$ gelten – warum? Gute Denkübung).
Den gefundenen Radius $r$ in $(I)$ und $(I_a)$ eingesetzt, ergibt ein Gleichungssystem mit 2 Unbekannten und 2 Gleichungen. Hier nochmal die 2 Gleichungen von oben:

$$(I) \quad (x-x_1)^2+(y-y_1)^2=(\pm r_1+r)^2$$ $$(I_a) \quad a_1x+b_1y+c_1r = d_1$$

D. h. wir haben eine Kreisgleichung und eine Geradengleichung. Geometrisch suchen wir also die Schnittpunkte von Kreis und Gerade.
Wir lösen $(I_a)$ zuerst nach $y$ auf:

$$y=\frac{d_1 - a_1 x - c_1 r}{b_1}=\underbrace{\frac{d_1-c_1 r}{b_1}}_{:=f}-\underbrace{\frac{a_1}{b_1}}_{=:g}x$$ $$y=f+gx$$

Wir setzen jetzt $y$ in $(I)$ ein und multiplizieren aus:

$$x^2-2x_1 x + x_1^2 + (f+gx)^2 - 2(f+gx)y_1+y_1^2=r_1^2\pm 2 r_1 r + r^2$$

Sortieren und zusammenfassen:

$$\underbrace{(1+g^2)}_{=:a} x^2 + \underbrace{2(fg-y_1g-x_1)}_{=:b}x+\underbrace{f^2-2fy_1+x_1^2+y_1^2-r_1^2-(\pm 2 r_1r)-r^2}_{=:c} = 0$$

Diese Gleichung kann man mit der abc-Formel lösen. Man erhält entweder 0, 1 oder 2 Lösungen. Also keine, einen oder zwei Schnittpunkte. Die gefundenen Lösungen, also das $x$ bzw. $x_1$ und $x_2$, in die obige Gleichung $y=f+gx$ einsetzen und damit $y$ bzw. $y_1$ und $y_2$ ausrechnen.
Zur Erinnerung: Die Schnittpunkte sind die Mittelpunkte der Lösungskreise. Den Radius haben wir ja bereits vorher ausgerechnet (es gibt nur einen Radius, da wir hier den symmetrischen Fall betrachten).
Wenn $a_1=0$, dann liegen alle 3 gegebenen Kreise auf einer Vertikalen. Wenn $b_1=0$, dann auf einer Horizontalen (für $k\neq 0$). Wenn sowohl $a_1=0$ als auch $b_1=0$, dann haben mindestens 2 der gegebenen Kreise denselben Mittelpunkt. Für $a_1=0$ oder $b_1=0$ vereinfacht sich die Gleichung $(I_a)$ und man muss dementsprechend das Gleichungssystem lösen.

Zum Abschluss folgt eine Abbildung zur Komplettlösung für den Fall $C_1(0|3)$ mit $r_1=1$, $C_2(2|0)$ mit $r_2=1,5$ und $C_3(-4|-1)$ mit $r_3=1$.

Apolloniuskreise Komplettlösung

Peter Haider

The Problem of Apollonius

The Apollonian Problem (Problem of Apollonius) is one of the most celebrated problems in ancient geometry. It concerns constructing the circles that are tangent to three arbitrary given circles.
In what follows we exclude degenerate circles, i. e. circles of radius 0 or infinity. A circle of radius 0 would degenerate into a point, while a circle of infinite radius becomes a straight line.
Several solution strategies exist, both geometric and analytic. We adopt an analytic approach. On top of the three given circles we place three new circles – having the same centres but different radii – such that their common intersection point is the centre of the desired solution circle. In some cases there are two intersection points, namely when all three circles intersect in two points. Then we obtain two solution circles.
The following figure illustrates this idea:

Apollonian circles – exterior solution

The intersection point of the blue circles is the centre of the solution circle.
Only one out of the eight possible solution circles is shown here – the one in which the solution circle touches all three given circles externally. The algebraic set‑up for this configuration is:

$$(I_+)\quad(x-x_1)^2+(y-y_1)^2=(r+r_1)^2$$ $$(II_+)\quad(x-x_2)^2+(y-y_2)^2=(r+r_2)^2$$ $$(III_+)\quad(x-x_3)^2+(y-y_3)^2=(r+r_3)^2$$

If we want the solution circle to touch the three given circles internally, we have to use:

$$(I_-)\quad(x-x_1)^2+(y-y_1)^2=(r-r_1)^2$$ $$(II_-)\quad(x-x_2)^2+(y-y_2)^2=(r-r_2)^2$$ $$(III_-)\quad(x-x_3)^2+(y-y_3)^2=(r-r_3)^2$$

The next figure illustrates this configuration:

Apollonian circles – interior solution

There are thus eight different systems of equations, depending on the chosen sign for the radii of the given circles.

When solving the system we will – as we shall see later – arrive at a quadratic equation for the radius $r$. Hence, in certain situations, one obtains two solutions for $r$ (for a single system). The following figure shows such a situation, namely where two solution circles touch the three given circles from the outside.

Apollonian circles – two radii

The general algebraic set‑up therefore reads:

$$(I)\quad(x-x_1)^2+(y-y_1)^2=(r \pm r_1)^2$$ $$(II)\quad(x-x_2)^2+(y-y_2)^2=(r \pm r_2)^2$$ $$(III)\quad(x-x_3)^2+(y-y_3)^2=(r \pm r_3)^2$$

Expanding $(I), (II)$ and $(III)$ gives:
$$(I_1) \quad x^2-2xx_1+x_1^2+y^2-2yy_1+y_1^2=r_1^2+2(\pm r_1)r+r^2$$ $$(II_2) \quad x^2-2xx_2+x_2^2+y^2-2yy_2+y_2^2=r_2^2+2(\pm r_2)r+r^2$$ $$(III_3) \quad x^2-2xx_3+x_3^2+y^2-2yy_3+y_3^2=r_3^2+2(\pm r_3)r+r^2$$ Subtracting $(I_1)-(II_2)$ and $(I_1)-(III_3)$ and collecting terms yields: $$2(x_1-x_2)x+2(y_1-y_2)y+2(\pm r_1-(\pm r_2))=(x_1^2+y_1^2-r_1^2)-(x_2^2+y_2^2-r_2^2)$$ $$2(x_1-x_3)x+2(y_1-y_3)y+2(\pm r_1-(\pm r_3))=(x_1^2+y_1^2-r_1^2)-(x_3^2+y_3^2-r_3^2)$$ where we set $$a_1=2(x_1-x_2),\; b_1=2(y_1-y_2),\; c_1=2(\pm r_1-\pm r_2),\; d_1=(x_1^2+y_1^2-r_1^2)-(x_2^2+y_2^2-r_2^2)$$ $$a_2=2(x_1-x_3),\; b_2=2(y_1-y_3),\; c_2=2(\pm r_1-\pm r_3),\; d_2=(x_1^2+y_1^2-r_1^2)-(x_3^2+y_3^2-r_3^2)$$ This gives a linear system of two equations: $$(I_a) \quad a_1x+b_1y+c_1r = d_1$$ $$(I_b) \quad a_2x+b_2y+c_2r = d_2$$

We first solve this linear system for $y$ (treating $r$ as a constant).
To this end we multiply the first equation by $a_2$ and the second by $a_1$:

$$\quad a_1x+b_1y+c_1r = d_1 \quad |\times a_2$$ $$\quad a_2x+b_2y+c_2r = d_2 \quad |\times a_1$$

This yields

$$\quad a_1 a_2 x + a_2 b_1 y + a_2 c_1 r = a_2 d_1$$ $$\quad a_1 a_2 x + a_1 b_2 y + a_1 c_2 r = a_1 d_2$$

Subtracting the first equation from the second eliminates $x$:

$$\underbrace{(a_1 b_2 - a_2 b_1)}_{=:k}y + \underbrace{( a_1 c_2 - a_2 c_1 )}_{=:-s_2} r = \underbrace{(a_1 d_2 - a_2 d_1)}_{=:m_2}$$ $$(K_y) \quad ky-s_2 r = m_2$$ $$\Rightarrow y=\underbrace{\frac{m_2}{k}}_{=:C}+\underbrace{\frac{s_2}{k}}_{=:D}r$$

The same procedure for $x$ gives:

$$\underbrace{(a_1 b_2 - a_2 b_1)}_{=:k}x + \underbrace{( b_2 c_1 - b_1 c_2 )}_{=:-s_1} r = \underbrace{(b_2 d_1 - b_1 d_2)}_{=:m_1}$$ $$(K_x) \quad kx-s_1 r = m_1$$ $$\Rightarrow x=\underbrace{\frac{m_1}{k}}_{=:A}+\underbrace{\frac{s_1}{k}}_{=:B}r$$

Summarising we have

$$(I_x) \quad x=A+Br$$ $$(I_y) \quad y=C+Dr$$

with

$$k:=a_1b_2-a_2b_1,\quad m_1:=b_2d_1-b_1d_2,\quad s_1:=b_1c_2-b_2c_1$$ $$m_2:=a_1d_2-a_2d_1,\quad s_2:=a_2c_1-a_1c_2$$

(assuming $k\neq 0$):

$$A:=\frac{m_1}{k},\; B:=\frac{s_1}{k},\; C:=\frac{m_2}{k},\; D:=\frac{s_2}{k},\; E:=A-x_1,\; F:=C-y_1$$

Substituting $x$ and $y$ into (I) and solving for $r$ gives:

$$(A+Br-x_1)^2+(C+Dr-y_1)^2=(r\pm r_1)^2$$

With $E=A-x_1$ and $F=C-y_1$ this reduces to

$$(E+Br)^2+(F+Dr)^2=(r\pm r_1)^2$$

Expanding:

$$\Rightarrow E^2+2EBr+B^2r^2+F^2+2FDr+D^2r^2=r^2\pm 2rr_1+r_1^2$$

Rearranging:

$$(\underbrace{B^2+D^2-1}_{\alpha})r^2+(\underbrace{2(EB+FD-(\pm r_1))}_{\beta})r+\underbrace{F^2+E^2-r_1^2}_{\gamma}=0$$

This is a quadratic equation in the unknown $r$.

$$\alpha r^2 + \beta r + \gamma = 0$$

where

$$\alpha=B^2+D^2-1,\quad \beta=2(EB+FD-(\pm r_1)),\quad \gamma=F^2+E^2-r_1^2$$

Solving this quadratic gives, depending on the configuration, one or two admissible (non‑negative) radii. Inserting the resulting radius/radii $r_1$ and/or $r_2$ into $(I_x)$ and $(I_y)$ yields the coordinates of the centre(s) of the solution circle(s). Running through all sign combinations requires solving the quadratic eight times, but one still obtains at most eight – not sixteen – distinct solutions, because the discriminant may vanish, negative radii are discarded, or identical solutions occur.

If the case $k=0$ with $(s_1\neq 0 \lor s_2\neq 0)$ occurs, all centres of the given circles lie on a straight line and we obtain two symmetric solutions – i. e. one radius $r$ for the solution circles. The following calculation has to be performed:
Reconsider the equations $(K_x)$ and $(K_y)$:

$$(K_x) \quad kx-s_1 r = m_1$$ $$(K_y) \quad ky-s_2 r = m_2$$

Setting $k:=0$ and solving for $r$ gives

$$r=\frac{-m_1}{s_1}$$

provided $s_1 \neq 0$. Otherwise

$$r=\frac{-m_2}{s_2}$$

(and by assumption $s_2 \neq 0$ – a nice exercise to verify).
Substituting the found radius $r$ into $(I)$ and $(I_a)$ furnishes a system with two unknowns and two equations. Recall the two equations:

$$(I) \quad (x-x_1)^2+(y-y_1)^2=(\pm r_1+r)^2$$ $$(I_a) \quad a_1x+b_1y+c_1r = d_1$$

Thus we have a circle equation and a line equation; geometrically we are looking for their intersection points.
Solving $(I_a)$ for $y$ yields

$$y=\frac{d_1 - a_1 x - c_1 r}{b_1}=\underbrace{\frac{d_1-c_1 r}{b_1}}_{:=f}-\underbrace{\frac{a_1}{b_1}}_{=:g}x$$ $$y=f+gx$$

Substituting this $y$ into $(I)$ and expanding gives

$$x^2-2x_1 x + x_1^2 + (f+gx)^2 - 2(f+gx)y_1+y_1^2=r_1^2\pm 2 r_1 r + r^2$$

Collecting terms one arrives at

$$\underbrace{(1+g^2)}_{=:a} x^2 + \underbrace{2(fg-y_1g-x_1)}_{=:b}x+\underbrace{f^2-2fy_1+x_1^2+y_1^2-r_1^2-(\pm 2 r_1r)-r^2}_{=:c} = 0$$

This quadratic can be solved with the standard formula, yielding 0, 1 or 2 intersection points. Inserting the obtained $x$‑values ($x_1, x_2$) into $y=f+gx$ gives the corresponding $y$‑coordinates ($y_1, y_2$).
Remember: the intersection points are the centres of the solution circles, and the radius has already been determined beforehand (there is only one radius in this symmetric case).
If $a_1=0$ all three given circles lie on a vertical line, if $b_1=0$ on a horizontal line (for $k\neq 0$). If both $a_1=0$ and $b_1=0$, at least two of the given circles share the same centre. For $a_1=0$ or $b_1=0$ the equation $(I_a)$ simplifies accordingly and the system has to be solved with the modified expressions.

Finally, the following figure shows the complete set of solutions for the example $C_1(0|3)$ with $r_1=1$, $C_2(2|0)$ with $r_2=1.5$ and $C_3(-4|-1)$ with $r_3=1$.

Apollonian circles – complete solution