Jérémy Le Borgne

Semi-characteristic polynomials, ϕ-modules and skew polynomials

We introduce the notion of semi-characteristic polynomial for a semi-linear map of a finitedimensional vector space over a field of characteristic p. This polynomial has some properties in common with the classical characteristic polynomial of a linear map. We use this notion to study skew polynomials and linearized polynomials over a finite field, giving an algorithm to compute the splitting field of a linearized polynomial over a finite field and the Galois action on this field. We also give a way to compute the optimal bound of a skew polynomial. We then look at properties of the factorizations of skew polynomials, giving a map that computes several invariants of these factorizations. We also explain how to count the number of factorizations and how to find them all.

The aim of this paper is to relate the theory of ϕ-modules over a finite field, which is semi-linear algebra, with the theory of skew polynomials, and give some applications to understand better the factorization of skew polynomials over finite fields. Let K be a field of characteristic p > 0 endowed with a Frobenius morphism σ, and let D be a finite-dimensional vector space over K endowed with a map ϕ that is semi-linear with respect to σ: this structure is called a ϕ-module. If one wants to evaluate a polynomial with coefficients in K at such a semi-linear map, the ring of polynomials considered should have a natural structure of skew polynomial ring (or twisted-polynomial ring, as discussed by Kedlaya in [START_REF] Kedlaya | Slope Filtrations For Relative Frobenius[END_REF]), in order for the relation P Q(ϕ) = P (ϕ)Q(ϕ) to be valid. The theory of ϕ-modules has been widely investigated in p-adic Hodge theory, often as a tool in the theory of (ϕ, Γ)-modules that Fontaine introduced in [START_REF] Fontaine | Représentations p-adiques des corps locaux[END_REF] for the study of p-adic representations of local fields. On the other hand, the theory of skew polynomials was founded by Ore, who gave the fundamental theorems about such polynomials. In the context of finite fields, this theory has been recently used (for example by Boucher and Ulmer in [START_REF] Boucher | Coding with skew polynomial rings[END_REF]) to build error-correcting codes. One of Ore's main theorems concerns factorizations of skew polynomials, and it says that in two given factorizations of a polynomial, the irreducible factors that appear do not depend on the factorization up to similarity (similarity is an equivalence relation on skew polynomials, that generalize the notion of being equal up to multiplicative constant in the case of commutative polynomials, see section 1.1 for more detail). One very important result concerning skew polynomial rings over finite fields is a polynomial-time (in the degree of the polynomial) factorization algorithm due to Giesbrecht in [START_REF] Giesbrecht | Factoring in skew polynomial rings over finite fields[END_REF].

In order to relate these theories, we introduce in the first part of the article the notion of semicharacteristic polynomial for a semi-linear map over a vector space over a field K of characteristic p > 0. Indeed, to a skew polynomial is naturally associated a ϕ-module (whose matrix is the companion matrix of the polynomial). Conversely, to a ϕ-module over K we associate a skew polynomial with coefficients in K, the semi-characteristic polynomial. This polynomial should somehow behave like the characteristic polynomial of a linear map (in particular, its degree is the same as the dimension of the underlying vector space), except that it depends on the choice of some element in the ϕ-module D. For the purpose of this article, our definition of the semicharacteristic polynomial is mostly interesting in the case that the ϕ-module has a basis of the form (x, ϕ(x), . . . , ϕ d-1 (x)) for some x ∈ D. We give several properties of the semi-characteristic polynomial in this context, yielding the fact that the semi-characteristic polynomials given by two such x are equivalent under the similarity relation, which is a crucial equivalence relation in the theory of skew polynomials. This polynomial is denoted by χ ϕ,x . We give an interpretation of a study of Jacobson about skew-polynomials in our context (see [Jac], Chapter 1) to understand the factorizations of the semi-characteristic polynomial of a ϕ-module. Our Theorem 1.4.4 gives a natural bijection between the Jordan-Hölder sequences of a ϕ-module and the factorizations of its semi-characteristic polynomial, the irreducible factors being given by the semi-characteristic polynomials of the composition factors. Conversely, our Proposition 1.4.5 shows any factorization of the semi-characteristic polynomial χ ϕ,x yields a Jordan-Hölder sequence for the ϕ-module.

In the second part of the article, we use the preceding tools to study skew polynomials over finite fields. To a skew polynomial is naturally associated a so-called linearized polynomial, which is a polynomial of the form a i X q i , where the cardinal of the base field is a power of q. Linearized polynomials have long been related to skew polynomials (see for example [LN94]), and it is easy to see that the set of the roots of a linearized polynomial is a F q -vector space. On the other hand, to a ϕ-module is associated a linear representation of a Galois group by Fontaine's theory of ϕmodules in characteristic p, which is recalled briefly in section 2.1. It appears that the considered representation is naturally the vector space of the roots of the associated linearized polynomial. As an application, we explain how to find the splitting field of a linearized polynomial together with the action of the Galois group on its roots: Theorem 1 (Theorem 2.2.3). Let P ∈ F q r [X, σ] with nonzero constant coefficient, and let L P be the associate linearized polynomial. Let Γ be the companion matrix of P , and

Γ 0 = Γσ(Γ) • • • σ r-1 (Γ).
Then the characteristic polynomial Q of Γ 0 has coefficients in F q , and the splitting field of L P has dimension m over F q r , where m is the maximal order of a root of Q in F q . Moreover, the action of a generator g of the Galois group G F q r is given in some basis of the F q -vector space of the roots of L P by the Frobenius normal form of Γ 0 .

We give a fast algorithm to compute a multiple of a skew polynomial that lies in the center of the ring, which has been a natural question about skew polynomials. In particular, since Giesbrecht's algorithm for factoring uses the computation of such a multiple, we improve the complexity of this part of his algorithm. We also explain how to test the similarity of skew polynomials effectively. Then, we investigate further the relations between the factorizations of a skew polynomial P and the structure of the ϕ-module associated to P as suggested by our Proposition 1.4.2. We define a map Ψ that is shown to be multiplicative and to send a skew polynomial P to a commutative polynomial of the same degree. This map allows to compute some invariants for P such as the number and degrees of factors of P in a given class of similarity, and tests irreducibility effectively. We explain how the factorization of the associated commutative polynomial Ψ(P ) yields one factorization of P (and in fact, all of them) when Ψ(P ) is squarefree. At the level of ϕ-modules, this map classifies the ϕ-modules up to semi-simplification. We also show Theorem 2 (Corollary 2.4.4). Let P ∈ F q r [X, σ]. Then the similarity classes of irreducible factors of P appear in all possible orders in the factorizations of P .

We also use the map Ψ to give a new way to compute the number of monic irreducible skew polynomials of given degree over a finite field. We then give a polynomial-time algorithm in the degree to count the number of factorizations of a skew polynomial as a product of monic irreducible polynomials, and explain a method to find them all (naturally, an algorithm for this would be exponential in general because so is the number of factorizations, however our method is linear in this number).

Note that ϕ-modules are often used as a tool for the study of Galois representations over local fields (and usually with characteristic zero). A ϕ-module over a local field has a sequence of slopes, which are rational numbers that characterise the composition factors of the ϕ-module. It should be possible to recover the slopes of a ϕ-module over a field of positive characteristic from a factorization of its semi-characteristic polynomial, and even probably without factoring it using Newton polygons. This is not the approach of this paper, where the focus is on finite fields, but this topic will be discussed in the forthcoming paper [LeB].

1 The semi-characteristic polynomial of a ϕ-module Let K be a field of characteristic p, let a ≥ 1 be an integer, and σ : K → K be the a-th power of the absolute Frobenius. Set q = p a . The fixed field of σ is the intersection of K with the finite field with q elements F q . From now on, we assume that F q ⊂ K. If P, Q ∈ K[X] and ϕ is a semi-linear map on K d , then it is not true in general that P Q(ϕ) = P (ϕ)Q(ϕ), since ϕ does not act trivially on K. The right point of view for the polynomials of semi-linear maps is that of skew polynomials. Before investigating the properties of the semi-characteristic polynomials, we will recall some definitions and basic properties of the skew polynomial ring with coefficients in K.

Skew polynomials

Definition 1.1.1. The ring of skew polynomials with coefficients in K, denoted K[X, σ], is the set of polynomials with coefficients in K endowed with the usual addition, and the non-commutative multiplication

• verifying X • a = σ(a) • X. Definition 1.1.2. Let P, Q ∈ K[X, σ],
we say that P is a right-divisor of Q (or that P divides Q on the right) if there exists U ∈ K[X, σ] such that Q = U P . If this is the case, we say that Q is a left-multiple of P .

The ring of skew polynomials was first studied by Ore in [START_REF] Ore | Theory of Non-Commutative Polynomials[END_REF]. In this paper, he proves that the ring K[X, σ] is a right-euclidean domain, and therefore a left-principal ideal domain. The notions of right greatest common divisor (rgcd) and left lowest common multiple (llcm) are well defined: we say that D is a rgcd (resp. a llcm) of P and Q if D is a left-multiple of any polynomial that divides both P and Q on the right (resp. if it is a right-divisor of any polynomial that is a left-multiple of both P and Q). The same notions exist on the other side if K is perfect. A factorization of a skew polynomial is in general not unique up to permutation of the factors and multiplication by a constant. Two different factorizations are related by the notion of similar polynomials, which we define now.

Definition 1.1.3. Two skew polynomials P and Q are said to be similar if there exists U ∈ K[X, σ], such that the right-greatest common divisor of U and P is 1, and such that QU is the left-lowest common multiple of U and P .

Theorem 1.1.4 (Ore, [Ore33]). Let P 1 • • • P r = Q 1 • • • Q s ∈ K[X,
σ] be two factorizations of a given polynomial as a product of irreducible polynomials. Then r = s and there exists a permutation σ ∈ S r such that Q σ(i) and P i are similar for all 1 ≤ i ≤ r.

We will use the notions of skew polynomials in a context of semilinear algebra, because these polynomials are naturally the polynomials of semilinear endomorphisms.

Definition of the semi-characteristic polynomial

As before, let K be a field of characteristic p and σ : K → K be the a-th power of the absolute Frobenius. We still assume that F q ⊂ K. A ϕ-module over K is a finite dimensional vector space D endowed with a map ϕ : D → D that is semi-linear with respect to σ. Such a ϕ-module is said to be étale if the image of ϕ contains a basis of D. The aim of this section is to associate to a ϕ-module a polynomial (or, more precisely, a family of polynomials) that is an analog of the characteristic polynomial for linear maps. In general, for x ∈ D, the set

