Does exactness of $0 \to \Bbb Z^n \to G \to \Bbb Z^m \to 0$ imply $G$ is isomorphic to $\Bbb Z^{m+n}$? Suppose we have an exact sequence of abelian groups $0 \to \Bbb Z^n \to G \to \Bbb Z^m \to 0$. By exactness, we know that $G/\Bbb Z^n$ is isomorphic to $\Bbb Z^m$ (here we are identifying $\Bbb Z^n $ with its image, since $\Bbb Z^n \to G$ is injective). 
From this, can I conclude that $G$ is isomorphic to $\Bbb Z^{m+n}$?
Intuitively this seems true, but how do I have to prove this?
 A: Yes, consider a map $h:\mathbb{Z}^m\rightarrow G$ such that $p\circ h=Id$ where $p:G\rightarrow\mathbb{Z}^m$ is the projection map. Let $e_1,...,e_m$ generators of $\mathbb{Z}^m$. $H$ the subgroup generated by $h(e_1),...,h(e_n)$. $H$ is isomorphic to $\mathbb{Z}^m$, and $G$ is isomorphic to $i(\mathbb{Z}^n)\oplus H$ where $i:\mathbb{Z}^n\rightarrow G$.
A: This exact sequence splits. If $\pi:G\to\Bbb Z^m$ is the surjection in
the exact sequence, then there is a homomorphism $\phi:\Bbb Z^m\to G$ with
$\pi\circ\phi$ the identity on $\Bbb Z^m$. To do this, let $e_1,\ldots,e_m$
be the standard basis of $\Bbb Z^m$ and pick some $g_i$ with $\pi(g_i)=e_i$.
Define $\phi(a_1e_1+\cdots+a_me_m)=a_1g_1+\cdots+a_me_m$.
Then $G$ is the direct sum of the $\Bbb Z^n$ inside $G$ with $\pi(\Bbb Z^m)
\cong\Bbb Z^m$.
A: It's true because free groups have the splitting property:

Theorem. Let $F$ be a free group. Then any surjective group homomorphism $\pi:G\rightarrow F$ has a right inverse homomorphism $\varphi:F\rightarrow G$, i.e. $\pi\circ\varphi=\mathrm{id}$.

(Even if $\pi$ isn't surjective, its image is still free by the Nielsen--Schreier Theorem. So $\varphi$ is defined on the image of $\pi$.)
The theorem isn't that hard to prove either. Suppose $F$ is free on the set of symbols $\{x_i\}$. Since $\pi$ is surjective, select any $g_i\in G$ so that $\pi(g_i)=x_i$. Now simply define $\varphi$ on the $x_i$'s by $\varphi(x_i):=g_i$; by the universal property of free groups, $\varphi$ extends to a homomorphism $\varphi:F\rightarrow G$. QED!
When a homomorphism $\pi:G\rightarrow H$ splits (i.e. has a right inverse), you always reconstruct $G$ as a semidirect product of $H$ with the kernel: $G\simeq \ker(\pi)\rtimes H$.
Basically the same thing holds in the abelian category:


*

*if $F$ is free abelian (i.e. $F\simeq \mathbb{Z}^I$), then any short exact sequence $0\rightarrow A\rightarrow B\rightarrow F\rightarrow 0$ splits; and,

*if a short exact sequence $0\rightarrow A\rightarrow B\rightarrow C\rightarrow 0$ splits, then $B\simeq A\oplus C$.


Note that if things are abelian, you don't need a semidirect product; a direct sum suffices.
