Geometry

Three circles that touch and are not the largest

In 1803 Gian Francesco Malfatti asked how to cut three round columns from a triangular block of marble with as little waste as possible, and answered with three circles each touching the other two and two sides. The circles exist in every triangle and are found by solving three equations. They are never the answer to his question: the plain greedy rule — the inscribed circle first, then the largest circle that still fits, twice — always does better, by 1.4 per cent on the equilateral triangle and by almost double on a thin one.

Worth reading first: A triangle that fits once fits everywhere · A centre is three weights.

The circles attached to a triangle in the essays before this one were defined by what they touch. The incircle touches the three sides; the nine-point circle touches the incircle and the three excircles; the pair of circles that holds a triangle between them holds a whole family of triangles once it holds one. In every case the definition was a tangency, and the theorem was that the tangency had consequences nobody asked for.

This essay is about a triangle’s circles defined by a tangency for a purpose, and about the purpose failing. In 1803 the Italian mathematician Gian Francesco Malfatti posed a practical problem: from a prism of marble whose cross-section is a triangle, cut three cylindrical columns, parallel to its length, so that as little marble as possible is wasted. In the cross-section that asks for three circles inside a triangle, not overlapping, with the largest possible total area. Malfatti assumed the answer was the arrangement in which each circle touches the other two and two sides of the triangle, and spent his paper on constructing it.

The assumption looks inevitable. Three circles packed as tightly as they can be, every one touching everything near it, no slack anywhere — what else could the best arrangement be? The figure shows what else.

Malfatti's three circles against the three largest, one at a time. A triangle with angles 40, 70, 70 degrees: Malfatti's circles cover 69.1% of it, the greedy choice of incircle then largest remaining circles covers 73.7%.
Fig. 1 A triangle with angles 40°, 70° and 70°. On the left, Malfatti’s three circles, each touching the other two and two sides, cover 69.1% of the triangle. On the right, the inscribed circle, then the largest circle that still fits, then the largest again, cover 73.7%.

The greedy circles win by being unequal

On the right is the arrangement that comes from not thinking at all. Take the largest circle that fits in the triangle — the incircle. Then take the largest circle that fits in what is left, which is a small circle tucked into one corner, touching the incircle and the two sides that meet there. Then take the largest circle that fits in what is left after that. Each choice is the best available at the moment it is made, and no choice looks ahead.

The greedy circles cover 73.7% of the triangle; Malfatti’s cover 69.1%. The greedy arrangement holds 6.6% more marble, and it does it by being lopsided. Malfatti’s three circles are of comparable size, so each one is small compared with the incircle. Area grows as the square of the radius, and the square punishes evenness: one large circle and two small ones beat three medium ones whenever the large one is large enough. The incircle is as large as a single circle in the triangle can be, and Malfatti’s arrangement gives it up entirely in exchange for three circles that fit together neatly.

The mistake is a familiar one from optimisation. Malfatti’s circles are locally rigid — no circle in the arrangement can grow without another shrinking, because each is pinned by three tangencies — and rigidity feels like optimality. But a configuration that cannot be improved by small moves can still be beaten by a completely different configuration, and here it always is. The greedy rule, which in the order a graph’s vertices are coloured can be made to fail as badly as one likes, is in this problem exactly right.

Three equations for three radii

Malfatti’s arrangement is still worth having, because it exists in every triangle and is exactly determined, and finding it is a neat piece of geometry.

Where Malfatti's equations come from: one side cut into three. The bottom side of a triangle with angles 40, 70 and 70 degrees, cut by two Malfatti circles into a tangent length 0.4838, a gap between touching points 0.3150, and a tangent length 0.2012.
Fig. 2 Along the bottom side, the tangent length from the left corner to the first circle, the distance between the points where the two circles touch the side, and the tangent length from the right corner to the second circle add up to the side’s length.

A circle of radius r1r_1 that touches both sides of a corner with angle AA has its centre on the corner’s angle bisector, and touches each side at distance r1cot⁡(A/2)r_1 \cot(A/2) from the corner — the tangent length. Two circles of radii r1r_1 and r2r_2 that touch each other and the same straight line touch the line at points 2r1r22\sqrt{r_1 r_2} apart: the centres are r1+r2r_1 + r_2 apart, their heights above the line differ by r1−r2r_1 - r_2, and the Pythagorean theorem gives the horizontal separation as the square root of (r1+r2)2−(r1−r2)2=4r1r2(r_1 + r_2)^2 - (r_1 - r_2)^2 = 4 r_1 r_2.

