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!)
A086040 Prime p concatenated with next 4 primes is also prime. 6
7, 47, 53, 67, 97, 101, 149, 401, 431, 479, 487, 757, 827, 887, 1061, 1171, 1409, 1429, 1543, 1721, 1789, 1811, 1889, 1987, 2099, 2113, 2137, 2273, 2689, 2719, 2857, 3203, 3571, 3613, 3623, 3761, 3853, 3917, 3929, 4007, 4217, 4441, 4943, 5039, 5209, 5281, 5449 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
a(1) = 7 because 7, 11, 13, 17 and 19 concatenated together yield 711131719, which is prime.
PROG
(Python)
from itertools import islice
from sympy import isprime, nextprime
def agen(): # generator of terms
plst = [2, 3, 5, 7, 11]
slst = list(map(str, plst))
while True:
if isprime(int("".join(slst))):
yield plst[0]
plst = plst[1:] + [nextprime(plst[-1])]
slst = slst[1:] + [str(plst[-1])]
print(list(islice(agen(), 50))) # Michael S. Branicky, Jan 26 2023
CROSSREFS
Sequence in context: A036944 A068640 A089725 * A009241 A263920 A124837
KEYWORD
base,nonn
AUTHOR
Chuck Seggelin (barkeep(AT)plastereddragon.com), Jul 07 2003
EXTENSIONS
Offset corrected by Arkadiusz Wesolowski, May 10 2012
a(15) and beyond from Michael S. Branicky, Jan 26 2023
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 May 5 12:29 EDT 2024. Contains 372275 sequences. (Running on oeis4.)