I was motivated by the inverse of the Fermat's little thm, so this make me the below questions.
First, for the $a \in \mathbb{Z}$, Is "$a^p\equiv a\pmod p \Rightarrow [a] \in\mathbb{Z}_p$" hold? Then, Why?
(Here the $[a]$ is equivalent class for $mod p$ with the $a \in \mathbb{Z}$ )
Second, Considering a field $K$ s.t. extension field of the $\mathbb{Z}_p$ and say $a \in K$
Then Is "$a^p\equiv a\pmod p \Rightarrow a \in\mathbb{Z}_p$" true? and why?
(Well.. Though $K$ is a arbitrary extension, someone said it is hold. But I'm don't know exact reason why that is true)
I approached those as intuitively thought, So my conclusion is all the two things are true. But As you knew it doesn't not ensure perfectness.
If those are correct, Would you give me some idea to prove those?
Thanks.
If I understood properly what you mean in the second question, you are asking if $K$ is an extension field of $\mathbb{Z}_{p}$ and $a \in K$ is such that $a$ is a root of the polynomial $x^{p}-x \text{ for } x \in K$, then $x \in \mathbb{Z}_{p}$.
The field $\mathbb{Z}_{p}$ has exactly p elements and from field theory one knows the polynomial $x^{p} - x$ has at most p roots in $K$. But from Fermat's Little Theorem, every element of $\mathbb{Z}_{p}$ is a root of this polynomial. Therefore, every root must be an element of $\mathbb{Z}_{p}$.
As for the first question, I don't understand what you mean as $\mathbb{Z}$ is not an extension of $\mathbb{Z}_{p}$ since it is not even a field.