OFFSET
1,1
LINKS
David Lovler, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (1,1,-1).
FORMULA
a(n) = 7*n - a(n-1) - 6, n > 1. - Vincenzo Librandi, Aug 05 2010
From Bruno Berselli, Sep 08 2010: (Start)
G.f.: x*(3 + 2*x + 2*x^2)/((1+x)*(1-x)^2).
a(n) - a(n-1) - a(n-2) + a(n-3) = 0 for n > 3.
a(n) = (14*n - 5 - 3*(-1)^n)/4. (End)
E.g.f.: 2 + ((14*x - 5)*exp(x) - 3*exp(-x))/4. - David Lovler, Sep 13 2022
MATHEMATICA
#+{3, 5}&/@(7*Range[0, 30])//Flatten (* Harvey P. Dale, Oct 10 2019 *)
PROG
(PARI) a(n) = (14*n - 5 - 3*(-1)^n)/4 \\ David Lovler, Sep 13 2022
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved