Minimal polynomial over GF(p) of a field element
m = gf_minimal_polynomial(F, e) m = gf_minimal_polynomial(p, n, e)
A field created by gf_create_field.
Prime number: the characteristic of the field, at most 2^20.
Degree of the field: an integer from 1 to 20, with p^n ≤ 2^20. With this syntax, the field uses the primitive polynomial returned by gf_default_primitive_polynomial.
The element, as an integer.
For n = 1: the element itself, in 0 .. p-1.
For n > 1: the exponent k of α^k, in -1 .. p^n - 2. Use -1 for the zero element. gf_to_exponential converts an element given by its coefficients to this form.
The minimal polynomial: a row of n + 1 coefficients, constant term first. Its degree d divides n; when d < n, the row is padded with zeros on the right.
The minimal polynomial of an element β of GF(p^n) is the monic polynomial of lowest degree with coefficients in GF(p) that has β as a root. It is the product of (x - γ) over the distinct conjugates γ = β, β^p, β^(p²), ... of β.
Some particular cases:
the minimal polynomial of 0 is x, and that of 1 is x - 1;
the minimal polynomial of a primitive element is a primitive polynomial; for α it is the field's own primitive polynomial;
in GF(p) (n = 1), the minimal polynomial of e is x - e.
| Version | Description |
| 2.0.0 | Refactoring of the function/toolbox. |