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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A103402 Palindromes p such that pi(p) is a palindromic prime. 5
3, 4, 5, 6, 11, 33, 555, 878, 5775, 6116, 919919, 58633685, 129707921, 16958285961, 867275572768 (list; graph; refs; listen; history; internal format)
OFFSET

1,1

COMMENTS

From a suggestion from Zak Seidov (zakseidov(AT)yahoo.com), Feb 02 2005.

a(16) > 32*10^12. [From Donovan Johnson (donovan.johnson(AT)yahoo.com), Dec 03 2009]

MATHEMATICA

NextPalindrome[n_] := Block[ {l = Floor[ Log[10, n] + 1], idn = IntegerDigits[n]}, If[ Union[ idn] == {9}, Return[n + 2], If[l < 2, Return[n + 1], If[ FromDigits[ Reverse[ Take[ idn, Ceiling[l/2]]]] FromDigits[ Take[ idn, -Ceiling[l/2]]], FromDigits[ Join[ Take[ idn, Ceiling[l/2]], Reverse[ Take[ idn, Floor[l/2]]] ]], idfhn = FromDigits[ Take[ idn, Ceiling[l/2]]] + 1; idp = FromDigits[ Join[ IntegerDigits[ idfhn], Drop[ Reverse[ IntegerDigits[ idfhn]], Mod[l, 2]]]] ]]]];

p = 0; a = {}; Do[p = NextPalindrome[p]; q = PrimePi[p]; If[PrimeQ[q], r = IntegerDigits[q]; If[Reverse[r] == r, Print[{p, q}]; AppendTo[a, p]]], {n, 10^6}]; a

CROSSREFS

Cf. A046941, A046942, A103357, A103358, A103403.

Sequence in context: A089912 A047425 A048989 * A154664 A191750 A034448

Adjacent sequences:  A103399 A103400 A103401 * A103403 A103404 A103405

KEYWORD

base,nonn

AUTHOR

Robert G. Wilson v (rgwv(AT)rgwv.com), Feb 03 2005

EXTENSIONS

a(15) from Donovan Johnson (donovan.johnson(AT)yahoo.com), Dec 03 2009

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 15 17:46 EST 2012. Contains 205835 sequences.