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-10 of 16 results. Next

A083571 Numbers k such that A008509(k) is prime.

Original entry on oeis.org

2, 3, 5, 10, 12, 72
Offset: 1

Views

Author

N. J. A. Sloane, Jun 14 2003

Keywords

Crossrefs

Programs

  • Mathematica
    palQ[n_]:=Reverse[x=IntegerDigits[n]]==x; t={}; c=0; Do[If[palQ[n*(n+1)/2],c=c+1; If[PrimeQ[n],AppendTo[t,c]]],{n,10^3}]; t (* Jayanta Basu, May 14 2013 *)
  • PARI
    ispal(n)=n=digits(n); for(i=1, #n\2, if(n[i]!=n[#n+1-i], return(0))); 1
    for(k=1,1e9,if(ispal(k*(k+1)/2),n++;if(isprime(k),print1(n", ")))) \\ Charles R Greathouse IV, May 15 2013

A003098 Palindromic triangular numbers.

Original entry on oeis.org

0, 1, 3, 6, 55, 66, 171, 595, 666, 3003, 5995, 8778, 15051, 66066, 617716, 828828, 1269621, 1680861, 3544453, 5073705, 5676765, 6295926, 35133153, 61477416, 178727871, 1264114621, 1634004361, 5289009825, 6172882716, 13953435931
Offset: 1

Views

Author

Keywords

Comments

The only known terms with an even number 2*m of digits that are the concatenation of two palindromes with m digits are 55, 66 and 828828 (see David Wells entry 828828). - Bernard Schott, Apr 29 2022

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • Charles W. Trigg, Palindromic Triangular Numbers, J. Rec. Math., 6 (1973), 146-147.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers, p. 73 and p. 178, entry 828828 (Rev. ed. 1997)

Crossrefs

Cf. A008509.
Intersection of A000217 and A002113.

Programs

  • Mathematica
    palQ[n_]:=Module[{idn=IntegerDigits[n]},idn==Reverse[idn]]; Select[ Accumulate[ Range[200000]],palQ]  (* Harvey P. Dale, Mar 23 2011 *)
    Select[Accumulate[Range[0,170000]],PalindromeQ] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Sep 15 2019 *)
  • PARI
    list(lim)=my(v=List(),d); for(n=0,(sqrt(8*lim+1)-1)/2, d=digits(n*(n+1)/2); if(d==Vecrev(d), listput(v,n*(n+1)/2))); Vec(v) \\ Charles R Greathouse IV, Jun 23 2017
    
  • Python
    A003098_list = [m for m in (n*(n+1)//2 for n in range(10**5)) if str(m) == str(m)[::-1]] # Chai Wah Wu, Sep 03 2021

A054263 Number of palindromic triangular numbers with n digits.

Original entry on oeis.org

3, 2, 3, 3, 2, 2, 6, 2, 1, 4, 7, 0, 4, 4, 12, 5, 6, 2, 3, 2, 6, 3, 6, 2, 2, 4, 3, 2, 5, 0, 3, 2, 1, 4, 3, 1, 10, 1, 4, 0
Offset: 1

Views

Author

Patrick De Geest, Apr 15 2000

Keywords

Examples

			a(10) = 4: 1264114621, 1634004361, 5289009825, 6172882716.
		

Crossrefs

A028336 Positive numbers k such that k*(k+1) is a palindrome.

Original entry on oeis.org

1, 2, 16, 77, 538, 1621, 2457, 5291, 5313, 52008, 142401, 143498, 1610151, 1713543, 4670028, 5218983, 15137566, 15282411, 15814148, 47370058, 50702751, 142594226, 166691108, 1694576061, 2554554552, 25541432472, 47878213558, 77714915542, 155482156418
Offset: 1

Views

Author

Keywords

Comments

For additional terms, see the De Geest link.

Crossrefs

Programs

  • Mathematica
    Select[Range[500000], PalindromeQ[#(#+1)] &] (* or *) Select[Range[50000], IntegerDigits[#(#+1)] == Reverse[ IntegerDigits[#(#+1)]] &] (* G. C. Greubel, Nov 24 2016 *)
  • PARI
    isok(k) = my(d = digits(k*(k+1))); Vecrev(d) == d; \\ Michel Marcus, Nov 09 2017

Extensions

More terms from Jon E. Schoenfield, Nov 09 2017

A050722 Palindromic triangular numbers arising from A050721 and A083571.

Original entry on oeis.org

3, 6, 66, 5995, 15051, 15199896744769899151
Offset: 1

Views

Author

Patrick De Geest, Sep 15 1999

Keywords

Crossrefs

A068641 Smallest n-digit palindromic triangular number, or 0 if no such number exists.

Original entry on oeis.org

1, 55, 171, 3003, 15051, 617716, 1269621, 35133153, 178727871, 1264114621, 13953435931, 0, 1313207023131, 19895044059891, 114401848104411, 1250444114440521, 11121736463712111, 357961407704169753
Offset: 1

Views

Author

Amarnath Murthy, Feb 28 2002

Keywords

Examples

			a(4) = 3003 = 77*78/2 is the smallest 4-digit palindromic triangular number.
a(12) = 0 as no 12-digit palindromic triangular number exists.
		

Crossrefs

Extensions

Edited by Patrick De Geest, Mar 24 2002

A068642 Index of the smallest n-digit palindromic triangular number, or 0 if no such number exists.

Original entry on oeis.org

1, 10, 18, 77, 173, 1111, 1593, 8382, 18906, 50281, 167053, 0, 1620621, 6307938, 15126258, 50008881, 149142458, 846122222, 2480116437, 5513600773, 14667896198, 49786655918, 246644446642, 529670494286, 2466444446642
Offset: 1

Views

Author

Amarnath Murthy, Feb 28 2002

Keywords

Examples

			a(4) = 77 as 77*78/2 = 3003 is the smallest 4-digit palindromic triangular number.
a(12) = 0 as no 12-digit palindromic triangular number exists.
		

Crossrefs

Extensions

Edited by Patrick De Geest, Mar 24 2002

A068643 Largest n-digit palindromic triangular number, or 0 if no such number exists.

Original entry on oeis.org

6, 66, 666, 8778, 66066, 828828, 6295926, 61477416, 178727871, 6172882716, 87350505378, 0, 68742000024786, 82078700787028, 684866959668486, 8208268228628028, 67898244444289876, 514816979979618415
Offset: 1

Views

Author

Amarnath Murthy, Feb 28 2002

Keywords

Examples

			a(4) = 8778 = 132*133/2 is the largest 4-digit palindromic triangular number.
a(12) = 0 as no 12-digit palindromic triangular number exists.
		

Crossrefs

Extensions

Edited by Patrick De Geest, Mar 24 2002

A068644 Index of the largest n-digit palindromic triangular number, or 0 if no such number exists.

Original entry on oeis.org

3, 11, 36, 132, 363, 1287, 3548, 11088, 18906, 111111, 417972, 0, 3707883, 12812392, 37009916, 128127032, 368505751, 1014708805, 3567632391, 11151642876, 36657342048, 104561417190, 417898160427, 1325269593372
Offset: 1

Views

Author

Amarnath Murthy, Feb 28 2002

Keywords

Examples

			a(4) = 132 as 132*133/2 = 8778 is the largest 4-digit palindromic triangular number.
a(12) = 0 as no 12-digit palindromic triangular number exists.
		

Crossrefs

Extensions

Edited by Patrick De Geest, Mar 24 2002

A350988 Numbers k such that the k-th triangular number is a binary palindrome.

Original entry on oeis.org

0, 1, 2, 5, 6, 9, 17, 21, 25, 33, 42, 65, 90, 129, 170, 257, 341, 357, 450, 513, 693, 893, 1025, 1365, 1397, 1445, 1617, 1670, 1750, 2049, 2730, 4097, 5418, 5985, 8193, 10397, 10922, 16385, 17313, 21717, 21845, 31749, 32769, 40637, 43605, 51537, 63482, 65537, 76217
Offset: 1

Views

Author

Amiram Eldar, Jan 28 2022

Keywords

Comments

This sequence is infinite since 2^k+1 is a term for all k>1 (Trigg, 1974).

Examples

			2 is a term since A000217(2) = 2*(2+1)/2 = 3 = 11_2 is a triangular number and also a binary palindromic number.
5 is a term since A000217(5) = 5*(5+1)/2 = 15 = 1111_2 is a triangular number and also a binary palindromic number.
		

Crossrefs

The binary version of A008509.
A000051 \ {3} is a subsequence.

Programs

  • Mathematica
    Select[Range[0, 10^5], PalindromeQ[IntegerDigits[#*(# + 1)/2, 2]] &]
  • PARI
    isok(k) = my(b=binary(k*(k+1)/2)); b == Vecrev(b); \\ Michel Marcus, Jan 28 2022
    
  • Python
    def ok(n): b = bin(n*(n+1)//2)[2:]; return b == b[::-1]
    print([k for k in range(80000) if ok(k)]) # Michael S. Branicky, Jan 28 2022

Formula

A000217(a(n)) = A350987(n).
Showing 1-10 of 16 results. Next