login
A228131
a(n) = Sum_{i=0..n-1} K(i,n)*i, where K(,) is Kronecker symbol.
5
0, 1, -1, 4, 0, 6, -7, 0, 27, 6, -11, -8, 0, 20, -30, 64, 0, -4, -19, 0, 0, 46, -69, -48, 250, 106, -9, 0, 0, 68, -93, 0, 0, 44, -70, 216, 0, 82, -156, 0, 0, 60, -43, -88, 0, 148, -235, -32, 1029, 94, -102, 0, 0, 6, -220, -224, 0, -82, -177, 0, 0, 168, -126, 1024, 0, 304, -67, 0, 0, 268, -497, 0, 0, 494, -50, -152, 0, 276, -395, 0, 2187, 4, -249, 0, 0, 310, -522, -176, 0, 388, -182, 0, 0, 424, -760, -192, 0, 202, 0, 2000
OFFSET
1,4
COMMENTS
For prime n==1 (mod 4), a(n) = 0.
For prime n==3 (mod 4) and n>3, i.e., n=A002145(m) for m>1, a(n) = -n*A002143(m).
LINKS
MATHEMATICA
Table[Sum[KroneckerSymbol[k, n]*k, {k, 0, n - 1}], {n, 0, 50}] (* G. C. Greubel, Apr 23 2018 *)
PROG
(PARI) a(n) = sum(i=1, n-1, kronecker(i, n)*i)
CROSSREFS
KEYWORD
sign
AUTHOR
Max Alekseyev, Aug 11 2013
STATUS
approved