The prime-counting function is the number of primes at most .
For , let be the primes at most . The inclusion-exclusion principle counts unsieved positive integers by . These are and the remaining primes, since every composite number has a prime factor at most its square root. Hence for . This is a prime-counting identity, distinct from the Legendre formula for factorial valuations.
If for every , where , then
for . Every prime in contributes at least to the primorial, so
Taking logarithms, using , and observing that for proves the claim.

Articles by others on the same topic (1)

The prime-counting function, denoted as \( \pi(x) \), is a mathematical function that counts the number of prime numbers less than or equal to a given number \( x \).