login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A057630 Primes such that replacing each digit d with d copies of the digit d produces a prime. Zeros are allowed. 3
11, 31, 53, 101, 131, 149, 223, 283, 311, 313, 331, 397, 463, 503, 641, 691, 937, 941, 1031, 1049, 1069, 1301, 1409, 1439, 1511, 1609, 1741, 1871, 1949, 1993, 1999, 2083, 2111, 2203, 2447, 2803, 2939, 3001, 3011, 3061, 3163, 3301, 3391, 3433, 3499, 3559 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

"Replacing each digit d with d copies of the digit d" is the function A048376, well defined on the set of positive integers. Therefore (the range of) the present sequence is the largest subset of A000040 stable under the operation A048376.

A004022 is a subsequence. - Chai Wah Wu, Dec 19 2019

LINKS

Chai Wah Wu, Table of n, a(n) for n = 1..10000

EXAMPLE

E.g. 641 becomes 66666644441 which is also prime.

MATHEMATICA

Select[Prime[Range[500]], PrimeQ[FromDigits[Flatten[Table[#, {#}]&/@ IntegerDigits[ #]]]]&]  [From Harvey P. Dale, Dec. 18, 2010]

PROG

(PARI) is_A057630(n)={isprime(A048376(n)) && isprime(n)} \\ - M. F. Hasler, Jan 23 2013

(Python)

from sympy import isprime, nextprime

A057630_list, dlist, p = [], [str(d)*d for d in range(10)], 2

while len(A057630_list) < 10000:

    if isprime(''.join(dlist[int(d)] for d in str(p))):

        A057630_list.append(p)

    p = nextprime(p) # Chai Wah Wu, Dec 19 2019

CROSSREFS

Cf. A004022, A057628.

Sequence in context: A031287 A230329 A232764 * A057628 A144364 A226922

Adjacent sequences:  A057627 A057628 A057629 * A057631 A057632 A057633

KEYWORD

nonn,base,nice,easy

AUTHOR

G. L. Honaker, Jr., Oct 10 2000

EXTENSIONS

More terms from Patrick De Geest, Oct 15 2000.

Offset changed to 1, according to OEIS conventions, by M. F. Hasler, Jan 23 2013

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 26 15:50 EDT 2020. Contains 334626 sequences. (Running on oeis4.)