Zeta My Grace…

On this regularly updated page, I will walk with you from the history to the mathematics of the Riemann zeta function, step by step and in simple terms.

From Finite Sums to Infinite Series

Let us start by summing all the numbers from 1 to 10, inclusive. We call this sum

\displaystyle S_{10} := 1 + 2 + \cdots + 10 .

We also represent it as

\displaystyle S_{10} = \sum_{n=1}^{10} n ,

where the symbol \sum , the capital Greek letter sigma, is a shorthand notation for a sum. We can clearly compute this sum, and it evaluates to 55. Since later we will deal with many terms, let us develop a simple technique. Because addition is a commutative operation, meaning 1 + 2 = 2 + 1 , we can rewrite the same sum as:

\displaystyle S_{10} = 10 + 9 + \cdots + 1.

If we add these two expressions term by term, we can pair the terms according to their positions. Each pair adds up to 11, and we have 10 such pairs, so:

\displaystyle 2 S_{10} = (1+10) + (2+9) + \cdots + (10+1) = 10 \times (10+1) = 110.

Hence, dividing by 2, we obtain S_{10} = 55 . The pattern now becomes clear. If we summed the numbers from 1 up to any N>1 , we would obtain

\displaystyle S_N = N \times (N+1)/ 2.

For instance, S_{100} = 100 \times 101 /2 = 5050 , and so on. Clearly, if we keep extending the sum all the way to infinity, the result will grow without bound, and summing all natural numbers would give infinity.

This clever summation trick is famously attributed to Carl Friedrich Gauss (1777–1855), who, according to a well-known anecdote, discovered it as a young schoolboy when asked to add the numbers from 1 to 100.

Now let us modify our sum in the following way. Instead of summing the numbers themselves, let us sum their corresponding reciprocal terms, and denote this by

\displaystyle H_{N} := \sum_{n=1}^N \frac{1}{n} = 1 + \frac{1}{2} + \frac{1}{3} + \cdots + \frac{1}{N} .

For instance, the numerical value of H_{10} is approximately 2.929, that is, H_{10} \approx 2.93 . Then let us extend the sum up to 100 terms. In that case we have H_{100} \approx 5.187 . What if we extend it up to 1000 terms, or even up to 10 000 terms? Here is the pattern:

H_{10} \approx 2.929 .
H_{100} \approx 5.187 .
H_{1000} \approx 7.48 .
H_{10000} \approx 9.78 .

It looks like we are converging to a number as we increase the number of terms being summed, doesn’t it? For instance, if we sum the first one million terms, we obtain about 14.397. It is obvious that each new term becomes smaller and smaller, but does the sum really converge?


Before we address this question, let us introduce an important mathematical operation called the logarithm.

Logarithm of a Number

If we multiply 2 by itself 5 times, we can write this in shorthand as

\displaystyle \underbrace{2 \times 2 \times \cdots \times 2}_{5 \text{ times}} = 2^5 = 32.

To recover the exponent 5 from the number 32, we use the inverse operation, which we denote by

\displaystyle \log_2 32 = 5.

This inverse operation is called a logarithm, and in this particular example it is the logarithm base 2. In general, an equation in the form b^x = y is equivalent to

\displaystyle \log_b y = x .

Long before logarithms were formally introduced, scholars in the medieval Arab world developed the algebraic foundations that later made such ideas possible. Mathematicians like al-Khwarizmi (c. 780–850) systematized algebra and applied it to practical fields like astronomy. Their work laid essential groundwork for later developments in Europe, including the invention of logarithms by John Napier in the early 17th century.

Now let us introduce the most important logarithm used in mathematics, called the natural logarithm. It is simply the logarithm whose base is the special number e \approx 2.71828 , which is called Euler’s number.

We denote it by \ln x := \log_e x. So, for example, \ln e = 1 and \ln e^5 = 5.

The natural logarithm plays a central role in calculus, growth processes, and as we will soon see, in understanding the behavior of the above series.

