ArticleslgStudy

mathematics

Prime number theorem

Prime number theorem is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Prime number theorem rather than just read about it. In short: In mathematics, the prime number theorem (PNT) describes the asymptotic distribution of prime numbers among the positive integers. It formalizes the intuitive idea that primes become less common as they become larger by precisely quantifying the rate at which this occurs.

Prime number theorem — main illustration
Prime number theorem — illustration

Key takeaways

  • Prime number theorem belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Prime number theorem to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Prime number theorem from memory before moving on to harder problems.

Reference excerpt

In mathematics, the prime number theorem (PNT) describes the asymptotic distribution of prime numbers among the positive integers. It formalizes the intuitive idea that primes become less common as they become larger by precisely quantifying the rate at which this occurs. The theorem was proved independently by Jacques Hadamard and Charles Jean de la Vallée Poussin in 1896 using ideas introduced by Bernhard Riemann (in particular, the Riemann zeta function). The first such distribution found is π(N) ~ ⁠N/log(N)⁠, where π(N) is the prime-counting function (the number of primes less than or equal to N) and log(N) is the natural logarithm of N. This means that for large enough N, the probability that a random integer not greater than N is prime is very close to 1 / log(N). In other words, the average gap between consecutive prime numbers among the first N integers is roughly log(N). Consequently, a random integer with at most 2n digits (for large enough n) is about half as likely to be prime as a random integer with at most n digits. For example, among the positive integers of at most 1000 digits, about one in 2300 is prime (log(101000) ≈ 2302.6), whereas among positive integers of at most 2000 digits, about one in 4600 is prime (log(102000) ≈ 4605.2).

Statement

Let π(x) be the prime-counting function defined to be the number of primes less than or equal to x, for any real number x. For example, π(10) = 4 because there are four prime numbers (2, 3, 5 and 7) less than or equal to 10. The prime number theorem then states that x / log x is a good approximation to π(x) (where log here means the natural logarithm), in the sense that the limit of the quotient of the two functions π(x) and x / log x as x increases without bound is 1:

lim x → ∞ π ( x ) [ x log ⁡ ( x ) ] = 1 , {\displaystyle \lim _{x\to \infty }{\frac {\;\pi (x)\;}{\;\left[{\frac {x}{\log(x)}}\right]\;}}=1,}

known as the asymptotic law of distribution of prime numbers. Using asymptotic notation this result can be restated as

π ( x ) ∼ x log ⁡ x . {\displaystyle \pi (x)\sim {\frac {x}{\log x}}.}

This notation (and the theorem) does not say anything about the limit of the difference of the two functions as x increases without bound. Instead, the theorem states that x / log x approximates π(x) in the sense that the relative error of this approximation approaches 0 as x increases without bound. The prime number theorem is equivalent to the statement that the nth prime number pn satisfies

p n ∼ n log ⁡ ( n ) , {\displaystyle p_{n}\sim n\log(n),}

the asymptotic notation meaning, again, that the relative error of this approximation approaches 0 as n increases without bound. For example, the 2×1017th prime number is 8512677386048191063, and (2×1017)log(2×1017) rounds to 7967418752291744388, a relative error of about 6.4%. On the other hand, the following asymptotic relations are logically equivalent:

lim x → ∞ π ( x ) log ⁡ x x = 1 , and lim x → ∞ π ( x ) log ⁡ π ( x ) x = 1. {\displaystyle {\begin{aligned}\lim _{x\rightarrow \infty }{\frac {\pi (x)\log x}{x}}&=1,{\text{ and}}\\\lim _{x\rightarrow \infty }{\frac {\pi (x)\log \pi (x)}{x}}\,&=1.\end{aligned}}}

As outlined below, the prime number theorem is also equivalent to

lim x → ∞ ϑ ( x ) x = lim x → ∞ ψ ( x ) x = 1 , {\displaystyle \lim _{x\to \infty }{\frac {\vartheta (x)}{x}}=\lim _{x\to \infty }{\frac {\psi (x)}{x}}=1,}

where ϑ and ψ are the first and the second Chebyshev functions respectively, and to

… excerpt ends here. Continue reading the full article.

Illustrations

Prime number theorem: Log–log plot showing absolute error of x / log x and Li(x), two approximations to the prime-counting function π(x). Unlike the ratio, the difference between π(x) and x / log x increases without bound as x increases. On the other hand, Li(x) − π(x) switches sign infinitely many times.
Log–log plot showing absolute error of x / log x and Li(x), two approximations to the prime-counting function π(x). Unlike the ratio, the difference between π(x) and x / log x increases without bound as x increases. On the other hand, Li(x) − π(x) switches sign infinitely many times.
Prime number theorem: Plot of the function 
  
    
      
         
        π
        (
        x
        ;
        4
        ,
        3
        )
        −
        π
        (
        x
        ;
        4
        ,
        1
        )
         
      
    
    {\displaystyle \ \pi (x;4,3)-\pi (x;4,1)\ }
  
 for n ≤ 30000
Plot of the function   π ( x ; 4 , 3 ) − π ( x ; 4 , 1 )   {\displaystyle \ \pi (x;4,3)-\pi (x;4,1)\ } for n ≤ 30000
Prime number theorem: Graph of the number of primes ending in 1, 3, 7, and 9 up to n for n < 10000
Graph of the number of primes ending in 1, 3, 7, and 9 up to n for n < 10000

Worked examples

Example 1 — a first encounter with Prime number theorem

Start with the simplest possible case. Write down what Prime number theorem claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Prime number theorem before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Prime number theorem ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Prime number theorem

In research
Prime number theorem appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Prime number theorem in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Prime number theorem is common in secondary-school and first-year university syllabi. It links to neighbouring topics Logarithms, Theorems about prime numbers, Theorems in analytic number theory, so understanding it makes those chapters shorter.
In everyday life
Look for Prime number theorem outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Prime number theorem” →

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study Prime number theorem in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Prime number theorem means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Prime number theorem out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Prime number theorem in simple terms?

In mathematics, the prime number theorem (PNT) describes the asymptotic distribution of prime numbers among the positive integers. It formalizes the intuitive idea that primes become less common as they become larger by precisely quantifying the rate at which this occurs.

Why does Prime number theorem matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Prime number theorem?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Prime number theorem.

Tags

  • Logarithms
  • Theorems about prime numbers
  • Theorems in analytic number theory

Keep exploring