login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A157174
Triangle, read by rows, T(n,k,m) = (m*(n-k)+1)*binomial(n-1, k-1) + (m*k+1)* binomial(n-1, k) - m*k*(n-k)*binomial(n-2, k-1), with m = 3.
2
1, 1, 1, 1, 5, 1, 1, 9, 9, 1, 1, 13, 18, 13, 1, 1, 17, 28, 28, 17, 1, 1, 21, 39, 38, 39, 21, 1, 1, 25, 51, 35, 35, 51, 25, 1, 1, 29, 64, 11, -50, 11, 64, 29, 1, 1, 33, 78, -42, -294, -294, -42, 78, 33, 1, 1, 37, 93, -132, -798, -1218, -798, -132, 93, 37, 1
OFFSET
0,5
COMMENTS
Row sums are: {1, 2, 7, 20, 46, 92, 160, 224, 160, -448, -28166, ...}.
FORMULA
T(n,k,m) = (m*(n-k)+1)*binomial(n-1, k-1) + (m*k+1)* binomial(n-1, k) - m*k*(n-k)*binomial(n-2, k-1), with m = 3.
EXAMPLE
Triangle begins as:
1;
1, 1;
1, 5, 1;
1, 9, 9, 1;
1, 13, 18, 13, 1;
1, 17, 28, 28, 17, 1;
1, 21, 39, 38, 39, 21, 1;
1, 25, 51, 35, 35, 51, 25, 1;
1, 29, 64, 11, -50, 11, 64, 29, 1;
1, 33, 78, -42, -294, -294, -42, 78, 33, 1;
1, 37, 93, -132, -798, -1218, -798, -132, 93, 37, 1;
MAPLE
T:= proc(n, k, m) option remember;
if k=0 and n=0 then 1
else (m*(n-k)+1)*binomial(n-1, k-1) + (m*k+1)* binomial(n-1, k) - m*k*(n-k)*binomial(n-2, k-1)
fi; end:
seq(seq(T(n, k, 3), k=0..n), n=0..10); # G. C. Greubel, Nov 29 2019
MATHEMATICA
T[n_, k_, m_]:= If[n==0 && k==0, 1, (m*(n-k)+1)*Binomial[n-1, k-1] + (m*k+1)*Binomial[n-1, k] +-m*k*(n-k)*Binomial[n-2, k-1]]; Table[T[n, k, 3], {n, 0, 10}, {k, 0, n}]//Flatten (* modified by G. C. Greubel, Nov 29 2019 *)
PROG
(PARI) T(n, k, m) = (m*(n-k)+1)*binomial(n-1, k-1) + (m*k+1)* binomial(n-1, k) - m*k*(n-k)*binomial(n-2, k-1); \\ G. C. Greubel, Nov 29 2019
(Magma) m:=3; [(m*(n-k)+1)*Binomial(n-1, k-1) + (m*k+1)* Binomial(n-1, k) - m*k*(n-k)*Binomial(n-2, k-1): k in [0..n], n in [0..10]]; // G. C. Greubel, Nov 29 2019
(Sage) m=3; [[(m*(n-k)+1)*binomial(n-1, k-1) + (m*k+1)* binomial(n-1, k) - m*k*(n-k)*binomial(n-2, k-1) for k in (0..n)] for n in [0..10]] # G. C. Greubel, Nov 29 2019
(GAP) m:=3;; Flat(List([0..10], n-> List([0..n], k-> (m*(n-k)+1)*Binomial(n-1, k-1) + (m*k+1)* Binomial(n-1, k) - m*k*(n-k)*Binomial(n-2, k-1) ))); # G. C. Greubel, Nov 29 2019
CROSSREFS
Cf. A157172 (m=2), this sequence (m=3).
Sequence in context: A046583 A046579 A153108 * A183450 A296128 A131061
KEYWORD
sign,tabl
AUTHOR
EXTENSIONS
Edited by G. C. Greubel, Nov 29 2019
STATUS
approved