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.

A333867 Table with T(1,1) = 1; for n>1, T(n,k) is the number of k's in rows 1 through n-1.

This page as a plain text file.
%I A333867 #27 Nov 17 2022 05:24:53
%S A333867 1,1,2,2,1,3,2,3,3,1,4,3,3,4,3,5,1,5,3,6,2,1,6,4,7,2,2,1,7,6,7,3,2,2,
%T A333867 1,8,8,8,3,2,3,3,8,9,11,3,2,3,3,3,8,10,15,3,2,3,3,4,1,0,1,10,11,18,4,
%U A333867 2,3,3,5,1,1,1,0,0,0,1,14,12,20,5,3,3,3,5,1,2,2,0,0,0,1,0,0,1,17,14,23,5,5
%N A333867 Table with T(1,1) = 1; for n>1, T(n,k) is the number of k's in rows 1 through n-1.
%C A333867 Equivalently, list 1, where, at stage k>1, write i in list 1 and j in list 2, where i is the number of j's in list 1, for j=1,2,...,m, where m=max number in list 1 from stages 1 to k-1; stage 1 is 1 in list 1.
%C A333867 Differs from A030717 in that this sequence includes 0's. - _Sean A. Irvine_, Apr 08 2020
%C A333867 Nevertheless, this sequence starts each row with the count of 1's, not 0's, whose counts are not recorded in the sequence (cf. A174382, which is also initialized with a 0). - _Peter Munn_, Oct 11 2022
%H A333867 Franklin T. Adams-Watters, <a href="/A333867/b333867.txt">First 32 rows, flattened</a>
%H A333867 Michael De Vlieger, <a href="/A333867/a333867.png">Plot a(w(j) + k - 1) at (j,k)</a> for j = 1..60 and w the sequence of partial sums of A126027, showing a(m) = 0 in black, a(m) = 1 in red, and a(m) > 1 in light blue.
%H A333867 Sean A. Irvine, <a href="https://github.com/archmageirvine/joeis/blob/master/src/irvine/oeis/a333/A333867.java">Java program</a> (github)
%e A333867 1;
%e A333867 1;
%e A333867 2;
%e A333867 2, 1;
%e A333867 3, 2;
%e A333867 3, 3, 1;
%e A333867 4, 3, 3;
%t A333867 t = {{1}}; Do[AppendTo[t, BinCounts[#, {1, Max[#] + 1}] &[Flatten[t]]], {30}];
%t A333867 Map[Length, t] (* A126027*)
%t A333867 Map[Total, t]  (* A253170*)
%t A333867 Flatten[t]     (* A333867 *)  (* _Peter J. C. Moses_, Apr 09 2020 *)
%o A333867 (Haskell)
%o A333867 import Data.List (sort, group)
%o A333867 a030717 n k = a030717_tabf !! (n-1) !! (k-1)
%o A333867 a030717_row n = a030717_tabf !! (n-1)
%o A333867 a030717_tabf = [1] : f [1] where
%o A333867    f xs = ys : f ((filter (> 0) ys) ++ xs) where
%o A333867           ys = h (group $ sort xs) [1..] where
%o A333867                h [] _ = []
%o A333867                h vss'@(vs:vss) (w:ws)
%o A333867                  | head vs == w = (length vs) : h vss ws
%o A333867                  | otherwise    = 0 : h vss' ws
%o A333867 -- _Reinhard Zumkeller_, Dec 28 2014
%Y A333867 Cf. A126027 (row lengths), A006920, A030717 (zeros suppressed).
%Y A333867 Cf. A174382.
%Y A333867 Cf. A253170 (row sums).
%K A333867 nonn,tabf,nice
%O A333867 1,3
%A A333867 _Clark Kimberling_
%E A333867 More terms from _Franklin T. Adams-Watters_, Dec 14 2006