OFFSET
1,1
FORMULA
a(3n+1) = 0.
PROG
(Python)
from sympy import isprime
def agen():
digits = 0
while True:
for i in range(digits+1):
t = int("1"*(digits-i) + "3" + "1"*i)
if isprime(t): yield t; break
else: yield 0
digits += 1
g = agen()
print([next(g) for i in range(23)]) # Michael S. Branicky, Mar 13 2021
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Dec 08 2003
EXTENSIONS
More terms from David Wasserman, Jan 03 2006
STATUS
approved