algebra.covariant_and_contravariantMathlib.Algebra.CovariantAndContravariant

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

refactor(data/set/intervals/monotone): split (#17893)

Also generalize&golf monotone_on.exists_monotone_extension and rename order.monotone to order.monotone.basic.

Lean 4 version is leanprover-community/mathlib4#947

Diff
@@ -6,7 +6,7 @@ Authors: Damiano Testa
 
 import algebra.group.defs
 import order.basic
-import order.monotone
+import order.monotone.basic
 
 /-!
 

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(first ported)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -173,7 +173,7 @@ theorem Group.covariant_iff_contravariant [Group N] :
   refine' ⟨fun h a b c bc => _, fun h a b c bc => _⟩
   · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c]
     exact h a⁻¹ bc
-  · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c] at bc 
+  · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c] at bc
     exact h a⁻¹ bc
 #align group.covariant_iff_contravariant Group.covariant_iff_contravariant
 #align add_group.covariant_iff_contravariant AddGroup.covariant_iff_contravariant
@@ -196,7 +196,7 @@ theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
   refine' ⟨fun h a b c bc => _, fun h a b c bc => _⟩
   · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a]
     exact h a⁻¹ bc
-  · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a] at bc 
+  · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a] at bc
     exact h a⁻¹ bc
 #align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swap
 #align add_group.covariant_swap_iff_contravariant_swap AddGroup.covariant_swap_iff_contravariant_swap
Diff
@@ -3,9 +3,9 @@ Copyright (c) 2021 Damiano Testa. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
 -/
-import Mathbin.Algebra.Group.Defs
-import Mathbin.Order.Basic
-import Mathbin.Order.Monotone.Basic
+import Algebra.Group.Defs
+import Order.Basic
+import Order.Monotone.Basic
 
 #align_import algebra.covariant_and_contravariant from "leanprover-community/mathlib"@"448144f7ae193a8990cb7473c9e9a01990f64ac7"
 
Diff
@@ -365,21 +365,17 @@ theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
 -/
 
-#print covariant_flip_mul_iff /-
 @[to_additive]
-theorem covariant_flip_mul_iff [CommSemigroup N] :
+theorem covariant_flip_hMul_iff [CommSemigroup N] :
     Covariant N N (flip (· * ·)) r ↔ Covariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
-#align covariant_flip_mul_iff covariant_flip_mul_iff
+#align covariant_flip_mul_iff covariant_flip_hMul_iff
 #align covariant_flip_add_iff covariant_flip_add_iff
--/
 
-#print contravariant_flip_mul_iff /-
 @[to_additive]
-theorem contravariant_flip_mul_iff [CommSemigroup N] :
+theorem contravariant_flip_hMul_iff [CommSemigroup N] :
     Contravariant N N (flip (· * ·)) r ↔ Contravariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
-#align contravariant_flip_mul_iff contravariant_flip_mul_iff
+#align contravariant_flip_mul_iff contravariant_flip_hMul_iff
 #align contravariant_flip_add_iff contravariant_flip_add_iff
--/
 
 @[to_additive]
 instance contravariant_hMul_lt_of_covariant_hMul_le [Mul N] [LinearOrder N]
@@ -398,28 +394,28 @@ instance covariant_hMul_lt_of_contravariant_hMul_le [Mul N] [LinearOrder N]
 @[to_additive]
 instance covariant_swap_hMul_le_of_covariant_hMul_le [CommSemigroup N] [LE N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (swap (· * ·)) (· ≤ ·)
-    where elim := (covariant_flip_mul_iff N (· ≤ ·)).mpr CovariantClass.elim
+    where elim := (covariant_flip_hMul_iff N (· ≤ ·)).mpr CovariantClass.elim
 #align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_hMul_le_of_covariant_hMul_le
 #align covariant_swap_add_le_of_covariant_add_le covariant_swap_add_le_of_covariant_add_le
 
 @[to_additive]
 instance contravariant_swap_hMul_le_of_contravariant_hMul_le [CommSemigroup N] [LE N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (swap (· * ·)) (· ≤ ·)
-    where elim := (contravariant_flip_mul_iff N (· ≤ ·)).mpr ContravariantClass.elim
+    where elim := (contravariant_flip_hMul_iff N (· ≤ ·)).mpr ContravariantClass.elim
 #align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_hMul_le_of_contravariant_hMul_le
 #align contravariant_swap_add_le_of_contravariant_add_le contravariant_swap_add_le_of_contravariant_add_le
 
 @[to_additive]
 instance contravariant_swap_hMul_lt_of_contravariant_hMul_lt [CommSemigroup N] [LT N]
     [ContravariantClass N N (· * ·) (· < ·)] : ContravariantClass N N (swap (· * ·)) (· < ·)
-    where elim := (contravariant_flip_mul_iff N (· < ·)).mpr ContravariantClass.elim
+    where elim := (contravariant_flip_hMul_iff N (· < ·)).mpr ContravariantClass.elim
 #align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_hMul_lt_of_contravariant_hMul_lt
 #align contravariant_swap_add_lt_of_contravariant_add_lt contravariant_swap_add_lt_of_contravariant_add_lt
 
 @[to_additive]
 instance covariant_swap_hMul_lt_of_covariant_hMul_lt [CommSemigroup N] [LT N]
     [CovariantClass N N (· * ·) (· < ·)] : CovariantClass N N (swap (· * ·)) (· < ·)
-    where elim := (covariant_flip_mul_iff N (· < ·)).mpr CovariantClass.elim
+    where elim := (covariant_flip_hMul_iff N (· < ·)).mpr CovariantClass.elim
 #align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_hMul_lt_of_covariant_hMul_lt
 #align covariant_swap_add_lt_of_covariant_add_lt covariant_swap_add_lt_of_covariant_add_lt
 
Diff
@@ -381,108 +381,88 @@ theorem contravariant_flip_mul_iff [CommSemigroup N] :
 #align contravariant_flip_add_iff contravariant_flip_add_iff
 -/
 
-#print contravariant_mul_lt_of_covariant_mul_le /-
 @[to_additive]
-instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
+instance contravariant_hMul_lt_of_covariant_hMul_le [Mul N] [LinearOrder N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (· * ·) (· < ·)
     where elim := (covariant_le_iff_contravariant_lt N N (· * ·)).mp CovariantClass.elim
-#align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_le
+#align contravariant_mul_lt_of_covariant_mul_le contravariant_hMul_lt_of_covariant_hMul_le
 #align contravariant_add_lt_of_covariant_add_le contravariant_add_lt_of_covariant_add_le
--/
 
-#print covariant_mul_lt_of_contravariant_mul_le /-
 @[to_additive]
-instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
+instance covariant_hMul_lt_of_contravariant_hMul_le [Mul N] [LinearOrder N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
     where elim := (covariant_lt_iff_contravariant_le N N (· * ·)).mpr ContravariantClass.elim
-#align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_le
+#align covariant_mul_lt_of_contravariant_mul_le covariant_hMul_lt_of_contravariant_hMul_le
 #align covariant_add_lt_of_contravariant_add_le covariant_add_lt_of_contravariant_add_le
--/
 
-#print covariant_swap_mul_le_of_covariant_mul_le /-
 @[to_additive]
-instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
+instance covariant_swap_hMul_le_of_covariant_hMul_le [CommSemigroup N] [LE N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (swap (· * ·)) (· ≤ ·)
     where elim := (covariant_flip_mul_iff N (· ≤ ·)).mpr CovariantClass.elim
-#align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_mul_le_of_covariant_mul_le
+#align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_hMul_le_of_covariant_hMul_le
 #align covariant_swap_add_le_of_covariant_add_le covariant_swap_add_le_of_covariant_add_le
--/
 
-#print contravariant_swap_mul_le_of_contravariant_mul_le /-
 @[to_additive]
-instance contravariant_swap_mul_le_of_contravariant_mul_le [CommSemigroup N] [LE N]
+instance contravariant_swap_hMul_le_of_contravariant_hMul_le [CommSemigroup N] [LE N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (swap (· * ·)) (· ≤ ·)
     where elim := (contravariant_flip_mul_iff N (· ≤ ·)).mpr ContravariantClass.elim
-#align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_mul_le_of_contravariant_mul_le
+#align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_hMul_le_of_contravariant_hMul_le
 #align contravariant_swap_add_le_of_contravariant_add_le contravariant_swap_add_le_of_contravariant_add_le
--/
 
-#print contravariant_swap_mul_lt_of_contravariant_mul_lt /-
 @[to_additive]
-instance contravariant_swap_mul_lt_of_contravariant_mul_lt [CommSemigroup N] [LT N]
+instance contravariant_swap_hMul_lt_of_contravariant_hMul_lt [CommSemigroup N] [LT N]
     [ContravariantClass N N (· * ·) (· < ·)] : ContravariantClass N N (swap (· * ·)) (· < ·)
     where elim := (contravariant_flip_mul_iff N (· < ·)).mpr ContravariantClass.elim
-#align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_mul_lt_of_contravariant_mul_lt
+#align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_hMul_lt_of_contravariant_hMul_lt
 #align contravariant_swap_add_lt_of_contravariant_add_lt contravariant_swap_add_lt_of_contravariant_add_lt
--/
 
-#print covariant_swap_mul_lt_of_covariant_mul_lt /-
 @[to_additive]
-instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
+instance covariant_swap_hMul_lt_of_covariant_hMul_lt [CommSemigroup N] [LT N]
     [CovariantClass N N (· * ·) (· < ·)] : CovariantClass N N (swap (· * ·)) (· < ·)
     where elim := (covariant_flip_mul_iff N (· < ·)).mpr CovariantClass.elim
-#align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_mul_lt_of_covariant_mul_lt
+#align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_hMul_lt_of_covariant_hMul_lt
 #align covariant_swap_add_lt_of_covariant_add_lt covariant_swap_add_lt_of_covariant_add_lt
--/
 
-#print LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le /-
 @[to_additive]
-instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSemigroup N]
+instance LeftCancelSemigroup.covariant_hMul_lt_of_covariant_hMul_le [LeftCancelSemigroup N]
     [PartialOrder N] [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
     where elim a b c bc := by
     cases' lt_iff_le_and_ne.mp bc with bc cb
     exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_right a).mpr cb⟩
-#align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le
+#align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_hMul_lt_of_covariant_hMul_le
 #align add_left_cancel_semigroup.covariant_add_lt_of_covariant_add_le AddLeftCancelSemigroup.covariant_add_lt_of_covariant_add_le
--/
 
-#print RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le /-
 @[to_additive]
-instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
+instance RightCancelSemigroup.covariant_swap_hMul_lt_of_covariant_swap_hMul_le
     [RightCancelSemigroup N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
     CovariantClass N N (swap (· * ·)) (· < ·)
     where elim a b c bc := by
     cases' lt_iff_le_and_ne.mp bc with bc cb
     exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_left a).mpr cb⟩
-#align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
+#align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_hMul_lt_of_covariant_swap_hMul_le
 #align add_right_cancel_semigroup.covariant_swap_add_lt_of_covariant_swap_add_le AddRightCancelSemigroup.covariant_swap_add_lt_of_covariant_swap_add_le
--/
 
-#print LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt /-
 @[to_additive]
-instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftCancelSemigroup N]
+instance LeftCancelSemigroup.contravariant_hMul_le_of_contravariant_hMul_lt [LeftCancelSemigroup N]
     [PartialOrder N] [ContravariantClass N N (· * ·) (· < ·)] :
     ContravariantClass N N (· * ·) (· ≤ ·)
     where elim a b c bc := by
     cases' le_iff_eq_or_lt.mp bc with h h
     · exact ((mul_right_inj a).mp h).le
     · exact (ContravariantClass.elim _ h).le
-#align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt
+#align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_hMul_le_of_contravariant_hMul_lt
 #align add_left_cancel_semigroup.contravariant_add_le_of_contravariant_add_lt AddLeftCancelSemigroup.contravariant_add_le_of_contravariant_add_lt
--/
 
-#print RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt /-
 @[to_additive]
-instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
+instance RightCancelSemigroup.contravariant_swap_hMul_le_of_contravariant_swap_hMul_lt
     [RightCancelSemigroup N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
     ContravariantClass N N (swap (· * ·)) (· ≤ ·)
     where elim a b c bc := by
     cases' le_iff_eq_or_lt.mp bc with h h
     · exact ((mul_left_inj a).mp h).le
     · exact (ContravariantClass.elim _ h).le
-#align right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
+#align right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt RightCancelSemigroup.contravariant_swap_hMul_le_of_contravariant_swap_hMul_lt
 #align add_right_cancel_semigroup.contravariant_swap_add_le_of_contravariant_swap_add_lt AddRightCancelSemigroup.contravariant_swap_add_le_of_contravariant_swap_add_lt
--/
 
 end Variants
 
Diff
@@ -2,16 +2,13 @@
 Copyright (c) 2021 Damiano Testa. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
-
-! This file was ported from Lean 3 source module algebra.covariant_and_contravariant
-! leanprover-community/mathlib commit 448144f7ae193a8990cb7473c9e9a01990f64ac7
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Algebra.Group.Defs
 import Mathbin.Order.Basic
 import Mathbin.Order.Monotone.Basic
 
+#align_import algebra.covariant_and_contravariant from "leanprover-community/mathlib"@"448144f7ae193a8990cb7473c9e9a01990f64ac7"
+
 /-!
 
 # Covariants and contravariants
Diff
@@ -133,22 +133,28 @@ class ContravariantClass : Prop where
 #align contravariant_class ContravariantClass
 -/
 
+#print rel_iff_cov /-
 theorem rel_iff_cov [CovariantClass M N μ r] [ContravariantClass M N μ r] (m : M) {a b : N} :
     r (μ m a) (μ m b) ↔ r a b :=
   ⟨ContravariantClass.elim _, CovariantClass.elim _⟩
 #align rel_iff_cov rel_iff_cov
+-/
 
 section flip
 
 variable {M N μ r}
 
+#print Covariant.flip /-
 theorem Covariant.flip (h : Covariant M N μ r) : Covariant M N μ (flip r) := fun a b c hbc =>
   h a hbc
 #align covariant.flip Covariant.flip
+-/
 
+#print Contravariant.flip /-
 theorem Contravariant.flip (h : Contravariant M N μ r) : Contravariant M N μ (flip r) :=
   fun a b c hbc => h a hbc
 #align contravariant.flip Contravariant.flip
+-/
 
 end flip
 
@@ -162,6 +168,7 @@ theorem act_rel_act_of_rel (m : M) {a b : N} (ab : r a b) : r (μ m a) (μ m b)
 #align act_rel_act_of_rel act_rel_act_of_rel
 -/
 
+#print Group.covariant_iff_contravariant /-
 @[to_additive]
 theorem Group.covariant_iff_contravariant [Group N] :
     Covariant N N (· * ·) r ↔ Contravariant N N (· * ·) r :=
@@ -173,14 +180,18 @@ theorem Group.covariant_iff_contravariant [Group N] :
     exact h a⁻¹ bc
 #align group.covariant_iff_contravariant Group.covariant_iff_contravariant
 #align add_group.covariant_iff_contravariant AddGroup.covariant_iff_contravariant
+-/
 
+#print Group.covconv /-
 @[to_additive]
 instance (priority := 100) Group.covconv [Group N] [CovariantClass N N (· * ·) r] :
     ContravariantClass N N (· * ·) r :=
   ⟨Group.covariant_iff_contravariant.mp CovariantClass.elim⟩
 #align group.covconv Group.covconv
 #align add_group.covconv AddGroup.covconv
+-/
 
+#print Group.covariant_swap_iff_contravariant_swap /-
 @[to_additive]
 theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
     Covariant N N (swap (· * ·)) r ↔ Contravariant N N (swap (· * ·)) r :=
@@ -192,13 +203,16 @@ theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
     exact h a⁻¹ bc
 #align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swap
 #align add_group.covariant_swap_iff_contravariant_swap AddGroup.covariant_swap_iff_contravariant_swap
+-/
 
+#print Group.covconv_swap /-
 @[to_additive]
 instance (priority := 100) Group.covconv_swap [Group N] [CovariantClass N N (swap (· * ·)) r] :
     ContravariantClass N N (swap (· * ·)) r :=
   ⟨Group.covariant_swap_iff_contravariant_swap.mp CovariantClass.elim⟩
 #align group.covconv_swap Group.covconv_swap
 #align add_group.covconv_swap AddGroup.covconv_swap
+-/
 
 section IsTrans
 
@@ -274,36 +288,46 @@ variable {α : Type _} {M N μ} [Preorder α] [Preorder N]
 
 variable {f : N → α}
 
+#print Covariant.monotone_of_const /-
 /-- The partial application of a constant to a covariant operator is monotone. -/
 theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M) : Monotone (μ m) :=
   fun a b ha => CovariantClass.elim m ha
 #align covariant.monotone_of_const Covariant.monotone_of_const
+-/
 
+#print Monotone.covariant_of_const /-
 /-- A monotone function remains monotone when composed with the partial application
 of a covariant operator. E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
     Monotone fun n => f (μ m n) :=
   hf.comp <| Covariant.monotone_of_const m
 #align monotone.covariant_of_const Monotone.covariant_of_const
+-/
 
+#print Monotone.covariant_of_const' /-
 /-- Same as `monotone.covariant_of_const`, but with the constant on the other side of
 the operator.  E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Monotone f) (m : N) : Monotone fun n => f (μ n m) :=
   hf.comp <| Covariant.monotone_of_const m
 #align monotone.covariant_of_const' Monotone.covariant_of_const'
+-/
 
+#print Antitone.covariant_of_const /-
 /-- Dual of `monotone.covariant_of_const` -/
 theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Antitone f) (m : M) :
     Antitone fun n => f (μ m n) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
 #align antitone.covariant_of_const Antitone.covariant_of_const
+-/
 
+#print Antitone.covariant_of_const' /-
 /-- Dual of `monotone.covariant_of_const'` -/
 theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Antitone f) (m : N) : Antitone fun n => f (μ n m) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
 #align antitone.covariant_of_const' Antitone.covariant_of_const'
+-/
 
 end Monotone
 
@@ -344,17 +368,21 @@ theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
 -/
 
+#print covariant_flip_mul_iff /-
 @[to_additive]
 theorem covariant_flip_mul_iff [CommSemigroup N] :
     Covariant N N (flip (· * ·)) r ↔ Covariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
 #align covariant_flip_mul_iff covariant_flip_mul_iff
 #align covariant_flip_add_iff covariant_flip_add_iff
+-/
 
+#print contravariant_flip_mul_iff /-
 @[to_additive]
 theorem contravariant_flip_mul_iff [CommSemigroup N] :
     Contravariant N N (flip (· * ·)) r ↔ Contravariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
 #align contravariant_flip_mul_iff contravariant_flip_mul_iff
 #align contravariant_flip_add_iff contravariant_flip_add_iff
+-/
 
 #print contravariant_mul_lt_of_covariant_mul_le /-
 @[to_additive]
@@ -374,34 +402,43 @@ instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
 #align covariant_add_lt_of_contravariant_add_le covariant_add_lt_of_contravariant_add_le
 -/
 
+#print covariant_swap_mul_le_of_covariant_mul_le /-
 @[to_additive]
 instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (swap (· * ·)) (· ≤ ·)
     where elim := (covariant_flip_mul_iff N (· ≤ ·)).mpr CovariantClass.elim
 #align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_mul_le_of_covariant_mul_le
 #align covariant_swap_add_le_of_covariant_add_le covariant_swap_add_le_of_covariant_add_le
+-/
 
+#print contravariant_swap_mul_le_of_contravariant_mul_le /-
 @[to_additive]
 instance contravariant_swap_mul_le_of_contravariant_mul_le [CommSemigroup N] [LE N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (swap (· * ·)) (· ≤ ·)
     where elim := (contravariant_flip_mul_iff N (· ≤ ·)).mpr ContravariantClass.elim
 #align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_mul_le_of_contravariant_mul_le
 #align contravariant_swap_add_le_of_contravariant_add_le contravariant_swap_add_le_of_contravariant_add_le
+-/
 
+#print contravariant_swap_mul_lt_of_contravariant_mul_lt /-
 @[to_additive]
 instance contravariant_swap_mul_lt_of_contravariant_mul_lt [CommSemigroup N] [LT N]
     [ContravariantClass N N (· * ·) (· < ·)] : ContravariantClass N N (swap (· * ·)) (· < ·)
     where elim := (contravariant_flip_mul_iff N (· < ·)).mpr ContravariantClass.elim
 #align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_mul_lt_of_contravariant_mul_lt
 #align contravariant_swap_add_lt_of_contravariant_add_lt contravariant_swap_add_lt_of_contravariant_add_lt
+-/
 
+#print covariant_swap_mul_lt_of_covariant_mul_lt /-
 @[to_additive]
 instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
     [CovariantClass N N (· * ·) (· < ·)] : CovariantClass N N (swap (· * ·)) (· < ·)
     where elim := (covariant_flip_mul_iff N (· < ·)).mpr CovariantClass.elim
 #align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_mul_lt_of_covariant_mul_lt
 #align covariant_swap_add_lt_of_covariant_add_lt covariant_swap_add_lt_of_covariant_add_lt
+-/
 
+#print LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le /-
 @[to_additive]
 instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSemigroup N]
     [PartialOrder N] [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
@@ -410,7 +447,9 @@ instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSem
     exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_right a).mpr cb⟩
 #align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le
 #align add_left_cancel_semigroup.covariant_add_lt_of_covariant_add_le AddLeftCancelSemigroup.covariant_add_lt_of_covariant_add_le
+-/
 
+#print RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le /-
 @[to_additive]
 instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
     [RightCancelSemigroup N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
@@ -420,7 +459,9 @@ instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
     exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_left a).mpr cb⟩
 #align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
 #align add_right_cancel_semigroup.covariant_swap_add_lt_of_covariant_swap_add_le AddRightCancelSemigroup.covariant_swap_add_lt_of_covariant_swap_add_le
+-/
 
+#print LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt /-
 @[to_additive]
 instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftCancelSemigroup N]
     [PartialOrder N] [ContravariantClass N N (· * ·) (· < ·)] :
