Definition red (a : poly A0 eqA ltM) (P : list (poly A0 eqA ltM)) :=
  reducestar A A0 A1 eqA invA minusA multA divA eqA_dec n ltM ltM_dec P
    (s2p A A0 eqA n ltM a) (pO A n).Definition addEnd :
  poly A0 eqA ltM -> list (poly A0 eqA ltM) -> list (poly A0 eqA ltM).

(* Specifications: *)
Theorem addEnd_cons : forall (a b : poly A0 eqA ltM) (aL : list (poly A0 eqA ltM)), In a (addEnd b aL) -> a = b \/ In a aL.
Theorem addEnd_id1 : forall (a : poly A0 eqA ltM) (aL : list (poly A0 eqA ltM)), In a (addEnd a aL).
Theorem addEnd_id2 : forall (a b : poly A0 eqA ltM) (aL : list (poly A0 eqA ltM)), In a aL -> In a (addEnd b aL).
Lemma addEnd_app : forall (a : poly A0 eqA ltM) (P : list (poly A0 eqA ltM)), addEnd a P = P ++ a :: nil.