# I don't understand this proof about Gaussian integers

Theorem: If p is a Gaussian prime and $p|zw$ for some gaussian integer $z,w \in Z[i]$ then $p|z$ or $p|w$.

Suppose $p \not| z$ and lets deduce $p | w$. Let $u$ be a greatest common divisor of $p, z$.

So $u = pt + zs$ for some $t,s \in Z[i]$ and $u |p$ and $u |z$. Write $p = uk$ for some $k$ in $Z[i]$. Since p is a Gaussian prime, one of $u$ or $k$ is a unit in $Z[i]$.

If $k$ is a unit, the $u=pk^{-1}$ where $k^{-1} \in Z[i]$, and we see that $p | u$. Since $u | z$ we get $p | z$ contrary to assumption.

Thus $u$ is a unit with inverse $u^{-1} \in Z[i]$. Then $$wu = pwt + wzs$$ and $$w = pwtu^{-1} + wzsu^{-1}$$ We see that $p | pwtu^{-1}$ and we are given that $p|wz$. So $p|w$

I don't get how the bold part concludes that $p | w$. Also for the theorem it says $p|z$ or $p|w$, why not the case $p | z$ and $p | w$?

-

Note that in any ring $R$, for any $a,b,c\in R$, if $a\mid b$ and $a\mid c$, then $a\mid b+c$. Also, $a\mid b$ implies $a\mid bc$.

Thus, $p\mid wz$ implies $p\mid wzsu^{-1}$, and $p \mid pwtu^{-1}$ together with $p\mid wzsu^{-1}$ implies that $$p\mid pwtu^{-1}+wzsu^{-1}.$$ But the thing on the right is equal to $w$. So we have that $p\mid w$.

The argument also (implicitly) examines the possibility that $p\mid z$, at the very beginning: if we had $p\mid z$, then would already have that $p\mid z$ or $p\mid w$, and we'd be done, so we might as well start off assuming that $p\nmid z$. It is fairly common to see a proof of a claim "$P$ is true or $Q$ is true" to just start off with "Assume that $P$ is false" and proceed to concluding $Q$.

-

You have the expression $$w = pwtu^{-1} + wzsu^{-1}$$ So $w$ is a sum of two terms, and $p$ divides both of them. So $p$ divides their sum. (If $p|a$ and $p|b$, then $p | a + b$.)

To answer your second question: in mathematics, the statement "A or B" always means "A or B or both": it means that at least one of A and B is true, not necessarily exactly one. So a statement "$p|w$ or $p|z$" includes the case where $p$ divides both $w$ and $z$, as well as the cases where it divides exactly one of them.

-

The assertion follows simply because multiples of $\rm\:p\:$ are closed under addition $\rm\:a\:p+b\:p = (a+b)\:p\:.\:$ The proof is obfuscated by needless sprinkling of unit factors. More simply and generally

$$\rm\ p\ |\ w\:z\ \Rightarrow\ p\ |\ w\: p,\:w\:z\ \Rightarrow\ p\ |\ (w\:p,\:w\:z)\: =\: w\:(p,z)\: =\: w\ \ since\ \ (p,z) = 1$$

-