OFFSET
0,3
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
Fan Chung, R. L. Graham, Primitive juggling sequences, Am. Math. Monthly 115 (3) (2008) 185-194
Index entries for linear recurrences with constant coefficients, signature (3,-2,2)
FORMULA
a(n+3) = 3*a(n+2) - 2*a(n+1) + 2*a(n). - G. C. Greubel, Feb 05 2016
MATHEMATICA
CoefficientList[Series[2x^2(1-x)/(1-3x+2x^2-2x^3), {x, 0, 30}], x] (* or *)
Join[{0}, LinearRecurrence[{3, -2, 2}, {0, 2, 4}, 30]] (* Harvey P. Dale, Apr 25 2011 *)
PROG
(Magma) I:=[0, 0, 2, 4, 8]; [n le 5 select I[n] else 3*Self(n-1) - 2*Self(n-2) + 2*Self(n-3): n in [1..40]]; // Vincenzo Librandi, Jan 06 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Mar 05 2006
STATUS
approved