OFFSET
1,1
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000
Index entries for linear recurrences with constant coefficients, signature (1,1,-1).
FORMULA
a(n) = 7*n - a(n-1) - 9, n > 1. - Vincenzo Librandi, Aug 05 2010
G.f.: x*(2+x+4*x^2) / ( (1+x)*(x-1)^2 ). - R. J. Mathar, Dec 04 2011
E.g.f.: 4 + ((14*x - 11)*exp(x) - 5*exp(-x))/4. - David Lovler, Sep 11 2022
MATHEMATICA
Select[Range@ 170, MemberQ[{2, 3}, Mod[#, 7]] &] (* or *)
Fold[Append[#1, 7 #2 - Last@ #1 - 9] &, {2}, Range[2, 49]] (* or *)
Rest@ CoefficientList[Series[x (2 + x + 4 x^2)/((1 + x) (x - 1)^2), {x, 0, 49}], x] (* Michael De Vlieger, Jan 12 2018 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved