I just constructed the semidirect product in Lang, and I'm trying to tie some facts together. From Ash's Algebra, I know that if $p\lt q$ are distinct primes, if $q\not\equiv 1\pmod{p}$, then any group $G$ of order $pq$ is abelian.

Is the converse true, that for any primes $p\lt q$, if $q\equiv 1\pmod{p}$ then there exists a nonabelian group of order $pq$?

One example I found online is that $\mathbb{Z}_3\ltimes \mathbb{Z}_7$ is nonabelian, and here $7\equiv 1\pmod{3}$. I was considering then semidirect products $\mathbb{Z}_p\ltimes\mathbb{Z}_q$ where $q\equiv 1\pmod{p}$ and some homomorphism $\phi\colon \mathbb{Z}_p\to\operatorname{Aut}(\mathbb{Z}_q)$ I calculate that $$ (1,0)(0,1)=(1+0,\phi_0(0)+1)=(1,1) $$ and $$ (0,1)(1,0)=(0+1,\phi_{-1}(1)+0)=(1,\phi_{p-1}(1)). $$ Is it true somehow that $\phi_{p-1}(1)\neq 1$ in each case to show the group is nonabelian? I guess if it did this would imply $\phi_{p-1}$ is the trivial automorphism, so maybe there's something there? If not, is there a way to show $\mathbb{Z}_p\ltimes\mathbb{Z}_q$ is nonabelian in these cases in general? Thanks.

  • $\begingroup$ @Dylan, I have my group operation defined as $(a_1,b_1)(a_2,b_2)=(a_1a_2,\phi_{a_2^{-1}}(b_1)b_2)$. $\endgroup$
    – yunone
    Sep 9, 2011 at 23:40
  • $\begingroup$ I see. I'm used to a different convention, so I became confused. No issues now! $\endgroup$ Sep 9, 2011 at 23:49

3 Answers 3


Given $p,q$, with $p<q$ and $p|(q-1)$, there exist a non-abelian group of order $pq$ and it is unique up to isomorphism:

If $G$ is a non-abelian group, $|G|=pq$, then subgroup $H$ of order $q$ is normal (by Sylow theorem); let $K$ be its subgroup of order $p$. Then $HK\leq G$ (since $H\triangleleft G$) and $HK=G$ (since $|KH|=|H|.|K|/|H\cap K|=pq=|G|$). So,

$H\triangleleft G$, $K\leq G$, $HK=G$, $H\cap K=(1)$ $\implies G\cong H \rtimes K$.

Now, to get all possible (non-isomorphic) semidirect products $H$ by $K$, we have to consider homomorphisms $\phi \colon K \rightarrow Aut(H)$.

Since $K\cong \mathbb{Z}/p$, $H\cong \mathbb{Z}/q$, we know that $Aut(H)\cong \mathbb{Z}/(q-1)$.

As $p|(q-1)$, and $Aut(H)$ is cyclic group of order $q-1$, it contains unique subgroup of order $p$. So for any two non-trivial homomorphisms $\phi, \psi \colon K\rightarrow Aut(H)$, we have $\phi(K)=\psi(K)$, and $K$ is cyclic. Also, these homomorphisms are injective, since $K$ is of prime order. (Note that trivial homomorphisms will give direct product of $H$ by $K$, so $G\cong H\times K$, abelian group of order $pq$).

Therefore by following theorem semidirect products of $H$ by $K$ w.r.t. $\phi$ and $\psi$ are isomorphic:

If $K$ is a cyclic group and $\phi,\psi\colon K\rightarrow Aut(H)$ are two injective homomorphisms such that $\phi(K)=\psi(K)$, then these two homomorphisms give isomorphic semi-direct products of $H$ by $K$ (Alperin and Bell- Groups and Representations).

Now it is clear the existance and uniqueness (up to isomorphism) of non-abelian groups of order $pq$.


I'm going to use a few facts from group theory, which are certainly in Lang. Let me know if I can clear anything up!

It should be clear that a non-trivial homomorphism $$ \mathbf Z/p\mathbf Z \to \operatorname{Aut}(\mathbf Z/q\mathbf Z) $$ will answer your question in the affirmative. You could use such a map to finish your calculations, since it will necessarily be an injection and so the class of $-1$ will map to an automorphism which is not the identity, which must move $1$.

Recall that $\operatorname{Aut}(\mathbf Z/q\mathbf Z)$ is isomorphic to $(\mathbf Z/q\mathbf Z)^*$. Since $q$ is prime, the latter group is cyclic; we can identify it with $\mathbf Z/(q - 1)\mathbf Z$ if we choose a primitive root mod $q$. Now, to give a non-trivial homomorphism $\mathbf Z/p\mathbf Z \to \mathbf Z/(q - 1)\mathbf Z$ is to give an element of $\mathbf Z/(q - 1)\mathbf Z$ having period $p$. I claim that you can find $p - 1$ such elements if $p$ divides $q - 1$.

