Skip to content

11.1 — Euler

Leonhard Euler published more mathematics than anyone in history — around 900 works, filling more than 80 volumes in the collected edition that is still not finished. He wrote at a rate of about 800 pages a year for decades. For the last seventeen years of his life he was almost completely blind, and he produced roughly half his output during that period, dictating to assistants from memory.

His name is attached to more notation, theorems and constants than anyone else's, which created a problem: the mathematician Pierre-Simon Laplace's advice to young mathematicians was "read Euler, read Euler, he is the master of us all", and the convention of naming results after the second person to discover them exists partly because otherwise everything would be called Euler's theorem.

Portrait of Leonhard Euler
Leonhard Euler (1707–1783). Painted with the drooping right eyelid that followed the fever and near-blindness of 1738. He lost the use of the other eye to a cataract in 1766 and said only, "Now I will have fewer distractions." Image: Wikimedia Commons.

1. The notation you use is his

Before Euler, mathematics was written in prose and ad-hoc symbols. Much of the notation that makes modern mathematics readable is his personal invention:

  • f(x) for a function.
  • e for the base of natural logarithms.
  • i for \sqrt{-1}.
  • \sum for a sum.
  • \pi popularised as the circle constant (William Jones used it first, Euler made it universal).
  • \sin, \cos, \tan as abbreviations.
  • \Delta for a finite difference.

Every one of those appears in this volume, and it is worth noticing how much of the difficulty of reading old mathematics comes from not having them. Notation is not decoration; a good symbol is a compressed idea, and Euler was the best notation designer who ever lived.

2. The Basel problem

In 1644 Pietro Mengoli asked for the exact value of

1 + \frac14+\frac19+\frac{1}{16}+\cdots = \sum_{n=1}^{\infty}\frac{1}{n^2}

Chapter 5.8 noted this converges, unlike the harmonic series. To what? Numerically it approaches about 1.6449, and nobody could identify the number. The Bernoulli brothers, among the finest mathematicians in Europe, worked on it for decades and failed.

In 1735 the 28-year-old Euler announced:

\sum_{n=1}^{\infty}\frac{1}{n^2} = \frac{\pi^2}{6}

A sum of reciprocals of squares producing \pi, with no circle anywhere in the question. It made him famous across Europe immediately.

His argument was audacious and, as originally given, not rigorous. He reasoned by analogy. A polynomial with roots r_1,r_2,\ldots factors as a product of terms (1-x/r_i). Euler treated \frac{\sin x}{x} as if it were an infinite polynomial, and its roots are at x = \pm\pi,\pm2\pi,\pm3\pi,\ldots, so:

\frac{\sin x}{x} = \left(1-\frac{x^2}{\pi^2}\right)\left(1-\frac{x^2}{4\pi^2}\right)\left(1-\frac{x^2}{9\pi^2}\right)\cdots

Expand the product and collect the x^2 terms. Compare with the Taylor series \frac{\sin x}{x} = 1 - \frac{x^2}{6}+\cdots from Chapter 5.8. Matching coefficients:

-\frac16 = -\frac{1}{\pi^2}\left(1+\frac14+\frac19+\cdots\right)

Multiply through by -\pi^2 and there it is.

Treating an infinite series as a polynomial with infinitely many roots was completely unjustified at the time. Nobody had shown such a factorisation was valid. Euler knew this, checked his answer numerically to twenty decimal places, saw it agreed, and published. A rigorous proof came a century later, and it confirmed him.

That combination — bold formal manipulation, checked ruthlessly against computation — is characteristically Euler's method. He was very rarely wrong, and where he was, the results were interesting anyway.

3. Euler's identity

e^{i\pi}+1 = 0

Chapter 5.8 derived it from the series. Chapter 2.5 explained it geometrically as a half-turn.

It is routinely voted the most beautiful equation in mathematics, and a 2014 brain-imaging study found that mathematicians viewing it showed activity in the same emotional regions that respond to great music and art.

