login
A103835
Smallest prime p, larger than previous term, such that concatenation of n and p is a prime.
1
3, 11, 13, 19, 23, 31, 43, 53, 67, 97, 113, 149, 151, 173, 193, 223, 239, 251, 373, 389, 397, 409, 431, 439, 457, 479, 487, 499, 569, 577, 601, 647, 739, 757, 797, 809, 811, 821, 827, 829, 863, 929, 991, 1109, 1181, 1297, 1301, 1303, 1327, 1367, 1409, 1429
OFFSET
1,1
COMMENTS
Cf. A096915.
EXAMPLE
a(10)=97 because 1097 is prime, while 1071,1073,1079,1083,1089 are all composite.
PROG
(Python)
from sympy import isprime, nextprime
def ispal(n): s = str(n); return s == s[::-1]
def aupto(lim):
n, p, alst = 1, 2, []
while p <= lim:
if isprime(int(str(n)+str(p))): n, alst = n + 1, alst + [p]
p = nextprime(p)
return alst
print(aupto(1429)) # Michael S. Branicky, Mar 11 2021
CROSSREFS
Sequence in context: A338445 A191049 A373471 * A067386 A063621 A176870
KEYWORD
nonn,base
AUTHOR
Zak Seidov, Mar 30 2005
STATUS
approved