---
title: "Differential Operator Rings"
canonical: "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/DifferentialRings/creation-diff-op-rings.html"
source: "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/DifferentialRings/creation-diff-op-rings.md"
part: "Commutative Algebra"
chapter: "Differential Rings"
breadcrumbs:
  - {"title": "Magma Handbook", "source": "https://docs.magma-maths.org/v2.30-1/index.md"}
  - {"title": "Commutative Algebra", "source": "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/index-commutative-algebra.md"}
  - {"title": "Differential Rings", "source": "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/DifferentialRings/index-differential-rings.md"}
prev: {"title": "Wronskian Matrix", "source": "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/DifferentialRings/wronskians.md"}
next: {"title": "Structure Operations on Differential Operator Rings", "source": "https://docs.magma-maths.org/v2.30-1/CommutativeAlgebra/DifferentialRings/structure-operations-diff-op-rings.md"}
intrinsics:
  - {"name": "DifferentialOperatorRing", "signature": "DifferentialOperatorRing(F): RngDiff -> RngDiffOp"}
  - {"name": "AssignNames", "signature": "AssignNames(~R, S): RngDiffOp, [MonStgElt]"}
  - {"name": "Name", "signature": "Name(R, i): RngDiffOp, RngIntElt -> RngDiffElt"}
  - {"name": ".", "signature": "R . i: RngDiffOp, RngIntElt -> RngDiffOpElt"}
  - {"name": "!", "signature": "R ! s: RngDiffOp, RngElt -> RngDiffOpElt"}
  - {"name": "Zero", "signature": "Zero(R): RngDiffOp -> RngDiffOpElt"}
  - {"name": "One", "signature": "One(R): RngDiffOp -> RngDiffOpElt"}
examples:
  - "ex-42ff41"
  - "ex-facb79"
---

# Differential Operator Rings

## Creation

<a id="function-differentialoperatorring-rngdiff"></a>
### `DifferentialOperatorRing(F): RngDiff -> RngDiffOp`

Returns the differential operator ring over the differential field $F$.

<a id="example-ex-42ff41"></a>
### `Example: Creating a Differential Operator Ring (ex-42ff41)`

```magma
> F<z> := RationalDifferentialField(Rationals());
> R := DifferentialOperatorRing(F);
> R;
Differential operator ring over Differential Ring of Algebraic function field
defined over Rational Field by
$.2 - 4711
with derivation given by (1) d(z)
```

<a id="procedure-assignnames-rngdiffop-monstgelt-ref"></a>
### `AssignNames(~R, S): RngDiffOp, [MonStgElt]`

Given a differential operator ring $R$ with $n$ indeterminates and a sequence $S$ of $n$ strings, assign the elements of $S$ to the names of the variables of $R$.

This procedure only changes the names used in the printing of the elements of $R$.

## Creation of Differential Operators

The easiest way to create an element in a given ring is to use the angle bracket construction to attach a name to the indeterminate of the differential operator ring. Other constructions are given below.

<a id="function-name-rngdiffop-rngintelt"></a>
### `Name(R, i): RngDiffOp, RngIntElt -> RngDiffElt`

<a id="operation-operation-rngdiffop-rngintelt-rngdiffopelt"></a>
### `R . i: RngDiffOp, RngIntElt -> RngDiffOpElt`

The $i$-th indeterminate of the differential ring $R$, where $i$ must be $1$.

<a id="operation-op-rngdiffop-rngelt"></a>
### `R ! s: RngDiffOp, RngElt -> RngDiffOpElt`

Coerce the element $s$ into the differential operator ring $R$. Elements that are coercible into $R$ are elements coercible into its underlying ring, sequences, and differential operators defined over the base ring of the coefficient ring of $R$.

When the base ring of $R$ is an algebraic differential field, elements of other differential operator rings over algebraic differential fields can be coerced into $R$ so long as the underlying rings of the differential fields are the same.

<a id="function-zero-rngdiffop"></a>
### `Zero(R): RngDiffOp -> RngDiffOpElt`

The zero element of the differential operator ring $R$.

<a id="function-one-rngdiffop"></a>
### `One(R): RngDiffOp -> RngDiffOpElt`

The identity element of the differential operator ring $R$.

<a id="example-ex-facb79"></a>
### `Example: Coercion into an Operator Ring (ex-facb79)`

```magma
> F<z> := RationalDifferentialField(Rationals());
> R<D> := DifferentialOperatorRing(F);
> R.1;
D
> R!(1/z);
1/z;
> R![1/2,0,5,z];
z*D^3 + 5*D^2 + 1/2
> S<T> := DifferentialOperatorRing(ChangeDerivation(F,z));
> R!T;
z*D
> S!D;
1/z*T
```