The constant e itself was first introduced by Jacob Bernoulli in 1683. However, it was Leonhard Euler (1707–1783) who later adopted the letter e for this constant, around 1727 or 1728. Euler is one of the most important intellectuals to emerge from bourgeois society. We will return to his contributions in much more detail later, especially when we discuss the Basel problem.

Now let us look at some numerical values of the natural logarithm.

\ln 10 \approx 2.3 .
\ln 100 \approx 4.6 .
\ln 1000 \approx 6.9 .
\ln 10000 \approx 9.2 .

If we compare these values with the earlier results for H_N , a striking similarity appears. To make this clearer, let us look at the difference \gamma_N := H_N - \ln N for certain values of N . Here are the results:

N=10, \quad \gamma_N \approx 0.6264
N=100, \quad \gamma_N \approx 0.5818
N=1000, \quad \gamma_N \approx 0.5772
N=10000, \quad \gamma_N \approx 0.5767
N=100000, \quad \gamma_N \approx 0.5771
N=1000000, \quad \gamma_N \approx 0.5772

The pattern is convincing: as N goes to infinity, the quantity \gamma_N appears to approach a constant value. This constant is called the Euler–Mascheroni constant, denoted by \gamma . Since we cannot set N equal to infinity, we instead talk about approaching infinity. We express this behavior as

\displaystyle \lim_{N \to \infty} (H_N - \ln N) = \gamma \approx 0.57721 .

We will return to the meaning of this “limit” operation in more detail later.

It was Lorenzo Mascheroni who corrected Euler’s initial approximation of \gamma  and attempted to calculate the constant to 32 decimal places.

This shows that the infinite sum is essentially equal to the logarithm of N (up to the Euler–Mascheroni constant). And if we recall the definition of the logarithm, although it grows very slowly, the logarithm of a number increases without bound. Therefore, the answer to our question is that H_N does not converge as we increase the number of terms.

So we conclude that even though each new term becomes extremely small, the overall sum still does not converge. This naturally leads us to ask the following question: does every sum involving infinitely many terms always diverge?

Bassel Problem

To explore our new question, let us modify our sum further and define

\displaystyle Z_N := \sum_{n=1}^{N} \frac{1}{n^2} = 1 + \frac{1}{4} + \frac{1}{9} + \cdots + \frac{1}{N^2}.

So in this case we are summing the squares of the reciprocals of the numbers from 1 up to N . Here are the results:

Z_{10} \approx 1.5498
Z_{100} \approx 1.6340
Z_{1000} \approx 1.6439
Z_{10000} \approx 1.6448

It seems we have finally reached a convergent infinite sum. But what exact number does it converge to?

The problem was first posed in 1650 by the Italian mathematician Pietro Mengoli. Later, the Bernoulli brothers, especially Jacob Bernoulli, in Basel helped popularize it across Europe. They showed that the series converges but were unable to determine its exact value. The Basel problem soon became well known, and many leading mathematicians attempted to solve it, yet none could find the precise sum—until Euler.

Before we go further and present Euler’s famous proof, we need to introduce a few basic terms.

Polynomial

A polynomial is an expression built using addition, subtraction, multiplication, and powers of x with nonnegative integer exponents, and it contains only finitely many terms. For example,

\displaystyle 1 + 2x^2, \qquad 3x + 2x^4 - x^5.

are polynomials, whereas \sin(x) is not.

Here x may simply be treated as a symbol.

Function

A function is a rule that assigns to each element of a set X exactly one element of a set Y . The set X is called the domain, and the set Y is called the codomain. We write this as

\displaystyle f : X \to Y.

For example, consider the set X := \{1, 2, 3 \} , and the set Y := \{1, 4, 9 \} . We can map each element of X to an element of Y by taking its square: f(x) := x^2. Indeed,

f(1) = 1^2 = 1,
f(2) = 2^2 = 4,
f(3) = 3^2 = 9.

