View Single Post
Old 2017-12-14, 22:24   #1359
GP2
 
GP2's Avatar
 
Sep 2003

22·3·5·43 Posts
Default

Quote:
Originally Posted by GP2 View Post
It is mathematically impossible for two Mersenne numbers with prime exponents to share the same factor, so this would be the easiest way to prevent the problem from recurring.
Of course, it is not impossible (as far as we know) for a Mersenne number with prime exponent to have the same factor twice. However, finding any such non-square-free Mersenne number would generate headlines worldwide, because then we'd automatically have the third known Wieferich prime. The odds of this are surely astronomically low.

It's simple enough to test for non-squarefree-ness separately, over the entire database of factors, or at the time any factor is submitted, using standard modular exponentiation library functions, so this unlikely eventuality isn't a reason not to put a unique constraint or unique index on the factors column.
GP2 is offline   Reply With Quote