Proof of:

The direct product of two cyclic groups Cn and Cm is cyclic if and only if n and m are coprime.

A nice answer is found here:

http://uk.answers.yahoo.com/question/in ... 620AALnR1t

Suppose Cn x Cm is cyclic and let (x,y) be a generator. Then x is a generator of Cn and y is a generator of Cm (this should be obvious). This means |x| = n and |y| = m Also |(x,y)| = nm, since |Cn x Cm| = nm. However, we also have |(x,y)| = lcm(n,m), and from a basic result in number theory, we have

gcd(n,m)*lcm(n,m) = nm, which means

gcd(n,m) = nm/lcm(n,m) = nm/nm = 1

Thus, m and n are relatively prime.

Conversely, suppose n and m are relatively prime and let x be a generator of Cn and y be a generator of Cm. Then, |(x,y)| = lcm(n,m) = nm = |Cn x Cm|. Thus, Cn x Cm is cyclic.