There are, in general, two ways of obtaining the $p$-adic integers: either analytically or algebraically. Both ways can be generalized under reasonable assumptions. On the one hand, for a ring $R$ and an ideal $I\leqslant R$ we can consider the projective limit $\varprojlim R/I^n$. If, moreover, we have $\bigcap_n I^n=\langle0\rangle$ we may consider the completion $\hat R_I$ using the metric
$$ |x-y|_I=e^{-\nu_I(x-y)},\quad \nu_I\colon R\setminus\{0\}\to\mathbb N_0,\,x\mapsto\max\{n\,|\,x\in I^n\},\,\nu_I(0)=\infty $$
for some real number $e>1$. In case of the $p$-adic integers I have found a reference (p. $11$, proposition $1.13$) verifying that the two constructions coincide (up to isomorphism, of course). I attempt to generalize the proof.
Let $I\leqslant R$ as above. Then $\hat R_I\cong\varprojlim R/I^n$.
Proof. The proof will consist of the following two steps:
- Find well-defined maps $\varphi_n\colon\hat R_I\to R/I^n$ compatible with the projective system.
- Check injectivity and surjectivity of the induced map $\varphi\colon\hat R_I\to\varprojlim R/I^n$
So, consider a $R$-valued Cauchy sequence $(a_k)_k$ with respect to $|\cdot|_I$. For $n\in\mathbb N$ we have $|a_k-a_{k'}|_I\le e^{-n}$ for $k,k'$ large enough. By defintion this is the case if $a_k\equiv a_{k'}\mod I^n$, i.e. the $I^n$-residue of $(a_k)_k$ eventually stabilizes. Hence, we may define $\varphi_n\colon\hat R_I\to R/I^n$ by mapping a Cauchy sequence to this eventually stable $I^n$-residue. This yields a well-defined ring homomorphism since if $(a_k)_k\sim(b_k)_k$ we have that $|a_k-b_k|_I\to0$ and, in particular, $a_k\equiv b_k\mod (I^n)$ for $k$ large enough. Since the ring operations on $\hat R_I$ are defined componentwise this definition yields ring homomorphisms.
Regarding compatability. Recall that the given projective system has as transition maps the natural projections $\pi_{nm}\colon R/I^m\to R/I^n$ for $m\ge n$. We have to show that these projections are compatible with the stable-residue-maps. Note that for $m\ge n$ (and $k,k'$ large enough) we have
$$ |a_k-a_{k'}|_I\le 2^{-m}\le 2^{-n} $$
and hence if the $I^m$-residue of $(a_k)_k$ is stable, so is the $I^n$-residue. Hence, simply projecting from $R/I^m$ to $R/I^n$ is compatible with mapping to stable residues.
Hence, we obtain a (unique) ring homomorphism $\varphi\colon\hat R_I\to\varprojlim R/I^n$ which we will show is the desired isomorphism.
First, injectivity. Suppose that $(a_k)_k$ (representing an equivalence class of Cauchy sequences) maps to $0$ under $\varphi$. Then, by compatibility, we have that the $I^n$-residues of $(a_k)_k$ are all eventually $0$, that is, $(a_k)_k$ lies in all $I^n$ eventually. As $\bigcap_n I^n=\langle0\rangle$ this is only possible if $(a_k)_k$ represents the $0$-sequences. Second, surjectivity. Let $(a_k+I^n)_k$ be an element of the projective limit. Then, choosing representatives, $(a_k)_k$ is a Cauchy sequence (since $a_m\equiv a_n\mod I^n$ for all $m\ge n$) which is mapped back to $(a_k+I^n)_k$ under $\varphi$. This concludes the proof. $\square$
Is the given proof correct? if not, where did it went wrong? I am a bit unsure about the compatibility argument.
Thanks in advance!