I ϕ,x = {Q ∈ K[X, σ] | Q(ϕ)(x) = 0}
is a left-ideal. Indeed, I ϕ,x is an additive subgroup of K[X, σ], and if P ∈ I ϕ,x and Q ∈ K[X, σ], then QP (ϕ)(x) = Q(ϕ)(P (ϕ)(x)) = 0. Hence this ideal has a generator m ϕ,x that we may call the minimal polynomial of x under the action of ϕ. We are mostly interested in the case where the degree of this polynomial is the dimension of the ϕ-module. In this case, we want to give an algebraic construction of m ϕ,x that will be called the semi-characteristic polynomial of ϕ in x. The idea is that by Cramer's formulas, the coefficients of m ϕ,x are rational functions in the coefficients of the matrix of the map ϕ: indeed, if (x, ϕ(x), . . . , ϕ d-1 (x)) is a basis of the ϕ-module D of dimension d, then ϕ d (x) can be written as a linear combination of x, ϕ(x), . . . , ϕ d-1 (x), the coefficients being of the form det(x, ϕ(x), . . . , ϕ i-1 (x), ϕ d (x), ϕ i+1 , . . . , ϕ d-1 (x)) det(x, ϕ(x), . . . , ϕ d-1 (x)) .

We show that these coefficients are actually polynomials.

Let d ∈ N and let

A = K[(a ij ) 1≤i,j≤d ]. Let G =     a 11 • • • a 1d . . . . . . a d1 • • • a dd    
be the so-called generic matrix with coefficients in A.

Theorem 1.2.1. Let x ∈ K d \ {0}, and let ϕ be the σ-semi-linear map on A d whose matrix in the canonical basis is G. Then there exists a unique family of polynomials P 0 , . . . , P d-1 ∈ A, depending only on x, such that

ϕ d (x) = P d-1 ϕ d-1 (x) + • • • + P 1 ϕ(x) + P 0 x.
Moreover, each P i is an homogeneous polynomial in the coefficients of G.

Before proving the theorem, let us mention the following corollary :

Corollary 1.2.2. Let L = K(x 1 , . . . x d ), and x =     x 1 . . . x d     ∈ L d
. Let P i be the polynomials defined as in Theorem 1.2.1. Then the

P i lie in K[x 1 , . . . , x d ][a ij ].
In particular, we can define the P i for x = 0.

The proof of the corollary will be given after that of the theorem. Let x 0 ∈ K d , and let (x i ) be the sequence of elements of A d defined by induction by x i+1 = Gσ(x i ). Here, σ acts on a vector in A d by raising each coordinate to the same power p a as σ on K. We call this sequence the sequence of iterates of x 0 under G. We will need the following lemma: Lemma 1.2.3. For all x ∈ K d \ {0}, the determinant ∆ = det(x 0 , . . . , x d-1 ) is an homogeneous element of A that is squarefree.

The fact that this determinant is homogeneous is clear since for all i ≥ 0, the coefficients of x i are all homogeneous polynomials of degree i-1 j=0 p j . We first show another lemma that will simplify the proof of Lemma 1.2.3. Lemma 1.2.4. With the above notations, it is enough to prove Lemma 1.2.3 for only one

x 0 ∈ K d \ {0}.
Proof. It is harmless to assume that K is algebraically closed (and hence infinite), which we will do in the proof. Let

x 0 , x ′ 0 ∈ K d \ {0}. Let (x i ) (respectively (x ′ i ))
the sequence of iterates of x 0 (respectively x ′ 0 ) under G. We assume that det(x 0 , . . . , x d-1 ) is a squarefree polynomial. Let P ∈ GL d (K) such that x ′ 0 = P x 0 . Let y 0 = x 0 and let (y i ) be the sequence of iterates of y 0 under P -1 Gσ(P ). We have x ′ 1 = Gσ(x ′ 0 ) = Gσ(P )σ(x 0 ) = P y 1 . An easy induction shows that for all i ≥ 0, x ′ i = P y i . Hence, det(x ′ 0 , . . . , x ′ d-1 ) = det P det(y 0 , . . . , y d-1 ). Since det P ∈ K × , it is enough to show that det(y 0 , . . . , y d-1 ) is squarefree. Define a morphism of K-algebras θ : A → A by G → P -1 Gσ(P ) (this gives the image of all the indeterminates by θ, and hence defines a unique morphism of K-algebras). In fact, this morphism is an isomorphism, with inverse given by G → P Gσ(P ) -1 . The map θ extends naturally to A d and A d×d and commutes with σ. By definition, θ(x ′ 0 ) = x 0 = y 0 , and θ(x i+1 ) = θ(G)σ(θ(x i )) = P -1 Gσ(P )σ(θ(x i )), which shows by induction that for all i ≥ 0, θ(x i ) = y i . Next, we remark that θ(det(x 0 , . . . , x d-1 )) = det(y 0 , . . . , y d-1 ). Since θ is an isomorphism, is maps a squarefree polynomial to a squarefree polynomial (the quotient of A by the ideal generated by a polynomial Q is reduced if and only if Q is squarefree). This proves the lemma.

We can now prove Lemma 1.2.3.

Proof. Let us prove the proposition by induction on the dimension d. Our induction hypothesis is that for any field K, the determinant ∆ is a squarefree polynomial. If d = 1, then the result is obvious. Assume the proposition is proved for d ∈ N, and prove it for d + 1. Recall that any factorization of ∆ has homogeneous irreducible factors. Therefore, we note that evaluating some of the variables to zero sends ∆ to a squarefree polynomial (in the unevaluated variables) if and only if ∆ is squarefree and the evaluation is nonzero. Indeed, if such an evaluation has a square factor, then so has ∆. Conversely, if ∆ has a square factor, then such an evaluation maps this square factor to either a nonconstant polynomial or to 0, and hence the evaluation also has a square factor. We will evaluate some of the variables to zero, namely we look at

G = 0 0 • • • 0 X 0 G ′ ,
where X 0 is of size (d -1) × 1 and G ′ is of size (d -1) × (d -1).

We define by induction

X i+1 = G ′ σ(X i ) for i ≥ 0. Now let x 0 =       1 0 . . . 0      
, and (x i ) the sequence of iterates of x 0 under this evaluation of G. Let us compute (x i ). First, x 1 = Gσ(x 0 ) = 0 X 0 and

x 2 = 0 X 1 . An easy induction shows that for all i ≥ 1,

x i = 0 X i-1
. Therefore, the evaluation ∆ ′ of ∆ that we are computing is

∆ ′ = det(x 0 , . . . , x d-1 ) = 1 0 0 • • • 0 0 X 0 X 1 • • • X d-2 .
This determinant is equal to its lower right (d-1)×(d-1) minor, which is equal to det(X 0 , . . . , X d-2 ). Denote by S the set of variables appearing in X 0 (i.e., a 21 , . . . , a d1 ), and S ′ the set of all the other variables appearing in G ′ . By induction hypothesis, applied with the field K(S), the polynomial ∆ ′ ∈ K(S)[S ′ ] is squarefree. This shows that if ∆ ′ has a square factor, then the only variables appearing in this square factor lie in S. Hence it is enough to find an evaluation in S ′ of ∆ ′ that is squarefree to show that ∆ ′ is squarefree, which implies that ∆ is squarefree as well. We use the previous computation that we evaluate in

G = 0 0 • • • 0 X 0 I d-1
, where I d-1 is the d -1 identity matrix. Then X i = σ i (X 0 ), and the evaluation of ∆ ′ that we are computing is

∆ ′′ = det(X 0 , σ(X 0 ), . . . , σ d-2 (X 0 )). What we need to prove now is that, in K[b 1 , . . . , b d ], the determinant V q (b 1 , . . . , b d ) = b 1 b q 1 • • • b q d-1 1 b 2 b q 2 • • • b q d-1 2 . . . • • • • • • . . . b d b q d • • • b q d-1 d
(which is known as the Moore determinant) is squarefree. It is a well-known fact that we have the following factorization:

V q (b 1 , . . . , b d ) = c ε∈P d-1 (Fq) d i=1 ε i b i , with c ∈ F × q . By ε ∈ P d-1 (F q ), we mean that the considered d-uples ε have their first nonzero coordinate equal to one. Note that if ε = (ε 1 , • • • , ε d ) ∈ P d-1 (F q ), then F ε = d i=1 ε i b i is an irreducible polynomial (it
is homogeneous with global degree 1). Two such distinct polynomials are not colinear since the coefficients are defined up to homothety, and hence are coprime. Moreover, if

F ε (β 1 , • • • , β d ) = 0,
then σ being linear on F q implies that the evaluation of the q-Vandermonde determinant at (β 1 , • • • , β d ) is the determinant of a matrix whose rows are linearly dependant over F q , so this evaluation is zero. Hilbert's zeros theorem shows that F ε divides V q , and given the coprimality of the F ε 's, their product divides V q . It is now enough to check that they have the same degree, that is easily seen to be q

d-1 + • • • + q + 1 = q d -1 q-1 .
Proof of Theorem 1.2.1. Since there exist simple ϕ-modules of dimension d with coefficients in A (that is, simple objects in the category of ϕ-modules over A, meaning that they have no nontrivial subspaces stable under the action of ϕ), the ϕ-module defined by ϕ is simple as a ϕ-module over the field of fractions B of A. In particular, for all x ∈ K d \ {0}, there exists a unique family

F 0 , . . . , F d-1 ∈ B such that ϕ d (x) = F d-1 ϕ d-1 (x) + • • • + F 1 ϕ(x) + F 0 x.
We want to show that the F i 's are actually in A. Let x 0 = x and (x i ) i≥0 be the sequence of iterates of x under G: for i ≥ 0, x i is the vector representing φ i (x) in the canonical basis. According to Cramer's theorem, the F i 's are given by the following formula, for i ≥ 0,:

F i = det(x 0 , . . . , x i-1 , x d , x i+1 , . . . , x d-1 ) det(x 0 , . . . , x d-1
) .

