%I #24 Sep 26 2021 13:17:28
%S 0,1,352,9909,107776,698125,3252096,12045817,37679104,103495401,
%T 256420000,584190541,1241471232,2487920149,4741917376,8654360625,
%U 15207694336,25846158097,42644120544,68520305701,107506720000,165082149981,248581222912,367691205289
%N a(n) = (n^9 + 5*n^8 + 4*n^7 - n^6 - 5*n^5 + 2*n^4)/6.
%H Colin Barker, <a href="/A255501/b255501.txt">Table of n, a(n) for n = 0..1000</a>
%H L. Kaylor and D. Offner, <a href="https://projecteuclid.org/euclid.involve/1513733722">Counting matrices over a finite field with all eigenvalues in the field</a>, Involve, a Journal of Mathematics, Vol. 7 (2014), No. 5, 627-645, see Theorem 6.1. [<a href="http://dx.doi.org/10.2140/involve.2014.7.627">DOI</a>]
%H <a href="/index/Rec#order_10">Index entries for linear recurrences with constant coefficients</a>, signature (10,-45,120,-210,252,-210,120,-45,10,-1).
%F a(n) = n^4 * (n^5 + 5*n^4 + 4*n^3 - n^2 - 5*n + 2)/6.
%F G.f.: x*(1 +342*x +6434*x^2 +24406*x^3 +24240*x^4 +5354*x^5 -242*x^6 -54*x^7 -x^8)/(1-x)^10. - _Colin Barker_, Mar 14 2015
%F E.g.f.: (x/6)* (6 +1050*x +8856*x^2 +17562*x^3 +12741*x^4 +4059*x^5 +606*x^6 +41*x^7 +x^8)*exp(x). - _G. C. Greubel_, Sep 24 2021
%p fp:=n->(n^9+5*n^8+4*n^7-n^6-5*n^5+2*n^4)/6;
%p [seq(fp(n), n=0..40)];
%t Table[n^4*(n^5 +5*n^4 +4*n^3 -n^2 -5*n +2)/6, {n, 0, 30}] (* _G. C. Greubel_, Sep 24 2021 *)
%o (Python)
%o # requires Python 3.2 or higher
%o from itertools import accumulate
%o A255501_list, m = [0], [60480, -208320, 273840, -168120, 45420, -2712, -648, 62, -1, 0]
%o for _ in range(10**2):
%o ....m = list(accumulate(m))
%o A255501_list.append(m[-1]) # _Chai Wah Wu_, Mar 14 2015
%o (PARI)
%o concat(0, Vec(x*(1 +342*x +6434*x^2 +24406*x^3 +24240*x^4 +5354*x^5 -242*x^6 -54*x^7 -x^8)/(1-x)^10 + O(x^100))) \\ _Colin Barker_, Mar 14 2015
%o (Sage) [n^4*(n^5 +5*n^4 +4*n^3 -n^2 -5*n +2)/6 for n in (0..30)] # _G. C. Greubel_, Sep 24 2021
%Y Cf. A229740, A255500.
%K nonn,easy
%O 0,3
%A _N. J. A. Sloane_, Mar 13 2015
|