OFFSET
0,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..200
Index entries for linear recurrences with constant coefficients, signature (22,-144,288).
FORMULA
a(n) = 4^n -3*6^n +3*12^n. - R. J. Mathar, Jun 29 2013
a(0)=1, a(1)=22, a(2)=340; for n>2, a(n) = 22*a(n-1) -144*a(n-2) +288*a(n-3). - Vincenzo Librandi, Jul 03 2013
a(n) = 18*a(n-1) -72*a(n-2) +4^n. - Vincenzo Librandi, Jul 03 2013
MATHEMATICA
CoefficientList[Series[1/((1-4x)(1-6x)(1-12x)), {x, 0, 20}], x] (* Vincenzo Librandi, Jul 03 2013 *)
LinearRecurrence[{22, -144, 288}, {1, 22, 340}, 20] (* Harvey P. Dale, Jun 01 2024 *)
PROG
(Magma) R<x>:=PowerSeriesRing(Integers(), 20); Coefficients(R!(1/((1-4*x)*(1-6*x)*(1-12*x)))); /* or */ I:=[1, 22, 340]; [n le 3 select I[n] else 22*Self(n-1)-144*Self(n-2)+288*Self(n-3): n in [1..20]]; // Vincenzo Librandi, Jul 03 2013
(PARI) my(x='x+O('x^20)); Vec(1/((1-4*x)*(1-6*x)*(1-12*x))) \\ G. C. Greubel, Apr 27 2019
(Sage) (1/((1-4*x)*(1-6*x)*(1-12*x))).series(x, 20).coefficients(x, sparse=False) # G. C. Greubel, Apr 27 2019
(GAP) List([0..20], n-> 2^n*(2^n -3^(n+1) +3*6^n)) # G. C. Greubel, Apr 27 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved