The blue curve gives the value of n/ln( n). The red curve shows the number of primes up to and including n, where n is measured on the horizontal axis. In fact you can get it to be as close to 100% as you like by choosing a large enough
Generally, the prime number theorem tells us that for large the approximation is nearly 100% of the true value. This translates to 90%, so here the estimate is better than for. Therefore in this case the estimate constitutes a proportion of Not bad.įor the actual number of primes up to and including is, so that’s the true value, and the estimate was Of the true result, which translates to 86%. Therefore, the approximation constitutes a proportion of To go back to our example of, the true value was and the approximation was. The prime number theorem does not say that for large values of the difference between the true value and our approximation is close to Instead, it tells us something about the question "what’s the approximation as a percentage of the true value"? However, to be precise about what the prime number theorem tells us, we need to say what we mean by "a good estimate". The actual number of primes up to and including (which you can look up in this list) is. Here is the natural logarithm of, which you can find on your calculator.Īs an example, let's take. Is a good estimate for the number of primes up to and including, and that the estimate gets better as gets larger. Loosely speaking, it says that for large integers, the expression The prime number theorem doesn’t answer this question precisely, but instead gives an approximation.
It attempts to answer the question "given a positive integer, how many integers up to and including are prime numbers"? The prime number theorem tells us something about how the prime numbers are distributed among the other integers. Powerful computer algorithms have enabled us to find larger and larger primes, but we will never be able to write down all of them. 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. This is why people find them interesting. Adapted from a figure by SKopp, CC BY-SA 3.0.Įvery other positive integer can be written as a product of prime numbers in a unique way - for example - so the prime numbers are like basic building blocks that other integers can be constructed from. You can find out more about the sieve here. This is an illustration of the sieve of Eratosthenes, which is designed to catch prime numbers.