Along the bottom side of the drawn triangle, then, three pieces add up to the side: r1cot⁡(A/2)+2r1r2+r2cot⁡(B/2)=cr_1 \cot(A/2) + 2\sqrt{r_1 r_2} + r_2 \cot(B/2) = c. Here the pieces are 0.4838, 0.3150 and 0.2012, adding to the side’s length 1. Each side gives one such equation, and the three equations in the three unknown radii have exactly one solution with all radii positive. The figures solve them by Newton’s method, starting from three small equal radii, and check every pair of circles for tangency afterwards to nine decimal places.

The equations can be solved in closed form. The formula, found by Malfatti and simplified by later writers, expresses each radius through the inradius, the semiperimeter and the distances from the incentre to the corners; and the construction with ruler and compass was given by Jakob Steiner in 1826, without proof, and proved later by others. The Japanese mathematician Ajima Naonobu had solved the same construction problem before Malfatti, which is why the arrangement is often named after both. The construction is a cousin of Apollonius’s problem, which asks for the circles touching three given ones and finds eight; Malfatti’s asks for three circles touching each other and the sides, and finds exactly one arrangement. None of that work asked whether the circles were the best three, because everyone took that for granted.

The equilateral triangle, where the gap is smallest

Malfatti's three circles against the three largest, one at a time. A triangle with angles 60, 60, 60 degrees: Malfatti's circles cover 72.9% of it, the greedy choice of incircle then largest remaining circles covers 73.9%.
Fig. 3 The equilateral triangle. Malfatti’s three equal circles cover 72.9%. The incircle with two corner circles, each a third of its radius, covers 73.9%.

For more than a century nobody checked. In 1930 H. Lob and H. W. Richmond pointed out that already for the equilateral triangle Malfatti’s arrangement loses. Its three equal circles have radius (3−1)/4(\sqrt3 - 1)/4 of the side and cover 72.9% of the triangle. The incircle alone covers π/(33)\pi/(3\sqrt3), about 60.5%, and the largest circle in each corner pocket, touching the incircle and the two sides, has exactly a third of its radius, so two of them add two ninths of the incircle’s area. The total is 73.9%.

The margin is 1.36%, and the equilateral triangle is where the margin is smallest. That is the content of the next figure: if Malfatti’s guess were going to be right anywhere, it would be right at the most symmetric triangle, and it is wrong there by a little over one per cent.

The third circle in the equilateral triangle goes into a second corner, not deeper into the first. Every corner has the same angle, so the second circle had three equally good places to go and the third has two. The two greedy circles in different corners each have a third of the incircle’s radius; a third circle squeezed beyond the second, deeper into the same corner, would have only a ninth.

A ratio that never reaches one

How much the greedy circles gain, across isosceles triangles. Ratio of greedy to Malfatti area against apex angle 4 to 176 degrees, minimum 1.0136 at 60 degrees; over every whole-degree triangle, between 1.0136 and 1.947.
Fig. 4 The greedy circles’ total area divided by Malfatti’s, for isosceles triangles with apex angle from 4° to 176°. The ratio is smallest at the equilateral triangle, 1.0136, and rises steeply on either side.

Taking isosceles triangles with every apex angle from 4° to 176°, the ratio of greedy area to Malfatti area is never below 1. Its minimum is at 60°, the equilateral triangle, and on either side it rises — slowly for wide triangles, steeply for sharp ones, reaching 1.8 at an apex of 4°. The curve has a visible corner near an apex angle of 37.5°. That is where the greedy packing changes its mind about the third circle: for sharper apexes the third circle goes deeper into the apex, beyond the second, and for blunter ones into one of the base corners. Each option’s area is a smooth function of the angle, and the larger of the two has a corner where they cross.

Over every triangle whose angles are whole numbers of degrees — 15,931 shapes — the ratio stays above 1 everywhere, with its least value 1.0136 at the equilateral triangle and its greatest 1.947, at the triangle with angles 1°, 89° and 90°. No triangle on the grid comes close to letting Malfatti’s arrangement win. That is not a proof, since a grid of shapes cannot exclude a counterexample between its points, but the margin it shows is large and smooth: the gap between the two arrangements is at least 1.36% everywhere, and nothing about the curve suggests a shape where it dips towards zero.

