login
Polya-Vinogradov numbers A177865 for primes p == 1 (mod 4).
2

%I #11 Mar 30 2012 19:00:10

%S 1,2,2,3,4,4,5,4,5,6,6,7,6,6,7,7,8,9,7,8,11,9,10,8,10,11,14,10,11,11,

%T 13,12,12,12,16,12,12,12,12,11,14,13,12,15,15,16,14,19,16,16,16,14,20,

%U 16,15,21,16,16,19,17,15,18,22,20,17,17,18,16,17,17

%N Polya-Vinogradov numbers A177865 for primes p == 1 (mod 4).

%C Polya-Vinogradov numbers for all odd primes is A177865, and for primes p == 3 (mod 4) is A207292.

%F a(n) = max_{0<k<p} |sum_{i=1..k} L(i/p)|, where p is the n-th prime == 1 (mod 4) and L(i/p) is the Legendre symbol.

%e The 3rd prime == 1 (mod 4) is 17 = prime(7), and A177865(7) = 2 (not 3, because the offset of A177865 is 2, not 1), so a(3) = 2.

%t T = Table[Max[Table[Abs[Sum[JacobiSymbol[i, Prime[n]], {i, 1, k}]], {k, 1, Prime[n] - 1}]], {n, 2, 200}]; P = Table[Mod[Prime[n], 4], {n, 2, 200}]; Pick[T, P, 1]

%Y Cf. A177865, A207292.

%K nonn

%O 1,2

%A _Jonathan Sondow_, Feb 16 2012