The Euler Product

Here is a sentence that sounds like it shouldn't be allowed: an infinite sum that adds up every single whole number is secretly identical to an infinite product that only ever looks at the prime numbers. Sums are about addition, spread across an endless, unstructured list; products are about multiplication, taken over a much sparser, much more special list — the primes, the atoms every number is built from. Nothing forces these two totally different machines to output the same number. And yet they do, always, exactly.

Leonhard Euler found this bridge in the 1730s, and it turned out to be one of the most productive single equations in the history of mathematics. It is the reason a smooth, continuous function of a real (later complex) variable can encode facts about primes — the discrete, jagged, unpredictable objects number theorists actually care about. Everything downstream, all the way to the Euler product for the zeta function and the whole field of analytic number theory, starts right here.

Three ways to say the same thing

It helps to hold the same fact in three different hands before diving into symbols:

The prototype

Consider the sum of 1/n^{s} over all positive integers (for s > 1, so the sum actually converges to a finite number). Euler's identity says this sum equals a product running over the primes only:

\sum_{n=1}^{\infty} \frac{1}{n^{s}} = \prod_{p \text{ prime}} \frac{1}{1 - p^{-s}}.

The left side is a sum over every number: 1, 2, 3, 4, 5, 6, … forever. The right side is a product over primes only: 2, 3, 5, 7, 11, … forever — a much thinner list, since most numbers aren't prime at all. That they land on the same value is one of the most consequential equations in mathematics: the function on either side is the multiplicative-function machinery meeting analysis for the first time, and it is later renamed and generalised as the Riemann zeta function.

Why it holds: factorisation in disguise

The proof is really just unique prime factorisation wearing an algebra costume. Expand each factor on the right as a geometric series,

\frac{1}{1 - p^{-s}} = 1 + p^{-s} + p^{-2s} + p^{-3s} + \cdots,

and imagine multiplying all of these series together, one per prime. Multiplying out picks one term — some power p^{-ks} — from each prime's series and multiplies them. A choice of "power a of 2, power b of 3, power c of 5, …" multiplies to exactly 1/n^{s} for the number n = 2^{a}3^{b}5^{c}\cdots. Because every whole number n has one and only one prime factorisation, every term 1/n^{s} is produced exactly once when you multiply everything out — no repeats, no gaps:

\prod_p \big(1 + p^{-s} + p^{-2s} + \cdots\big) = \sum_{n=1}^{\infty} \frac{1}{n^{s}}.

The Euler product is unique factorisation, rephrased as a statement about infinite series. If numbers could be built from primes in more than one way, the two sides simply wouldn't match.

Worked example: watching the identity build itself, prime by prime

Restrict attention to just the two primes 2 and 3, and take s = 2. The Euler factors multiply to an exact, tidy fraction:

\frac{1}{1 - 2^{-2}} \times \frac{1}{1 - 3^{-2}} = \frac{4}{3} \times \frac{9}{8} = \frac{3}{2}.

Expanding both geometric series and multiplying them out produces every term 1/n^{2} for n = 2^{a}3^{b} — the numbers 1, 2, 3, 4, 6, 8, 9, 12, 16, 18, 24, 27, 32, 36, \ldots — each appearing exactly once. Adding up their reciprocal squares should climb, term by term, towards that same 3/2:

1 + \tfrac{1}{4} + \tfrac{1}{9} + \tfrac{1}{16} + \tfrac{1}{36} + \tfrac{1}{64} + \tfrac{1}{81} + \tfrac{1}{144} + \cdots \;=\; 1,\ 1.25,\ 1.361,\ 1.424,\ 1.451,\ 1.467,\ 1.479,\ 1.486,\ \ldots \to \tfrac{3}{2}.

Keep adding 2-and-3-smooth terms and the running total creeps past 1.498 and keeps climbing — never overshooting, always heading for exactly 1.5. Nothing is approximate here except how far we've bothered to add: the sum and the product are the same infinite number, just reached by two completely different routes.