The denominator of F i is nothing but the determinant ∆ from Lemma 1.2.3. Since it is squarefree according to that lemma, Hilbert's zeros theorem (assuming K is algebraically closed) shows that it is enough to prove that the numerator vanishes whenever the denominator vanishes. If ∆ is mapped to zero by the evaluation of G at a, then the family (x 0 (a), . . . , x d-1 (a)) is linearly dependent over K, so it spans a vector space of dimension at most d -1. But the span of this family is also stable under ϕ since the smallest subspace stable by ϕ containing x 0 (a) (that we denote D x0(a) ) is spanned by the x i (a)'s, and for all r ∈ N, x d+r (a) lies in the span of x r (a), . . . , x r+d-1 (a). Therefore, any family of d elements of D x0(a) is linearly dependent over K, so that the numerator of F i vanishes at a for all 0 ≤ i ≤ d -1, which proves the theorem.

Proof of Corollary 1.2.2. The case d = 1 is obvious, so we will prove the corollary for d ≥ 2.

Recall that we want to show that, applying Theorem 1.2.1 with the field L = K(x 1 , . . . , x d ), we get the fact that the

P i 's lie in K(x 1 , . . . , x d )[a ij ]. Now let y =       1 0 . . . 0       , P =        x 1 0 • • • 0 x 2 1 . . . . . . . . . 0 . . . 0 x d • • • 0 1       
, and H = P -1 Gσ(P ), so that x = P y, and the P i associated to x (with respect to the matrix G) and y (with respect to the matrix H) are the same (by the computation of Lemma 1.2.4).

Since the coefficients of

H lie in K[x 1 , . . . , x d ][a ij ][x -1
1 ], so do the P i 's. Now taking another P whose determinant is, say, x 2 (which is possible since d ≥ 2), we see that the P i 's also lie in

K[x 1 , . . . , x d ][a ij ][x -1 2 ], so they actually lie in K[x 1 , . . . , x d ][a ij ].
Definition 1.2.5. With the previous notations, the polynomial χ 0

ϕ,x = X d - d-1 i=0 P i X i ∈ A[x 1 , . . . , x d ][X, σ] obtained from the vector x of Corollary 1.2.2 is called the universal semi- characteristic polynomial in over K. Given a ϕ-module D of dimension d over K, whose matrix in a basis B of K d is G(a)
, and x ∈ D whose coordinates in the basis B are given by ξ = (ξ 1 , . . . , ξ d ), the semi-characteristic polynomial of ϕ in x in the basis B is the evaluation of χ 0 ϕ,x at a, ξ, that will be denoted χ ϕ,x,B or just χ ϕ,x when no confusion is possible.

Remark 1.2.6. We will see later (see Corollary 2.6.2) that if the ϕ-module D has dimension d,

then χ ϕ,0,B = X d . Of course, χ ϕ,x,B lies in K[X, σ].
The main properties of this polynomial are that χ ϕ,x,B (ϕ)(x) = 0 and that χ ϕ,x,B is constructed algebraically from G(a) and the coefficients of x. Let us give an example with σ(

x) = x q , d = 2, G = a b c d , x = 1 0 . Then χ ϕ,x = X 2 + P 1 (a, b, c, d)X + P 0 (a, b, c, d)
, with P 0 (a, b, c, d) = adc q-1bc q , P 1 (a, b, c, d) = -a qc q-1 d. Note that, when formally putting q = 1, we recover the expression of the characteristic polynomial. When d = 3,

with x =    1 0 0   ,
we can write χ ϕ,x = X 3 + P 2 X 2 + P 1 X + P 0 . The polynomial P 0 has 336 terms, P 1 has 232 terms, and P 2 has 107 terms.

Lemma 1.2.7. Let (D, ϕ) be a ϕ-module of dimension d over K, endowed with a basis B. Let x ∈ D and let χ ϕ,x be the associated semi-characteristic polynomial. Then the left-ideal

I ϕ,x = {Q ∈ K[X, σ] | Q(ϕ)(x) = 0} contains χ ϕ,x
, and if the ϕ-module D is generated by x, then

I ϕ,x = K[X, σ]χ ϕ,x .
Proof. We have already seen that χ ϕ,x (ϕ)(x) = 0. Assume x generates D, then x, ϕ(x), . . . , ϕ d-1 (x) is a linearly independant family in D, so all the nonzero elements of I ϕ,x have degree at least d.

Then the monic generator of I ϕ,x , which is the minimal polynomial m ϕ,x of x by definition, has degree d. Since I ϕ,x contains a unique monic element of minimal degree, m ϕ,x = χ ϕ,x . Hence

I ϕ,x = K[X, σ]χ ϕ,x .
The hypothesis that the ϕ-module admits a generator might not sound very satisfactory, but the following proposition shows that, at least when K is infinite, such a generator always exists.

Proposition 1.2.8. Assume the field K is infinite, and let (D, ϕ) be an étale ϕ-module over K. Then there exists x ∈ D which generates D under the action of ϕ.

Proof. Let d = dim D. What we want to prove is that there exists x ∈ D such that the determinant det(x, ϕ(x), . . . , ϕ d-1 (x)) = 0. We work with the field K(X 1 , . . . , X d ) over which the map σ extends naturally, and we denote by G the matrix of the map ϕ in a basis of D. Let x 0 = (X 1 , . . . , X d ) and for 0 ≤ i ≤ d -1, x i+1 = Gσ(x i ), we consider the polynomial R = det(x 0 , . . . , x d-1 ). Since K is infinite, it is enough to show that R is not the zero polynomial. Hence, it is enough to check that there is a specialization of X 1 , . . . , X d in an algebraic closure K alg of K such that R is not sent to zero. Since D is isomorphic over K alg to the ϕ-module whose matrix is identity, R = αV q (X 1 , . . . , X d ) where α ∈ K is nonzero and V q is the q-Vandermonde determinant that already appeared above, which is nonzero. This shows that R = 0.

Remark 1.2.9. We shall see later what happens when K is finite. The matter of when a ϕ-module over K has a generator is discussed in the section 2.6.1. We will also see in the next section a more precise description of χ ϕ,x when x is not a generator (see Corollary 1.4.3).

Basic properties

We look at some of the first properties of the semi-characteristic polynomials that are directly related to Ore's theory of skew polynomials. In particular, we explain how the notion of similarity appears naturally in our context. Note that the results of this section and the next one are mostly a reinterpretation of Chapter I of [Jac].

Proposition 1.3.1. Let D be a ϕ-module over K and x, y ∈ D two nonzero elements. Assume that both x and y generate D as a ϕ-module. Then χ ϕ,x and χ ϕ,y are similar.

Proof. Since x generates D, there exists U ∈ K[X, σ] such that y = U (ϕ)(x). Now, let B be a basis of D, and let χ ϕ,x , χ ϕ,y be the semi-characteristic polynomials corresponding to x and y in this basis. Then χ ϕ,y U (ϕ)(x) = 0, so χ ϕ,x is a right-divisor of χ ϕ,y U . Since y generates D, there exists a polynomial V such that x = V (ϕ)(y), so that V U (ϕ)(x) = x. Hence, χ ϕ,x divides V U -1 on the right: this exactly means that the right greatest common divisor of U and χ ϕ,x is 1. Hence, χ ϕ,y U , that has degree deg U + deg χ ϕ,x , is the left lowest common multiple of U and χ ϕ,x . Conversely, let P be a monic polynomial similar to χ ϕ,x . Then there exists U ∈ K[X, σ] and V ∈ K[X, σ] two polynomials, such that U and χ ϕ,x are rightcoprime, and V χ ϕ,x = P U . Since U and χ ϕ,x are right-coprime, there exist P 1 , P 2 ∈ K[X, σ] such that P 1 U + P 2 χ ϕ,x = 1, so P 1 (ϕ)U (ϕ)(x) = x. In particular, y = U (ϕ)(x) is a generator of D. Moreover, P (ϕ)(y) = 0, so χ ϕ,y is a right-divisor of P . Since they have the same degree and P is monic, they are equal.

Corollary 1.3.2. Let (D 1 , ϕ 1 ) and (D 2 , ϕ 2 ) be two isomorphic ϕ-modules. Assume that x 1 ∈ D 1 generates D 1 , and x 2 ∈ D 2 generates D 2 . Then the semi-characteristic polynomials χ ϕ1,x1 and χ ϕ2,x2 are similar.

Proof. Choosing an isomorphism mapping x 1 to some x ′ 2 ∈ D 2 , we are reduced to prove that χ ϕ2,x2 and χ ϕ2,x ′ 2 are similar. This follows from Proposition 1.3.1. This shows that if x generates the ϕ-module D, and B is a basis of D, then the semicharacteristic polynomial χ ϕ,x,B does not depend on the choice of the basis up to similarity. Frow now on, we shall sometimes talk about the semi-characteristic polynomial of a ϕ-module, which will stand for the set of its characteristic polynomials with first vector generating the ϕ-module. It is contained in a similarity class that depends neither upon the class of isomorphism of the ϕ-module, nor upon the choice of the generator x. More precisely, it is the set of all monic polynomials contained in this similarity class. This set will be denoted by χ ϕ .

Semi-characteristic polynomials and sub-ϕ-modules

We now want to understand how the notion of semi-characteristic polynomial behaves with respect to sub-ϕ-modules.

Proposition 1.4.1. Let (D, ϕ) be a ϕ-module of dimension d over K. Then χ ϕ,x is irreducible in K[X, σ] for all x ∈ D \ {0} if and only if D is a simple ϕ-module.
Proof. Assume that χ ϕ,x is irreducible for all x ∈ D \ {0}. Using the above notations, for all x, I ϕ,x = K[X, σ]χ ϕ,x . This means that for all nonzero polynomial Q ∈ K[X, σ] with deg Q < d, and for all x, Q(ϕ)(x) = 0. In particular, all the families x, . . . , ϕ d-1 (x) are linearly independant over K, so D is simple. Conversely, assume that D is simple. Let x ∈ D, nonzero. If χ ϕ,x = P Q with P, Q monic and deg P < d, then P (ϕ)Q(ϕ(x)) = 0. The ϕ-module generated by Q(ϕ(x)) is then of dimension < d, so it is zero, and Q(ϕ(x)) = 0, which means that χ ϕ,x divides Q on the right, so Q = χ ϕ,x .

Proposition 1.4.2. Let 0 → D 1 → D → D 2 → 0 be an exact sequence of ϕ-modules, and denote by ϕ 1 , ϕ, ϕ 2 the respective maps on D 1 , D, D 2 . Let x ∈ D. Let x = x mod D 1 , and

