← Exceptional Atlas

Sphere Packing & the Leech Lattice

Part 9 of 9. The 240 roots generate the E₈ lattice, which gives both the largest kissing number and the densest sphere packing in 8 dimensions. A binary code builds it, and the same ideas lead to the Leech lattice in 24.

The E₈ lattice

Part 8 treated the 240 roots as a finite set. They are also the shortest nonzero vectors of the E₈ lattice, a discrete subgroup of ℝ8 that extends outward in shells of increasing squared length. This part asks how well that lattice packs spheres: how many can touch one sphere, and how densely they can fill space. It then builds E₈ from an error-correcting code and follows the same route to the Leech lattice in 24 dimensions.

The D₈⁺ construction

A vector is in the E₈ lattice if its 8 coordinates are either all integers or all half-integers (n + ½ with n ∈ ℤ), and their sum is even. The shortest integer vectors are the 112 roots (±1, ±1, 0, …, 0) of D8, and the shortest half-integer vectors are the 128 vectors (±½, …, ±½) with an even number of minus signs.

Shell structure

squared length klattice vectors in shellnotes
01the zero vector
2240the 240 roots (minimum shell)
42,160
66,720
817,520
1030,240
1260,480
1482,560
16140,400

Figure 1. Shell counts for the E₈ lattice. Each row counts lattice vectors of exactly that squared length.

Shell explorer

Squared length k: 2
View:

Showing the k = 2 shell (240 vectors).

Figure 2. E₈ lattice shells, k = 2 to 16. In parallel coordinates, blue lines are integer vectors and indigo lines half-integer ones. In the Coxeter projection, grey dots are the 240 roots and coloured dots the selected shell. Beyond k = 2 the view draws an even sample of at most about 1,500 vectors; the count above is always the full shell.

The theta series

The theta series of a lattice Λ collects the shell counts into one generating function:

For E₈:

The displayed q is a norm-counting variable. In the standard modular convention Q = e2πiτ counts half the squared norm, so ΘE₈(τ) = 1 + 240Q + 2160Q2 + ⋯ = E4(τ), the weight-4 Eisenstein series. Equivalently, the displayed series is E4 after substituting Q = q2. Its modular transformation law is what Viazovska's 2016 packing proof relies on.

Unimodularity

A lattice Λ is unimodular if its dual lattice Λ* equals Λ itself, where:

E₈ is unimodular, so its fundamental domain has volume exactly 1. Up to isometry it is the only even unimodular lattice in 8 dimensions; there are none in dimensions 1–7 and 24 in dimension 24 (the Niemeier lattices, one of which is the Leech lattice). Being even and unimodular is what makes the theta series a modular form of weight n/2.

The lower bound

Divide the roots by √2 to get unit vectors. Their pairwise inner products lie in , all ≤ 1/2, so 240 unit spheres centred at these points touch a central unit sphere without overlapping. The kissing number in 8 dimensions is at least 240.

The upper bound: linear programming

The harder direction is showing that no 241 unit vectors in ℝ8 can be pairwise at least 60° apart. Take N unit vectors with pairwise inner products at most 1/2, and a function f: [−1, 1] → ℝ with (a) f(t) ≤ 0 for t ∈ [−1, 1/2] and (b) nonnegative Gegenbauer coefficients. Then

This is the Delsarte bound. In 1979 Odlyzko and Sloane, and independently Levenshtein, found a function for n = 8 whose bound is exactly 240:

Kissing bounds across dimensions

DimBest known kissingDelsarte LP boundStatus
122✓ trivial
266✓ classical
31213.1612 proved 1953 (Schütte, van der Waerden), not by LP
42425.5624 proved 2003 (Musin), by strengthening the LP method
54046.34gap
67282.63gap
7126140.16gap
8240240✓ 1979 (Odlyzko–Sloane)
9306380.10gap
10510595.83gap
164,3208,313.78gap
24196,560196,560✓ 1979 (Odlyzko–Sloane)

Figure 3. Kissing number lower bound vs Delsarte LP upper bound. The LP bound equals the kissing number only in dimensions 1, 2, 8 and 24. In dimensions 3 and 4 the kissing numbers are known, 12 and 24, but the plain LP bound rounds down to 13 and 25 and the proofs needed more. LP values for other dimensions are optima of Delsarte's linear program, the bounds Odlyzko and Sloane (1979) tabulated, recomputed here numerically; best-known configurations are from Cohn's table of kissing number bounds as of 2026.

