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-4 of 4 results.

A062209 Numbers k such that the smoothly undulating palindromic number (4*10^k-7)/33 = 121...21 is a prime (or PRP).

Original entry on oeis.org

7, 11, 43, 139, 627, 1399, 1597, 1979, 7809, 14059, 46499
Offset: 1

Views

Author

Patrick De Geest and Hans Rosenthal (Hans.Rosenthal(AT)t-online.de), Jun 15 2001

Keywords

Comments

Prime versus probable prime status and proofs are given in the author's table.
No further terms < 100000. - Ray Chandler, Aug 17 2011
The corresponding primes, called smoothly undulating palindromic primes (cf. links, A032758 and A059758), are listed in A092696. The number of '12's is given in A056803(n) = (a(n)-1)/2. - M. F. Hasler, Jul 30 2015

Examples

			k=11 --> (12*10^11 - 21)/99 = 12121212121.
		

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 139, p. 48, Ellipses, Paris 2008.

Crossrefs

Programs

  • Mathematica
    d[n_]:=IntegerDigits[n]; Length/@d[Select[NestList[FromDigits[Join[d[#],{2,1}]]&,1,1000],PrimeQ]] (* Jayanta Basu, May 25 2013 *)
  • PARI
    for(n=1,1e5,ispseudoprime(5^n<<(n+2)\33)&&print1(n",")) \\ M. F. Hasler, Jul 30 2015

Extensions

a(11) = 46499 from Ray Chandler, Nov 11 2010
Edited by Ray Chandler, Aug 17 2011
Name and other items edited by M. F. Hasler, Jul 30 2015

A037487 Decimal expansion of a(n) is given by the first n terms of the periodic sequence with initial period 1,2.

Original entry on oeis.org

1, 12, 121, 1212, 12121, 121212, 1212121, 12121212, 121212121, 1212121212, 12121212121, 121212121212, 1212121212121, 12121212121212, 121212121212121, 1212121212121212, 12121212121212121, 121212121212121212, 1212121212121212121, 12121212121212121212
Offset: 1

Views

Author

Keywords

Comments

See A037610 for a general formula. - Hieronymus Fischer, Jan 03 2013
(Smoothly undulating palindromic) primes in this sequence are listed in A092696(n) = (4*10^A062209(n)-7)/33. - M. F. Hasler, Jul 30 2015

Crossrefs

Cf. A037610.

Programs

  • Mathematica
    Table[FromDigits[PadRight[{},n,{1,2}]],{n,20}] (* or *) LinearRecurrence[ {10,1,-10},{1,12,121},20] (* Harvey P. Dale, Jun 21 2016 *)
  • PARI
    A037487(n)=10^n*4\33  \\ - M. F. Hasler, Jan 13 2013
    
  • PARI
    Vec(x*(2*x+1)/((x-1)*(x+1)*(10*x-1)) + O(x^100)) \\ Colin Barker, Apr 30 2014

Formula

a(n) = floor((4/33)*10^n). - Hieronymus Fischer, Jan 03 2013
a(n) = 10*a(n-1)+a(n-2)-10*a(n-3). G.f.: x*(2*x+1) / ((x-1)*(x+1)*(10*x-1)). - Colin Barker, Apr 30 2014

A056803 Numbers k such that k copies of 12 followed by 1 is a palindromic prime.

Original entry on oeis.org

3, 5, 21, 69, 313, 699, 798, 989, 3904, 7029, 23249
Offset: 1

Views

Author

Robert G. Wilson v, Aug 22 2000

Keywords

Examples

			12121212121 is prime so 5 is a term.
		

Crossrefs

Corresponding primes are given in A092696. Corresponding decimal digit lengths are given in A062209. a(k) = (A062209(k-1)-1)/2.

Programs

  • Mathematica
    Do[m = n; If[PrimeQ[120(10^(2n) - 1)/99 + 1], Print[n]], {n, 1, 600}]
    (IntegerLength[#]-1)/2&/@Select[10#+1&/@Table[FromDigits[Flatten[ IntegerDigits/@ PadRight[{},n,{1,2}]]],{n,2,15000,2}],PrimeQ] (* Harvey P. Dale, Apr 02 2020 *)

Extensions

More terms from Rick L. Shepherd, Mar 04 2004
Definition clarified by N. J. A. Sloane, Nov 09 2024
a(11) from Michael S. Branicky, Dec 11 2024

A153328 Numbers k such that (10^k-1)*120/99 + 1 is prime.

Original entry on oeis.org

6, 10, 42, 138, 626, 1398, 1596, 1978, 7808, 14058, 46498
Offset: 1

Views

Author

Cino Hilliard, Dec 23 2008

Keywords

Comments

Also 2*A056803 which I took the liberty of using to create the last 2 entries.
These numbers are always even. If n is odd, then 10^n-1 produces a number with an odd number of 9's which 99 does not divide. a(6), a(10), a(42) are 1212121, 12121212121, 1212121212121212121212121212121212121212121 which can be found in A092696. Also, the formula produce palindromic numbers.

Crossrefs

Programs

  • PARI
    /* n=number of values to test; r=repeat digits, e.g., 12, 121, 177, 1234; d = last digit appended to the end */
    repr(n,r,d) = ln=length(Str(r));for(x=0,n,y=(10^(ln*x)-1)*10*r/ (10^ln-1)+1;if(ispseudoprime(y),print1(ln*x",")))

Extensions

a(11) from Michael S. Branicky, Dec 11 2024
Showing 1-4 of 4 results.