
Plus Advent Calendar Door #6: The prime number theorem
The prime numbers are those integers that can only be divided by themselves and 1. The first seven are

This is an illustration of the sieve of Eratosthenes, which is designed to catch prime numbers. You can find out more about the sieve here. Adapted from a figure by SKopp, CC BY-SA 3.0.
Every other positive integer can be written as a product of prime numbers in a unique way — for example
We have known for thousands of years that there are infinitely many prime numbers (see here for a proof), but there isn't a simple formula which tells us what they all are. Powerful computer algorithms have enabled us to find larger and larger primes, but we will never be able to write down all of them.
The prime number theorem tells us something about how the prime numbers are distributed among the other integers. It attempts to answer the question "given a positive integer
The prime number theorem doesn't answer this question precisely, but instead gives an approximation. Loosely speaking, it says that for large integers
As an example, let's take

The red curve shows the number of primes up to and including n, where n is measured on the horizontal axis. The blue curve gives the value of n/ln(n). The difference between true result and approximation increases as n grows, but the ratio between the two values tends to 1.
To state the prime number theorem in its full mathematical glory using mathematical notation, let's first write
Return to the Plus advent calendar 2021.
This article was produced as part of our collaboration with the Isaac Newton Institute for Mathematical Sciences (INI) – you can find all the content from the collaboration here.
The INI is an international research centre and our neighbour here on the University of Cambridge's maths campus. It attracts leading mathematical scientists from all over the world, and is open to all. Visit www.newton.ac.uk to find out more.
