For any finite list of prime numbers p1, p2, ..., pn. at least one additional prime number exists. Let P be the product of all the prime numbers in the list: P = p1p2...pn. Let q = P + 1. Therefore q is either prime or not:
- If q is prime, then at least one prime is not listed.
- If q is not prime, then some prime factor p divides q. If this factor p were on our list, then it would divide P (because P is the product of every number on the list); but p divides P + 1 = q. If p divides P and q, then p would divide the difference of the two numbers, which is (P + 1) − P or just 1, but no prime number divides 1, and therefore p cannot be on the list and at least one more prime number is not listed.
Therefore for any finite list of prime numbers at least one additional prime number exists, and therefore infinitely many numbers are prime.
Euclid is often erroneously reported to have proved this result by contradiction, beginning by assuming that the set initially considered contains all prime numbers, or that it contains precisely the n smallest primes, rather than any arbitrary finite set of primes. Although the proof as a whole is not by contradiction, insofar as it begins without assuming that only finitely many primes exist, a proof by contradiction is within it: that none of the initially considered primes can divide q.
Another proof, by the Swiss mathematician Leonhard Euler, relies on the fundamental theorem of arithmetic: that every integer has a unique prime factorization. If P is the set of all prime numbers, Euler wrote that:
The first equality is given by the formula for a geometric series in each term of the product. To show the second equality, distribute the product over the sum:
in the result, every product of primes once appears; therefore by the fundamental theorem of arithmetic the sum equals the sum over all integers.
The sum on the right is the harmonic series, which diverges; therefore the product on the left must also diverge. Each term of the product is finite; therefore the number of terms is infinite; therefore primes are infinitely many.
Paul Erdős gave a third proof that relies on the fundamental theorem of arithmetic. Every integer n can be uniquely written as
where r is square-free - not divisible by any square numbers (let s² be the largest square number that divides n and then let r=n/s²). Suppose that a finite number k of prime numbers exists:
Fix a positive integer N and try to count the number of integers between 1 and N. Each of these numbers can be written as rs² where r is square-free and r and s2 are both less than N. By the fundamental theorem of arithmetic, there are only 2k square-free numbers r (see Combination#Number of k-combinations for all k) as each of the prime numbers factorizes r at most once, and we must have s<√N. So the total number of integers less than N is at most 2k√N; i.e.:
This inequality does not hold for N sufficiently large; therefore primes are infinitely many.
Some recent proofs
Juan Pablo Pinasco has written the following proof.
Let p1, ..., pN be the smallest N primes. By the inclusion–exclusion principle, the number of positive integers that are divisible by one of those primes and that x equals or exceeds is
Divide by x and let x → ∞
If no other primes than p1, ..., pN exist, then the expression in (1) equals and the expression in (2) equals 1, but 1 exceeds the expression in (3). Therefore more primes than p1, ..., pN exist.
If only finitely many primes exist, then
(the numerator of the fraction would grow singly exponentially whereas by Stirling's approximation the denominator grows more quickly than singly exponentially), contradicting the fact that for each k the numerator exceeds or equals the denominator.
Proof using the irrationality of π
The numerators of this product are the prime numbers, and each denominator is the multiple of four nearest to the numerator.
If primes were finitely many, then this formula would show that π is rational, but π is not rational.
Notes and references
- James Williamson (translator and commentator), The Elements of Euclid, With Dissertations, Clarendon Press, Oxford, 1782, page 63.
- In general, for any integers a, b, c if and , then . For more information, see Divisibility.
- Michael Hardy and Catherine Woodgold, "Prime Simplicity", Mathematical Intelligencer, volume 31, number 4, fall 2009, pages 44–52.
- Juan Pablo Pinasco, "New Proofs of Euclid's and Euler's theorems", American Mathematical Monthly, volume 116, number 2, February, 2009, pages 172–173.
- Junho Peter Whang, "Another Proof of the Infinitude of the Prime Numbers", American Mathematical Monthly, volume 117, number 2, February 2010, page 181.
- Debnath, Lokenath (2010), The Legacy of Leonhard Euler: A Tricentennial Tribute, World Scientific, p. 214, ISBN 9781848165267.