# $\mathbb{Z}_m \times \mathbb Z_n$ is cyclic if and only if $\gcd(m,n)=1$ [closed]

Let $m,n$ be positive integers bigger than $1$. Show that $\mathbb{Z}_m \times \mathbb Z_n$ is cyclic if and only if $\gcd(m,n)=1$.

I have no idea on how to start. Anyone hints are much helpful.

## closed as off-topic by user26857, C. Falcon, Daniel W. Farlow, Trevor Gunn, JMPJun 23 '17 at 7:13

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question is missing context or other details: Please improve the question by providing additional context, which ideally includes your thoughts on the problem and any attempts you have made to solve it. This information helps others identify where you have difficulties and helps them write answers appropriate to your experience level." – user26857, C. Falcon, Daniel W. Farlow, Trevor Gunn, JMP
If this question can be reworded to fit the rules in the help center, please edit the question.

## 1 Answer

Hint 1: Suppose $d = \gcd(m,n) > 1$. Then $k = \frac{mn}{d}$ is an integer (why?) and every element of $\mathbb{Z}_m \times \mathbb{Z}_n$ has order dividing $k$ (why?). Conclude that $\mathbb{Z}_m \times \mathbb{Z}_n$ cannot be cyclic in this case.

Hint 2: Suppose $d = \gcd(m,n) = 1$. Consider the element $(1,1) \in \mathbb{Z}_m \times \mathbb{Z}_n$ and compute its order. Conlcude that $\mathbb{Z}_m \times \mathbb{Z}_n$ is cyclic in this case.

• Can you tell me why every element of Zm x Zn has order dividing k? – user370967 Jun 21 '17 at 22:27
• @Math_QED: It is an easy calculation $k (a,b) = (0,0)$ for $(a,b) \in \mathbb{Z}_m \times \mathbb{Z}_n$, since $k = m \cdot \frac{n}{d} = n \cdot \frac{m}{d}$, with each of $\frac{n}{d}$ and $\frac{m}{d}$ being integers. Then it follows that $\text{ord}(a,b) \mid k$. – Michael Joyce Jun 22 '17 at 1:25
• Ah yes, I didn't look at it that way! Thanks a lot haha :) – user370967 Jun 22 '17 at 7:53
• @Math_QED: Happy to help. – Michael Joyce Jun 22 '17 at 14:10