galois.primitive_polys¶
- galois.primitive_polys(characteristic, degree)¶
Returns all degree-\(m\) primitive polynomials \(f(x)\) over \(\mathrm{GF}(p)\).
- Parameters
- Returns
All degree-\(m\) primitive polynomials over \(\mathrm{GF}(p)\).
- Return type
Examples
In [1]: galois.primitive_polys(2, 5) Out[1]: [Poly(x^5 + x^2 + 1, GF(2)), Poly(x^5 + x^3 + 1, GF(2)), Poly(x^5 + x^3 + x^2 + x + 1, GF(2)), Poly(x^5 + x^4 + x^2 + x + 1, GF(2)), Poly(x^5 + x^4 + x^3 + x + 1, GF(2)), Poly(x^5 + x^4 + x^3 + x^2 + 1, GF(2))]