A056993 a(n) is the smallest k >= 2 such that k^(2^n)+1 is prime, or -1 if no such k exists.
2, 2, 2, 2, 2, 30, 102, 120, 278, 46, 824, 150, 1534, 30406, 67234, 70906, 48594, 62722, 24518, 75898, 919444
Offset: 0
Examples
The primes are 2^(2^0) + 1 = 3, 2^(2^1) + 1 = 5, 2^(2^2) + 1 = 17, 2^(2^3) + 1 = 257, 2^(2^4) + 1 = 65537, 30^(2^5) + 1, 102^(2^6) + 1, ....
Links
- Yves Gallot, Generalized Fermat Prime Search
- Lucile and Yves Gallot, Generalized Fermat Prime Search
- Michael Goetz, id=103235 of Top 5000 Primes
- Luke Harmon, Gaetan Delavignette, Arnab Roy, and David Silva, PIE: p-adic Encoding for High-Precision Arithmetic in Homomorphic Encryption, Cryptology ePrint Archive 2023/700.
- Stephen Scott, id=84401 of Top 5000 Primes
- Sylvanus A. Zimmerman, PrimeGrid’s Generalized Fermat Prime Search
Crossrefs
Programs
-
Mathematica
f[n_] := (p = 2^n; k = 2; While[cp = k^p + 1; !PrimeQ@cp, k++ ]; k); Do[ Print[{n, f@n}], {n, 0, 17}] (* Lei Zhou, Feb 21 2005 *)
-
PARI
a(n)=my(k=2);while(!isprime(k^(2^n)+1),k++);k \\ Anders Hellström, Sep 16 2015
Formula
a(n) = A085398(2^(n+1)). - Jianing Song, Jun 13 2022
Extensions
1534 from Robert G. Wilson v, Oct 30 2000
62722 from Jeppe Stig Nielsen, Aug 07 2005
24518 and 75898 from Lei Zhou, Feb 01 2012
919444 from Jeppe Stig Nielsen, Dec 30 2017
Comments