OFFSET
0,2
COMMENTS
Note period 12 for a(n) mod 10.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..200
Index entries for linear recurrences with constant coefficients, signature (-1,-1,3,3,3)
FORMULA
From R. J. Mathar, Jan 17 2009: (Start)
G.f.: (1 + 3*x + 6*x^2 + 6*x^3 + 3*x^4)/((1 + x + x^2)*(1 - 3*x^3)).
a(n) = -a(n-1) - a(n-2) + 3*a(n-3) + 3*a(n-4) + 3*a(n-5).
a(n) = (3*b(n)-A049347(n))/2 where b(n)=1,1,2,3,3,6,9,9,18,27,27,54,.. = 3*b(n-3).
(End)
PROG
(PARI) Vec((1+3*x+6*x^2+6*x^3+3*x^4)/((1+x+x^2)*(1-3*x^3))+O(x^99)) \\ Charles R Greathouse IV, Jun 20 2011
CROSSREFS
Cf. A107365.
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, May 25 2008
EXTENSIONS
a(27)-a(43) added by Andrew Howroyd, Nov 03 2018
STATUS
approved