The proof came in stages. In 1967 Michael Goldberg showed that Malfatti’s arrangement is never optimal — for every triangle, some rearrangement beats it. Which arrangement is optimal was settled by V. A. Zalgaller and G. A. Los’ in 1994, who showed by a long case analysis that the greedy one is, and the argument was completed and checked by Marco Andreatta, András Bezdek and Jan Boroński in 2011. Two hundred and eight years separate the question and the full answer, and the answer is the arrangement a child would draw.

Thin triangles, where the greedy circles stack

Malfatti's three circles against the three largest, one at a time. A triangle with angles 15, 82.5, 82.5 degrees: Malfatti's circles cover 43.2% of it, the greedy choice of incircle then largest remaining circles covers 61.8%.
Fig. 5 A thin triangle with angles 15°, 82.5° and 82.5°. Above, Malfatti’s circles cover 43.2%. Below, the greedy circles cover 61.8%: after the incircle, the next two both go into the sharp corner, one behind the other.

The thin triangle shows how badly the tangency condition can mislead. Malfatti’s circles must each touch two sides, so one sits in each corner. The two blunt corners at the wide end are crowded together, and the circles there are small; the circle in the sharp corner is large, but it is pinned against the two small ones and cannot use the long tapering wedge in front of it. Together they cover 43.2% of the triangle.

The greedy circles do something Malfatti’s cannot. After the incircle, the largest remaining space is the long wedge towards the sharp corner, and the second circle goes there. After that, the largest remaining space is still the same wedge, now in front of the second circle, and the third circle goes there too. The three circles form a chain shrinking towards the point, each touching the next and both long sides, and they cover 61.8%: 43% more than Malfatti’s. Each circle in the chain has the same fixed fraction of the radius of the one behind it, the fraction depending only on the sharp angle. At 15° that fraction is close to 0.77, so the circles shrink slowly and the chain fills the wedge well.

That is the general shape of the failure. Malfatti’s arrangement uses each corner once. The best arrangement uses the corner with the most room as often as it pays to, and in a thin triangle that is every time.

Where the third circle goes

Where the greedy packing puts its third circle, for every shape. 690 triangle shapes by smallest and middle angle: 413 put the greedy third circle deeper into the sharpest corner, 277 in a second corner; greatest gain over Malfatti 1.95 times.
Fig. 6 Every triangle shape by its smallest angle α (across) and middle angle β (up), coloured by where the greedy packing puts its third circle: deeper into the sharpest corner (orange), or in a second corner (blue). Darker means a larger gain over Malfatti’s circles. The black curve is where the two choices give equal circles.

The greedy rule has to make one real decision, and the figure maps it. After the incircle, the second circle always goes into the sharpest corner: the pocket between the incircle and a corner with angle θ\theta holds a circle whose radius is the inradius times

k(θ)=1−sin⁡(θ/2)1+sin⁡(θ/2),k(\theta) = \frac{1 - \sin(\theta/2)}{1 + \sin(\theta/2)},

and kk is larger the sharper the corner. For the third circle there are two candidates: the pocket in the second-sharpest corner, with radius the inradius times k(β)k(\beta), or the pocket beyond the second circle in the sharpest corner, with radius the inradius times k(α)k(\alpha) twice over, k(α)2k(\alpha)^2. The third circle goes deeper exactly when k(α)2>k(β)k(\alpha)^2 > k(\beta), and the curve where these are equal splits the shape triangle in two.

Above the curve, where the two smaller angles are very different, the sharpest corner is so much roomier than the next that it is worth using twice. Below it, where the two smaller angles are similar — including every triangle with two equal small angles and the equilateral triangle at the far corner — the third circle goes into a second corner. Of the 690 shapes in the figure, 413 send the third circle deeper. A third candidate, the little pocket between the incircle, the second circle and one side, never holds the largest circle for any shape, and the figure checks that too.

The shading shows where Malfatti loses most: at the top left, among triangles with one very sharp corner, where the greedy chain fills a long wedge that Malfatti’s arrangement leaves almost empty. Near the equilateral corner of the map the shading is faintest. The map is the essay’s argument in one picture: Malfatti’s arrangement is never best, and the reason it loses is always one of two specific choices it is forbidden to make.

The circles still mark a centre

Three lines through Malfatti's touching points, meeting at one point. A triangle with angles 40, 70 and 70 degrees, its Malfatti circles, and the three lines from each corner to the opposite touching point, concurrent to within 5.4e-15 on 595 shapes.
Fig. 7 Malfatti’s circles touch one another at three points. The line from each corner to the point where the two circles away from it touch is drawn, and the three lines meet at one point.

