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

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A186698 Next prime after n-th palindrome. 2

%I

%S 2,3,5,5,7,7,11,11,11,13,23,37,47,59,67,79,89,101,103,113,127,137,149,

%T 157,163,173,191,193,211,223,223,233,251,257,263,277,283,293,307,317,

%U 331,337,347,359,367,379,389,397,409,419,431,439,449,457,467,479,487,499,509,521,541,541,547,557,569,577,587,599,607,617,631,641,647

%N Next prime after n-th palindrome.

%C There are infinitely many n for which a(n+1) = a(n). For example, when 10^k + 1 is composite, 10^k - 1 and 10^k + 1 are successive palindromes which have the same next prime. - _Robert Israel_, Nov 04 2015

%H Chai Wah Wu, <a href="/A186698/b186698.txt">Table of n, a(n) for n = 1..10000</a>

%p digrev:= proc(x) option remember; local t;

%p t:= x mod 10;

%p t*10^ilog10(x)+procname((x-t)/10)

%p end proc:

%p for x from 0 to 9 do digrev(x):= x od:

%p N:=6;

%p Pals:= \$1..9:

%p for d from 2 to N do

%p if d::even then

%p m:= d/2;

%p Pals:= Pals, seq(n*10^m + digrev(n), n=10^(m-1)..10^m-1);

%p else

%p m:= (d-1)/2;

%p Pals:= Pals, seq(seq(n*10^(m+1)+y*10^m+digrev(n), y=0..9), n=10^(m-1)..10^m-1);

%p fi

%p od:

%p Pals:=[Pals]:

%p map(nextprime,Pals); # _Robert Israel_, Nov 04 2015

%Y Cf. A014208, A186697.

%K nonn,base

%O 1,1

%A _Harvey P. Dale_, Feb 25 2011

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.

Last modified May 13 13:53 EDT 2021. Contains 343858 sequences. (Running on oeis4.)