Calculating the Sieve of Eratosthenes