# Proofcheck on alternative proof that every nonzero element of $Z_{n}$ is a unit or a divisor.

I'm working through Gallian's Ch. 13 on Integral Domains, the second chapter in the book dealing with topics concerning rings. I feel this was a good book on intro group theory (which is what a lot of universities use it for), but I feel it's a little dicey on intro ring theory content (I doubt anybody uses it for that).

Anyways the ring theory part is a little bare, and so I didn't have much to work with in proving every element of $$Z_{n}$$ is a unit or a zero divisor. This book proves the more general result about 'every finite commutative ring' afterwards so I can't use that either. I think I have a solid alternative proof (using kind of a pigeon-hole argument) though even without all the fancy techniques the other solutions out there have. Would love for comments and critiques, especially on the second half of it.

Let $$n\geq4$$ (the $$n<4$$ cases are trivial; moreover they are prime and handled elsewhere).

First suppose some arbitrary $$k\in\mathbb{Z}_{n}$$ is both a unit and a zero divisor. Hence there exists some $$l\in\mathbb{Z}_{n}\setminus \{0\}$$ such that $$kl=lk=0$$. Now since $$k$$ is a unit, we have that $$k^{-1}\in\mathbb{Z}_{n}$$. It follows that \begin{align*}0 &=k^{-1}0 \\ &=k^{-1}kl \\ &=l,\end{align*}a contradiction. Next suppose $$k\in\mathbb{Z}_{n}\setminus \{0\}$$ is neither a unit nor a zero-divisor. Hence for all $$l\in\mathbb{Z}_{n}\setminus\{0,1\}$$, we have $$kl\neq 0,\text{ (since k,l\neq 0, and since k is not a zero-divisor)}$$ $$kl\neq 1, \text{ (k is not a unit)}$$ $$kl\neq k. \text{ (l\neq 1)}$$Hence the $$n-2$$ remaining choices for $$l \in \mathbb{Z}_{n}\setminus \{0,1\}$$ can yield at most $$n-3$$ unique products $$kl\in \mathbb{Z}_{n}\setminus \{0,1,k\}$$. In any case we must have that there exist integers $$l_{1}>l_{2}\in\mathbb{Z}_{n}\setminus \{0,1\}$$ such that $$kl_{1}=kl_{2}$$. It follows that \begin{align*}0 &= kl_{1}-kl_{2} \\ &= k(l_{1}-l_{2}),\end{align*}which is impossible since the nonzero element $$k$$ is not a zero divisor and $$l_{1}-l_{2}>0$$ by construction. Thus a contradiction. QED.

The argument is fine, but you slightly over-complicate the reasoning for the contradiction when $$k$$ is neither a unit nor a zero divisor.

It is enough to note that the map $$K:\mathbb Z_n\rightarrow \mathbb Z_n$$ defined by $$K(l)=kl$$ is not injective, as its range is a subset of $$\mathbb Z_n- \{1\}$$ (since $$k$$ is not a unit).

It immediately follows that for some distinct $$l_1,l_2\in \mathbb Z_n$$, $$kl_1=kl_1\Rightarrow k(l_1-l_2)=0$$ and so $$k$$ is a zero divisor, a contradiction (just like you concluded).

This approach also comes with the (very slight) advantage of not having to deal with $$n=2,3$$ as special cases.

• Really appreciate the feedback! Aug 14, 2020 at 12:55
• The same proof works in general: math.stackexchange.com/a/60974/589
– lhf
Aug 16, 2020 at 14:09
• @lhf Yes fair observation. Thanks for linking this. Aug 16, 2020 at 17:53