Computing $\operatorname{Hom}_{\mathbb{Z}}(G, C_p)$

66 Views Asked by At

Let $G$ be a finite abelian group and $C_n$ the cyclic group with $n$ elements. I'm trying to compute $\operatorname{Hom}_{\mathbb{Z}}(G, C_p)$ for a prime $p$.

We can write $G \cong C_{n_1} \times \dots \times C_{n_k}$, in which case a morphism $\varphi \colon G \to C_p$ is the same as a morphism $\varphi_i \colon C_{n_i} \to C_p$ for each $i$. But $$\operatorname{Hom}_{\mathbb{Z}}(C_{n_i}, C_p) \cong \begin{cases}0, &&\text{if $p \nmid n_i$} \\ C_p, &&\text{if $p \mid n_i$.} ​\end{cases}$$ So if $N$ is the number of $C_{n_i}$ such that $p \mid n_i$, then $$\operatorname{Hom}(G, C_p) \cong C_p^{N}.$$ Is this correct? I just want to make sure I'm not overlooking anything.