The gap by dimension

Dimension: 8

dim 8: best known = 240, LP bound = 240, gap = 0 (tight).

Figure 4. Kissing-number bounds for dimensions 2–24, log scale. Blue is the best known configuration, red the Delsarte LP bound. The slider highlights a dimension here and in the table.

Beyond dimensions 1 and 2, the Delsarte bound is tight only in dimensions 8 and 24, where the inner products between minimal vectors of E8 and of the Leech lattice sit exactly at the roots of the optimal polynomial.

Packing density

Kissing is a local question. Packing asks how densely equal spheres can fill all of ℝn; for a lattice, the density is the volume of one ball divided by the volume of a fundamental domain. E8 settled kissing in 1979, and packing took 37 more years.

Computing E₈'s packing density from scratch

Step 1. Unit-ball volume in 8D.
Step 2. Packing radius from minimum vector length.

E₈'s minimum vectors have squared length 2, so length √2. Packing radius is half the minimum distance.

Step 3. Ball volume at the packing radius.
Step 4. Covolume of the E₈ lattice.

E₈ is unimodular: its fundamental parallelepiped has volume exactly 1.

Step 5. Packing density.

Density = (ball volume) / (covolume of lattice).

Figure 5. Computing E₈'s packing density in five elementary steps. The final answer is π⁴/384 ≈ 0.2537.

The Cohn–Elkies upper bound

The upper-bound side uses an analogue of the Delsarte bound, due to Cohn and Elkies (2003). If an admissible Schwartz-class function f has the right positivity conditions and f(x) ≤ 0 for |x| ≥ r, then:

Each admissible f gives an upper bound, and finding the best one is an infinite-dimensional linear program. In most dimensions the best bound found numerically stays well above the best known packing.

Viazovska's function

In 2016, Maryna Viazovska constructed a specific admissible function f for n = 8 whose Cohn–Elkies bound equals π⁴/384 exactly. Up to constants, each piece of her f has the form:

where φ is built from Eisenstein series and theta functions but is not itself a modular form. f is the sum of two pieces: in one, φ is a quasimodular form of weight 0 (it involves E2, which is not modular); in the other, it is a weakly holomorphic modular form of weight −2 for Γ(2), allowed a pole at the cusp. The two are arranged so that f meets the positivity conditions and takes exactly the right values at the points of E₈. The paper appeared in the Annals of Mathematics in 2017.

To get a feel for tuning f, Figure 6 searches a small family in dimension 8: f(x) = (a + b|x|2) e−α|x|2. Its Fourier transform has a closed form, so both conditions can be checked exactly: f must be nonpositive everywhere beyond E8's minimal distance √2, not just at the lattice shells, and f̂ must be nonnegative everywhere. When both hold, Cohn–Elkies bounds the density of every 8-dimensional packing by (π4/384) · f(0)/∫f, so the ratio f(0)/∫f says how far the bound sits above E8. For a bare Gaussian, degree 0 in |x|2, the two conditions can never hold together (f > 0 everywhere or f̂ < 0 everywhere), which is why the family multiplies it by a linear one.

checking… f(r)   must be ≤ 0 in the shaded region r ≥ √2(a + b r²) e−αr²
checking… f̂(k)   must be ≥ 0 everywhere∝ (a + b(4/α − k²/4α²)) e−k²/4α
a1.000
b0.000
α1.000

Constraints

Bound f(0) / ∫f, in units of E8's density

none

Figure 6. A Cohn–Elkies bound in dimension 8 from a two-term Gaussian family. Top: f(r), which must stay at or below zero in the shaded region. Bottom: its Fourier transform, which must stay at or above zero. Curves are scaled to fit. Both conditions are checked exactly, and when they hold the panel reports the resulting upper bound on packing density. Best in family jumps to a = 2, b = −1, α = 2.5, the optimum of this family, which bounds every 8-dimensional packing by about 2.005 times E8's density.

The bound itself is Cohn and Elkies' (2003). Viazovska's contribution was an f whose bound comes down from about 2 times E8's density, where this family stops, to exactly 1. Numerical searches with high-degree polynomials had already come very close to 1 and suggested the right f vanishes at every E8 shell radius beyond the first. Viazovska built that function from modular forms.

Historical timeline

