Number

Every triple, on one circle

Draw a line of rational slope through a single point of a circle. Wherever it comes out is a rational point, and clearing the denominators turns it into a Pythagorean triple — so every triple there is comes from one line through one point.

Worth reading first: Two squares, four triangles, and no algebra · A sphere is a plane plus one point.

Three, four, five. Five, twelve, thirteen. Eight, fifteen, seventeen. Twenty, twenty-one, twenty-nine. The list of whole-number right triangles goes on forever and has no obvious pattern, and it can be produced in its entirety by a single geometric construction.

Rational points on the unit circleLines of rational slope through the left-hand point of a circle, each meeting it again at a rational point.(−1, 0)3/4 → 7, 24, 252/3 → 5, 12, 131/2 → 3, 4, 52/5 → 21, 20, 291/3 → 8, 6, 101/4 → 15, 8, 17each line of rational slope meets the circle a second time at a rational pointclearing the denominators turns that point into a Pythagorean triple, and every triple arises this way
Fig. 1 Lines of rational slope through the left-hand point of the unit circle. Each one meets the circle a second time at a point with rational coordinates, and clearing denominators turns that point into a whole-number right triangle. The generator computes each triple from its slope and checks that it satisfies the theorem.

Dividing a2+b2=c2a^2 + b^2 = c^2 by c2c^2 gives (a/c)2+(b/c)2=1(a/c)^2 + (b/c)^2 = 1, so every triple is a point with rational coordinates on the unit circle, and conversely every rational point on the circle scales up to a triple. The two questions are the same question.

The Pythagorean theorem by dissectionTwo squares of the same size. Each holds four copies of one right triangle. The space left over is a single tilted square on the left and two upright squares on the right.same four trianglessame four triangles
Fig. 2 The theorem the triples satisfy, in the form this collection met it first: two squares and four triangles, rearranged. That argument works for every right triangle, whatever its sides. This essay asks the much narrower question of which right triangles have whole-number sides, and the answer turns out to be completely known.

The move from the first question to the second is worth naming, because it is the whole method. A search over triples of whole numbers is a search over an infinite three-dimensional set with a constraint. Dividing by cc turns it into a search over a curve, and a curve is one-dimensional; then the projection below turns the curve into a line, and a search over a line of rational numbers is no search at all, because the rational numbers can simply be listed. Two reductions and the problem stops being a problem.

Why a rational line hits a rational point

Fix the point (1,0)(-1, 0), which is on the circle, and take the line through it with slope t=m/kt = m/k.

Substituting y=t(x+1)y = t(x+1) into x2+y2=1x^2 + y^2 = 1 gives a quadratic in xx with rational coefficients, and one of its roots is already known: x=1x = -1, the point the line was drawn through. A quadratic with rational coefficients and one rational root has a rational other root, because the two roots sum to a rational number.

That is the whole argument, and it is worth pausing on because it explains why the trick works for conics and stops working immediately afterwards. A line meets a conic in two points; knowing one of them rational forces the other. A line meets a cubic in three points, and knowing one rational root of a cubic tells nothing about the other two — which is why the same method fails for x3+y3=1x^3 + y^3 = 1, and why Fermat’s last theorem is not settled in a paragraph.

Carrying the algebra out gives

x=k2m2k2+m2,y=2mkk2+m2,x = \frac{k^2 - m^2}{k^2 + m^2}, \qquad y = \frac{2mk}{k^2 + m^2},

and clearing denominators produces the triple (k2m2, 2mk, k2+m2)(k^2 - m^2,\ 2mk,\ k^2 + m^2) — Euclid’s parametrisation, which appears in Book X of the Elements with no circle in sight.

Every triple, exactly once

The construction produces triples. That it produces all of them, and each primitive one exactly once, needs the correspondence to run both ways.

Given a triple, divide by cc to land on the circle, draw the line from (1,0)(-1,0) to that point, and read off the slope. The slope is rational because both coordinates are, so every rational point comes from some tt — and different points give different slopes, because a line through (1,0)(-1, 0) meets the circle only once more.