If we interpret a polynomial as a rule that takes a numerical input and produces a numerical output, it becomes a polynomial function. For instance, treating x as a variable, the polynomial \displaystyle 1 + 2x^2 defines the function

f(x) := 1 + 2x^2.

Limit

Sometimes a function is not defined at a certain point, but still makes sense as we get close to that point. For instance, consider

\displaystyle f(x) := \frac{\sin x}{x}.

At x = 0 , this becomes 0/0 , which is undefined. However, if we choose a small value such as x = 0.1 , we find f(0.1) \approx 0.998334 , and f(0.01) \approx 0.999983 for x = 0.01 , and so on. This suggests that the function approaches the value 1 as x approaches 0.

Similarly, if we look at the function ( \cos x - 1 )/x, we observe that it approaches to zero as x \to 0, and the function \cos( \pi x /2)/(1-x) approaches to \pi/2, as x \to 1. All these facts can be shown using the classical geometric arguments on the unit circle.

These behaviors are described using limits, written as

\displaystyle \lim_{x \to 0} \frac{\sin x}{x} =1 , \qquad \lim_{x \to 0} \frac{\cos x - 1}{x} =0, \qquad \lim_{x \to 1} \frac{\cos (\pi x /2)}{1-x} =\frac{\pi}{2}\,.

Of course, when a function behaves nicely at a given point, its limit at that point is simply its value there. For example, as x goes to 3, the function x^2 takes the value 3^2, so

\displaystyle \lim_{x \to 3} x^2 = 3^2 = 9.

Derivative

A derivative measures how sensitively a function changes when its input changes. Formally, it is defined as

\displaystyle f'(x) := \lim_{h \to 0} \frac{f(x+h) - f(x)}{h}.

For example, if f(x) := x^2 , then

\displaystyle f'(x) = \lim_{h \to 0} \frac{(x+h)^2 - x^2}{h} = \lim_{h \to 0} \frac{x^2 + 2xh + h^2 - x^2}{h} = \lim_{h \to 0} (2x + h) = 2x .

Similarly, the derivative of x^3 is 3x^2 . In fact, for any function of the form f(x) := x^n with n \ge 1 , the general rule is \displaystyle f'(x) = n \, x^{n-1}. In addition, the derivative of any constant is zero, since a constant does not change when x changes.

Now let us consider the derivative of the trigonometric function f(x):= \sin x . Using the identity

\sin(x+h) = \sin x \cos h + \cos x \sin h,

we compute

\displaystyle f'(x) = \lim_{h \to 0} \frac{\sin(x+h) - \sin x}{h} ,

which reads

\displaystyle f'(x)= \lim_{h \to 0} \frac{\sin x(\cos h - 1)}{h} + \lim_{h \to 0}  \frac{\cos x \sin h}{h} = 0 \cdot \sin x + 1 \cdot \cos x = \cos x,

where we use the two previously mentioned facts: \sin h/ h \to 1 and ( \cos h - 1)/h \to 0 as h \to 0 .

Thus: \displaystyle f'(x) = \cos x. In a similar way, one can show that the derivative of \cos x is - sin x.

The ideas behind limits and derivatives took shape gradually. In the 17th century, Isaac Newton and Gottfried Wilhelm Leibniz independently developed calculus, introducing the derivative as a precise way to describe instantaneous change. Their work formalized methods earlier hinted at by ancient Greek mathematicians such as Archimedes, who used limiting processes to approximate areas and volumes. The modern definition of a limit, however, was not fully clarified until the 19th century by Augustin-Louis Cauchy and Karl Weierstrass, who gave calculus its rigorous foundations.

To demonstrate how Euler approached the Basel problem, let us first look at a polynomial function:

\displaystyle f(x) := a + b x + c x^2 + d x^3.

How can we identify the coefficients a, b, c, d from the function itself? For example, evaluating at x = 0 immediately gives f(0) = a. What about b ?

We take the derivative: f'(x) = b + 2cx + 3dx^2, so f'(0) = b.