1611
Kepler conjectures the densest 3D packing is the face-centred cubic (~74%).
1905
Minkowski initiates the modern study of lattice packing.
1967
Leech constructs the Leech lattice in 24 dimensions.
1979
Odlyzko–Sloane and Levenshtein independently prove the 8D and 24D kissing numbers (240 and 196,560) are optimal.
1998
Hales proves the 3D packing density (FCC / 74%) is optimal, confirming Kepler's 1611 conjecture.
2003
Cohn and Elkies introduce the LP bound for packing density. For n = 8 and 24 the bound comes very close to the lattice lower bound without matching it.
2016 Mar 14
Viazovska posts The sphere packing problem in dimension 8 to arXiv. E₈ is optimal.
2016 Mar 21
Cohn, Kumar, Miller, Radchenko, and Viazovska prove the Leech lattice is optimal in 24D, seven days later.
2022
Viazovska receives the Fields Medal, the second woman to do so.

Figure 7. Key dates in the sphere packing story.

The 8- and 24-dimensional proofs appeared a week apart in March 2016, both built on modular forms. The densest packing is known in dimensions 1, 2, 3, 8 and 24 and in no others.

Codes and packings

A binary block code of length n is a set C ⊆ {0, 1}n of valid codewords. A channel flips some bits of a transmitted codeword, and the receiver guesses the nearest codeword to what arrived. A good code spreads its codewords apart in Hamming distance, so a few flipped bits can always be undone.

A sphere packing is the same idea in ℝn: centres at least some minimum distance apart, and noise decoded by rounding to the nearest centre. Construction A turns one problem into the other.

Construction A

Given a binary linear code C ⊆ {0, 1}n (equivalently, a linear subspace of 𝔽2n), define the lattice:

A vector x ∈ ℤn is in Λ(C) if its coordinates, read mod 2, form a codeword. Because a linear code is closed under addition mod 2, Λ(C) is closed under addition, and it is a lattice.

For a small example, take n = 2 and the repetition code C = {00, 11}:

This is D2, the integer points with even coordinate sum.

The extended Hamming [8, 4, 4] code

The extended Hamming code H8 has length 8, dimension 4 (so 24 = 16 codewords) and minimum distance 4: any two codewords differ in at least 4 positions. It is self-dual, equal to its own orthogonal complement in 𝔽28. Its codewords are the zero word, the all-ones word, and 14 words of weight 4:

Click a codeword to see which E₈ lattice vectors it generates via Construction A.

Figure 8. The 16 codewords of the extended Hamming code. Click one to see the Construction A vectors it produces.

Click a codeword above to see the lattice vectors.

Figure 9. The minimum-length lattice vectors congruent to the selected codeword mod 2.

The minimum shell from the code

The minimum squared length of Λ(C) is min(4, d), where d is the minimum distance of the code, so here it is 4. The vectors of squared length 4 come in two kinds. Each of the 14 weight-4 codewords gives vectors with ±1 in its four positions, 24 = 16 sign choices each, for 224. The zero codeword gives the all-even vectors ±2ei, 16 more. That is 224 + 16 = 240, and scaling by 1/√2 brings the squared length down to 2, E₈'s minimum shell.

So E₈ has now been described three ways: by its roots, as D8+, and as Construction A on the extended Hamming code.

The lattice-code dictionary

Code sideLattice side
length ndimension n
minimum Hamming distance dminimum squared length min(d, 4)
2k codewordslattice modulo 2ℤn has 2k cosets
self-dual codeunimodular lattice
weight enumerator WC(x, y)theta series ΘΛ(q) (via substitution)
Hamming ball around a codewordVoronoi cell around a lattice point
decoder = nearest codeworddecoder = nearest lattice point
error correction capabilitypacking radius

Figure 10. The dictionary between binary codes and Construction A lattices.

Construction A, step by step

Pick a codeword and the eight boxes below show its bits. Where the codeword has a 1 the lattice coordinate must be odd (±1, ±3, …), and where it has a 0 it must be even (0, ±2, …). Generate draws a random minimum-shell vector that fits.

Codeword:

Figure 11. Construction A in action. Each box represents one coordinate of ℤ8. Red boxes (codeword bit = 1) hold odd integers; blue boxes (bit = 0) hold even integers. The generated vector is a point in Λ(H8); after scaling by 1/√2 it becomes a minimum vector of E₈.

