A p-adic map is injective for rational numbers and surjective for irrationals. Does this imply the converse? I have a bijective function that maps the p-adic numbers to a permutation of them. I can prove that under this function each rational p-adic number maps to a rational p-adic number, and each irrational p-adic number is mapped by an irrational p-adic number. 
I speculate that the converse is also true. That is, I know that for my function $f$ and its inverse $f'$
$$\begin{aligned}
f:  \mathbb{Q}_p &\rightarrow \mathbb{Q}_p\\
\text{ and}\\
f': \mathbb{I}_p &\rightarrow \mathbb{I}_p 
\end{aligned}$$ 
What I want is to prove is the converse of these statements: i.e.,
$$\begin{aligned}
f:  \mathbb{I}_p &\rightarrow \mathbb{I}_p\\
\text{ and}\\
f': \mathbb{Q}_p &\rightarrow \mathbb{Q}_p 
\end{aligned}$$ 
If we were dealing with a finite set then I believe the converse statements would be implied and I would have what I want. But is this actually true for the infinite set of p-adic numbers, or do I need to find a proof?
 A: I interpret your question as follows: Call $I_p := \mathbb Q_p \setminus \mathbb Q$ the irrational $p$-adic numbers, and assume we have a bijection $f: \mathbb Q_p \rightarrow \mathbb Q_p$ such that $f(\mathbb Q) \subseteq \mathbb Q$ and $f^{-1}(I_p) \subseteq I_p$ (note however that each of these conditions is equivalent to the other). Can we conclude that also $f(I_p) \subseteq I_p$ (or equivalently $f^{-1}(\mathbb Q) \subseteq \mathbb Q$)?
The answer is no. For example let $f$ be given as follows: Choose a bijection $g: \mathbb Q \rightarrow \mathbb N$ (whose existence is equivalent to the rational numbers being countable infinite), and a bijection $h :\mathbb Q^\times \rightarrow \mathbb Q \setminus \mathbb N$ (whose existence is equivalent to both sets being countable infinite). Choose countable infinitely many irrational $p$-adic numbers $z_0, z_1, z_2, ...$ which are linearly independent over $\mathbb Q$. Set
$$f(x) := \begin{cases}
g(x) \text{ if } x \in \mathbb Q\\
h(y) \text{ if } x = y\cdot z_0 \text{ with } y \in \mathbb Q^\times\\
y\cdot z_{i-1} \text{ if } x = y\cdot z_i \text{ with } y \in \mathbb Q^\times, i \ge 1\\
x \text{ otherwise}
\end{cases}$$
If I'm not mistaken, $f$ is a bijection of $\mathbb Q_p$ with $f(\mathbb Q) \subseteq \mathbb Q$ (and $f^{-1}(I_p) \subseteq I_p$), but $f(I_p) \not\subseteq I_p$ (e.g. $f(z_0) \in \mathbb Q$) (and $f^{-1}(\mathbb Q) \not\subseteq \mathbb Q$).
Note that in spite of the tags "number-theory" and "p-adic-number-theory", since you put no restriction on the function $f$ in terms of being compatible with any arithmetic, algebraic or topological structure of the $p$-adics, this is actually just a set-theoretic question, and the above counterexample just makes a little more explicit in this case what in general would be achieved by a partition of an uncountable set into countable infinitely many countable infinite subsets, and one uncountable one.
