Image of a fixed element under a random endomorphism in an Abelian group

Let $G$ be a finite Abelian group with endomorphism ring $End(G)$. I am interested in the probability $P(\phi(g_1) = g_2)$ for fixed $g_1,g_2 \in G$ and a uniformly chosen endomorphism $\phi(\cdot)$ from $End(G)$. Essentially, I want to understand where the set of endomorphisms will take each element $g \in G$. I ran into this question while considering homomorphic compression schemes that compress an $n$-length sequence $g^n$ into a sequence of length $k$ by applying a homomorphism $\phi \colon G^n \rightarrow G^k$. I describe the question in detail below.

Let $\mathbb{Z}_n$ be the cyclic group of $n$ elements. If $G ={\mathbb{Z}_{p^r}}$, I understand what is going on and can prove for instance that $\phi(g)$ is uniformly distributed across the smallest subgroup of $\mathbb{Z}_{p^r}$ that $g$ belongs to as $\phi(\cdot)$ varies over $End(\mathbb{Z}_{p^r})$. But, I am having trouble understanding what happens in the case of groups of the form $\mathbb{Z}_{p^r}^k$ such as $\mathbb{Z}_2^2$ for example. In this case, $\phi(g)$ is uniformly distributed over $\mathbb{Z}_2^2$ for all non-identity $g$ regardless of which subgroup $g$ belongs to.

Question: Is there a uniform way to write down the probability $P(\phi(g_1) = g_2)$ for fixed $g_1,g_2 \in G$ and an arbitrary $\phi(\cdot) \in End(G)$ for a finite Abelian group $G$?

I would greatly appreciate any pointers and hope the question isn't too elementary for MO. Please feel free to edit/re-tag the question if needed.

-

For a group $G=\mathbb{Z}_{p^r}^k$ this is quite straightforward. Let $g$ have order $p^r$ in $G$ (if not then we are effectively working in $\mathbb{Z}_{p^s}$ where $s < k$). Applying an automorphism of $G$ we can assume that $g=(1,0,\ldots,0)$. Endomorphisms of $G$ correspond to matrices over $\mathbb{Z}_{p^r}$. The image of $s$ is the first row (or column if you put the map on the other side) and we see that the image of $s$ is uniformly distibuted over all of $G$.

Now consider a general finite abelian $p$-group $G$. Let $g\in G$. We can write $G=\langle h\rangle\times H$ where $g=p^s h\in H$ and $h$ has order $p^m$ for some $m\ge s$. We can specify an endomorphism of $G$ by mapping $h$ to any element $h'$ of order $\le p^m$ and taking any homomorphism from $H$ to $G$. Then the $h'$ are uniformly distributed amongst the elements of order $\le p^m$ in $G$ and $g'$ is mapped to $g'=p^{m-r}h'$. These $g'$ are uniformly distributed over a certain subgroup of $G$.

For general finite abelian $G$ split up $G$ as a product of its Sylow $p$-subgroups. Then $g\in G$ splits up into its primary components and each of these behave in the same way, under a random endomorphism, as in the $p$-group case above.

Added I now see that the argument I gave in the prime power case is valid in the general case too. The key observation is that a maximal cyclic subgroup of a finite abelian group is a direct summand. Let $g\in G$ have order $m$ and let $H$ be a maximal cyclic subgroup of order $mn$ containing $\langle g\rangle$. Then the images of $g$ under random endomorphisms of $G$ are uniformly distributed in the subgroup $n G[mn]$ of $G$ where $G[mn]$ denotes the $mn$-torsion subgroup of $G$.

Added (4/7/2010) Thanks to Tom for pointing out my error above. The argument I had in mind for proving that maximal cyclic groups are summands doesn't actually work. :-( As t3suji points out, the images are uniformly distributed over a subgroup. Identifying this subgroup looks like being a bit more fiddly than I believed and I lack the patience to do it now. It seems that reduction to the prime power case is a good way to proceed.

-
To me, the following comment explains the simplicity of the answer. It is a priori clear that (in the case of abelian $G$) the images are distributed uniformly in a subgroup, because the map $ev:End(G)\to G:\rho\mapsto\rho(g)$ is a group homomorphism. Thus the only question is to describe the image of $ev$, that is, the set of all possible images of $g$. – t3suji Jul 3 '10 at 13:01
Thanks, t3suji. Now that you mention it, this is an obvious point; but it wasn't obvious to me when I was writing the answer. :-) – Robin Chapman Jul 3 '10 at 14:33
It's not true that a maximal cyclic subgroup of a finite abelian group must be a summand. If $G$ is the product of two cyclic groups of order $p^3$ and $p$ then there is a maximal cyclic subgroup of order $p^2$. – Tom Goodwillie Jul 4 '10 at 3:00
Tom Goodwillie's comment shows that the answer is not as simple. Maybe the following approach works: assume $G$ is a p-group. It's isomorphism type is given by a partition. If $g\in G$ is a non-zero element, the isomorphism type of $(g,G)$ is probably given by a bipartition (this should be similar to classification of pairs (vector,nilpotent operator), see Achar, Henderson: Orbit closures in an enhanced nilpotent cone). Now define order on isomorphism classes by saying that $(g,G)<(h,G)$ if $h$ is the image of $g$. I expect this is the same order on bipartitions as in Achar-Henderson's paper. – t3suji Jul 4 '10 at 4:34
@Robin,t3suji and Tom: Thanks for your comments. I am still trying to grok the arguments. I don't have much exposure to group theory but I hope to get there soon :) I am hoping to specialize Robin's answer and the ensuing comments to the case of $\mathbb{Z}_4$ vs $\mathbb{Z}_2^2$ and go from there. Thanks again. – Dinesh Jul 7 '10 at 1:38