Rational points on the unit circleLines of rational slope through the left-hand point of a circle, each meeting it again at a rational point.(−1, 0)4/5 → 9, 40, 411/2 → 3, 4, 52/5 → 21, 20, 293/8 → 55, 48, 732/7 → 45, 28, 531/5 → 24, 10, 26each line of rational slope meets the circle a second time at a rational pointclearing the denominators turns that point into a Pythagorean triple, and every triple arises this way
Fig. 3 A different set of slopes, giving 3,4,53,4,5 then 21,20,2921,20,29 then 55,48,7355,48,73 and three more. Every rational slope between zero and one gives a distinct triple, and every primitive triple arises from exactly one slope in lowest terms with kk and mm of opposite parity.

So the rational points on the circle are in bijection with the rational numbers, and the triples are the rational numbers in different clothing. That is a complete answer to a question that looks as though it should have a list rather than a formula.

The primitivity condition needs a word. The formula with k=3k = 3, m=1m = 1 gives (8,6,10)(8, 6, 10), which is (4,3,5)(4, 3, 5) doubled. Requiring gcd(k,m)=1\gcd(k, m) = 1 and kk, mm of opposite parity gives exactly the primitive triples, each once. When both are odd the formula produces twice a primitive triple, which is why the parity condition is there and not an aesthetic preference.

The same projection, twice

The construction — project from a point of a circle onto a line, and pull rational points back — is stereographic projection in one dimension lower.

Stereographic projection, one dimension downA circle resting on a line: rays from the top of the circle match its points with points of the line, and only the top has no partner.-2-1-0.500.512the missing pointwithout end……and the line runs on forever
Fig. 4 The projection this essay uses, in the form it is usually met: a circle projected from one of its own points onto a line. Every point of the circle except the one projected from lands somewhere on the line, and every point of the line comes from exactly one point of the circle.

That is not an analogy, it is the same map. The circle minus the point (1,0)(-1, 0) corresponds bijectively with the line of slopes, exactly as the sphere minus its north pole corresponds with the plane; and the missing point is the slope “infinity”, the vertical line, which meets the circle only at (1,0)(-1, 0) itself.

Recognising it as a projection says what generalises. The same argument parametrises the rational points on any conic that has one rational point to project from — and the caveat is not decorative. The circle x2+y2=3x^2 + y^2 = 3 has no rational points at all, so there is nothing to project from and the method never starts. Whether a conic has a rational point is itself a substantial question, answered by the Hasse–Minkowski theorem: it has one exactly when it has one modulo every prime and over the reals, which reduces an infinite search to finitely many congruence checks.

Reading the triples off the lattice

The circle is one way in. The lattice is another, and the two describe the same objects differently.

The circle of radius √25 on the integer latticeA circle drawn on the whole-number grid, with the lattice points it passes through marked.12 lattice points sit on the circle — and 4 × (3 − 0) = 12divisors of 25: 1, 5, 25 are 1 mod 4, none are 3 mod 4
Fig. 5 The circle of radius 55 on the integer lattice, passing through (3,4)(3, 4) and its seven reflections. A Pythagorean triple with hypotenuse cc is a lattice point on the circle of radius cc, so counting lattice points on circles counts triples too.

Jacobi’s formula counts the lattice points on the circle of radius n\sqrt{n}, and applying it at n=c2n = c^2 counts the triples with hypotenuse cc. A hypotenuse admits a primitive triple exactly when it has a prime factor 1(mod4)\equiv 1 \pmod 4, and admits several when it has several — 65=5×1365 = 5 \times 13 is the hypotenuse of two primitive triples, (63,16,65)(63, 16, 65) and (33,56,65)(33, 56, 65), one for each factor.

So the two-squares theory and the triples theory are the same theory. That 55, 1313, 1717 and 2929 are the hypotenuses that appear early is the same fact as their being the primes that are sums of two squares, and the primes 3(mod4)\equiv 3 \pmod 4 never appear as a primitive hypotenuse at all.

