# Writing the relationships of group elements in terms of modular arithmetic

Consider a group $$G$$ of order $$pq$$ (like ($$\mathbb{Z}_p \times \mathbb{Z}_q$$,+)), where $$p$$ and $$q$$ are distinct primes, and two elements $$g_1, g_2 \in G$$. Suppose $$|g_1|=p$$ and $$|g_2|=q$$. These two elements satisfy the relation,

$$g_1^m g_2^n =e$$, where $$e$$ is the identity element of $$G$$.

Then can we write as,

$$m \equiv 0 (mod p)$$

$$n \equiv 0 (mod q)$$ ?

If it is possible can someone please explain why it is possible? This is not clear to me..

• What is $g$ in $g^mg^n=e$?
– brj
May 10, 2020 at 13:52
• Sorry that was a mistake. Thanks @brj I corrected it now. May 10, 2020 at 17:24

There is a useful result in group theory: $$\forall x\in G$$, and $$m, n\in \mathbb{Z}$$, if $$x^n = 1$$ and $$x^m = 1$$, then $$x^{(m, n)} = 1$$ (where $$(m, n)$$ denotes the greatest common divisor of $$m$$ and $$n$$). To see why this holds, observe that $$(m,n) = mx+ny$$ for suitable $$x$$ and $$y$$ (see Extended Euclidean algorithm for how). Now from this it follows that $$\forall m\in\mathbb{Z}, x^m = 1\iff |x|$$ divides m. Since to say that $$n$$ divides $$m$$ is to say that $$m\equiv 0(mod n)$$, the rest follows.
• Thank you very much @brj . That means from $g_1^m g_2^n =e$, we can get $g_1^m=e \rightarrow (1)$ and $g_2^n=e \rightarrow (2)$. And then using (1) and $g_1^p=e$ we get $m \equiv 0 (mod p)$ and using (2) and $g_2^q=e$ we can get $n \equiv 0 (mod q)$ ? May 10, 2020 at 17:39
• From (1) can we also take as $g_1^m=g_1^p$ and then get $m \equiv p (mod p)$ as well? And same for (2), as $n \equiv q (mod q)$? May 10, 2020 at 17:43
• @BobTraver no, that is incorrect $g_1^mg_2^n$ does not imply $g_1^m$ and $g_2^n$ are $e$ (they can be inverses of each other)
• Ok, @brj but then in my question I know the relation $g_1^m g_2^n =e$ only, then how can I apply the above answer to get $m \equiv 0 (mod p)$ and $n \equiv 0 (mod q)$? May 10, 2020 at 17:54