---
title: "Other Ring Constructions"
canonical: "https://docs.magma-maths.org/v2.30-1/BasicRings/IntroductionToRings/creation-other.html"
source: "https://docs.magma-maths.org/v2.30-1/BasicRings/IntroductionToRings/creation-other.md"
part: "Basic Rings"
chapter: "Introduction to Rings"
breadcrumbs:
  - {"title": "Magma Handbook", "source": "https://docs.magma-maths.org/v2.30-1/index.md"}
  - {"title": "Basic Rings", "source": "https://docs.magma-maths.org/v2.30-1/BasicRings/index-basic-rings.md"}
  - {"title": "Introduction to Rings", "source": "https://docs.magma-maths.org/v2.30-1/BasicRings/IntroductionToRings/index-introduction-to-rings.md"}
prev: {"title": "Ideals and Quotient Rings", "source": "https://docs.magma-maths.org/v2.30-1/BasicRings/IntroductionToRings/ideal-quotient.md"}
next: {"title": "Ring of Integers", "source": "https://docs.magma-maths.org/v2.30-1/BasicRings/Integers/index-integers.md"}
intrinsics:
  - {"name": "ResidueClassField", "signature": "ResidueClassField(I): Rng -> Fld, Map"}
  - {"name": "loc", "signature": "loc< R | a₁, ..., aᵣ >: Rng, RngElt, ..., RngElt -> Rng, Map"}
  - {"name": "Localization", "signature": "Localization(R, P): Rng, Rng -> Rng, Map"}
  - {"name": "comp", "signature": "comp< R | a₁, ..., aᵣ >: Rng, RngElt, ..., RngElt -> Rng, Map"}
  - {"name": "Completion", "signature": "Completion(R, P): Rng, Rng -> Rng, Map"}
  - {"name": "ext", "signature": "ext< R | >: Rng -> RngUPol"}
  - {"name": "ext", "signature": "ext< R, n | >: Rng, RngIntElt -> RngMPol"}
---

# Other Ring Constructions

Magma allows the construction of residue fields, localization of rings, and completion of rings. These constructions really just create appropriate rings of different categories within Magma.

## Residue Class Fields

<a id="function-residueclassfield-rng"></a>
### `ResidueClassField(I): Rng -> Fld, Map`

Given a maximal ideal $I$ of a ring $R$, create the residue class field $K$ of the quotient ring $R/I$, together with a map sending an element of $R$ to the corresponding element of $K$.

## Localization

<a id="constructor-constructor-loc-rng-rngelt-rngelt-rng-map"></a>
### `loc< R | a₁, ..., aᵣ >: Rng, RngElt, ..., RngElt -> Rng, Map`

Given a ring $R$ and elements $a_1, \ldots, a_r$ of $R$, which generate a prime ideal $P$ of $R$, create the localization $L$ of $R$ at $P$, together with a map sending an element of $R$ to the corresponding element of $L$.

<a id="function-localization-rng-rng"></a>
### `Localization(R, P): Rng, Rng -> Rng, Map`

Given a ring $R$ and a prime ideal $P$ of $R$, create the localization $L$ of $R$ at $P$, together with a map sending an element of $R$ to the corresponding element of $L$.

## Completion

<a id="constructor-constructor-comp-rng-rngelt-rngelt-rng-map"></a>
### `comp< R | a₁, ..., aᵣ >: Rng, RngElt, ..., RngElt -> Rng, Map`

Given a ring $R$ and elements $a_1, \ldots, a_r$ of $R$, which generate a prime ideal or zero ideal $P$ of $R$, create the completion $C$ of $R$ at $P$, together with a map sending an element of $R$ to the corresponding element of $C$.

<a id="function-completion-rng-rng"></a>
### `Completion(R, P): Rng, Rng -> Rng, Map`

Given a ring $R$ and a prime ideal or zero ideal $P$ of $R$, create the completion $C$ of $R$ at $P$, together with a map sending an element of $R$ to the corresponding element of $C$.

## Transcendental Extension

<a id="constructor-constructor-ext-rng-rngupol"></a>
### `ext< R | >: Rng -> RngUPol`

Given a ring $R$ create the univariate transcendental extension $R[x]$ of $R$. This is equivalent to `PolynomialRing(R)`.

<a id="constructor-constructor-ext-rng-rngintelt-rngmpol"></a>
### `ext< R, n | >: Rng, RngIntElt -> RngMPol`

Given a ring $R$ and an integer $n \geq 1$, create the multivariate transcendental extension $R[x_1, \ldots, x_n]$ of $R$. This is equivalent to `PolynomialRing(R, n)`.
