The prime counting function
Hello,
I've thought about the prime counting function pi(n), and I thought that when n is a primorial : 17#, 19#, 23# and so on, there may exist a way to find the exact value pi(n) that could be simpler than computing all the primes (whitch would, of course need to be tested)
Example : We know that pi(210)=46, let's suppose we didn't know it, we could start by calculating the number of possible positions doing 11*1/2=1/2, 1/21/2*1/3=2/6, 2/62/6*1/5=8/30, 8/308/30*1/7=48/210,
Then, we would add 4, the number of primes up to x#, (in that case 7#), giving us 52, then we take away 1, because the first number in any cycle x# is always a possible prime position but 1 isn't prime, so we get to 51,
And, (probably the most time consuming part for this method) : we take away, for each of the primes above x (for x#), whose square is below x#, the number of primes that they can multiply by to give less than x#, in the case 7#, 11 can be multiplied up to 19, giving us 4 taken away (11*11, 13, 17, 19), and 13² takes away another number,
We have thus 51(4+1)=46.
Maybe an interesting idea...
