login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A059677 Numbers n such that 1n1, 3n3, 7n7 and 9n9 are all primes. 2
20, 53, 341, 536, 2312, 2477, 3380, 3665, 3686, 4547, 5009, 5105, 6458, 6488, 6731, 6845, 7499, 7508, 7562, 7835, 8411, 8831, 9032, 9386, 9764, 9839, 11027, 11885, 14990, 19589, 20498, 21080, 22844, 24821, 25220, 26393, 27593, 29864, 29921 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Table of n, a(n) for n=1..39.

EXAMPLE

2312 is included because 123121, 323123, 723127 and 923129 are all primes.

MATHEMATICA

Select[ Range[ 30000 ], PrimeQ[ ToExpression[ StringInsert[ ToString[ # ], "1", {1, -1} ] ] ] && PrimeQ[ ToExpression[ StringInsert[ ToString[ # ], "3", {1, -1} ] ] ] && PrimeQ[ ToExpression[ StringInsert[ ToString[ # ], "7", {1, -1} ] ] ] && PrimeQ[ ToExpression[ StringInsert[ ToString[ # ], "9", {1, -1} ] ] ] & ]

enclose[n_]:=Table[FromDigits[Join[{i}, IntegerDigits[n], {i}]], {i, {1, 3, 7, 9}}]; Select[Range[30000], AllTrue[enclose[#], PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 21 2015 *)

CROSSREFS

Cf. A032682, A059693, A059694.

Sequence in context: A205220 A188250 A008524 * A108108 A123456 A144521

Adjacent sequences:  A059674 A059675 A059676 * A059678 A059679 A059680

KEYWORD

base,nonn

AUTHOR

Harvey P. Dale, Feb 05 2001

EXTENSIONS

More terms from Patrick De Geest, Feb 07 2001.

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 | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified August 16 08:52 EDT 2017. Contains 290623 sequences.