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) = 18*(n-1) - a(n-1) for n > 1 and a(1)=5. - Vincenzo Librandi, Nov 25 2010
From Colin Barker, Oct 25 2019: (Start)
G.f.: x*(5 + 8*x + 5*x^2) / ((1 - x)^2*(1 + x)).
a(n) = a(n-1) + a(n-2) - a(n-3) for n>3.
a(n) = ((-1)^(1+n) + 18*n - 9) / 2. (End)
E.g.f.: 5 + ((18*x - 9)*exp(x) - exp(-x))/2. - David Lovler, Sep 08 2022
Sum_{n>=1} (-1)^(n+1)/a(n) = tan(2*Pi/9)*Pi/18. - Amiram Eldar, Feb 27 2023
MATHEMATICA
Select[Range@ 500, MemberQ[{5, 13}, Mod[#, 18]] &] (* Michael De Vlieger, Nov 23 2018 *)
PROG
(GAP) Filtered([1..500], k->k mod 18 = 5 or k mod 18 = 13); # Muniru A Asiru, Nov 24 2018
(PARI) Vec(x*(5 + 8*x + 5*x^2) / ((1 - x)^2*(1 + x)) + O(x^60)) \\ Colin Barker, Oct 25 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Giovanni Teofilatto, Sep 07 2008
EXTENSIONS
Corrected (213 replaced with 211, 231 with 229, 249 with 247, 265 with 267 etc.) by R. J. Mathar, Apr 22 2010
STATUS
approved