In mathematics and computer algebra the factorization of a polynomial consists in decomposing it in a product of irreducible factors. This decomposition is theoretically possible and is unique for polynomials with coefficients in any field,
but rather strong restrictions on the field of the coefficients are
needed to allow to compute this factorization by mean of an algorithm. In practice, algorithms have been designed only for polynomials with coefficients in a finite field, in the field of rationals or in a finitely generated field extension of one of them.

The case of the

Since the second half of twentieth century, major improvements have been made to this problem that results in the fact that factoring a polynomial of degree 1000 over a medium sized prime field (less than one million of elements) is now a routine task.

As the reduction of the factorization of multivariate polynomials to that of univariate polynomials does not have any specificity in the case of coefficients in a finite field, only polynomials with one variable are considered in this article.

A finite field or Galois field is a field with a finite order (number of elements). The order of a finite field is always a prime or a power of prime. For each prime power

Irreducible polynomials allow to construct the finite fields of non prime order. In fact, for a prime power

It follows that, to compute in a finite field of non prime order, one needs to generate an irreducible polynomial. For this, the common method is to take a polynomial at random and test it for irreducibility. For sake of efficiency of the multiplication in the field, it is usual to search for polynomials of the shape

Irreducible polynomials over finite fields are also useful for Pseudorandom number generators using feedback shift registers and discrete logarithm over

In the algorithms that follow, the complexities are expressed in terms of number of arithmetic operations in

The case of the

**factorization of univariate polynomials over a finite field**, which is the object of this article, is especially important, because all the algorithms (including the case of multivariate polynomials over the rational numbers), which are sufficiently efficient to be implemented, reduce the problem to this case (see Polynomial factorization). It is also interesting for various applications of finite fields such as coding theory (cyclic redundancy codes and BCH codes), cryptography (public key cryptography by mean of elliptic curves), and computational number theory.Since the second half of twentieth century, major improvements have been made to this problem that results in the fact that factoring a polynomial of degree 1000 over a medium sized prime field (less than one million of elements) is now a routine task.

As the reduction of the factorization of multivariate polynomials to that of univariate polynomials does not have any specificity in the case of coefficients in a finite field, only polynomials with one variable are considered in this article.

### Finite field

The theory of finite fields, whose origins can be traced back to the works of Gauss and Galois, has played a part in various branches of mathematics. Due to the applicability of the concept in other topics of mathematics and sciences like computer science there has been a resurgence of interest in finite fields and this is partly due to important applications in coding theory and cryptography. Applications of finite fields introduce some of these developments in cryptography, computer algebra and coding theory.A finite field or Galois field is a field with a finite order (number of elements). The order of a finite field is always a prime or a power of prime. For each prime power

*q*=*p*, there exists exactly one finite field with^{r}*q*elements, up to isomorphism. This field is denoted*GF*(*q*) or**F**_{q}. If*p*is prime,*GF*(*p*) is the prime field of order*p*; it is the field of residue classes modulo*p*, and its*p*elements are denoted 0, 1, ...,*p*−1. Thus*a*=*b*in*GF*(*p*) means the same as*a*≡*b*mod*p*.### Irreducible polynomials

Let*F*be a finite field. As for general fields, a non-constant polynomial*f*in*F*[*x*] is said to be irreducible over*F*if it is not the product of two polynomials of positive degree. A polynomial of positive degree that is not irreducible over*F*is called*reducible over**F*.Irreducible polynomials allow to construct the finite fields of non prime order. In fact, for a prime power

*q*, let**F**_{q}be the finite field with*q*elements, unique up to an isomorphism. A polynomial*f*of degree*n*greater than one, which is irreducible over**F**_{q}, defines a field extension of degree*n*which is isomorphic to the field with*q*^{n}elements: the elements of this extension are the polynomials of degree lower than*n*; addition, subtraction and multiplication by an element of**F**_{q}are those of the polynomials; the product of two elements it the remainder of the division by*f*of their product as polynomials; the inverse of an element may be computed by the extended GCD algorithm (see Arithmetic of algebraic extensions).It follows that, to compute in a finite field of non prime order, one needs to generate an irreducible polynomial. For this, the common method is to take a polynomial at random and test it for irreducibility. For sake of efficiency of the multiplication in the field, it is usual to search for polynomials of the shape

*x*^{n}+*ax*+*b*.Irreducible polynomials over finite fields are also useful for Pseudorandom number generators using feedback shift registers and discrete logarithm over

**F**_{2n}.#### Example

The polynomial*P*=*x*^{4}+ 1 is irreducible over**Q**but not over any finite field.- On any field extension of
**F**_{2},*P*= (*x*+1)^{4}.

- On every other finite field, at least one of −1, 2 and −2 is a square, because the product of two non squares is a square and so we have

- If then
- If then
- If then

### Complexity

Polynomial factoring algorithms use basic polynomial operations such as products, divisions, gcd, powers of one polynomial modulo another, etc. A multiplication of two polynomials of degree at most*n*can be done in*O*(*n*^{2}) operations in**F**_{q}using "classical" arithmetic, or in*O*(*n*log(*n*)) operations in**F**_{q}using "fast" arithmetic. A Euclidean division (division with remainder) can be performed within the same time bounds. The cost of a polynomial greatest common divisor between two polynomials of degree at most*n*can be taken as*O*(*n*^{2}) operations in**F**_{q}using classical methods, or as*O*(*n*log^{2}(*n*)) operations in**F**_{q}using fast methods. For polynomials*h*,*g*of degree at most*n*, the exponentiation*h*mod^{q}*g*can be done with*O*(log(*q*)) polynomial products, using exponentiation by squaring method, that is*O*(*n*^{2}log(*q*)) operations in**F**_{q}using classical methods, or*O*(*n*log(*q*)log(*n*)) operations in**F**_{q}using fast methods.In the algorithms that follow, the complexities are expressed in terms of number of arithmetic operations in

**F**_{q}, using classical algorithms for the arithmetic of polynomials.**To Join Ajit Mishra's Online Classroom***CLICK HERE*