x 1 = χ ϕ2,x (ϕ)(x). Then χ ϕ,x = χ ϕ1,x1 χ ϕ2,x .
Moreover, if x is a generator of D, then x 1 (resp. x) is a generator of D 1 (resp. of D 2 ).

Proof. We can assume that K is algebraically closed. The set {x ∈ D / x generates D} is the Zariski-open subset of D {det(x, ϕ(x), . . . , ϕ d-1 (x)) = 0}. Since it is not empty, and the identity is polynomial in the coefficients of the vector x, it is enough to prove the proposition when x is a generator of D. The result is clear if D 1 = D, so we assume that D 1 = D. In this case, x / ∈ D 1 , otherwise x would not generate the whole of D. Therefore, x = 0. Let x 1 = χ ϕ2,x (ϕ)(x). Since χ ϕ2,x (ϕ)(x) = 0, x 1 ∈ D 1 . It is a generator of D 1 , otherwise there would be a polynomial P with degree < dim D 1 such that P (ϕ)(x 1 ) = 0, so P χ ϕ2,x (ϕ)(x) = 0, with deg P χ ϕ2,x < dim D, which is in contradiction with the fact that x generates D. On the other hand, it is obvious that x generates D 2 . Hence, χ ϕ1,x1 χ ϕ2,x (ϕ)(x) = 0, so χ ϕ1,x1 χ ϕ2,x is right-divisible by P , and the equality of the degrees proves that χ ϕ,x = χ ϕ1,x1 χ ϕ2,x .

≤ i ≤ m -1. Let x ∈ D. Then χ ϕ,x = π m-1 . . . π 0 ,
with π i = χ ϕi,yi for some

y i ∈ D i /D i+1 , for all 0 ≤ i ≤ m -1 (in particular each polynomial π i is irreducible in K[X, σ]).
Proof. Let us prove the theorem by induction on m. If m = 0 the result is clear. Assume m ≥ 1, then Proposition 1.4.2 shows that χ ϕ,x = χ ϕ1,x1 χ ϕ0,x with x = x mod D 1 and x 1 = χ ϕ0,x (x) ∈ D 1 .

The induction hypothesis shows that χ ϕ1,y1 factors as

2 i=m-1 χ ϕi,xi with x i ∈ D i /D i+1 .
Let D be an étale ϕ-module that has a generator x, and let χ ϕ,x be its semi-characteristic polynomial with respect to x. If D → D 2 is a quotient of D (on which the induced map is denoted by ϕ 2 ), then we can associate to D 2 the semi-characteristic polynomial χ ϕ2,x where x is the image of x in the quotient. The following proposition shows that this map is in fact a bijection.

Proposition 1.4.5. Let D be an étale ϕ-module that has a generator x, and let χ ϕ,x be its semicharacteristic polynomial with respect to x in some basis. Then the above map is a natural bijection between the following sets:

(i) The monic right-divisors of χ ϕ,x ;

(ii) The quotients of the ϕ-module D.

Moreover, this bijection maps exactly the irreducible divisors to the simple quotients.

Proof. First note that by Proposition 1.4.2, χ ϕ2,x is an irreducible right-divisor of P . The considered map is surjective. Indeed, let χ ϕ,x = P 1 P 2 with P 2 irreducible, and let y = P 2 (ϕ)(x). Let D y be the sub-ϕ-module generated by y and let D → D/D y be the canonical projection. Then x = x mod D y generates D/D y and P 2 (ϕ)(x) = 0, so χ ϕ,x = P 2 . Now, we show that the considered map is also injective. Let D ′ , D ′′ be two simple quotients endowed with the induced maps ϕ ′ , ϕ ′′ . Denote by x′ (resp. x′′ ) the image of x by the canonical projection to D ′ (resp. D ′′ ). Assume that χ ϕ ′ ,x ′ = χ ϕ ′′ ,x ′′ . Then there exists a unique map D ′ → D ′′ sending x′ to x′′ , and this map is an isomorphism. Moreover, the kernel of the composite map D → D ′′ is the set of y ∈ D such that y = Q(ϕ)(x) for some polynomial Q that is right-divisible by χ ϕ ′′ ,x ′′ . This is exactly the kernel of the canonical map D → D ′′ , so D ′ = D ′′ . The fact that irreducible polynomials correspond to simple ϕ-modules follows from Proposition 1.4.1.

We have the following corollary, that will be useful to count the factorizations of a skew polynomial over a finite field.

Corollary 1.4.6. Let P ∈ K[X, σ] be a monic polynomial with nonzero constant coefficient. Then there is a natural bijection between the factorizations of P as a product of monic irreducible polynomials, and the Jordan-Hölder sequences of V P .

Proof. The proof is an easy induction on the number of irreducible factors of P .

Skew polynomials and ϕ-modules over finite fields

We now want to focus on ϕ-modules over finite fields. We investigate some other links with skew polynomials and the so-called linearized polynomials. The reference used for basics on linearized polynomials over finite fields is [LN94], Chap 4, §4.

Galois representations and ϕ-modules

Let K be a field of characteristic p, and K sep be a separable closure of K. There is an antiequivalence of categories between the F q -representations of G K = Gal(K sep /K) and the étale ϕ-modules over K, when ϕ acts as x → x q on K. The functor from representations to ϕ-modules is Hom GK (•, K sep ), and its quasi-inverse is Hom ϕ (•, K sep ), where G K acts naturally on K sep and ϕ acts as x → x q on K sep . This theory was introduced by Fontaine to study the Galois representations of local fields of characteristic p and then gave birth to the theory of (ϕ, Γ)-modules to study the p-adic representations of p-adic fields. We want to use this tool in the context of finite fields. Here, we use the equivalence of categories to skew polynomials rather than representations. Indeed, the data of a representation of G F q r is very simple: it is just given by the action of the Frobenius x → x q r on the representation. Let p be a prime number, q = p a a power of p, and r ≥ 1 be an integer.

Definition 2.1.1. A q-linearized polynomial over F q r is a polynomial L ∈ F q r [X] of the form L = d i=0 a i X q i where for all 0 ≤ i ≤ d, a i ∈ F q r . Remark 2.1.2. Such polynomials define F q -linear maps on any extension of F q r , hence the terminology. Furthermore, the roots of a q-linearized polynomial have a natural structure of F q -vector space.

The vector space of q-linearized polynomials is endowed with a structure of noncommutative F q r -algebra, with the usual sum and product given by the composition:

L 1 × L 2 (X) = L 1 (L 2 (X)).
It is easily checked that there is a natural isomorphism between the F q r -algebras of q-linearized polynomials over F q r , and of skew polynomials F q r [X, σ] where σ(x) = x q . The correspondance between linearized and skew polynomials is the following: Definition 2.1.3. Let P ∈ F q r [X, σ] be a skew polynomial, P = d i=0 a i X i . By definition, the associated linearized polynomial is L P = d i=0 a i X q i . Conversely, if L is a linearized polynomial over F q r , its associated skew polynomial is denoted by P L .

Let P ∈ F q r [X, σ] be a monic polynomial, say P = X dd-1 i=0 a i X i . To P we associate the linearized polynomial L P as before, and the ϕ-module D P given by the following data:

• D P = d-1 i=0 F q r e i , • for i ∈ {0, . . . , d -2}, ϕ(e i ) = e i+1 , • ϕ(e d-1 ) = d-1 i=0 a i e i .
We can note that in the canonical basis (e 0 , . . . , e d-1 ), χ ϕ,e0 = P . Lemma 2.1.4. Let (D, ϕ) be a ϕ-module over F q r . Then (D, ϕ r ) is a ϕ r -module over F q r . Let V be the F q -representation of G F q r associated to ϕ and V r be the F q r -representation of G F q r associated to ϕ r . Then V r ≃ V ⊗ Fq F q r . Proof. It is clear that ϕ r is σ r -semi-linear (which means just linear!). Then, there is a natural injective map V = Hom ϕ (D, F q ) ֒→ Hom ϕ r (D, F q ) = V r . A classical argument (appearing for example in the proof of Proposition 1.2.6 in [START_REF] Fontaine | Représentations p-adiques des corps locaux[END_REF]) shows that a family of elements of V that is linearly independant over F q remains linearly independant over F q r . Hence V ⊗ Fq F q r injects into V r , and since dim Fq V = dim F q r V r , we get V r ≃ V ⊗ Fq F q r . Lemma 2.1.5. The representation V P associated to the ϕ-module D P is naturally isomorphic to the vector space of the roots of L P endowed with the natural action of G F q r . Proof. By definition, V P = Hom ϕ (D P , Fq ). Let f ∈ V P . Let ξ i = f (e i ), the relations between the e i 's and the fact that f is ϕ-equivariant imply that for all 0 ≤ i ≤ d -2, ξ i = ξ q i 0 . Subsequently, ξ q d 0 = d-1 i=0 a i ξ q i 0 , so that ξ 0 is a root of L P . Conversely, the same computation shows that given any root ξ of L P , the map D → F q sending e i to ξ q i is a ϕ-equivariant morphism. Hence, the map

V P → {Roots of L P } f → f (e 0 )
is an isomorphism. Moreover, the action of G F q r on V P comes from that on F q r , so that it is just the raising to the q r -th power, and it is compatible with the previous map, making it an isomorphism of representations.

Theorem 2.1.6. Let (D P , ϕ) be the ϕ-module associated to the polynomial P . Then the Frobenius map g ∈ G F q r acting on V P (by x → x q r ) and the map ϕ r on D P have matrices that are conjugate.

Proof. Since the matrix of the Frobenius acting on V P is conjugate to the matrix of the Frobenius acting on the F q r -representation associated to (D P , ϕ r ) by Lemma 2.1.4, we will show that the matrix of the latter is conjugate to the matrix of ϕ r . By the Chinese remainders theorem, it is enough to show the result when the characteristic polynomial of ϕ r is a power of an irreducible polynomial Q. By the elementary divisors theory, it is also enough to show the result when ϕ r is a cyclic endomorphism. Assume that the matrix of ϕ r in the basis (e 0 , . . . e d-1 ) is the companion matrix of a polynomial Q e , with Q irreducible. Then the map Hom ϕ r (D Q e , F q r ) → Roots of L Q e (X r ) = V Q e (X r ) , mapping f to f (e 0 ) is an isomorphism of F q r -representations by Lemma 2.1.5. Let ξ be a nonzero root of L Q e (X r ) , and let f ∈ Hom ϕ r (D Q e , F q r ) mapping e 0 to ξ. Let g be the Frobenius map on V Q e (X r ) , and χ g be its characteristic polynomial. Then f (χ g (ϕ r )(e 0 )) = χ g (g)(ξ) = 0 because f is ϕ r -equivariant. Hence for all f ∈ Hom ϕ r (D Q e , F q r ), f (χ g (ϕ r )(e 0 )) = 0. The injectivity of the map Hom ϕ r (D Q e , F q r ) → V Q e (X r ) implies that χ g (ϕ r ) = 0, so the minimal polynomial of ϕ r divides χ

