OFFSET
0,2
COMMENTS
Number of 0..n arrays of six elements with zero second differences. - R. H. Hardin, Nov 16 2011
Also number of ordered triples (w,x,y) with all terms in {1,...,n+1} and w + 4*x = 5*y. Also the number of 3-tuples (w,x,y) with all terms in {1,...,n+1} and 5*w = 2*x +3*y. - Clark Kimberling, Apr 15 2012 [Corrected by Pontus von Brömssen, Jan 26 2020]
a(n) is also the number of 5 boxes polyomino (zig-zag patterns) packing into (n+3) X (n+3) square. See illustration in links. - Kival Ngaokrajang, Nov 10 2013
Also, number of ordered pairs (x,y) with both terms in {1,...,n+1} and x+4*y divisible by 5; or number of ordered pairs (x,y) with both terms in {1,...,n+1} and 2*x+3*y divisible by 5. - Pontus von Brömssen, Jan 26 2020
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
Kival Ngaokrajang, Illustration of initial terms
Index entries for linear recurrences with constant coefficients, signature (2,-1,0,0,1,-2,1).
FORMULA
G.f.: (1+x^5)/((1-x)^2*(1-x^5)).
a(n) = 2*a(n-1) -a(n-2) +a(n-5) -2*a(n-6) +a(n-7). - R. H. Hardin, Nov 16 2011
EXAMPLE
For n = 5 there are 8 0..5 arrays of six elements with zero second differences: [0,0,0,0,0,0], [0,1,2,3,4,5], [1,1,1,1,1,1], [2,2,2,2,2,2], [3,3,3,3,3,3], [4,4,4,4,4,4], [5,4,3,2,1,0], [5,5,5,5,5,5].
MAPLE
seq(coeff(series((1+x^5)/((1-x)^2*(1-x^5)), x, n+1), x, n), n = 0..65); # G. C. Greubel, Sep 12 2019
MATHEMATICA
CoefficientList[Series[(1+x^5)/(1-x)^2/(1-x^5), {x, 0, 65}], x] (* or *) LinearRecurrence[{2, -1, 0, 0, 1, -2, 1}, {1, 2, 3, 4, 5, 8, 11}, 65] (* Harvey P. Dale, Apr 17 2015 *)
PROG
(PARI) Vec((1+x^5)/(1-x)^2/(1-x^5)+O(x^65)) \\ Charles R Greathouse IV, Sep 25 2012
(Magma) R<x>:=PowerSeriesRing(Integers(), 65); Coefficients(R!( (1+x^5)/((1-x)^2*(1-x^5)) )); // G. C. Greubel, Sep 12 2019
(Sage)
def A008812_list(prec):
P.<x> = PowerSeriesRing(ZZ, prec)
return P((1+x^5)/((1-x)^2*(1-x^5))).list()
A008812_list(65) # G. C. Greubel, Sep 12 2019
(GAP) a:=[1, 2, 3, 4, 5, 8, 11];; for n in [8..65] do a[n]:=2*a[n-1]-a[n-2] +a[n-5]-2*a[n-6]+a[n-7]; od; a; # G. C. Greubel, Sep 12 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
More terms added by G. C. Greubel, Sep 12 2019
STATUS
approved