# Explicit construction of the $p$-adic numbers

Jordan Bell
March 17, 2016

## 1 Zp

Let $p$ be prime, let $N_{p}=\{0,\ldots,p-1\}$, and let $\mathbb{Z}_{p}$ be the set of maps $x:\mathbb{Z}\to N_{p}$ such that $x(k)=0$ for all $k<0$.

For $x,y\in\mathbb{Z}_{p}$, we define $x+y\in\mathbb{Z}_{p}$ by induction. Define

 $(x+y)(0)\equiv x(0)+y(0)\pmod{p},\qquad(x+y)(0)\in N_{p}.$

Assume for $k\geq 0$ that there is some $A_{k}\in\mathbb{Z}$ such that

 $\sum_{j=0}^{k}(x+y)(j)p^{j}=A_{k}p^{k+1}+\sum_{j=0}^{k}(x(j)+y(j))p^{j}.$

Define

 $(x+y)(k+1)\equiv-A_{k}+x(k+1)+y(k+1)\pmod{p},\qquad(x+y)(k+1)\in N_{p},$

and then define $A_{k+1}\in\mathbb{Z}$ by

 $(x+y)(k+1)=A_{k+1}p-A_{k}+x(k+1)+y(k+1).$

Then

 $\displaystyle\sum_{j=0}^{k+1}(x+y)(j)p^{j}$ $\displaystyle=(x+y)(k+1)p^{k+1}+\sum_{j=0}^{k}(x+y)(j)p^{j}$ $\displaystyle=A_{k+1}p^{k+2}-A_{k}p^{k+1}+(x(k+1)+y(k+1))p^{k+1}$ $\displaystyle+A_{k}p^{k+1}+\sum_{j=0}^{k}(x(j)+y(j))p^{j}$ $\displaystyle=A_{k+1}p^{k+2}+\sum_{j=0}^{k+1}(x(j)+y(j))p^{j}.$

Thus, for each $k\geq 0$, $(x+y)(k)\in N_{p}$ and

 $\sum_{j=0}^{k}(x+y)(j)p^{j}\equiv\sum_{j=0}^{k}(x(j)+y(j))p^{j}\pmod{p^{k+1}}.$ (1)

It is immediate that $x+y=y+x$.

###### Lemma 1.

If $x,y\in\mathbb{Z}_{p}$ and for each $k\geq 0$,

 $\sum_{j=0}^{k}x(j)p^{j}\equiv\sum_{j=0}^{k}y(j)p^{j}\pmod{p^{k+1}},$

then $x=y$.

###### Proof.

Suppose by contradiction that $x\neq y$. Now, $x(0)\equiv y(0)\pmod{p}$ and $x(0),y(0)\in N_{p}$ so $x(0)=y(0)$. As $x\neq y$, there is a minimal $k\geq 0$ such that $x(k+1)\neq y(k+1)$. On the one hand,

 $\sum_{j=0}^{k+1}x(j)p^{j}=x(k+1)p^{k+1}+\sum_{j=0}^{k}y(j)p^{j},$

and on the other hand,

 $\sum_{j=0}^{k+1}x(j)p^{j}\equiv\sum_{j=0}^{k+1}y(j)p^{j}\pmod{p^{k+2}}.$

Then there is some $B$ such that

 $x(k+1)p^{k+1}=Cp^{k+2}+y(k+1)p^{k+1}.$

so $x(k+1)-y(k+1)=Bp$. But $-p+1\leq x(k+1)-y(k+1)\leq p-1$, so $B=0$ and hence $x(k+1)=y(k+1)$, a contradiction and thus $x=y$. ∎

Therefore, if $t\in\mathbb{Z}_{p}$ satisfies, for all $k\geq 0$,

 $\sum_{j=0}^{k}t(j)p^{j}\equiv\sum_{j=0}^{k}(x(j)+y(j))p^{j}\pmod{p^{k+1}}.$

then $t=x+y$. Now let $x,y,z\in\mathbb{Z}_{p}$. For $k\geq 0$,

 $\displaystyle\sum_{j=0}^{k}(x+(y+z))(j)p^{j}$ $\displaystyle\equiv\sum_{j=0}^{k}(x(j)+(y+z)(j))p^{j}\pmod{p^{k+1}}$ $\displaystyle=\sum_{j=0}^{k}(x(j)+y(j)+z(j))p^{j}\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}((x+y)(j)+z(j))p^{j}\pmod{p^{k+1}},$

which shows that $x+(y+z)=(x+y)+z$.

