OFFSET
1,1
LINKS
Chai Wah Wu, Table of n, a(n) for n = 1..31
FORMULA
a(n) = prime(A104386(n)).
PROG
(Python)
from itertools import count, islice
from sympy import isprime, prevprime
def agen():
for d in count(1):
ru = int("1"*d)
for r in range(ru, 10*ru, ru):
if r > 2:
p = prevprime(r)
if isprime(r + (r-p)) and prevprime(r+(r-p)) == p:
yield p
print(list(islice(agen(), 15))) # Michael S. Branicky, Jun 30 2022
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Zak Seidov, Mar 04 2005
EXTENSIONS
More terms from Giovanni Resta, Feb 09 2006
STATUS
approved