Quote:
Originally Posted by fernwood
Can anyone explain how that could be known for such a large number?
I think Wilson's Theorem would be a good one to understand the general principle of how these tests work. For many of primality tests (for example, the AKS primality test), you don't have finish the calculation to know that the number is composite.
Let's look at n = 5 using Wilson's Theorem:
-- 1*2 = 2 (mod 5)
-- 2*3 = 1 (mod 5)
-- 1*4 = 4 (mod 5)
And so we've shown that 5 is prime by finishing the calculation of 4!.
But let's look at n = 8 using Wilson's Theorem:
-- 1*2 = 2 (mod 8)
-- 2*3 = 6 (mod 8)
-- 3*6 = 2 (mod 8)
-- 4*2 = 0 (mod 8)
At this point, we can just stop because we know that it will be impossible for 7! to be equal to -1 (mod 8). And we've only done 4 out of the 7 calculations.
I don't know the specific tools used for the Euclid-Mullin value, but I would not at all be surprised if it was something that worked kind of like this.