Define $t\in\mathbb{Z}_{p}$ by $t(k)=0$ for all $k\geq 0$. It is immediate that for $x\in\mathbb{Z}_{p}$, $x+t=x$, $t+x=x$. If $x\neq 0$, let $m\geq 0$ be minimal such that $x(m)\neq 0$, and define $y\in\mathbb{Z}_{p}$ by

 $y(k)=\begin{cases}0&0\leq km.\end{cases}$

This makes sense because $1\leq x(m)\leq p-1$. Then $x(k)+y(k)=0$ for $0\leq k, $x(m)+y(m)=p$, and $x(k)+y(k)=p-1$ for $k>m$. For $k>m$,

 $\displaystyle\sum_{j=0}^{k}(x(j)+y(j))p^{j}$ $\displaystyle=p\cdot p^{m}+\sum_{j=m+1}^{k}(p-1)p^{j}$ $\displaystyle=p^{m+1}+(p-1)\cdot\frac{p^{k+1}-p^{m+1}}{p-1}$ $\displaystyle=p^{k+1},$

so

 $\sum_{j=0}^{k}(x(j)+y(j))p^{j}\equiv\sum_{j=0}^{k}0\cdot p^{j}\pmod{p^{k+1}},$

and it follows that $x+y=0$, $y+x=0$, namely $y=-x$.

We have established that $(\mathbb{Z}_{p},+)$ is an abelian group whose identity is $k\mapsto 0$, $k\geq 0$.

###### Lemma 2.

For $x\in\mathbb{Z}_{p}$ and $m\geq 1$,

 $(p^{m}x)(k)=\begin{cases}0&0\leq k
###### Proof.

For $x\in\mathbb{Z}_{p}$ and $m\geq 1$ define $y(j)=0$ for $0\leq j and $y(j)=x(j-m)$ for $j\geq m$. By (1), for $k\geq m$,

 $\displaystyle\sum_{j=0}^{k}(p^{m}x)(j)p^{j}$ $\displaystyle\equiv\sum_{j=0}^{k}p^{m}x(j)p^{j}\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}x(j)p^{j+m}\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=m}^{m+k}x(j-m)p^{j}\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=m}^{k}x(j-m)p^{j}\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}y(j)p^{j}\pmod{p^{k+1}}.$

The following lemma shows that if $x(k)=0$ for $k then it makes sense to talk about $p^{-m}x\in\mathbb{Z}_{p}$. That is, if $x(k)=0$ for $k then there is a unique $y\in\mathbb{Z}_{p}$ such that $p^{m}y=x$. (For comparison, it is false that for any $z\in\mathbb{C}$ there is a unique $z^{1/2}\in\mathbb{C}$, or that for any $n\in\mathbb{Z}$ there is a unique $p^{-1}n\in\mathbb{Z}$.)

###### Lemma 3.

Let $x\in\mathbb{Z}_{p}$ with $x(0)=0$. If $y\in\mathbb{Z}_{p}$ and $py=x$ then $y(k)=x(k+1)$ for $k\geq 0$.

###### Proof.

By Lemma 2, $(py)(0)=0$ and $(py)(k)=y(k-1)$ for $k\geq 1$, and as $py=x$ this means $x(0)=0$ and $x(k)=y(k-1)$ for $k\geq 1$, i.e. $x(k+1)=y(k)$ for $k\geq 0$. ∎

### 1.2 Multiplication

For $x,y\in\mathbb{Z}_{p}$, we define $xy\in\mathbb{Z}_{p}$ by induction. Define

 $(xy)(0)\equiv x(0)y(0)\pmod{p},\qquad(xy)(0)\in N_{p}.$

Assume for $k\geq 0$ that there is some $A_{k}\in\mathbb{Z}$ such that

 $\sum_{j=0}^{k}(xy)(j)p^{j}=A_{k}p^{k+1}+\left(\sum_{j=0}^{k}x(j)p^{j}\right)% \left(\sum_{j=0}^{k}y(j)p^{j}\right).$

There is some $B\in\mathbb{Z}$ such that

 $\begin{split}&\displaystyle\left(\sum_{j=0}^{k+1}x(j)p^{j}\right)\left(\sum_{j% =0}^{k+1}y(j)p^{j}\right)\\ \displaystyle=&\displaystyle\left(x(k+1)p^{k+1}+\sum_{j=0}^{k}x(j)p^{j}\right)% \left(y(k+1)p^{k+1}+\sum_{j=0}^{k}y(j)p^{j}\right)\\ \displaystyle=&\displaystyle Bp^{k+2}+x(k+1)y(0)p^{k+1}+x(0)y(k+1)p^{k+1}+% \left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}y(j)p^{j}\right).\end{split}$

