Paper 3, Section II, 11H

Number Theory
Part II, 2020

Let pp be an odd prime.

(i) Define the Legendre symbol (xp)\left(\frac{x}{p}\right), and show that when (x,p)=1(x, p)=1, then (x1p)=(xp)\left(\frac{x^{-1}}{p}\right)=\left(\frac{x}{p}\right).

(ii) State and prove Gauss's lemma, and use it to evaluate (1p)\left(\frac{-1}{p}\right). [You may assume Euler's criterion.]

(iii) Prove that

x=1p(xp)=0\sum_{x=1}^{p}\left(\frac{x}{p}\right)=0

and deduce that

x=1p(x(x+1)p)=1\sum_{x=1}^{p}\left(\frac{x(x+1)}{p}\right)=-1

Hence or otherwise determine the number of pairs of consecutive integers z,z+1z, z+1 such that 1z,z+1p11 \leqslant z, z+1 \leqslant p-1 and both zz and z+1z+1 are quadratic residues modp\bmod p.