# Discrete valuation ring

In abstract algebra, a discrete valuation ring (DVR) is a principal ideal domain (PID) with exactly one non-zero maximal ideal.
This means a DVR is an integral domain R that satisfies any and all of the following equivalent conditions:
* R is a local ring, a principal ideal domain, and not a field.
* R is a valuation ring with a value group isomorphic to the integers under addition.
* R is a local ring, a Dedekind domain, and not a field.
* R is Noetherian and a local domain whose unique maximal ideal is principal, and not a field.
* R is integrally closed, Noetherian, and a local ring with Krull dimension one.
* R is a principal ideal domain with a unique non-zero prime ideal.
* R is a principal ideal domain with a unique irreducible element (up to multiplication by units).
* R is a unique factorization domain with a unique irreducible element (up to multiplication by units).
* R is Noetherian, not a field, and every nonzero fractional ideal of R is irreducible in the sense that it cannot be written as a finite intersection of fractional ideals properly containing it.
* There is some discrete valuation ν on the field of fractions K of R such that R = {0} $\cup$ {x $\in$ K : ν(x) ≥ 0}.

## Examples
### Algebraic
#### Localization of Dedekind rings

Let $\mathbb {Z} _{(2)}:=\{z/n\mid z,n\in \mathbb {Z} ,\,\,n{\text{ is odd}}\}$. Then, the field of fractions of $\mathbb {Z} _{(2)}$ is $\mathbb {Q}$. For any nonzero element $r$ of $\mathbb {Q}$, we can apply unique factorization to the numerator and denominator of r to write r as ⁠2$^k$ z/n⁠ where z, n, and k are integers with z and n odd. In this case, we define ν(r)=k. Then $\mathbb {Z} _{(2)}$ is the discrete valuation ring corresponding to ν. The maximal ideal of $\mathbb {Z} _{(2)}$ is the principal ideal generated by 2, i.e. $2\mathbb {Z} _{(2)}$, and the "unique" irreducible element (up to units) is 2 (this is also known as a uniformizing parameter). Note that $\mathbb {Z} _{(2)}$ is the localization of the Dedekind domain $\mathbb {Z}$ at the prime ideal generated by 2.
More generally, any localization of a Dedekind domain at a non-zero prime ideal is a discrete valuation ring; in practice, this is frequently how discrete valuation rings arise. In particular, we can define rings
    $\mathbb {Z} _{(p)}:=\left.\left\{{\frac {z}{n}}\,\right|z,n\in \mathbb {Z} ,p\nmid n\right\}$
for any prime p in complete analogy.

#### p-adic integers

The ring $\mathbb {Z} _{p}$ of p-adic integers is a DVR, for any prime $p$. Here $p$ is an irreducible element; the valuation assigns to each $p$-adic integer $x$ the largest integer $k$ such that $p^{k}$ divides $x$.

#### Formal power series

Another important example of a DVR is the ring of formal power series $R=k[[T]]$ in one variable $T$ over some field $k$. The "unique" irreducible element is $T$, the maximal ideal of $R$ is the principal ideal generated by $T$, and the valuation $\nu$ assigns to each power series the index (i.e. degree) of the first non-zero coefficient.
If we restrict ourselves to real or complex coefficients, we can consider the ring of power series in one variable that converge in a neighborhood of 0 (with the neighborhood depending on the power series). This is a discrete valuation ring. This is useful for building intuition with the Valuative criterion of properness.

#### Ring in function field

For an example more geometrical in nature, take the ring R = {f/g : f, g polynomials in R[X] and g(0) ≠ 0}, considered as a subring of the field of rational functions R(X) in the variable X. R can be identified with the ring of all real-valued rational functions defined (i.e. finite) in a neighborhood of 0 on the real axis (with the neighborhood depending on the function). It is a discrete valuation ring; the "unique" irreducible element is X and the valuation assigns to each function f the order (possibly 0) of the zero of f at 0. This example provides the template for studying general algebraic curves near non-singular points, the algebraic curve in this case being the real line.

### Scheme-theoretic
#### Henselian trait

For a DVR $R$ it is common to write the fraction field as $K={\text{Frac}}(R)$ and $\kappa =R/{\mathfrak {m}}$ the residue field. These correspond to the generic and closed points of $S={\text{Spec}}(R).$ For example, the closed point of ${\text{Spec}}(\mathbb {Z} _{p})$ is $\mathbb {F} _{p}$ and the generic point is $\mathbb {Q} _{p}$. Sometimes this is denoted as
    $\eta \to S\leftarrow s$
where $\eta$ is the generic point and $s$ is the closed point .

#### Localization of a point on a curve

Given an algebraic curve $(X,{\mathcal {O}}_{X})$, the local ring ${\mathcal {O}}_{X,{\mathfrak {p}}}$ at a smooth point ${\mathfrak {p}}$ is a discrete valuation ring, because it is a principal valuation ring. Note because the point ${\mathfrak {p}}$ is smooth, the completion of the local ring is isomorphic to the completion of the localization of $\mathbb {A} ^{1}$ at some point ${\mathfrak {q}}$.

## Uniformizing parameter

Given a DVR R, any irreducible element of R is a generator for the unique maximal ideal of R and vice versa. Such an element is also called a uniformizing parameter of R (or a uniformizing element, a uniformizer, or a prime element).
If we fix a uniformizing parameter t, then M=(t) is the unique maximal ideal of R, and every other non-zero ideal is a power of M, i.e. has the form (t$^k$) for some k≥0. All the powers of t are distinct, and so are the powers of M. Every non-zero element x of R can be written in the form αt$^k$ with α a unit in R and k≥0, both uniquely determined by x. The valuation is given by ν(x) = kv(t). So to understand the ring completely, one needs to know the group of units of R and how the units interact additively with the powers of t.
The function v also makes any discrete valuation ring into a Euclidean domain.

## Topology

Every discrete valuation ring, being a local ring, carries a natural topology and is a topological ring. It also admits a metric space structure where the distance between two elements x and y can be measured as follows:
    $|x-y|=2^{-\nu (x-y)}$
(or with any other fixed real number > 1 in place of 2). Intuitively: an element z is "small" and "close to 0" iff its valuation ν(z) is large. The function |x-y|, supplemented by |0|=0, is the restriction of an absolute value defined on the field of fractions of the discrete valuation ring.
A DVR is compact if and only if it is complete and its residue field R/M is a finite field.
Examples of complete DVRs include
* the ring of p-adic integers and
* the ring of formal power series over any field
For a given DVR, one often passes to its completion, a complete DVR containing the given ring that is often easier to study. This completion procedure can be thought of in a geometrical way as passing from rational functions to power series, or from rational numbers to the reals.
The ring of all formal power series in one variable with real coefficients is the completion of the ring of rational functions defined (i.e. finite) in a neighborhood of 0 on the real line; it is also the completion of the ring of all real power series that converge near 0. The completion of $\mathbb {Z} _{(p)}=\mathbb {Q} \cap \mathbb {Z} _{p}$ (which can be seen as the set of all rational numbers that are p-adic integers) is the ring of all p-adic integers Z$_p$.