Hence

 $\displaystyle\left(\sum_{j=0}^{k+1}x(j)p^{j}\right)\left(\sum_{j=0}^{k+1}y(j)p% ^{j}\right)$ $\displaystyle=Bp^{k+2}+x(k+1)y(0)p^{k+1}+x(0)y(k+1)p^{k+1}$ $\displaystyle+\sum_{j=0}^{k}(xy)(j)p^{j}-A_{k}p^{k+1}.$

Now define

 $(xy)(k+1)\equiv x(k+1)y(0)+x(0)y(k+1)-A_{k}\pmod{p},\qquad(xy)(k+1)\in N_{p},$

and let $C\in\mathbb{Z}$ such that

 $(xy)(k+1)=Cp+x(k+1)y(0)+x(0)y(k+1)-A_{k},$

whence, taking $A_{k+1}=B-C$,

 $\displaystyle\left(\sum_{j=0}^{k+1}x(j)p^{j}\right)\left(\sum_{j=0}^{k+1}y(j)p% ^{j}\right)$ $\displaystyle=Bp^{k+2}+(xy)(k+1)p^{k+1}-Cp^{k+2}+A_{k}p^{k+1}$ $\displaystyle+\sum_{j=0}^{k}(xy)(j)p^{j}-A_{k}p^{k+1}$ $\displaystyle=A_{k+1}p^{k+2}+\sum_{j=0}^{k+1}(xy)(j)p^{j}.$

Thus, for each $k\geq 0$, $(xy)(k)\in N_{p}$ and

 $\sum_{j=0}^{k}(xy)(j)p^{j}\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum% _{j=0}^{k}y(j)p^{j}\right)\pmod{p^{k+1}}.$ (2)

It is immediate that $xy=yz$.

For $t\in\mathbb{Z}_{p}$, if for each $k\geq 0$,

 $\sum_{j=0}^{k}t(j)p^{j}\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j% =0}^{k}y(j)p^{j}\right)\pmod{p^{k+1}}.$

then $t=xy$. Now let $x,y,z\in\mathbb{Z}_{p}$. For $k\geq 0$,

 $\displaystyle\sum_{j=0}^{k}(x(yz))(j)p^{j}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}(yz% )(j)p^{j}\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}y(j% )p^{j}\right)\left(\sum_{j=0}^{k}z(j)p^{j}\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}(xy)(j)p^{j}\right)\left(\sum_{j=0}^{k}% z(j)p^{j}\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}((xy)z)(j)p^{j}\pmod{p^{k+1}},$

which shows that $x(yz)=(xy)z$.

Define $u\in\mathbb{Z}_{p}$ by $u(0)=1$, $u(k)=0$ for $k\geq 1$. It is apparent that for $x\in\mathbb{Z}_{p}$, $xu=x$ and $ux=x$.

### 1.3 Ring

For $x,y,z\in\mathbb{Z}_{p}$ and for $k\geq 0$, using (1) and (2),

 $\displaystyle\sum_{j=0}^{k}(x(y+z))(j)p^{j}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}(y+% z)(j)p^{j}\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}(y(% j)+z(j))p^{j}\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}y(j% )p^{j}\right)$ $\displaystyle+\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}z(j)p^{j% }\right)\pmod{p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}(xy)(j)p^{j}+\sum_{j=0}^{k}(xz)(j)p^{j}\pmod{% p^{k+1}}$ $\displaystyle\equiv\sum_{j=0}^{k}(xy+xz)(j)p^{j}\pmod{p^{k+1}},$

which shows that $x(y+z)=xy+xz$. Therefore $\mathbb{Z}_{p}$ is a commutative ring with unity $0\mapsto 1$, $k\mapsto 0$ for $k\geq 1$.

### 1.4 Integral domain

Let $\mathbb{Z}_{p}^{*}$ be the set of those $x\in\mathbb{Z}_{p}$ for which there is some $y\in\mathbb{Z}_{p}$ such that $xy=1$, namely the set of invertible elements of $\mathbb{Z}_{p}$.

###### Lemma 4.

Let $x\in\mathbb{Z}_{p}$. $x\in\mathbb{Z}_{p}^{*}$ if and only if $x(0)\neq 0$.

###### Proof.

If $x(0)=0$ and $y\in\mathbb{Z}_{p}$ then $(xy)(0)\equiv x(0)y(0)\equiv 0\pmod{p}$ while $1(0)\equiv 1\pmod{p}$, so $xy\neq 1$ and therefore $x\not\in\mathbb{Z}_{p}^{*}$.

If $x(0)\neq 0$, we define $y\in\mathbb{Z}_{p}$ by induction. As $x(0)\neq 0$, it makes sense to define

 $y(0)x(0)\equiv 1\pmod{p},\qquad y(0)\in N_{p}.$

We use (2) and the fact that $1(0)=1$, $1(k)=0$ for $k\geq 1$. Suppose for $k\geq 0$ that there is some $A_{k}\in\mathbb{Z}$ such that

 $\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}y(j)p^{j}\right)=A_{k}% p^{k+1}+1.$

Because $x(0)\neq 0$, it makes sense to define

 $y(k+1)x(0)+x(k+1)y(0)\equiv-A_{k}\pmod{p}.$

Then

 $\displaystyle\left(\sum_{j=0}^{k+1}x(j)p^{j}\right)\left(\sum_{j=0}^{k+1}y(j)p% ^{j}\right)$ $\displaystyle\equiv x(k+1)y(0)p^{k+1}+y(k+1)x(0)p^{k+1}$ $\displaystyle\left(\sum_{j=0}^{k}x(j)p^{j}\right)\left(\sum_{j=0}^{k}y(j)p^{j}% \right)\pmod{p^{k+2}}$ $\displaystyle\equiv-A_{k}p^{k+1}+A_{k}p^{k+1}+1\pmod{p^{k+2}}$ $\displaystyle\equiv 1\pmod{p^{k+2}}.$

This shows that $xy=1$, thus $x\in\mathbb{Z}_{p}^{*}$ and $y=x^{-1}$. ∎

###### Theorem 5.

$\mathbb{Z}_{p}$ is an integral domain.

###### Proof.

Let $x,y\in\mathbb{Z}_{p}$ be nonzero. Let $m\geq 0$ be minimal such that $x(m)\neq 0$ and let $n\geq 0$ be minimal such that $y(n)\neq 0$. Then $(p^{-m}x)(0)\neq 0$ and $(p^{-n}y)(0)\neq 0$, and using $p^{-m-n}(xy)=p^{-m}x\cdot p^{-n}y$,

 $\displaystyle(xy)(m+n)$ $\displaystyle\equiv(p^{-m-n}(xy))(0)\pmod{p}$ $\displaystyle\equiv(p^{-m}x)(0)\cdot(p^{-n}y)(0)\pmod{p}$ $\displaystyle\not\equiv 0\pmod{p},$

thus $xy\neq 0$. ∎

### 1.5 p-adic valuation

For $x\in\mathbb{Z}_{p}$, let

 $v_{p}(x)=\inf\{k\geq 0:x(k)\neq 0\}.$

$x(k)=0$ for $0\leq k. $v_{p}(x)=\infty$ if and only if $x=0$.

###### Lemma 6.

For $x,y\in\mathbb{Z}_{p}$,

 $v_{p}(xy)=v_{p}(x)+v_{p}(y)$

and

 $v_{p}(x+y)\geq\min(v_{p}(x),v_{p}(y)).$

Lemma 4 says that for $x\in\mathbb{Z}_{p}$, $x\in\mathbb{Z}_{p}^{*}$ if and only if $x(0)\neq 0$. In other words,

 $\mathbb{Z}_{p}^{*}=\{x\in\mathbb{Z}_{p}:v_{p}(x)=0\}=\{x\in\mathbb{Z}_{p}:|x|_% {p}=1\}.$

For $n\geq 1$, define $\pi_{n}:\mathbb{Z}_{p}\to\mathbb{Z}/p^{n}\mathbb{Z}$ by

 $\pi_{n}(x)=\sum_{k=0}^{n-1}x(k)p^{k}+p^{n}\mathbb{Z}.$

It is apparent that $\pi_{n}$ is onto.

###### Lemma 7.

$\pi_{n}:\mathbb{Z}_{p}\to\mathbb{Z}/p^{n}\mathbb{Z}$ is a ring homomorphism, and

 $\ker\pi_{n}=\{x\in\mathbb{Z}_{p}:v_{p}(x)\geq n\}=p^{n}\mathbb{Z}_{p}.$
###### Proof.

Let $x,y\in\mathbb{Z}_{p}$. By (1),

 $\sum_{k=0}^{n-1}(x+y)(k)p^{k}+p^{n}\mathbb{Z}=\sum_{k=0}^{n-1}x(k)p^{k}+\sum_{% k=0}^{n-1}y(k)p^{k}+p^{n}\mathbb{Z},$

i.e.

 $\pi_{n}(x+y)=\pi_{n}(x)+\pi_{n}(y).$

By (2),

 $\sum_{k=0}^{n-1}(xy)(k)p^{k}+p^{n}\mathbb{Z}=\left(\sum_{k=0}^{n-1}x(k)p^{k}+p% ^{n}\mathbb{Z}\right)\left(\sum_{k=0}^{n-1}y(k)p^{k}+p^{n}\mathbb{Z}\right),$