The bridge between the two is the Gaussian integers, where a triple is a squaring. If k+mik + mi is a Gaussian integer, then (k+mi)2=(k2m2)+2mki(k + mi)^2 = (k^2 - m^2) + 2mki, whose real and imaginary parts are the two legs, and whose norm is (k2+m2)2(k^2 + m^2)^2 — the hypotenuse squared. So generating a triple is squaring a complex number with whole-number parts, and the parametrisation that this essay derived from a line through a circle is the map zz2z \mapsto z^2 restricted to the lattice. Two routes, one formula, and neither of them mentions the other’s objects.

What the picture cannot show

The figure draws six lines and a circle, and the set it describes is infinite and unbounded in every direction. Slopes near zero give triples with one leg vastly longer than the other; slopes near one give nearly isosceles triples, which are rare and interesting — (3,4,5)(3,4,5), (20,21,29)(20,21,29), (119,120,169)(119,120,169) — and are themselves governed by a Pell equation and appear at exponentially spaced intervals.

More importantly, the picture cannot show that the parametrisation is complete. It shows six triples arriving from six slopes; the theorem is that no triple arrives from anywhere else, and completeness is the whole content. The argument for it is the two-way correspondence in the section above, and no drawing carries a bijection — a bijection is a claim about two infinite sets, and a figure is a claim about a handful of points.

There is a third thing the drawing hides, which is the difference between the rationals and the reals. The circle drawn on the page looks continuous and the rational points are dense on it, so nothing in the picture distinguishes a rational point from any other. The whole subject lives in that invisible distinction: the circle has continuum-many points and countably many rational ones, and the difference between those two sizes is exactly what makes the parametrisation worth having.

The tree above the parametrisation

The parametrisation lists the triples, and it does not organise them. There is a structure that does, and it was found much later.

Every primitive triple has exactly three children, obtained by multiplying the column vector (a,b,c)(a, b, c) by three fixed integer matrices, and every primitive triple has exactly one parent — so the primitive triples form a ternary tree rooted at (3,4,5)(3, 4, 5). Barning found it in 1963 and Hall in 1970; it is remarkable that a set studied for three thousand years turned out to have an unnoticed tree structure in the twentieth century.

The tree is the parametrisation seen through kk and mm, where the three matrices act on the pair (k,m)(k, m) by simple linear maps, and it is a close relative of the mediant tree — both are generated by two-by-two integer matrices of determinant one acting on pairs, both produce every object of their kind exactly once, and both are unrecognisable as trees from the objects they enumerate.

What the tree adds is a notion of distance the parametrisation does not have. Two triples with similar-looking sides may be far apart in the tree, and two that look unrelated may be parent and child: (3,4,5)(3,4,5)'s three children are (5,12,13)(5,12,13), (21,20,29)(21,20,29) and (15,8,17)(15,8,17), which is not an ordering anybody would guess from the numbers. Enumerating a set and organising it are different achievements, and the parametrisation only does the first.

The same distinction shows up whenever a set has more than one natural description. The Stern–Brocot tree and the Farey sequence hold identical fractions and answer different questions; the divisor list and the divisor lattice hold identical divisors and only one of them shows the arithmetic. The lesson each time is that the arrangement is not a presentational choice — it is where the information is.

The triangles that are nearly isosceles

One family in the list deserves following, because it turns a question about triples into a question about a completely different equation.

A right triangle with legs differing by one — (3,4,5)(3,4,5), (20,21,29)(20,21,29), (119,120,169)(119,120,169), (696,697,985)(696,697,985) — is as close to isosceles as a whole-number right triangle can be, and it cannot be isosceles, because that would make 2\sqrt2 rational. Setting b=a+1b = a + 1 in a2+b2=c2a^2 + b^2 = c^2 and rearranging gives (2a+1)22c2=1(2a+1)^2 - 2c^2 = -1, which is Pell’s equation for 2\sqrt2.

The convergents of √2Each convergent marked on a number line, alternating above and below the value it approaches.√2 = 1.4142143/27/517/1241/2999/70239/169577/4087 convergents, each one closer than the last and on the other sidethe last of them, 577/408, is wrong by 2.1e-6
Fig. 6 The convergents of 2\sqrt2. The solutions of the Pell equation are exactly these fractions, and each one is a nearly-isosceles right triangle: 75\tfrac{7}{5} gives (3,4,5)(3,4,5), 4129\tfrac{41}{29} gives (20,21,29)(20,21,29), 239169\tfrac{239}{169} gives (119,120,169)(119,120,169).

So the near-isosceles triples are the continued-fraction convergents of 2\sqrt2 in disguise, they grow by a factor of about 5.85.8 each time, and there are infinitely many of them. Three separate constructions in this collection — the peeling of a rectangle, the descent that proves 2\sqrt2 irrational, and this parametrisation of triangles — turn out to produce the same sequence of numbers, because all three are about how badly 2\sqrt2 can be approximated by fractions.

The area of a right triangle

Fermat’s one surviving complete proof is about these triangles, and its conclusion is negative.

No Pythagorean triangle has a square area. Equivalently, there are no whole numbers with a2+b2=c2a^2 + b^2 = c^2 and 12ab\tfrac12 ab a perfect square. Fermat proved it by descent — assume such a triangle exists, construct a strictly smaller one, and note that a decreasing sequence of positive whole numbers cannot continue — and it is the only proof he wrote out in full.

The result matters more than it looks. It implies the case n=4n = 4 of Fermat’s last theorem immediately, which is why that case was settled three centuries before the rest. And it is the first theorem in what became the theory of congruent numbers: which whole numbers are the area of some right triangle with rational sides. One and two and three are not; five, six and seven are. The question is equivalent to a statement about rational points on the elliptic curve y2=x3n2xy^2 = x^3 - n^2 x, and a complete answer depends on the Birch–Swinnerton-Dyer conjecture, which is unproved.

So the same triangles that yield to a paragraph of coordinate geometry when the question is “which ones exist” become one of the seven Millennium Problems when the question is “which areas occur”. Nothing in either figure distinguishes the two questions, and that is the honest summary of what a picture of this subject can and cannot do.

What the ancients knew

Plimpton 322, a Babylonian tablet from about 1800 BC, lists fifteen rows of numbers that are, on the standard reading, Pythagorean triples — including (12709,13500,18541)(12709, 13500, 18541), which nobody stumbles on by trial. Whatever generated it was systematic, and the reconstruction that fits the data best is close to the kk, mm parametrisation, with the entries generated from ratios of regular numbers.

That is a thousand years before Pythagoras and fifteen hundred before Euclid wrote the parametrisation down. What the tablet does not contain is any statement of the theorem or any argument, which is the recurring difficulty with pre-Greek mathematics: the outputs demonstrate a method and the method was never written.

Euclid’s own presentation, in Book X, is a lemma about numbers rather than a result about triangles, and it makes no reference to right angles at all. The circle in this essay is entirely modern — it is Diophantus’ method of chords, formalised in the nineteenth century — and its value is that it explains why the parametrisation is complete, which Euclid’s version demonstrates without illuminating.

The tablet has one more thing worth saying about it. Its rows are ordered, and what they are ordered by is the ratio of the short leg to the long one, running smoothly from about 0.990.99 down to about 0.40.4 — which is to say, by angle. Whether that makes it a trigonometric table, as one recent reading argues, or a set of exercises in reciprocal pairs, as the more conservative reading has it, the ordering is deliberate and it is geometric. Somebody was looking at these numbers as shapes, and doing so a millennium and a half before anybody wrote down a proof about them.

Where the ladder goes next

This is the third rung on the Pythagoras ladder. The dissection proof established the theorem by rearranging area; this rung takes the theorem as given and asks which whole numbers satisfy it, which is a different question that happens to have a complete answer.

The next question is the obvious one and has no such answer: an+bn=cna^n + b^n = c^n for n3n \ge 3. The chord construction fails immediately, because a cubic curve does not hand over its third intersection, and what replaces it — the arithmetic of points on elliptic curves — is the machinery Wiles eventually used. The gap between a conic and a cubic is the gap between a paragraph and three hundred years.

Closer to hand, the same lattice carries the question of which numbers are sums of two squares, and the same projection carries the sphere onto the plane.