OFFSET
0,3
LINKS
Seiichi Manyama, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (0,4,1,-2,1).
FORMULA
G.f.: (1 + x - x^2) / (1 - 4*x^2 - x^3*(1-x)^2).
a(n) = 4*a(n-2) + a(n-3) - 2*a(n-4) + a(n-5).
MATHEMATICA
LinearRecurrence[{0, 4, 1, -2, 1}, {1, 1, 3, 5, 11}, 50] (* Vincenzo Librandi, Jan 14 2026 *)
PROG
(PARI) my(N=40, x='x+O('x^N)); Vec((1+x-x^2)/(1-4*x^2-x^3*(1-x)^2))
(Magma) I:=[1, 1, 3, 5, 11]; [n le 5 select I[n] else 4*Self(n-2) + Self(n-3) - 2*Self(n-4) + Self(n-5): n in [1..40]]; // Vincenzo Librandi, Jan 14 2026
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Seiichi Manyama, Jan 14 2026
STATUS
approved
