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 A329767 #9 Nov 30 2019 09:10:15 %S A329767 1,2,0,0,2,2,0,2,2,4,0,2,4,6,4,0,2,2,12,12,4,0,2,6,30,18,8,0,0,2,2,44, %T A329767 44,32,4,0,0,2,6,82,76,74,16,0,0,0,2,4,144,138,172,52,0,0,0,0,2,6,258, %U A329767 248,350,156,4,0,0,0,0,2,2,426,452,734,404,28,0,0,0,0 %N A329767 Triangle read by rows where T(n,k) is the number of binary words of length n >= 0 with runs-resistance k, 0 <= k <= n. %C A329767 A composition of n is a finite sequence of positive integers with sum n. %C A329767 For the operation of taking the sequence of run-lengths of a finite sequence, runs-resistance is defined as the number of applications required to reach a singleton. %C A329767 Except for the k = 0 column and the n = 0 and n = 1 rows, this is the triangle appearing on page 3 of Lenormand, which is A319411. Unlike A318928, we do not here require that a(n) >= 1. %C A329767 The n = 0 row is chosen to ensure that the row-sums are A000079, although the empty word arguably has indeterminate runs-resistance. %H A329767 Claude Lenormand, <a href="/A318921/a318921.pdf">Deux transformations sur les mots</a>, Preprint, 5 pages, Nov 17 2003. %e A329767 Triangle begins: %e A329767 1 %e A329767 2 0 %e A329767 0 2 2 %e A329767 0 2 2 4 %e A329767 0 2 4 6 4 %e A329767 0 2 2 12 12 4 %e A329767 0 2 6 30 18 8 0 %e A329767 0 2 2 44 44 32 4 0 %e A329767 0 2 6 82 76 74 16 0 0 %e A329767 0 2 4 144 138 172 52 0 0 0 %e A329767 0 2 6 258 248 350 156 4 0 0 0 %e A329767 0 2 2 426 452 734 404 28 0 0 0 0 %e A329767 For example, row n = 4 counts the following words: %e A329767 0000 0011 0001 0010 %e A329767 1111 0101 0110 0100 %e A329767 1010 0111 1011 %e A329767 1100 1000 1101 %e A329767 1001 %e A329767 1110 %t A329767 runsres[q_]:=If[Length[q]==1,0,Length[NestWhileList[Length/@Split[#]&,q,Length[#]>1&]]-1]; %t A329767 Table[Length[Select[Tuples[{0,1},n],runsres[#]==k&]],{n,0,10},{k,0,n}] %Y A329767 Row sums are A000079. %Y A329767 Column k = 2 is A319410. %Y A329767 Column k = 3 is 2 * A329745. %Y A329767 The version for compositions is A329744. %Y A329767 The version for partitions is A329746. %Y A329767 The number of nonzero entries in row n > 0 is A319412(n). %Y A329767 The runs-resistance of the binary expansion of n is A318928. %Y A329767 Cf. A001037, A096365, A225485, A245563, A319411, A325280, A329747, A329750. %K A329767 nonn,tabl %O A329767 0,2 %A A329767 _Gus Wiseman_, Nov 21 2019