Having failed at the job they were proposed for, Malfatti’s circles turn out to have the property this sequence of essays has been collecting. They touch each other at three points. Draw the line from each corner of the triangle to the touching point of the two circles that do not sit in that corner. The three lines meet at a single point, the first Ajima–Malfatti point, which appears in the catalogue of triangle centres alongside the centroid and the incentre. On 595 triangle shapes, with angles in steps of 5°, the three lines miss a common point by at most a few parts in 101510^{15}, which is rounding.

Like the other centres in the catalogue, this one can be written as three weights on the corners, and its weights are strange ones: the side length times the fourth power of the secant of a quarter of the opposite angle, asec⁡4(A/4)a \sec^4(A/4) and its two companions. The incentre in one circle touching four has weights aa, bb, cc; Malfatti’s radii are built from half-angles and square roots of products of radii, and the square roots halve the angles again. The figure checks the formula against the drawn meeting point to nine decimal places. It is a centre of the triangle with no extremal meaning at all, produced by circles whose extremal meaning was a mistake.

The concurrence has the same shape as the theorems earlier in the sequence. Nine points on one circle and the partners across the bisectors were coincidences of construction that held for every triangle. This one is a coincidence of three tangencies: three lines that have no reason to meet, built from circles that have no reason to be anything special, meeting all the same. The construction gives a centre. It does not give the best three columns of marble.

A guess that was wrong for one hundred and twenty-seven years

The striking thing about Malfatti’s problem is not that the guess was wrong but how long it stood. The equilateral counterexample requires nothing beyond the area of the incircle and of one corner circle — a computation a student could do in a few lines — and it went unnoticed from 1803 to 1930. The arrangement had been studied intensively in that time: its construction, its radii, its generalisations to other shapes and to spheres. Everyone who studied it took the extremal claim from the problem’s name and never computed the alternative.

The lesson is the usual one about small cases, turned around: here the smallest case, the equilateral triangle, would have told the truth immediately, and nobody looked at it. A claim that some arrangement is the best is a claim about every alternative, and it can only be tested by producing alternatives. The greedy arrangement is the first alternative anyone would produce. That is what makes the history instructive rather than merely unlucky.

The same mistake has a modern form in numerical optimisation. A configuration found by tightening — every constraint active, every object touching its neighbours — is a local optimum by construction, and solvers will happily report it. Newton’s method, which finds Malfatti’s circles in a handful of steps, will find them every time from almost any start, because they are a solution of the equations it is given. Whether those are the right equations is a question no solver asks.

What the figures do and do not establish

The figures compute both arrangements exactly for each triangle shown and compare them on a grid of 15,931 shapes. They establish the comparison on that grid, and the map establishes where the greedy rule’s one decision goes for each shape. They do not prove that the greedy arrangement is the best possible: the figures compare greedy against Malfatti, not against all arrangements of three circles. That the greedy one is optimal is the theorem of Zalgaller and Los’, and of Andreatta, Bezdek and Boroński, and the figures only illustrate it.

The concurrence of the three lines through Malfatti’s touching points is checked numerically on 595 shapes. It is a known theorem, proved from the closed-form radii, and the figure is evidence of the theorem, not a proof of it.

Still open: more than three circles

For three circles in a triangle, the greedy arrangement is the best, and that is proved. For four or more it is conjectured and not proved. The natural generalisation of Malfatti’s problem asks for nn non-overlapping circles in a triangle with the largest total area, and the greedy rule — the largest circle that fits, then the largest that fits in what is left, and so on — produces an arrangement for every nn. Zalgaller and Los’ conjectured that it is optimal for every nn, and the conjecture is open: the case analysis that settled three circles grows quickly with the number of circles, and no structural argument is known that would replace it.

Nothing in general guarantees that greedy packing is optimal — a rule that never looks ahead has no reason to be right — and a proof for triangles would have to explain what it is about the shape that protects the rule. That the rule works for every triangle and three circles, after two centuries in which the most obvious arrangement turned out to be wrong for every triangle, is itself the reason the larger question is taken seriously.

What links here

Computed from the collection, not written here: the essays that point at this one.

Shares its objects with

Essays that name at least two of the same things, and that neither author linked.

Named objects

A dashed tag is an object no other essay names yet.

Angle bisectorCounterexampleGreedy algorithmIncircleNewtons methodOptimisationTangency