OFFSET
1,2
COMMENTS
LINKS
Index entries for linear recurrences with constant coefficients, signature (2,-1,-1,2,-1).
FORMULA
G.f.: x*(1+x^2)^2 / ( (1+x)*(x^2-x+1)*(x-1)^2 ). - R. J. Mathar, Oct 25 2011
From Wesley Ivan Hurt, Jul 22 2016: (Start)
a(n) = 2*a(n-1) - a(n-2) - a(n-3) + 2*a(n-4) - a(n-5) for n>5.
a(n) = a(n-6) + 12 for n>6.
a(n) = (6*n - 3 + cos(n*Pi/3) - cos(n*Pi) - sqrt(3)*sin(n*Pi/3))/3.
a(6k) = 12k-1, a(6k-1) = 12k-2, a(6k-2) = 12k-5, a(6k-3) = 12k-7, a(6k-4) = 12k-10, a(6k-5) = 12k-11. (End)
Sum_{n>=1} (-1)^(n+1)/a(n) = (4-sqrt(3))*Pi/12. - Amiram Eldar, Jan 01 2022
MAPLE
A108118:=n->12*floor(n/6)+[1, 2, 5, 7, 10, 11][(n mod 6)+1]: seq(A108118(n), n=0..100); # Wesley Ivan Hurt, Jul 22 2016
MATHEMATICA
Select[ Range[132], !IntegerQ[ #/4] && !IntegerQ[ #/3] &] (* or *) Flatten[ NestList[12 + # &, {1, 2, 5, 7, 10, 11}, 10]]
PROG
(Magma) [n : n in [0..150] | n mod 12 in [1, 2, 5, 7, 10, 11]]; // Wesley Ivan Hurt, Jul 22 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Zak Seidov, Jun 04 2005
STATUS
approved