Some questions about (normal) subgroups of finite groups

If the number of subgroups $H$ of some finite group $G$ is mentioned, as far as I understood, all subgroups are considered, no matter whether two or more of them are isomorphic, whereas the number of conjugacy classes is the number of different (non-isomorphic) subgroups of $G$. Is that right ?

What is the easiest way to check whether a subgroup $H$ of a group $G$ is normal ? Is it best to check, whether there is an element $a\in G$ and an element $b\in H$, such that $aba^{-1}$ is not element of $H$, or is there a better way ?

MAGMA allows to determine the conjugacy classes and the normal subgroups of a finite group $G$. How can I determine the number of subgroups with MAGMA ?

• There can be subgroups that aren't conjugate, yet still isomorphic. Consider the dihedral group of symmetries of a square: The subgroup $N = \langle 1, r^2 \rangle$ is normal (it's the center), hence conjugate only to itself. But all subgroups generated by reflections are isomorphic to $N$, just not conjugate to $N$. – pjs36 Dec 20 '15 at 19:57
• Also, consider any abelian group, where every subgroup is normal and therefore lives in a conjugacy class containing only itself. E.g. $\mathbb{Z}_p \times \mathbb{Z}_p$ contains $p+1$ cyclic subgroups of order $p$. They are all isomorphic to each other but not conjugate. – Bungo Dec 20 '15 at 20:00
• Yes, e.g. the Klein group $\mathbb Z_2 \times \mathbb Z_2$ has five conjugacy classes of subgroups: the trivial group, the whole group, and the three isomorphic but non-conjugate cyclic subgroups of order $2$. – Bungo Dec 20 '15 at 20:07
• There are many ways to establish the normality of a subgroup. That could easily be a question on its own. For example, a subgroup $H$ is normal in $G$ if and only if its normalizer is all of $G$. The kernel of any homomorphism is normal. Any subgroup whose index is the smallest prime dividing $|G|$ is normal. Any subgroup of the center is normal. There are various special groups which are always normal:any characteristic subgroup (such as the center) is normal. The intersection of all of the conjugates of any given subgroup is normal. There are many other examples. – Bungo Dec 20 '15 at 20:16
• One example in a finite group is that for any given prime $p$, the Sylow $p$-subgroups are always conjugate to each other. – Bungo Dec 20 '15 at 20:17

Magma has a IsNormal(G,H) command to tell you if $H$ is normal in $G$.
If you want to know the number of subgroups of $G$ having some specific property, having a specified order, or just in general all the subgroups, use the Subgroups(G) command. It will list the conjugacy classes, and for each conjugacy class it will tell you the "length"; this is the number of subgroups in that conjugacy class. So you can just add them up.