|
|
A120664
|
|
Expansion of 2*x*(1-6*x+12*x^2)/(1-8*x+19*x^2-12*x^3).
|
|
1
|
|
|
0, 2, 4, 18, 92, 442, 2004, 8738, 37132, 155082, 640004, 2619058, 10653372, 43144922, 174174004, 701478978, 2820264812, 11324105962, 45425564004, 182089676498, 729520967452, 2921570654202, 11696742970004, 46818352939618
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,2
|
|
LINKS
|
|
|
FORMULA
|
a(n) = 8*a(n-1) - 19*a(n-2) + 12*a(n-3) for n > 3.
G.f.: 2*x*(1-6*x+12*x^2)/(1-8*x+19*x^2-12*x^3). (End)
|
|
MATHEMATICA
|
LinearRecurrence[{8, -19, 12}, {0, 2, 4, 18}, 31] (* G. C. Greubel, Dec 26 2022 *)
|
|
PROG
|
(Magma) I:=[2, 4, 18]; [0] cat [n le 3 select I[n] else 8*Self(n-1) -19*Self(n-2) +12*Self(n-3): n in [1..31]]; // G. C. Greubel, Dec 26 2022
(SageMath)
@CachedFunction
if (n<4): return (0, 2, 4, 18)[n]
else: return 8*a(n-1) -19*a(n-2) +12*a(n-3)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy,less
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|