OFFSET
5,1
LINKS
Colin Barker, Table of n, a(n) for n = 5..1000
Index entries for linear recurrences with constant coefficients, signature (10,-45,120,-210,252,-210,120,-45,10,-1).
FORMULA
a(n) = (17055360 -16329024*n +7697736*n^2 -2299060*n^3 +462798*n^4 -60207*n^5 +4284*n^6 -30*n^7 -18*n^8 +n^9)/362880. - Colin Barker, Nov 25 2014
G.f.: x^5*(3-2*x)*(1 -7*x +23*x^2 -44*x^3 +55*x^4 -44*x^5 +23*x^6 -7*x^7 +x^8)/(1-x)^10. - Colin Barker, Nov 25 2014
MAPLE
seq(coeff(series(x^5*(3-2*x)*(1 -7*x +23*x^2 -44*x^3 +55*x^4 -44*x^5 +23*x^6 -7*x^7 +x^8)/(1-x)^10, x, n+1), x, n), n = 5..40); # G. C. Greubel, Sep 26 2019
MATHEMATICA
LinearRecurrence[{10, -45, 120, -210, 252, -210, 120, -45, 10, -1}, {3, 7, 18, 47, 123, 319, 806, 1954, 4506, 9859}, 40] (* Harvey P. Dale, Aug 04 2017 *)
PROG
(PARI) Vec(-x^5*(2*x-3)*(x^8-7*x^7+23*x^6-44*x^5+55*x^4-44*x^3+23*x^2 -7*x+1)/(x-1)^10 + O(x^40)) \\ Colin Barker, Nov 25 2014
(Magma) R<x>:=PowerSeriesRing(Integers(), 40); Coefficients(R!( x^5*(3 -2*x)*(1-7*x+23*x^2-44*x^3+55*x^4-44*x^5+23*x^6-7*x^7+x^8)/(1-x)^10 )); // G. C. Greubel, Sep 26 2019
(Sage)
def A027971_list(prec):
P.<x> = PowerSeriesRing(ZZ, prec)
return P( x^5*(3-2*x)*(1-7*x+23*x^2-44*x^3+55*x^4-44*x^5+23*x^6-7*x^7 +x^8)/(1-x)^10 ).list()
a=A027971_list(40); a[5:] # G. C. Greubel, Sep 26 2019
(GAP) a:=[3, 7, 18, 47, 123, 319, 806, 1954, 4506, 9859];; for n in [11..40] do a[n]:=10*a[n-1]-45*a[n-2]+120*a[n-3]-210*a[n-4]+252*a[n-5]-210*a[n-6] +120*a[n-7] -45*a[n-8]+10*a[n-9]-a[n-10]; od; a; # G. C. Greubel, Sep 26 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved