login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A358427
a(n) is the least prime p such that there are exactly n primes q with the same number of digits as p such that the concatenations p|q and q|p are prime, or 0 if there is no such p.
0
2, 3, 13, 23, 19, 353, 157, 173, 101, 113, 137, 193, 181, 1831, 983, 1297, 2861, 1321, 1259, 1381, 1229, 1039, 1009, 1097, 1033, 1019, 1237, 1129, 1051, 1013, 1049, 1723, 1181, 1117, 1583, 1523, 1153, 1439
OFFSET
0,1
COMMENTS
For every 5-digit prime p, there are at least 70 primes q. Thus it is very likely that a(n) = 0 for 38 <= n <= 69. However, there is no proof of this.
EXAMPLE
a(4) = 19 because 19 is prime and there are 4 primes 13, 31, 79, 97 where 1913, 1319, 1931, 3119, 1979, 7931, 1397 and 9731 are prime, and no smaller prime works.
MAPLE
A:= Array(0..37): count:= 0: p:= 0:
while count < 38 do
p:= nextprime(p);
v:= f(p);
if v <= 37 and A[v] = 0 then count:= count+1; A[v]:= p; fi;
od:
convert(A, list);
PROG
(Python)
from itertools import count, islice
from sympy import isprime, primerange
def agen(): # generator of terms
adict, n = dict(), 0
for d in count(1):
pow = 10**d
for p in primerange(10**(d-1), pow):
v = 0
for q in primerange(10**(d-1), pow):
t = p*pow + q
if isprime(p*pow + q) and isprime(q*pow + p): v += 1
if v not in adict: adict[v] = p
while n in adict: yield adict[n]; n += 1
print(list(islice(agen(), 38))) # Michael S. Branicky, Nov 15 2022
CROSSREFS
Cf. A358421.
Sequence in context: A282342 A137248 A355438 * A136260 A296932 A288054
KEYWORD
nonn,base,more
AUTHOR
J. M. Bergot and Robert Israel, Nov 15 2022
STATUS
approved