OFFSET
1,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..200
Index entries for linear recurrences with constant coefficients, signature (23,-43,21).
FORMULA
a(1)=1, a(2)=23, a(3)=486, a(n) = 23*a(n-1) - 43*a(n-2) + 21*a(n-3). - Vincenzo Librandi, Oct 19 2012
From Elmo R. Oliveira, Mar 29 2025: (Start)
G.f.: x/((1-21*x)*(x-1)^2).
E.g.f.: exp(x)*(21*exp(20*x) - 20*x - 21)/400.
a(n) = (21^(n+1) - 20*n - 21)/400. (End)
MATHEMATICA
LinearRecurrence[{23, -43, 21}, {1, 23, 486}, 20] (* Vincenzo Librandi, Oct 19 2012 *)
PROG
(Magma) I:=[1, 23, 486]; [n le 3 select I[n] else 23*Self(n-1) - 43*Self(n-2)+ 21*Self(n-3): n in [1..20]]; // Vincenzo Librandi, Oct 19 2012
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved
