Canonical P-adic Expansion of Rational is Eventually Periodic/Sufficient Condition

Theorem
Let $\struct {\Q_p, \norm {\,\cdot\,}_p}$ be the $p$-adic numbers for some prime $p$.

Let the canonical expansion of $x$ be eventually periodic.

Then:
 * $x$ be a rational number

Proof
Let the canonical expansion of $x$ be eventually periodic.

Lemma

 * $\exists r \in Q, n \in \Z, y \in \Q_p$:
 * $(1) \quad x = r + p^n y$
 * $(2) \quad$the canonical expansion of $y$ is periodic

To show that $x$ is a rational number it is sufficient to show that $y$ is a rational number.

Let
 * $\ldots d_{k - 1} \ldots d_1 d_0 d_{k - 1} \ldots d_1 d_0 d_{k - 1} \ldots d_1 d_0$

be the periodic canonical expansion of $y$.

By definition of a canonical expansion:
 * $y = d_0 + d_1 p + \ldots + d_{k-1} p^{k-1} + d_0 p^k + d_1 p^{k+1} + \ldots + d_{k-1} p^{2k-1} + d_0 p^{2k} + \ldots$

Let $a = d_0 + d_1 p + \ldots + d_{k-1} p^{k-1}$.

Then:
 * $y = a \paren { 1 + p^k + p^{2k} + \ldots }$

Lemma

 * $1 + p^k + p^{2k} + p^{3k} + \ldots = \dfrac 1 {1 - p^k}$

Then:
 * $y = \dfrac a {1 - p^k}$

Hence:
 * $y$ is a rational number

It follows that $x$ is a rational number.