Count the number of elements of ring

1/ How to count the number of elements of $\mathbb{Z}[i]/(1+2i)^n$?

2/ How to write $\mathbb{Z}[i]/(1+2i)^n$ as direct sum of cyclic groups (in view of the structure theorem of finite abelian groups)?

Solutions Collecting From Web of "Count the number of elements of ring"

Write $(1+2i)^n=u+iv$, $u,v\in\mathbb Z\setminus\{0\}$. Since $\mathbb Z[i]\simeq\mathbb Z\times\mathbb Z$ (as $\mathbb Z$-modules), we have $$\mathbb Z[i]/(u+iv)\simeq \mathbb Z\times\mathbb Z/\langle(u,v),(-v,u)\rangle.$$ The Smith Normal Form of the matrix $\left(\begin{matrix}u&v\\-v&u \end{matrix}\right)$ is $\left(\begin{matrix}1&0\\0&u^2+v^2 \end{matrix}\right)$. (It is not hard to show that $\gcd(u,v)=1$.) Thus we get $$\mathbb Z[i]/(u+iv)\simeq \mathbb Z/(u^2+v^2)\mathbb Z.$$ This shows that $|\mathbb Z[i]/(u+iv)|=u^2+v^2$, and therefore $$u^2+v^2=N(u+iv)=N((1+2i)^n)=N(1+2i)^n=5^n.$$

Here’s one approach you could take. Note that $(1+2i)^n(1-2i)^n=5^n$ and $(1+2i)^n$ and $(1-2i)^n$ are coprime in $\mathbb{Z}[i]$, so by the Chinese remainder theorem, $$\mathbb{Z}[i]/5^n\cong \mathbb{Z}[i]/(1+2i)^n\times \mathbb{Z}[i]/(1-2i)^n$$ as rings. But $$\mathbb{Z}[i]/(1+2i)^n\cong \mathbb{Z}[i]/(1-2i)^n$$ as rings (though not as $\mathbb{Z}[i]$-modules) by sending $i$ to $-i$, and it is easy to see that the underlying abelian group of $\mathbb{Z}[i]/5^n$ is $\mathbb{Z}/5^n\times\mathbb{Z}/5^n$ (since an element of $\mathbb{Z}[i]/5^n$ is just a number $a+bi$ where both $a$ and $b$ are taken mod $5^n$). If you have any decomposition of $\mathbb{Z}/5^n\times\mathbb{Z}/5^n$ as a product of two isomorphic abelian groups, then both factors must be isomorphic to $\mathbb{Z}/5^n$ (this follows easily from the classification of finite abelian groups, for instance). Thus the additive group of $\mathbb{Z}[i]/(1+2i)^n$ must be isomorphic to $\mathbb{Z}/5^n$.