Skip to content

Commit

Permalink
adapt to MC#1256
Browse files Browse the repository at this point in the history
  • Loading branch information
Tragicus committed Aug 19, 2024
1 parent 86bb4c9 commit 73d4a14
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions refinements/karatsuba.v
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ rewrite [p in RHS](rdivp_eq (monicXn _ m)) [q in RHS](rdivp_eq (monicXn _ m)).
rewrite /shift_op /shift_polyR /shiftp /implem /implem_nat /implem_id.
simpC.
rewrite !ih !(mulrDl, mulrDr, mulNr) mulnC exprM.
rewrite -addrA -addrA -opprD [X in X + _ - _]addrC [in LHS]addrACA addrK.
by rewrite !(commr_polyXn, mulrA, addrA).
rewrite -[in X in X + _]addrA -opprD [X in X + _ - _]addrC [in LHS]addrACA.
by rewrite addrK !(commr_polyXn, mulrA, addrA).
Qed.

Lemma karatsubaE (p q : {poly R}) : karatsuba (N:=nat) p q = p * q.
Expand Down
4 changes: 2 additions & 2 deletions theory/dvdring.v
Original file line number Diff line number Diff line change
Expand Up @@ -1792,8 +1792,8 @@ HB.builders Context R of IntegralDomain_isEuclidean R.
rewrite (eqd_trans (gcdrE _ _)) ?(eqd_trans (ihn' _ _)) //;
do ?by rewrite -ltnS (leq_trans (mod_spec _ _)) ?b0 //.
rewrite mulrBl addrA [v * a + _]addrC -mulrA -addrA -mulrBr /div b0.
case: edivP ihn'=> /= q r.
move/eqP; rewrite addrC -subr_eq; move/eqP=>->.
case: edivP ihn'=> /= q r /eqP.
rewrite [_ + r]addrC -subr_eq; move/eqP=>->.
by rewrite b0 /= => nrb; apply; rewrite -ltnS (leq_trans nrb).
Qed.

Expand Down

0 comments on commit 73d4a14

Please sign in to comment.