login
A017954
Expansion of 1/((1-3x)(1-6x)(1-12x)).
1
1, 21, 315, 4185, 52731, 648081, 7869555, 94992345, 1143260811, 13739265441, 164992058595, 1980630120105, 23771914474491, 285289093487601, 3423625845396435, 41084450500377465, 493019048181297771
OFFSET
0,2
FORMULA
a(0)=1, a(1)=21, a(2)=315; for n>2, a(n) = 21*a(n-1) -126*a(n-2) +216*a(n-3). - Vincenzo Librandi, Jul 02 2013
a(n) = 18*a(n-1) -72*a(n-2) +3^n. - Vincenzo Librandi, Jul 02 2013
a(n) = (12^(n+2) - 3*6^(n+2) + 2*3^(n+2))/54. [Yahia Kahloune, Jul 06 2013]
MATHEMATICA
CoefficientList[Series[1 / ((1 - 3 x) (1 - 6 x) (1 - 12 x)), {x, 0, 30}], x] (* Vincenzo Librandi, Jul 02 2013 *)
LinearRecurrence[{21, -126, 216}, {1, 21, 315}, 30] (* Harvey P. Dale, Sep 21 2019 *)
PROG
(Magma) m:=20; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!(1/((1-3*x)*(1-6*x)*(1-12*x)))); /* or */ I:=[1, 21, 315]; [n le 3 select I[n] else 21*Self(n-1)-126*Self(n-2)+216*Self(n-3): n in [1..20]]; // Vincenzo Librandi, Jul 02 2013
CROSSREFS
Sequence in context: A019041 A021214 A016318 * A055434 A016315 A113531
KEYWORD
nonn,easy
AUTHOR
STATUS
approved