I think this is correct:
If $\phi:\mathbb Z^{n}\to\mathbb Z^{k}$ is a group homomorphism then $n=\operatorname{rank}\operatorname{im}\phi+\operatorname{rank}\ker\phi$.
Here is my attempt at a proof:
$\phi$ may be naturally and uniquely extended to a linear map between $\mathbb Q$-vector spaces $\widetilde{\phi}:\mathbb Q^{n}\to\mathbb Q^{k}$, where $n=\dim\operatorname{im}\widetilde{\phi}+\dim\ker\widetilde{\phi}$.
My questions:
- Is this proof correct? I am concerned with "rank" either not making sense for subgroups or not coinciding with "dimension".
- Does this appear in books (maybe with different formulation)? I have not found it in some standard textbooks I've looked in.