What makes it worth the praise is not mysticism but unification. e came from continuous growth (Chapter 1.4). \pi came from circles (Chapter 3.3). i came from an impossible square root (Chapter 2.5). Three constants from three unrelated corners of mathematics, and the identity says they were always the same subject. Growth in an imaginary direction is rotation, and half a rotation is -1.

4. The Königsberg bridges

Chapter 8.6 tells the story. Euler's 1736 solution founded graph theory and, by throwing away every geometric property except connectivity, opened the way to topology.

The paper's most important sentence is almost an aside: he notes that the problem "has nothing to do with measurement", which was a genuinely new kind of mathematics. Everything before it had been about quantity or magnitude.

5. The polyhedron formula

V - E + F = 2

Chapter 3.6 covered it. Euler found it in 1750 and could not prove it satisfactorily; Cauchy gave the first proof in 1811.

Its significance emerged much later. The number 2 is a topological invariant — it does not change when the shape is deformed, and it changes only when the number of holes changes. This is the seed of algebraic topology, an entire modern field devoted to attaching numbers to shapes in ways that survive deformation.

6. Number theory

Euler's totient function \varphi(n) counts how many numbers below n share no factor with it. Euler's theorem generalises Fermat's little theorem from Chapter 1.6:

a^{\varphi(n)}\equiv1\pmod n \quad\text{when } a \text{ and } n \text{ share no factor}

This is the mathematical core of RSA encryption. The decryption exponent works because of this theorem, and Volume I, 8.2 works through the arithmetic. Euler proved it in 1763; it secured the internet from 1977. Two hundred and fourteen years between the mathematics and the application, and nobody in 1763 could have imagined it.

The Euler product formula connects primes to analysis:

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

A sum over all integers equals a product over all primes. The bridge is the Fundamental Theorem of Arithmetic from Chapter 1.5: every integer factors uniquely into primes, so expanding the product generates every integer exactly once.

This identity founded analytic number theory, the use of calculus to study whole numbers, and the function on the left is the Riemann zeta function of Chapter 11.4.

Euler also gave a new proof that there are infinitely many primes: the harmonic series diverges (Chapter 5.8), and by the product formula that requires infinitely many primes. Divergence of an infinite sum, proving a fact about whole numbers. Nobody had connected those worlds before.

7. The rest of it

Mechanics, rewritten in the language of calculus rather than Newton's geometry, which is why physics is now taught with equations rather than diagrams.

Fluid dynamics. The Euler equations describe inviscid flow, and adding viscosity gives the Navier–Stokes equations of Chapter 11.4.

Rigid body rotation. Euler angles are still how a spacecraft's or aircraft's orientation is specified, and their failure mode — gimbal lock — is why Chapter 2.5's quaternions exist.

The calculus of variations, with Lagrange: finding the function that minimises a quantity rather than the point. This became the foundation of theoretical physics, since almost every physical law can be stated as "nature minimises something".

The number e, named and studied by him. Euler's constant \gamma \approx 0.5772, the gap between the harmonic series and the natural logarithm, whose irrationality is still unknown.

Music theory, ship design, artillery ballistics, insurance mathematics, lotteries, and the Latin squares that became Sudoku.

8. The man

Born in Basel in 1707, son of a pastor, taught by Johann Bernoulli who spotted him immediately. Recruited to the St Petersburg Academy at 20, moved to Berlin under Frederick the Great, then back to St Petersburg under Catherine the Great — Frederick found him socially dull and mocked him as a "mathematical Cyclops" after he lost the sight in one eye.

Thirteen children, of whom five survived to adulthood. Contemporaries record that he worked with a child on his knee and others playing at his feet, and that it did not slow him down. Deeply religious throughout, and unbothered by the fashionable atheism of Frederick's court.

