OFFSET
0,3
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (1,1,-1,1,-1,-1,1).
FORMULA
G.f.: (1+x^5)/((1-x^2)^2*(1-x^4)).
a(n) = floor((n^2 + 3*n + 11 + 5*(n+1)*(-1)^n)/16). - Tani Akinari, Jul 07 2014
G.f.: (1 - x + x^2 - x^3 + x^4)/( (1+x^2)*(1+x)^2*(1-x)^3 ). - R. J. Mathar, Dec 18 2014
MAPLE
seq(coeff(series((1+x^5)/((1-x^2)^2*(1-x^4)), x, n+1), x, n), n = 0..70); # G. C. Greubel, Sep 11 2019
MATHEMATICA
CoefficientList[Series[(1+x^5)/((1-x^2)^2(1-x^4)), {x, 0, 70}], x] (* Vincenzo Librandi, Jul 08 2014 *)
LinearRecurrence[{1, 1, -1, 1, -1, -1, 1}, {1, 0, 2, 0, 4, 1, 6}, 70] (* Harvey P. Dale, May 15 2017 *)
PROG
(PARI) Vec((1+x^5)/(1-x^2)^2/(1-x^4)+ O(x^70)) \\ Michel Marcus, Jul 07 2014
(Magma) [Floor((n^2+3*n+11+5*(n+1)*(-1)^n)/16): n in [0..70]]; // Vincenzo Librandi, Jul 08 2014
(Sage)
def A008797_list(prec):
P.<x> = PowerSeriesRing(ZZ, prec)
return P((1+x^5)/((1-x^2)^2*(1-x^4))).list()
A008797_list(70) # G. C. Greubel, Sep 11 2019
(GAP) a:=[1, 0, 2, 0, 4, 1, 6];; for n in [8..70] do a[n]:=a[n-1]+a[n-2]-a[n-3]+a[n-4]-a[n-5]-a[n-6]+a[n-7]; od; a; # G. C. Greubel, Sep 11 2019
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Definition clarified by N. J. A. Sloane, Feb 02 2018
More terms added by G. C. Greubel, Sep 11 2019
STATUS
approved