View Single Post
Old 2021-04-11, 16:06   #15
Viliam Furik
 
Viliam Furik's Avatar
 
"Viliam Furík"
Jul 2018
Martin, Slovakia

70810 Posts
Default Update

I have been trying to find something and came across the Wikipedia page for the LL test, where it says, that the sign of the S(p-3) is (-1)(p-1)/2 (except for p = 5), for starting value of 2/3, which is the Wagstaff number with exponent p, i.e. (2p+1)/3. This turns out to be 1 (mod p). Thus LL test with starting value of 2/3, and done modulo p is entirely composed of terms p-1, always. Using the property of the sign I tried to devise a checking test which under the assumption of the Mp being prime checks whether the conditions fit according to the known sign of the S(p-3).

S(p-2) = X * (2p-1)
S(p-2) = X (mod p)

S(p-3) = K * (2p-1) + sign * 2(p+1)/2
S(p-3) = K + sign * 2(p+1)/2 (mod p)

S(p-2) = S(p-3)2 - 2 = K2 + sigma * 2 * K * 2(p+1)/2 + 2p+1 - 2 = K2 + sigma * K * 2(p+3)/2 + 2 = K(K + sigma * 2(p+3)/2) + 2

using the property that all terms after the first one are -1 (mod p)

S(p-2) = S(p-3) = -1 (mod p)
S(p-2) = K(K + sigma * 2(p+3)/2) + 2 = -1 (mod p)
K(K + sigma * 2(p+3)/2) = -3 (mod p)

I observed that for all primes the 2(p+3)/2 is either 4 or -4 (mod p). I later realised that it's because 2p+3 is 16 (mod p), or equivalent if p < 16, thus the square root of 16 is 4 or -4. This means that the equation becomes

K(K +- 4) = -3 (mod p)

For the plus case, the solutions for K are -3 and -1, of which only -3 seems to satisfy the condition from the fourth row. For the minus case, the solutions are 1 and 3, and again, only 1 seems to ever satisfy the condition.

That would all be nice unless ALL primes p satisfied these conditions, which they do.

Is there any other way to modify this, so that we can use this test at all, or does it mean something in the sense of all Mersenne numbers being something like PRP modulo p (thus signifying impossibility of such test)?

I also tried something with starting value 4, and 10, because there is a relation between signs of S(p-3) for these starting values, but it only gives the product of the signs.
Viliam Furik is offline   Reply With Quote