Erdos Problem #90 $500

The Unit Distance Problem

Given n points in the plane, what is the maximum number of pairs at distance exactly 1? A fundamental question in combinatorial geometry that remains open after 75 years.

The Question

Let u(n) be the maximum number of unit distances among n points in the plane. What is the true order of growth of u(n)?

Current bounds: n^{1+c/log log n} ≤ u(n) ≤ O(n^{4/3})

Explore the problem
Part 1

What Is a Unit Distance?

A unit distance is simply a pair of points that are exactly distance 1 apart. If you think of points as dots on paper and draw a line between two that are exactly 1 unit apart, that line represents a unit distance.

Unit Distance
Given points P and Q in the plane, they form a unit distance if |PQ| = 1, where |PQ| denotes the Euclidean distance between P and Q.

For n points, there are n(n-1)/2 pairs. The unit distance problem asks: how many of these can simultaneously equal 1?

Why Does This Matter?

The unit distance problem sits at the heart of combinatorial geometry, a field that studies how geometric constraints limit combinatorial possibilities. It connects to:

Part 2

Try It Yourself

Unit Distance Explorer

Click to place points. Green lines connect points at unit distance. Can you maximize the number of unit distances?

n = 25
Unit length: 60px
Click to add points, drag to move
Points (n)
0
Total Pairs
0
Unit Distances
0
Ratio u(n)/n
-
Part 3

Best Known Constructions

To prove a lower bound on u(n), we need to exhibit point configurations with many unit distances. The best constructions come from lattice structures.

Equilateral Triangles
3 points, 3 unit distances
Ratio: 1.0 per point
Triangular Lattice
Achieves ~3n unit distances
Each point has up to 6 neighbors
Square Lattice
Suboptimal: ~2n unit distances
Each point has up to 4 neighbors
Evolved Greedy ✓
50 points → 133 unit distances
Best: 2.667 per point

The Triangular Lattice is Optimal Locally

In the triangular (hexagonal) lattice, each interior point has exactly 6 neighbors at unit distance. This is the maximum possible by a classical packing argument: you cannot fit more than 6 non-overlapping unit circles around a point.

For the triangular lattice with n points: u(n) = 3n - O(sqrt(n))

However, the best asymptotic constructions use more sophisticated number-theoretic ideas to achieve u(n) = n^{1+c/log log n} for some constant c > 0.

Computational Discovery: Evolved Greedy Algorithm

Using ShinkaEvolve (evolutionary code optimization) with gemini-3-pro-preview, we discovered an improved greedy construction algorithm. Instead of filling a rectangular region of the triangular lattice, the evolved algorithm grows a compact "blob" shape by iteratively adding the lattice point that maximizes unit-distance connections.

ShinkaEvolve Results
✓ COMPLETED
Generations
50
Best Score
2.667
Compute Time
36m
Total Cost
$12.95
Top Evolved Strategies (all achieving score 2.667):
greedy_lattice_construction lattice_local_search simulated_annealing hexagonal_pruning_ils harborth_spiral_search
n (points) Unit Distances Ratio u(n)/n
25 57 2.28
50 133 2.667
100 265 2.65

The evolution converged on lattice-based approaches with local search optimization. For n=50, the best configuration achieves 133 unit distances (ratio 2.667). The theoretical upper bound O(n^{4/3}) ≈ 185 for n=50. Try it using the "Evolved Greedy" button above!

Part 4

Current Bounds

State of Knowledge Open Problem
Upper Bound
u(n) = O(n^{4/3})
Spencer, Szemeredi, Trotter (1984)
Lower Bound
u(n) = Omega(n^{1+c/log log n})
Erdos (1946)
Conjectured
u(n) = O(n^{1+epsilon}) for all epsilon > 0
Erdos Conjecture

Bounds Visualization

The chart below shows the theoretical bounds compared to our computational results. The gap between lower and upper bounds represents the open problem.

Upper Bound O(n^{4/3})
Lower Bound ~3n (triangular lattice)
Evolved Greedy (computed)
Linear u(n) = n

The Gap

The gap between n^{1+c/log log n} and n^{4/3} is enormous. For n = 10^6, the lower bound gives roughly n^{1.05} while the upper bound allows n^{1.33}. Closing this gap is worth $500.

Erdos believed the true answer is closer to the lower bound: that u(n) grows only slightly faster than linear. Any improvement to either bound would be a significant breakthrough.

Part 5

Connection to Incidence Geometry

The upper bound u(n) = O(n^{4/3}) comes from a beautiful connection to incidence geometry - the study of how points and curves can intersect.

Szemeredi-Trotter Theorem (1983)
The number of incidences between n points and m lines in the plane is O(n^{2/3}m^{2/3} + n + m).
Lines (m) Points (n) Incidences

Each incidence (orange) is where a point lies on a line. The theorem bounds the total count.

From Lines to Circles

The key insight is that each unit distance corresponds to an incidence between a point P and a unit circle centered at another point Q. If we count how many times points lie on unit circles centered at other points, we are counting unit distances.

Points Unit circles Incidences (= unit distances)

Point Q at unit distance from P lies on the unit circle centered at P. Each such incidence is a unit distance.

Using a generalization of Szemeredi-Trotter to circles (proved by Spencer, Szemeredi, and Trotter), one obtains:

u(n) ≤ cn^{4/3} for some constant c

Why Can't We Do Better?

The Szemeredi-Trotter bound for lines is tight - there exist configurations achieving the bound. However, the situation for unit circles is different. The constraint that all circles have the same radius should help, but we don't know how to exploit it.

The Challenge
Improving the upper bound requires either:

(1) A better incidence bound for equal-radius circles, or

(2) A completely different approach that avoids incidence counting.
Part 6

The Bigger Picture

The unit distance problem belongs to a family of extremal problems in combinatorial geometry. Related questions include:

The Guth-Katz Breakthrough (2015)

The distinct distances problem (Erdős Problem #89) asks: what is the minimum number of distinct distances determined by n points? Erdős conjectured this minimum is Ω(n/√log n), achieved by the integer lattice.

Guth-Katz Theorem (2015)
Any set of n points in the plane determines at least Ω(n/log n) distinct distances.

This was a major breakthrough using algebraic geometry techniques (the polynomial method). The connection to unit distances is deep: if we could maximize repeated distances, we would minimize distinct distances.

Lattice points Unit distance √2 distance 2 distance

Integer lattice: many repeated distances (colored by type) but still Ω(n/√log n) distinct values.

The Deep Connection

In Higher Dimensions

In d dimensions (d ≥ 4), the unit distance problem is essentially solved. The maximum is Theta(n^2) in 4D and higher, achieved by placing points on a 2-dimensional sphere. The cases d = 2 and d = 3 remain the most mysterious.

d = 2: n^{1+o(1)} ≤ u(n) ≤ O(n^{4/3})
d = 3: n^{4/3} ≤ u(n) ≤ O(n^{3/2})
d ≥ 4: u(n) = Theta(n^2)