mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Proth Prime Search (https://www.mersenneforum.org/forumdisplay.php?f=109)
-   -   Proths of the form 2^{k+1}(2^{k} - 1) + 1, 2k+1 is prime (https://www.mersenneforum.org/showthread.php?t=25610)

 jshort 2020-06-11 23:46

Proths of the form 2^{k+1}(2^{k} - 1) + 1, 2k+1 is prime

(I guess am sort of answering my own question here......but here goes)

Are Proth Primes of the form [TEX]2^{k+1} \cdot (2^{k} - 1) + 1[/TEX] worthwhile to search for?

Fyi - I'm specifically referring to the special case when [TEX]2k + 1[/TEX] is itself a prime number and when [TEX]k \equiv 0,3 mod(4)[/TEX]

So here are my reasons for choosing these numbers and restrictions.

1) I noticed that potential composite factors [TEX]q[/TEX] have to satisfy some very strict congruence conditions when [TEX]p = 2k+1[/TEX] is prime (even more strict than prime factors of Mersenne numbers).

For example, [TEX]q \equiv 1 mod (4(2k+1))[/TEX] because the order of 2 over [TEX]q[/TEX] can be shown to be equal to [TEX]4p[/TEX].

2) Sieving out composite Proths of this form is very easy due to the fact that all potential prime factors have the form [TEX]1 + 4(2k+1)[/TEX] (unless [TEX]q = 5[/TEX], but the congruence restrictions on [TEX]k[/TEX] prevent this).

Fyi - I personally used the Pollard-rho algorithm with the iterating function [TEX]x_{n+1} = x_{n}^{24 \cdot (2k+1)} + 1[/TEX] to weed out many composites

(here is a basic program:

rho1(n)=
{
local(x,y);

x=2; y=2^(24p) + 1;
while(gcd(y-x,n)==1,
x=(x^(24p)+1)%n;
y=(y^(24p)+1)%n; y=(y^(24p)+1)%n
);
gcd(n,y-x)
}

)

Note: You don't necessarily need to use the 'extra' [TEX]24[/TEX] multiplier in the exponent of the iterating function, however the exponent of the iterating function definitely needs to be a "highly composite number" multiple of [TEX]4(2k+1)[/TEX] (if not equal to [TEX]4(2k+1)[/TEX] itself) to be the most efficient at weeding out composite Proths of this form .

Alternatively, the p-1 test could be used instead to weed out composites. I'm not sure which of the two would be more efficient tbh (if anyone knows the answer to this, that'd be awesome!).

 carpetpool 2020-06-12 05:34

I think you are referring to [URL="https://primes.utm.edu/top20/page.php?id=41"]Gaussian Mersenne norms[/URL].

 JeppeSN 2020-06-15 17:42

[QUOTE=carpetpool;547769]I think you are referring to [URL="https://primes.utm.edu/top20/page.php?id=41"]Gaussian Mersenne norms[/URL].[/QUOTE]

That sounds correct. In fact it seems the Gaussian Mersenne norms includes a bit more candidates, namely 2^{2k+1} ± 2^{k+1} + 1 where the sign of the middle term is picked such that the candidate is not divisible by 5. You can fix the sign, then you will get "half" of the Gaussian Mersenne norms. /JeppeSN

 Batalov 2020-06-15 19:07

[url]https://primes.utm.edu/top20/page.php?id=41[/url]

[url]https://oeis.org/A057429[/url] = [url]https://oeis.org/A007670[/url] + [url]https://oeis.org/A007671[/url]

 Batalov 2020-06-15 21:00

[QUOTE=jshort;547755]Fyi - I personally used the Pollard-rho algorithm with the iterating function [TEX]x_{n+1} = x_{n}^{24 \cdot (2k+1)} + 1[/TEX] to weed out many composites

Alternatively, the p-1 test could be used instead to weed out composites. I'm not sure which of the two would be more efficient tbh (if anyone knows the answer to this, that'd be awesome!).[/QUOTE]

In additional to what UTM's (and Mathworld's iirc has one) comprehensive pages says, quick note: Gaussian Mersenne norms share many similarities to Mersenne numbers. In particular,
* n needs to be prime - why? because otherwise there is an algebraic factorization. (And in the algebraic factorization you will find both + and - forms)
* Any factor (except 5 which is intrinsic) is of form [C]2 * k * p + 1[/C], so trial factoring is simplified but is very similar to Mersenne project: you don't sieve database-wide - you pre-factor each candidate. Furthermore, just like factors of Mersenne composites, these will not share the same factors (except the trivial case when one divides the other).

...that's just a few quick thoughts is a spare time during lunch break.

P.S. All primes of this form at this time are known -- loosely speaking to the limit of p < 10,000,000. So searching below this limit will not bring too much joy to the searcher.

 JeppeSN 2020-06-20 07:55

If you consider the numbers [B]2^(4k+2) + 1[/B], there are two kinds of algebraic factorizations for them. One is because 4k+2 = 2(2k+1), so the exponent has an odd divisor, therefore:

2^(4k+2) + 1 = (2^2)^(2k+1) + 1 = (2^2 + 1)[(2^2)^(2k) - (2^2)^(2k-1) + ... - (2^2)^3 + (2^2)^2 - 2^2 + 1]

But this simply says that 2^2 + 1 = 5 divides 2^(4k+2) + 1 which is also quite obvious without the factorization above.

Set n=2k+1. When n is a prime, there are no other nontrivial odd factors of the exponent 4k+2 than n, and then we do not get more factorizations of the above type.

However, Aurifeuille noted another algebraic factorization of 2^(4k+2) + 1, namely

2^(4k+2) + 1 = (2^(2k+1) - 2^(k+1) + 1)(2^(2k+1) + 2^(k+1) + 1)

For each k, one of the two factors here is necessarily divisible by 5. Then the other may be prime.

We can also write Aurifeuille's factorization with j = k+1 instead:

2^(4j-2) + 1 = (2^(2j-1) - 2^j + 1)(2^(2j-1) + 2^j + 1)

or with n (which is odd):

2^(2n) + 1 = (2^n - 2^((n+1)/2) + 1)(2^n + 2^((n+1)/2) + 1)

Let n be this odd number. The relation to Mersenne primes, as explained on Caldwell's page linked by carpetpool and Batalov above, is that the complex number (1+i)^n - 1 where i is a square root of minus one, is a prime in the ring of Gaussian integers exactly if the one of Aurifeuille's factors which is not a multiple of 5, is an ordinary prime.

The classical ([url]https://en.wikipedia.org/wiki/Aurifeuillean_factorization#History[/url]) example is n = 29 (so k=14 and j=15) where Aurifeuille says:

2^58 + 1 = (2^29 - 2^15 + 1)(2^29 + 2^15 + 1)

where the latter factor is prime (so a Gaussian Mersenne norm prime corresponding to the Gaussian prime (1+i)^29 - 1 where i is either of the two square roots of minus one).

/JeppeSN

 All times are UTC. The time now is 23:00.