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.

A352057 Triangular numbers whose nonzero digits are all the same.

This page as a plain text file.
%I A352057 #45 Apr 09 2022 06:36:48
%S A352057 0,1,3,6,10,55,66,300,666,990,3003,5050,10011,66066,500500,600060,
%T A352057 50005000,5000050000,500000500000,50000005000000,5000000050000000,
%U A352057 500000000500000000,50000000005000000000,5000000000050000000000,500000000000500000000000,50000000000005000000000000
%N A352057 Triangular numbers whose nonzero digits are all the same.
%C A352057 This sequence may correspond to "monochromatic step squads" in the British animation "Numberblocks".
%C A352057 Conjecture: the largest term in this sequence whose nonzero digits are not 5 is 600060.
%t A352057 (* Method1 *)
%t A352057 NonZeroQ[n_Integer] := n != 0; Select[
%t A352057 Table[n (n + 1)/2, {n, 0, 1000000}],
%t A352057 Length[Tally[Select[IntegerDigits[#], NonZeroQ]]] == 1 &]
%t A352057 (* Method2 *)
%t A352057 Sort[Select[
%t A352057   Flatten[Outer[Times,
%t A352057     Table[FromDigits[IntegerDigits[n, 2]], {n, 2^16 - 1}], Range[9]]],
%t A352057    IntegerQ[Sqrt[8 # + 1]] &]]
%o A352057 (Python)
%o A352057 from sympy import integer_nthroot
%o A352057 from sympy.utilities.iterables import multiset_permutations
%o A352057 def istri(n): return integer_nthroot(8*n+1, 2)[1]
%o A352057 def zplus1(digits):
%o A352057     if digits == 1: yield 0
%o A352057     for d1 in "123456789":
%o A352057         digset = "0"*(digits-1) + d1*(digits-1)
%o A352057         for mp in multiset_permutations(digset, digits-1):
%o A352057             t = int(d1 + "".join(mp))
%o A352057             yield t
%o A352057 def afind(maxdigits):
%o A352057     for digits in range(1, maxdigits+1):
%o A352057         for t in zplus1(digits):
%o A352057             if istri(t):
%o A352057                 print(t, end=", ")
%o A352057 afind(22) # _Michael S. Branicky_, Mar 02 2022
%o A352057 (PARI) isok(k) = my(d=digits(k*(k+1)/2)); d = select(x->(x!=0), d); #Set(d)<=1;
%o A352057 lista(nn) = {for (n=0, nn, if (isok(n), print1(n*(n+1)/2, ", ")););} \\ _Michel Marcus_, Mar 02 2022
%Y A352057 Supersequence of A037156.
%Y A352057 Cf. A000217, A118668, A125289, A343811.
%Y A352057 Cf. A352148 (indices of these triangular numbers).
%K A352057 nonn,base
%O A352057 1,3
%A A352057 _Steven Lu_, Mar 02 2022
%E A352057 a(24)-a(25) from _Michael S. Branicky_, Mar 02 2022