Elementary divisor rings (Smith normal form)

Is the ring $R={\mathbb Z}/n{\mathbb Z}$ an elementary divisor ring? Can you provide an easy proof from well-known results, or a reference to this result?

(Recall that an elementary divisor ring $R$ is one for which every matrix over $R$ is equivalent to a diagonal matrix. The existence of Smith normal form shows that when $R$ is a principal ideal domain, it is an elementary divisor ring. Of course, when $n$ is composite then $R={\mathbb Z}/n{\mathbb Z}$ is not even a domain, although it is a principal ideal ring.)

This follows from the fact that Smith normal forms over $\Bbb{Z}$ exist.
If $\overline{A}$ is matrix over $\Bbb{Z}_n$ then we can, arbitrarily, lift the entries to integers and form a matrix $A$ with integer entries. By the existence of Smith normal forms over $\Bbb{Z}$ there exists invertible (i.e. determinant $=\pm1$) integer matrices $P$ and $Q$ such that $PAQ=D$ is a diagonal matrix.
Reducing that matrix equation modulo $n$ gives $$\overline{D}=\overline{P}\overline{A}\overline{Q}.$$ Here $\overline{D}$ is obviously a diagonal matrix, and because $\overline{P}$ and $\overline{Q}$ have determinants $=\pm\overline{1}$ they are invertible over $R$ (alternatively you can reduce their inverses in a matrix ring over $\Bbb{Z}$ modulo $n$). The claim follows from this.
• Thanks! Actually, I guess the divisibility relations are also induced in ${\mathbb Z}/n{\mathbb Z}$ from the fact that they hold in ${\mathbb Z}$ – user6584 Sep 14 '18 at 13:17
• True, @user6584. It's less clear in which form the uniqueness survives. We do get some uniqueness because the "Smith form" describes the structure of a certain $\Bbb{Z}_n$-module. That is still unique as an abelian group, so even that will survive in some form. – Jyrki Lahtonen Sep 14 '18 at 14:44