cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A065437 Smallest base relative to which the n-th prime is palindromic.

Original entry on oeis.org

3, 2, 2, 2, 10, 3, 2, 18, 3, 4, 2, 6, 5, 6, 46, 52, 4, 6, 5, 7, 2, 78, 5, 8, 8, 10, 102, 2, 5, 8, 2, 10, 136, 138, 148, 3, 7, 162, 166, 3, 178, 10, 6, 12, 6, 11, 8, 222, 8, 12, 3, 14, 12, 8, 2, 262, 268, 7, 11, 14, 282, 292, 7, 310, 2, 316, 15, 9, 346, 8, 10, 358, 366, 4, 13, 10, 388
Offset: 1

Views

Author

Peter Bertok (peter(AT)bertok.com), Nov 23 2001

Keywords

Comments

Subset of A016026 for primes only.

Examples

			71 is the 20th prime and can be written as 131 in base 7, hence a(20)=7.
		

Crossrefs

Cf. A016026.

Programs

  • Mathematica
    PrimeMinBase[ n_ ] := NestWhile[ # + 1 &, 2, IntegerDigits[ Prime[ n ], # ] != Reverse[ IntegerDigits[ Prime[ n ], # ] ] & ]
    sbr[n_]:=Module[{k=2},While[IntegerDigits[n,k]!=Reverse[ IntegerDigits[ n,k]], k++]; k]; Table[sbr[n],{n,Prime[Range[80]]}] (* Harvey P. Dale, Jun 07 2016 *)