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 A368579 #18 Jan 05 2024 12:45:58 %S A368579 1,-1,1,0,0,1,0,0,0,1,0,0,1,0,1,0,0,1,1,0,1,0,0,2,2,1,0,1,0,0,3,3,2,1, %T A368579 0,1,0,0,5,6,4,2,1,0,1,0,0,8,11,7,4,2,1,0,1,0,0,13,20,14,8,4,2,1,0,1, %U A368579 0,0,21,37,27,15,8,4,2,1,0,1 %N A368579 Triangle read by rows. T(n, k) is the number of compositions of n where the first part k is the largest part and the last part is not 1. %F A368579 T(n, k) = F(k+1, n+1-k) - F(k+1, n-k) where F(k, n) = Sum_{j=1..min(n, k)} F(k, n-j) if n > 1 and otherwise n. F(n, k) refers to the generalized Fibonacci numbers A092921. %e A368579 Triangle T(n, k) starts: %e A368579 [0] [ 1] %e A368579 [1] [-1, 1] %e A368579 [2] [ 0, 0, 1] %e A368579 [3] [ 0, 0, 0, 1] %e A368579 [4] [ 0, 0, 1, 0, 1] %e A368579 [5] [ 0, 0, 1, 1, 0, 1] %e A368579 [6] [ 0, 0, 2, 2, 1, 0, 1] %e A368579 [7] [ 0, 0, 3, 3, 2, 1, 0, 1] %e A368579 [8] [ 0, 0, 5, 6, 4, 2, 1, 0, 1] %e A368579 [9] [ 0, 0, 8, 11, 7, 4, 2, 1, 0, 1] %e A368579 For instance, row 6 lists the compositions below: %e A368579 0 . %e A368579 1 . %e A368579 2 [2, 2, 2], [2, 1, 1, 2]; %e A368579 3 [3, 3], [3, 1, 2]; %e A368579 4 [4, 2]; %e A368579 5 . %e A368579 6 [6]. %o A368579 (Python) %o A368579 from functools import cache %o A368579 @cache %o A368579 def F(k, n): %o A368579 return sum(F(k, n-j) for j in range(1, min(k, n))) if n > 1 else n %o A368579 def Trow(n): %o A368579 return list(F(k+1, n+1-k) - F(k+1, n-k) for k in range(n+1)) %o A368579 print(flatten([Trow(n) for n in range(12)])) %Y A368579 Cf. A368279 (row sums), A092921 (generalized Fibonacci), A000045 (Fibonacci column k=2), A034008 (T(2n, n)). %K A368579 sign,tabl %O A368579 0,24 %A A368579 _Peter Luschny_, Jan 05 2024