@@ -431,7 +472,9 @@ instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftC
     · exact (ContravariantClass.elim _ h).le
 #align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt
 #align add_left_cancel_semigroup.contravariant_add_le_of_contravariant_add_lt AddLeftCancelSemigroup.contravariant_add_le_of_contravariant_add_lt
+-/
 
+#print RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt /-
 @[to_additive]
 instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
     [RightCancelSemigroup N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
@@ -442,6 +485,7 @@ instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mu
     · exact (ContravariantClass.elim _ h).le
 #align right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
 #align add_right_cancel_semigroup.contravariant_swap_add_le_of_contravariant_swap_add_lt AddRightCancelSemigroup.contravariant_swap_add_le_of_contravariant_swap_add_lt
+-/
 
 end Variants
 
Diff
@@ -169,7 +169,7 @@ theorem Group.covariant_iff_contravariant [Group N] :
   refine' ⟨fun h a b c bc => _, fun h a b c bc => _⟩
   · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c]
     exact h a⁻¹ bc
-  · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c] at bc
+  · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c] at bc 
     exact h a⁻¹ bc
 #align group.covariant_iff_contravariant Group.covariant_iff_contravariant
 #align add_group.covariant_iff_contravariant AddGroup.covariant_iff_contravariant
@@ -188,7 +188,7 @@ theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
   refine' ⟨fun h a b c bc => _, fun h a b c bc => _⟩
   · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a]
     exact h a⁻¹ bc
-  · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a] at bc
+  · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a] at bc 
     exact h a⁻¹ bc
 #align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swap
 #align add_group.covariant_swap_iff_contravariant_swap AddGroup.covariant_swap_iff_contravariant_swap
Diff
@@ -307,6 +307,7 @@ theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (s
 
 end Monotone
 
+#print covariant_le_of_covariant_lt /-
 theorem covariant_le_of_covariant_lt [PartialOrder N] :
     Covariant M N μ (· < ·) → Covariant M N μ (· ≤ ·) :=
   by
@@ -315,7 +316,9 @@ theorem covariant_le_of_covariant_lt [PartialOrder N] :
   · exact rfl.le
   · exact (h _ bc).le
 #align covariant_le_of_covariant_lt covariant_le_of_covariant_lt
+-/
 
+#print contravariant_lt_of_contravariant_le /-
 theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
     Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) :=
   by
@@ -323,18 +326,23 @@ theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
   rintro rfl
   exact lt_irrefl _ bc
 #align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_le
+-/
 
+#print covariant_le_iff_contravariant_lt /-
 theorem covariant_le_iff_contravariant_lt [LinearOrder N] :
     Covariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) :=
   ⟨fun h a b c bc => not_le.mp fun k => not_le.mpr bc (h _ k), fun h a b c bc =>
     not_lt.mp fun k => not_lt.mpr bc (h _ k)⟩
 #align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_lt
+-/
 
+#print covariant_lt_iff_contravariant_le /-
 theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
     Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·) :=
   ⟨fun h a b c bc => not_lt.mp fun k => not_lt.mpr bc (h _ k), fun h a b c bc =>
     not_le.mp fun k => not_le.mpr bc (h _ k)⟩
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
+-/
 
 @[to_additive]
 theorem covariant_flip_mul_iff [CommSemigroup N] :
@@ -348,19 +356,23 @@ theorem contravariant_flip_mul_iff [CommSemigroup N] :
 #align contravariant_flip_mul_iff contravariant_flip_mul_iff
 #align contravariant_flip_add_iff contravariant_flip_add_iff
 
+#print contravariant_mul_lt_of_covariant_mul_le /-
 @[to_additive]
 instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (· * ·) (· < ·)
     where elim := (covariant_le_iff_contravariant_lt N N (· * ·)).mp CovariantClass.elim
 #align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_le
 #align contravariant_add_lt_of_covariant_add_le contravariant_add_lt_of_covariant_add_le
+-/
 
+#print covariant_mul_lt_of_contravariant_mul_le /-
 @[to_additive]
 instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
     where elim := (covariant_lt_iff_contravariant_le N N (· * ·)).mpr ContravariantClass.elim
 #align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_le
 #align covariant_add_lt_of_contravariant_add_le covariant_add_lt_of_contravariant_add_le
+-/
 
 @[to_additive]
 instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
Diff
@@ -133,12 +133,6 @@ class ContravariantClass : Prop where
 #align contravariant_class ContravariantClass
 -/
 
-/- warning: rel_iff_cov -> rel_iff_cov is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) (r : N -> N -> Prop) [_inst_1 : CovariantClass.{u1, u2} M N μ r] [_inst_2 : ContravariantClass.{u1, u2} M N μ r] (m : M) {a : N} {b : N}, Iff (r (μ m a) (μ m b)) (r a b)
-but is expected to have type
-  forall (M : Type.{u2}) (N : Type.{u1}) (μ : M -> N -> N) (r : N -> N -> Prop) [_inst_1 : CovariantClass.{u2, u1} M N μ r] [_inst_2 : ContravariantClass.{u2, u1} M N μ r] (m : M) {a : N} {b : N}, Iff (r (μ m a) (μ m b)) (r a b)
-Case conversion may be inaccurate. Consider using '#align rel_iff_cov rel_iff_covₓ'. -/
 theorem rel_iff_cov [CovariantClass M N μ r] [ContravariantClass M N μ r] (m : M) {a b : N} :
     r (μ m a) (μ m b) ↔ r a b :=
   ⟨ContravariantClass.elim _, CovariantClass.elim _⟩
