OFFSET
0,2
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (3,0,-1,3).
FORMULA
From Richard Choulet, Jan 02 2008: (Start)
a(n) = (1/7)*3^(n+1) + (4/3)*(-1)^n - (16/21)*cos(Pi*n/3) + (16*sqrt(3)/7)*sin(Pi*n/3).
a(n) = (1/7)*3^(n+1) + (1/7)*[4; 12; 36; -4; -12; -36] for n>=0. (End)
G.f.: (1 - 15*x^3) / ((1+x)*(1-3*x)*(1-x+x^2)). - Colin Barker, Feb 10 2016
MATHEMATICA
Join[{1, 3}, LinearRecurrence[{3, 0, -1, 3}, {9, 11, 33, 99}, 25]] (* G. C. Greubel, Oct 11 2016 *)
PROG
(PARI) Vec((1-15*x^3)/((1+x)*(1-3*x)*(1-x+x^2)) + O(x^40)) \\ Colin Barker, Feb 10 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Dec 09 2007
STATUS
approved