The original title (on which gpr) commented was "Matrices over $\mathbb{Z}_n$", which is not a bad title, but then I think the current one (the one essentially suggested by gpr and made by me just taking the first line of the question basically) "Number of idempotent $n \times n$ matrices over $\mathbb{Z}_m" is quite a bit more informative (besides the usage of the letter n now being the same in title and body).
]]>