Canonical: https://knowlpedia.com/algebra-fields-galois/ring-of-integers/

# Ring of integers of a number field

The subring consisting of all algebraic integers in a number field.

The **ring of integers** of a [number field](https://knowlpedia.com/algebra-fields-galois/number-field/) \(K\) is
\[
\mathcal O_K=\{\alpha\in K:\alpha\text{ is an algebraic integer}\}.
\]
Equivalently, it is the [integral closure](https://knowlpedia.com/algebra-commutative/integral-closure/) of \(\mathbb Z\) in \(K\). Addition and multiplication preserve [integrality](https://knowlpedia.com/algebra-fields-galois/algebraic-integer/), so this subset is a subring with identity.

## Size and coordinates

As an additive group it is free of rank \([K:\mathbb Q]\). A choice of its integer coordinates is an [integral basis](https://knowlpedia.com/algebra-fields-galois/integral-basis/). This does not assert that it has a basis of powers of one element.

## Examples

One has \(\mathcal O_{\mathbb Q}=\mathbb Z\) and \(\mathcal O_{\mathbb Q(i)}=\mathbb Z[i]\). For \(\mathbb Q(\sqrt{-3})\), the element \((1+\sqrt{-3})/2\) is also integral, so merely adjoining the square root misses part of the ring.

## References

1. J. S. Milne, *Algebraic Number Theory*, v3.08. [Author’s text](https://www.jmilne.org/math/CourseNotes/ANTc.pdf), §2, Proposition 2.29 and Corollary 2.30.
