Section BuchRed.
Load "hCoefStructure".
Load "hOrderStructure".
Load "hBuch".
intros L p q H; apply Cb_incl with (1 := cs) (P := addEnd A A0 eqA n ltM p L);
auto.
elim L; simpl in |- *; auto.
intros a l H0 a0 H1; elim H1; clear H1; intros H1; auto.
case (H0 a0); auto.
Qed.
intros L p q H; apply Cb_incl with (1 := cs) (P := p :: L); auto.
elim L; simpl in |- *; auto.
intros a l H0 a0 H1; elim H1; clear H1; intros H1; auto.
case H1; auto.
Qed.
intros L p q H H0.
apply Cb_trans with (1 := cs) (b := p); auto.
apply Cb_cons_addEnd; auto.
Qed.
intros p L; unfold nf, LetP in |- *; auto.
case
(Reducef A A0 A1 eqA plusA invA minusA multA divA cs eqA_dec n ltM ltM_dec
os L p); simpl in |- *; auto.
intros x0; case x0; simpl in |- *.
intros x c H'.
change
(CombLinear A A0 eqA plusA multA eqA_dec n ltM ltM_dec
(p :: L)
(mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM x c)) x))
in |- *.
apply CombLinear_mults1 with (1 := cs); auto.
apply unit_nZ with (1 := cs); auto.
apply reducestar_cb1 with (1 := cs); auto.
Qed.
intros L1 L2 H' q; case q; simpl in |- *.
intros x H'0 H'1.
apply CombLinear_compo with (1 := cs) (L1 := L1); auto.
intros q0 H'2.
case inPolySet_inv1 with (1 := H'2); auto.
intros q1 H; elim H; intros H0 H1; clear H.
lapply (H' q1); [ intros H'6 | idtac ]; auto.
generalize H'6 H1; case q1; simpl in |- *; auto.
intros x0 H'5 H'7 H'8; rewrite H'8; auto.
Defined.
intros p L; unfold nf in |- *.
case
(Reducef A A0 A1 eqA plusA invA minusA multA divA cs eqA_dec n ltM ltM_dec
os L p); auto.
case p.
unfold LetP in |- *; intros x H' x0; case x0; simpl in |- *.
intros x1 c H'0.
change
(CombLinear A A0 eqA plusA multA eqA_dec n ltM ltM_dec
(mks A A0 eqA n ltM
(mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM x1 c)) x1)
(canonical_mults A A0 A1 eqA plusA invA minusA multA divA cs eqA_dec
n ltM os (unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM x1 c))
x1
(unit_nZ A A0 A1 eqA plusA invA minusA multA divA cs n ltM
(mks A A0 eqA n ltM x1 c)) c) :: L) x)
in |- *.
apply CombLinear_compo with (1 := cs) (L1 := mks A A0 eqA n ltM x1 c :: L);
auto.
change
(CombLinear A A0 eqA plusA multA eqA_dec n ltM ltM_dec
(mks A A0 eqA n ltM x1 c :: L)
(s2p A A0 eqA n ltM (mks A A0 eqA n ltM x H')))
in |- *.
apply reducestar_cb2 with (1 := cs); auto.
intros q H'1; inversion H'1; auto.
2: apply CombLinear_id with (1 := cs); auto.
2: apply inskip; auto.
generalize c H2; case x1; auto.
intros c0 H'2; inversion H'2.
intros a0 l c0 H'2.
cut
(~
zeroP (A:=A) A0 eqA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (a0 :: l) c0)));
[ intros nZu | idtac ]; auto.
apply
CombLinear_1
with
(a := divTerm (A:=A) (A0:=A0) (eqA:=eqA) divA (n:=n)
(T1 A1 n)
(b:=unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (pX a0 l) c0))
nZu)
(p := pO A n)
(q := mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (pX a0 l) c0))
(pX a0 l)); auto.
simpl in |- *; auto.
change
(inPolySet A A0 eqA n ltM
(pX
(multTerm (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (pX a0 l) c0)) a0)
(mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (pX a0 l) c0)) l))
(exist (fun a1 => canonical A0 eqA ltM a1)
(pX
(multTerm (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (a0 :: l) c0))
a0)
(mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (a0 :: l) c0))
l))
(canonical_mults A A0 A1 eqA plusA invA minusA multA divA cs eqA_dec
n ltM os
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (pX a0 l) c0))
(pX a0 l)
(unit_nZ _ _ _ _ _ _ _ _ _ cs _ ltM
(mks A A0 eqA n ltM (pX a0 l) c0)) c0) :: L))
in |- *.
apply incons; auto.
apply CombLinear_0; auto.
apply
(eqp_trans _ _ _ _ _ _ _ _ _ cs n)
with
(y := mults (A:=A) multA (n:=n)
(divTerm (A:=A) (A0:=A0) (eqA:=eqA) divA (n:=n)
(T1 A1 n)
(b:=unit A A0 A1 eqA divA n ltM
(mks A A0 eqA n ltM (a0 :: l) c0)) nZu)
(mults (A:=A) multA (n:=n)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (a0 :: l) c0))
(a0 :: l))); auto.
2: apply (eqp_sym _ _ _ _ _ _ _ _ _ cs n); auto.
apply
(eqp_trans _ _ _ _ _ _ _ _ _ cs n)
with
(y := mults (A:=A) multA (n:=n)
(multTerm (A:=A) multA (n:=n)
(divTerm (A:=A) (A0:=A0) (eqA:=eqA) divA (n:=n)
(T1 A1 n)
(b:=unit A A0 A1 eqA divA n ltM
(mks A A0 eqA n ltM (a0 :: l) c0)) nZu)
(unit A A0 A1 eqA divA n ltM (mks A A0 eqA n ltM (a0 :: l) c0)))
(a0 :: l)); auto.
apply
(eqp_trans _ _ _ _ _ _ _ _ _ cs n)
with (y := mults (A:=A) multA (n:=n) (T1 A1 n) (a0 :: l));
auto.
rewrite H'2; auto.
apply (eqp_sym _ _ _ _ _ _ _ _ _ cs n); auto.
apply mults_comp with (1 := cs); auto.
apply divTerm_on_eqT with (1 := cs); auto.
apply (eqT_sym A n); auto.
apply unit_T1; auto.
apply unit_nZ with (1 := cs); auto.
Qed.

Theorem zerop_elim_Cb :
forall (L : list (poly A0 eqA ltM)) (p q : poly A0 eqA ltM),
zerop A A0 eqA n ltM p ->
Cb A A0 eqA plusA multA eqA_dec n ltM ltM_dec q (p :: L) ->
Cb A A0 eqA plusA multA eqA_dec n ltM ltM_dec q L.