End HornerMx.
Prenex Implicits horner_mx powers_mx.
Section CharPoly.
Variables (R : ringType) (n : nat) (A : 'M[R]_n).
Implicit Types p q : {poly R}.
Definition char_poly_mx := 'X%:M - map_mx (@polyC R) A.
Definition char_poly := \det char_poly_mx.
Let diagA := [seq A i i | i : 'I_n].
Let size_diagA : size diagA = n.

(* Specifications: *)
Lemma size_char_poly : size char_poly = n.+1.
Lemma char_poly_monic : char_poly \is monic.
Lemma char_poly_trace : n > 0 -> char_poly`_n.-1 = - \tr A.
Lemma char_poly_det : char_poly`_0 = (- 1) ^+ n * \det A.
End CharPoly.