OFFSET
1,1
COMMENTS
Numbers k for which A276076(k) and A276086(k) are multiples of three. For a simple proof, consider the penultimate digit in the factorial and primorial base expansions of n, A007623 and A049345. - Antti Karttunen, Feb 08 2024
LINKS
Guenther Schrack, Table of n, a(n) for n = 1..10015
Index entries for linear recurrences with constant coefficients, signature (1,0,0,1,-1).
FORMULA
G.f.: x*(2+x+x^2+x^3+x^4) / ( (1+x)*(1+x^2)*(1-x)^2 ). - R. J. Mathar, Oct 08 2011
From Wesley Ivan Hurt, May 21 2016: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5) for n>5.
a(n) = (6*n - 1 - i^(2*n) - (1-i)*i^(-n) - (1+i)*i^n)/4 where i = sqrt(-1).
From Guenther Schrack, Feb 10 2019: (Start)
a(n) = (6*n - 1 - (-1)^n -2*(-1)^(n*(n+1)/2))/4.
a(n) = a(n-4) + 6, a(1)=2, a(2)=3, a(3)=4, a(4)=5, for n > 4.
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(3)*Pi/12 - 2*log(2)/3 + log(3)/4. - Amiram Eldar, Dec 17 2021
MAPLE
A047247:=n->(6*n-1-I^(2*n)-(1-I)*I^(-n)-(1+I)*I^n)/4: seq(A047247(n), n=1..100); # Wesley Ivan Hurt, May 21 2016
MATHEMATICA
Table[(6n-1-I^(2n)-(1-I)*I^(-n)-(1+I)*I^n)/4, {n, 80}] (* Wesley Ivan Hurt, May 21 2016 *)
LinearRecurrence[{1, 0, 0, 1, -1}, {2, 3, 4, 5, 8}, 70] (* Harvey P. Dale, May 25 2024 *)
PROG
(Magma) [n : n in [0..100] | n mod 6 in [2, 3, 4, 5]]; // Wesley Ivan Hurt, May 21 2016
(PARI) my(x='x+O('x^70)); Vec(x*(2+x+x^2+x^3+x^4)/((1-x)*(1-x^4))) \\ G. C. Greubel, Feb 16 2019
(Sage) a=(x*(2+x+x^2+x^3+x^4)/((1-x)*(1-x^4))).series(x, 72).coefficients(x, sparse=False); a[1:] # G. C. Greubel, Feb 16 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
More terms from Wesley Ivan Hurt, May 21 2016
STATUS
approved