OFFSET
1,3
LINKS
Nathaniel Johnston, Table of n, a(n) for n = 1..500
Index entries for linear recurrences with constant coefficients, signature (4, 10).
FORMULA
a(n) = ((2+sqrt(14))^(n-1) - (2-sqrt(14))^(n-1))/(2*sqrt(14)). - Rolf Pleisch, May 14 2011
G.f.: x^2/(1-4*x-10*x^2).
MATHEMATICA
Join[{a=0, b=1}, Table[c=4*b+10*a; a=b; b=c, {n, 100}]]
LinearRecurrence[{4, 10}, {0, 1}, 30] (* G. C. Greubel, Jan 16 2018 *)
PROG
(PARI) x='x+O('x^30); concat([0], Vec(x^2/(1-4*x-10*x^2))) \\ G. C. Greubel, Jan 16 2018
(Magma) I:=[0, 1]; [n le 2 select I[n] else 4*Self(n-1) + 10*Self(n-2): n in [1..30]]; // G. C. Greubel, Jan 16 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vladimir Joseph Stephan Orlovsky, Jan 16 2011
STATUS
approved