# Structure theorem of finitely generated modules over a PID

I want to prove the structure theorem of finitely generated modules over a PID using the primary decomposition in a Noetherian $R$-module $M$.

Applying the results on primary decomposition to the case when $R$ is a PID I know that $M_{tor}=\bigcap_{i=1}^n N_i$ where $(N_i:M)=(p_i^{m_i})$ and $(N:M)=\prod_{i=1}^n(p_i^{m_i})$ and this factorization is unique. My question is if I could use this to prove that

$M_{tor}\cong R / (q_1^{k_1})\bigoplus R / (q_2^{k_2}) \bigoplus ... \bigoplus R / (q_s^{k_s})$ in some way?

Grouping together therms corresponding to the same prime $q$ I have that $M_{tor}\cong N_1\bigoplus N_2 \bigoplus ... \bigoplus N_m$ where $N_i=\{x\in M:ann(x)=q_i^{\alpha _i}, \alpha _i \in \mathbb{N}\}$. Since $Ass(M)$ consists of those prime ideals $P$ of $R$ such that $P=ann(x)$ for some $x\in M$ by the above observation we must have that $Ass(M_{tor})=\{q_1,q_2,...,q_m\}$ and if we assume the primary decomposition of $M_{tor}$ to be irredundandant we must have that the $p_is$ equal the $q_is$. Hence there is some connection between the primary decomposition and the structure theorem, please help me see how I can use this!

-
Hint: try to look here at Proposition 10.1.10. If you have questions related to the proof or else, please let me know. – user26857 Dec 2 '12 at 16:26