@@ -148,22 +142,10 @@ section flip
 
 variable {M N μ r}
 
-/- warning: covariant.flip -> Covariant.flip is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {r : N -> N -> Prop}, (Covariant.{u1, u2} M N μ r) -> (Covariant.{u1, u2} M N μ (flip.{succ u2, succ u2, 1} N N Prop r))
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} {μ : M -> N -> N} {r : N -> N -> Prop}, (Covariant.{u2, u1} M N μ r) -> (Covariant.{u2, u1} M N μ (flip.{succ u1, succ u1, 1} N N Prop r))
-Case conversion may be inaccurate. Consider using '#align covariant.flip Covariant.flipₓ'. -/
 theorem Covariant.flip (h : Covariant M N μ r) : Covariant M N μ (flip r) := fun a b c hbc =>
   h a hbc
 #align covariant.flip Covariant.flip
 
-/- warning: contravariant.flip -> Contravariant.flip is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {r : N -> N -> Prop}, (Contravariant.{u1, u2} M N μ r) -> (Contravariant.{u1, u2} M N μ (flip.{succ u2, succ u2, 1} N N Prop r))
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} {μ : M -> N -> N} {r : N -> N -> Prop}, (Contravariant.{u2, u1} M N μ r) -> (Contravariant.{u2, u1} M N μ (flip.{succ u1, succ u1, 1} N N Prop r))
-Case conversion may be inaccurate. Consider using '#align contravariant.flip Contravariant.flipₓ'. -/
 theorem Contravariant.flip (h : Contravariant M N μ r) : Contravariant M N μ (flip r) :=
   fun a b c hbc => h a hbc
 #align contravariant.flip Contravariant.flip
@@ -180,12 +162,6 @@ theorem act_rel_act_of_rel (m : M) {a b : N} (ab : r a b) : r (μ m a) (μ m b)
 #align act_rel_act_of_rel act_rel_act_of_rel
 -/
 
-/- warning: group.covariant_iff_contravariant -> Group.covariant_iff_contravariant is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N], Iff (Covariant.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2)))))) r) (Contravariant.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2)))))) r)
-but is expected to have type
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N], Iff (Covariant.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.425 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.427 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.425 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.427) r) (Contravariant.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.444 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.446 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.444 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.446) r)
-Case conversion may be inaccurate. Consider using '#align group.covariant_iff_contravariant Group.covariant_iff_contravariantₓ'. -/
 @[to_additive]
 theorem Group.covariant_iff_contravariant [Group N] :
     Covariant N N (· * ·) r ↔ Contravariant N N (· * ·) r :=
@@ -198,12 +174,6 @@ theorem Group.covariant_iff_contravariant [Group N] :
 #align group.covariant_iff_contravariant Group.covariant_iff_contravariant
 #align add_group.covariant_iff_contravariant AddGroup.covariant_iff_contravariant
 
-/- warning: group.covconv -> Group.covconv is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2)))))) r], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2)))))) r
-but is expected to have type
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.600 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.602 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.600 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.602) r], ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.619 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.621 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.619 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.621) r
-Case conversion may be inaccurate. Consider using '#align group.covconv Group.covconvₓ'. -/
 @[to_additive]
 instance (priority := 100) Group.covconv [Group N] [CovariantClass N N (· * ·) r] :
     ContravariantClass N N (· * ·) r :=
@@ -211,12 +181,6 @@ instance (priority := 100) Group.covconv [Group N] [CovariantClass N N (· * ·)
 #align group.covconv Group.covconv
 #align add_group.covconv AddGroup.covconv
 
-/- warning: group.covariant_swap_iff_contravariant_swap -> Group.covariant_swap_iff_contravariant_swap is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N], Iff (Covariant.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))))) r) (Contravariant.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))))) r)
-but is expected to have type
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N], Iff (Covariant.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.674 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.676 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.674 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.676)) r) (Contravariant.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.696 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.698 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.696 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.698)) r)
-Case conversion may be inaccurate. Consider using '#align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swapₓ'. -/
 @[to_additive]
 theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
     Covariant N N (swap (· * ·)) r ↔ Contravariant N N (swap (· * ·)) r :=
@@ -229,12 +193,6 @@ theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
 #align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swap
 #align add_group.covariant_swap_iff_contravariant_swap AddGroup.covariant_swap_iff_contravariant_swap
 
-/- warning: group.covconv_swap -> Group.covconv_swap is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))))) r], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toHasMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))))) r
-but is expected to have type
-  forall {N : Type.{u1}} {r : N -> N -> Prop} [_inst_2 : Group.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.855 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.857 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.855 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.857)) r], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.877 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.879 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (MulOneClass.toMul.{u1} N (Monoid.toMulOneClass.{u1} N (DivInvMonoid.toMonoid.{u1} N (Group.toDivInvMonoid.{u1} N _inst_2))))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.877 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.879)) r
-Case conversion may be inaccurate. Consider using '#align group.covconv_swap Group.covconv_swapₓ'. -/
 @[to_additive]
 instance (priority := 100) Group.covconv_swap [Group N] [CovariantClass N N (swap (· * ·)) r] :
     ContravariantClass N N (swap (· * ·)) r :=
@@ -316,23 +274,11 @@ variable {α : Type _} {M N μ} [Preorder α] [Preorder N]
 
 variable {f : N → α}
 
-/- warning: covariant.monotone_of_const -> Covariant.monotone_of_const is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} [_inst_2 : Preorder.{u2} N] [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))] (m : M), Monotone.{u2, u2} N N _inst_2 _inst_2 (μ m)
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} {μ : M -> N -> N} [_inst_2 : Preorder.{u1} N] [_inst_3 : CovariantClass.{u2, u1} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1485 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1487 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1485 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1487)] (m : M), Monotone.{u1, u1} N N _inst_2 _inst_2 (μ m)
-Case conversion may be inaccurate. Consider using '#align covariant.monotone_of_const Covariant.monotone_of_constₓ'. -/
 /-- The partial application of a constant to a covariant operator is monotone. -/
 theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M) : Monotone (μ m) :=
   fun a b ha => CovariantClass.elim m ha
 #align covariant.monotone_of_const Covariant.monotone_of_const
 
-/- warning: monotone.covariant_of_const -> Monotone.covariant_of_const is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))], (Monotone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Monotone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
-but is expected to have type
-  forall {M : Type.{u3}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u3, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1549 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1551 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1549 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1551)], (Monotone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : M), Monotone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
-Case conversion may be inaccurate. Consider using '#align monotone.covariant_of_const Monotone.covariant_of_constₓ'. -/
 /-- A monotone function remains monotone when composed with the partial application
 of a covariant operator. E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
@@ -340,12 +286,6 @@ theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Mo
   hf.comp <| Covariant.monotone_of_const m
 #align monotone.covariant_of_const Monotone.covariant_of_const
 
-/- warning: monotone.covariant_of_const' -> Monotone.covariant_of_const' is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toHasLe.{u1} N _inst_2))], (Monotone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Monotone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
-but is expected to have type
-  forall {N : Type.{u2}} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u2, u2} N N (Function.swap.{succ u2, succ u2, succ u2} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1631 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1633 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1631 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1633)], (Monotone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : N), Monotone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
-Case conversion may be inaccurate. Consider using '#align monotone.covariant_of_const' Monotone.covariant_of_const'ₓ'. -/
 /-- Same as `monotone.covariant_of_const`, but with the constant on the other side of
 the operator.  E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
@@ -353,24 +293,12 @@ theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (s
   hf.comp <| Covariant.monotone_of_const m
 #align monotone.covariant_of_const' Monotone.covariant_of_const'
 
-/- warning: antitone.covariant_of_const -> Antitone.covariant_of_const is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))], (Antitone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Antitone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
-but is expected to have type
-  forall {M : Type.{u3}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u3, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1713 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1715 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1713 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1715)], (Antitone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : M), Antitone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
-Case conversion may be inaccurate. Consider using '#align antitone.covariant_of_const Antitone.covariant_of_constₓ'. -/
 /-- Dual of `monotone.covariant_of_const` -/
 theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Antitone f) (m : M) :
     Antitone fun n => f (μ m n) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
 #align antitone.covariant_of_const Antitone.covariant_of_const
 
-/- warning: antitone.covariant_of_const' -> Antitone.covariant_of_const' is a dubious translation:
-lean 3 declaration is
-  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toHasLe.{u1} N _inst_2))], (Antitone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Antitone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
-but is expected to have type
-  forall {N : Type.{u2}} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u2, u2} N N (Function.swap.{succ u2, succ u2, succ u2} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1787 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1789 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1787 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1789)], (Antitone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : N), Antitone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
-Case conversion may be inaccurate. Consider using '#align antitone.covariant_of_const' Antitone.covariant_of_const'ₓ'. -/
 /-- Dual of `monotone.covariant_of_const'` -/
 theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Antitone f) (m : N) : Antitone fun n => f (μ n m) :=
@@ -379,12 +307,6 @@ theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (s
 
 end Monotone
 
-/- warning: covariant_le_of_covariant_lt -> covariant_le_of_covariant_lt is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Covariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)))) -> (Covariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1))))
-but is expected to have type
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1850 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1852 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1850 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1852)) -> (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1869 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1871 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1869 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1871))
-Case conversion may be inaccurate. Consider using '#align covariant_le_of_covariant_lt covariant_le_of_covariant_ltₓ'. -/
 theorem covariant_le_of_covariant_lt [PartialOrder N] :
     Covariant M N μ (· < ·) → Covariant M N μ (· ≤ ·) :=
   by
@@ -394,12 +316,6 @@ theorem covariant_le_of_covariant_lt [PartialOrder N] :
   · exact (h _ bc).le
 #align covariant_le_of_covariant_lt covariant_le_of_covariant_lt
 
-/- warning: contravariant_lt_of_contravariant_le -> contravariant_lt_of_contravariant_le is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Contravariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)))) -> (Contravariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1))))
-but is expected to have type
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1940 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1942 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1940 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1942)) -> (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1959 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1961 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1959 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1961))
-Case conversion may be inaccurate. Consider using '#align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_leₓ'. -/
 theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
     Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) :=
   by
@@ -408,60 +324,30 @@ theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
   exact lt_irrefl _ bc
 #align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_le
 
-/- warning: covariant_le_iff_contravariant_lt -> covariant_le_iff_contravariant_lt is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))))) (Contravariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1)))))
-but is expected to have type
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2022 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2024 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2022 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2024)) (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2041 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2043 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2041 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2043))
-Case conversion may be inaccurate. Consider using '#align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_ltₓ'. -/
 theorem covariant_le_iff_contravariant_lt [LinearOrder N] :
     Covariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) :=
   ⟨fun h a b c bc => not_le.mp fun k => not_le.mpr bc (h _ k), fun h a b c bc =>
     not_lt.mp fun k => not_lt.mpr bc (h _ k)⟩
 #align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_lt
 
-/- warning: covariant_lt_iff_contravariant_le -> covariant_lt_iff_contravariant_le is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))))) (Contravariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1)))))
-but is expected to have type
-  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2124 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2126 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2124 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2126)) (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2143 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2145 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2143 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2145))
-Case conversion may be inaccurate. Consider using '#align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_leₓ'. -/
 theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
     Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·) :=
   ⟨fun h a b c bc => not_lt.mp fun k => not_lt.mpr bc (h _ k), fun h a b c bc =>
     not_le.mp fun k => not_le.mpr bc (h _ k)⟩
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
 
-/- warning: covariant_flip_mul_iff -> covariant_flip_mul_iff is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) (r : N -> N -> Prop) [_inst_1 : CommSemigroup.{u1} N], Iff (Covariant.{u1, u1} N N (flip.{succ u1, succ u1, succ u1} N N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) r) (Covariant.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) r)
-but is expected to have type
-  forall (N : Type.{u1}) (r : N -> N -> Prop) [_inst_1 : CommSemigroup.{u1} N], Iff (Covariant.{u1, u1} N N (flip.{succ u1, succ u1, succ u1} N N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2299 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2301 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2299 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2301)) r) (Covariant.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2318 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2320 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2318 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2320) r)
-Case conversion may be inaccurate. Consider using '#align covariant_flip_mul_iff covariant_flip_mul_iffₓ'. -/
 @[to_additive]
 theorem covariant_flip_mul_iff [CommSemigroup N] :
     Covariant N N (flip (· * ·)) r ↔ Covariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
 #align covariant_flip_mul_iff covariant_flip_mul_iff
 #align covariant_flip_add_iff covariant_flip_add_iff
 
-/- warning: contravariant_flip_mul_iff -> contravariant_flip_mul_iff is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) (r : N -> N -> Prop) [_inst_1 : CommSemigroup.{u1} N], Iff (Contravariant.{u1, u1} N N (flip.{succ u1, succ u1, succ u1} N N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) r) (Contravariant.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) r)
-but is expected to have type
-  forall (N : Type.{u1}) (r : N -> N -> Prop) [_inst_1 : CommSemigroup.{u1} N], Iff (Contravariant.{u1, u1} N N (flip.{succ u1, succ u1, succ u1} N N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2389 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2391 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2389 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2391)) r) (Contravariant.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2408 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2410 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2408 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2410) r)
-Case conversion may be inaccurate. Consider using '#align contravariant_flip_mul_iff contravariant_flip_mul_iffₓ'. -/
 @[to_additive]
 theorem contravariant_flip_mul_iff [CommSemigroup N] :
     Contravariant N N (flip (· * ·)) r ↔ Contravariant N N (· * ·) r := by rw [IsSymmOp.flip_eq]
 #align contravariant_flip_mul_iff contravariant_flip_mul_iff
 #align contravariant_flip_add_iff contravariant_flip_add_iff
 
-/- warning: contravariant_mul_lt_of_covariant_mul_le -> contravariant_mul_lt_of_covariant_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2477 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2479 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2477 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2479) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2492 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2494 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2492 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2494)], ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2510 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2512 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2510 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2512) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2525 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2527 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2525 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2527)
-Case conversion may be inaccurate. Consider using '#align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_leₓ'. -/
 @[to_additive]
 instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (· * ·) (· < ·)
@@ -469,12 +355,6 @@ instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
 #align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_le
 #align contravariant_add_lt_of_covariant_add_le contravariant_add_lt_of_covariant_add_le
 
-/- warning: covariant_mul_lt_of_contravariant_mul_le -> covariant_mul_lt_of_contravariant_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))], CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2589 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2591 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2589 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2591) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2604 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2606 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2604 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2606)], CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2622 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2624 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2622 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2624) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2637 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2639 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2637 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2639)
-Case conversion may be inaccurate. Consider using '#align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_leₓ'. -/
 @[to_additive]
 instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
@@ -482,12 +362,6 @@ instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
 #align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_le
 #align covariant_add_lt_of_contravariant_add_le covariant_add_lt_of_contravariant_add_le
 
-/- warning: covariant_swap_mul_le_of_covariant_mul_le -> covariant_swap_mul_le_of_covariant_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LE.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N _inst_2)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N _inst_2)
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LE.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2701 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2703 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2701 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2703) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2716 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2718 : N) => LE.le.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2716 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2718)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2737 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2739 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2737 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2739)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2752 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2754 : N) => LE.le.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2752 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2754)
-Case conversion may be inaccurate. Consider using '#align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_mul_le_of_covariant_mul_leₓ'. -/
 @[to_additive]
 instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (swap (· * ·)) (· ≤ ·)
@@ -495,12 +369,6 @@ instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
 #align covariant_swap_mul_le_of_covariant_mul_le covariant_swap_mul_le_of_covariant_mul_le
 #align covariant_swap_add_le_of_covariant_add_le covariant_swap_add_le_of_covariant_add_le
 
-/- warning: contravariant_swap_mul_le_of_contravariant_mul_le -> contravariant_swap_mul_le_of_contravariant_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LE.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N _inst_2)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N _inst_2)
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LE.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2815 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2817 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2815 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2817) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2830 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2832 : N) => LE.le.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2830 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2832)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2851 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2853 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2851 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2853)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2866 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2868 : N) => LE.le.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2866 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2868)
-Case conversion may be inaccurate. Consider using '#align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_mul_le_of_contravariant_mul_leₓ'. -/
 @[to_additive]
 instance contravariant_swap_mul_le_of_contravariant_mul_le [CommSemigroup N] [LE N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (swap (· * ·)) (· ≤ ·)
@@ -508,12 +376,6 @@ instance contravariant_swap_mul_le_of_contravariant_mul_le [CommSemigroup N] [LE
 #align contravariant_swap_mul_le_of_contravariant_mul_le contravariant_swap_mul_le_of_contravariant_mul_le
 #align contravariant_swap_add_le_of_contravariant_add_le contravariant_swap_add_le_of_contravariant_add_le
 
-/- warning: contravariant_swap_mul_lt_of_contravariant_mul_lt -> contravariant_swap_mul_lt_of_contravariant_mul_lt is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LT.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N _inst_2)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N _inst_2)
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LT.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2929 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2931 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2929 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2931) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2944 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2946 : N) => LT.lt.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2944 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2946)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2965 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2967 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2965 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2967)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2980 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2982 : N) => LT.lt.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2980 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2982)
-Case conversion may be inaccurate. Consider using '#align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_mul_lt_of_contravariant_mul_ltₓ'. -/
 @[to_additive]
 instance contravariant_swap_mul_lt_of_contravariant_mul_lt [CommSemigroup N] [LT N]
     [ContravariantClass N N (· * ·) (· < ·)] : ContravariantClass N N (swap (· * ·)) (· < ·)
@@ -521,12 +383,6 @@ instance contravariant_swap_mul_lt_of_contravariant_mul_lt [CommSemigroup N] [LT
 #align contravariant_swap_mul_lt_of_contravariant_mul_lt contravariant_swap_mul_lt_of_contravariant_mul_lt
 #align contravariant_swap_add_lt_of_contravariant_add_lt contravariant_swap_add_lt_of_contravariant_add_lt
 
-/- warning: covariant_swap_mul_lt_of_covariant_mul_lt -> covariant_swap_mul_lt_of_covariant_mul_lt is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LT.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N _inst_2)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N _inst_2)
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : CommSemigroup.{u1} N] [_inst_2 : LT.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3043 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3045 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3043 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3045) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3058 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3060 : N) => LT.lt.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3058 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3060)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3079 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3081 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (CommSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3079 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3081)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3094 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3096 : N) => LT.lt.{u1} N _inst_2 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3094 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3096)
-Case conversion may be inaccurate. Consider using '#align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_mul_lt_of_covariant_mul_ltₓ'. -/
 @[to_additive]
 instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
     [CovariantClass N N (· * ·) (· < ·)] : CovariantClass N N (swap (· * ·)) (· < ·)
@@ -534,12 +390,6 @@ instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
 #align covariant_swap_mul_lt_of_covariant_mul_lt covariant_swap_mul_lt_of_covariant_mul_lt
 #align covariant_swap_add_lt_of_covariant_add_lt covariant_swap_add_lt_of_covariant_add_lt
 
-/- warning: left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le -> LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3160 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3162 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3160 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3162) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3175 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3177 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3175 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3177)], CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3193 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3195 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3193 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3195) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3208 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3210 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3208 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3210)
-Case conversion may be inaccurate. Consider using '#align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_leₓ'. -/
 @[to_additive]
 instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSemigroup N]
     [PartialOrder N] [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
@@ -549,12 +399,6 @@ instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSem
 #align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le
 #align add_left_cancel_semigroup.covariant_add_lt_of_covariant_add_le AddLeftCancelSemigroup.covariant_add_lt_of_covariant_add_le
 
-/- warning: right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le -> RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3285 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3287 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3285 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3287)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3300 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3302 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3300 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3302)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3321 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3323 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3321 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3323)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3336 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3338 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3336 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3338)
-Case conversion may be inaccurate. Consider using '#align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_leₓ'. -/
 @[to_additive]
 instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
     [RightCancelSemigroup N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
@@ -565,12 +409,6 @@ instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
 #align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
 #align add_right_cancel_semigroup.covariant_swap_add_lt_of_covariant_swap_add_le AddRightCancelSemigroup.covariant_swap_add_lt_of_covariant_swap_add_le
 
-/- warning: left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt -> LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3410 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3412 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3410 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3412) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3425 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3427 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3425 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3427)], ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3443 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3445 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3443 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3445) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3458 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3460 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3458 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3460)
-Case conversion may be inaccurate. Consider using '#align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_ltₓ'. -/
 @[to_additive]
 instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftCancelSemigroup N]
     [PartialOrder N] [ContravariantClass N N (· * ·) (· < ·)] :
@@ -582,12 +420,6 @@ instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftC
 #align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt
 #align add_left_cancel_semigroup.contravariant_add_le_of_contravariant_add_lt AddLeftCancelSemigroup.contravariant_add_le_of_contravariant_add_lt
 
-/- warning: right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt -> RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt is a dubious translation:
-lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
-but is expected to have type
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3544 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3546 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3544 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3546)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3559 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3561 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3559 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3561)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3580 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3582 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3580 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3582)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3595 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3597 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3595 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3597)
-Case conversion may be inaccurate. Consider using '#align right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_ltₓ'. -/
 @[to_additive]
 instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
     [RightCancelSemigroup N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
Diff
@@ -318,7 +318,7 @@ variable {f : N → α}
 
 /- warning: covariant.monotone_of_const -> Covariant.monotone_of_const is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} [_inst_2 : Preorder.{u2} N] [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2))] (m : M), Monotone.{u2, u2} N N _inst_2 _inst_2 (μ m)
+  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} [_inst_2 : Preorder.{u2} N] [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))] (m : M), Monotone.{u2, u2} N N _inst_2 _inst_2 (μ m)
 but is expected to have type
   forall {M : Type.{u2}} {N : Type.{u1}} {μ : M -> N -> N} [_inst_2 : Preorder.{u1} N] [_inst_3 : CovariantClass.{u2, u1} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1485 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1487 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1485 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1487)] (m : M), Monotone.{u1, u1} N N _inst_2 _inst_2 (μ m)
 Case conversion may be inaccurate. Consider using '#align covariant.monotone_of_const Covariant.monotone_of_constₓ'. -/
@@ -329,7 +329,7 @@ theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M)
 
 /- warning: monotone.covariant_of_const -> Monotone.covariant_of_const is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2))], (Monotone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Monotone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
+  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))], (Monotone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Monotone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
 but is expected to have type
   forall {M : Type.{u3}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u3, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1549 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1551 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1549 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1551)], (Monotone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : M), Monotone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
 Case conversion may be inaccurate. Consider using '#align monotone.covariant_of_const Monotone.covariant_of_constₓ'. -/
@@ -342,7 +342,7 @@ theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Mo
 
 /- warning: monotone.covariant_of_const' -> Monotone.covariant_of_const' is a dubious translation:
 lean 3 declaration is
-  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toLE.{u1} N _inst_2))], (Monotone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Monotone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
+  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toHasLe.{u1} N _inst_2))], (Monotone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Monotone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
 but is expected to have type
   forall {N : Type.{u2}} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u2, u2} N N (Function.swap.{succ u2, succ u2, succ u2} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1631 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1633 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1631 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1633)], (Monotone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : N), Monotone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
 Case conversion may be inaccurate. Consider using '#align monotone.covariant_of_const' Monotone.covariant_of_const'ₓ'. -/
@@ -355,7 +355,7 @@ theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (s
 
 /- warning: antitone.covariant_of_const -> Antitone.covariant_of_const is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2))], (Antitone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Antitone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
+  forall {M : Type.{u1}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u3}} [_inst_1 : Preorder.{u3} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N _inst_2))], (Antitone.{u2, u3} N α _inst_2 _inst_1 f) -> (forall (m : M), Antitone.{u2, u3} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
 but is expected to have type
   forall {M : Type.{u3}} {N : Type.{u2}} {μ : M -> N -> N} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} [_inst_3 : CovariantClass.{u3, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1713 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1715 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1713 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1715)], (Antitone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : M), Antitone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ m n)))
 Case conversion may be inaccurate. Consider using '#align antitone.covariant_of_const Antitone.covariant_of_constₓ'. -/
@@ -367,7 +367,7 @@ theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : An
 
 /- warning: antitone.covariant_of_const' -> Antitone.covariant_of_const' is a dubious translation:
 lean 3 declaration is
-  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toLE.{u1} N _inst_2))], (Antitone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Antitone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
+  forall {N : Type.{u1}} {α : Type.{u2}} [_inst_1 : Preorder.{u2} α] [_inst_2 : Preorder.{u1} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (LE.le.{u1} N (Preorder.toHasLe.{u1} N _inst_2))], (Antitone.{u1, u2} N α _inst_2 _inst_1 f) -> (forall (m : N), Antitone.{u1, u2} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
 but is expected to have type
   forall {N : Type.{u2}} {α : Type.{u1}} [_inst_1 : Preorder.{u1} α] [_inst_2 : Preorder.{u2} N] {f : N -> α} {μ : N -> N -> N} [_inst_3 : CovariantClass.{u2, u2} N N (Function.swap.{succ u2, succ u2, succ u2} N N (fun (ᾰ : N) (ᾰ : N) => N) μ) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1787 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1789 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N _inst_2) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1787 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1789)], (Antitone.{u2, u1} N α _inst_2 _inst_1 f) -> (forall (m : N), Antitone.{u2, u1} N α _inst_2 _inst_1 (fun (n : N) => f (μ n m)))
 Case conversion may be inaccurate. Consider using '#align antitone.covariant_of_const' Antitone.covariant_of_const'ₓ'. -/
@@ -379,7 +379,12 @@ theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (s
 
 end Monotone
 
-#print covariant_le_of_covariant_lt /-
+/- warning: covariant_le_of_covariant_lt -> covariant_le_of_covariant_lt is a dubious translation:
+lean 3 declaration is
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Covariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)))) -> (Covariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1))))
+but is expected to have type
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1850 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1852 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1850 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1852)) -> (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1869 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1871 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1869 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1871))
+Case conversion may be inaccurate. Consider using '#align covariant_le_of_covariant_lt covariant_le_of_covariant_ltₓ'. -/
 theorem covariant_le_of_covariant_lt [PartialOrder N] :
     Covariant M N μ (· < ·) → Covariant M N μ (· ≤ ·) :=
   by
@@ -388,9 +393,13 @@ theorem covariant_le_of_covariant_lt [PartialOrder N] :
   · exact rfl.le
   · exact (h _ bc).le
 #align covariant_le_of_covariant_lt covariant_le_of_covariant_lt
--/
 
-#print contravariant_lt_of_contravariant_le /-
+/- warning: contravariant_lt_of_contravariant_le -> contravariant_lt_of_contravariant_le is a dubious translation:
+lean 3 declaration is
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Contravariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)))) -> (Contravariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1))))
+but is expected to have type
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : PartialOrder.{u2} N], (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1940 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1942 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1940 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1942)) -> (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1959 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1961 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N _inst_1)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1959 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.1961))
+Case conversion may be inaccurate. Consider using '#align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_leₓ'. -/
 theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
     Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) :=
   by
@@ -398,23 +407,30 @@ theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
   rintro rfl
   exact lt_irrefl _ bc
 #align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_le
--/
 
-#print covariant_le_iff_contravariant_lt /-
+/- warning: covariant_le_iff_contravariant_lt -> covariant_le_iff_contravariant_lt is a dubious translation:
+lean 3 declaration is
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))))) (Contravariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1)))))
+but is expected to have type
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2022 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2024 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2022 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2024)) (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2041 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2043 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2041 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2043))
+Case conversion may be inaccurate. Consider using '#align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_ltₓ'. -/
 theorem covariant_le_iff_contravariant_lt [LinearOrder N] :
     Covariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) :=
   ⟨fun h a b c bc => not_le.mp fun k => not_le.mpr bc (h _ k), fun h a b c bc =>
     not_lt.mp fun k => not_lt.mpr bc (h _ k)⟩
 #align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_lt