Decoding

A code of minimum distance d corrects ⌊(d−1)/2⌋ errors, because Hamming balls of that radius around distinct codewords do not overlap. For d = 4 that means any single flipped bit can be undone by nearest-codeword decoding, and any two flips can at least be detected. Click a bit in the "received" row to flip it.

sent
received
decoded
No noise yet. Click any bit in the "received" row to flip it.

Figure 12. The extended Hamming [8, 4, 4] decoder. Click bits in the "received" row to inject errors; the decoder returns the codeword at minimum Hamming distance. With one flip the decoder always recovers the original. Two flips put the received word at distance 2 from the original and at least 2 from every other codeword, so it can tie, and three flips can land it nearer a wrong codeword.

The lattice behaves the same way. The packing radius of E₈ (minimum norm 2) is 1/√2, so a point perturbed by less than that still rounds back to the original. A larger perturbation can carry it out of the original's Voronoi cell and into a neighbour's.

From 8 dimensions to 24

In 24 dimensions the natural code is the binary Golay code, a self-dual [24, 12, 8] code with 4,096 codewords, and the target is the Leech lattice. Construction A alone does not reach it.

Construction A on the Golay code, scaled by 1/√2 so that it is unimodular, is an even unimodular lattice, but its shortest vectors are the 48 vectors ±√2 ei of squared length 2, coming from the zero codeword. Every nonzero codeword has weight at least 8 and contributes vectors of squared length at least 4. So the result is the Niemeier lattice whose roots form 24 copies of A1, not the Leech lattice. The fix is Construction B: among integer vectors congruent mod 2 to a Golay codeword, keep those whose coordinate sum is divisible by 4, which removes ±2ei; then add the coset of an odd vector such as (−3, 1, 1, …, 1), and scale by 1/√8. The result is the Leech lattice Λ24, with minimum squared length 4 and 196,560 minimal vectors. Leech found it in the mid-1960s; its automorphism group gave Conway three new sporadic simple groups, one as a quotient and two as subgroups.

E₈ and Leech, side by side

Figure 13. E₈ and Leech compared property by property, with bars on a log scale. "Highlight differences" dims what they share (both unimodular, both proved optimal in 2016).

A lattice without roots

Of the 24 even unimodular lattices in dimension 24 (the Niemeier lattices), twenty-three contain vectors of squared length 2. The Leech lattice is the one that does not, so its minimum squared length jumps to 4, carried by 196,560 vectors.

Roots would force the automorphism group to contain their Weyl group. The Leech lattice has none, and its symmetry group comes from somewhere else; it contains the symmetries of the Golay code but is far larger.

The Niemeier family

Root system# rootsNotes
D241104largest root count
D16 ⊕ E8720E₈ appears as a summand
E83720three orthogonal copies of E₈
A24600
⋮ (19 more)⋮all with roots
(none)0Leech lattice Λ24

Figure 14. The Niemeier lattices, abbreviated. E83, the direct sum of three copies of E₈, is one of the twenty-three with roots and is not the Leech lattice.

Leech and three copies of E₈

The Leech lattice can still be built from E₈, but from copies of E₈ scaled by √2, so that their minimum squared length is already 4. The Leech lattice contains three mutually orthogonal copies of √2E₈, and a Turyn-type construction (Lepowsky and Meurman, 1982, modelled on Turyn's 1967 construction of the Golay code from two versions of the Hamming code) glues them together without creating any vectors of squared length 2. Unscaled E83 cannot be enlarged at all, since it is already unimodular.

The Conway groups

The automorphism group of the Leech lattice, Co0, has order ≈ 8.3 × 1018. In 1968 John Conway computed this group and discovered that its quotient by a centre of order 2 is a simple group, Co1, and that Co0 contains two further sporadic simple groups: Co2, the stabiliser of a vector of squared length 4 (type 2), and Co3, the stabiliser of a vector of squared length 6 (type 3). Co1, Co2 and Co3 are three of the 26 sporadic finite simple groups. Co1 is a quotient of Co0, not a subgroup, while Co0 also contains other sporadic groups: the Higman–Sims and McLaughlin groups, and the Mathieu groups. M24, the symmetry group of the Golay code, sits inside Co0 as its coordinate permutations, and the Leech lattice is also the starting point for constructing the Monster, which the Modular Forms series takes up.