login
A104881
Triangle T(n,k) = Sum_{j=0..k} (n-k)^(k-j), read by rows.
3
1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 7, 4, 1, 1, 5, 13, 15, 5, 1, 1, 6, 21, 40, 31, 6, 1, 1, 7, 31, 85, 121, 63, 7, 1, 1, 8, 43, 156, 341, 364, 127, 8, 1, 1, 9, 57, 259, 781, 1365, 1093, 255, 9, 1, 1, 10, 73, 400, 1555, 3906, 5461, 3280, 511, 10, 1, 1, 11, 91, 585, 2801, 9331, 19531, 21845, 9841, 1023, 11, 1
OFFSET
0,5
COMMENTS
Reverse of triangle A104878.
FORMULA
T(n, k) = Sum_{j=0..k} (n-k)^(k-j).
Sum_{k=0..n} T(n, k) = A104879(n).
Sum_{k=0..floor(n/2)} T(k, n-k) = A104882(n).
EXAMPLE
Triangle begins as:
1;
1, 1;
1, 2, 1;
1, 3, 3, 1;
1, 4, 7, 4, 1;
1, 5, 13, 15, 5, 1;
MATHEMATICA
T[n_, k_]:= If[k==n, 1, Sum[(n-k)^(k-j), {j, 0, k}]];
Table[T[n, k], {n, 0, 12}, {k, 0, n}]//Flatten (* G. C. Greubel, Jun 15 2021 *)
PROG
(Magma) [(&+[ (n-k)^(k-j): j in [0..k]]): k in [0..n], n in [0..12]]; // G. C. Greubel, Jun 15 2021
(Sage) flatten([[sum((n-k)^(k-j) for j in (0..k)) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Jun 15 2021
CROSSREFS
Cf. A104878, A104879 (row sums), A104882 (diagonal sums).
Sequence in context: A327913 A028657 A053534 * A171699 A104878 A196863
KEYWORD
easy,nonn,tabl
AUTHOR
Paul Barry, Mar 28 2005
STATUS
approved