OFFSET
0,4
COMMENTS
LINKS
Index entries for linear recurrences with constant coefficients, signature (3,-2,0,-1,1).
FORMULA
a(n) = a(n-1)+a(n-2)+a(n-3)+4*n-8 with a(0)=0, a(1)=0 and a(2)=1.
a(n) = a(n-1)+A001590(n+3)-2 with a(0)=0.
a(n+2) = add(A008288(n-k+2,k+2),k=0..floor(n/2)).
GF(x) = (x^2*(1+x)^2)/((1-x)^2*(1-x-x^2-x^3)).
Contribution from Bruno Berselli, Sep 23 2010: (Start)
a(n) = 2*a(n-1)-a(n-4)+4 for n>4.
a(n)-3*a(n-1)+2a(n-2)+a(n-4)-a(n-5) = 0 for n>4. (End)
MAPLE
nmax:=31: a(0):=0: a(1):=0: a(2):=1: for n from 3 to nmax do a(n):= a(n-1)+a(n-2)+a(n-3)+4*n-8 od: seq(a(n), n=0..nmax);
MATHEMATICA
LinearRecurrence[{3, -2, 0, -1, 1}, {0, 0, 1, 5, 14}, 40] (* Harvey P. Dale, Dec 15 2023 *)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Johannes W. Meijer, Sep 21 2010
STATUS
approved