Macaulay2 » Documentation
Packages » RationalPoints2 » extField
next | previous | forward | backward | up | index | toc

# extField -- Define field extensions

- Usage:
    `extField p / extField {p, p', ...}`
    `extField(F, p) / extField(F, {p, p', ...})`
    `splittingField p`
    `splittingField(F, p)`
- Inputs:
  - p, a univariate polynomial or a list of them
  - F, the base field; if not specified then it is taken to be the field of definition of p
- Optional inputs:
  - Variable => a symbol, default value "a", the variable to use for the primitive element of the extension field
- Outputs:
  - F', an extension field over the field of definition of p, or over the base field F

## Description

Methods for defining field extensions. The method extField accepts an irreducible polynomial p and adds one of its zeros into the base field. The base field can itself be a simple extension represented by a primitive element, in which case a new primitive element is computed. Use the option Variable to specify the symbol used for the primitive element (the default is a like GaloisField). N.B. Any data previously stored in this symbol will be lost! As is the case for GaloisField.

Here we first add i into the rational numbers. Similar to toField, the variable used in the polynomial will be set to its image in the extension, but note that this is not necessarily the primitive element.

    i1 : QQ[x]; F = extField(4*x^2+1, Variable=>i); x

         1
    o3 = -i
         2

    o3 : F

    i4 : baseRing F

          QQ[i]
    o4 = ------
          2
         i  + 1

    o4 : QuotientRing

    i5 : i^2 + 1 == 0

    o5 = true

Now we perform another field extension over F by adding the square root of 2. A new primitive element a will be computed.

    i6 : QQ[q]; F' = extField(F, q^2-2); q

         1 3   5
    o8 = -a  - -a
         6     6

    o8 : F'

    i9 : q^2 == 2

    o9 = true

    i10 : baseRing F'

              QQ[a]
    o10 = ------------
           4     2
          a  - 2a  + 9

    o10 : QuotientRing

For elements of the base field F, we can use baseChange to determine their images in the extension field F'.

    i11 : j = baseChange_F' i

          1 3   1
    o11 = -a  + -a
          6     6

    o11 : F'

    i12 : j^2 + 1 == 0

    o12 = true

It is also possible to do multiple extensions at the same time. Note that x is now set to i/2, so in order to use it as a variable we need to use symbol to reclaim it.

    i13 : QQ[symbol x]; F' = extField {4*x^2+1, x^2-2}; baseRing F'

              QQ[a]
    o15 = ------------
           4     2
          a  - 2a  + 9

    o15 : QuotientRing

When passing a list of polynomials, the variable x will not be set. This can also be used for one polynomial to avoid setting the value of x.

    i16 : extField {4*x^2+1}; x

    o17 = x

    o17 : QQ[x]

Repeatedly applying extField using the same polynomial will add all its zeros into the field. This can also be done using the method splittingField. For example we may construct the splitting field of x^3-2 as follows.

    i18 : QQ[x]; p = x^3-2; F = extField {p}; #zeros_F p

    o21 = 1

    i22 : F' = extField {p, p}; #zeros_F' p

    o23 = 3

    i24 : F' = splittingField p; #zeros_F' p

    o25 = 3

Over finite fields, the degree is first computed while the rest is handled by GaloisField.

    i26 : ZZ/11[x]; F = extField(x^4+1); describe F

    o28 = GF 121

    i29 : x

    o29 = 5a + 5

    o29 : F

    i30 : x^4 + 1 == 0

    o30 = true

## Caveat

If PARI/GP is available on the system, the program will try to use the function polredbest to reduce the minimal polynomial. This will give an equivalent but usually much optimal result. Note that for large inputs, one could increase the pari stack size by using setPariSize n.

## Ways to use extField:

- `extField(List)`
- `extField(Ring,List)`
- `extField(Ring,RingElement)`
- `extField(RingElement)`

## For the programmer

The object extField is a method function with options.

The source of this document is in /build/macaulay2-88fgJW/macaulay2-1.25.11+ds/M2/Macaulay2/packages/RationalPoints2.m2:1025:0.