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

A213518 Numbers k such that the triangular number k*(k+1)/2 has 2 different digits in base 10.

Original entry on oeis.org

4, 5, 6, 7, 8, 9, 12, 13, 18, 24, 34, 44, 58, 66, 77, 100, 101, 105, 109, 114, 132, 141, 363, 666, 714, 816, 1000, 1095, 1287, 1332, 1541, 3363, 6666, 10000, 10114, 13332, 66666, 100000, 133332, 666666, 1000000, 1333332, 6666666, 10000000, 13333332, 33336636, 66666666, 100000000
Offset: 1

Views

Author

T. D. Noe, Jun 22 2012

Keywords

Comments

The list of triangular numbers containing only one digit (A045914) is finite. This list is infinite because numbers like 133332, 666666, and 1000000 occur an infinite number of times.
A118668(a(n)) = 2. - Reinhard Zumkeller, Jul 11 2015
For n > 2, A325907(n) is a term. - Seiichi Manyama, Sep 15 2019

Crossrefs

Cf. A062691 (the corresponding triangular numbers), A213516, A213517, A325907.
Cf. A118668.
Cf. A187127.

Programs

  • Haskell
    a213518 n = a213518_list !! (n-1)
    a213518_list = filter ((== 2) . a118668) [0..]
    -- Reinhard Zumkeller, Jul 11 2015
    
  • Mathematica
    t = {}; Do[tri = n*(n+1)/2; If[Length[Union[IntegerDigits[tri]]] == 2, AppendTo[t, n]], {n, 10^5}]; t
  • PARI
    for(k=0, 1e8, if(#Set(digits(k*(k+1)/2))==2, print1(k", "))) \\ Seiichi Manyama, Sep 15 2019

Extensions

a(45)-a(48) from Seiichi Manyama, Sep 15 2019

A227218 Smallest triangular number ending in n ones.

Original entry on oeis.org

1, 1711, 105111, 6271111, 664611111, 222222111111, 22222221111111, 2222222211111111, 2517912111111111, 18428299161111111111, 2222222222211111111111, 222222222222111111111111, 22222222222221111111111111, 1090161504430911111111111111
Offset: 1

Views

Author

Shyam Sunder Gupta, Sep 19 2013

Keywords

Comments

If a triangular number ends in like digits then it can only end in 0's, 1's, 5's or 6's.
The sequence is infinite because the sequence of triangular numbers 21, 2211, 222111, 22221111, ... (A319170) is infinite.

Examples

			a(2) = 1711 because 1711 is the smallest triangular number ending in  2 '1's.
		

Crossrefs

Programs

  • Mathematica
    t = {}; Do[Do[x = n*(n + 1)/2;If[Mod[x, 10^m] == (10^m - 1)/9, AppendTo[t, x]; Break[]], {n, 1, 10^m}], {m, 1, 10}]; t
    a[n_] := Block[{x, y, s}, s = y /. List@ ToRules[ Reduce[(y+1)* y/2 == x*10^n +(10^n - 1)/9 && y > 0 && x >= 0, {y, x}, Integers] /. C[1] -> 0]; Min[s*(s + 1)/2]]; Array[a, 20] (* Giovanni Resta, Sep 20 2013 *)
  • Python
    from sympy import sqrt_mod_iter
    def A227218(n):
        k, a = 10**n<<1, (10**n-1)//9<<1
        m = (a<<2)+1
        return min(b for b in ((d>>1)*((d>>1)+1) for d in sqrt_mod_iter(m, k) if d&1) if b%k==a)>>1 # Chai Wah Wu, May 04 2024

Extensions

a(11)-a(14) from Giovanni Resta, Sep 20 2013

A227219 Smallest triangular number ending in at least n 5's.

Original entry on oeis.org

15, 55, 6555, 2235555, 717655555, 13140555555, 9206385555555, 1551745755555555, 103835341555555555, 26427628585555555555, 2262637355455555555555, 8808604932555555555555, 4704913988655555555555555, 4704913988655555555555555, 19391196055786555555555555555
Offset: 1

Views

Author

Shyam Sunder Gupta, Sep 19 2013

Keywords

Comments

If a triangular number ends in like digits then it can only end in 0's, 1's, 5's or 6's.

Examples

			a(3)=6555 because 6555 is the smallest triangular number ending in 3 '5's.
		

Crossrefs

Programs

  • Mathematica
    t = {}; Do[Do[x = n*(n + 1)/2;If[Mod[x, 10^m] == 5*(10^m - 1)/9, AppendTo[t, x]; Break[]], {n, 1, 10^m}], {m, 1, 10}]; t
    a[n_] := Block[{x, y, s}, s = y /. List@ ToRules[ Reduce[(y+1)* y/2 == x*10^n + 5*(10^n - 1)/9 && y > 0 && x >= 0, {y, x}, Integers] /. C[1] -> 0]; Min[s*(s + 1)/2]]; Array[a, 20] (* Giovanni Resta, Sep 20 2013 *)
  • Python
    from sympy import sqrt_mod_iter
    def A227219(n):
        k, a = 10**n<<1, 10*(10**n-1)//9
        m = (a<<2)+1
        return min(b for b in ((d>>1)*((d>>1)+1) for d in sqrt_mod_iter(m, k) if d&1) if b%k==a)>>1 # Chai Wah Wu, May 04 2024

Extensions

a(1) corrected and a(11)-a(15) from Giovanni Resta, Sep 20 2013
Name clarified by Michel Marcus, Sep 05 2019

A227220 Smallest triangular number ending in n 6's.

Original entry on oeis.org

6, 66, 666, 8146666, 2340066666, 109704666666, 15212926666666, 66488766666666, 173147535666666666, 11302559226666666666, 14642337066666666666, 77850029701666666666666, 1029964845546666666666666, 3086210323568466666666666666, 4014564887872666666666666666
Offset: 1

Views

Author

Shyam Sunder Gupta, Sep 19 2013

Keywords

Comments

If a triangular number ends in like digits then it can only end in 0's, 1's, 5's or 6's.

Examples

			a(4)=8146666 because 8146666 is the smallest triangular number ending in  4 '6's.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local k;
       k:=min(map(rhs@op, [msolve(k*(k+1)=4/3*(10^n-1),2*10^n)]));
       k*(k+1)/2
    end proc:
    map(f, [$1..30]); # Robert Israel, Sep 04 2019
  • Mathematica
    t = {}; Do[Do[x = n*(n + 1)/2;If[Mod[x, 10^m] == 6*(10^m - 1)/9, AppendTo[t, x]; Break[]], {n, 1, 10^m}], {m, 1, 10}]; t
    a[n_] := Block[{x,y,s}, s = y /. List@ ToRules[ Reduce[(y+1)* y/2 == x*10^n + 2(10^n - 1)/3 && y > 0 && x >= 0, {y, x}, Integers] /. C[1] -> 0]; Min[s*(s + 1)/2]]; Array[a,20] (* Giovanni Resta, Sep 20 2013 *)
  • Python
    from sympy import sqrt_mod_iter
    def A227220(n):
        k, a = 10**n<<1, (10**n-1)//3<<2
        m = (a<<2)+1
        return min(b for b in ((d>>1)*((d>>1)+1) for d in sqrt_mod_iter(m, k) if d&1) if b%k==a)>>1 # Chai Wah Wu, May 04 2024

Extensions

a(11)-a(15) from Giovanni Resta, Sep 20 2013

A088278 Smallest palindromic triangular numbers beginning with palindromes whose first digit is 1, 3, 5, 6, or 8.

Original entry on oeis.org

1, 3, 55, 6, 8778, 114401848104411, 0, 55, 66, 0, 10129457886113466431168875492101, 11121736463712111
Offset: 1

Views

Author

Amarnath Murthy, Sep 29 2003

Keywords

Comments

The possible values of the ones digit of a triangular number are 0,1,3,5,6 and 8. Similarly, one can list the two-digit numbers k such that a triangular number of the form 100r + k can exist, and so on for the first three digits, etc. For palindromes P beginning with numbers other than these (e.g., for 33 and 88, which are two-digit palindromes P that start with 1, 3, 5, 6, or 8 but are not in A187127), the corresponding term is 0.

Examples

			From _Jon E. Schoenfield_, Mar 03 2018: (Start)
        Palindrome P       a(n) = smallest palindromic
       starting with    triangular number starting with P
   n  1, 3, 5, 6, or 8   (or 0 if no such number exists)
  ==  ================  =================================
   1          1                                         1
   2          3                                         3
   3          5                                        55
   4          6                                         6
   5          8                                      8778
   6         11                           114401848104411
   7         33                                         0
   8         55                                        55
   9         66                                        66
  10         88                                         0
  11        101          10129457886113466431168875492101
  12        111                         11121736463712111
  13        121                                         ?
  14        131                             1313207023131
  15        141                                         ?
  16        151                      15199896744769899151
  17        161                                         ?
  18        171                                       171
  19        181                                         ?
  20        191                                         ?
  21        303                                         0
(End)
		

Crossrefs

Cf. A003098 (palindromic triangular numbers), A187127 (numbers that are the residue mod 100 of a triangular number). - Jon E. Schoenfield, Mar 03 2018

Extensions

Name and Comments edited, offset changed to 1, and a(11) and a(12) corrected (a(11) taken from b-file at A003098) by Jon E. Schoenfield, Mar 03 2018
Showing 1-5 of 5 results.