$\mathbb Z_{mn}$ isomorphic to $\mathbb Z_m\times\mathbb Z_n$ whenever $m$ and $n$ are coprime

How to show that $\mathbb Z_{mn}$ is isomorphic to $\mathbb Z_m \times\mathbb Z_n$ when $m$ and $n$ are coprime? It is easy to show that the natural map from $\mathbb Z_{mn}$ to $\mathbb Z_m \times\mathbb Z_n$ is a ring homomorphism. How to show that it is bijective?


You define $f:\mathbb{Z}\rightarrow \mathbb{Z}/n\mathbb{Z}\times\mathbb{Z}/m\mathbb{Z}$ by $f(a)=(a\bmod{n},a\bmod{m})$ which is a ring homomorphism.

Then you can verify that $\ker{f}=mn\mathbb{Z}$ and to show that $f$ surjective:

$\gcd{(m,n)}=1$ so there exists $x,y$ such that $xn+ym=1$, so for $(s,t)\in\mathbb{Z}/n\mathbb{Z}\times\mathbb{Z}/m\mathbb{Z}$ consider $a=sxn+tym$. Then since: $$ xn\equiv 1\bmod{m}\text{ and } ym\equiv 1\bmod{n} $$ you have $f(a)=(s,t)$.


The two rings have the same cardinality, so it is enough to show that the homomorphism is injective.

Now, what is the kernel? The kernel consists precisely of those $a \in \mathbb Z_{mn}$ such that $a \equiv 0 \pmod{n}$ and $a \equiv 0 \pmod{m}$. The gcd is 1, so...


The element $(1,1)$ in the direct product has order $mn$ (why?). Then you know the direct product is cyclic, and a cyclic group is uniquely determined (up to isomorphism) by its order.