i.e.

 $\pi_{n}(xy)=\pi_{n}(x)\pi_{n}(y).$

For $1\in\mathbb{Z}_{p}$, $1(0)=1$, $1(k)=0$ for $k\geq 1$, so

 $\pi_{n}(1)=1+p^{n}\mathbb{Z},$

which is the unity of $\mathbb{Z}/p^{n}\mathbb{Z}$. Therefore $\pi_{n}$ is a ring homomorphism.

$\pi_{n}(x)=0$ means

 $\sum_{k=0}^{n-1}x(k)p^{k}\in p^{n}\mathbb{Z}.$

But $0\leq\sum_{k=0}^{n-1}x(k)p^{k}<\sum_{k=0}^{n-1}(p-1)p^{k}=p^{n}-1$, so $\pi_{n}(x)=0$ if and only if $x(k)=0$ for $0\leq k\leq n-1$. ∎

Then for $n\geq 1$,

 $\displaystyle\mathbb{Z}_{p}$ $\displaystyle=\bigcup_{j=0}^{p^{n}-1}(j+p^{n}\mathbb{Z}_{p})$ $\displaystyle=\bigcup_{j=0}^{p^{n}-1}\{x\in\mathbb{Z}_{p}:v_{p}(x-j)\geq n\}$ $\displaystyle=\bigcup_{j=0}^{p^{n}-1}\{x\in\mathbb{Z}_{p}:|x-j|_{p}\leq p^{-n}\}$ $\displaystyle=\bigcup_{j=0}^{p^{n}-1}\{x\in\mathbb{Z}_{p}:|x-j|_{p}

Because $\mathbb{Z}/p\mathbb{Z}$ is a field and $\pi_{1}:\mathbb{Z}_{p}\to\mathbb{Z}/p\mathbb{Z}$ is an onto ring homomorphism,

 $\ker\pi_{1}=p\mathbb{Z}_{p}$

is a maximal ideal in $\mathbb{Z}_{p}$.

###### Theorem 8.

If $I$ is an ideal in $\mathbb{Z}_{p}$ and $I\neq\{0\}$, then there is some $n\geq 0$ such that $I=p^{n}\mathbb{Z}_{p}$.

###### Proof.

There is some $a\in I$ with minimal $v_{p}(a)\geq 0$, and as $I\neq\{0\}$, $v_{p}(a)\neq\infty$. Then $(p^{-v_{p}(a)}a)(0)=a(v_{p}(a))\neq 0$, so by Lemma 4, $p^{-v_{p}(a)}a\in\mathbb{Z}_{p}^{*}$. Hence there is some $u\in\mathbb{Z}_{p}^{*}$ such that $p^{-v_{p}(a)}a=u$, i.e. $p^{v_{p}(a)}=u^{-1}a$. But $I$ is an ideal and $a\in I$, so $p^{v_{p}(a)}\in I$, which shows that $p^{v_{p}(a)}\mathbb{Z}_{p}\subset I$. Let $x\in I$, $x\neq 0$. Then there is some $v\in\mathbb{Z}_{p}^{*}$ such that $p^{-v_{p}(x)}x=v$, i.e. $x=p^{v_{p}(x)}v$. Because $v_{p}(a)$ is minimal, $v_{p}(x)\geq v_{p}(a)$ and so

 $x=p^{v_{p}(x)}v=p^{v_{p}(a)}\cdot p^{v_{p}(x)-v_{p}(a)}\in p^{v_{p}(a)}\mathbb% {Z}_{p}.$

Therefore $I=p^{v_{p}(a)}\mathbb{Z}_{p}$. ∎

## 2 Qp

Let $\mathbb{Q}_{p}$ be the set of maps $x:\mathbb{Z}\to N_{p}$ such that for some $m\in\mathbb{Z}$, $x(k)=0$ for all $k. For $x\in\mathbb{Q}_{p}$ define

 $v_{p}(x)=\inf\{k\in\mathbb{Z}:x(k)\neq 0\}.$

$x(k)=0$ for $k, $k\in\mathbb{Z}$. $v_{p}(x)=\infty$ if and only if $x=0$.

 $\mathbb{Z}_{p}=\{x\in\mathbb{Q}_{p}:v_{p}(x)\geq 0\}.$

For $m\in\mathbb{Z}$ and $x\in\mathbb{Q}_{p}$, define

 $(T_{m}x)(k)=x(k+m),\qquad k\in\mathbb{Z}.$

For $x\in\mathbb{Q}_{p}$ with $x(k)=0$ for $k, if $k<0$ then $k+m and so

 $(T_{m}x)(k)=x(k+m)=0,$

which means that $T_{m}x\in\mathbb{Z}_{p}$. For $x,y\in\mathbb{Q}_{p}$ with $x(k)=0$ and $y(k)=0$ for $k, $T_{m}x,T_{m}y\in\mathbb{Z}_{p}$ and $T_{m}x+T_{m}y\in\mathbb{Z}_{p}$. Define

 $x+y=T_{-m}(T_{m}x+T_{m}y)\in\mathbb{Q}_{p}.$

Check that this makes sense. Likewise, $T_{m}x\cdot T_{m}y\in\mathbb{Z}_{p}$, and define

 $xy=T_{-m}(T_{m}x\cdot T_{m}y)\in\mathbb{Q}_{p}.$

Check that this makes sense. Check that $\mathbb{Q}_{p}$ is a commutative ring with additive identity $k\mapsto 0$ for $k\in\mathbb{Z}$. and unity $0\mapsto 1$, $k\mapsto 0$ for $k\neq 0$. Finally,11 1 For a ring $R$ with $x\in R$, $px=\sum_{k=1}^{p}x$. It does not make sense to talk about $px$ before we have $x+y$, and it is nonsense to talk about $p^{-m}x$ for $x\in\mathbb{Q}_{p}$ before have defined addition on $\mathbb{Q}_{p}$. This is why I defined $T_{m}$ rather than initially using $x\mapsto p^{-m}x$; it is incorrect and a sloppy habit to use properties of an object before showing that it exists.

 $T_{m}x=p^{-m}x.$
###### Theorem 9.

$\mathbb{Q}_{p}$ is a field, of characteristic $0$.

## 3 Metric

For $x\in\mathbb{Q}_{p}$ define

 $|x|_{p}=p^{-v_{p}(x)}.$

$|x|_{p}=0$ if and only if $x=0$. For $x,y\in\mathbb{Q}_{p}$ define

 $d_{p}(x,y)=|x-y|_{p}.$

$d_{p}$ is an ultrametric:

 $d_{p}(x,z)\leq\max(d_{p}(x,y),d_{p}(y,z)).$
###### Theorem 10.

$\mathbb{Q}_{p}$ is a topological field.

###### Proof.

For $(x,y),(u,v)\in\mathbb{Q}_{p}\times\mathbb{Q}_{p}$ let

 $\rho((x,y),(u,v))=\max(d_{p}(x,u),d_{p}(y,v)).$
 $d_{p}(x+y,u+v)=|(x-u)+(y-v)|_{p}=\max(|x-u|_{p},|y-v|_{p})=\rho((x,y),(u,v)),$

which shows that $(x,y)\mapsto x+y$ is continuous $\mathbb{Q}_{p}\times\mathbb{Q}_{p}\to\mathbb{Q}_{p}$. And

 $d_{p}(-x,-y)=|-x-y|_{p}=|-1|_{p}|x+y|_{p}=|x+y|_{p}=d_{p}(x,y),$

which shows that $x\mapsto-x$ is continuous $\mathbb{Q}_{p}\to\mathbb{Q}_{p}$. For $\rho((x,y),(u,v))\leq\delta$, $|x-u|_{p}\leq\delta$ so $|u|_{p}\leq|x|_{p}+\delta$ and

 $\displaystyle d_{p}(xy,uv)$ $\displaystyle=|xy-uv|_{p}$ $\displaystyle=|xy-uy+uy-uv|_{p}$ $\displaystyle=\max(|xy-uy|_{p},|uy-uv|_{p})$ $\displaystyle=\max(|y|_{p}|x-u|_{p},|u|_{p}|y-v|_{p})$ $\displaystyle\leq\max(|y|_{p}\delta,(|x|_{p}+\delta)\delta),$

which shows that $(x,y)\mapsto xy$ is continuous $\mathbb{Q}_{p}\times\mathbb{Q}_{p}\to\mathbb{Q}_{p}$. Finally, for $x,y\neq 0$,

 $d_{p}(x^{-1},y^{-1})=|x^{-1}-y^{-1}|_{p}=|xy|_{p}^{-1}|y-x|_{p},$

which shows that $x\mapsto x^{-1}$ is continuous $\mathbb{Q}_{p}\setminus\{0\}\to\mathbb{Q}_{p}\setminus\{0\}$. ∎

For $x\in\mathbb{Q}_{p}$ and $r>0$, write

 $B_{

Thus, for $x\in\mathbb{Q}_{p}$ and $n\geq 0$,

 $x+p^{n}\mathbb{Z}=B_{\leq p^{-n}}(x).$
###### Lemma 11.

For $x\in\mathbb{Q}_{p}$,

 $\{x+p^{n}\mathbb{Z}_{p}:n\geq 0\}$

is a local base at $x$.

###### Proof.

For $\epsilon>0$, let $p^{-n}<\epsilon$, $n\geq 0$, namely $n>\frac{1}{\log p}\log\frac{1}{\epsilon}$. For this $n$,

 $x+p^{n}\mathbb{Z}_{p}=B_{\leq p^{-n}}(x)\subset B_{<\epsilon}(x).$

###### Theorem 12.

$\mathbb{Z}_{p}$ is a compact subspace of $\mathbb{Q}_{p}$.

###### Proof.

Let $x_{n}\in\mathbb{Z}_{p}$ be a sequence. Because $x_{n}(0)\in N_{p}$, $n\geq 0$, there is some $a(0)\in N_{p}$ and an infinite subset $I_{0}$ of $\{n\geq 0\}$ such that $x_{n}(0)=a(0)$ for $n\in I_{0}$. Suppose by induction that for some $N\geq 0$ there are $a(0),\ldots,a(N)\in N_{p}$ and an infinite set $I_{N}\subset\{n\geq 0\}$ such that

 $x_{n}(k)=a(k),\qquad 0\leq k\leq N,\quad n\in I_{N}.$

But for each $x\in I_{N}$, $x_{n}(N+1)$ belongs to the finite set $N_{p}$, and because $I_{N}$ is infinite there is some $a(N+1)\in N_{p}$ and an infinite set $I_{N+1}\subset I_{N}$ such that $x_{n}(N+1)=a(N+1)$ for $n\in I_{N+1}$. We have thus defined $a\in\mathbb{Z}_{p}$.

Let $\alpha_{0}\in I_{0}$, and by induction let $\alpha_{n}>\alpha_{n-1}$, $\alpha_{n}\in I_{n}$; in particular as $\alpha_{0}\geq 0$ we have $\alpha_{n}\geq n$. Then for any $n\geq 0$, $x_{\alpha_{n}}(k)=a(k)$ for $0\leq k\leq n$. Take $\epsilon>0$ and let $p^{-m-1}<\epsilon$. For $n\geq m$,

 $|x_{\alpha_{n}}-a|_{p}\leq p^{-n-1}\leq p^{-m-1}<\epsilon,$

which shows that the sequence $x_{\alpha_{n}}$ tends to $a$. This means that $\mathbb{Z}_{p}$ is sequentially compact and therefore compact. ∎

For $x,y\in\mathbb{Q}_{p}$,

 $d_{p}(px,py)=|px-py|_{p}=|p|_{p}|x-y|_{p}=p^{-1}|x-y|_{p},$

which shows that $x\mapsto px$ is continuous $\mathbb{Q}_{p}\to\mathbb{Q}_{p}$. Therefore, the fact that $\mathbb{Z}_{p}$ is compact implies that for $n\geq 0$, $p^{n}\mathbb{Z}_{p}$ is compact. Then by Lemma 11 we get the following.

###### Theorem 13.

$\mathbb{Q}_{p}$ is locally compact.

###### Theorem 14.

$\mathbb{Q}_{p}$ is a complete metric space.

A topological space $X$ is zero-dimensional if there is a base for its topology each element of which is clopen. In a Hausdorff space, a compact set is closed, and because the sets $p^{n}\mathbb{Z}_{p}$ are compact, $n\geq 0$, from Lemma 11 we get the following.

###### Lemma 15.

$\mathbb{Q}_{p}$ is zero-dimensional.

It is a fact that if a Hausdorff space is zero-dimensional then it is totally disconnected, so by the above, $\mathbb{Q}_{p}$ is totally disconnected.

## 4 p-adic fractional part

For $x\in\mathbb{Q}_{p}$, let

 $[x]_{p}=\sum_{k\geq 0}x(k)p^{k}\in\mathbb{Z}_{p}$

and

 $\{x\}_{p}=\sum_{k<0}x(k)p^{k}\in\mathbb{Z}[1/p]\subset\mathbb{Q}.$

We call $\{x\}_{p}$ the $p$-adic fractional part of $x$. Then

 $x=[x]_{p}+\{x\}_{p}\in\mathbb{Q}_{p}.$

Furthermore, as $x(k)\to 0$ as $k\to-\infty$,

 $0\leq\{x\}_{p}<\sum_{k<0}(p-1)p^{k}=(p-1)\sum_{k=1}^{\infty}p^{-k}=1,$

therefore for $x\in\mathbb{Q}_{p}$,

 $\{x\}_{p}\in[0,1)\cap\mathbb{Z}[1/p].$

Define the Prüfer $p$-group

 $\mathbb{Z}(p^{\infty})=\{e^{2\pi imp^{-n}}:m,n\geq 0\}.$

We assign the Prüfer $p$-group the discrete topology.

Define $\psi_{p}:\mathbb{Q}_{p}\to S^{1}$ by

 $\psi_{p}(x)=e^{2\pi i\{x\}_{p}}.$

We prove that this is a homomorphism from the locally compact group $\mathbb{Q}_{p}$ whose image is the Prüfer $p$-group and whose kernel is $\mathbb{Z}_{p}$.22 2 Alain M. Robert, A Course in $p$-adic Analysis, p. 42, Proposition 5.4.

###### Theorem 16.

$\psi_{p}:\mathbb{Q}_{p}\to S^{1}$ is a homomorphism of locally compact groups. $\psi_{p}(\mathbb{Q}_{p})=\mathbb{Z}(p^{\infty})$, and $\ker\psi_{p}=\mathbb{Z}_{p}$.

###### Proof.

For $x,y\in\mathbb{Q}_{p}$,

 $\displaystyle\{x+y\}_{p}-\{x\}_{p}-\{y\}_{p}$ $\displaystyle=x+y-[x+y]_{p}-x+[x]_{p}-y+[y]_{p}$ $\displaystyle=[x]_{p}+[y]_{p}-[x+y]_{p}\in\mathbb{Z}_{p}.$

Check that $\mathbb{Z}[1/p]\cap\mathbb{Z}_{p}=\mathbb{Z}$. It then follows that

 $\{x+y\}_{p}-\{x\}_{p}-\{y\}_{p}\in\mathbb{Z},$

therefore $e^{2\pi i(\{x+y\}_{p}-\{x\}_{p}-\{y\}_{p})}=1$, i.e.

 $\psi_{p}(x+y)=e^{2\pi i\{x+y\}_{p}}=e^{2\pi i\{x\}_{p}}e^{2\pi i\{y\}_{p}}=% \psi_{p}(x)\psi_{p}(y),\qquad x,y\in\mathbb{Q}_{p},$

namely $\psi_{p}$ is a homomorphism.

$\psi_{p}(x)=1$ if and only if $e^{2\pi i\{x\}_{p}}=1$ if and only if $\{x\}_{p}\in\mathbb{Z}$. But $\{x\}_{p}\in[0,1)$, so $\psi_{p}(x)=1$ if and only if $\{x\}_{p}=0$, hence $\psi_{p}(x)=1$ if and only if $x\in\mathbb{Z}_{p}$, namely

 $\ker\psi_{p}=\mathbb{Z}_{p}.$

Let $x\in\mathbb{Q}_{p}$. As $\{x\}_{p}\in\mathbb{Z}[1/p]$, there is some $n\geq 0$ such that $p^{n}\{x\}_{p}\in\mathbb{Z}$, so $\psi_{p}(x)^{p^{n}}=1$, which means that $\psi_{p}(x)\in\mathbb{Z}[p^{\infty}]$. Let $e^{2\pi imp^{-n}}\in\mathbb{Z}[p^{\infty}]$, $n,m\geq 0$. But $p^{-n}\in\mathbb{Q}_{p}$ and, whether or not $n>0$,

 $\psi_{p}(p^{-n})=e^{2\pi i\{p^{-n}\}_{p}}=e^{2\pi ip^{-n}},$

and $mp^{-n}\in\mathbb{Q}_{p}$, and using that $\psi_{p}$ is a homomorphism,

 $\psi_{p}(mp^{-n})=\psi_{p}(p^{-n})^{m}=e^{2\pi imp^{-n}}.$

This shows that $\psi_{p}(\mathbb{Q}_{p})=\mathbb{Z}[p^{\infty}]$.

Finally, let $x\in\mathbb{Q}_{p}$. For $y\in B_{\leq 1}(x)=x+\mathbb{Z}_{p}$, so there is some $w\in\mathbb{Z}_{p}$ such that $y=x+w$. But $\psi_{p}(x+w)=\psi_{p}(x)\psi_{p}(w)=\psi_{p}(x)$, so

 $|\psi_{p}(y)-\psi_{p}(x)|=|\psi_{p}(x)-\psi_{p}(x)|=0,$

showing that $\psi_{p}$ is continuous at $x$. ∎

Because $\mathbb{Z}[p^{\infty}]$ is discrete, it is immediate that $\psi_{p}$ is an open map. The first isomorphism theorem for topological groups states that if $G$ and $H$ are locally compact groups, $f:G\to H$ is a homomorphism of topological groups that is onto and open, then $G/\ker f$ and $H$ are isomorphic as topological groups. Therefore the quotient group $\mathbb{Q}_{p}/\mathbb{Z}_{p}$ and the Prüfer group $\mathbb{Z}[p^{\infty}]$ are isomorphic as topological groups.