OFFSET
0,2
COMMENTS
Smallest prime of this form is a(18) = 5559917313492231463. - Bruno Berselli, Jun 17 2013
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..300
Index entries for linear recurrences with constant coefficients, signature (13,-23,11).
FORMULA
From Vincenzo Librandi, Jun 17 2013: (Start)
G.f.: (1-3*x+12*x^2)/((1-11*x) (1-x)^2).
a(n) = 13*a(n-1) - 23*a(n-2) + 11*a(n-3). (End)
E.g.f.: exp(x)*(exp(10*x) - x). - Elmo R. Oliveira, Sep 10 2024
MATHEMATICA
Table[11^n - n, {n, 0, 20}] (* or *) CoefficientList[Series[(1 - 3 x + 12 x^2) / ((1 - 11 x) (1 - x)^2), {x, 0, 30}], x] (* Vincenzo Librandi, Jun 17 2013 *)
LinearRecurrence[{13, -23, 11}, {1, 10, 119}, 20] (* Harvey P. Dale, Aug 02 2017 *)
PROG
(Magma) [11^n-n: n in [0..20]]; // Vincenzo Librandi, Jul 01 2011
(PARI) a(n)=11^n-n \\ Charles R Greathouse IV, Jul 01 2011
(Magma) I:=[1, 10, 119]; [n le 3 select I[n] else 13*Self(n-1)-23*Self(n-2)+11*Self(n-3): n in [1..30]]; // Vincenzo Librandi, Jun 17 2013
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved