The dihedral group $D_n$ cannot be written as a product of two nontrivial groups Let $n$ be an odd prime. I want to prove that the dihedral group $D_n$ cannot be written as a product of two nontrivial groups. But it seems problematic, as I completely neglect the properties of prime of the $n$ in my proof.
So, first of all, I'm using the fact that $D_n$ have some element of order 2, which are the reflections $r$ across its axes of symmetry. (Edit: I would like to credit Anne Bauval for pointing out my mistake here.)
Next, I'm assuming that $D_n$ can be written as a product $G \times H$ of two nontrivial groups $G$ and $H$, neither of which is equal to $D_n$ itself. Since $D_n$ is not abelian for $n \geq 3$, WLOG $G$ is not abelian. (I doubt this but I can’t think of a good reason for $G$ to be not abelian. Sorry if I made a mistake here.)
Now, I take a nontrivial element $g$ from $G$ and a nontrivial element $h$ from $H$. Since $G$ and $H$ are both nontrivial, $g$ and $h$ both have order at least 2.
Next, I consider the element $(g, h) \in G \times H$. Since $(g, h)$ is not equal to the identity element $(1, 1)$, it must have order at least 2.
If $(g, h)$ has order 2, then I have:
$$(g, h)^2 = (g, h) \cdot (g, h) = (g^2, h^2) = (e,e)$$
where the second equality follows from the fact that $G$ and $H$ are both groups, and the third equality follows from the fact that $(g, h)$ has order 2.
This implies that $g^2 = e$ and $h^2 = e$, which means that $g$ and $h$ both lie in the set of reflections of $D_n$, and hence must commute with each other. But this contradicts the assumption that $G$ is not abelian.
Therefore, $(g, h)$ cannot have order 2. But since $D_n$ has a unique element of order 2, namely $r$, it follows that $(g, h)$ cannot be equal to $r$.
This implies that $G \times H$ cannot contain all of the reflections of $D_n$, and hence cannot be equal to $D_n$ itself. Then it completes the proof (Did I?)
Sorry for the poor presentations. Could someone please take a look at my proof and let me know if there are any errors or if it can be improved? Thank you!
 A: Your proof does not work (there are several irremediable mistakes, pointed in the comments) but contains some inspiring ideas, for a proof which works for every odd $n$ (not necessarily prime).
Suppose $D_n=G\times H$ where $|H|$ is odd. Then, $G$ (viewed as a subgroup of $D_n$) contains at least a reflection $s$ (either by
Cauchy's theorem, or simply by contradiction: else, $G$ and $H$ would only contain rotations, hence so would $D_n$). Then, every element in $H$ is a rotation commuting with $s,$ hence $H=\{1\}.$
Note that when $n=2m$ with $m$ odd, $D_n\cong D_m\times C_2.$
A: I think you need to use that $p$ is an odd prime. So the following proof is probably the one you should have in mind:
By Lagrange, every nontrivial proper subgroup of $D_p$, where $p$ is an odd prime, is isomorphic to $C_2$ or $C_p$. Indeed, the divisors of $2p$ are $1,2,p,2p$. But the direct product of cyclic groups is abelian, hence it cannot be isomorphic to $D_p$ for $p\ge 3$.
A: Let $D_n=H×K$
Then $|G|=|H|\cdot |K|$
Where $H, K$ both are non trivial.
We know
$|D_n|=2n=|H|\cdot |K|$
If $n$ prime and $n\ge 3$, then only non trivial divisors of $|D_n|$ is $2$ and $n$
Hence $H \text{or} K\cong \Bbb{Z}_n \text{or} \Bbb{Z_2}$
Which implies $D_n$ is abelian (or even cyclic)