Blind from 1766. His output increased. He had committed the entire Aeneid to memory and could state which line began each page of his copy, and he did mathematics of enormous complexity in his head, dictating results to his sons and assistants.

He died in 1783, aged 76, after a day spent calculating the orbit of the newly discovered Uranus and discussing it over tea. The eulogy said he "ceased to calculate and to live".

The Euler Archive is still publishing his work. Papers he wrote before 1783 continued to appear in the St Petersburg Academy's journal for another fifty years, and the backlog was that large.


Euler was the most prolific. The next was the most exacting — a man who published almost nothing unless it was perfect, and whose unpublished notebooks contained decades of other people's later discoveries.

Every formula above, built from scratch

None of the results in this chapter are worth memorising, because each one can be rebuilt in under a minute from something simpler. What follows is that rebuilding, one result at a time, so the formula and the reason for it sit on the same page as the explanation that needed them.

Euler's identity

e^{i\pi}+1 = 0

Where it comes from. It is Euler's formula at one particular angle. From 5.3 — rules of differentiation, obtained by putting i\theta into the exponential series and sorting the terms by whether they carry an i:

e^{i\theta} = \cos\theta+i\sin\theta

Set \theta = \pi. Then \cos\pi = -1 and \sin\pi = 0:

e^{i\pi} = -1+i(0) = -1

Add 1 to both sides.

Why people find it moving. Five constants that arrived in mathematics from five unrelated directions — e from compound interest, i from solving cubics, \pi from circles, and 1 and 0 from counting — turn out to satisfy one short relation. Nobody designed this. It is what happens when the definitions are followed honestly.

What it actually says, stripped of the mysticism: rotating by half a turn takes you to the opposite side. e^{i\theta} is the instruction "rotate by \theta", and half a turn from 1 lands on -1. Read that way it is almost obvious, and the surprise is that the exponential function should have anything to do with rotation at all — which is the real content, and it comes from the series.

The Basel problem

\sum_{n=1}^\infty\frac{1}{n^2} = 1+\frac14+\frac19+\frac{1}{16}+\cdots = \frac{\pi^2}{6}

Posed in 1650, unsolved for 85 years, and cracked by the 28-year-old Euler in 1735. The answer astonished everyone: a sum of reciprocal squares, with nothing circular anywhere in sight, produces \pi.

Euler's original argument, which is bold and not quite legal. He knew the series for sine:

\sin x = x - \frac{x^3}{3!}+\frac{x^5}{5!}-\cdots

Divide by x:

\frac{\sin x}{x} = 1 - \frac{x^2}{6}+\frac{x^4}{120}-\cdots

Now the leap. A polynomial with roots r_1, r_2, \ldots and value 1 at zero can be written as a product of factors:

\left(1-\frac{x}{r_1}\right)\left(1-\frac{x}{r_2}\right)\cdots

Euler assumed this works for the infinite series too. The roots of \frac{\sin x}{x} are where \sin x = 0 apart from x=0 itself, namely \pm\pi, \pm2\pi, \pm3\pi,\ldots Pairing each root with its negative:

\frac{\sin x}{x} = \left(1-\frac{x^2}{\pi^2}\right)\left(1-\frac{x^2}{4\pi^2}\right)\left(1-\frac{x^2}{9\pi^2}\right)\cdots

Now multiply out and collect the x^2 terms. Each bracket contributes its own -\frac{x^2}{n^2\pi^2} while all the others contribute their 1:

\text{coefficient of } x^2 = -\frac{1}{\pi^2}\left(1+\frac14+\frac19+\cdots\right)

Compare with the series, where the x^2 coefficient is -\frac16:

-\frac{1}{\pi^2}\sum\frac{1}{n^2} = -\frac16 \quad \Rightarrow \quad \sum\frac{1}{n^2} = \frac{\pi^2}{6}

