OFFSET
1,2
LINKS
G. C. Greubel, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (3,0,-8,7,3,-6,2).
FORMULA
a(n) = Sum_{i=1..n} 1/8*(2^(i/2+2)*((10-7*sqrt(2))*(-1)^(i) + 10 + 7*sqrt(2))-(-1)^(i)-2*i*(i+12)-79).
G.f.: x*(1+x-x^2)/((1-x)^4*(1+x)*(1-2*x^2)). - Alexander R. Povolotsky, Aug 12 2011
a(n) = (1/32)*( (-1/2)^n + 32*(41*sqrt(2)-58)*(sqrt(2)-2)^n - 32*(58+41*sqrt(2))*(-2-sqrt(2))^n ).
MATHEMATICA
LinearRecurrence[{3, 0, -8, 7, 3, -6, 2}, {1, 4, 11, 25, 50, 93, 162}, 40] (* Harvey P. Dale, Sep 09 2015 *)
CoefficientList[Series[(1 + x - x^2)/((1 - x)^4*(1 + x)*(1 - 2*x^2)), {x, 0, 50}], x] (* G. C. Greubel, Feb 25 2017 *)
PROG
(PARI) my(x='x+O('x^50)); Vec((1+x-x^2)/((1-x)^4*(1+x)*(1-2*x^2))) \\ G. C. Greubel, Feb 25 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Jeffrey R. Goodwin, Aug 08 2011
STATUS
approved