Skip to content

Riemann zeta function ​

Also known as: zeta function.

The meromorphic function ζ(s) extending ∑ n⁻ˢ to all of ℂ ∖ {1}, linking prime numbers via its Euler product to zeros in the complex plane.

Diagram illustrating Riemann zeta function
Diagram illustrating Riemann zeta function.

Level 1 — First-Principles ​

For any real number s>1, add the reciprocals of all positive whole numbers raised to the power s:

ζ(s)=1+12s+13s+14s+…

For s=2, Euler proved this sum equals π2/6; for s=1, it becomes the harmonic sum and diverges to infinity. Allowing s to vary over the two-dimensional grid of real and imaginary coordinatescomplex plane, this unending sum of weighted reciprocalsinfinite series converges whenever Re(s)>1 and factors into an infinite product over all whole numbers above 1 that have no smaller divisorsprime number.

In 1859, Bernhard Riemann extended this formula to the entire plane (except a single pole at s=1) using the unique smooth extension of a complex function beyond where its original sum convergesanalytic continuation. That globally extended function is the Riemann zeta function. It vanishes at the negative even integers −2,−4,−6,…, which are called predictable negative-integer zeros forced by the symmetry equationtrivial zero. Every other zero lies inside the vertical band 0<Re(s)<1critical strip, and the Riemann Hypothesis states that every single one sits on the vertical line Re(s)=1/2critical line.

Limits of the intuition ​

Thinking of ζ(s) as the sum ∑n=1∞n−s works only to the right of Re(s)=1. Inside the band 0<Re(s)<1 and to the left of 0, the partial sums of n−s oscillate wildly or blow up. Computing ζ(s) there requires an alternative representation—such as the alternating Dirichlet eta formula (1−21−s)−1∑n=1∞(−1)n−1n−s for Re(s)>0 except where 21−s=1 (the isolated points s=1+2πikln⁡2 on Re(s)=1), or Riemann's Mellin-integral representation valid on all of C∖{1}.

Level 2 — Undergrad Bridge ​

For Re(s)>1, the zeta function admits both a Dirichlet series and an Euler product:

ζ(s)=∑n=1∞n−s=∏p(1−p−s)−1.

Multiplying by the archimedean gamma factor produces the completed zeta function

Λ(s)=π−s/2Γ(s/2)ζ(s),

which continues meromorphically to C with simple poles only at s=0 and s=1, and satisfies the functional equation

Λ(s)=Λ(1−s).

