If $Q = \{a: \mbox{$1\le a\le p-1$ and $a$ is a quadratic residue}\}$. How can i prove that if $p\ge 5$, then $\sum_{t\in Q} t \equiv 0 \pmod{p}$. Any help is appreciated
2026-03-29 05:44:09.1774763049
Let $Q = \{a:{1\le a\le p-1 \text{ and } a \text{ is a quadratic residue}}\}$. Prove that if $p\ge 5$, then $\sum_{t\in Q} t \equiv 0 \pmod{p}$.
76 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
Let $g$ be a primitive root of $p$. Then the quadratic residues of $p$ are congruent, in some order, to $1, g^2,g^4,g^6,\dots, g^{p-3}$ (the even powers of $g$).
Note that $$(1+g^2+g^4+\cdots+g^{p-3})(1-g^2)=1-g^{p-1}\equiv 0\pmod{p}.$$ If $p\gt 3$, then $1-g^2\not\equiv 0\pmod{p}$, since $g$ has order $p-1$, and the result follows.
Remark: The result can also be proved without using primitive roots, but the argument is somewhat more complicated.