Next, f''(x) = 2c + 6dx, \quad f''(0) = 2c, and f'''(x) = 6d, \quad f'''(0) = 6d.

Thus we can write

\displaystyle f(x) = f(0) + f'(0) x + \frac{f''(0)}{2} x^2 + \frac{f'''(0)}{6} x^3.

This is the Maclaurin series of the function. The key idea is that the coefficients are determined by the derivatives at zero. This idea allows us to express even non-polynomial functions using an “infinite polynomial”.

Let us apply this idea to f(x) : = \sin x . We need its derivatives at zero. The fist derivative is f'(x) = \cos x, and the next derivative is f''(x) = -\sin x.

Then, \displaystyle f'''(x) = -\cos x. Next, \displaystyle f^{(4)}(x) = \sin x,

and the pattern repeats.

Evaluate at x = 0 :

f(0) = \sin 0 = 0
f'(0) = \cos 0 = 1
f''(0) = -\sin 0 = 0
f'''(0) = -\cos 0 = -1
f^{(4)}(0) = \sin 0 = 0 , and so on.

Now insert these into the Maclaurin formula:

\displaystyle \sin(x) = x - \frac{x^3}{6} + \frac{x^5}{120} - \cdots.

So we have managed to write a non-polynomial function in a form that looks almost like a polynomial. However, the price we pay is that it contains infinitely many terms.

Euler’s Elegant Solution

Let us now recall another important feature of polynomials. Consider the polynomial

\displaystyle 2 - 3x + x^2.

We can rewrite it as (1- x)(2 - x).

Similarly,

\displaystyle  4   - 4x - x^2 + x^3 = (1 -x)(2 - x)(2 + x).

Why is this factorization useful? Because it reveals the zeros (or roots) of the corresponding polynomial function: in the latter case, 1 , 2 , and -2 . These are exactly the values of x for which the function becomes zero.

Of course, it is not always easy to factor a polynomial just by looking at it. But the nice thing is that the process also works in reverse: if we already know the zeros of a polynomial, then we can immediately write down its factorization. Fortunately, there are several methods for finding the zeros (or roots) of a polynomial.

For example, suppose we know that a certain polynomial has zeros at x = 1, x = -1, and x = 5. Then the polynomial must contain the factors

(x-1)(x+1)(x-5) = x^3 - 5x^2 -x +5.

But there is an important point: we may multiply all of this by any non-zero constant, and the zeros will not change. Therefore, when we go in the reverse direction, we can introduce an additional constant, say A. In essence,

(x-1)(x+1)(x-5) and A(x-1)(x+1)(x-5)

have the same zeros, even though they are not the same polynomial.

This leads to a natural question: Can we write a non-polynomial function such as \sin x in a similar factored form?

If we know all the zeros, the answer is yes. We already know that \sin 0 = 0 . Since \sin x is a periodic function, we also have

\displaystyle \sin(\pi) = 0,
\displaystyle \sin(-\pi) = 0,
\displaystyle \sin(2\pi) = 0,
\displaystyle \sin(-2\pi) = 0, and so on.

Thus the zeros of \sin x are all integer multiples of \pi , positive and negative, including zero.

So we might guess that \sin x can be written as an infinite product over its zeros:

\displaystyle \sin x = A \, (0 - x)\, (-\pi - x)\, (\pi - x)\, (-2\pi - x)\, (2\pi - x)\cdots

for some constant A . We introduce A because multiplying a function by a constant does not change its zeros, as we discussed, and we determine its value later.

Let us expand each factor slightly:

\displaystyle (-\pi - x) = -\pi\left(1 + \frac{x}{\pi}\right), \qquad (\pi - x) = \pi\left(1 - \frac{x}{\pi}\right),

\displaystyle (-2\pi - x) = -2\pi\left(1 + \frac{x}{2\pi}\right), \qquad (2\pi - x) = 2\pi\left(1 - \frac{x}{2\pi}\right),

and so on.

Thus the entire product becomes

