# If $\gcd(a,b) = 1,$ then why is the set of invertible elements of $\mathbb Z_{ab}$ isomorphic to that of $\mathbb Z_a\times \mathbb Z_b$?

If $\gcd(a,b) = 1,$ then why is the set of invertible elements of $\mathbb Z_{ab}$ isomorphic to that of $\mathbb Z_a\times \mathbb Z_b$?

I know the proof that as rings, $\mathbb Z_{ab}$ is congruent to $\mathbb Z_a\times \mathbb Z_b.$ Does this extend to the sets of their invertible (aka relatively prime elements)? If so, why? Is this equivalent to the assertion that $\gcd(a,bc) = 1$ iff $\gcd(a,b) = 1$ and $\gcd(a,c) = 1?$

Note: I selected the answer as the one that does not utilize the Chinese Remainder Theorem, since I was using this to prove the Chinese Remainder Theorem. Thank you for the help!

• This is just a particular case of the Chinese remainder theorem. – Amitai Yuval Nov 23 '14 at 22:03

gcd$(a, bc) = 1 \Rightarrow$ there exists no prime integer $p$ such that $p|a$ and $p|bc \Rightarrow$ there exists no prime integers $r, s$ such that $r|a, r|b$ and $s|a, s|c \Rightarrow$ gcd$(a, b) = 1$ and gcd$(a, c) = 1.$

On the other hand, suppose gcd$(a, b) = 1$ and gcd$(a, c) = 1.$ Let $p$ be a prime integer such that $p|a, p|bc.$ Then $p|b$ or $p|c,$ a contradiction.

Yes in general, if $R \to S$ is an isomorphism of rings, one easily checks that it restricts to an isomorphism of the unit groups $R^\times \to S^\times$. And for two rings $R_1,R_2$ we clearly have $(R_1 \times R_2)^\times = R_1^\times \times R_2^\times$.

• PS: Really no number-theoretic computation (see other answers) is necessary for this ... – Martin Brandenburg Nov 23 '14 at 23:23
• Thanks! I am using this as the base case of an inductive argument to prove the CRT, which I should have specified in the question. – justin Nov 23 '14 at 23:24
• This seems to be a little bit weird. The general CRT in ring theory has a two-line proof, no induction or anything beyond the definitions is needed. – Martin Brandenburg Nov 23 '14 at 23:28
• Okay, thank you for the tip. I just started learning about ring theory, so I'm probably not doing this the most efficient way. – justin Nov 23 '14 at 23:32

It is easy to prove that $x$ is invertible $\pmod{ab}$ if and only if $x$ is invertible $\pmod{a}$ and $x$ is invertible $\pmod{b}$:

$\Rightarrow$:

If $xy \equiv 1 \pmod{ab}$ then $xy \equiv 1 \pmod{a}$ and $xy \equiv 1 \pmod{b}$.

$\Leftarrow$:

Let $xy_1 \equiv 1 \pmod{a}$ and $xy_2 \equiv 1 \pmod{b}$. By CRT you can find an $y$ such that $y \equiv y_1 \pmod{a}$ and $y \equiv y_2 \pmod{b}$. Then $$xy \equiv 1 \pmod{a} \\ xy \equiv 1 \pmod{b}$$ Therefore, by the uniqueness of CRT $xy \equiv 1 \pmod{ab}$.