Throw in a third prime, 5, and the target itself moves — but predictably. The exact product is now \tfrac{4}{3} \times \tfrac{9}{8} \times \tfrac{25}{24} = \tfrac{25}{16} = 1.5625, and summing 1/n^2 over every number built only from 2s, 3s, and 5s — 1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 15, \ldots — climbs steadily towards that new value instead. Add a prime to the product, and a whole new column of numbers joins the sum to match it — always in perfect lockstep, because every number's factorisation only ever uses the primes that are actually available.

The same pattern works for any multiplicative function, not just the constant function 1. Take the divisor-counting function d(n) (how many divisors n has), which satisfies d(p^{k}) = k + 1. Its Euler factor at a prime is (1 + 2p^{-s} + 3p^{-2s} + \cdots) = (1 - p^{-s})^{-2}, so restricting again to p = 2, 3 at s = 2 gives an exact target of (4/3)^{2}(9/8)^{2} = 9/4 = 2.25. Summing d(n)/n^{2} over the same smooth numbers — d(1)/1 + d(2)/4 + d(3)/9 + d(4)/16 + \cdots = 1,\ 1.5,\ 1.722,\ 1.910,\ldots — climbs the same way, homing in on 2.25. Different function, same mechanism: unique factorisation lines the two sides up term for term.

A first stunning consequence: a new proof that primes never run out

Now push the identity to its edge. Set s = 1. The left side becomes the harmonic series \sum 1/n, which famously diverges — it grows without bound, however slowly. Since the two sides are forced to agree, the product over primes must diverge too. But a product of finitely many finite factors can never diverge to infinity — so there must be infinitely many primes feeding into that product. That is a brand-new, thoroughly analytic proof of a fact Euclid proved by pure logic two thousand years earlier — arrived at instead by watching an infinite sum refuse to settle down.

Pushed a little further (taking logarithms of both sides), the same idea shows that \sum_p 1/p — the sum of the reciprocals of the primes alone — also diverges. That is a much sharper statement than "there are infinitely many primes": it says the primes are packed densely enough that their reciprocals still add up to infinity, in stark contrast to, say, the perfect squares (\sum 1/n^{2} converges). This density estimate is the seed that eventually grows into the Prime Number Theorem.

It is tempting to chop both sides off after, say, one hundred terms and expect a hundred-term harmonic sum to exactly equal a product over the primes below one hundred. It doesn't — not quite. The worked example above shows the truthful picture: a truncated sum only creeps towards the exact value of a truncated product, closing the gap term by term but never quite arriving until every term is included. The Euler product is a statement about two infinite processes agreeing in the limit, not about any finite snapshot of either one matching the other on the nose.

There's a second, sharper subtlety hiding at s = 1. The theorem as stated requires s > 1, precisely so both sides converge to an actual number. At s = 1 that requirement fails — the harmonic series and the prime product both blow up to infinity. That's not a contradiction or a broken identity; it's the interesting case rather than the boring one. "Both sides diverge together" is itself the content of the new proof that primes are infinite — the identity is doing real work by failing to converge in exactly the way it does.

In 1735, a 28-year-old Euler had already stunned Europe by solving the Basel problem: proving that 1 + \tfrac14 + \tfrac19 + \tfrac{1}{16} + \cdots = \pi^{2}/6, a sum mathematicians had failed to pin down for nearly a century. Once he had that number nailed to \pi, it was a short step — for Euler, anyway — to notice the very same sum could be rearranged as a product over primes, purely from unique factorisation. Suddenly a question about primes was tangled up with a question about \pi and, eventually, about the whole machinery of calculus and complex analysis.

A century later, Riemann picked the same identity up, let s become a complex number, and realised the zeros of the resulting function encode the exact distribution of the primes. One innocent-looking equality — a sum equals a product — turned out to be the doorway between two subjects that, on the surface, have nothing to do with each other. That's the whole of analytic number theory, in miniature, starting from this one page.