\displaystyle \sin x = A \,(-1) \, x \, (-\pi)\left(1 + \frac{x}{\pi}\right)\, (\pi)\left(1 - \frac{x}{\pi}\right)\, (-2\pi)\left(1 + \frac{x}{2\pi}\right)\, (2\pi)\left(1 - \frac{x}{2\pi}\right) \cdots

Group the constant factors together:

\displaystyle \sin x = A\,(-1)(-\pi)(\pi)(-2\pi)(2\pi)\cdots \,  x \,  \left(1 + \frac{x}{\pi}\right)\left(1 - \frac{x}{\pi}\right) \left(1 + \frac{x}{2\pi}\right)\left(1 - \frac{x}{2\pi}\right) \cdots

Now use the identity (a + b)(a - b) = a^2 - b^2 to simplify each pair:

\displaystyle \left(1 + \frac{x}{\pi}\right)\left(1 - \frac{x}{\pi}\right) = 1 - \frac{x^2}{\pi^2},

\displaystyle \left(1 + \frac{x}{2\pi}\right)\left(1 - \frac{x}{2\pi}\right) = 1 - \frac{x^2}{(2\pi)^2},

and so on.

Let us also absorb all constant factors into a single constant:

\displaystyle B := A \, (-1)(-\pi)(\pi)(-2\pi)(2\pi)\cdots.

Then

\displaystyle \sin x = B\, x \, \left(1 - \frac{x^2}{\pi^2}\right)\left(1 - \frac{x^2}{(2\pi)^2}\right)\left(1 - \frac{x^2}{(3\pi)^2}\right)\cdots.

Divide both sides by x :

\displaystyle \frac{\sin x}{x} = B\, \prod_{n=1}^{\infty} \left(1 - \frac{x^2}{n^2\pi^2}\right).

Here, we introduce a shorthand notation for an infinite product. Just as the symbol \sum denotes a sum over many terms, the symbol \prod (the Greek capital letter Pi) denotes a product over many terms.

Now, we already know that

\displaystyle \lim_{x\to 0} \frac{\sin x}{x} = 1.

Taking the limit of the both sides as x \to 0 gives

\displaystyle 1 = B \cdot (1)(1)(1)\cdots,

so we conclude: B = 1.

Thus Euler’s infinite product for the sine function is

\displaystyle \frac{\sin x}{x} =  \prod_{n=1}^{\infty} \left(1 - \frac{x^2}{n^2\pi^2}\right).

If we multiply all of these factors together, the coefficient of x^2 comes from choosing the \displaystyle -\frac{x^2}{n^2\pi^2} term from exactly one of the factors and the constant term 1 from all the others. Namely, consider the first three terms

\displaystyle  \prod_{n=1}^3 \left(1 - \frac{x^2}{n^2\pi^2}\right) = \left(1 - \frac{x^2}{\pi^2}\right)\left(1 - \frac{x^2}{2^2\pi^2}\right)\left(1 - \frac{x^2}{3^2\pi^2}\right) =  \left(1 - \frac{x^2}{\pi^2}- \frac{x^2}{2^2\pi^2} +  \frac{x^4}{2^2\pi^4} \right)\left(1 - \frac{x^2}{3^2\pi^2}\right)

\displaystyle  \prod_{n=1}^3 \left(1 - \frac{x^2}{n^2\pi^2}\right)  =  \left(1 - \frac{x^2}{\pi^2}- \frac{x^2}{2^2\pi^2} - \frac{x^2}{3^2\pi^2} +  \frac{x^4}{2^2\pi^4} +  \left(  \frac{x^2}{3^2\pi^2} \right) \left(  \frac{x^2}{\pi^2}+ \frac{x^2}{2^2\pi^2} - \frac{x^4}{2^2\pi^4} \right) \right)

\displaystyle  \prod_{n=1}^3 \left(1 - \frac{x^2}{n^2\pi^2}\right)  =  \left(1 - \sum_{n=1}^3 \frac{1}{n^2 \pi^2} x^2 + () x^4 + () x^6  \right).