Why this was audacious. Euler assumed an infinite series factorises like a polynomial, which is not automatically true — an infinite product can converge to the wrong thing, or not converge at all. He checked his answer numerically to many decimal places before publishing, and rigorous proofs came a century later. 9.P gives one of them, from Parseval's theorem applied to a sawtooth.

The general result, which Euler also found:

\sum\frac{1}{n^4} = \frac{\pi^4}{90}, \qquad \sum\frac{1}{n^6} = \frac{\pi^6}{945}

Every even power has a clean answer involving \pi. No odd power does. \sum\frac{1}{n^3} was only proved irrational in 1978, and almost nothing else is known about it — a gap that has resisted three hundred years of attention.

The Euler product

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

Read it aloud. "The sum over all whole numbers of one over n to the s equals the product, over all primes, of one over one minus p to the minus s."

Where it comes from. Expand each factor on the right as a geometric series, using \frac{1}{1-r} = 1+r+r^2+\cdots from 2.2 — polynomials:

\frac{1}{1-2^{-s}} = 1+\frac{1}{2^s}+\frac{1}{4^s}+\frac{1}{8^s}+\cdots

\frac{1}{1-3^{-s}} = 1+\frac{1}{3^s}+\frac{1}{9^s}+\cdots

Now multiply all these together. Picking one term from each bracket and multiplying gives \frac{1}{(2^a3^b5^c\cdots)^s} — and by unique factorisation, every whole number arises from exactly one such choice. So the product expands into the sum \sum\frac{1}{n^s}, each term appearing exactly once.

What it means. The left side knows about addition; the right side knows about multiplication and primes. This identity is the bridge, and it is why questions about how primes are distributed become questions about a function of a complex variable. Every result in analytic number theory since 1737 goes through it.

One immediate consequence. Put s=1. The left side is the harmonic series, which diverges — proved in 8.5 — combinatorics and recurrences. So the right side must diverge too, which requires infinitely many primes. A new proof that the primes never run out, two thousand years after Euclid's, and this one also shows they are common enough that \sum\frac1p itself diverges.

Euler's polyhedron formula

V-E+F = 2

Derived in 8.6 — graph theory for planar graphs; for a solid, project it onto a sphere and flatten. Every convex polyhedron obeys it: a cube has 8-12+6 = 2, a tetrahedron 4-6+4=2, a football 60-90+32=2.

The consequence Plato would have wanted. Combine it with the handshake lemma and you can prove there are exactly five regular solids and no more. Suppose each face has p sides and each vertex meets q faces. Counting edges two ways gives pF = 2E and qV = 2E. Substituting into Euler's formula:

\frac{2E}{q}-E+\frac{2E}{p} = 2 \quad \Rightarrow \quad \frac1p+\frac1q = \frac12+\frac1E

Since E>0, we need \frac1p+\frac1q>\frac12, and both p,q\ge3. The only whole-number solutions are (3,3), (3,4), (4,3), (3,5), (5,3) — the tetrahedron, octahedron, cube, icosahedron and dodecahedron. Five, and the arithmetic says there can never be a sixth.

Euler's theorem and RSA

a^{\phi(n)}\equiv1\pmod n \qquad \text{when } \gcd(a,n)=1

Proved in 1.6 — modular arithmetic. Published in 1763; used to secure the internet from 1977.

How RSA uses it. Pick two large primes p and q and let n = pq, so that \phi(n) = (p-1)(q-1). Choose e sharing no factor with \phi(n), and find d with

ed\equiv1\pmod{\phi(n)}

Encryption is c = m^e\bmod n and decryption is m = c^d\bmod n. Why decryption works:

c^d = \left(m^e\right)^d = m^{ed} = m^{1+k\phi(n)} = m\cdot\left(m^{\phi(n)}\right)^k \equiv m\cdot1^k = m\pmod n

The whole scheme is Euler's theorem plus the fact that factoring n is hard while multiplying p and q is easy. Euler had no idea; the theorem sat unused for 214 years.