The Prime counting function counts the number of primes less than or equal to . The prime number theorem says that,
.
In 1859 Bernhard Riemann presented a paper On the number of primes less than a given number he showed this to be exactly,
,
where,
- is the natural logarithm of
- are the non-trivial zeros of the Riemann Zeta function.
Whilst the sum is over all it is needed only to add up to the term such that as after that .
The convergence of
is dependent on the Riemann hypothesis and if true is better behaved.