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.

Showing 1-8 of 8 results.

A100028 Values of n for which the decimal number 10...030...01 is an n-digit prime.

Original entry on oeis.org

3, 5, 7, 9, 23, 29, 33, 185, 267, 307, 757, 897, 1571, 2977, 3831, 4595, 6573, 9511, 11651, 15641, 68885, 69883
Offset: 1

Views

Author

Harvey Dubner (harvey(AT)dubner.com), Nov 20 2004

Keywords

Examples

			The corresponding primes are 131, 10301, 1003001, 100030001, 10000000000300000000001, etc.
		

Crossrefs

Programs

  • Mathematica
    IntegerLength/@Select[Table[FromDigits[Join[PadRight[{1},n,0],{3},PadLeft[ {1},n,0]]],{n,35000}],PrimeQ] (* Harvey P. Dale, Dec 20 2019 *)

Formula

a(n) = 2*(A171376(n+1))+1. - Chai Wah Wu, Aug 20 2015

A100027 Smallest (2n+1)-digit palindromic prime of the form 10...0M0...01 (thus M is a palindrome with <= 2n-1 digits).

Original entry on oeis.org

101, 10301, 1003001, 100030001, 10000500001, 1000008000001, 100000323000001, 10000000500000001, 1000000008000000001, 100000000212000000001, 10000000000300000000001, 1000000000016100000000001, 100000000000080000000000001, 10000000000000300000000000001, 1000000000000024200000000000001
Offset: 1

Views

Author

Harvey Dubner (harvey(AT)dubner.com), Nov 20 2004

Keywords

Comments

Essentially a duplicate of A028989. - Jeppe Stig Nielsen, Apr 04 2025

Crossrefs

Values of M are given in A100026. Cf. A100028.
Cf. A028989.

A099744 Palindromes n such that 10n01 is a prime.

Original entry on oeis.org

3, 5, 6, 222, 282, 353, 434, 555, 626, 656, 747, 828, 858, 929, 939, 10301, 10601, 11411, 11711, 12821, 12921, 13431, 13731, 14141, 14241, 14741, 15951, 16161, 17171, 17771, 18381, 18981, 19191, 19491, 19991, 20402, 20702, 22022, 22322
Offset: 1

Views

Author

N. J. A. Sloane, Nov 19 2004

Keywords

Crossrefs

Programs

  • Maple
    read transforms; pal:=[]; for n from 0 to 8000 do if digrev(n) = n then pal:=[op(pal),n]; fi; od:
    t0:=[]; u0:=[]; for n from 1 to nops(pal) do m:=pal[n]; p0:="10"; p1:="01"; t1:=cat(p0,m,p1); t1:=convert(t1,decimal,10); if isprime(t1) then t0:=[op(t0),m]; u0:=[op(u0),t1]; fi; od: t0; # u0 gives A099746.
  • Mathematica
    p = Select[ Range[ 22322], # == FromDigits[ Reverse[ IntegerDigits[ # ]]] &]; Select[p, PrimeQ[ FromDigits[ Join[{1, 0}, IntegerDigits[ # ], {0, 1}]]] &] (* Robert G. Wilson v, Nov 20 2004 *)
    Select[Range[23000],PalindromeQ[#]&&PrimeQ[FromDigits[Join[{1,0},IntegerDigits[ #],{0,1}]]]&] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Mar 26 2021 *)

Extensions

More terms from Robert G. Wilson v, Nov 19 2004

A100955 Consider all (2n+1)-digit palindromic primes of the form 30...0M0...03 (so that M is a palindrome with <= 2n-1 digits); a(n) = smallest such M.

Original entry on oeis.org

1, 1, 1, 2, 5, 2, 2, 8, 5, 434, 5, 313, 272, 838, 5, 272, 8, 505, 1, 7, 212, 7, 151, 686, 2, 242, 656, 656, 323, 929, 121, 242, 262, 12521, 454, 949, 353, 2, 16361, 707, 10301, 515, 29092, 454, 13331, 686, 848, 20602, 1, 484, 737, 101, 242, 121, 15551, 656, 232
Offset: 1

Views

Author

Robert G. Wilson v, Nov 23 2004

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{k = 0, t = Flatten[ Join[{3}, Table[0, {n - 1}]]]}, While[s = Drop[t, Min[ -Floor[ Log[10, k]/2], 0]]; k != FromDigits[ Reverse[ IntegerDigits[k]]] || !PrimeQ[ FromDigits[ Join[s, IntegerDigits[k], Reverse[s]]]], k++ ]; k]; Table[ f[n], {n, 57}]

A100956 Consider all (2n+1)-digit palindromic primes of the form 70...0M0...07 (so that M is a palindrome with <= 2n-1 digits); a(n) = smallest such M.

Original entry on oeis.org

2, 2, 141, 2, 545, 5, 141, 282, 111, 3, 141, 5, 131, 282, 141, 141, 9, 3, 2, 303, 171, 6, 222, 323, 2, 393, 797, 606, 191, 404, 414, 363, 797, 171, 474, 737, 25752, 545, 20502, 14241, 848, 12821, 15951, 474, 575, 12321, 2, 17771, 8, 666, 14541, 15651, 171, 191
Offset: 1

Views

Author

Robert G. Wilson v, Nov 23 2004

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{k = 0, t = Flatten[ Join[{7}, Table[0, {n - 1}]]]}, While[s = Drop[t, Min[ -Floor[ Log[10, k]/2], 0]]; k != FromDigits[ Reverse[ IntegerDigits[k]]] || !PrimeQ[ FromDigits[ Join[s, IntegerDigits[k], Reverse[s]]]], k++ ]; k]; Table[ f[n], {n, 55}]

A100957 Consider all (2n+1)-digit palindromic primes of the form 90...0M0...09 (so that M is a palindrome with <= 2n-1 digits); a(n) = smallest such M.

Original entry on oeis.org

1, 7, 2, 1, 2, 5, 838, 232, 121, 8, 151, 202, 2, 101, 646, 5, 1, 151, 424, 404, 242, 131, 646, 272, 16361, 1, 494, 1, 868, 101, 494, 12421, 14041, 151, 595, 383, 515, 19091, 10001, 242, 17171, 20602, 161, 292, 11011, 8, 1, 11611, 22822, 232, 17771, 616, 767
Offset: 1

Views

Author

Robert G. Wilson v, Nov 23 2004

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{k = 0, t = Flatten[ Join[{9}, Table[0, {n - 1}]]]}, While[s = Drop[t, Min[ -Floor[ Log[10, k]/2], 0]]; k != FromDigits[ Reverse[ IntegerDigits[k]]] || !PrimeQ[ FromDigits[ Join[s, IntegerDigits[k], Reverse[s]]]], k++ ]; k]; Table[ f[n], {n, 55}]