--/
 
-#print covariant_lt_iff_contravariant_le /-
+/- warning: covariant_lt_iff_contravariant_le -> covariant_lt_iff_contravariant_le is a dubious translation:
+lean 3 declaration is
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (LT.lt.{u2} N (Preorder.toHasLt.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))))) (Contravariant.{u1, u2} M N μ (LE.le.{u2} N (Preorder.toHasLe.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1)))))
+but is expected to have type
+  forall (M : Type.{u1}) (N : Type.{u2}) (μ : M -> N -> N) [_inst_1 : LinearOrder.{u2} N], Iff (Covariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2124 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2126 : N) => LT.lt.{u2} N (Preorder.toLT.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2124 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2126)) (Contravariant.{u1, u2} M N μ (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2143 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2145 : N) => LE.le.{u2} N (Preorder.toLE.{u2} N (PartialOrder.toPreorder.{u2} N (LinearOrder.toPartialOrder.{u2} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2143 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2145))
+Case conversion may be inaccurate. Consider using '#align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_leₓ'. -/
 theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
     Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·) :=
   ⟨fun h a b c bc => not_lt.mp fun k => not_lt.mpr bc (h _ k), fun h a b c bc =>
     not_le.mp fun k => not_le.mpr bc (h _ k)⟩
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
--/
 
 /- warning: covariant_flip_mul_iff -> covariant_flip_mul_iff is a dubious translation:
 lean 3 declaration is
@@ -440,23 +456,31 @@ theorem contravariant_flip_mul_iff [CommSemigroup N] :
 #align contravariant_flip_mul_iff contravariant_flip_mul_iff
 #align contravariant_flip_add_iff contravariant_flip_add_iff
 
-#print contravariant_mul_lt_of_covariant_mul_le /-
+/- warning: contravariant_mul_lt_of_covariant_mul_le -> contravariant_mul_lt_of_covariant_mul_le is a dubious translation:
+lean 3 declaration is
+  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))
+but is expected to have type
+  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2477 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2479 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2477 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2479) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2492 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2494 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2492 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2494)], ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2510 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2512 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2510 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2512) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2525 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2527 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2525 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2527)
+Case conversion may be inaccurate. Consider using '#align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_leₓ'. -/
 @[to_additive]
 instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
     [CovariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (· * ·) (· < ·)
     where elim := (covariant_le_iff_contravariant_lt N N (· * ·)).mp CovariantClass.elim
 #align contravariant_mul_lt_of_covariant_mul_le contravariant_mul_lt_of_covariant_mul_le
 #align contravariant_add_lt_of_covariant_add_le contravariant_add_lt_of_covariant_add_le
--/
 
-#print covariant_mul_lt_of_contravariant_mul_le /-
+/- warning: covariant_mul_lt_of_contravariant_mul_le -> covariant_mul_lt_of_contravariant_mul_le is a dubious translation:
+lean 3 declaration is
+  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))], CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1)) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))))
+but is expected to have type
+  forall (N : Type.{u1}) [_inst_1 : Mul.{u1} N] [_inst_2 : LinearOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2589 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2591 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2589 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2591) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2604 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2606 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2604 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2606)], CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2622 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2624 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N _inst_1) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2622 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2624) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2637 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2639 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N (LinearOrder.toPartialOrder.{u1} N _inst_2))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2637 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.2639)
+Case conversion may be inaccurate. Consider using '#align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_leₓ'. -/
 @[to_additive]
 instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
     [ContravariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·)
     where elim := (covariant_lt_iff_contravariant_le N N (· * ·)).mpr ContravariantClass.elim
 #align covariant_mul_lt_of_contravariant_mul_le covariant_mul_lt_of_contravariant_mul_le
 #align covariant_add_lt_of_contravariant_add_le covariant_add_lt_of_contravariant_add_le
--/
 
 /- warning: covariant_swap_mul_le_of_covariant_mul_le -> covariant_swap_mul_le_of_covariant_mul_le is a dubious translation:
 lean 3 declaration is
@@ -512,7 +536,7 @@ instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
 
 /- warning: left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le -> LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le is a dubious translation:
 lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
+  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
 but is expected to have type
   forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3160 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3162 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3160 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3162) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3175 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3177 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3175 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3177)], CovariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3193 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3195 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3193 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3195) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3208 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3210 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3208 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3210)
 Case conversion may be inaccurate. Consider using '#align left_cancel_semigroup.covariant_mul_lt_of_covariant_mul_le LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_leₓ'. -/
@@ -527,7 +551,7 @@ instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSem
 
 /- warning: right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le -> RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le is a dubious translation:
 lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
+  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
 but is expected to have type
   forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3285 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3287 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3285 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3287)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3300 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3302 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3300 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3302)], CovariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3321 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3323 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3321 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3323)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3336 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3338 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3336 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3338)
 Case conversion may be inaccurate. Consider using '#align right_cancel_semigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_leₓ'. -/
@@ -543,7 +567,7 @@ instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
 
 /- warning: left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt -> LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt is a dubious translation:
 lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
+  forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1)))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
 but is expected to have type
   forall (N : Type.{u1}) [_inst_1 : LeftCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3410 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3412 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3410 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3412) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3425 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3427 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3425 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3427)], ContravariantClass.{u1, u1} N N (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3443 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3445 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (LeftCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3443 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3445) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3458 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3460 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3458 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3460)
 Case conversion may be inaccurate. Consider using '#align left_cancel_semigroup.contravariant_mul_le_of_contravariant_mul_lt LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_ltₓ'. -/
@@ -560,7 +584,7 @@ instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftC
 
 /- warning: right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt -> RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt is a dubious translation:
 lean 3 declaration is
-  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
+  forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LT.lt.{u1} N (Preorder.toHasLt.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toHasMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))))) (LE.le.{u1} N (Preorder.toHasLe.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)))
 but is expected to have type
   forall (N : Type.{u1}) [_inst_1 : RightCancelSemigroup.{u1} N] [_inst_2 : PartialOrder.{u1} N] [_inst_3 : ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3544 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3546 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3544 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3546)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3559 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3561 : N) => LT.lt.{u1} N (Preorder.toLT.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3559 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3561)], ContravariantClass.{u1, u1} N N (Function.swap.{succ u1, succ u1, succ u1} N N (fun (ᾰ : N) (ᾰ : N) => N) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3580 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3582 : N) => HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N (RightCancelSemigroup.toSemigroup.{u1} N _inst_1))) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3580 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3582)) (fun (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3595 : N) (x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3597 : N) => LE.le.{u1} N (Preorder.toLE.{u1} N (PartialOrder.toPreorder.{u1} N _inst_2)) x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3595 x._@.Mathlib.Algebra.CovariantAndContravariant._hyg.3597)
 Case conversion may be inaccurate. Consider using '#align right_cancel_semigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_ltₓ'. -/

Changes in mathlib4

