Series

Sums of two squares — the series

11 essays on one idea, from the one that introduces it to the one that assumes the rest.
  1. The circle of radius √25 on the integer lattice. A circle drawn on the whole-number grid, with the lattice points it passes through marked.

    Two squares, and a lattice

    Whether a prime is the sum of two squares is decided entirely by its remainder on division by four. A fact about circles is settled by a fact about remainders, and neither statement contains any hint of the other.

    part 1 · number
  2. The two squares of 97, produced by division. A table of the division chain on 97 and a square root of minus one modulo it, with each row's quotient and remainder, the point at which the remainder falls below the square root marked, and the two squares that add to 97.

    The two squares actually produced

    Three proofs say a prime one more than a multiple of four is a sum of two squares, and not one of them hands over the squares. Running the Euclidean algorithm half-way does — and where to stop is the whole of the correctness argument.

    part 2 · number
  3. How rare a sum of two squares is. Two curves against the logarithm of the bound: the fraction of numbers below it that are sums of two squares, falling; and that count times the square root of the logarithm, divided by the bound, which is nearly constant.

    Almost no number is one

    Sums of two squares look common — a sixth of all numbers up to a million are one. The fraction is falling to nothing, at a rate so slow that no computation will ever make it obvious, and the constant in front of it has been computed to fifty places and identified with nothing.

    part 3 · number
  4. The next sum of two squares after 150. A quarter of the circle of radius √150 on the integer lattice, with the column x = 12 and the first lattice point above the circle in it, (12, 3), on the circle of radius √153.

    The wait for the next sum of two squares

    Sums of two squares thin out to a share of nought, and yet the gaps between them stay short. Take the largest square below any number; what is left over is small, and a small number is always close to a square. Two squarings in a row say the next sum of two squares is never more than about 2√2 times the fourth root of n away — a bound proved in 1947 that nobody has improved, sitting far above every gap anyone has found.

    part 4 · number
  5. From a rational point on x² + y² = 17 to a whole one. The circle of radius √17 on the integer lattice, a rational point on it, and 4 reflections through nearest lattice points, the denominators 3757, 205, 25, 5, 1, ending at (1, 4).

    A fraction on the circle forces a whole point

    If a number is a sum of two squares of fractions, it is a sum of two squares of whole numbers. Draw the circle, mark the rational point, join it to the nearest lattice point and follow the line to where it meets the circle again: the new point is rational too, with a smaller denominator. Repeat, and the denominators fall until they reach one. The argument needs no primes at all — only the fact that every point of the plane is within distance one of the lattice.

    part 5 · number
  6. Each prime of the form 4k + 1 as a point on its own circle. Points (a, b) with a > b > 0 and a² + b² prime, for the 1125 such primes below 20000, filling the sector between 0° and 45°.

    Which way a prime's two squares point

    A prime one more than a multiple of four is a sum of two squares in exactly one way, and the two squares make a point on a circle. Draw that point for every such prime and ask which way it faces. It faces every way equally — the angles spread evenly over the sector, which Hecke proved by giving each angle a remainder and copying Dirichlet. Measured over seventy-four thousand primes, they are even more evenly spread than random angles would be.

    part 6 · number
  7. Primes in five thousand thin sectors. 581517 primes in (2e7, 4e7] in 4967 sectors; mean 117.08, variance ratio 0.874, 2 empty.

    Sectors that shrink with the primes

    Hecke proved that the angles of the primes a² + b² are evenly spread, so every fixed sector eventually gets its share. Let the sector shrink as the primes grow, to width X^(−α), and the question is open beyond small α. Measured on the 581,517 such primes between twenty and forty million, wide shrinking sectors fluctuate far less than chance and thin ones as much as chance — and the thin sectors that go empty are not scattered: they gather beside the directions of small rational slope, most of all slopes like 1/3 and 1/1 whose two terms are both odd.

    part 7 · number
  8. A walk on Gaussian primes stopped by a moat. Step ≤ 2 from 1 + i: 720 primes reached, farthest 17 + 42i at 45.310.

    A walk on Gaussian primes stopped by a moat

    Start at 1 + i and step from Gaussian prime to Gaussian prime, never more than 2 at a time: the walk reaches 720 primes and stops at 17 + 42i, surrounded by a moat. Allow steps of √10 and it reaches a quarter of a million primes before stopping at distance 1,024; steps of 4 carry it to 4,313. Whether some fixed step lets a walker reach infinity is a question Basil Gordon asked in 1962, and it is open.

    part 8 · number
  9. The numbers below a hundred as sums of three cubes. Smallest solution size per n < 100: 1:9 2:1 3:1 6:2 7:2 8:16 9:2 10:2 11:3 12:11 15:2 16:2 17:2 18:3 19:3 20:3 21:16 24:2 25:3 26:3 27:6 28:3 29:3 30:10d 33:16d 34:3 35:3 36:3 37:4 38:4 39:6d 42:17d 43:3 44:8 45:4 46:3 47:8 48:4 51:796 52:11d 53:3 54:3 55:3 56:4 57:4 60:5 61:5 62:3 63:4 64:6 65:4 66:4 69:5 70:21 71:4 72:4 73:4 74:15d 75:9d 78:55 79:35 80:4 81:3 82:14 83:4 84:8d 87:4271 88:5 89:7 90:4 91:4 92:4 93:7 96:22 97:5 98:5 99:4.

    Thirty-three as three cubes

    Which numbers are a sum of three cubes, allowing negatives? Nothing like the rule for two squares is known — only that numbers leaving 4 or 5 on division by 9 are impossible. Every other number below a hundred has a sum with cubes under 5,000, except eight; 33 needed sixteen-digit cubes and was found in 2019.

    part 9 · number
  10. Where each count of cubes stops being needed. last needing 9..6: 239, 454, 8042, 1290740; counts 114, 5721, 154467, 941641, 393997, 3922, 121, 15, 2 up to 1500000.

    Nine cubes for two numbers

    Every whole number is a sum of at most nine positive cubes, and only two numbers, 23 and 239, need all nine. Fifteen need eight, the last of them 454; 121 need seven, the last 8,042; six are needed for the last time at 1,290,740. The count every number needs is nine, fixed by two small accidents. The count every large number needs is somewhere between four and seven, and the computation says four — a question about how the cubes spread out, not about the cubes themselves.

    part 10 · number
  11. How many fourth powers every number needs. Fewest fourth powers summing to n, n <= 10000000: 19 needed by 79, 159, 239, 319, 399, 479, 559; 18 by 24 numbers (last 1248); 17 by 65 (last 13792).

    Nineteen fourth powers, and then sixteen

    Edward Waring claimed in 1770 that every number is a sum of at most nineteen fourth powers. It is true, and it is needed: 79 takes nineteen, because its remainder on division by sixteen forces fifteen ones. But only seven numbers need nineteen, the last of them 559; the last to need eighteen is 1,248, and the last to need seventeen is 13,792. Counting every number to ten million shows the stragglers thinning out and the one obstruction that never goes away — the remainder modulo sixteen, which makes 31, 496, 7,936 and every 31·16ᵐ need sixteen for ever.

    part 11 · number

All series