g . If Q ε (g) = 0 for some ε ≤ e, then Q ε (ϕ r )(f )(x) = Q ε (g)(f (x)) for all x ∈ D, f ∈ Hom ϕ r (D Q e , F q r
), and so Q ε (ϕ r ) = 0, which shows that ε = e. Therefore, the minimal polynomial of g is Q e , and the matrices of g and ϕ r are conjugate.

From now on and throughout the article, we will perform complexity computations using the usual notations O and Õ (we say that a complexity is Õ(g(n)) if it is O(g(n) log k (n)) for some integer k). For computations over finite fields, we will usually express the complexity as the number of operations needed in the base field F q . We will make the common assumption that the multiplication in F q r is quasilinear. We will denote by MM (d) the complexity of the multiplication of two matrices of size d × d over F q , so that the multiplication of two matrices of size d × d over

F q r is MM (dr).
Remark 2.1.7. The matrix of g can be computed in O(MM (dr) log r + d 2 r 2 log q log r) multiplications in F q if P has degree d and multiplication of matrices of size d × d over F q r has complexity MM (dr). Indeed, if G is the companion matrix of ϕ, then the matrix of ϕ r is Gσ(G) • • • σ r-1 (G). Since applying σ t to an element of F q r costs t log q operations in F q r (by a fast exponentiation algorithm), a divide-and-conquer algorithm allows us to compute the matrix of ϕ r with O(MM (d) log r + d 2 r) operations in

F q r . Algorithm 1 Returns E(G, r) = Gσ(G) • • • σ r-1 (G) Input: G the matrix of ϕ, r ≥ 1 an integer Output: E(G, r) the matrix of ϕ r if r = 1 then return G else if r is even then return E(G, r/2) • σ r/2 (E(G, r/2)) else return G • σ(E(G, (r -1)/2) • σ (r-1)/2 (E(G, (r -1)/2))) end if end if
The following proposition gives another application of considering ϕ r , namely testing similarity of polynomials.

Proposition 2.1.8. Let P, Q ∈ F q r [X, σ] be two monic polynomials. Let Γ P (resp. Γ Q ) be the companion matrix of P (resp. Q). Then P and Q are similar if and only if the matrices

Γ P • • • σ r-1 (Γ P ) and Γ Q • • • σ r-1 (Γ Q ) are conjugate.
Proof. Assume P and Q are similar, and let

d = deg P = deg Q. Then P = χ ϕ,x for some x ∈ D Q . Therefore, there exists U ∈ GL d (F q r ) such that Γ P = U -1 Γ Q σ(U ), so Γ P • • • σ r-1 (Γ P ) = U -1 Γ Q • • • σ r-1 (Γ Q )U .
Hence, these two matrices are conjugate. Conversely, assume that these matrices are conjugate. Then the representations V Q and V P are isomorphic (because these matrices are conjugate to the matrices of the action of the Frobenius on the respective representations, which are therefore F q -conjugate), so the ϕ-modules D P and D Q are isomorphic. Hence, P and Q are similar.

This proposition shows how similarity can be tested only by computing the Frobenius normal form of ϕ r , which can be done in Õ(MM (dr)) operations in F q .

The splitting field of a linearized polynomial

In this section, we use the previous results to explain how to compute the splitting field of a qlinearized polynomial with coefficients in F q r and the action of G F q r on its roots. We start with a lemma from

[LN94]. Lemma 2.2.1. Let Q ∈ F q [Y
] with nonzero constant coefficient and let L Q be the q-linearized associated polynomial. Then the splitting field of L Q is F q m , where m is the maximal order of a root of

Q in F × q . Remark 2.2.2. If Q = Q t1 1 • • • Q ts s
with the polynomials Q i distinct monic irreducible, then setting t = max{t i } -1 and e = max{Order of the roots of Q i }, we have m = ep t .

We are ready to prove the following: Theorem 2.2.3. Let P ∈ F q r [X, σ] with nonzero constant coefficient, and let L P be the associated linearized polynomial. Let Γ be the companion matrix of P , and Γ 0 = Γσ(Γ) • • • σ r-1 (Γ). Then the characteristic polynomial Q of Γ 0 has coefficients in F q , and the splitting field of L P has degree m over F q r , where m is the maximal order of a root of Q in F q . Moreover, the Frobenius normal form G 0 of Γ 0 has coefficients in F q , and the action of a generator g of the Galois group G F q r is given (in some basis of the F q -vector space of the roots of L P ) by G 0 .

Proof. By Theorem 2.1.6, Γ 0 , being the matrix of (D P , ϕ r ), is conjugate to the matrix of the action of g on the roots of L P . The latter has coefficients in F q since it is the matrix of an F qrepresentation V P of G F q r , as does the Frobenius normal form of Γ 0 . It only remains to determine the splitting field of L P . But this field is the same as the subfield of F q r fixed by the kernel of the representation V P . This again is the same as the subfield fixed by the kernel of the representation V P ⊗ F q r , which is the same as the splitting field of L Q . The result then follows from Lemma 2.2.1.

Example 2.2.4. Let q = 7 and r = 5. The field F 7 5 is built as

F 7 [Y ]/(Y 5 + Y + 4), and ω denotes the class of Y in F 7 5 . Let L = Z 7 3 + ωZ 7 2 -ω 2 Z ∈ F 7 5 [Z]. The associated skew polynomial P ∈ F 7 5 [X, σ] is X 3 + ωX 2 -ω 2 , so the matrix of ϕ on D P is Γ =    0 0 ω 2 1 0 0 0 1 -ω   . The characteristic polynomial of the matrix Γ 0 of ϕ r is Y 3 + Y 2 + Y + 5
, which is irreducible. The order of any root of this polynomial in F 7 is 171, so the splitting field of L is F 7 5×171 . This also shows that the Jordan form of the matrix of ϕ r is

   0 0 -5 1 0 -1 0 1 -1   
, that is the matrix of the action of x → x 7 5 on a basis of the roots of L over F 7 5 .

Optimal bound of a skew polynomial

