login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A349636 Primes that remain prime when a single "1" digit is inserted between any two adjacent digits. 1
13, 31, 37, 67, 79, 103, 109, 151, 163, 181, 193, 211, 241, 367, 457, 547, 571, 601, 613, 631, 709, 787, 811, 1117, 1213, 1831, 2017, 2683, 3019, 3319, 3391, 3511, 3517, 3607, 4519, 4999, 6007, 6121, 6151, 6379, 6673, 6871, 6991, 8293, 11119, 11317, 11467 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
37 and 317 are prime; 2683 is prime, as are 21683, 26183, and 26813.
MATHEMATICA
Select[Prime@Range[5, 1500], (p=#; And@@PrimeQ[FromDigits/@(Insert[IntegerDigits@p, 1, #]&/@Range[2, IntegerLength@p])])&] (* Giorgos Kalogeropoulos, Nov 23 2021 *)
PROG
(Python)
from sympy import isprime, primerange
def ok(p):
if p < 10: return False
s = str(p)
return all(isprime(int(s[:i] + "1" + s[i:])) for i in range(1, len(s)))
def aupto(limit): return [p for p in primerange(1, limit+1) if ok(p)]
print(aupto(12000)) # Michael S. Branicky, Nov 23 2021
CROSSREFS
The terms of A069246 > 10 are a subsequence.
Cf. A215417 (same with 0), A217044 (2), A217045 (4), A217046 (6), A217047 (8), A217062 (9), A217063 (3), A217064 (5), A217065 (7).
Sequence in context: A040086 A176181 A023274 * A129864 A350409 A080387
KEYWORD
nonn,base
AUTHOR
Michael S. Branicky, Nov 23 2021
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 14 23:14 EDT 2024. Contains 375171 sequences. (Running on oeis4.)