Generator of Additive Group Modulo m iff Unit of Ring

Theorem
Let $m \in \Z: m > 1$

Let $\left({\Z_m, +_m}\right)$ be the Additive Group of Integers Modulo $m$.

Let $\left({\Z_m, +_m, \times_m}\right)$‎ be the ring of integers modulo $m$.

Let $a \in \Z_m$.

Then:
 * $a$ is a generator of $\left({\Z_m, +_m}\right)$

iff
 * $a$ is a unit of $\left({\Z_m, +_m, \times_m}\right)$

Proof
From Integers under Addition form Infinite Cyclic Group, the identity element $1_\Z$ of the ring of integers $\left({\Z, +, \times}\right)$ is a generator of the group $\left({\Z, +}\right)$.

Thus from Quotient Group of Cyclic Group, the identity element $1_{\Z_m}$ of the ring $\left({\Z_m, +_m, \times_m}\right)$ is a generator of the group $\left({\Z_m, +_m}\right)$.

Let $a \in \Z_m$.

Suppose $1_{\Z_m} \in \left\langle{a}\right\rangle$, where $\left\langle{a}\right\rangle$ signifies the group generated by $a$.

Then the smallest subgroup of $\left({\Z_m, +_m}\right)$ containing $1_{\Z_m}$, i.e. $\left({\Z_m, +_m}\right)$ itself, is contained in $\left\langle{a}\right\rangle$.

Thus $\left\langle{a}\right\rangle = \left({\Z_m, +_m}\right)$ iff $1_{\Z_m} \in \left\langle{a}\right\rangle$.

However, from Subgroup of Additive Group Modulo m is Ideal of Ring, $\left\langle{a}\right\rangle$ is an ideal of $\left({\Z_m, +_m, \times_m}\right)$, and hence is the principal ideal $\left({a}\right)$ generated by $a$.

But from Principal Ideal from Element in Center of Ring, $1_{\Z_m} \in \left\langle{a}\right\rangle$ iff $a$ is a unit of the ring $\left({\Z_m, +_m, \times_m}\right)$.

Hence the result.