OFFSET
0,3
LINKS
Gopinath A. R., Table of n, a(n) for n = 0..200
Calvin Lin, Tiling, Discrete Mathematics Problem on Linear Recurrence Relations, Brilliant.
Index entries for linear recurrences with constant coefficients, signature (0,4,2,2,4).
FORMULA
a(n) = 4*a(n-2) + 2*a(n-3) + 2*a(n-4) + 4*a(n-5), with a(0)=1, a(1)=1, a(2)=4, a(3)=6, and a(4)=20.
G.f.: (1+x)/(1-4*x^2-2*x^3-2*x^4-4*x^5).
Asymptotic formula: a(n) ~ 0.581189405182598 * 2.3498153157195^n.
MATHEMATICA
LinearRecurrence[{0, 4, 2, 2, 4}, {1, 1, 4, 6, 20}, 33] (* or *) CoefficientList[Series[(1 + x)/(1 - 4 x^2 - 2 x^3 - 2 x^4 - 4 x^5), {x, 0, 33}], x] (* Vincenzo Librandi, Apr 30 2018 *)
PROG
(Sage)
fx = (1+x)/(1-4*x^2-2*x^3-2*x^4-4*x^5)
fxt = taylor(fx, x, 0, 50)
for i in range(51):
print(i, fxt.coefficient(x, i))
(PARI) Vec( (1+x)/(1-4*x^2-2*x^3-2*x^4-4*x^5) +O(x^66) ) \\ Joerg Arndt, Aug 07 2013
(Magma) I:=[1, 1, 4, 6, 20]; [n le 5 select I[n] else 4*Self(n-2)+2*Self(n-3)+ 2*Self(n-4)+4*Self(n-5): n in [1..35]]; // Vincenzo Librandi, Apr 30 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Gopinath A. R., Aug 01 2013
STATUS
approved