Ford Circles

Every fraction gets a circle. The circles kiss their neighbors — and never, ever cross.
Hidden in how evenly they spread is a statement exactly as strong as the Riemann Hypothesis.

12
Hover or tap a circle: its fraction, and its tangent kissing-partners, light up. Drag to pan.

The scoreboard: how evenly do the fractions spread?

Franel's discrepancy D(n) measures how far the Farey fractions of order n sit from perfectly even spacing. Franel–Landau (1924): the Riemann Hypothesis is equivalent to D(n) growing slower than n1/2+ε. The chart shows D(n) against reference slopes — the data can't prove anything (finite window), but you can watch which slope it hugs.

About the math (one click deep, as promised)

Ford circle. For a reduced fraction p/q, draw the circle of radius 1/(2q²) sitting on the number line at x = p/q. Big-denominator fractions get tiny circles: the circle's size is the fraction's simplicity.

Kissing theorem (Ford 1938). Two Ford circles never overlap. They are tangent exactly when |ps − rq| = 1 — exactly when the fractions are neighbors in a Farey sequence. The whole tangency structure of the picture is number theory made visible: each circle's kissing partners are its continued-fraction relatives.

Mediant. Between two kissing circles p/q and r/s, the first new fraction to appear as n grows is the mediant (p+r)/(q+s) — its circle nests exactly into the gap, tangent to both parents. Raise the order slider and watch the gaps fill in this way, forever.

The RH connection (Franel–Landau 1924). List the Farey fractions of order n in (0,1] as f₁ < … < f_N. If they were perfectly evenly spread, f_ν would sit at ν/N. The discrepancy D(n) = Σ|f_ν − ν/N| measures the total deviation. Franel and Landau proved: RH ⇔ D(n) = O(n^{1/2+ε}) for every ε > 0. Evenness of fractions and zeros of ζ are the same fact wearing two costumes.

Claim grade: visualization / pedagogy only. The theorems cited (Ford's tangency theorem, the Franel–Landau equivalence) are classical and proved. The discrepancy chart is a finite computation (n ≤ 300): finite data can neither confirm nor refute an asymptotic statement, so nothing on this page is evidence for or against the Riemann Hypothesis.

Engine and unit tests (Farey correctness against totient sums, exact tangency criteria, hand-computed discrepancies) are in this site's repository.