The previous section has shown that, given a ϕ-module (D, ϕ) over F q r , the ϕ r -module (D, ϕ r ) should have interesting properties for the study of (D, ϕ). In this subsection, we will show how this idea can also help us solve the problem of finding a multiple of a polynomial lying in the center of F q r [X, σ]. We recall the notations from the above section, that we shall use in this one: if P ∈ F q r [X, σ], then D P is the associated ϕ-module, L P is the associated linearized polynomial, and V P is the associated linear representation of G F q r (either by Fontaine's theory, or as the roots of L P , since both are the same object by Lemma 2.1.5).

The following lemma is a slightly generalized version of a lemma from [LN94], where only the case r = 1 is treated.

Lemma 2.3.1. Let L 1 , L be two linearized polynomials. Then L 1 is a right-divisor of L in the algebra of linearized polynomials if and only if it is a divisor of L in the classical sense.

Proof. First assume that L 1 divides L on the right in the sense of linearized polynomials, meaning that there exists a linearized polynomial L 2 such that L(X) = L 2 (L 1 (X)). Since the constant coefficient of L 2 is zero, this implies that L 1 divides L in the classical sense. Conversely, if L 1 divides L in the classical sense, write the right-euclidean division of L by L 1 as linearized polynomials, we have

L = L 2 • L 1 + R with deg R < deg L 1 . From the first part of the proof, L 1 divides L 2 • L 1 in the classical sense, so it also divides R. Since deg R < deg L 1 , R = 0.
This already allows us to give an explicit description of the optimal bound of a skew polynomial. A bound of a skew polynomial P is a nonzero multiple of P that lies in the center of F q r [X, σ] (which is easily shown to be F q [X r ]), and an optimal bound is a bound with lowest degree.

Theorem 2.3.2. Let P ∈ F q r [X, σ] be a monic polynomial with nonzero constant term. Let π ϕ r be the minimal polynomial of the F q -linear map ϕ r : D P → D P . Then the optimal bound for P is π ϕ r (X r ). It has degree at most r deg P and can be computed in Õ(d 2 r 2 log q + M M (rd)) operations in F q .

Proof.

Since π ϕ r (ϕ r ) = 0, π ϕ r (X r )(ϕ)(e 0 ) = 0. Since P = χ ϕ,e0 , P is a right divisor of π ϕ r (X r ). Conversely, if Q ∈ F q [Y ] is a monic polynomial such that Q(X r ) is right-divisible by P , then Q(ϕ r )(e 0 ) = 0. Moreover, since Q(X r ) is central, XQ(ϕ r )(e 0 ) = Q(ϕ r )(ϕ(e 0 )
). An immediate induction shows that, since e 0 generates D P under the action of ϕ, Q(ϕ r ) = 0. Hence, π ϕ r divides Q. By Remark 2.1.7, the matrix of ϕ r can be computed in Õ(d 2 r 2 log q + MM (rd)) operations in F q . Its minimal polynomial can be computed in Õ(MM (rd)) operations by [START_REF] Giesbrecht | Nearly optimal algorithms for canonical matrix forms[END_REF], hence the complexity of the computation of the optimal bound. Remark 2.3.3. This complexity can be compared with Giesbrecht's computation of an optimal bound in Õ(d 3 r 2 + MM (rd)) operations in F q r ([Gie98], Lemma 4.2). Since this part is used in his factorization algorithm, computing the optimal bound using Theorem 2.3.2 improves the complexity of this part of Giesbrecht's algorithm.

Theorem 2.2.3 has shown that the characteristic polynomial of ϕ r already gives interesting information. Since the characteristic polynomial is also slightly easier to compute than the minimal polynomial, we introduce the following definition: Definition 2.3.4. Let P ∈ F q r [X, σ] a monic skew polynomial, and let (D P , ϕ) be the associated ϕ-module. The polynomial Ψ(P ) ∈ F q [Y ] is defined as the characteristic polynomial of ϕ r , that is det(Y idϕ r ).

Remark 2.3.5. The polynomial Ψ(P ) can be thought of as lying in the center F q [X r ] of F q r [X, σ]. This is a reason why we use the variable Y . The other reason is that Ψ(P ) is a commutative polynomial, and a different notation for the variable can help avoid confusions.

Remark 2.3.6. By a result of Keller-Gehrig, the characteristic polynomial of an endomorphism of F d q r can be computed in O(MM (dr)) operations in F q (see [START_REF] Keller-Gehrig | Fast algorithms for the characteristic polynomial[END_REF]). Hence, if P has degree d, Ψ(P ) can be computed in O(MM (dr) log r + d 2 r 2 log r log q) operations in F q .

Corollary 2.3.7. Let P ∈ F q r [X, σ] with nonzero constant coefficient. The polynomial Ψ(P )(X r ) is a bound for P .

Proof. It follows directly from Theorem 2.3.2.

The map Ψ and factorizations

In this section, we explain how the map Ψ can be used to find factorizations of a skew polynomial.

Let (D, ϕ) be an étale ϕ-module over F q r . We note that this property is not true when P is not irreducible: this will be discussed in Remark 2.4.10 below.

Lemma 2.4.6. Every irreducible monic polynomial in F q [Y ] is the image of a monic irreducible polynomial by the map Ψ.

Proof. It is clear that Y is the image of X. Now assume that R ∈ F q [Y ] is irreducible, monic, with nonzero constant coefficient. Let V be the F q -representation of G F q r whose dimension is the degree of R, and for which the matrix of the Frobenius map x → x q r is the companion matrix of R. Let (D, ϕ) be the ϕ-module corresponding to V . Since R is irreducible, V is an irreducible representation, so (D, ϕ) is an irreducible ϕ-module. Let χ ϕ be the semi-characteristic polynomial of ϕ at some nonzero x ∈ D. Theorem 2.1.6 shows that R is equal to the characteristic polynomial of ϕ r , which is just Ψ(χ ϕ ) by definition. Moreover, the irreducibility of the ϕ-module D yields the irreducibility of χ ϕ,x .

Corollary 2.4.7. Let P ∈ F q r [X, σ] be a monic polynomial. The polynomial P is irreducible if and only if

Ψ(P ) is irreducible in F q [Y ].
Since testing irreducibility of a polynomial of degree d over F q can be done in O(dMM (d)) mulitplications in F q , we can test irreducibility of a polynomial in

F q r [X, σ] of degree d in O(d 2 r 2 log r log q+ MM (rd) + dMM (d)) multiplications in F q .
Proof. We can assume that P has nonzero constant coefficient. By Proposition 2.4.2, we know that if Ψ(P ) is irreducible, then so is P . Conversely, Lemma 2.4.6 shows that every irreducible divisor D of Ψ(P ) has an irreducible antecedent Q by Ψ. By Proposition 2.4.3, Q is similar to a right-divisor of P . Hence since P is irreducible, Q = P , and Ψ(P ) = D, so Ψ(P ) is irreducible.

Corollary 2.4.8. The map Ψ is surjective.

Proof. The result follows directly from Lemma 2.4.6 and Proposition 2.4.2.

Corollary 2.4.9. The degrees of the factors in a factorization of a monic polynomial P ∈ F q r [X, σ] as a product of irreducibles are the same as the degrees of the factors of Ψ(P ) in a factorization as a product of irreducible polynomials in F q [Y ].

Remark 2.4.10. Let P, Q ∈ F q r [X, σ] be two monic polynomials, then Ψ(P ) = Ψ(Q) if and only if D P and D Q have the same semi-simplifications. Indeed, the similarity classes (with multiplicities) of the monic irreducible factors appearing in factorizations of P are uniquely determined by Ψ(P ) because Ψ is multiplicative and by Ore's Theorem. On the other hand, these similarity classes are also uniquely determined by the semi-simplification of D P again by multiplicativity of Ψ and by Theorem 1.4.4. Now, we use the map Ψ to get more precise information about the factorization of

P ∈ F q r [X, σ] from the factorization of Ψ(P ) ∈ F q [Y ].
Proposition 2.4.11. Let P ∈ F q r [X, σ] be a monic polynomial. Assume

Ψ(P ) = Q 1 • • • Q s , with Q i ∈ F q [Y
] distinct irreducible monic polynomials (Ψ(P ) is squarefree). Then P has a unique right-divisor P i such that Ψ(P i ) = Q i . It is given by P i = rgcd(P, Q i (X r )).

Proof. Assuming that the P i 's are irreducible, uniqueness is clear, since a right-divisor S of P such that Ψ(S) = Q i must divide both P and Q i (X r ). Let 1 ≤ i ≤ s, and P i = rgcd(P, Q i (X r )). Since V Ψ(P )(X r ) = V P ⊗ Fq F q r , Ψ(Ψ(P )(X r )) = Ψ(P )(X) r . Hence, all divisors of Ψ(P i ) are in the same similarity class, and Ψ(P i ) is a power of Q i , so its degree is divisible by deg Q i . But Q i has only multiplicity one as a divisor of Ψ(P ), so Ψ(P i ) is either 1 or Q i . Since i deg P i = deg P , Ψ(P i ) = Q i for all 1 ≤ i ≤ s, and P i has degree deg Q i and is irreducible because Q i is.

Remark 2.4.12. More generally, when

Ψ(P ) = Q e1 1 • • • Q es s , P i = rgcd(P, Q i (X r
)) has degree divisible by deg Q i , and Ψ(P i ) = Q εi i for some 1 ≤ ε i ≤ e i . This can sometimes provide a partial or even complete factorization for P , but not always: this will be better understood later when we count factorizations of a given polynomial.

Counting irreducible polynomials

Before counting factorizations of a given skew polynomial, we focus on finding the number of monic irreducible skew polynomials. This computation appears in [START_REF] Coulter | On decomposition of sub-linearized polynomials[END_REF], although it is obtained by very different methods. Here, it only comes from the computation of the cardinal of the fibers of Ψ. Recall that a ϕ-module is called simple if it has no nontrivial subspaces stable by ϕ.

Lemma 2.5.1. Let D be a simple étale ϕ-module over F q r of dimension d. Then End(

D) = F q [ϕ r ] ≃ F q d . Proof. Let E = End(D). It is clear that F q [ϕ r ] is contained in E.
Moreover, any u ∈ E commutes with ϕ and therefore with ϕ r . Since D is simple, ϕ r has no nontrivial invariant subspace, so it is a result of elementary linear algebra that the commutant of ϕ r is

F q r [ϕ r ]. Hence E is contained inF q r [ϕ r ]. Now let u = d-1 i=0 a i ϕ r ∈ E.
The condition that u commutes with ϕ yields d-1 i=0 (a q ia i )ϕ r ϕ = 0. Hence, the endomorphism d-1 i=0 (a q ia i )ϕ r is zero on the image of ϕ. Since D is étale, d-1 i=0 (a q ia i )ϕ r is zero, and since (id, ϕ r , . . . , ϕ (d-1)r ) is a basis of the commutant of ϕ r over F q r , a q i = a i for all 0 ≤ i ≤ d -1, so u ∈ F q [ϕ r ]. Hence E has dimension d over F q , and it is isomorphic to F q d . Proposition 2.5.2. Let Q ∈ F q [Y ] be a monic irreducible polynomial of degree d. Then the number of monic polynomials P ∈ F q r [X, σ] such that Ψ(P ) = Q is q dr -1 q d -1 .

Proof. By Corollary 2.4.5, it is enough to compute the number of polynomials P similar to a given P 0 such that Ψ(P ) = Q. Let P be such a polynomial. Since Q is irreducible, so is P , and therefore the ϕ-module D P is simple. We already know that any polynomial similar to P appears as a semi-characteristic polynomial of ϕ. Now we want to characterize the nonzero x, y ∈ D P such that χ ϕ,x = χ ϕ,y . We claim that these are the nonzero x, y such that y = u(x) for some u ∈ End(D P ). Indeed, it this is the case, then χ ϕ,x (ϕ)(y) = u(χ ϕ,x (ϕ)(x)) = 0, so χ ϕ,y = χ ϕ,x . Conversely, if χ ϕ,x = χ ϕ,y then the map x → y defines an automorphism of F q r -vector space of D P that is ϕ-equivariant thanks to this relation. This shows, using Lemma 2.5.1, that there is a natural bijection between D P modulo the relation χ ϕ,x = χ ϕ,y and D P modulo the relation of End(D P )-colinearity.

Putting both parts together, we get the fact that {Monic polynomials similar to P } is in bijection with {End(D P )-lines in D P }, yielding the result.

Corollary 2.5.3. The number of monic irreducible polynomials of degree d in F q r [X, σ] is

q dr -1 d(q d -1) i|d µ i d q i ,
where µ is the Möbius function.

Proof. It follows directly from Corollary 2.4.5, Proposition 2.5.2 and the classical formula for the number of irreducible monic polynomials in F q [Y ], that can be for instance found in [LN94]. As mentioned before, this formula already appeared in [START_REF] Coulter | On decomposition of sub-linearized polynomials[END_REF].

2.6 A closer look at the structure of D P

In this section, we consider the whole structure of the ϕ-module D P instead of just looking at Ψ(P ).

We address two different problems that both need a careful look at the structure of a ϕ-module D, or equivalently of the associated representation. Note that Proposition 2.4.11 shows that when Ψ(P ) has no square factors, for each choice of an order of the similarity classes of the polynomials arising in a factorization of P , there is a unique factorization of P such that P has its factors in the chosen order. Therefore, there are exactly s! factorizations of P as a product of irreducible monic polynomials in this case. The starting point of our discussion is Proposition 1.4.5. We rewrite it in our context, adding the formulation coming from representation theory. Let P ∈ F q r [X, σ] be a monic polynomial with nonzero constant coefficient. There are natural bijections between the following sets:

(i) The monic irreducible right-divisors of P ;

(ii) The simple quotients of the ϕ-module D P ;

(iii) The irreducible subrepresentations of V P .

Remark 2.6.1. In this context, this result may sound surprising, because if V 0 = V ⊕s with V an irreducible representation of dimension d and s > r, V 0 has q ds -1 q d -1 distinct subrepresentations with irreducible quotient, whereas all the divisors of P are similar, and hence P has less than q dr -1 q d -1 monic irreducible right-divisors. There is no contradiction, however: the proposition just says that this case never happens, meaning that in this case V 0 is not some V P , or, equivalently, that the ϕ-module associated to V 0 cannot be generated by a single element if s ≥ r. We can give yet more precise information about whether there is a generator for a ϕ-module over a finite field: because of the equivalence of categories with the representations, the ϕ-module is a direct sum of ϕ-modules such that the composition factors of each summand are all the same, and the ϕ-module has a generator if and only if each of them has one. It remains to decide when a ϕ-module with isomorphic composition factors (that is, with semi-simplification isomorphic to a direct sum of copies of the same simple object) has a generator. We will introduce some definitions to discuss this matter. They will also be useful to count factorizations.

Generated ϕ-modules over finite fields

We recall that an endomorphism is in Jordan form if its matrix is block-diagonal, where the blocks have the following form:

         A I 0 . . . 0 0 A I . . . 0 0 0 . . . . . . . . . 0 . . . 0 . . . I 0 . . . . . . 0 A         
, where the characteristic polynomial of A is irreducible. These blocks are called the Jordan blocks, and the length of a Jordan block is the number of A in this writing (it is the length of the F q [Y ]module corresponding to the endomorphism whose matrix is the Jordan block). Note that if the characteristic polynomial of the endomorphism is split, the matrices A that appear in its Jordan form are 1-dimensional. Assume that the minimal polynomial µ g of g is a power of an irreducible polynomial π, say µ g = π t , with deg π = δ. Let W = F δ q endowed with the endomorphism whose matrix in the canonical basis is the companion matrix of π : any irreducible invariant subspace of g is isomorphic to W . We say that g has type (t 1 , . . . , t m ) if t 1 ≥ • • • ≥ t m and the Jordan blocks of (the Jordan form of) g have lengths t 1 , . . . , t m . Of course, t = t 1 . In general, if g has type (t 1 , . . . , t m ), then the map induced by g on any quotient of V by an irreducible invariant subspace has type (t ′ 1 , . . . , t ′ m ) where t ′ i = t i except for one i for which t ′ i = t i -1 (or possibly m ′ = m -1 when t m = 1).

Lemma 2.6.2. Let D be an étale ϕ-module over F q r . Assume all the composition factors of D are isomorphic. Then D has a generator if and only if the number of Jordan blocks of the representation V associated to D is ≤ r.

Proof. Since all the composition factors of D are isomorphic, it makes sense to talk about the type of the associated representation V , on which the Frobenius acts by g. The proof is done by induction on the type of g. The possible types for the considered endomorphisms have the form (t 1 , . . . , t s ) with s ≤ r by hypothesis. We complete the notation with zeros in order that the type is denoted by a r-tuple (t 1 , . . . , t s , 0, . . . , 0). We order the types with respect to the lexicographical order. If g has type (1, 0, . . . , 0), then D is simple, so it has a generator. Now assume g has type (t 1 , . . . , t s , 0, . . . , 0). If every simple sub-ϕ-module of D is a direct factor of D, then g has type (1, . . . , 1, 0, . . . , 0), and D = D ⊕s 0 where D 0 is the only composition factor of D. But we know that D ⊕s 0 has a generator since it is a quotient of D ⊕r 0 which has one. Now, if D has a simple subobject D 0 that is not a direct factor, then we have an exact sequence 0 → D 0 → D → D ′ → 0 that is not split, and where the representation V ′ associated to D ′ has a smaller type than g. By induction hypothesis, there exists some x 0 ∈ D ′ such that D ′ is generated by x 0 . Let x be any lift of x 0 in D, and let D x be the sub-ϕ-module of D generated by x. If D x ∩ D 0 = {0}, then x 0 → x gives a splitting, which is not possible. Hence D 0 ⊂ D x , and D x = D, so D has a generator.

Counting factorizations

Now let us consider the problem of counting factorizations of a monic polynomial P ∈ F q r [X, σ] as a product of monic irreducible polynomials. The problem is reduced to that of computing the number of Jordan-Hölder sequences for an endomorphism g of an F q -vector space V . As before, first assume that the minimal polynomial µ g of g is a power of the irreducible polynomial π, say µ g = π t , with deg π = δ, and let W = F δ q endowed with the endomorphism whose matrix in the canonical basis is the companion matrix of π. There are q δm -1 q δ -1 irreducible invariant subspaces for g because the intersection of such an invariant subspace with a Jordan block must be the only irreducible invariant subspace of this block, or zero, so Hom(W, V ) = Hom(W, W ⊕m ). We want know how many quotients of V by an irreducible invariant subspace there are for each given possible type.

Lemma 2.6.3. Let (t 1 , . . . , t m ) be the type of g. Let 1 ≤ i ≤ m such that i = m or t i > t i+1 . Let i 0 be the smallest j such that t j = t i . Then there are q δ(i-1) + q δi + • • • + q δ(i0-1) invariant irreducible subspaces of V such that the quotient has type (t 1 , . . . , t i -1, t i+1 , . . . , t m ) (or (t 1 , . . . , t m-1 ) if i = m and t m = 1).

Proof. Denote by (e 1,1 , . . . , e 1,δ , e 2,1 , . . . , e 2,δ , . . . ) a basis of V in which the matrix of g has Jordan form. More precisely, for all 1 ≤ i ≤ m, and for all 1 ≤ j ≤ t i and 1 ≤ l ≤ δ, we have g(e j,l ) = e j,l+1 if (j, l) is not of the shape (j, 1) for some integer j ≥ 2, or of the shape (j, δ) for some integer j ≥ 1, g(e j,1 ) = e δu,δ + e δu+1,2 if j ≥ 2, and g(e j,δ ) = δ l=1 a l e j,l , where

δ l=1 a l Y l-1 ∈ F q [Y
] is an irreducible polynomial that does not depend of j (it is the characteristic polynomial of the induced endomorphism on any irreducible invariant subspace). There are i 0 -1 Jordan blocks of g whose length is greater than the length of the i-th block. For λ = (λ 1,1 , . . . , λ 1,δ , . . . , λ i0-1,δ ) ∈ F δ(i0-1) q , let v λ = e i0,1 + i0-1 j=1 δ l=1 λ j,l e j,l . Since two such vectors v λ , v µ are not colinear, they generate distinct invariant subspaces V λ , V µ , which are clearly isomorphic to W . Moreover, the quotient V /V λ has the same type as V /V (0) because the map V → V that sends e i0,1 to v λ and is the identity outside the invariant subspace generated by e i0,1 is an isomorphism (its matrix is upper triangular). One can build the same way invariant subspaces with quotients of the same type as generated by vectors of the shape e i0+1,1 + i0 j=1 δ l=1 λ j,l e j,l , . . . , e i,1 + i-1 j=1 δ l=1 λ j,l e j,l . There are exactly q δi0-1 + • • • + q δi-1 invariant subspaces that are built in this way. Doing such constructions for each i ′ satisfying the hypotheses of the lemma, we get exactly q δm -1 q δ -1 irreducible invariant subspaces, which means all of them. Among these subspaces, the ones for which the quotient has the requested shape are exactly the q δi0-1 + • • • + q δi-1 built for the first i we considered. This proves the lemma.

In order to compute the number of Jordan-Hölder sequences of g, consider the following diagram:

1 q δ . . . q δ(m-1) such that

• either m ′ = m -1, t ′ j = t j for 1 ≤ j ≤ m -1, if t m = 1;

• or m ′ = m, t ′ j = t j for all j = i, with 1 ≤ i ≤ m such that t i > t i+1 .

To such a path γ, we affect a weight w(γ), which is the sum of the coefficients written above the cells of the first table containing the same number t i as the cell whose coefficient was lowered in the second table. Here is an example of a table and all the admissible paths with the corresponding weights:

In general, we do not know any simple formula for this computation (except in some particular cases that we shall discuss below), but a recursive algorithm can be used to compute the result. Given a table with coefficients (t 1 , . . . t m ), we need to compute the values associated to all tables that can be built out of this table through an admissible path. There are at most t 1 . . . t m such tables. According to Remark 2.6.1, there are at most r Jordan blocks for g. Using the notations above, this means m ≤ r. Moreover, m i=1 δt i = dim V , so that τ ≤ dim V δ . Then, by the arithmetic-geometric inequality, t 1 . . . t m ≤ dim V δ r , so the computation of the number of Jordan-Hölder sequences of g can be done in polynomial time in the dimension of V , when r is fixed.

Example 2.6.4. Let us take a closer look at one particular example: assume that the type of g is (1, . . . , 1) (m terms). Then there is only one admissible path γ, that leads to (1, . . . , 1) (m -1 terms), and its weight is q mδ -1 q δ -1 . Hence the number of Jordan-Hölder sequences of g is m j=1

q δj -1 q δ -1 = [m] q δ !, the q δ -factorial of m.

Example 2.6.5. Let us look at an actual example. Let q = 7, r = 2, with F 7 2 defined as F 7 [Y ]/(Y 2 -Y + 3), and let ω be the class of Y in F 7 2 . Consider the polynomial P = X 6 + ω 3 X 5 + ω 17 X 4 + ω 3 X 3 + ω 27 X 2 + ω 35 X + ω 36 . The Jordan form of the matrix of ϕ 2 on D P is

         
0 -4 0 0 0 0 1 -1 0 0 0 0 0 0 0 -4 0 0 0 0 1 -1 1 0 0 0 0 0 0 -4 0 0 0 0 1 -1

         
, so the endomorphism g has type (2, 1) with 2-dimensional irreducible blocks. We write the following diagram with all the admissible paths and their weights:

1 7 2 2 1 1 } } { { { { { { { { 7 2 > > > > > > > > > 1 7 2 1 1 1+7 2 1 2 1 1 1 O O O 1 1 O O O 1 + 7 2 + 7 2 = 1 + 7 2 + 7 2
This shows that the number of factorizations of P as a product of monic irreducible polynomials is 99. An exhaustive research of all the factorizations with Magma gives the same result, but takes around one minute, whereas this computation is instantaneous. Now, we need to look at the general case, with no further assumption on the minimal polynomial of g. In this case, by the Chinese remainders Theorem, V is a direct sum of invariant subspaces on which the induced endomorphisms have minimal polynomial that is a power of an irreducible. Here, the type of g is defined again as the data of ((W 1 , T 1 ), . . . , (W s , T s )) where the W l 's are the distinct classes of irreducible invariant subspaces of V , and the T l 's are the tables representing the types of the endomorphisms induced on the corresponding subspaces of V . The notion of admissible path can be defined as previously.

Proposition 2.6.6. Let g be an endomorphism of an F q -vector space V . Assume that the type of g is ((W 1 , T 1 ), . . . , (W s , T s )). Denote by δ i the dimension of W i , and by τ i the sum of the coefficients in table T i . Then the number of Jordan-Hölder sequences of g is

(τ 1 + • • • + τ s )! τ 1 ! • • • τ s ! (Γ1,...,Γs) w(Γ 1 ) • • • w(Γ s ),
the product being taken over all the s-uples (Γ 1 , . . . , Γ s ) of admissible path sequences ending at the empty tables.

Proof. From a chain of admissible paths ending at ((W 1 , ∅), . . . , (W s , ∅)), it is possible to extract its W l -part Γ l for all 1 ≤ l ≤ s. By definition, it is the sequence of all the paths involving a change in the table associated to W l . Such a chain is a sequence of admissible paths from T l ending at the empty table. It is clear that the weight of the path sequence is the product of the weights of the Γ l 's. Therefore, it does not depend on the way the Γ l 's were combined together. The admissible path sequences that end at ((W 1 , ∅), . . . , (W s , ∅)) are all the different ways to recombine admissible path sequences from all the (W i , T i ) to the empty table. The weight of such a sequence is the product of the weights of the W l -parts. There are as many recombinations as anagrams of a word that includes τ l times the letter W l for all 1 ≤ l ≤ s, τ l being the sum of the integers appearing in T l . The result then follows directly from the previous discussion an the fact that the

Contents1

  The semi-characteristic polynomial of a ϕ-module 3 1.1 Skew polynomials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 1.2 Definition of the semi-characteristic polynomial . . . . . . . . . . . . . . . . . . . . 4 1.3 Basic properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 1.4 Semi-characteristic polynomials and sub-ϕ-modules . . . . . . . . . . . . . . . . . . 10 2 Skew polynomials and ϕ-modules over finite fields 12 2.1 Galois representations and ϕ-modules . . . . . . . . . . . . . . . . . . . . . . . . . 12 2.2 The splitting field of a linearized polynomial . . . . . . . . . . . . . . . . . . . . . . 14 2.3 Optimal bound of a skew polynomial . . . . . . . . . . . . . . . . . . . . . . . . . . 15 2.4 The map Ψ and factorizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 2.5 Counting irreducible polynomials . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 2.6 A closer look at the structure of D P . . . . . . . . . . . . . . . . . . . . . . . . . . 20 2.6.1 Generated ϕ-modules over finite fields . . . . . . . . . . . . . . . . . . . . . 21 2.6.2 Counting factorizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

  Corollary 1.4.3. Let D be an étale ϕ-module over K of dimension d and x ∈ D. Assume that the sub-ϕ-module D x generated by x has dimension r ≤ d. Denote by ϕ x the map induced by ϕ on D x . Then χ ϕ,x = χ ϕx,x X d-r .Proof. Apply Corollary 1.4.3 with D 1 the sub-ϕ-module generated by x. Since x is 0 in D 2 and D 2 has dimension dr, it remains to show that χ ϕ2,0 = X d-r . We will show by induction on d that if D is a ϕ-module of dimension d, then χ ϕ,0 = X d . Assume K is algebraically closed. If d = 1, a direct computation shows that χ ϕ,0 = X. For d ≥ 2, D is isomorphic to the ϕ-module whose matrix is identity since K is algebraically closed, so we can pick a sub-ϕ-module D 1 of D of dimension 1. By induction hypothesis and Proposition 1.4.2, we get the fact that χϕ,0 = X • X d-1 = X d . Theorem 1.4.4. Let 0 ⊂ D m ⊂ • • • ⊂ D 0 = D bea Jordan-Hölder sequence for the ϕ-module D. Denote by ϕ i the map induced by ϕ on D i , and by ϕ i the map induced by ϕ on D i /D i+1 for 0

  t 1 t 2 . . . t m with t 1 ≥ • • • ≥ t m .An admissible path is a transformation of this table into another table 1 q δ . . . q δ(m ′ -1) t ′

	1	t ′ 2	. . .	t ′ m ′

Proposition 2.4.1. The map Ψ is constant on similarity classes.

Proof. Assume that the ϕ-module D is generated by some x ∈ D, and let χ ϕ,x be the corresponding semi-characteristic polynomial of ϕ in the basis x, ϕ(x), . . . , ϕ d-1 (x). Then it is clear from the definition that Ψ(χ ϕ,x ) is the characteristic polynomial of ϕ r . Now, if two polynomials P and Q are similar, Q appears as the semi-characteristic polynomial of an element of D P . Hence, there exists x ∈ D P such that χ ϕ,x = Q. In this case, Ψ(Q) is the characteristic polynomial of ϕ r , which also equals Ψ(P ), so Ψ(P ) = Ψ(Q).

As we will see below, Ψ does not classify the similarity classes of polynomials, but it classifies the similarity classes of the factors appearing in the factorizations of a polynomial.

Proposition 2.4.2. Let P, Q ∈ F q r [X, σ] be two monic, nonconstant polynomials. Then

Proof. We translate Proposition 1.4.2 in terms of matrices: let (e 0 , . . . , e d-1 ) be the canonical basis of D P Q , and let y = Q(ϕ)(e 0 ). Let δ 1 = deg P and δ 2 = deg Q, then (y, ϕ(y), . . . , ϕ δ1-1 (y), e 0 , . . . , e δ2-1 ) is a basis of D P Q in which the matrix of ϕ is H = G P (⋆) 0 G Q , where G P (resp. G Q ) is the companion matrix of P (resp. of Q). Since this matrix is block-upper-triangular, the characteristic polynomial of Hσ(H)

On the other hand, since H is the matrix of ϕ in some basis, this characteristic polynomial is Ψ(P Q).

Proposition 2.4.3. Let P, Q ∈ F q r [X, σ] be two monic polynomials with P irreducible. Then P is similar to a right-divisor of Q if and only if Ψ(P ) divides Ψ(Q).

Proof. The case P = X is obvious, so we treat the case where P has nonzero constant coefficient.

If P is a right-divisor of Q, then Proposition 2.4.2 shows that Ψ(P ) divides Ψ(Q). Conversely, if Ψ(P ) divides Ψ(Q), we want to show that D P is a quotient of D Q , or equivalently, that V P is a subrepresentation of V Q . Let g be the Frobenius map x → x q r acting on V Q . We want to show that V Q has a subspace stable under g, of dimension deg P , on which the characteristic polynomial of g is Ψ(P ). By the Chinese remainders Theorem, we can assume that Ψ(Q) is a power of Ψ(P ). Indeed, this Theorem shows that D Q is the direct sum of subspaces stable under the action of g, and such that the characteristic polynomial of the action of g on each of these subspaces is a power of an irreducible polynomial. Now, assuming that Ψ(Q) is a power of Ψ(P ), we see that the Jordan form of g on V Q is a block-upper-triangular matrix whose diagonal blocks are all the same, equal to the companion matrix of Ψ(P ). Thus V P appears as a subrepresentation of V Q .

Corollary 2.4.4.

Then the similarity classes of irreducible factors of P appear in all possible orders in the factorizations of P .

Proof. If the similarity class of P 0 ∈ K[X, σ] appears in some factorization of P , then Ψ(P 0 ) is a divisor of Ψ(P ), and P has a right-divisor similar to P 0 . For the general case, it is easy to see that if Q ∈ F q r [X, σ] is any polynomial, then there exists Q similar to Q such that XQ = QX.

Corollary 2.4.5. Let P, Q ∈ F q r [X, σ] be two monic polynomials, with P irreducible. Then P and Q are similar if and only if Ψ(P ) = Ψ(Q).

Proof. Since we already know that Ψ is constant on similarity classes, it is enough to prove that if Ψ(P ) = Ψ(Q), then P and Q are similar. If Ψ(P ) = Ψ(Q), then Q has a right-divisor that is similar to P . Since P and Q have the same degree, P is similar to Q.

number of anagrams of a word that includes τ l times the letter W l is the multinomial coefficient

Example 2.6.7. Assume g has type ((W 1 , (t 1 )), . . . , (W s , (t s ))). It is easy to see that the only admissible path sequence for (W l , (t l )) has weight 1. Hence the number of Jordan-Hölder sequences of g is

The previous discussions also allow us to explain how to find all factorizations of a given polynomial P using Giesbrecht's algorithm. A first factorization of P yields a Jordan-Hölder sequence for the ϕ-module D P . All the simple sub-ϕ-modules of D P can be constructed as in the proof of Lemma 2.6.3. Any such simple sub-ϕ-module yields a factorization of P as P = P 1 Q, with P 1 irreducible as in Theorem 1.4.2. By performing left-euclidean division in F q r [X, σ] (which is possible because F q r is perfect), we can find Q, which we factor again by Giesbrecht's algorithm. For each factorization we find, it takes as many uses of Giesbrecht's algorithm as factors there are in the polynomial. Since Giesbrecht's algorithm is polynomial in the degree and in r, this quite naïve method gives all the factorizations of P with a complexity that is a polynomial in d and r times the number of factorizations of P .

Algorithm 2 AllFactorizations(P ) returns all the factorizations of P ∈ F q r [X, σ] Input: P ∈ F q r [X, σ], monic Output: List of all possible factorizations of P as product of monic irreducibles Compute a factorization of P , P = P 1 . . . P s if s = 1 then return [P ] else

Let G be the companion matrix of P , compute a Jordan-Hölder sequence for the ϕ-module that has matrix G as in Proposition 1.4.2 Let F P = [ ] for each isomorphism class C of submodules of D P do for x ∈ D P such that the submodule generated by x is in C do Compute F = AllFactorizations(χ -1 ϕ,x P ) Add (χ ϕ,x , F ) to F P , for all F ∈ F end for end for return F P end if Note that the same kind of methods could also be used to find all the factorizations of a polynomial with prescribed orders of the similarity classes of the factors appearing in P , or of just some of them.