What is being displayed
The dots are the points of the square lattice Z², with the origin drawn larger. A circle centred on the origin with squared radius n passes through r₂(n) of them. Only n that are sums of two squares qualify: if such an n factors over the primes p ≡ 1 (mod 4) as p₁^e₁ … pₖ^eₖ, then r₂(n) = 4(e₁+1)…(eₖ+1).
Coloured are the circles that pass through more lattice points than any smaller circle. Their squared radii are
0, 1, 5, 25, 65, 325, 1105, 4225, 5525, 27625, …
carrying 1, 4, 8, 12, 16, 24, 32, 36, 48, 64, … points. These are OEIS A071383 and A071385. Conway showed that consecutive squared radii grow by a factor of at most 5. Each zoom step moves to the next record, the view being sized so that the radius rounds up to a whole lattice step, which is why the green circle always sits just inside the frame.
Green marks the largest record circle that fits in the view, blue the earlier ones. Past a few thousand points the points on a record circle sit closer together than a pixel and the circle reads as a solid ring; the lattice itself merges into a solid field at much the same depth, which is why the picture becomes a filled square carrying rings.
Records and their lattice points are computed exactly while you zoom, from factorisations over the Gaussian integers, so nothing is tabulated in advance.
Press u on the smaller circles to draw the unit-distance segments: for each vector joining the origin to a point on the current record circle, every pair of lattice points separated by that same vector is joined. All these segments have equal length, so the figure shows how often a single distance is repeated among lattice points, the question behind the Erdős unit-distance problem. It is offered only up to r² = 325, and thins as the circles grow; beyond that the segments are too dense to read.
oeis.org/A071383
press any key or tap to close