Note that, if then is a qudratic residue, hence ( Legendre's Symbol)
Thus we find that . - the sum is taken over the quadratic residues-
Now, how many quadratic residues are there?
If a prime number p is in the form p=4k+1, then how do I prove that the sum of the quadratic residues mod p is equal to p(p-1)/4? I tried adding consecutive perfect squares up to [((p-1)/2)^2]^2 and then subtracting to get the congruences, but that didn't work too well. Any suggestions are welcome