A008766 Expansion of (1+x^5)/((1-x)*(1-x^2)*(1-x^3)*(1-x^4)).
1, 1, 2, 3, 5, 7, 10, 13, 18, 23, 29, 36, 45, 54, 65, 77, 91, 106, 123, 141, 162, 184, 208, 234, 263, 293, 326, 361, 399, 439, 482, 527, 576, 627, 681, 738, 799, 862, 929, 999, 1073, 1150, 1231, 1315, 1404, 1496, 1592, 1692, 1797, 1905, 2018, 2135, 2257, 2383, 2514, 2649, 2790, 2935
Offset: 0
Links
- Washington Bomfim, Table of n, a(n) for n = 0..9999 (first 1000 terms from G. C. Greubel)
- Index entries for linear recurrences with constant coefficients, signature (2,-1,1,-1,-1,1,-1,2,-1).
Programs
-
GAP
a:=[1,1,2,3,5,7,10,13,18];; for n in [10..60] do a[n]:=2*a[n-1]-a[n-2]+a[n-3]-a[n-4]-a[n-5]+a[n-6]-a[n-7]+2*a[n-8]-a[n-9]; od; a; # G. C. Greubel, Sep 10 2019
-
Magma
R
:=PowerSeriesRing(Integers(), 60); Coefficients(R!( (1+x^5)/((1-x)*(1-x^2)*(1-x^3)*(1-x^4)) )); // G. C. Greubel, Sep 10 2019 -
Maple
seq(coeff(series((1+x^5)/((1-x)*(1-x^2)*(1-x^3)*(1-x^4)), x, n+1), x, n), n = 0 .. 60); # G. C. Greubel, Sep 10 2019
-
Mathematica
CoefficientList[Series[(1+x^5)/(1-x)/(1-x^2)/(1-x^3)/(1-x^4),{x,0,60}],x] (* or *) LinearRecurrence[{2,-1,1,-1,-1,1,-1,2,-1}, {1,1,2,3,5,7,10, 13,18}, 60] (* Harvey P. Dale, Jul 24 2016 *)
-
PARI
Vec((1+x^5)/(1-x)/(1-x^2)/(1-x^3)/(1-x^4) +O(x^99)) \\ Charles R Greathouse IV, Sep 26 2012
-
PARI
seq(x) = { a = vector(x+1); my(N = 5); for(n=0,x, a[n+1]=round((2*N^3-15*N^2+60*N-110*!(N%2)-65*(N%2))/144); N++);a}; seq(60) \\ Washington Bomfim, Jan 14 2021
-
Sage
def A008766_list(prec): P.
= PowerSeriesRing(ZZ, prec) return P((1+x^5)/((1-x)*(1-x^2)*(1-x^3)*(1-x^4))).list() A008766_list(60) # G. C. Greubel, Sep 10 2019
Formula
a(n) = round((2*N^3 - 15*N^2 + 60*N - 110*[N mod 2=0] - 65*[N mod 2])/144), where N = n+5. - Washington Bomfim, Jan 14 2021
Extensions
Terms a(45) onward added by G. C. Greubel, Sep 10 2019
Comments