# Elementary divisors for chains of submodules

Given free modules $N \le M$ of finite rank over a PID $R$, it's well-known that there is a basis $\{x_1,\ldots,x_n\}$ of $M$ and there are $e_1,\ldots,e_n \in R$ such that $\{e_ix_i\mid e_i \neq 0\}$ is a basis of $N$.

Now my question is, if this property also holds for chains of submodules.

Formally: Let $L \le N$ with $N,M$ as above. Is there a basis $\{ x_1, \ldots, x_n \}$ of $M$ and are there $e_i, f_i\in R$ such that $\{e_ix_i\mid e_i \neq 0\}$ is a basis of $N$ and $\{f_ie_ix_i\mid e_i\neq 0 \wedge f_i \neq 0\}$ is a basis of $L$ ?

This is true for fields but I have no idea if it also holds for all PIDs.