This symmetry pairs any zero ρ in 0<Re(s)<1 with 1−ρ (and conjugation pairs ρ with ρ―). For Re(s)≥1, the Euler product (and Hadamard–de la Vallée Poussin's boundary theorem on Re(s)=1) forces ζ(s)≠0. For Re(s)≤0, Λ(s)=Λ(1−s)≠0 (except for the pole at s=0 where ζ(0)=−1/2), so ζ(s) vanishes there precisely at the poles of Γ(s/2) with s≠0, namely s=−2,−4,−6,….

Because ζ(s) is also the Dirichlet L-function of the trivial character modulo 1, proving nonvanishing of all Dirichlet L-functions for Re(s)>1/2 immediately forces ζ(s)≠0 on 1/2<Re(s)<1, and functional-equation symmetry s↦1−s then rules out 0<Re(s)<1/2 as well.

Level 3 — Formal Lean Contract ​

In Mathlib4 (Mathlib.NumberTheory.LSeries.RiemannZeta), riemannZeta : ℂ → ℂ is defined via the Mellin transform of the Jacobi theta function and equals completedRiemannZeta s / Gammaℝ s away from s = 0 (with riemannZeta 0 = -1 / 2; s ≠ 1 is explicitly excluded in the hypothesis so the statement stays independent of Mathlib's total-function junk value at the simple pole s=1, even though Mathlib defines riemannZeta 1 to be nonzero via riemannZeta_one_ne_zero, making the guard redundant but harmless).

Stage 00 anchors this function in:

  • 00_statement/statements.lean#RiemannZetaZerosOnLine (upstream src/Statements.lean:7-8):
    lean
    def RiemannZetaZerosOnLine : Prop :=
      ∀ s : ℂ, riemannZeta s = 0 → (¬∃ n : ℕ, s = -2 * ((n : ℂ) + 1)) → s ≠ 1 → s.re = 1 / 2
  • 00_statement/main.lean#riemannZeta_eq_zero_re (upstream src/Main.lean:11-12), which witnesses RiemannZetaZerosOnLine directly from riemannHypothesis.

See the page's live verification banner (audit/verification-status.json) for the currently pinned upstream snapshot and local Lean build status (build_status: unverified-locally; entry static scan reports 0 forbidden tokens in solution files and 5 expected sorrys in root Challenge.lean).

Where this analogy breaks ​

Writing ζ(s)=1+2−s+3−s+… is valid only when Re(s)>1; substituting s=1/2+14.13i directly into the sum produces a divergent series rather than 0, so the equation ζ(s)=0 on the critical line applies strictly to the analytic continuation.

Formal Lean Anchors ​

def RiemannZetaZerosOnLine — Upstream source (src/Statements.lean L7-L8)

lean
def RiemannZetaZerosOnLine : Prop :=
  ∀ s : ℂ, riemannZeta s = 0 → (¬∃ n : ℕ, s = -2 * ((n : ℂ) + 1)) → s ≠ 1 → s.re = 1 / 2

theorem riemannZeta_eq_zero_re — Upstream source (src/Main.lean L11-L12)

lean
/-- Every zero of ζ other than the trivial zeros −2, −4, … (and the point 1) has real part 1/2. -/
theorem riemannZeta_eq_zero_re : RiemannZetaZerosOnLine := by
  sorry -- [EXTRACTED_STUB upstream=src/Main.lean:11-12 commit=41c2716658c42ba08eb0648994a2efe83082a95c body_lines=1 body_sha256=c7d55f018299eab5ea1f4aaf73850a06adcfb51ad7807e7bb9661a43e11f68eb]
  • prime number — A whole number greater than 1 whose only positive whole-number divisors are 1 and itself; every integer above 1 factors uniquely into a product of them.
  • infinite series — A limit of partial sums formed by adding infinitely many terms; in number theory, weighting terms by n⁻ˢ produces a Dirichlet series that turns integer arithmetic into a smooth function.
  • complex plane — The two-dimensional coordinate plane of numbers s = σ + it, where the horizontal coordinate σ = Re(s) sets decay rate and the vertical coordinate t = Im(s) sets oscillation frequency.
  • analytic continuation — The unique extension of a complex-differentiable function from a smaller region to a larger domain, locked in place by the identity theorem.
  • trivial zero — A zero at a non-positive integer forced purely by poles of the gamma factor in the functional equation, carrying no hidden information about prime fluctuations.
  • critical strip — The open vertical band 0 < Re(s) < 1 in the complex plane that contains every nontrivial zero of ζ(s) and of every Dirichlet L-function.
  • critical line — The vertical line Re(s) = 1/2 bisecting the critical strip—the axis of mirror symmetry s ↦ 1 − s where the Riemann Hypothesis asserts all nontrivial zeros lie.

Referenced By ​

Authoritative Sources ​

  • Ueber die Anzahl der Primzahlen unter einer gegebenen Grösse (paper) — B. Riemann, Monatsberichte der Königlichen Preussischen Akademie der Wissenschaften zu Berlin (November 1859), pp. 671–680.
  • The Theory of the Riemann Zeta-Function (book) — E. C. Titchmarsh, 2nd ed. (revised by D. R. Heath-Brown), Oxford University Press (1986), Chapters 1–2.
  • Mathlib4: riemannZeta (mathlib) — Mathlib.NumberTheory.LSeries.RiemannZeta (riemannZeta, RiemannHypothesis, pinned mathlib rev 31ce06eaadf4a200c0e1407c5f10953cf606b8f8).

Page Glossary ​

complex plane
The two-dimensional coordinate plane of numbers s = σ + it, where the horizontal coordinate σ = Re(s) sets decay rate and the vertical coordinate t = Im(s) sets oscillation frequency.
infinite series
A limit of partial sums formed by adding infinitely many terms; in number theory, weighting terms by n⁻ˢ produces a Dirichlet series that turns integer arithmetic into a smooth function.
prime number
A whole number greater than 1 whose only positive whole-number divisors are 1 and itself; every integer above 1 factors uniquely into a product of them.
analytic continuation
The unique extension of a complex-differentiable function from a smaller region to a larger domain, locked in place by the identity theorem.
trivial zero
A zero at a non-positive integer forced purely by poles of the gamma factor in the functional equation, carrying no hidden information about prime fluctuations.
critical strip
The open vertical band 0 < Re(s) < 1 in the complex plane that contains every nontrivial zero of ζ(s) and of every Dirichlet L-function.
critical line
The vertical line Re(s) = 1/2 bisecting the critical strip—the axis of mirror symmetry s ↦ 1 − s where the Riemann Hypothesis asserts all nontrivial zeros lie.