OFFSET
0,3
FORMULA
a(n) = Sum_{k=0..n} binomial(n,k)*trinomial(k,n-k)*n^k.
MAPLE
A027907 := proc(n, k) add( binomial(n, j)*binomial(n-j, k-2*j), j=0..n) ; end proc:
seq(A187667(n), n=0..10) ; # R. J. Mathar, Mar 27 2011
MATHEMATICA
a[n_] := If[n == 0, 1, Coefficient[(1 + n x + n x^2 + n x^3)^n, x^n]]
Table[a[n], {n, 0, 12}]
PROG
(Maxima) makelist(coeff(expand((1+n*x+n*x^2+n*x^3)^n), x, n), n, 0, 12);
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Emanuele Munarini, Mar 12 2011
STATUS
approved