%I #27 Apr 25 2024 10:43:57
%S 1,1,2,2,2,3,2,3,3,4,3,4,4,4,5,3,4,5,5,5,6,4,5,6,6,6,6,7,4,6,6,7,7,7,
%T 7,8,5,6,7,8,8,8,8,8,9,5,7,8,8,9,9,9,9,9,10,6,8,9,9,10,10,10,10,10,10,
%U 11,6,8,9,10,10,11,11,11,11,11,11,12,7,9,10,11,11,12,12,12,12,12,12,12,13,7,10,11,12,12,12,13,13,13,13,13,13,13,14,8,10,12,12,13,13,14,14,14,14,14,14,14,14,15
%N Triangle T(n,k) = floor(k*(n+1)/(k+1)), 1 <= k <= n.
%C T(n,k) is the maximum number of wins in a sequence of n games in which the longest winning streak is of length k.
%C T(n,k) generalizes the pattern found in sequence A004523 where A004523(n) = floor(2n/3).
%H Reinhard Zumkeller, <a href="/A182210/b182210.txt">Rows n = 1..150 of triangle, flattened</a>
%H Sela Fried and Toufik Mansour, <a href="https://doi.org/10.47443/dml.2023.218">The total number of descents and levels in (cyclic) tensor words</a>, Disc. Math. Lett. (2024) Vol. 13, 44-49. See p. 49.
%F T(n,k) = floor(k(n+1)/(k+1)).
%e T(12,4) = 10 since 10 is the maximum number of wins in a 12-game sequence in which the longest winning streak is 4. One such sequence with 10 wins is WWWWLWWWWLWW.
%e The triangle T(n,k) begins
%e 1,
%e 1, 2,
%e 2, 2, 3,
%e 2, 3, 3, 4,
%e 3, 4, 4, 4, 5,
%e 3, 4, 5, 5, 5, 6,
%e 4, 5, 6, 6, 6, 6, 7,
%e 4, 6, 6, 7, 7, 7, 7, 8,
%e 5, 6, 7, 8, 8, 8, 8, 8, 9,
%e 5, 7, 8, 8, 9, 9, 9, 9, 9, 10,
%e 6, 8, 9, 9, 10, 10, 10, 10, 10, 10, 11,
%e 6, 8, 9, 10, 10, 11, 11, 11, 11, 11, 11, 12,
%p seq(seq(floor(k*(n+1)/(k+1)),k=1..n),n=1..15);
%t Flatten[Table[Floor[k*(n+1)/(k+1)],{n,0,20},{k,n}]] (* _Harvey P. Dale_, Jul 21 2015 *)
%o (Haskell)
%o a182210 n k = a182210_tabl !! (n-1) !! (k-1)
%o a182210_tabl = [[k*(n+1) `div` (k+1) | k <- [1..n]] | n <- [1..]]
%o -- _Reinhard Zumkeller_, Jul 08 2012
%Y A004523(n+1) = T(n,2).
%K nonn,nice,easy,tabl,look
%O 1,3
%A _Dennis P. Walsh_, Apr 18 2012