OFFSET
1,1
COMMENTS
Here prime(n) means the n-th prime in 2, 3, 5, 7, ..., not the n-th term of A352808 that happens to be a prime.
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..10000
FORMULA
a(n) = k if A352808(k) = prime(n). - Michael S. Branicky, May 17 2022
PROG
(Python)
from sympy import nextprime
from itertools import count, islice
def agen(): # generator of terms
A352808lst = [0, 1]; A352808set = {0, 1}
mink = p = 2
for n in count(2):
ahalf, k = A352808lst[n//2], mink
while k in A352808set or k&ahalf: k += 1
A352808lst.append(k); A352808set.add(k)
while mink in A352808set: mink += 1
while p in A352808set: yield A352808lst.index(p); p = nextprime(p)
print(list(islice(agen(), 76))) # Michael S. Branicky, May 17 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, May 17 2022
STATUS
approved