OFFSET
0,2
LINKS
Index entries for linear recurrences with constant coefficients, signature (18,-87,70).
FORMULA
G.f.: 1/(1-10*x)-1/(1-7*x)+1/(1-x).
E.g.f.: e^(10*x)-e^(7*x)+e^x.
a(n) = 17*a(n-1)-70*a(n-2)+54 with a(0)=1, a(1)=4. - Vincenzo Librandi, Jul 21 2010
a(0)=1, a(1)=4, a(2)=52, a(n)=18*a(n-1)-87*a(n-2)+70*a(n-3). - Harvey P. Dale, May 05 2011
MATHEMATICA
Table[10^n-7^n+1, {n, 0, 20}] (* or *) LinearRecurrence[{18, -87, 70}, {1, 4, 52}, 21] (* Harvey P. Dale, May 05 2011 *)
PROG
(PARI) a(n)=10^n-7^n+1 \\ Charles R Greathouse IV, Jun 11 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Mohammad K. Azarian, Jan 31 2009
STATUS
approved