A099746 Primes arising in A099744.

Original entry on oeis.org

10301, 10501, 10601, 1022201, 1028201, 1035301, 1043401, 1055501, 1062601, 1065601, 1074701, 1082801, 1085801, 1092901, 1093901, 101030101, 101060101, 101141101, 101171101, 101282101, 101292101, 101343101, 101373101, 101414101
Offset: 1

Views

Author

N. J. A. Sloane, Nov 19 2004

Keywords

Comments

Prompted by Harvey Dubner's Nov 07 2004 discovery that 10000...000M000...00001 with M=3761673, a palindrome, is a 130023-digit palindromic prime.

Crossrefs

Programs

  • Mathematica
    p = Select[ Range[ 22322], # == FromDigits[ Reverse[ IntegerDigits[ # ]]] &]; q = Select[p, PrimeQ[ FromDigits[ Join[{1, 0}, IntegerDigits[ # ], {0, 1}]]] &]; Table[ FromDigits[ Join[{1, 0}, IntegerDigits[ q[[n]]], {0, 1}]], {n, 24}]; (* Robert G. Wilson v, Nov 20 2004 *)

Extensions

More terms from Robert G. Wilson v, Nov 20 2004

A261450 Smallest k such that A011557(n)//k//rev is prime, where rev is the string of digits of A011557(n) reversed (retaining any leading zeros) and // denotes concatenation.

Original entry on oeis.org

0, 3, 3, 3, 5, 8, 29, 5, 8, 15, 3, 21, 8, 3, 21, 3, 8, 18, 20, 92, 110, 51, 102, 6, 57, 23, 5, 114, 8, 32, 41, 6, 236, 6, 39, 60, 110, 62, 36, 17, 53, 21, 161, 41, 159, 57, 137, 42, 83, 114, 126, 80, 30, 36, 278, 107, 425, 111, 68, 68, 95, 29, 8, 53, 426, 48
Offset: 0

Views

Author

Felix Fröhlich, Aug 23 2015

Keywords

Comments

Is a(n) = 0 for any n > 0? If such an n exists, that n is a term of A000079 (cf. Greathouse, 2010).
All terms are congruent to 0 or 2 modulo 3, since if k is congruent to 1 modulo 3, 1000...0//k//00...01 is divisible by 3 and thus not prime.
a(n) <= A100026(n-1) with equality when a(n) is a palindrome. - Michel Marcus, Sep 11 2015

Examples

			a(1) = 3, because 10001, 10101, and 10201 are composite and 10301 is prime.
a(6) = 29, because 29 is the smallest k such that 1000000//k//0000001 is prime. The decimal expansion of that prime is 1000000290000001.
		

Crossrefs

Programs

  • Mathematica
    Table[k = 0; d = IntegerDigits[10^n]; While[! PrimeQ@ FromDigits@ Join[d, IntegerDigits@ k, Reverse@ d], k++]; k, {n, 0, 65}] (* Michael De Vlieger, Aug 26 2015 *)
  • PARI
    a(n) = x=10^n; k=0; while(!ispseudoprime(eval(Str(x, k, concat(Vecrev(Str(x)))))), k++); k
    
  • Perl
    use ntheory ":all"; for my $n (0..50) { my($t,$c)=(0); $t++ while $c=1 . 0 x $n . $t . 0 x $n . 1, !is_prob_prime($c); say "$n $t"; } # Dana Jacobsen, Oct 02 2015
Showing 1-8 of 8 results.