On this page
Three villages need one road network, and every kilometre costs money. You could build two roads along the triangle's sides, or put a junction inside and run a road to each village. Where should the junction go, and what does it save?
Where should the junction go to connect three towns with the shortest road?
The best junction is the Fermat point: the point whose total distance to the three corners of a triangle is as small as possible (Wolfram MathWorld).
When every angle of the triangle is less than 120°, the Fermat point is the inside point where each side subtends 120°, so the three roads leave the junction at 120° to each other (MathWorld).
Fermat posed the problem to Torricelli, whose solution was published by his pupil Viviani in 1659 (MathWorld).
Worked example: move the junction and watch the total
Let's test the MathWorld 120° rule. Put towns A and B 12 km apart on an east-west line. Town C is 9 km due north of their midpoint. The angle at C is about 67° and the angles at A and B about 56°, all under 120°.
Now move the junction and add up the three roads:
At C (just roads C to A and C to B): 10.817 + 10.817 = 21.63 km
At the midpoint of AB: 6 + 6 + 9 = 21.00 km
6 km north of the midpoint: 8.485 + 8.485 + 3 = 19.97 km
3 km north (the centroid): 6.708 + 6.708 + 6 = 19.42 km
3.46 km north: 6.928 + 6.928 + 5.536 = 19.39 km
3.46 km north and 2 km east: 8.718 + 5.292 + 5.886 = 19.90 km
The smallest total, 19.39 km, is at 3.46 km north, and there every pair of roads meets at 120°. That saves about 2.2 km over two roads.
The bottom is flat: the centroid is only about 24 metres worse, so use the 120° rule, not guesswork.
Why do the roads meet at 120°?
Class 12 calculus confirms the 120° property that MathWorld states. By symmetry the junction lies on the north-south line at height y, so the total length is L(y) = 2√(36 + y²) + (9 − y).
Set the derivative to zero: 2y/√(36 + y²) − 1 = 0. So y/√(36 + y²) = 1/2, giving y² = 12 and y = 2√3 ≈ 3.46 km. The ratio 1/2 is cos 60°: each slanting road makes 60° with the line pointing due south from the junction. So the two slanting roads are 60° + 60° = 120° apart, and each makes 180° − 60° = 120° with the road going north.
Soap films find the same answer. By Plateau's laws, soap films always meet in threes along an edge at 120° (Wikipedia: Plateau's laws). Our post on Karen Uhlenbeck and the mathematics of soap films shows where that idea leads.
What happens when one angle is 120° or more?
When one angle of the triangle is 120° or more, the Fermat point lies at that obtuse corner (Wikipedia: Fermat point). The shortest network is then the two sides that meet there (Wikipedia: Steiner tree problem).
Move C to just 2 km north of the midpoint. The angle at C is now about 143°. The calculus still asks for a junction 3.46 km north, which is beyond C. Walking north from the midpoint, the total keeps falling: 14.00 km, then 13.17 km at 1 km north, then 12.65 km at C. So the best network is roads from C to A and C to B.
The cut-off is exactly 120°: the junction wants height 6/√3 km, and C sits higher than that only when the angle at C is under 120°.
How much can a junction ever save? The Gilbert-Pollak conjecture says the Steiner ratio (town-to-town roads only versus extra junctions allowed) is at most 2/√3, about 1.155, reached by an equilateral triangle. It is still unproven (Wikipedia: Steiner tree problem). If it holds, a junction never saves more than about 13.4%.
How can you find the Fermat point yourself?
Check the angles. If one is 120° or more, that corner is the answer.
Draw an equilateral triangle outward on two of the sides.
Join each new outer corner to the opposite corner of the original triangle. The lines cross at the Fermat point (Wikipedia: Fermat point).
Check with a protractor that the roads meet at 120°.
Those outward triangles also appear in Napoleon's theorem on equilateral triangles.
A junction you can drag is easier to see than to read about, which is what the Fermi Simulation Lab is for: interactive simulations for ideas like this one. If the derivative step lost you, the Fermi Problem Library has worked problems with a step-by-step solver that explains the reasoning.



