OFFSET
1,2
COMMENTS
Previous name was: Recursive sequence of indices of Proth primes a*2^b + 1.
LINKS
Chris K. Caldwell, The Prime Pages, 3871*2^1925976+1 (7742*2^1925975+1)
Chris K. Caldwell, The Prime Pages, 1925975*2^1989191+1
Chris K. Caldwell, The Prime Pages, 1989191*2^2008551+1
Chris K. Caldwell, The Prime Pages, 2008551*2^4371904+1
Chris K. Caldwell, The Prime Pages, 68311*2^6487924+1 (4371904*2^6487918+1)
MATHEMATICA
t = {a = 1}; Do[If[PrimeQ[a*2^n + 1], AppendTo[t, a = n]], {n, 2, 2300}]; t (* Jayanta Basu, Jun 29 2013 *)
PROG
(PARI) a=1; until(, print1(a, ", "); for(b=a+1, +oo, if(ispseudoprime(a*2^b+1), a=b; break())))
(Python)
from gmpy2 import is_prime
from itertools import count, islice
def agen(): # generator of terms
an = 1
while True:
yield an
an = next(k for k in count(an+1) if is_prime(an*(1<<k) + 1))
print(list(islice(agen(), 18))) # Michael S. Branicky, Aug 12 2025
CROSSREFS
KEYWORD
hard,nonn,more
AUTHOR
Chad Davis (cad16(AT)po.cwru.edu)
EXTENSIONS
a(19) from Kellen Shenton, May 08 2022
a(20) from Kellen Shenton, May 14 2022
a(21)-a(22) from Kellen Shenton, Feb 21 2025
New name, new offset and a(23) from Kellen Shenton, Aug 10 2025
STATUS
approved
