---
title: "Solving Norm Equations"
canonical: "https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFields/norm-equation.html"
source: "https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFields/norm-equation.md"
part: "Global Fields"
chapter: "Number Fields"
breadcrumbs:
  - {"title": "Magma Handbook", "source": "https://docs.magma-maths.org/v2.30-1/index.md"}
  - {"title": "Global Fields", "source": "https://docs.magma-maths.org/v2.30-1/GlobalFields/index-global-fields.md"}
  - {"title": "Number Fields", "source": "https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFields/index-number-fields.md"}
prev: {"title": "Galois Theory", "source": "https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFields/galois-theory.md"}
next: {"title": "Places and Divisors", "source": "https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFields/divisors.md"}
examples:
  - "ex-2b3577"
---

<a id="norm-equation"></a>
<a id="fldnum-main-norm-equation"></a>
# Solving Norm Equations

Magma has routines for solving norm equations, Thue equations, index form equations, and unit equations. These are documented in Section [Diophantine Equations](https://docs.magma-maths.org/v2.30-1/GlobalFields/NumberFieldsAndOrders/equation.md#rngord-equations).

<a id="example-ex-2b3577"></a>
## `Example: Solving a Relative Norm Equation (ex-2b3577)`

We try to solve $N(x) = 3$ in some relative extension: (Note that since the larger field is a quadratic extension, the second call tells us that there is no integral element with norm $3$)

```magma
> x := PolynomialRing(Integers()).1;
> K := NumberField([x^2-229, x^2-2]);
> NormEquation(K, 3);
true [
  1/3*K.1 - 16/3
]
```

Next we solve the same equation but come from a different angle, we will define the norm map as an element of the group ring and, instead of explicitly computing a relative extension, work instead with the implicit fixed field.

```magma
> F := AbsoluteField(K);
> t := F!K.2;
> t^2;
2
> A, _, mA := AutomorphismGroup(F);
> S := sub<A | [ x : x in A | mA(x)(t) eq t]>;
> N := map<F -> F | x:-> &* [ mA(y)(x) : y in S]>;
> NormEquation(3, N);
true [
  -5/1*$.1 + 2/3*$.3
]
```

Finally, to show the effect of `Raw`:

```magma
> f, s, base := NormEquation(3, N:Raw);
> s;
[
  ( 0  1 -1  1 -1  0  2 -1 -1 -1 -1  2  0  0)
]
> z := PowerProduct(base, s[1]);
> z;
-5/1*$.1 + 2/3*$.3
> N(z);
3
```
