OFFSET
1,3
EXAMPLE
For n = 3, the primes are 3, 5 and 7. 3 + 5 = 8, 3 + 7 = 10 and 5 + 7 = 12 are all distinct even numbers, so a(3) = 3.
PROG
(Python)
from sympy import nextprime
from itertools import islice
def agen(): # generator of terms
plst, s, p = [3], set(), 3
while True:
yield len(s)
p = nextprime(p)
s.update(p+pi for pi in plst)
plst.append(p)
print(list(islice(agen(), 60))) # Michael S. Branicky, May 07 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Kshitij Thakkar and Gargee Girdhari, May 07 2023
STATUS
approved