Problem: Find all the units in
-
$\mathbb{Z} _7$;
-
$\mathbb{Z} _8$;
-
$\mathbb{Z} _9$;
-
$\mathbb{Z} _{10}$.
Solution: We recall that an element $a\in \mathbb{Z} _n$ is called a unit if the equation $ax=1$ has a solution in $\mathbb{Z} _n$. We have the following important result.
Let $a$ and $n$ be integers with $n>1$. Then $\bar{a}$ is a unit in $\mathbb{Z} _n$ if and only if $\gcd(a,n)=1$ in $\mathbb{Z} $. Thus, for a prime $p$ every nonzero element is a unit.
-
$\mathbb{Z} _7$. Since $7$ is a prime number, so all nonzero elements will be unit. Let us denote the set of all units in $\mathbb{Z} _n$ by $\mathcal{U}_n$, then
\[
\mathcal{U}_7 = \left\{ \bar{1}, \bar{2} ,\bar{3} ,\bar{4} ,\bar{5} ,\bar{6} \right\} .
\]
-
$\mathbb{Z} _8$. The units will be
\[
\mathcal{U} _8 = \left\{ \bar{1} ,\bar{3} ,\bar{5} ,\bar{7} \right\}.
\]
-
$\mathbb{Z} _9$. The units will be
\[
\mathcal{U} _9 = \left\{ \bar{1} ,\bar{2} ,\bar{4} ,\bar{5} ,\bar{7} ,\bar{8} \right\}.
\]
-
$\mathbb{Z} _{10}$. The units will be
\[
\mathcal{U} _{10} = \left\{ \bar{1} ,\bar{3} ,\bar{7} ,\bar{9} \right\} .
\]