In your example, $3$ is a primitive root mod $7$ and we can send $1 \in \mathbf Z/3\mathbf Z$ to the automorphism of $\mathbf Z/7\mathbf Z$ given by $a \mapsto 9a = 2a$.

  • $\begingroup$ @yunone Yes, although I think it might be hard to actually calculate $\phi_{p - 1}$ in general. Also, I messed up some numbers. One second. $\endgroup$ Sep 10, 2011 at 0:36
  • $\begingroup$ Thanks, when you have the chance, doyou mind expanding on the line "Now, to give a non-trivial homomorphism...having period $p$." How does an element of period $p$ show a nontrivial homomorphism? And why does $q\equiv 1\pmod{p}$ imply such elements exist? $\endgroup$
    – yunone
    Sep 10, 2011 at 0:42
  • $\begingroup$ @yunone Sure. You only have to specify one element because the domain is a cyclic group, so you just have to specify a valid image of $1$. The only constraint on the image in this case is that it have period (maybe I should say order) dividing $p$. To get an element of period $p$, I would review stuff like Theorem 3.5 in Keith Conrad's handout. $\endgroup$ Sep 10, 2011 at 0:50
  • $\begingroup$ There's also a discussion in section I.4 of Lang. $\endgroup$ Sep 10, 2011 at 0:54
  • $\begingroup$ Ah, I remember now. This comes from 4.3(iv). Thanks for your help. $\endgroup$
    – yunone
    Sep 10, 2011 at 0:59

A nontrivial homomorphism $\varphi\colon\mathbb Z_p\to\operatorname{Aut}(\mathbb Z_q)$ exists in the form of an embedding, because $\operatorname{Aut}(\mathbb Z_q)$ is cyclic of order $q-1$ and $p\mid q-1$. But to build up a semidirect product $\mathbb Z_p\stackrel{\varphi}{\ltimes}\mathbb Z_q$ in terms of its Cayley table, you've got to explicitly know how the automorphisms $\varphi_\alpha$ do operate, for every $\alpha\in\mathbb Z_p$. Necessarily, $\varphi_0=Id_{\mathbb Z_q}$ and, for $j=1,\dots, p-1$, $\varphi_j$ has order $p$. Since $\varphi_j$ is an automorphism of $\mathbb Z_q$, $\varphi_j(0)=0$ and, for every nontrivial $k$, $\varphi_j(k)=$ $k\varphi_j(1)$. By induction: $$\varphi_j^n(k)=k\varphi_j(1)^n$$ and since $\varphi_j$ has order $p$: $$\varphi_j(1)^p=1$$ Therefore, each of the $p-1$ elements of order $p$ in $\mathbb Z_q^\times$ generates a distinct automorphism of $\mathbb Z_q$, of order $p$. Denoted with $x\in\mathbb Z_q^\times$ one of such elements of order $p$, the other ones are $x^2,\dots,x^{p-1}$, and with them all we get the recipe (cycle notation): \begin{alignat}{1} \varphi_1 &:= (1,x,\dots,x^{p-1})(i_2,i_2x,\dots,i_2x^{p-1})\dots(i_N,i_Nx,\dots,i_Nx^{p-1}) \\ \varphi_k &:= \varphi_1^k,\text{ for }k=2,\dots,p-1 \\ \tag1 \end{alignat} where $N:=\frac{q-1}{p}$ and $R:=\{i_1:=1,i_2,\dots,i_N\}$ is a set of cosets representatives of the quotient $\mathbb Z_q^\times/\langle x\rangle$.

Once you get all the $\varphi_j$'s from $(1)$, you can plug them into the definition of semidirect product to explicitly build up $G$ as $\mathbb Z_p\stackrel{\varphi}{\ltimes}\mathbb Z_q$ (Cayley table). By renaming the generator of order $p$, you just change the order in the sequence $(\varphi_j)_{j=1,\dots,p-1}$ gotten from $(1)$, so this construction is essentially unique.

Example 1. Take $p=3$, $q=7$, $x=2$ (in fact $2$ has order $3$ in $\mathbb Z_7^\times$). Hence $N=2$, and $(1)$ yields: \begin{alignat}{1} &\varphi_{1}=(1,2,4)(3,6,5) \\ &\varphi_{2}=(1,4,2)(3,5,6) \\ \end{alignat} Example 2. Take $p=5$, $q=11$, $x=3$ (in fact $3$ has order $5$ in $\mathbb Z_{11}^\times$). Hence $N=2$, and $(1)$ yields: \begin{alignat}{1} &\varphi_{1}=(1,3,9,5,4)(2,6,7,10,8) \\ &\varphi_{2}=(1,9,4,3,5)(2,7,8,6,10) \\ &\varphi_{3}=(1,5,3,4,9)(2,10,6,8,7) \\ &\varphi_{4}=(1,4,5,9,3)(2,8,10,7,6) \\ \end{alignat} Example 3. Take $p=3$, $q=13$, $x=3$ (in fact $3$ has order $3$ in $\mathbb Z_{13}^\times$). Hence $N=4$, and $(1)$ yields: \begin{alignat}{1} &\varphi_{1}=(1,3,9)(2,6,5)(4,12,10)(7,8,11) \\ &\varphi_{2}=(1,9,3)(2,5,6)(4,10,12)(7,11,8) \\ \end{alignat}


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .