Heegner numbers¶
Overview¶
The Heegner numbers are the nine positive integers
for which the imaginary quadratic field \(K=\mathbb{Q}(\sqrt{-d})\) has class number \(h_K = 1\). Equivalently, the ring of integers \(\mathcal{O}_K\) is a unique factorization domain (UFD). [contributors, 2025, Weisstein, 2025]
This “exactly nine” phenomenon is one of the landmark classification results in classical algebraic number theory and is tightly connected to:
the arithmetic of binary quadratic forms (Gauss),
complex multiplication of elliptic curves and singular moduli (Heegner–Stark),
and the famous “almost integer” \(e^{\pi\sqrt{163}}\).
1. Imaginary quadratic fields and discriminants¶
Let \(d>0\) be squarefree and set \(K=\mathbb{Q}(\sqrt{-d})\).
1.1 The ring of integers \(\mathcal{O}_K\)¶
A frequent pitfall is assuming \(\mathcal{O}_K=\mathbb{Z}[\sqrt{-d}]\) always holds. In fact:
If \(d\equiv 1,2 \pmod 4\), then
\[ \mathcal{O}_K=\mathbb{Z}[\sqrt{-d}], \qquad \Delta_K=-4d. \]If \(d\equiv 3 \pmod 4\), then
\[ \mathcal{O}_K=\mathbb{Z}\!\left[\frac{1+\sqrt{-d}}{2}\right], \qquad \Delta_K=-d. \]
Here \(\Delta_K\) is the (fundamental) field discriminant. [Cox, 2013]
1.2 Heegner discriminants¶
Because the theory is often indexed by discriminant rather than by \(d\), it is useful to record:
These are exactly the negative fundamental discriminants with class number \(1\). [Cox, 2013]
2. Class number and unique factorization¶
2.1 From element factorization to ideal factorization¶
The ring \(\mathcal{O}_K\) is a Dedekind domain. This implies:
Every nonzero ideal factors uniquely into prime ideals.
But elements in \(\mathcal{O}_K\) may fail to factor uniquely into irreducibles.
The mechanism measuring “how far” we are from principal ideals is the ideal class group:
Its cardinality is the class number:
2.2 Why \(h_K=1\) is the same as “UFD” here¶
For rings of integers in number fields (Dedekind domains), we have the chain of equivalences:
So Heegner numbers classify precisely the imaginary quadratic integer rings with unique factorization. [Cox, 2013]
2.3 A concrete failure of unique factorization¶
In \(\mathbb{Z}[\sqrt{-5}]\) (which corresponds to \(d=5\), not a Heegner number), we have:
and these are genuinely distinct factorizations (up to units), so UFD fails; indeed \(h_{\mathbb{Q}(\sqrt{-5})}>1\). [Cox, 2013]
3. Gauss’ binary quadratic forms viewpoint¶
Binary quadratic forms provide a very concrete model for class groups.
A primitive positive definite binary quadratic form is
with negative discriminant
Two forms are equivalent if related by an \(\mathrm{SL}_2(\mathbb{Z})\) change of variables. Gauss’ composition defines a finite abelian group on equivalence classes, and that group matches the ideal class group (for the order of discriminant \(\Delta\); in particular for fundamental \(\Delta\) it matches \(\mathrm{Cl}(\mathcal{O}_K)\)). [Cox, 2013]
3.1 Reduced forms and the class number¶
A positive definite form \((a,b,c)\) is reduced if:
and if \(|b|=a\) or \(a=c\), then additionally \(b\ge 0\).
A key fact: the number of reduced forms of discriminant \(\Delta\) equals the class number \(h(\Delta)\). So \(h(\Delta)=1\) means: there is exactly one reduced form for that discriminant. [Cox, 2013]
3.2 The unique reduced forms for the Heegner discriminants¶
For each Heegner discriminant, the single reduced form can be written explicitly:
\(\Delta=-4\): \(x^2+y^2\)
\(\Delta=-8\): \(x^2+2y^2\)
\(\Delta=-3\): \(x^2+xy+y^2\)
\(\Delta=-7\): \(x^2+xy+2y^2\)
\(\Delta=-11\): \(x^2+xy+3y^2\)
\(\Delta=-19\): \(x^2+xy+5y^2\)
\(\Delta=-43\): \(x^2+xy+11y^2\)
\(\Delta=-67\): \(x^2+xy+17y^2\)
\(\Delta=-163\): \(x^2+xy+41y^2\)
You can verify, for example, that \(x^2+xy+41y^2\) has discriminant \(1-4\cdot 1\cdot 41=-163\). This “single reduced form” phenomenon is another face of class number one. [Cox, 2013]
4. The class-number-one theorem (why exactly nine?)¶
The theorem states that there are exactly nine imaginary quadratic fields of class number one. Historically:
Heegner (1952) proved the result using modular functions and the emerging ideas of complex multiplication. [Heegner, 1952]
A gap in the original proof was later clarified and the argument completed/strengthened in later work (notably by Stark), leading to the modern accepted classification. [Stark, 1967, Stark, 1969]
The broader Diophantine toolkit around these questions is closely linked to effective bounds from linear forms in logarithms (Baker’s theory). [Baker, 1966]
A widely used modern reference that connects the class group, quadratic forms, and complex multiplication in one narrative is Cox. [Cox, 2013]
5. Why Heegner numbers create “almost integers”¶
The most famous numerical surprise is:
This is not an accident; it comes from complex multiplication and the \(q\)-expansion of the modular \(j\)-invariant.
5.1 The \(j\)-invariant and its \(q\)-series¶
Let \(j(\tau)\) be the modular \(j\)-invariant. It has a Fourier expansion in
of the form
with integer coefficients. [Diamond and Shurman, 2005]
When \(\tau\) is an imaginary quadratic point in the upper half-plane (a CM point), \(j(\tau)\) is an algebraic integer. More precisely, \(j(\tau)\) generates the Hilbert class field of \(K=\mathbb{Q}(\tau)\). When \(h_K=1\), the Hilbert class field is just \(K\) itself, and the special values become exceptionally explicit. [Cox, 2013]
5.2 Why \(d=163\) is the showpiece¶
Take
Then \(\mathrm{Im}(\tau)=\frac{\sqrt{163}}{2}\), so
which is astronomically small. Also \(\mathrm{Re}(\tau)=\tfrac12\), so \(q\) is negative real to extremely high precision:
Therefore \(q^{-1}\approx -e^{\pi\sqrt{163}}\) and the expansion implies
is extremely close to \(q^{-1}+744\).
For this specific CM point, complex multiplication yields the celebrated exact value
Substituting \(q^{-1}\approx -e^{\pi\sqrt{163}}\) gives
and the error is on the order of \(e^{-\pi\sqrt{163}}\), explaining why the approximation is absurdly accurate. [contributors, 2025, Cox, 2013, Weisstein, 2025]
6. Analytic class number formula (bridge to \(L\)-functions)¶
A second “high-level” way to see class numbers is the Dirichlet class number formula. For a negative fundamental discriminant \(\Delta<0\):
Here:
\(w\) is the number of roots of unity in \(\mathcal{O}_K\); for imaginary quadratic fields, \(w=2\) except for \(\Delta=-4\) (Gaussian integers, \(w=4\)) and \(\Delta=-3\) (Eisenstein integers, \(w=6\)).
\(\chi_\Delta(n)=\left(\frac{\Delta}{n}\right)\) is the Kronecker symbol (a quadratic Dirichlet character),
and
\[ L(1,\chi_\Delta)=\sum_{n=1}^{\infty}\frac{\chi_\Delta(n)}{n}. \]
This formula is the doorway from “class number” into Dirichlet characters and \(L\)-functions, and it is a natural starting point for computational experiments around prime races / residue classes later. [Cox, 2013]
7. Computation-friendly viewpoints (good experiment hooks)¶
7.1 Counting reduced forms (elementary and visual)¶
For a negative fundamental discriminant \(\Delta\), enumerate all integer triples \((a,b,c)\) with:
apply the reduced-form tie-break rules, and count reduced forms. That count is \(h(\Delta)\).
For the Heegner discriminants, you will find exactly one reduced class.
7.2 “Almost integers” via truncated \(q\)-series¶
Choose \(d\in\{19,43,67,163\}\) and set \(\tau=(1+\sqrt{-d})/2\). Compute \(q=e^{2\pi i\tau}\) numerically and compare:
approximating \(j(\tau)\) by truncating its \(q\)-expansion. The gap shrinks dramatically as \(d\) increases, with \(d=163\) the most striking.
8. Common confusion: Heegner numbers vs Heegner points¶
Heegner numbers: the nine \(d\) for which \(\mathbb{Q}(\sqrt{-d})\) has class number \(1\).
Heegner points: CM points on modular curves / elliptic curves used in deep results about ranks of elliptic curves (e.g. Gross–Zagier and Kolyvagin).
They share the same complex multiplication background, but they are different objects.