Therefore, the total coefficient of x^2 in the product is \displaystyle - \sum_{n=1}^3 \frac{1}{n^2 \pi^2}.

Thus, in the infinite product, we get

\displaystyle \frac{\sin x}{x} = 1 - \left(\sum_{n=1}^{\infty} \frac{1}{n^2 \pi^2}\right) x^2 + \cdots.

Now let us compare this with the Maclaurin series of \sin x . We already know that

\displaystyle \sin x = x - \frac{x^3}{6} + \frac{x^5}{120} - \cdots

and hence

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

Now we have two different expressions for \displaystyle \frac{\sin x}{x} :

From the infinite product:
\displaystyle \frac{\sin x}{x} = 1 - \left(\sum_{n=1}^{\infty} \frac{1}{n^2 \pi^2}\right) x^2 + \cdots

From the Maclaurin series:
\displaystyle \frac{\sin x}{x} = 1 - \frac{x^2}{6} + \cdots

Since these are two different ways of writing the same function, their coefficients must agree.
In particular, the coefficients of x^2 must be equal:

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

So we obtain

\displaystyle \sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{\pi^2}{6}\approx 1.644934\ldots

This is exactly the solution of the Basel problem: One of the most beautiful connections between infinite series and geometry (the number \pi ) in all of mathematics.

In a similar way, by comparing the Maclaurin series of \sin x / x with its infinite product representation, we can also compute

\displaystyle \sum_{n=1}^{\infty} \frac{1}{n^4} = \frac{\pi^4}{90}.

This shows that Euler’s method not only solves the Basel problem but also reveals a deep pattern connecting even powers of reciprocals to corresponding powers of \pi .

Euler’s solution to the Basel problem was so striking that it immediately made him a mathematical celebrity across Europe. His proof was unlike anything mathematicians had seen before—ingenious, daring, and unexpectedly effective. In the centuries that followed, the identity became one of the most frequently rediscovered results in mathematics. Dozens of new proofs were later found, using Fourier series, complex analysis, geometric methods, Parseval’s identity, and even probabilistic techniques. Each proof illuminates a different part of mathematics, and the Basel problem remains a classic example of how profound ideas can emerge from a deceptively simple infinite sum.

The Riemann Zeta Function

Now we are ready to introduce one of the most graceful functions in mathematics: the Riemann zeta function. So far, we have explored several infinite series, such as

\displaystyle S = \sum_{n=1}^\infty n, \quad H = \sum_{n=1}^\infty \frac{1}{n}, \quad \text{and } Z = \sum_{n=1}^\infty \frac{1}{n^2}.

These are all special cases of a single, more general function: the Riemann zeta function, denoted by

\displaystyle \zeta(s) := \sum_{n=1}^\infty \frac{1}{n^s}.

With this definition we see that \zeta(-1) = S, \zeta(1) = H, and \zeta(2) = Z.

This naturally leads to a new question: what happens if we choose other values for s ? For instance, what does the series mean when s = 1.3 , or s = -2 or even s = \sqrt{-3} ?

After solving the Basel problem, Euler began investigating the more general series \sum_{n=1}^\infty \frac{1}{n^s}  for other values of s > 1 . In doing so, he discovered extraordinary formulas linking these sums to the prime numbers, revealing structures that later became the foundations of analytic number theory.

More than a century later, in 1859, Bernhard Riemann, one of the greatest mathematicians in history, transformed the subject. In his eight-page paper Über die Anzahl der Primzahlen unter einer gegebenen Grösse (“On the Number of Primes Less Than a Given Magnitude”), he extended this series to complex values of s , introduced analytic continuation, discovered the functional equation, and revealed a deep connection between the zeros of \zeta(s) and the distribution of prime numbers.

Riemann’s brief paper ended with a quiet remark about the location of these nontrivial zeros—a conjecture now known as the Riemann Hypothesis, widely regarded as the most important unsolved problem in mathematics.