mathlib3
mathlib4
chore(*): remove empty lines between variable statements (#11418)

Empty lines were removed by executing the following Python script twice

import os
import re


# Loop through each file in the repository
for dir_path, dirs, files in os.walk('.'):
  for filename in files:
    if filename.endswith('.lean'):
      file_path = os.path.join(dir_path, filename)

      # Open the file and read its contents
      with open(file_path, 'r') as file:
        content = file.read()

      # Use a regular expression to replace sequences of "variable" lines separated by empty lines
      # with sequences without empty lines
      modified_content = re.sub(r'(variable.*\n)\n(variable(?! .* in))', r'\1\2', content)

      # Write the modified content back to the file
      with open(file_path, 'w') as file:
        file.write(modified_content)
Diff
@@ -69,7 +69,6 @@ open Function
 section Variants
 
 variable {M N : Type*} (μ : M → N → N) (r : N → N → Prop)
-
 variable (M N)
 
 /-- `Covariant` is useful to formulate succinctly statements about the interactions between an
@@ -244,7 +243,6 @@ end Contravariant
 section Monotone
 
 variable {α : Type*} {M N μ} [Preorder α] [Preorder N]
-
 variable {f : N → α}
 
 /-- The partial application of a constant to a covariant operator is monotone. -/
doc(Mathlib/Algebra): fix typos (#10080)

Fix minor typos in the Mathlib/Algebra/CovariantAndContravariant.lean file.

Diff
@@ -72,7 +72,7 @@ variable {M N : Type*} (μ : M → N → N) (r : N → N → Prop)
 
 variable (M N)
 
-/-- `Covariant` is useful to formulate succintly statements about the interactions between an
+/-- `Covariant` is useful to formulate succinctly statements about the interactions between an
 action of a Type on another one and a relation on the acted-upon Type.
 
 See the `CovariantClass` doc-string for its meaning. -/
@@ -80,7 +80,7 @@ def Covariant : Prop :=
   ∀ (m) {n₁ n₂}, r n₁ n₂ → r (μ m n₁) (μ m n₂)
 #align covariant Covariant
 
-/-- `Contravariant` is useful to formulate succintly statements about the interactions between an
+/-- `Contravariant` is useful to formulate succinctly statements about the interactions between an
 action of a Type on another one and a relation on the acted-upon Type.
 
 See the `ContravariantClass` doc-string for its meaning. -/
chore: refactor of Algebra/Group/Defs to reduce imports (#9606)

We are not that far from the point that Algebra/Group/Defs depends on nothing significant besides simps and to_additive.

This removes from Mathlib.Algebra.Group.Defs the dependencies on

  • Mathlib.Tactic.Basic (which is a grab-bag of random stuff)
  • Mathlib.Init.Algebra.Classes (which is ancient and half-baked)
  • Mathlib.Logic.Function.Basic (not particularly important, but it is barely used in this file)

The goal is to avoid all unnecessary imports to set up the definitions of basic algebraic structures.

We also separate out Mathlib.Tactic.TypeStar and Mathlib.Tactic.Lemma as prerequisites to Mathlib.Tactic.Basic, but which can be imported separately when the rest of Mathlib.Tactic.Basic is not needed.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Yaël Dillies <yael.dillies@gmail.com>

Diff
@@ -3,7 +3,7 @@ Copyright (c) 2021 Damiano Testa. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
 -/
-import Mathlib.Algebra.Group.Defs
+import Mathlib.Algebra.Group.Basic
 import Mathlib.Order.Basic
 import Mathlib.Order.Monotone.Basic
 
chore(Algebra/Regular/Basic): generalize to IsCancelMul (#8428)

This lets lemmas about cancellative monoids work for cancellative semigroups

Some docstrings have been rewritten, as adjusting the wording was too awkward.

The new .all names are intended to match Commute.all.

Diff
@@ -31,7 +31,7 @@ relation (typically `(≤)` or `(<)`), these are the only two typeclasses that I
 The general approach is to formulate the lemma that you are interested in and prove it, with the
 `Ordered[...]` typeclass of your liking.  After that, you convert the single typeclass,
 say `[OrderedCancelMonoid M]`, into three typeclasses, e.g.
-`[LeftCancelSemigroup M] [PartialOrder M] [CovariantClass M M (Function.swap (*)) (≤)]`
+`[CancelMonoid M] [PartialOrder M] [CovariantClass M M (Function.swap (*)) (≤)]`
 and have a go at seeing if the proof still works!
 
 Note that it is possible to combine several `Co(ntra)variantClass` assumptions together.
@@ -362,27 +362,27 @@ theorem contravariant_le_of_contravariant_eq_and_lt [PartialOrder N]
   then the following four instances (actually eight) can be removed in favor of the above two. -/
 
 @[to_additive]
-instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSemigroup N]
+instance IsLeftCancelMul.covariant_mul_lt_of_covariant_mul_le [Mul N] [IsLeftCancelMul N]
     [PartialOrder N] [CovariantClass N N (· * ·) (· ≤ ·)] :
     CovariantClass N N (· * ·) (· < ·) where
   elim a _ _ bc := (CovariantClass.elim a bc.le).lt_of_ne ((mul_ne_mul_right a).mpr bc.ne)
 
 @[to_additive]
-instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
-    [RightCancelSemigroup N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
+instance IsRightCancelMul.covariant_swap_mul_lt_of_covariant_swap_mul_le
+    [Mul N] [IsRightCancelMul N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
     CovariantClass N N (swap (· * ·)) (· < ·) where
   elim a _ _ bc := (CovariantClass.elim a bc.le).lt_of_ne ((mul_ne_mul_left a).mpr bc.ne)
 
 @[to_additive]
-instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftCancelSemigroup N]
+instance IsLeftCancelMul.contravariant_mul_le_of_contravariant_mul_lt [Mul N] [IsLeftCancelMul N]
     [PartialOrder N] [ContravariantClass N N (· * ·) (· < ·)] :
     ContravariantClass N N (· * ·) (· ≤ ·) where
   elim := (contravariant_le_iff_contravariant_lt_and_eq N N _).mpr
     ⟨ContravariantClass.elim, fun _ ↦ mul_left_cancel⟩
 
 @[to_additive]
-instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
-    [RightCancelSemigroup N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
+instance IsRightCancelMul.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
+    [Mul N] [IsRightCancelMul N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
     ContravariantClass N N (swap (· * ·)) (· ≤ ·) where
   elim := (contravariant_le_iff_contravariant_lt_and_eq N N _).mpr
     ⟨ContravariantClass.elim, fun _ ↦ mul_right_cancel⟩
chore: tidy various files (#8409)
Diff
@@ -43,7 +43,7 @@ A formal remark is that normally `CovariantClass` uses the `(≤)`-relation, whi
 `ContravariantClass` uses the `(<)`-relation. This need not be the case in general, but seems to be
 the most common usage. In the opposite direction, the implication
 ```lean
-[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] ↦ LeftCancelSemigroup α
+[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] → LeftCancelSemigroup α
 ```
 holds -- note the `Co*ntra*` assumption on the `(≤)`-relation.
 
chore(Co(ntra)variantClass): generalize and remove duplicates (#6677)

4 files have major changes:

Algebra/CovariantAndContravariant.lean

  • Add new theorem contravariant_le_iff_contravariant_lt_and_eq.
  • Add covariantClass_le_of_lt generalizing and replacing Mul.to_covariantClass_left/right in Algebra/Order/Monoid/Defs.lean
  • Replace CommSemigroup by IsSymmOp N N mu and replace CancelSemigroup by IsMulCancel, removing superfluous associativity assumption.
  • new theorems covariant_lt_of_covariant_le_of_contravariant_eq and contravariant_le_of_contravariant_eq_and_lt that could replace eight instances when appropriate refactoring is in place.
  • Golfs
  • Fix changed names in other files.

Algebra/Order/Monoid/Lemmas.lean

  • Generalize mul_eq_mul_iff_eq_and_eq and remove the less general Left/Right.mul_eq_mul_iff_eq_and_eq.
  • Move mul_le_mul_iff_of_ge.
  • Introduce the more general Left/Right versions of min_le_max_of_mul_le_mul.
  • Move min_lt_max_of_mul_lt_mul here from Algebra/GroupPower/Order.lean.
  • Replace CommSemigroup by IsSymmOp.

Algebra/Order/Monoid/Basic.lean

  • Remove eq_and_eq_of_le_of_le_of_mul_le as it's just one direction of mul_le_mul_iff_of_ge but with more assumptions.

Algebra/Order/Ring/Lemmas.lean

  • Generalize two versions of mul_eq_mul_iff_eq_and_eq_of_pos
  • Golfs

Changes to Algebra/Group/UniqueProds.lean and Algebra/MonoidAlgebra/NoZeroDivisors.lean are in declarations that will be removed by #6723.

Co-authored-by: Junyan Xu <junyanxu.math@gmail.com>

Diff
@@ -43,7 +43,7 @@ A formal remark is that normally `CovariantClass` uses the `(≤)`-relation, whi
 `ContravariantClass` uses the `(<)`-relation. This need not be the case in general, but seems to be
 the most common usage. In the opposite direction, the implication
 ```lean
-[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] => LeftCancelSemigroup α
+[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] ↦ LeftCancelSemigroup α
 ```
 holds -- note the `Co*ntra*` assumption on the `(≤)`-relation.
 
@@ -134,11 +134,11 @@ section flip
 variable {M N μ r}
 
 theorem Covariant.flip (h : Covariant M N μ r) : Covariant M N μ (flip r) :=
-  fun a _ _ hbc ↦ h a hbc
+  fun a _ _ ↦ h a
 #align covariant.flip Covariant.flip
 
 theorem Contravariant.flip (h : Contravariant M N μ r) : Contravariant M N μ (flip r) :=
-  fun a _ _ hbc ↦ h a hbc
+  fun a _ _ ↦ h a
 #align contravariant.flip Contravariant.flip
 
 end flip
@@ -249,33 +249,33 @@ variable {f : N → α}
 
 /-- The partial application of a constant to a covariant operator is monotone. -/
 theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M) : Monotone (μ m) :=
-  fun _ _ ha ↦ CovariantClass.elim m ha
+  fun _ _ ↦ CovariantClass.elim m
 #align covariant.monotone_of_const Covariant.monotone_of_const
 
 /-- A monotone function remains monotone when composed with the partial application
 of a covariant operator. E.g., `∀ (m : ℕ), Monotone f → Monotone (fun n ↦ f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
-    Monotone fun n ↦ f (μ m n) :=
-  fun _ _ x ↦ hf (Covariant.monotone_of_const m x)
+    Monotone (f <| μ m ·) :=
+  hf.comp (Covariant.monotone_of_const m)
 #align monotone.covariant_of_const Monotone.covariant_of_const
 
 /-- Same as `Monotone.covariant_of_const`, but with the constant on the other side of
 the operator.  E.g., `∀ (m : ℕ), Monotone f → Monotone (fun n ↦ f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
-    (hf : Monotone f) (m : N) : Monotone fun n ↦ f (μ n m) :=
-  fun _ _ x ↦ hf (@Covariant.monotone_of_const _ _ (swap μ) _ _ m _ _ x)
+    (hf : Monotone f) (m : N) : Monotone (f <| μ · m) :=
+  Monotone.covariant_of_const (μ := swap μ) hf m
 #align monotone.covariant_of_const' Monotone.covariant_of_const'
 
 /-- Dual of `Monotone.covariant_of_const` -/
 theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Antitone f) (m : M) :
-    Antitone fun n ↦ f (μ m n) :=
+    Antitone (f <| μ m ·) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
 #align antitone.covariant_of_const Antitone.covariant_of_const
 
 /-- Dual of `Monotone.covariant_of_const'` -/
 theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
-    (hf : Antitone f) (m : N) : Antitone fun n ↦ f (μ n m) :=
-  hf.comp_monotone <| @Covariant.monotone_of_const _ _ (swap μ) _ _ m
+    (hf : Antitone f) (m : N) : Antitone (f <| μ · m) :=
+  Antitone.covariant_of_const (μ := swap μ) hf m
 #align antitone.covariant_of_const' Antitone.covariant_of_const'
 
 end Monotone
@@ -283,109 +283,108 @@ end Monotone
 theorem covariant_le_of_covariant_lt [PartialOrder N] :
     Covariant M N μ (· < ·) → Covariant M N μ (· ≤ ·) := by
   intro h a b c bc
-  rcases le_iff_eq_or_lt.mp bc with (rfl | bc)
-  · exact rfl.le
+  rcases bc.eq_or_lt with (rfl | bc)
+  · exact le_rfl
   · exact (h _ bc).le
 #align covariant_le_of_covariant_lt covariant_le_of_covariant_lt
 
+theorem covariantClass_le_of_lt [PartialOrder N] [CovariantClass M N μ (· < ·)] :
+    CovariantClass M N μ (· ≤ ·) := ⟨covariant_le_of_covariant_lt _ _ _ CovariantClass.elim⟩
+
+theorem contravariant_le_iff_contravariant_lt_and_eq [PartialOrder N] :
+    Contravariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) ∧ Contravariant M N μ (· = ·) := by
+  refine ⟨fun h ↦ ⟨fun a b c bc ↦ ?_, fun a b c bc ↦ ?_⟩, fun h ↦ fun a b c bc ↦ ?_⟩
+  · exact (h a bc.le).lt_of_ne (by rintro rfl; exact lt_irrefl _ bc)
+  · exact (h a bc.le).antisymm (h a bc.ge)
+  · exact bc.lt_or_eq.elim (fun bc ↦ (h.1 a bc).le) (fun bc ↦ (h.2 a bc).le)
+
 theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
-    Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) := by
-  refine fun h a b c bc ↦ lt_iff_le_and_ne.mpr ⟨h a bc.le, ?_⟩
-  rintro rfl; exact lt_irrefl _ bc
+    Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) :=
+  And.left ∘ (contravariant_le_iff_contravariant_lt_and_eq M N μ).mp
 #align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_le
 
 theorem covariant_le_iff_contravariant_lt [LinearOrder N] :
     Covariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) :=
-  ⟨fun h _ _ _ bc ↦ not_le.mp fun k ↦ not_le.mpr bc (h _ k),
-   fun h _ _ _ bc ↦ not_lt.mp fun k ↦ not_lt.mpr bc (h _ k)⟩
+  ⟨fun h _ _ _ bc ↦ not_le.mp fun k ↦ bc.not_le (h _ k),
+   fun h _ _ _ bc ↦ not_lt.mp fun k ↦ bc.not_lt (h _ k)⟩
 #align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_lt
 
 theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
     Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·) :=
-  ⟨fun h _ _ _ bc ↦ not_lt.mp fun k ↦ not_lt.mpr bc (h _ k),
-   fun h _ _ _ bc ↦ not_le.mp fun k ↦ not_le.mpr bc (h _ k)⟩
+  ⟨fun h _ _ _ bc ↦ not_lt.mp fun k ↦ bc.not_lt (h _ k),
+   fun h _ _ _ bc ↦ not_le.mp fun k ↦ bc.not_le (h _ k)⟩
 #align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
 
--- Porting note: `covariant_flip_mul_iff` used to use the `IsSymmOp` typeclass from Lean 3 core.
--- To avoid it, we prove the relevant lemma here.
-@[to_additive]
-lemma flip_mul [CommSemigroup N] : (flip (· * ·) : N → N → N) = (· * ·) :=
-  funext fun a ↦ funext fun b ↦ mul_comm b a
+variable (mu : N → N → N)
 
-@[to_additive]
-theorem covariant_flip_mul_iff [CommSemigroup N] :
-    Covariant N N (flip (· * ·)) r ↔ Covariant N N (· * ·) r := by rw [flip_mul]
-#align covariant_flip_mul_iff covariant_flip_mul_iff
-#align covariant_flip_add_iff covariant_flip_add_iff
+theorem covariant_flip_iff [IsSymmOp N N mu] :
+    Covariant N N (flip mu) r ↔ Covariant N N mu r := by rw [IsSymmOp.flip_eq]
+#noalign covariant_flip_mul_iff
+#noalign covariant_flip_add_iff
 
-@[to_additive]
-theorem contravariant_flip_mul_iff [CommSemigroup N] :
-    Contravariant N N (flip (· * ·)) r ↔ Contravariant N N (· * ·) r := by rw [flip_mul]
-#align contravariant_flip_mul_iff contravariant_flip_mul_iff
-#align contravariant_flip_add_iff contravariant_flip_add_iff
+theorem contravariant_flip_iff [IsSymmOp N N mu] :
+    Contravariant N N (flip mu) r ↔ Contravariant N N mu r := by rw [IsSymmOp.flip_eq]
+#noalign contravariant_flip_mul_iff
+#noalign contravariant_flip_add_iff
 
-@[to_additive]
-instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
-    [CovariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (· * ·) (· < ·) where
-  elim := (covariant_le_iff_contravariant_lt N N (· * ·)).mp CovariantClass.elim
+instance contravariant_lt_of_covariant_le [LinearOrder N]
+    [CovariantClass N N mu (· ≤ ·)] : ContravariantClass N N mu (· < ·) where
+  elim := (covariant_le_iff_contravariant_lt N N mu).mp CovariantClass.elim
 
-@[to_additive]
-instance covariant_mul_lt_of_contravariant_mul_le [Mul N] [LinearOrder N]
-    [ContravariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (· * ·) (· < ·) where
-  elim := (covariant_lt_iff_contravariant_le N N (· * ·)).mpr ContravariantClass.elim
-
-@[to_additive]
-instance covariant_swap_mul_le_of_covariant_mul_le [CommSemigroup N] [LE N]
-    [CovariantClass N N (· * ·) (· ≤ ·)] : CovariantClass N N (swap (· * ·)) (· ≤ ·) where
-  elim := (covariant_flip_mul_iff N (· ≤ ·)).mpr CovariantClass.elim
-
-@[to_additive]
-instance contravariant_swap_mul_le_of_contravariant_mul_le [CommSemigroup N] [LE N]
-    [ContravariantClass N N (· * ·) (· ≤ ·)] : ContravariantClass N N (swap (· * ·)) (· ≤ ·) where
-  elim := (contravariant_flip_mul_iff N (· ≤ ·)).mpr ContravariantClass.elim
+instance covariant_lt_of_contravariant_le [LinearOrder N]
+    [ContravariantClass N N mu (· ≤ ·)] : CovariantClass N N mu (· < ·) where
+  elim := (covariant_lt_iff_contravariant_le N N mu).mpr ContravariantClass.elim
 
 @[to_additive]
-instance contravariant_swap_mul_lt_of_contravariant_mul_lt [CommSemigroup N] [LT N]
-    [ContravariantClass N N (· * ·) (· < ·)] : ContravariantClass N N (swap (· * ·)) (· < ·) where
-  elim := (contravariant_flip_mul_iff N (· < ·)).mpr ContravariantClass.elim
+instance covariant_swap_mul_of_covariant_mul [CommSemigroup N]
+    [CovariantClass N N (· * ·) r] : CovariantClass N N (swap (· * ·)) r where
+  elim := (covariant_flip_iff N r (· * ·)).mpr CovariantClass.elim
 
 @[to_additive]
-instance covariant_swap_mul_lt_of_covariant_mul_lt [CommSemigroup N] [LT N]
-    [CovariantClass N N (· * ·) (· < ·)] : CovariantClass N N (swap (· * ·)) (· < ·) where
-  elim := (covariant_flip_mul_iff N (· < ·)).mpr CovariantClass.elim
+instance contravariant_swap_mul_of_contravariant_mul [CommSemigroup N]
+    [ContravariantClass N N (· * ·) r] : ContravariantClass N N (swap (· * ·)) r where
+  elim := (contravariant_flip_iff N r (· * ·)).mpr ContravariantClass.elim
+
+theorem covariant_lt_of_covariant_le_of_contravariant_eq [ContravariantClass M N μ (· = ·)]
+    [PartialOrder N] [CovariantClass M N μ (· ≤ ·)] : CovariantClass M N μ (· < ·) where
+  elim a _ _ bc := (CovariantClass.elim a bc.le).lt_of_ne (bc.ne ∘ ContravariantClass.elim _)
+
+theorem contravariant_le_of_contravariant_eq_and_lt [PartialOrder N]
+    [ContravariantClass M N μ (· = ·)] [ContravariantClass M N μ (· < ·)] :
+    ContravariantClass M N μ (· ≤ ·) where
+  elim := (contravariant_le_iff_contravariant_lt_and_eq M N μ).mpr
+    ⟨ContravariantClass.elim, ContravariantClass.elim⟩
+
+/- TODO:
+  redefine `IsLeftCancel N mu` as abbrev of `ContravariantClass N N mu (· = ·)`,
+  redefine `IsRightCancel N mu` as abbrev of `ContravariantClass N N (flip mu) (· = ·)`,
+  redefine `IsLeftCancelMul` as abbrev of `IsLeftCancel`,
+  then the following four instances (actually eight) can be removed in favor of the above two. -/
 
 @[to_additive]
 instance LeftCancelSemigroup.covariant_mul_lt_of_covariant_mul_le [LeftCancelSemigroup N]
     [PartialOrder N] [CovariantClass N N (· * ·) (· ≤ ·)] :
     CovariantClass N N (· * ·) (· < ·) where
-  elim a b c bc := by
-    cases' lt_iff_le_and_ne.mp bc with bc cb
-    exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_right a).mpr cb⟩
+  elim a _ _ bc := (CovariantClass.elim a bc.le).lt_of_ne ((mul_ne_mul_right a).mpr bc.ne)
 
 @[to_additive]
 instance RightCancelSemigroup.covariant_swap_mul_lt_of_covariant_swap_mul_le
     [RightCancelSemigroup N] [PartialOrder N] [CovariantClass N N (swap (· * ·)) (· ≤ ·)] :
     CovariantClass N N (swap (· * ·)) (· < ·) where
-  elim a b c bc := by
-    cases' lt_iff_le_and_ne.mp bc with bc cb
-    exact lt_iff_le_and_ne.mpr ⟨CovariantClass.elim a bc, (mul_ne_mul_left a).mpr cb⟩
+  elim a _ _ bc := (CovariantClass.elim a bc.le).lt_of_ne ((mul_ne_mul_left a).mpr bc.ne)
 
 @[to_additive]
 instance LeftCancelSemigroup.contravariant_mul_le_of_contravariant_mul_lt [LeftCancelSemigroup N]
     [PartialOrder N] [ContravariantClass N N (· * ·) (· < ·)] :
     ContravariantClass N N (· * ·) (· ≤ ·) where
-  elim a b c bc := by
-    cases' le_iff_eq_or_lt.mp bc with h h
-    · exact ((mul_right_inj a).mp h).le
-    · exact (ContravariantClass.elim _ h).le
+  elim := (contravariant_le_iff_contravariant_lt_and_eq N N _).mpr
+    ⟨ContravariantClass.elim, fun _ ↦ mul_left_cancel⟩
 
 @[to_additive]
 instance RightCancelSemigroup.contravariant_swap_mul_le_of_contravariant_swap_mul_lt
     [RightCancelSemigroup N] [PartialOrder N] [ContravariantClass N N (swap (· * ·)) (· < ·)] :
     ContravariantClass N N (swap (· * ·)) (· ≤ ·) where
-  elim a b c bc := by
-    cases' le_iff_eq_or_lt.mp bc with h h
-    · exact ((mul_left_inj a).mp h).le
-    · exact (ContravariantClass.elim _ h).le
+  elim := (contravariant_le_iff_contravariant_lt_and_eq N N _).mpr
+    ⟨ContravariantClass.elim, fun _ ↦ mul_right_cancel⟩
 
 end Variants
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -68,7 +68,7 @@ open Function
 
 section Variants
 
-variable {M N : Type _} (μ : M → N → N) (r : N → N → Prop)
+variable {M N : Type*} (μ : M → N → N) (r : N → N → Prop)
 
 variable (M N)
 
@@ -243,7 +243,7 @@ end Contravariant
 
 section Monotone
 
-variable {α : Type _} {M N μ} [Preorder α] [Preorder N]
+variable {α : Type*} {M N μ} [Preorder α] [Preorder N]
 
 variable {f : N → α}
 
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,16 +2,13 @@
 Copyright (c) 2021 Damiano Testa. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
-
-! This file was ported from Lean 3 source module algebra.covariant_and_contravariant
-! leanprover-community/mathlib commit 2258b40dacd2942571c8ce136215350c702dc78f
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Algebra.Group.Defs
 import Mathlib.Order.Basic
 import Mathlib.Order.Monotone.Basic
 
+#align_import algebra.covariant_and_contravariant from "leanprover-community/mathlib"@"2258b40dacd2942571c8ce136215350c702dc78f"
+
 /-!
 
 # Covariants and contravariants
chore: convert lambda in docs to fun (#5045)

Found with git grep -n "λ [a-zA-Z_ ]*,"

Diff
@@ -256,14 +256,14 @@ theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M)
 #align covariant.monotone_of_const Covariant.monotone_of_const
 
 /-- A monotone function remains monotone when composed with the partial application
-of a covariant operator. E.g., `∀ (m : ℕ), Monotone f → Monotone (λ n, f (m + n))`. -/
+of a covariant operator. E.g., `∀ (m : ℕ), Monotone f → Monotone (fun n ↦ f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
     Monotone fun n ↦ f (μ m n) :=
   fun _ _ x ↦ hf (Covariant.monotone_of_const m x)
 #align monotone.covariant_of_const Monotone.covariant_of_const
 
 /-- Same as `Monotone.covariant_of_const`, but with the constant on the other side of
-the operator.  E.g., `∀ (m : ℕ), Monotone f → Monotone (λ n, f (n + m))`. -/
+the operator.  E.g., `∀ (m : ℕ), Monotone f → Monotone (fun n ↦ f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Monotone f) (m : N) : Monotone fun n ↦ f (μ n m) :=
   fun _ _ x ↦ hf (@Covariant.monotone_of_const _ _ (swap μ) _ _ m _ _ x)
chore: fix upper/lowercase in comments (#4360)
  • Run a non-interactive version of fix-comments.py on all files.
  • Go through the diff and manually add/discard/edit chunks.
Diff
@@ -60,7 +60,7 @@ as it is easier to use.
 -/
 
 
--- TODO: convert `has_exists_mul_of_le`, `has_exists_add_of_le`?
+-- TODO: convert `ExistsMulOfLE`, `ExistsAddOfLE`?
 -- TODO: relationship with `Con/AddCon`
 -- TODO: include equivalence of `LeftCancelSemigroup` with
 -- `Semigroup PartialOrder ContravariantClass α α (*) (≤)`?
@@ -263,7 +263,7 @@ theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Mo
 #align monotone.covariant_of_const Monotone.covariant_of_const
 
 /-- Same as `Monotone.covariant_of_const`, but with the constant on the other side of
-the operator.  E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (n + m))`. -/
+the operator.  E.g., `∀ (m : ℕ), Monotone f → Monotone (λ n, f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Monotone f) (m : N) : Monotone fun n ↦ f (μ n m) :=
   fun _ _ x ↦ hf (@Covariant.monotone_of_const _ _ (swap μ) _ _ m _ _ x)
chore: add missing #align statements (#1902)

This PR is the result of a slight variant on the following "algorithm"

  • take all mathlib 3 names, remove _ and make all uppercase letters into lowercase
  • take all mathlib 4 names, remove _ and make all uppercase letters into lowercase
  • look for matches, and create pairs (original_lean3_name, OriginalLean4Name)
  • for pairs that do not have an align statement:
    • use Lean 4 to lookup the file + position of the Lean 4 name
    • add an #align statement just before the next empty line
  • manually fix some tiny mistakes (e.g., empty lines in proofs might cause the #align statement to have been inserted too early)
Diff
@@ -81,6 +81,7 @@ action of a Type on another one and a relation on the acted-upon Type.
 See the `CovariantClass` doc-string for its meaning. -/
 def Covariant : Prop :=
   ∀ (m) {n₁ n₂}, r n₁ n₂ → r (μ m n₁) (μ m n₂)
+#align covariant Covariant
 
 /-- `Contravariant` is useful to formulate succintly statements about the interactions between an
 action of a Type on another one and a relation on the acted-upon Type.
@@ -88,6 +89,7 @@ action of a Type on another one and a relation on the acted-upon Type.
 See the `ContravariantClass` doc-string for its meaning. -/
 def Contravariant : Prop :=
   ∀ (m) {n₁ n₂}, r (μ m n₁) (μ m n₂) → r n₁ n₂
+#align contravariant Contravariant
 
 /-- Given an action `μ` of a Type `M` on a Type `N` and a relation `r` on `N`, informally, the
 `CovariantClass` says that "the action `μ` preserves the relation `r`."
@@ -104,6 +106,7 @@ class CovariantClass : Prop where
   /-- For all `m ∈ M` and all elements `n₁, n₂ ∈ N`, if the relation `r` holds for the pair
   `(n₁, n₂)`, then, the relation `r` also holds for the pair `(μ m n₁, μ m n₂)` -/
   protected elim : Covariant M N μ r
+#align covariant_class CovariantClass
 
 /-- Given an action `μ` of a Type `M` on a Type `N` and a relation `r` on `N`, informally, the
 `ContravariantClass` says that "if the result of the action `μ` on a pair satisfies the
@@ -122,10 +125,12 @@ class ContravariantClass : Prop where
   pair `(μ m n₁, μ m n₂)` obtained from `(n₁, n₂)` by acting upon it by `m`, then, the relation
   `r` also holds for the pair `(n₁, n₂)`. -/
   protected elim : Contravariant M N μ r
+#align contravariant_class ContravariantClass
 
 theorem rel_iff_cov [CovariantClass M N μ r] [ContravariantClass M N μ r] (m : M) {a b : N} :
     r (μ m a) (μ m b) ↔ r a b :=
   ⟨ContravariantClass.elim _, CovariantClass.elim _⟩
+#align rel_iff_cov rel_iff_cov
 
 section flip
 
@@ -133,9 +138,11 @@ variable {M N μ r}
 
 theorem Covariant.flip (h : Covariant M N μ r) : Covariant M N μ (flip r) :=
   fun a _ _ hbc ↦ h a hbc
+#align covariant.flip Covariant.flip
 
 theorem Contravariant.flip (h : Contravariant M N μ r) : Contravariant M N μ (flip r) :=
   fun a _ _ hbc ↦ h a hbc
+#align contravariant.flip Contravariant.flip
 
 end flip
 
@@ -145,6 +152,7 @@ variable {M N μ r} [CovariantClass M N μ r]
 
 theorem act_rel_act_of_rel (m : M) {a b : N} (ab : r a b) : r (μ m a) (μ m b) :=
   CovariantClass.elim _ ab
+#align act_rel_act_of_rel act_rel_act_of_rel
 
 @[to_additive]
 theorem Group.covariant_iff_contravariant [Group N] :
@@ -154,6 +162,8 @@ theorem Group.covariant_iff_contravariant [Group N] :
     exact h a⁻¹ bc
   · rw [← inv_mul_cancel_left a b, ← inv_mul_cancel_left a c] at bc
     exact h a⁻¹ bc
+#align group.covariant_iff_contravariant Group.covariant_iff_contravariant
+#align add_group.covariant_iff_contravariant AddGroup.covariant_iff_contravariant
 
 @[to_additive]
 instance (priority := 100) Group.covconv [Group N] [CovariantClass N N (· * ·) r] :
@@ -168,6 +178,8 @@ theorem Group.covariant_swap_iff_contravariant_swap [Group N] :
     exact h a⁻¹ bc
   · rw [← mul_inv_cancel_right b a, ← mul_inv_cancel_right c a] at bc
     exact h a⁻¹ bc
+#align group.covariant_swap_iff_contravariant_swap Group.covariant_swap_iff_contravariant_swap
+#align add_group.covariant_swap_iff_contravariant_swap AddGroup.covariant_swap_iff_contravariant_swap
 
 
 @[to_additive]
@@ -183,9 +195,11 @@ variable [IsTrans N r] (m n : M) {a b c d : N}
 --  Lemmas with 3 elements.
 theorem act_rel_of_rel_of_act_rel (ab : r a b) (rl : r (μ m b) c) : r (μ m a) c :=
   _root_.trans (act_rel_act_of_rel m ab) rl
+#align act_rel_of_rel_of_act_rel act_rel_of_rel_of_act_rel
 
 theorem rel_act_of_rel_of_rel_act (ab : r a b) (rr : r c (μ m a)) : r c (μ m b) :=
   _root_.trans rr (act_rel_act_of_rel _ ab)
+#align rel_act_of_rel_of_rel_act rel_act_of_rel_of_rel_act
 
 end Trans
 
@@ -199,6 +213,7 @@ variable {M N μ r} {mu : N → N → N} [IsTrans N r] [i : CovariantClass N N m
 
 theorem act_rel_act_of_rel_of_rel (ab : r a b) (cd : r c d) : r (mu a c) (mu b d) :=
   _root_.trans (@act_rel_act_of_rel _ _ (swap mu) r _ c _ _ ab) (act_rel_act_of_rel b cd)
+#align act_rel_act_of_rel_of_rel act_rel_act_of_rel_of_rel
 
 end MEqN
 
@@ -208,6 +223,7 @@ variable {M N μ r} [ContravariantClass M N μ r]
 
 theorem rel_of_act_rel_act (m : M) {a b : N} (ab : r (μ m a) (μ m b)) : r a b :=
   ContravariantClass.elim _ ab
+#align rel_of_act_rel_act rel_of_act_rel_act
 
 section Trans
 
@@ -217,10 +233,12 @@ variable [IsTrans N r] (m n : M) {a b c d : N}
 theorem act_rel_of_act_rel_of_rel_act_rel (ab : r (μ m a) b) (rl : r (μ m b) (μ m c)) :
     r (μ m a) c :=
   _root_.trans ab (rel_of_act_rel_act m rl)
+#align act_rel_of_act_rel_of_rel_act_rel act_rel_of_act_rel_of_rel_act_rel
 
 theorem rel_act_of_act_rel_act_of_rel_act (ab : r (μ m a) (μ m b)) (rr : r b (μ m c)) :
     r a (μ m c) :=
   _root_.trans (rel_of_act_rel_act m ab) rr
+#align rel_act_of_act_rel_act_of_rel_act rel_act_of_act_rel_act_of_rel_act
 
 end Trans
 
@@ -235,28 +253,33 @@ variable {f : N → α}
 /-- The partial application of a constant to a covariant operator is monotone. -/
 theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M) : Monotone (μ m) :=
   fun _ _ ha ↦ CovariantClass.elim m ha
+#align covariant.monotone_of_const Covariant.monotone_of_const
 
 /-- A monotone function remains monotone when composed with the partial application
 of a covariant operator. E.g., `∀ (m : ℕ), Monotone f → Monotone (λ n, f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
     Monotone fun n ↦ f (μ m n) :=
   fun _ _ x ↦ hf (Covariant.monotone_of_const m x)
+#align monotone.covariant_of_const Monotone.covariant_of_const
 
 /-- Same as `Monotone.covariant_of_const`, but with the constant on the other side of
 the operator.  E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Monotone f) (m : N) : Monotone fun n ↦ f (μ n m) :=
   fun _ _ x ↦ hf (@Covariant.monotone_of_const _ _ (swap μ) _ _ m _ _ x)
+#align monotone.covariant_of_const' Monotone.covariant_of_const'
 
 /-- Dual of `Monotone.covariant_of_const` -/
 theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Antitone f) (m : M) :
     Antitone fun n ↦ f (μ m n) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
+#align antitone.covariant_of_const Antitone.covariant_of_const
 
 /-- Dual of `Monotone.covariant_of_const'` -/
 theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Antitone f) (m : N) : Antitone fun n ↦ f (μ n m) :=
   hf.comp_monotone <| @Covariant.monotone_of_const _ _ (swap μ) _ _ m
+#align antitone.covariant_of_const' Antitone.covariant_of_const'
 
 end Monotone
 
@@ -266,21 +289,25 @@ theorem covariant_le_of_covariant_lt [PartialOrder N] :
   rcases le_iff_eq_or_lt.mp bc with (rfl | bc)
   · exact rfl.le
   · exact (h _ bc).le
+#align covariant_le_of_covariant_lt covariant_le_of_covariant_lt
 
 theorem contravariant_lt_of_contravariant_le [PartialOrder N] :
     Contravariant M N μ (· ≤ ·) → Contravariant M N μ (· < ·) := by
   refine fun h a b c bc ↦ lt_iff_le_and_ne.mpr ⟨h a bc.le, ?_⟩
   rintro rfl; exact lt_irrefl _ bc
+#align contravariant_lt_of_contravariant_le contravariant_lt_of_contravariant_le
 
 theorem covariant_le_iff_contravariant_lt [LinearOrder N] :
     Covariant M N μ (· ≤ ·) ↔ Contravariant M N μ (· < ·) :=
   ⟨fun h _ _ _ bc ↦ not_le.mp fun k ↦ not_le.mpr bc (h _ k),
    fun h _ _ _ bc ↦ not_lt.mp fun k ↦ not_lt.mpr bc (h _ k)⟩
+#align covariant_le_iff_contravariant_lt covariant_le_iff_contravariant_lt
 
 theorem covariant_lt_iff_contravariant_le [LinearOrder N] :
     Covariant M N μ (· < ·) ↔ Contravariant M N μ (· ≤ ·) :=
   ⟨fun h _ _ _ bc ↦ not_lt.mp fun k ↦ not_lt.mpr bc (h _ k),
    fun h _ _ _ bc ↦ not_le.mp fun k ↦ not_le.mpr bc (h _ k)⟩
+#align covariant_lt_iff_contravariant_le covariant_lt_iff_contravariant_le
 
 -- Porting note: `covariant_flip_mul_iff` used to use the `IsSymmOp` typeclass from Lean 3 core.
 -- To avoid it, we prove the relevant lemma here.
@@ -291,10 +318,14 @@ lemma flip_mul [CommSemigroup N] : (flip (· * ·) : N → N → N) = (· * ·)
 @[to_additive]
 theorem covariant_flip_mul_iff [CommSemigroup N] :
     Covariant N N (flip (· * ·)) r ↔ Covariant N N (· * ·) r := by rw [flip_mul]
+#align covariant_flip_mul_iff covariant_flip_mul_iff
+#align covariant_flip_add_iff covariant_flip_add_iff
 
 @[to_additive]
 theorem contravariant_flip_mul_iff [CommSemigroup N] :
     Contravariant N N (flip (· * ·)) r ↔ Contravariant N N (· * ·) r := by rw [flip_mul]
+#align contravariant_flip_mul_iff contravariant_flip_mul_iff
+#align contravariant_flip_add_iff contravariant_flip_add_iff
 
 @[to_additive]
 instance contravariant_mul_lt_of_covariant_mul_le [Mul N] [LinearOrder N]
chore: fix casing errors per naming scheme (#1670)
Diff
@@ -237,23 +237,23 @@ theorem Covariant.monotone_of_const [CovariantClass M N μ (· ≤ ·)] (m : M)
   fun _ _ ha ↦ CovariantClass.elim m ha
 
 /-- A monotone function remains monotone when composed with the partial application
-of a covariant operator. E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (m + n))`. -/
+of a covariant operator. E.g., `∀ (m : ℕ), Monotone f → Monotone (λ n, f (m + n))`. -/
 theorem Monotone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Monotone f) (m : M) :
     Monotone fun n ↦ f (μ m n) :=
   fun _ _ x ↦ hf (Covariant.monotone_of_const m x)
 
-/-- Same as `monotone.covariant_of_const`, but with the constant on the other side of
+/-- Same as `Monotone.covariant_of_const`, but with the constant on the other side of
 the operator.  E.g., `∀ (m : ℕ), monotone f → monotone (λ n, f (n + m))`. -/
 theorem Monotone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Monotone f) (m : N) : Monotone fun n ↦ f (μ n m) :=
   fun _ _ x ↦ hf (@Covariant.monotone_of_const _ _ (swap μ) _ _ m _ _ x)
 
-/-- Dual of `monotone.covariant_of_const` -/
+/-- Dual of `Monotone.covariant_of_const` -/
 theorem Antitone.covariant_of_const [CovariantClass M N μ (· ≤ ·)] (hf : Antitone f) (m : M) :
     Antitone fun n ↦ f (μ m n) :=
   hf.comp_monotone <| Covariant.monotone_of_const m
 
-/-- Dual of `monotone.covariant_of_const'` -/
+/-- Dual of `Monotone.covariant_of_const'` -/
 theorem Antitone.covariant_of_const' {μ : N → N → N} [CovariantClass N N (swap μ) (· ≤ ·)]
     (hf : Antitone f) (m : N) : Antitone fun n ↦ f (μ n m) :=
   hf.comp_monotone <| @Covariant.monotone_of_const _ _ (swap μ) _ _ m
Feat: prove IsTrans α r → Trans r r r and Trans r r r → IsTrans α r (#1522)

Now Trans.trans conflicts with _root_.trans.

Diff
@@ -57,12 +57,6 @@ typeclass assumptions, since `Function.swap` is slightly better behaved than `fl
 However, sometimes as a **non-typeclass** assumption, we prefer `flip (*)` (or `flip (+)`),
 as it is easier to use.
 
-
-# Porting notes
-
-In mathlib3 we used the `is_trans` typeclass from Lean 3 core,
-and we have switched to the `Trans` typeclass from Lean 4 core.
-
 -/
 
 
@@ -184,14 +178,14 @@ instance (priority := 100) Group.covconv_swap [Group N] [CovariantClass N N (swa
 
 section Trans
 
-variable [Trans r r r] (m n : M) {a b c d : N}
+variable [IsTrans N r] (m n : M) {a b c d : N}
 
 --  Lemmas with 3 elements.
 theorem act_rel_of_rel_of_act_rel (ab : r a b) (rl : r (μ m b) c) : r (μ m a) c :=
-  trans (act_rel_act_of_rel m ab) rl
+  _root_.trans (act_rel_act_of_rel m ab) rl
 
 theorem rel_act_of_rel_of_rel_act (ab : r a b) (rr : r c (μ m a)) : r c (μ m b) :=
-  trans rr (act_rel_act_of_rel _ ab)
+  _root_.trans rr (act_rel_act_of_rel _ ab)
 
 end Trans
 
@@ -200,11 +194,11 @@ end Covariant
 --  Lemma with 4 elements.
 section MEqN
 
-variable {M N μ r} {mu : N → N → N} [Trans r r r] [i : CovariantClass N N mu r]
+variable {M N μ r} {mu : N → N → N} [IsTrans N r] [i : CovariantClass N N mu r]
   [i' : CovariantClass N N (swap mu) r] {a b c d : N}
 
 theorem act_rel_act_of_rel_of_rel (ab : r a b) (cd : r c d) : r (mu a c) (mu b d) :=
-  trans (@act_rel_act_of_rel _ _ (swap mu) r _ c _ _ ab) (act_rel_act_of_rel b cd)
+  _root_.trans (@act_rel_act_of_rel _ _ (swap mu) r _ c _ _ ab) (act_rel_act_of_rel b cd)
 
 end MEqN
 
@@ -217,16 +211,16 @@ theorem rel_of_act_rel_act (m : M) {a b : N} (ab : r (μ m a) (μ m b)) : r a b
 
 section Trans
 
-variable [Trans r r r] (m n : M) {a b c d : N}
+variable [IsTrans N r] (m n : M) {a b c d : N}
 
 --  Lemmas with 3 elements.
 theorem act_rel_of_act_rel_of_rel_act_rel (ab : r (μ m a) b) (rl : r (μ m b) (μ m c)) :
     r (μ m a) c :=
-  trans ab (rel_of_act_rel_act m rl)
+  _root_.trans ab (rel_of_act_rel_act m rl)
 
 theorem rel_act_of_act_rel_act_of_rel_act (ab : r (μ m a) (μ m b)) (rr : r b (μ m c)) :
     r a (μ m c) :=
-  trans (rel_of_act_rel_act m ab) rr
+  _root_.trans (rel_of_act_rel_act m ab) rr
 
 end Trans
 
chore: fix more casing errors per naming scheme (#1232)

I've avoided anything under Tactic or test.

In correcting the names, I found Option.isNone_iff_eq_none duplicated between Std and Mathlib, so the Mathlib one has been removed.

Co-authored-by: Reid Barton <rwbarton@gmail.com>

Diff
@@ -46,7 +46,7 @@ A formal remark is that normally `CovariantClass` uses the `(≤)`-relation, whi
 `ContravariantClass` uses the `(<)`-relation. This need not be the case in general, but seems to be
 the most common usage. In the opposite direction, the implication
 ```lean
-[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] => left_cancel_semigroup α
+[Semigroup α] [PartialOrder α] [ContravariantClass α α (*) (≤)] => LeftCancelSemigroup α
 ```
 holds -- note the `Co*ntra*` assumption on the `(≤)`-relation.
 
@@ -67,8 +67,8 @@ and we have switched to the `Trans` typeclass from Lean 4 core.
 
 
 -- TODO: convert `has_exists_mul_of_le`, `has_exists_add_of_le`?
--- TODO: relationship with `con/add_con`
--- TODO: include equivalence of `left_cancel_semigroup` with
+-- TODO: relationship with `Con/AddCon`
+-- TODO: include equivalence of `LeftCancelSemigroup` with
 -- `Semigroup PartialOrder ContravariantClass α α (*) (≤)`?
 -- TODO : use ⇒, as per Eric's suggestion?  See
 -- https://leanprover.zulipchat.com/#narrow/stream/116395-maths/topic/ordered.20stuff/near/236148738
chore: update SHA in porting header (#1306)

These files correspond to files flagged "The following files have been modified since the commit at which they were verified." by port_status.py but are in sync with mathlib3, so we can update the hash.

I only updated the easy ones, the others need a closer inspection.

Co-authored-by: Reid Barton <rwbarton@gmail.com>

Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
 
 ! This file was ported from Lean 3 source module algebra.covariant_and_contravariant
-! leanprover-community/mathlib commit c4658a649d216f57e99621708b09dcb3dcccbd23
+! leanprover-community/mathlib commit 2258b40dacd2942571c8ce136215350c702dc78f
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
chore: fix casing per naming scheme (#1183)

Fix a lot of wrong casing mostly in the docstrings but also sometimes in def/theorem names. E.g. fin 2 --> Fin 2, add_monoid_hom --> AddMonoidHom

Remove \n from to_additive docstrings that were inserted by mathport.

Move files and directories with Gcd and Smul to GCD and SMul

Diff
@@ -37,7 +37,7 @@ say `[OrderedCancelMonoid M]`, into three typeclasses, e.g.
 `[LeftCancelSemigroup M] [PartialOrder M] [CovariantClass M M (Function.swap (*)) (≤)]`
 and have a go at seeing if the proof still works!
 
-Note that it is possible to combine several co(ntra)variant_class assumptions together.
+Note that it is possible to combine several `Co(ntra)variantClass` assumptions together.
 Indeed, the usual ordered typeclasses arise from assuming the pair
 `[CovariantClass M M (*) (≤)] [ContravariantClass M M (*) (<)]`
 on top of order/algebraic assumptions.
chore: add source headers to ported theory files (#1094)

The script used to do this is included. The yaml file was obtained from https://raw.githubusercontent.com/wiki/leanprover-community/mathlib/mathlib4-port-status.md

Diff
@@ -2,6 +2,11 @@
 Copyright (c) 2021 Damiano Testa. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Damiano Testa
+
+! This file was ported from Lean 3 source module algebra.covariant_and_contravariant
+! leanprover-community/mathlib commit c4658a649d216f57e99621708b09dcb3dcccbd23
+! Please do not edit these lines, except to modify the commit id
+! if you have ported upstream changes.
 -/
 import Mathlib.Algebra.Group.Defs
 import Mathlib.Order.Basic

Dependencies 21

22 files ported (100.0%)
10337 lines ported (100.0%)

All dependencies are ported!