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.
%I A349042 #38 Nov 12 2021 12:25:55 %S A349042 0,1,1,1,3,1,4,1,5,0,1,2,6,1,2,7,2,1,1,1,2,10,4,1,2,2,11,6,1,2,1,2,2, %T A349042 13,9,1,2,1,2,2,15,12,1,2,1,2,1,0,1,3,19,14,2,2,1,2,3,20,17,3,2,1,2,1, %U A349042 0,1,1,1,4,25,19,4,4,1,2,1,0,1,1,5,29,20,4,6,2,3,1,0,1,1,1 %N A349042 Triangle read by rows in which row n >= 1 lists the count of 0's, ..., k's in all previous terms in the triangle. T(0,0) = 0, k is from [0..A049820(n)]. %C A349042 For n >= 1 the n-th row length equals A049820(n) + 1. The same definition, but for k from [0..n] gives A032531. %H A349042 Michael De Vlieger, <a href="/A349042/a349042.png">Scatterplot of a(n)</a> for n=0..31686, i.e., rows 0..256. %H A349042 Michael De Vlieger, <a href="/A349042/a349042_1.png">Scatterplot of a(n)</a>for n=0..518562, i.e., rows 0..1024 %H A349042 <a href="/index/In#inventory">Index entries for sequences related to the inventory sequence</a> %e A349042 Triangle begins: %e A349042 k=0 1 2 3 4 5 %e A349042 n=0: 0; %e A349042 n=1: 1; %e A349042 n=2: 1; %e A349042 n=3: 1, 3; %e A349042 n=4: 1, 4; %e A349042 n=5: 1, 5, 0, 1; %e A349042 n=6: 2, 6, 1; %e A349042 n=7: 2, 7, 2, 1, 1, 1; %t A349042 c[_] = 0; Reap[Do[w = {}; Array[(Set[m, c[#]]; c[m]++; AppendTo[w, m]) &, If[n == 0, 1, n - DivisorSigma[0, n] + 1], 0]; Sow[w], {n, 0, 15}]][[-1, -1]] // Flatten (* _Michael De Vlieger_, Nov 09 2021 *) %o A349042 (Python) %o A349042 from collections import Counter %o A349042 from sympy import divisor_count %o A349042 def auptor(rows): %o A349042 alst, inventory = [0], Counter([0]) %o A349042 for m in range(1, rows): %o A349042 for k in range(m-divisor_count(m)+1): %o A349042 c = inventory[k]; alst.append(c); inventory.update([c]) %o A349042 return alst %o A349042 print(auptor(16)) # _Michael S. Branicky_, Nov 07 2021 %Y A349042 Cf. A032531, A049820. %K A349042 nonn,tabf %O A349042 0,5 %A A349042 _Ctibor O. Zizka_, Nov 06 2021