OFFSET
0,3
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..10000
Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,2,0,0,0,0,-1).
FORMULA
a(n) = Product_{k=0..4} Sum_{j=1..n} e^(2*Pi*ijk/5), i=sqrt(-1).
a(n) = cos(4*Pi*n/5 + 2*Pi/5)*(n*cos(2*Pi*n/5 + Pi/5)/5 + n*sqrt(1/5 - 2*sqrt(5)/25)*sin(2*Pi*n/5 + Pi/5) + n*(1/5 - sqrt(5)/5)) + sin(4*Pi*n/5 + 2*Pi/5)*(n*sqrt(2*sqrt(5)/25 + 1/5)*cos(2*Pi*n/5 + Pi/5) + sqrt(5)*n*sin(2*Pi*n/5 + Pi/5)/5 - n*sqrt(2*sqrt(5)/25 + 2/5)) - n*(sqrt(5)/5 + 1/5)*cos(2*Pi*n/5 + Pi/5) - n*sqrt(2/5 - 2*sqrt(5)/25)*sin(2*Pi*n/5 + Pi/5) + 4*n/5.
a(n) = n^5 mod (5*n). - Paul Barry, Apr 13 2005
Multiplicative with a(5^e) = 0, a(p^e) = p^e otherwise. - Mitch Harris, Jun 09 2005
From R. J. Mathar, Feb 04 2009: (Start)
a(n) = 2*a(n-5) - a(n-10).
G.f.: x*(1 + 2*x + 3*x^2 + 4*x^3 + 4*x^5 + 3*x^6 + 2*x^7 + x^8)/(1-x^5)^2.
From R. J. Mathar, Apr 14 2011: (Start)
a(n) = n*A011558(n).
Dirichlet g.f.: (1-5^(1-s))*zeta(s-1). (End)
Sum_{k=1..n} a(k) ~ (2/5) * n^2. - Amiram Eldar, Nov 20 2022
MATHEMATICA
Table[If[Divisible[n, 5], 0, n], {n, 0, 80}] (* Harvey P. Dale, Apr 26 2018 *)
PROG
(PARI) a(n) = if (n % 5, n, 0); \\ Michel Marcus, Feb 28 2019
(Magma) [(n mod 5 eq 0) select 0 else n: n in [0..80]]; // G. C. Greubel, Feb 28 2019
(Sage) [n if not n % 5==0 else 0 for n in range(80)] # G. C. Greubel, Feb 28 2019
CROSSREFS
KEYWORD
easy,nonn,mult
AUTHOR
Paul Barry, Jan 30 2004
STATUS
approved