I need to plot the following hasse diagrams:
1) 
2)
I tried using xypic. For the first I worte the following code
\xymatrix{
&{G}\ar@{-}[dr]\ar@{-}[dl] \\
{\mathbb{Z}_p}\ar@{-}[dr] & & \mathbb{Z}_q}\ar@{-}[dl]}\\
{{e}} \\
}
but it displays nothing. About second one, I don't really know from where to start. I can write also this wrong code:
\xymatrix{
& {HK}\ar@{-}[dr]\ar@{=}[dl]\\
H@\ar{=}[dr] & K@\ar{-}[dl]\\
{H\cap K}
}
How can I plot them both? Where is my mistake?


tikz-cd.tikz-cdhas an advantage in that it allows you to use the power of TikZ. (You can respectfully tell you teacher about this package also :-)). – Gonzalo Medina Aug 26 '13 at 15:59