Explanation of these examples

37 Views Asked by At

I am having trouble deciphering something in my number theory notes relating to Thue's proof for sums of two squares.

First the proof given by my professor,

If $p\equiv 1\pmod{4}$ then $p$ is the sum of two squares.

Proof. Since $p\equiv 1\pmod{4}$, then there is some $z$ such that, $z^2\equiv -1\pmod{p}$. From this construct the

$(1+\lfloor\sqrt{p}\rfloor)^2>(\sqrt{p})^2=p$,

numbers $x+zy$, with $0\le x\le\sqrt{p}$ and $0\le y\le\sqrt{p}$. From the pigeon hole principle we know that since there are more than $p$ of these numbers there must be at least two of which are congruent to one another modulo $p$. So let $x_1+zy_1\equiv x_2+zy_2\pmod{p}$, so $x+zy\equiv 0\pmod{p}$, with $|x|=|x_1-x_2|$ and $|y|=|y_1-y_2|$ where $x$ and $y$ are not both zero. Then $x^2+y^2\equiv x^2+(-zx)^2\equiv x^2(1+z^2)\equiv 0\pmod{p}$, so $0<x^2+y^2<p+p=2p$. Moreover since $x$ and $y$ are not both zero it must be the case that $x^2+y^2=p$. Q.E.D.

Now my question pertains to showing that $p=x^2+3y^2$. In the notes he says you use Thue's argument to get to the fact that if $p\equiv 1\pmod{3}$ then $x^2+3y^2=mp$ with $1\le m\le 3$. This part makes sense to me since you can just take $z^2=-3\pmod{p}$ in Thue's argument and deduce the above. Next if $m=3$ then it divides the RHS and hence divides the LHS, and since $m|3y^2$ it must divide $x$ and so, it all reduces to $3(x/3)^2+y^2=p$ which is what we needed, which also makes sense to me. Now I am confused about why $m\ne 2$. He says that it must be the case that when $m=2$, we have to have $(2,xy)=1$, and then we get $\equiv 1+3\equiv 0\pmod{4}$, and thats all he gives. Could someone explain why this is?