Which of the following mappings is well-defined?
a) $f: \mathbb{Z}_m \rightarrow \mathbb{Z}_m, \overline{x} \mapsto \overline{x^2}$
b) $g: {\mathbb{Z}}_m \rightarrow {\mathbb{Z}}_m, \overline{x} \mapsto \overline{2^x}$
I think the second one is not well defined because of the counter example in $\mathbb{Z}_5$
$5 \mapsto \overline{2^5} = \overline{2}$ but $10 \mapsto \overline{2^{10}} = \overline{4}$
But how do I proof/disproof a)
thank you
For b), you were right. To look at a, we say $x = a + m\cdot q$ and see if the result is independent of $m$, i.e. if $f(a+m\cdot q) \equiv f(a)$: $$f(a+m\cdot q) = (a + m\cdot q)^2 = a^2 + 2m\cdot q + m^2 q^2 \equiv a^2 = f(a) \qquad (\text{mod }m)$$ This concludes the proof, that $f$ is well-defined