%I #19 Sep 08 2022 08:46:21
%S 0,1,19,90,266,615,1221,2184,3620,5661,8455,12166,16974,23075,30681,
%T 40020,51336,64889,80955,99826,121810,147231,176429,209760,247596,
%U 290325,338351,392094,451990,518491,592065,673196,762384,860145,967011,1083530,1210266,1347799,1496725,1657656,1831220
%N a(n) = trinomial(2*n, 4) = (1/6)*n*(2*n - 1)*(2*n^2 + 7*n - 3).
%C The irregular triangle of trinomial coefficients is given in A027907 with the Comtet reference.
%D L. Comtet, Advanced Combinatorics, Reidel, 1974, pp. 77-78. (In the integral formula on p. 77 a left bracket is missing for the cosine argument.)
%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (5,-10,10,-5, 1).
%F a(n) = A027907(2*n, 4), n >= 0. a(n) = A027907(2*n, 4*(n-1)), for n >= 1 (symmetry).
%F a(n) = binomial(2*n, 2) + (2*n)*binomial(2*n-1, 2) + binomial(2*n, 4)(from the trinomial definition) = (1/6)*n*(2*n - 1)*(2*n^2 + 7*n - 3).
%F G.f.: x*(1 + 14*x + 5*x^2 - 4*x^3)/(1 - x)^5.
%F a(n) = (1/Pi)*Integral_{x=0..2} (1/sqrt(4 - x^2))*(x^2 - 1)^(2*n)*R(4*(n-2), x), n >= 0, with the R polynomial coefficients given in A127672. Note that R(-n, x) = R(n, x) [Comtet, p. 77, the integral formula for q = 3, n -> 2*n, k = 4, rewritten with x = 2*cos(phi)]. For the odd numbered rows see A302709.
%t LinearRecurrence[{5, -10, 10, -5, 1}, {0, 1, 19, 90, 266}, 41] (* _Vincenzo Librandi_, Feb 28 2018 *)
%o (Magma) [(1/6)*n*(2*n-1)*(2*n^2+7*n-3): n in [0..40]]; // _Vincenzo Librandi_, Apr 28 2018
%o (PARI) a(n) = n*(2*n-1)*(2*n^2+7*n-3)/6; \\ _Altug Alkan_, May 01 2018
%o (PARI) a(n) = polcoeff((1 + x + x^2)^(2*n), 4); \\ _Michel Marcus_, May 04 2018
%Y Cf. A014105 (k=2), A027907, A131423 (k=3), A127672, A302709.
%K nonn,easy
%O 0,3
%A _Wolfdieter Lang_, Apr 27 2018