OFFSET
0,1
LINKS
G. C. Greubel, Rows n = 0..100 of triangle, flattened
FORMULA
T(n, k) = Sum_{j=0..k} Stirling1(n, n-j)*binomial(n,j) + Sum_{j=0..n-k} Stirling1(n, n-j)*binomial(n,j).
EXAMPLE
Triangle begins as:
2;
2, 2;
0, -2, 0;
-1, -10, -10, -1;
20, -4, 86, -4, 20;
-78, -128, 102, 102, -128, -78;
77, -13, 1982, -6628, 1982, -13, 77;
2641, 2494, 1129, 12448, 12448, 1129, 2494, 2641;
MAPLE
with(combinat);
T:= proc(n, k) option remember; add(stirling1(n, n-j)*binomial(n, j), j=0..k) + add(stirling1(n, n-j)* binomial(n, j), j=0..n-k); end;
seq(seq(T(n, k), k=0..n), n=0..10); # G. C. Greubel, Nov 26 2019
MATHEMATICA
T[n_, k_]:= Sum[StirlingS1[n, n-j]*Binomial[n, j], {j, 0, k}] + Sum[StirlingS1[n, n-j]*Binomial[n, j], {j, 0, n-k}];
Table[T[n, k], {n, 0, 10}, {k, 0, n}]//Flatten
PROG
(PARI) T(n, k) = sum(j=0, k, stirling(n, n-j, 1)*binomial(n, j)) + sum(j=0, n-k, stirling(n, n-j, 1)*binomial(n, j)); \\ G. C. Greubel, Nov 26 2019
(Magma)
T:= func< n, k | (&+[StirlingFirst(n, n-j)*Binomial(n, j): j in [0..k]]) + (&+[StirlingFirst(n, n-j)*Binomial(n, j): j in [0..n-k]]) >;
[T(n, k): k in [0..n], n in [0..10]]; // G. C. Greubel, Nov 26 2019
(Sage)
def T(n, k): return sum((-1)^j*stirling_number1(n, n-j)*binomial(n, j) for j in (0..k)) + sum((-1)^j*stirling_number1(n, n-j)*binomial(n, j) for j in (0..n-k))
[[T(n, k) for k in (0..n)] for n in (0..10)] # G. C. Greubel, Nov 26 2019
(GAP)
T:= function(n, k) return Sum([0..k], j-> (-1)^j*Stirling1(n, n-j)*Binomial(n, j)) + Sum([0..n-k], j-> (-1)^j*Stirling1(n, n-j)*Binomial(n, j)); end;
Flat(List([0..10], n-> List([0..n], k-> T(n, k) ))); # G. C. Greubel, Nov 26 2019
CROSSREFS
KEYWORD
sign,tabl
AUTHOR
Roger L. Bagula, Apr 10 2010
EXTENSIONS
Name edited by G. C. Greubel, Nov 27 2019
STATUS
approved