OFFSET
0,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..200
Index entries for linear recurrences with constant coefficients, signature (21,-138,280).
FORMULA
a(n) = (2*4^(n+1) -7^(n+2) +5*10^(n+1))/9. - R. J. Mathar, Nov 11 2012
a(0)=1, a(1)=21, a(2)=303; for n>2, a(n) = 21*a(n-1) -138*a(n-2) +280*a(n-3). - Vincenzo Librandi, Jul 03 2013
a(n) = 17*a(n-1) -70*a(n-2) +4^n. - Vincenzo Librandi, Jul 03 2013
MATHEMATICA
CoefficientList[Series[1 / ((1 - 4 x) (1 - 7 x) (1 - 10 x)), {x, 0, 20}], x] (* Vincenzo Librandi, Jul 03 2013 *)
LinearRecurrence[{21, -138, 280}, {1, 21, 303}, 30] (* Harvey P. Dale, Mar 09 2017 *)
PROG
(Magma) m:=20; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!(1/((1-4*x)*(1-7*x)*(1-10*x)))); /* or */ I:=[1, 21, 303]; [n le 3 select I[n] else 21*Self(n-1)-138*Self(n-2)+280*Self(n-3): n in [1..20]]; // Vincenzo Librandi, Jul 03 2013
(PARI) x='x+O('x^30); Vec(1/((1-4*x)*(1-7*x)*(1-10*x))) \\ G. C. Greubel, Aug 24 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved