algebra.module.piMathlib.Algebra.Module.Pi

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)

(no changes)

(no changes)

(no changes)

(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)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Simon Hudon, Patrick Massot
 -/
 import Algebra.Module.Basic
-import Algebra.Regular.Smul
+import Algebra.Regular.SMul
 import Algebra.Ring.Pi
 import GroupTheory.GroupAction.Pi
 
Diff
@@ -115,7 +115,7 @@ instance module' {g : I → Type _} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddC
 instance (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i, Module α <| f i]
     [∀ i, NoZeroSMulDivisors α <| f i] : NoZeroSMulDivisors α (∀ i : I, f i) :=
   ⟨fun c x h =>
-    or_iff_not_imp_left.mpr fun hc =>
+    Classical.or_iff_not_imp_left.mpr fun hc =>
       funext fun i => (smul_eq_zero.mp (congr_fun h i)).resolve_left hc⟩
 
 #print Function.noZeroSMulDivisors /-
Diff
@@ -3,10 +3,10 @@ Copyright (c) 2018 Simon Hudon. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Simon Hudon, Patrick Massot
 -/
-import Mathbin.Algebra.Module.Basic
-import Mathbin.Algebra.Regular.Smul
-import Mathbin.Algebra.Ring.Pi
-import Mathbin.GroupTheory.GroupAction.Pi
+import Algebra.Module.Basic
+import Algebra.Regular.Smul
+import Algebra.Ring.Pi
+import GroupTheory.GroupAction.Pi
 
 #align_import algebra.module.pi from "leanprover-community/mathlib"@"be24ec5de6701447e5df5ca75400ffee19d65659"
 
Diff
@@ -2,17 +2,14 @@
 Copyright (c) 2018 Simon Hudon. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Simon Hudon, Patrick Massot
-
-! This file was ported from Lean 3 source module algebra.module.pi
-! leanprover-community/mathlib commit be24ec5de6701447e5df5ca75400ffee19d65659
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Algebra.Module.Basic
 import Mathbin.Algebra.Regular.Smul
 import Mathbin.Algebra.Ring.Pi
 import Mathbin.GroupTheory.GroupAction.Pi
 
+#align_import algebra.module.pi from "leanprover-community/mathlib"@"be24ec5de6701447e5df5ca75400ffee19d65659"
+
 /-!
 # Pi instances for modules
 
Diff
@@ -35,10 +35,12 @@ variable (x y : ∀ i, f i) (i : I)
 
 namespace Pi
 
+#print IsSMulRegular.pi /-
 theorem IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
 #align is_smul_regular.pi IsSMulRegular.pi
+-/
 
 #print Pi.smulWithZero /-
 instance smulWithZero (α) [Zero α] [∀ i, Zero (f i)] [∀ i, SMulWithZero α (f i)] :
@@ -119,12 +121,14 @@ instance (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i, Module
     or_iff_not_imp_left.mpr fun hc =>
       funext fun i => (smul_eq_zero.mp (congr_fun h i)).resolve_left hc⟩
 
+#print Function.noZeroSMulDivisors /-
 /-- A special case of `pi.no_zero_smul_divisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/
 instance Function.noZeroSMulDivisors {ι α β : Type _} {r : Semiring α} {m : AddCommMonoid β}
     [Module α β] [NoZeroSMulDivisors α β] : NoZeroSMulDivisors α (ι → β) :=
   Pi.noZeroSMulDivisors _
 #align function.no_zero_smul_divisors Function.noZeroSMulDivisors
+-/
 
 end Pi
 
Diff
@@ -108,8 +108,8 @@ variable {I f}
 instance module' {g : I → Type _} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddCommMonoid (g i)}
     [∀ i, Module (f i) (g i)] : Module (∀ i, f i) (∀ i, g i)
     where
-  add_smul := by intros ; ext1; apply add_smul
-  zero_smul := by intros ; ext1; apply zero_smul
+  add_smul := by intros; ext1; apply add_smul
+  zero_smul := by intros; ext1; apply zero_smul
 #align pi.module' Pi.module'
 -/
 
Diff
@@ -35,12 +35,6 @@ variable (x y : ∀ i, f i) (i : I)
 
 namespace Pi
 
-/- warning: is_smul_regular.pi -> IsSMulRegular.pi is a dubious translation:
-lean 3 declaration is
-  forall {I : Type.{u1}} {f : I -> Type.{u2}} {α : Type.{u3}} [_inst_1 : forall (i : I), SMul.{u3, u2} α (f i)] {k : α}, (forall (i : I), IsSMulRegular.{u3, u2} α (f i) (_inst_1 i) k) -> (IsSMulRegular.{u3, max u1 u2} α (forall (i : I), f i) (Pi.instSMul.{u1, u2, u3} I α (fun (i : I) => f i) (fun (i : I) => _inst_1 i)) k)
-but is expected to have type
-  forall {I : Type.{u2}} {f : I -> Type.{u3}} {α : Type.{u1}} [_inst_1 : forall (i : I), SMul.{u1, u3} α (f i)] {k : α}, (forall (i : I), IsSMulRegular.{u1, u3} α (f i) (_inst_1 i) k) -> (IsSMulRegular.{u1, max u2 u3} α (forall (i : I), f i) (Pi.instSMul.{u2, u3, u1} I α (fun (i : I) => f i) (fun (i : I) => _inst_1 i)) k)
-Case conversion may be inaccurate. Consider using '#align is_smul_regular.pi IsSMulRegular.piₓ'. -/
 theorem IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
@@ -125,12 +119,6 @@ instance (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i, Module
     or_iff_not_imp_left.mpr fun hc =>
       funext fun i => (smul_eq_zero.mp (congr_fun h i)).resolve_left hc⟩
 
-/- warning: function.no_zero_smul_divisors -> Function.noZeroSMulDivisors is a dubious translation:
-lean 3 declaration is
-  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {r : Semiring.{u2} α} {m : AddCommMonoid.{u3} β} [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)))) (Function.hasSMul.{u1, u2, u3} ι α β (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
-but is expected to have type
-  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [r : Semiring.{u2} α] [m : AddCommMonoid.{u3} β] [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Pi.instSMul.{u1, u3, u2} ι α (fun (a._@.Mathlib.Algebra.Module.Pi._hyg.934 : ι) => β) (fun (i : ι) => SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
-Case conversion may be inaccurate. Consider using '#align function.no_zero_smul_divisors Function.noZeroSMulDivisorsₓ'. -/
 /-- A special case of `pi.no_zero_smul_divisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/
 instance Function.noZeroSMulDivisors {ι α β : Type _} {r : Semiring α} {m : AddCommMonoid β}
Diff
@@ -114,14 +114,8 @@ variable {I f}
 instance module' {g : I → Type _} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddCommMonoid (g i)}
     [∀ i, Module (f i) (g i)] : Module (∀ i, f i) (∀ i, g i)
     where
-  add_smul := by
-    intros
-    ext1
-    apply add_smul
-  zero_smul := by
-    intros
-    ext1
-    apply zero_smul
+  add_smul := by intros ; ext1; apply add_smul
+  zero_smul := by intros ; ext1; apply zero_smul
 #align pi.module' Pi.module'
 -/
 
Diff
@@ -35,16 +35,16 @@ variable (x y : ∀ i, f i) (i : I)
 
 namespace Pi
 
-/- warning: is_smul_regular.pi -> Pi.IsSMulRegular.pi is a dubious translation:
+/- warning: is_smul_regular.pi -> IsSMulRegular.pi is a dubious translation:
 lean 3 declaration is
   forall {I : Type.{u1}} {f : I -> Type.{u2}} {α : Type.{u3}} [_inst_1 : forall (i : I), SMul.{u3, u2} α (f i)] {k : α}, (forall (i : I), IsSMulRegular.{u3, u2} α (f i) (_inst_1 i) k) -> (IsSMulRegular.{u3, max u1 u2} α (forall (i : I), f i) (Pi.instSMul.{u1, u2, u3} I α (fun (i : I) => f i) (fun (i : I) => _inst_1 i)) k)
 but is expected to have type
   forall {I : Type.{u2}} {f : I -> Type.{u3}} {α : Type.{u1}} [_inst_1 : forall (i : I), SMul.{u1, u3} α (f i)] {k : α}, (forall (i : I), IsSMulRegular.{u1, u3} α (f i) (_inst_1 i) k) -> (IsSMulRegular.{u1, max u2 u3} α (forall (i : I), f i) (Pi.instSMul.{u2, u3, u1} I α (fun (i : I) => f i) (fun (i : I) => _inst_1 i)) k)
-Case conversion may be inaccurate. Consider using '#align is_smul_regular.pi Pi.IsSMulRegular.piₓ'. -/
-theorem Pi.IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
+Case conversion may be inaccurate. Consider using '#align is_smul_regular.pi IsSMulRegular.piₓ'. -/
+theorem IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
-#align is_smul_regular.pi Pi.IsSMulRegular.pi
+#align is_smul_regular.pi IsSMulRegular.pi
 
 #print Pi.smulWithZero /-
 instance smulWithZero (α) [Zero α] [∀ i, Zero (f i)] [∀ i, SMulWithZero α (f i)] :
@@ -135,7 +135,7 @@ instance (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i, Module
 lean 3 declaration is
   forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {r : Semiring.{u2} α} {m : AddCommMonoid.{u3} β} [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)))) (Function.hasSMul.{u1, u2, u3} ι α β (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
 but is expected to have type
-  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [r : Semiring.{u2} α] [m : AddCommMonoid.{u3} β] [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Pi.instSMul.{u1, u3, u2} ι α (fun (a._@.Mathlib.Algebra.Module.Pi._hyg.938 : ι) => β) (fun (i : ι) => SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
+  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [r : Semiring.{u2} α] [m : AddCommMonoid.{u3} β] [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Pi.instSMul.{u1, u3, u2} ι α (fun (a._@.Mathlib.Algebra.Module.Pi._hyg.934 : ι) => β) (fun (i : ι) => SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
 Case conversion may be inaccurate. Consider using '#align function.no_zero_smul_divisors Function.noZeroSMulDivisorsₓ'. -/
 /-- A special case of `pi.no_zero_smul_divisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/
Diff
@@ -135,7 +135,7 @@ instance (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i, Module
 lean 3 declaration is
   forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {r : Semiring.{u2} α} {m : AddCommMonoid.{u3} β} [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MulZeroClass.toHasZero.{u2} α (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} α (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} α (Semiring.toNonAssocSemiring.{u2} α r)))) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)))) (Function.hasSMul.{u1, u2, u3} ι α β (SMulZeroClass.toHasSmul.{u2, u3} α β (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (SMulWithZero.toSmulZeroClass.{u2, u3} α β (MulZeroClass.toHasZero.{u2} α (MulZeroOneClass.toMulZeroClass.{u2} α (MonoidWithZero.toMulZeroOneClass.{u2} α (Semiring.toMonoidWithZero.{u2} α r)))) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddZeroClass.toHasZero.{u3} β (AddMonoid.toAddZeroClass.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
 but is expected to have type
-  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {r : Semiring.{u2} α} {m : AddCommMonoid.{u3} β} [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Pi.instSMul.{u1, u3, u2} ι α (fun (a._@.Mathlib.Algebra.Module.Pi._hyg.938 : ι) => β) (fun (i : ι) => SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
+  forall {ι : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [r : Semiring.{u2} α] [m : AddCommMonoid.{u3} β] [_inst_1 : Module.{u2, u3} α β r m] [_inst_2 : NoZeroSMulDivisors.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1))))], NoZeroSMulDivisors.{u2, max u1 u3} α (ι -> β) (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (Pi.instZero.{u1, u3} ι (fun (ᾰ : ι) => β) (fun (i : ι) => AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m))) (Pi.instSMul.{u1, u3, u2} ι α (fun (a._@.Mathlib.Algebra.Module.Pi._hyg.938 : ι) => β) (fun (i : ι) => SMulZeroClass.toSMul.{u2, u3} α β (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (SMulWithZero.toSMulZeroClass.{u2, u3} α β (MonoidWithZero.toZero.{u2} α (Semiring.toMonoidWithZero.{u2} α r)) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (MulActionWithZero.toSMulWithZero.{u2, u3} α β (Semiring.toMonoidWithZero.{u2} α r) (AddMonoid.toZero.{u3} β (AddCommMonoid.toAddMonoid.{u3} β m)) (Module.toMulActionWithZero.{u2, u3} α β r m _inst_1)))))
 Case conversion may be inaccurate. Consider using '#align function.no_zero_smul_divisors Function.noZeroSMulDivisorsₓ'. -/
 /-- A special case of `pi.no_zero_smul_divisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/

Changes in mathlib4

mathlib3
mathlib4
chore: split Algebra.Module.Basic (#12501)

Similar to #12486, which did this for Algebra.Algebra.Basic.

Splits Algebra.Module.Defs off Algebra.Module.Basic. Most imports only need the Defs file, which has significantly smaller imports. The remaining Algebra.Module.Basic is now a grab-bag of unrelated results, and should probably be split further or rehomed.

This is mostly motivated by the wasted effort during minimization upon encountering Algebra.Module.Basic.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>

Diff
@@ -3,7 +3,7 @@ Copyright (c) 2018 Simon Hudon. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Simon Hudon, Patrick Massot
 -/
-import Mathlib.Algebra.Module.Basic
+import Mathlib.Algebra.Module.Defs
 import Mathlib.Algebra.Regular.SMul
 import Mathlib.Algebra.Ring.Pi
 import Mathlib.GroupTheory.GroupAction.Pi
doc: convert many comments into doc comments (#11940)

All of these changes appear to be oversights to me.

Diff
@@ -70,8 +70,7 @@ instance module (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i,
 /- Extra instance to short-circuit type class resolution.
 For unknown reasons, this is necessary for certain inference problems. E.g., for this to succeed:
 ```lean
-example (β X : Type*) [NormedAddCommGroup β] [NormedSpace ℝ β] : Module ℝ (X → β) :=
-inferInstance
+example (β X : Type*) [NormedAddCommGroup β] [NormedSpace ℝ β] : Module ℝ (X → β) := inferInstance
 ```
 See: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/Typeclass.20resolution.20under.20binders/near/281296989
 -/
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
@@ -29,7 +29,7 @@ variable (x y : ∀ i, f i) (i : I)
 
 namespace Pi
 
-theorem _root_.IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
+theorem _root_.IsSMulRegular.pi {α : Type*} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
 #align is_smul_regular.pi IsSMulRegular.pi
@@ -41,7 +41,7 @@ instance smulWithZero (α) [Zero α] [∀ i, Zero (f i)] [∀ i, SMulWithZero α
     zero_smul := fun _ => funext fun _ => zero_smul _ _ }
 #align pi.smul_with_zero Pi.smulWithZero
 
-instance smulWithZero' {g : I → Type _} [∀ i, Zero (g i)] [∀ i, Zero (f i)]
+instance smulWithZero' {g : I → Type*} [∀ i, Zero (g i)] [∀ i, Zero (f i)]
     [∀ i, SMulWithZero (g i) (f i)] : SMulWithZero (∀ i, g i) (∀ i, f i) :=
   { Pi.smul' with
     smul_zero := fun _ => funext fun _ => smul_zero _
@@ -53,7 +53,7 @@ instance mulActionWithZero (α) [MonoidWithZero α] [∀ i, Zero (f i)]
   { Pi.mulAction _, Pi.smulWithZero _ with }
 #align pi.mul_action_with_zero Pi.mulActionWithZero
 
-instance mulActionWithZero' {g : I → Type _} [∀ i, MonoidWithZero (g i)] [∀ i, Zero (f i)]
+instance mulActionWithZero' {g : I → Type*} [∀ i, MonoidWithZero (g i)] [∀ i, Zero (f i)]
     [∀ i, MulActionWithZero (g i) (f i)] : MulActionWithZero (∀ i, g i) (∀ i, f i) :=
   { Pi.mulAction', Pi.smulWithZero' with }
 #align pi.mul_action_with_zero' Pi.mulActionWithZero'
@@ -70,21 +70,21 @@ instance module (α) {r : Semiring α} {m : ∀ i, AddCommMonoid <| f i} [∀ i,
 /- Extra instance to short-circuit type class resolution.
 For unknown reasons, this is necessary for certain inference problems. E.g., for this to succeed:
 ```lean
-example (β X : Type _) [NormedAddCommGroup β] [NormedSpace ℝ β] : Module ℝ (X → β) :=
+example (β X : Type*) [NormedAddCommGroup β] [NormedSpace ℝ β] : Module ℝ (X → β) :=
 inferInstance
 ```
 See: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/Typeclass.20resolution.20under.20binders/near/281296989
 -/
 /-- A special case of `Pi.module` for non-dependent types. Lean struggles to elaborate
 definitions elsewhere in the library without this. -/
-instance Function.module (α β : Type _) [Semiring α] [AddCommMonoid β] [Module α β] :
+instance Function.module (α β : Type*) [Semiring α] [AddCommMonoid β] [Module α β] :
     Module α (I → β) :=
   Pi.module _ _ _
 #align function.module Pi.Function.module
 
 variable {I f}
 
-instance module' {g : I → Type _} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddCommMonoid (g i)}
+instance module' {g : I → Type*} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddCommMonoid (g i)}
     [∀ i, Module (f i) (g i)] : Module (∀ i, f i) (∀ i, g i)
     where
   add_smul := by
@@ -107,7 +107,7 @@ instance noZeroSMulDivisors (α) [Semiring α] [∀ i, AddCommMonoid <| f i]
 
 /-- A special case of `Pi.noZeroSMulDivisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/
-instance _root_.Function.noZeroSMulDivisors {ι α β : Type _} [Semiring α] [AddCommMonoid β]
+instance _root_.Function.noZeroSMulDivisors {ι α β : Type*} [Semiring α] [AddCommMonoid β]
     [Module α β] [NoZeroSMulDivisors α β] : NoZeroSMulDivisors α (ι → β) :=
   Pi.noZeroSMulDivisors _
 #align function.no_zero_smul_divisors Function.noZeroSMulDivisors
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,17 +2,14 @@
 Copyright (c) 2018 Simon Hudon. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Simon Hudon, Patrick Massot
-
-! This file was ported from Lean 3 source module algebra.module.pi
-! leanprover-community/mathlib commit a437a2499163d85d670479f69f625f461cc5fef9
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Algebra.Module.Basic
 import Mathlib.Algebra.Regular.SMul
 import Mathlib.Algebra.Ring.Pi
 import Mathlib.GroupTheory.GroupAction.Pi
 
+#align_import algebra.module.pi from "leanprover-community/mathlib"@"a437a2499163d85d670479f69f625f461cc5fef9"
+
 /-!
 # Pi instances for modules
 
fix: add missing _root_ (#3630)

Mathport doesn't understand this, and apparently nor do many of the humans fixing the errors it creates.

If your #align statement complains the def doesn't exist, don't change the #align; work out why it doesn't exist instead.

Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com> Co-authored-by: Parcly Taxel <reddeloostw@gmail.com>

Diff
@@ -32,10 +32,10 @@ variable (x y : ∀ i, f i) (i : I)
 
 namespace Pi
 
-theorem IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
+theorem _root_.IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
-#align is_smul_regular.pi Pi.IsSMulRegular.pi
+#align is_smul_regular.pi IsSMulRegular.pi
 
 instance smulWithZero (α) [Zero α] [∀ i, Zero (f i)] [∀ i, SMulWithZero α (f i)] :
     SMulWithZero α (∀ i, f i) :=
chore: bump to nightly-2023-04-11 (#3139)
Diff
@@ -101,7 +101,7 @@ instance module' {g : I → Type _} {r : ∀ i, Semiring (f i)} {m : ∀ i, AddC
     rw [zero_smul]
 #align pi.module' Pi.module'
 
-instance noZeroSMulDivisors (α) {_ : Semiring α} {_ : ∀ i, AddCommMonoid <| f i}
+instance noZeroSMulDivisors (α) [Semiring α] [∀ i, AddCommMonoid <| f i]
     [∀ i, Module α <| f i] [∀ i, NoZeroSMulDivisors α <| f i] :
     NoZeroSMulDivisors α (∀ i : I, f i) :=
   ⟨fun {_ _} h =>
@@ -110,7 +110,7 @@ instance noZeroSMulDivisors (α) {_ : Semiring α} {_ : ∀ i, AddCommMonoid <|
 
 /-- A special case of `Pi.noZeroSMulDivisors` for non-dependent types. Lean struggles to
 synthesize this instance by itself elsewhere in the library. -/
-instance _root_.Function.noZeroSMulDivisors {ι α β : Type _} {_ : Semiring α} {_ : AddCommMonoid β}
+instance _root_.Function.noZeroSMulDivisors {ι α β : Type _} [Semiring α] [AddCommMonoid β]
     [Module α β] [NoZeroSMulDivisors α β] : NoZeroSMulDivisors α (ι → β) :=
   Pi.noZeroSMulDivisors _
 #align function.no_zero_smul_divisors Function.noZeroSMulDivisors
chore: fix most phantom #aligns (#1794)
Diff
@@ -35,7 +35,7 @@ namespace Pi
 theorem IsSMulRegular.pi {α : Type _} [∀ i, SMul α <| f i] {k : α}
     (hk : ∀ i, IsSMulRegular (f i) k) : IsSMulRegular (∀ i, f i) k := fun _ _ h =>
   funext fun i => hk i (congr_fun h i : _)
-#align pi.is_smul_regular.pi Pi.IsSMulRegular.pi
+#align is_smul_regular.pi Pi.IsSMulRegular.pi
 
 instance smulWithZero (α) [Zero α] [∀ i, Zero (f i)] [∀ i, SMulWithZero α (f i)] :
     SMulWithZero α (∀ i, f i) :=
@@ -83,7 +83,7 @@ definitions elsewhere in the library without this. -/
 instance Function.module (α β : Type _) [Semiring α] [AddCommMonoid β] [Module α β] :
     Module α (I → β) :=
   Pi.module _ _ _
-#align pi.function.module Pi.Function.module
+#align function.module Pi.Function.module
 
 variable {I f}
 

Dependencies 3 + 145

146 files ported (98.0%)
57931 lines ported (98.2%)
Show graph

The unported dependencies are