OFFSET
0,3
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..2500
Index entries for linear recurrences with constant coefficients, signature (-1,2,8).
FORMULA
a(n) = -a(n-1) + 2*a(n-2) + 8*a(n-3) for all n in Z.
a() = a(-n-3) * 2^(2*n+3) for all n in Z. - Michael Somos, Sep 17 2014
0 = a(n)*(+4*a(n+1) + 2*a(n+2)) + a(n+1)*(+a(n+1) + a(n+2)) for all n in Z. - Michael Somos, Sep 17 2014
EXAMPLE
G.f. = 1 - x + 3*x^2 + 3*x^3 - 5*x^4 + 35*x^5 - 21*x^6 + 51*x^7 + 187*x^8 + ...
MATHEMATICA
LinearRecurrence[{-1, 2, 8}, {-1, 3, 3}, 40] (* Harvey P. Dale, Aug 03 2012 *)
CoefficientList[Series[1/((1-2*x)*(1+3*x+4*x^2)), {x, 0, 50}], x] (* G. C. Greubel, Aug 13 2018 *)
PROG
(PARI) {a(n) = if( n<0, polcoeff( x^3 / ((2 - x) * (4 + 3*x + x^2)) + x * O(x^-n), -n), polcoeff( 1 / ((1 - 2*x) * (1 + 3*x + 4*x^2)) + x * O(x^n), n))}; /* Michael Somos, Sep 17 2014 */
(PARI) x='x+O('x^50); Vec(1/((1-2*x)*(1+3*x+4*x^2))) \\ G. C. Greubel, Aug 13 2018
(Magma) m:=25; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!(1/((1-2*x)*(1+3*x+4*x^2)))); // G. C. Greubel, Aug 13 2018
CROSSREFS
KEYWORD
sign,easy
AUTHOR
Krishnamurthy Balasubraniam, Nov 19 2011
EXTENSIONS
Definition from R. J. Mathar, Nov 19 2011
Added a(0) = 1. - Michael Somos, Sep 17 2014
STATUS
approved