group extension with finite abelian group I am a student majoring physics. The question below may be simple but confuse me. Thanks for any suggestion or detailed answer.
Given two finite abelian group $N$ and $A$, the question is how many possible $G$ satisfying the following short exact sequence:
$0 \rightarrow N \rightarrow G \rightarrow A \rightarrow 0$.
In another words(to my understanding), how many possible choices of $G$ which are group extension of $N$ by $A$? I am grateful who can give me the detailed consideration of the case: $N=Z_{n_1}\times Z_{n_2}$, and $A=Z_{m_1} \times Z_{m_2}$.
 A: I don't know if you still need the answer to the question, but I will answer it anyway. As you have probably realized by now, there is no easy answer to this question. 


*

*'How many possible $G$' is too difficult and I shall only be interested in 'How many possible extensions of $A$ by $N$'. Even  with this simplification, it is a complicated problem.

*There are two main ingredients to construct a group extension, you need a group automorphism $\phi: A\to Aut(N)$ and an element in $H^2(A,N_{\phi})$ which is the second cohomology group of $A$ with values in $N$ and the action given by $\phi$ (the definition of this object is not too difficult). 

*The answer to the question : 'How many possible extensions of $A$ by $N$ are there ?' is therefore given by
$$\sum_{\phi\in \hom(A,Aut(N))} \# H^2(A,N_{\phi})$$
and in all generalities, it is pretty much everything you can say.


*If $A$ is cyclic, abstract considerations allow you to say that $H^2(A,N_{\phi})=H^0(A,N_{\phi})$ which is by definition the module $N^{\phi(A)}$ of elements in $N$ fixed by any automorphism in $\phi(A)$. 

*If $|A|$ and $|N|$ happen to be prime to each other, abstract considerations allow you to say $H^2(A,N_{\phi})=\{0\}$. As a result, in this case, you have as many extensions of $A$ by $N$ as $\# \hom(A,Aut(N))$. Furthermore for any $\phi\in \hom(A,Aut(N))$, the associated extension is a semi-direct product :
$$N\rtimes_{\phi}A\text{.} $$
If you are not in case $4$ or $5$, I doubt a lot that you can come to an understandable conclusion. If you are in case 5, I think you can even compute the isomorphism class. 
For a reference about the link between group extensions and $2$-cocycles see the answer to this question.
Central extensions versus semidirect products
Here $H^2(A,N_{\phi})$ is some equivalence class of $2$-cocycles of $A$ with values in $N$, see the comment of Derek Holt to the aforementioned answer. 
