geometry.manifold.algebra.smooth_functionsMathlib.Geometry.Manifold.Algebra.SmoothFunctions

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)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -3,7 +3,7 @@ Copyright © 2020 Nicolò Cavalleri. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Nicolò Cavalleri
 -/
-import Mathbin.Geometry.Manifold.Algebra.Structures
+import Geometry.Manifold.Algebra.Structures
 
 #align_import geometry.manifold.algebra.smooth_functions from "leanprover-community/mathlib"@"728ef9dbb281241906f25cbeb30f90d83e0bb451"
 
Diff
@@ -306,11 +306,11 @@ field `𝕜` inherit a vector space structure.
 -/
 
 
-#print SmoothMap.hasSmul /-
-instance hasSmul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+#print SmoothMap.instSMul /-
+instance instSMul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun r f => ⟨r • f, smooth_const.smul f.Smooth⟩⟩
-#align smooth_map.has_smul SmoothMap.hasSmul
+#align smooth_map.has_smul SmoothMap.instSMul
 -/
 
 #print SmoothMap.coe_smul /-
@@ -412,11 +412,11 @@ If `V` is a module over `𝕜`, then we show that the space of smooth functions
 is naturally a vector space over the ring of smooth functions from `N` to `𝕜`. -/
 
 
-#print SmoothMap.instSmul' /-
-instance instSmul' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+#print SmoothMap.instSMul' /-
+instance instSMul' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul C^∞⟮I, N; 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun f g => ⟨fun x => f x • g x, Smooth.smul f.2 g.2⟩⟩
-#align smooth_map.has_smul' SmoothMap.instSmul'
+#align smooth_map.has_smul' SmoothMap.instSMul'
 -/
 
 #print SmoothMap.smul_comp' /-
Diff
@@ -175,9 +175,9 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
     Group C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid with
     inv := fun f => ⟨fun x => (f x)⁻¹, f.Smooth.inv⟩
-    mul_left_inv := fun a => by ext <;> exact mul_left_inv _
+    hMul_left_inv := fun a => by ext <;> exact mul_left_inv _
     div := fun f g => ⟨f / g, f.Smooth.div g.Smooth⟩
-    div_eq_mul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
+    div_eq_hMul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
 #align smooth_map.group SmoothMap.group
 #align smooth_map.add_group SmoothMap.addGroup
 -/
@@ -369,7 +369,7 @@ def C : 𝕜 →+* C^∞⟮I, N; 𝓘(𝕜, A), A⟯
     where
   toFun := fun c : 𝕜 => ⟨fun x => (algebraMap 𝕜 A) c, smooth_const⟩
   map_one' := by ext x <;> exact (algebraMap 𝕜 A).map_one
-  map_mul' c₁ c₂ := by ext x <;> exact (algebraMap 𝕜 A).map_mul _ _
+  map_mul' c₁ c₂ := by ext x <;> exact (algebraMap 𝕜 A).map_hMul _ _
   map_zero' := by ext x <;> exact (algebraMap 𝕜 A).map_zero
   map_add' c₁ c₂ := by ext x <;> exact (algebraMap 𝕜 A).map_add _ _
 #align smooth_map.C SmoothMap.C
@@ -435,7 +435,7 @@ instance module' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
   smul := (· • ·)
   smul_add c f g := by ext x <;> exact smul_add (c x) (f x) (g x)
   add_smul c₁ c₂ f := by ext x <;> exact add_smul (c₁ x) (c₂ x) (f x)
-  mul_smul c₁ c₂ f := by ext x <;> exact mul_smul (c₁ x) (c₂ x) (f x)
+  hMul_smul c₁ c₂ f := by ext x <;> exact mul_smul (c₁ x) (c₂ x) (f x)
   one_smul f := by ext x <;> exact one_smul 𝕜 (f x)
   zero_smul f := by ext x <;> exact zero_smul _ _
   smul_zero r := by ext x <;> exact smul_zero _
Diff
@@ -2,14 +2,11 @@
 Copyright © 2020 Nicolò Cavalleri. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Nicolò Cavalleri
-
-! This file was ported from Lean 3 source module geometry.manifold.algebra.smooth_functions
-! leanprover-community/mathlib commit 728ef9dbb281241906f25cbeb30f90d83e0bb451
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Geometry.Manifold.Algebra.Structures
 
+#align_import geometry.manifold.algebra.smooth_functions from "leanprover-community/mathlib"@"728ef9dbb281241906f25cbeb30f90d83e0bb451"
+
 /-!
 # Algebraic structures over smooth functions
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Nicolò Cavalleri
 
 ! This file was ported from Lean 3 source module geometry.manifold.algebra.smooth_functions
-! leanprover-community/mathlib commit e5ab837fc252451f3eb9124ae6e7b6f57455e7b9
+! leanprover-community/mathlib commit 728ef9dbb281241906f25cbeb30f90d83e0bb451
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -13,6 +13,9 @@ import Mathbin.Geometry.Manifold.Algebra.Structures
 /-!
 # Algebraic structures over smooth functions
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 In this file, we define instances of algebraic structures over smooth functions.
 -/
 
Diff
@@ -32,40 +32,50 @@ variable {𝕜 : Type _} [NontriviallyNormedField 𝕜] {E : Type _} [NormedAddC
 
 namespace SmoothMap
 
+#print SmoothMap.instMul /-
 @[to_additive]
-instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
+instance instMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
     Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.Smooth.mul g.Smooth⟩⟩
-#align smooth_map.has_mul SmoothMap.hasMul
-#align smooth_map.has_add SmoothMap.hasAdd
+#align smooth_map.has_mul SmoothMap.instMul
+#align smooth_map.has_add SmoothMap.instAdd
+-/
 
+#print SmoothMap.coe_mul /-
 @[simp, to_additive]
 theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I, N; I', G⟯) : ⇑(f * g) = f * g :=
   rfl
 #align smooth_map.coe_mul SmoothMap.coe_mul
 #align smooth_map.coe_add SmoothMap.coe_add
+-/
 
+#print SmoothMap.mul_comp /-
 @[simp, to_additive]
 theorem mul_comp {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I'', N'; I', G⟯) (h : C^∞⟮I, N; I'', N'⟯) : (f * g).comp h = f.comp h * g.comp h :=
   by ext <;> simp only [ContMDiffMap.comp_apply, coe_mul, Pi.mul_apply]
 #align smooth_map.mul_comp SmoothMap.mul_comp
 #align smooth_map.add_comp SmoothMap.add_comp
+-/
 
+#print SmoothMap.instOne /-
 @[to_additive]
-instance hasOne {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] :
+instance instOne {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] :
     One C^∞⟮I, N; I', G⟯ :=
   ⟨ContMDiffMap.const (1 : G)⟩
-#align smooth_map.has_one SmoothMap.hasOne
-#align smooth_map.has_zero SmoothMap.hasZero
+#align smooth_map.has_one SmoothMap.instOne
+#align smooth_map.has_zero SmoothMap.instZero
+-/
 
+#print SmoothMap.coe_one /-
 @[simp, to_additive]
 theorem coe_one {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] :
     ⇑(1 : C^∞⟮I, N; I', G⟯) = 1 :=
   rfl
 #align smooth_map.coe_one SmoothMap.coe_one
 #align smooth_map.coe_zero SmoothMap.coe_zero
+-/
 
 section GroupStructure
 
@@ -77,23 +87,28 @@ under pointwise multiplication.
 -/
 
 
+#print SmoothMap.semigroup /-
 @[to_additive]
 instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
-  { SmoothMap.hasMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
+  { SmoothMap.instMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
 #align smooth_map.semigroup SmoothMap.semigroup
 #align smooth_map.add_semigroup SmoothMap.addSemigroup
+-/
 
+#print SmoothMap.monoid /-
 @[to_additive]
 instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
     Monoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.semigroup,
-    SmoothMap.hasOne with
+    SmoothMap.instOne with
     one_mul := fun a => by ext <;> exact one_mul _
     mul_one := fun a => by ext <;> exact mul_one _ }
 #align smooth_map.monoid SmoothMap.monoid
 #align smooth_map.add_monoid SmoothMap.addMonoid
+-/
 
+#print SmoothMap.coeFnMonoidHom /-
 /-- Coercion to a function as an `monoid_hom`. Similar to `monoid_hom.coe_fn`. -/
 @[to_additive "Coercion to a function as an `add_monoid_hom`. Similar to `add_monoid_hom.coe_fn`.",
   simps]
@@ -105,9 +120,11 @@ def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H'
   map_mul' := coe_mul
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
 #align smooth_map.coe_fn_add_monoid_hom SmoothMap.coeFnAddMonoidHom
+-/
 
 variable (I N)
 
+#print SmoothMap.compLeftMonoidHom /-
 /-- For a manifold `N` and a smooth homomorphism `φ` between Lie groups `G'`, `G''`, the
 'left-composition-by-`φ`' group homomorphism from `C^∞⟮I, N; I', G'⟯` to `C^∞⟮I, N; I'', G''⟯`. -/
 @[to_additive
@@ -122,9 +139,11 @@ def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSp
   map_mul' f g := by ext x <;> show φ (f x * g x) = φ (f x) * φ (g x) <;> simp
 #align smooth_map.comp_left_monoid_hom SmoothMap.compLeftMonoidHom
 #align smooth_map.comp_left_add_monoid_hom SmoothMap.compLeftAddMonoidHom
+-/
 
 variable (I') {N}
 
+#print SmoothMap.restrictMonoidHom /-
 /-- For a Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group homomorphism from
 `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`. -/
 @[to_additive
@@ -137,16 +156,20 @@ def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace
   map_mul' f g := rfl
 #align smooth_map.restrict_monoid_hom SmoothMap.restrictMonoidHom
 #align smooth_map.restrict_add_monoid_hom SmoothMap.restrictAddMonoidHom
+-/
 
 variable {I N I' N'}
 
+#print SmoothMap.commMonoid /-
 @[to_additive]
 instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
-  { SmoothMap.monoid, SmoothMap.hasOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
+  { SmoothMap.monoid, SmoothMap.instOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
 #align smooth_map.comm_monoid SmoothMap.commMonoid
 #align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
+-/
 
+#print SmoothMap.group /-
 @[to_additive]
 instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
     Group C^∞⟮I, N; I', G⟯ :=
@@ -157,27 +180,34 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
     div_eq_mul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
 #align smooth_map.group SmoothMap.group
 #align smooth_map.add_group SmoothMap.addGroup
+-/
 
+#print SmoothMap.coe_inv /-
 @[simp, to_additive]
 theorem coe_inv {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
     (f : C^∞⟮I, N; I', G⟯) : ⇑f⁻¹ = f⁻¹ :=
   rfl
 #align smooth_map.coe_inv SmoothMap.coe_inv
 #align smooth_map.coe_neg SmoothMap.coe_neg
+-/
 
+#print SmoothMap.coe_div /-
 @[simp, to_additive]
 theorem coe_div {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
     (f g : C^∞⟮I, N; I', G⟯) : ⇑(f / g) = f / g :=
   rfl
 #align smooth_map.coe_div SmoothMap.coe_div
 #align smooth_map.coe_sub SmoothMap.coe_sub
+-/
 
+#print SmoothMap.commGroup /-
 @[to_additive]
 instance commGroup {G : Type _} [CommGroup G] [TopologicalSpace G] [ChartedSpace H' G]
     [LieGroup I' G] : CommGroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.group, SmoothMap.commMonoid with }
 #align smooth_map.comm_group SmoothMap.commGroup
 #align smooth_map.add_comm_group SmoothMap.addCommGroup
+-/
 
 end GroupStructure
 
@@ -191,6 +221,7 @@ under pointwise multiplication.
 -/
 
 
+#print SmoothMap.semiring /-
 instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : Semiring C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.addCommMonoid,
@@ -200,19 +231,25 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
     zero_mul := fun a => by ext <;> exact MulZeroClass.zero_mul _
     mul_zero := fun a => by ext <;> exact MulZeroClass.mul_zero _ }
 #align smooth_map.semiring SmoothMap.semiring
+-/
 
+#print SmoothMap.ring /-
 instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
     Ring C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.semiring, SmoothMap.addCommGroup with }
 #align smooth_map.ring SmoothMap.ring
+-/
 
+#print SmoothMap.commRing /-
 instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : CommRing C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.semiring, SmoothMap.addCommGroup, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
+-/
 
 variable (I N)
 
+#print SmoothMap.compLeftRingHom /-
 /-- For a manifold `N` and a smooth homomorphism `φ` between smooth rings `R'`, `R''`, the
 'left-composition-by-`φ`' ring homomorphism from `C^∞⟮I, N; I', R'⟯` to `C^∞⟮I, N; I'', R''⟯`. -/
 def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace H' R']
@@ -223,9 +260,11 @@ def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace
     SmoothMap.compLeftAddMonoidHom I N φ.toAddMonoidHom hφ with
     toFun := fun f => ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMDiff x)⟩ }
 #align smooth_map.comp_left_ring_hom SmoothMap.compLeftRingHom
+-/
 
 variable (I') {N}
 
+#print SmoothMap.restrictRingHom /-
 /-- For a "smooth ring" `R` and open sets `U ⊆ V` in `N`, the "restriction" ring homomorphism from
 `C^∞⟮I, V; I', R⟯` to `C^∞⟮I, U; I', R⟯`. -/
 def restrictRingHom (R : Type _) [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
@@ -233,9 +272,11 @@ def restrictRingHom (R : Type _) [Ring R] [TopologicalSpace R] [ChartedSpace H'
   { SmoothMap.restrictMonoidHom I I' R h, SmoothMap.restrictAddMonoidHom I I' R h with
     toFun := fun f => ⟨f ∘ Set.inclusion h, f.Smooth.comp (smooth_inclusion h)⟩ }
 #align smooth_map.restrict_ring_hom SmoothMap.restrictRingHom
+-/
 
 variable {I N I' N'}
 
+#print SmoothMap.coeFnRingHom /-
 /-- Coercion to a function as a `ring_hom`. -/
 @[simps]
 def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
@@ -243,12 +284,15 @@ def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H'
   { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coeFnAddMonoidHom : C^∞⟮I, N; I', R⟯ →+ _) with
     toFun := coeFn }
 #align smooth_map.coe_fn_ring_hom SmoothMap.coeFnRingHom
+-/
 
+#print SmoothMap.evalRingHom /-
 /-- `function.eval` as a `ring_hom` on the ring of smooth functions. -/
 def evalRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
     (n : N) : C^∞⟮I, N; I', R⟯ →+* R :=
   (Pi.evalRingHom _ n : (N → R) →+* R).comp SmoothMap.coeFnRingHom
 #align smooth_map.eval_ring_hom SmoothMap.evalRingHom
+-/
 
 end RingStructure
 
@@ -262,28 +306,37 @@ field `𝕜` inherit a vector space structure.
 -/
 
 
+#print SmoothMap.hasSmul /-
 instance hasSmul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun r f => ⟨r • f, smooth_const.smul f.Smooth⟩⟩
 #align smooth_map.has_smul SmoothMap.hasSmul
+-/
 
+#print SmoothMap.coe_smul /-
 @[simp]
 theorem coe_smul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
     (f : C^∞⟮I, N; 𝓘(𝕜, V), V⟯) : ⇑(r • f) = r • f :=
   rfl
 #align smooth_map.coe_smul SmoothMap.coe_smul
+-/
 
+#print SmoothMap.smul_comp /-
 @[simp]
 theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
     (g : C^∞⟮I'', N'; 𝓘(𝕜, V), V⟯) (h : C^∞⟮I, N; I'', N'⟯) : (r • g).comp h = r • g.comp h :=
   rfl
 #align smooth_map.smul_comp SmoothMap.smul_comp
+-/
 
+#print SmoothMap.module /-
 instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   Function.Injective.module 𝕜 coeFnAddMonoidHom ContMDiffMap.coe_injective coe_smul
 #align smooth_map.module SmoothMap.module
+-/
 
+#print SmoothMap.coeFnLinearMap /-
 /-- Coercion to a function as a `linear_map`. -/
 @[simps]
 def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
@@ -294,6 +347,7 @@ def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     toFun := coeFn
     map_smul' := coe_smul }
 #align smooth_map.coe_fn_linear_map SmoothMap.coeFnLinearMap
+-/
 
 end ModuleStructure
 
@@ -309,25 +363,30 @@ inherit an algebra structure.
 
 variable {A : Type _} [NormedRing A] [NormedAlgebra 𝕜 A] [SmoothRing 𝓘(𝕜, A) A]
 
+#print SmoothMap.C /-
 /-- Smooth constant functions as a `ring_hom`. -/
-def c : 𝕜 →+* C^∞⟮I, N; 𝓘(𝕜, A), A⟯
+def C : 𝕜 →+* C^∞⟮I, N; 𝓘(𝕜, A), A⟯
     where
   toFun := fun c : 𝕜 => ⟨fun x => (algebraMap 𝕜 A) c, smooth_const⟩
   map_one' := by ext x <;> exact (algebraMap 𝕜 A).map_one
   map_mul' c₁ c₂ := by ext x <;> exact (algebraMap 𝕜 A).map_mul _ _
   map_zero' := by ext x <;> exact (algebraMap 𝕜 A).map_zero
   map_add' c₁ c₂ := by ext x <;> exact (algebraMap 𝕜 A).map_add _ _
-#align smooth_map.C SmoothMap.c
+#align smooth_map.C SmoothMap.C
+-/
 
+#print SmoothMap.algebra /-
 instance algebra : Algebra 𝕜 C^∞⟮I, N; 𝓘(𝕜, A), A⟯ :=
   {
     SmoothMap.semiring with
     smul := fun r f => ⟨r • f, smooth_const.smul f.Smooth⟩
-    toRingHom := SmoothMap.c
+    toRingHom := SmoothMap.C
     commutes' := fun c f => by ext x <;> exact Algebra.commutes' _ _
     smul_def' := fun c f => by ext x <;> exact Algebra.smul_def' _ _ }
 #align smooth_map.algebra SmoothMap.algebra
+-/
 
+#print SmoothMap.coeFnAlgHom /-
 /-- Coercion to a function as an `alg_hom`. -/
 @[simps]
 def coeFnAlgHom : C^∞⟮I, N; 𝓘(𝕜, A), A⟯ →ₐ[𝕜] N → A
@@ -340,6 +399,7 @@ def coeFnAlgHom : C^∞⟮I, N; 𝓘(𝕜, A), A⟯ →ₐ[𝕜] N → A
   map_add' := SmoothMap.coe_add
   map_mul' := SmoothMap.coe_mul
 #align smooth_map.coe_fn_alg_hom SmoothMap.coeFnAlgHom
+-/
 
 end AlgebraStructure
 
@@ -352,18 +412,23 @@ If `V` is a module over `𝕜`, then we show that the space of smooth functions
 is naturally a vector space over the ring of smooth functions from `N` to `𝕜`. -/
 
 
-instance hasSmul' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+#print SmoothMap.instSmul' /-
+instance instSmul' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul C^∞⟮I, N; 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun f g => ⟨fun x => f x • g x, Smooth.smul f.2 g.2⟩⟩
-#align smooth_map.has_smul' SmoothMap.hasSmul'
+#align smooth_map.has_smul' SmoothMap.instSmul'
+-/
 
+#print SmoothMap.smul_comp' /-
 @[simp]
 theorem smul_comp' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (f : C^∞⟮I'', N'; 𝕜⟯)
     (g : C^∞⟮I'', N'; 𝓘(𝕜, V), V⟯) (h : C^∞⟮I, N; I'', N'⟯) :
     (f • g).comp h = f.comp h • g.comp h :=
   rfl
 #align smooth_map.smul_comp' SmoothMap.smul_comp'
+-/
 
+#print SmoothMap.module' /-
 instance module' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module C^∞⟮I, N; 𝓘(𝕜), 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯
     where
@@ -375,6 +440,7 @@ instance module' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
   zero_smul f := by ext x <;> exact zero_smul _ _
   smul_zero r := by ext x <;> exact smul_zero _
 #align smooth_map.module' SmoothMap.module'
+-/
 
 end ModuleOverContinuousFunctions
 
Diff
@@ -33,21 +33,21 @@ variable {𝕜 : Type _} [NontriviallyNormedField 𝕜] {E : Type _} [NormedAddC
 namespace SmoothMap
 
 @[to_additive]
-instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G] :
+instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
     Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.Smooth.mul g.Smooth⟩⟩
 #align smooth_map.has_mul SmoothMap.hasMul
 #align smooth_map.has_add SmoothMap.hasAdd
 
 @[simp, to_additive]
-theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
+theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I, N; I', G⟯) : ⇑(f * g) = f * g :=
   rfl
 #align smooth_map.coe_mul SmoothMap.coe_mul
 #align smooth_map.coe_add SmoothMap.coe_add
 
 @[simp, to_additive]
-theorem mul_comp {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
+theorem mul_comp {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I'', N'; I', G⟯) (h : C^∞⟮I, N; I'', N'⟯) : (f * g).comp h = f.comp h * g.comp h :=
   by ext <;> simp only [ContMDiffMap.comp_apply, coe_mul, Pi.mul_apply]
 #align smooth_map.mul_comp SmoothMap.mul_comp
@@ -79,14 +79,14 @@ under pointwise multiplication.
 
 @[to_additive]
 instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace H' G]
-    [HasSmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
+    [SmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.hasMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
 #align smooth_map.semigroup SmoothMap.semigroup
 #align smooth_map.add_semigroup SmoothMap.addSemigroup
 
 @[to_additive]
-instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
-    [HasSmoothMul I' G] : Monoid C^∞⟮I, N; I', G⟯ :=
+instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
+    Monoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.semigroup,
     SmoothMap.hasOne with
     one_mul := fun a => by ext <;> exact one_mul _
@@ -98,7 +98,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
 @[to_additive "Coercion to a function as an `add_monoid_hom`. Similar to `add_monoid_hom.coe_fn`.",
   simps]
 def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
-    [HasSmoothMul I' G] : C^∞⟮I, N; I', G⟯ →* N → G
+    [SmoothMul I' G] : C^∞⟮I, N; I', G⟯ →* N → G
     where
   toFun := coeFn
   map_one' := coe_one
@@ -113,8 +113,8 @@ variable (I N)
 @[to_additive
       "For a manifold `N` and a smooth homomorphism `φ` between additive Lie groups `G'`,\n`G''`, the 'left-composition-by-`φ`' group homomorphism from `C^∞⟮I, N; I', G'⟯` to\n`C^∞⟮I, N; I'', G''⟯`."]
 def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSpace H' G']
-    [HasSmoothMul I' G'] {G'' : Type _} [Monoid G''] [TopologicalSpace G''] [ChartedSpace H'' G'']
-    [HasSmoothMul I'' G''] (φ : G' →* G'') (hφ : Smooth I' I'' φ) :
+    [SmoothMul I' G'] {G'' : Type _} [Monoid G''] [TopologicalSpace G''] [ChartedSpace H'' G'']
+    [SmoothMul I'' G''] (φ : G' →* G'') (hφ : Smooth I' I'' φ) :
     C^∞⟮I, N; I', G'⟯ →* C^∞⟮I, N; I'', G''⟯
     where
   toFun f := ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMDiff x)⟩
@@ -130,7 +130,7 @@ variable (I') {N}
 @[to_additive
       "For an additive Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group\nhomomorphism from `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`."]
 def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
-    [HasSmoothMul I' G] {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', G⟯ →* C^∞⟮I, U; I', G⟯
+    [SmoothMul I' G] {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', G⟯ →* C^∞⟮I, U; I', G⟯
     where
   toFun f := ⟨f ∘ Set.inclusion h, f.Smooth.comp (smooth_inclusion h)⟩
   map_one' := rfl
@@ -142,7 +142,7 @@ variable {I N I' N'}
 
 @[to_additive]
 instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
-    [HasSmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
+    [SmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid, SmoothMap.hasOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
 #align smooth_map.comm_monoid SmoothMap.commMonoid
 #align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
Diff
@@ -37,7 +37,7 @@ instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [H
     Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.Smooth.mul g.Smooth⟩⟩
 #align smooth_map.has_mul SmoothMap.hasMul
-#align smooth_map.has_add SmoothMap.has_add
+#align smooth_map.has_add SmoothMap.hasAdd
 
 @[simp, to_additive]
 theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
@@ -82,7 +82,7 @@ instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace
     [HasSmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.hasMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
 #align smooth_map.semigroup SmoothMap.semigroup
-#align smooth_map.add_semigroup SmoothMap.add_semigroup
+#align smooth_map.add_semigroup SmoothMap.addSemigroup
 
 @[to_additive]
 instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
@@ -92,7 +92,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     one_mul := fun a => by ext <;> exact one_mul _
     mul_one := fun a => by ext <;> exact mul_one _ }
 #align smooth_map.monoid SmoothMap.monoid
-#align smooth_map.add_monoid SmoothMap.add_monoid
+#align smooth_map.add_monoid SmoothMap.addMonoid
 
 /-- Coercion to a function as an `monoid_hom`. Similar to `monoid_hom.coe_fn`. -/
 @[to_additive "Coercion to a function as an `add_monoid_hom`. Similar to `add_monoid_hom.coe_fn`.",
@@ -104,7 +104,7 @@ def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H'
   map_one' := coe_one
   map_mul' := coe_mul
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
-#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coe_fn_add_monoid_hom
+#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coeFnAddMonoidHom
 
 variable (I N)
 
@@ -121,7 +121,7 @@ def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSp
   map_one' := by ext x <;> show φ 1 = 1 <;> simp
   map_mul' f g := by ext x <;> show φ (f x * g x) = φ (f x) * φ (g x) <;> simp
 #align smooth_map.comp_left_monoid_hom SmoothMap.compLeftMonoidHom
-#align smooth_map.comp_left_add_monoid_hom SmoothMap.comp_left_add_monoid_hom
+#align smooth_map.comp_left_add_monoid_hom SmoothMap.compLeftAddMonoidHom
 
 variable (I') {N}
 
@@ -136,7 +136,7 @@ def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace
   map_one' := rfl
   map_mul' f g := rfl
 #align smooth_map.restrict_monoid_hom SmoothMap.restrictMonoidHom
-#align smooth_map.restrict_add_monoid_hom SmoothMap.restrict_add_monoid_hom
+#align smooth_map.restrict_add_monoid_hom SmoothMap.restrictAddMonoidHom
 
 variable {I N I' N'}
 
@@ -145,7 +145,7 @@ instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpa
     [HasSmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid, SmoothMap.hasOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
 #align smooth_map.comm_monoid SmoothMap.commMonoid
-#align smooth_map.add_comm_monoid SmoothMap.add_comm_monoid
+#align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
 
 @[to_additive]
 instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
@@ -156,7 +156,7 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
     div := fun f g => ⟨f / g, f.Smooth.div g.Smooth⟩
     div_eq_mul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
 #align smooth_map.group SmoothMap.group
-#align smooth_map.add_group SmoothMap.add_group
+#align smooth_map.add_group SmoothMap.addGroup
 
 @[simp, to_additive]
 theorem coe_inv {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
@@ -177,7 +177,7 @@ instance commGroup {G : Type _} [CommGroup G] [TopologicalSpace G] [ChartedSpace
     [LieGroup I' G] : CommGroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.group, SmoothMap.commMonoid with }
 #align smooth_map.comm_group SmoothMap.commGroup
-#align smooth_map.add_comm_group SmoothMap.add_comm_group
+#align smooth_map.add_comm_group SmoothMap.addCommGroup
 
 end GroupStructure
 
@@ -193,7 +193,7 @@ under pointwise multiplication.
 
 instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : Semiring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.add_comm_monoid,
+  { SmoothMap.addCommMonoid,
     SmoothMap.monoid with
     left_distrib := fun a b c => by ext <;> exact left_distrib _ _ _
     right_distrib := fun a b c => by ext <;> exact right_distrib _ _ _
@@ -203,12 +203,12 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
 
 instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
     Ring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.add_comm_group with }
+  { SmoothMap.semiring, SmoothMap.addCommGroup with }
 #align smooth_map.ring SmoothMap.ring
 
 instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : CommRing C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.add_comm_group, SmoothMap.commMonoid with }
+  { SmoothMap.semiring, SmoothMap.addCommGroup, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
 
 variable (I N)
@@ -220,7 +220,7 @@ def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace
     [SmoothRing I'' R''] (φ : R' →+* R'') (hφ : Smooth I' I'' φ) :
     C^∞⟮I, N; I', R'⟯ →+* C^∞⟮I, N; I'', R''⟯ :=
   { SmoothMap.compLeftMonoidHom I N φ.toMonoidHom hφ,
-    SmoothMap.comp_left_add_monoid_hom I N φ.toAddMonoidHom hφ with
+    SmoothMap.compLeftAddMonoidHom I N φ.toAddMonoidHom hφ with
     toFun := fun f => ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMDiff x)⟩ }
 #align smooth_map.comp_left_ring_hom SmoothMap.compLeftRingHom
 
@@ -230,7 +230,7 @@ variable (I') {N}
 `C^∞⟮I, V; I', R⟯` to `C^∞⟮I, U; I', R⟯`. -/
 def restrictRingHom (R : Type _) [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
     {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', R⟯ →+* C^∞⟮I, U; I', R⟯ :=
-  { SmoothMap.restrictMonoidHom I I' R h, SmoothMap.restrict_add_monoid_hom I I' R h with
+  { SmoothMap.restrictMonoidHom I I' R h, SmoothMap.restrictAddMonoidHom I I' R h with
     toFun := fun f => ⟨f ∘ Set.inclusion h, f.Smooth.comp (smooth_inclusion h)⟩ }
 #align smooth_map.restrict_ring_hom SmoothMap.restrictRingHom
 
@@ -240,7 +240,7 @@ variable {I N I' N'}
 @[simps]
 def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : C^∞⟮I, N; I', R⟯ →+* N → R :=
-  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coe_fn_add_monoid_hom : C^∞⟮I, N; I', R⟯ →+ _) with
+  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coeFnAddMonoidHom : C^∞⟮I, N; I', R⟯ →+ _) with
     toFun := coeFn }
 #align smooth_map.coe_fn_ring_hom SmoothMap.coeFnRingHom
 
@@ -281,7 +281,7 @@ theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r :
 
 instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
-  Function.Injective.module 𝕜 coe_fn_add_monoid_hom ContMDiffMap.coe_injective coe_smul
+  Function.Injective.module 𝕜 coeFnAddMonoidHom ContMDiffMap.coe_injective coe_smul
 #align smooth_map.module SmoothMap.module
 
 /-- Coercion to a function as a `linear_map`. -/
@@ -289,8 +289,8 @@ instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
 def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →ₗ[𝕜] N → V :=
   {
-    (coe_fn_add_monoid_hom :
-      C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+ _) with
+    (coeFnAddMonoidHom : C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+
+        _) with
     toFun := coeFn
     map_smul' := coe_smul }
 #align smooth_map.coe_fn_linear_map SmoothMap.coeFnLinearMap
Diff
@@ -49,14 +49,14 @@ theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [H
 @[simp, to_additive]
 theorem mul_comp {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
     (f g : C^∞⟮I'', N'; I', G⟯) (h : C^∞⟮I, N; I'', N'⟯) : (f * g).comp h = f.comp h * g.comp h :=
-  by ext <;> simp only [ContMdiffMap.comp_apply, coe_mul, Pi.mul_apply]
+  by ext <;> simp only [ContMDiffMap.comp_apply, coe_mul, Pi.mul_apply]
 #align smooth_map.mul_comp SmoothMap.mul_comp
 #align smooth_map.add_comp SmoothMap.add_comp
 
 @[to_additive]
 instance hasOne {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] :
     One C^∞⟮I, N; I', G⟯ :=
-  ⟨ContMdiffMap.const (1 : G)⟩
+  ⟨ContMDiffMap.const (1 : G)⟩
 #align smooth_map.has_one SmoothMap.hasOne
 #align smooth_map.has_zero SmoothMap.hasZero
 
@@ -281,7 +281,7 @@ theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r :
 
 instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
-  Function.Injective.module 𝕜 coe_fn_add_monoid_hom ContMdiffMap.coe_inj coe_smul
+  Function.Injective.module 𝕜 coe_fn_add_monoid_hom ContMDiffMap.coe_injective coe_smul
 #align smooth_map.module SmoothMap.module
 
 /-- Coercion to a function as a `linear_map`. -/
Diff
@@ -117,7 +117,7 @@ def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSp
     [HasSmoothMul I'' G''] (φ : G' →* G'') (hφ : Smooth I' I'' φ) :
     C^∞⟮I, N; I', G'⟯ →* C^∞⟮I, N; I'', G''⟯
     where
-  toFun f := ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMdiff x)⟩
+  toFun f := ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMDiff x)⟩
   map_one' := by ext x <;> show φ 1 = 1 <;> simp
   map_mul' f g := by ext x <;> show φ (f x * g x) = φ (f x) * φ (g x) <;> simp
 #align smooth_map.comp_left_monoid_hom SmoothMap.compLeftMonoidHom
@@ -221,7 +221,7 @@ def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace
     C^∞⟮I, N; I', R'⟯ →+* C^∞⟮I, N; I'', R''⟯ :=
   { SmoothMap.compLeftMonoidHom I N φ.toMonoidHom hφ,
     SmoothMap.comp_left_add_monoid_hom I N φ.toAddMonoidHom hφ with
-    toFun := fun f => ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMdiff x)⟩ }
+    toFun := fun f => ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMDiff x)⟩ }
 #align smooth_map.comp_left_ring_hom SmoothMap.compLeftRingHom
 
 variable (I') {N}
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Nicolò Cavalleri
 
 ! This file was ported from Lean 3 source module geometry.manifold.algebra.smooth_functions
-! leanprover-community/mathlib commit d1bd9c5df2867c1cb463bc6364446d57bdd9f7f1
+! leanprover-community/mathlib commit e5ab837fc252451f3eb9124ae6e7b6f57455e7b9
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -21,6 +21,8 @@ noncomputable section
 
 open scoped Manifold
 
+open TopologicalSpace
+
 variable {𝕜 : Type _} [NontriviallyNormedField 𝕜] {E : Type _} [NormedAddCommGroup E]
   [NormedSpace 𝕜 E] {E' : Type _} [NormedAddCommGroup E'] [NormedSpace 𝕜 E'] {H : Type _}
   [TopologicalSpace H] {I : ModelWithCorners 𝕜 E H} {H' : Type _} [TopologicalSpace H']
@@ -104,6 +106,40 @@ def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H'
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
 #align smooth_map.coe_fn_add_monoid_hom SmoothMap.coe_fn_add_monoid_hom
 
+variable (I N)
+
+/-- For a manifold `N` and a smooth homomorphism `φ` between Lie groups `G'`, `G''`, the
+'left-composition-by-`φ`' group homomorphism from `C^∞⟮I, N; I', G'⟯` to `C^∞⟮I, N; I'', G''⟯`. -/
+@[to_additive
+      "For a manifold `N` and a smooth homomorphism `φ` between additive Lie groups `G'`,\n`G''`, the 'left-composition-by-`φ`' group homomorphism from `C^∞⟮I, N; I', G'⟯` to\n`C^∞⟮I, N; I'', G''⟯`."]
+def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSpace H' G']
+    [HasSmoothMul I' G'] {G'' : Type _} [Monoid G''] [TopologicalSpace G''] [ChartedSpace H'' G'']
+    [HasSmoothMul I'' G''] (φ : G' →* G'') (hφ : Smooth I' I'' φ) :
+    C^∞⟮I, N; I', G'⟯ →* C^∞⟮I, N; I'', G''⟯
+    where
+  toFun f := ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMdiff x)⟩
+  map_one' := by ext x <;> show φ 1 = 1 <;> simp
+  map_mul' f g := by ext x <;> show φ (f x * g x) = φ (f x) * φ (g x) <;> simp
+#align smooth_map.comp_left_monoid_hom SmoothMap.compLeftMonoidHom
+#align smooth_map.comp_left_add_monoid_hom SmoothMap.comp_left_add_monoid_hom
+
+variable (I') {N}
+
+/-- For a Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group homomorphism from
+`C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`. -/
+@[to_additive
+      "For an additive Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group\nhomomorphism from `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`."]
+def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
+    [HasSmoothMul I' G] {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', G⟯ →* C^∞⟮I, U; I', G⟯
+    where
+  toFun f := ⟨f ∘ Set.inclusion h, f.Smooth.comp (smooth_inclusion h)⟩
+  map_one' := rfl
+  map_mul' f g := rfl
+#align smooth_map.restrict_monoid_hom SmoothMap.restrictMonoidHom
+#align smooth_map.restrict_add_monoid_hom SmoothMap.restrict_add_monoid_hom
+
+variable {I N I' N'}
+
 @[to_additive]
 instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [HasSmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
@@ -175,6 +211,31 @@ instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H
   { SmoothMap.semiring, SmoothMap.add_comm_group, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
 
+variable (I N)
+
+/-- For a manifold `N` and a smooth homomorphism `φ` between smooth rings `R'`, `R''`, the
+'left-composition-by-`φ`' ring homomorphism from `C^∞⟮I, N; I', R'⟯` to `C^∞⟮I, N; I'', R''⟯`. -/
+def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace H' R']
+    [SmoothRing I' R'] {R'' : Type _} [Ring R''] [TopologicalSpace R''] [ChartedSpace H'' R'']
+    [SmoothRing I'' R''] (φ : R' →+* R'') (hφ : Smooth I' I'' φ) :
+    C^∞⟮I, N; I', R'⟯ →+* C^∞⟮I, N; I'', R''⟯ :=
+  { SmoothMap.compLeftMonoidHom I N φ.toMonoidHom hφ,
+    SmoothMap.comp_left_add_monoid_hom I N φ.toAddMonoidHom hφ with
+    toFun := fun f => ⟨φ ∘ f, fun x => (hφ.Smooth _).comp x (f.ContMdiff x)⟩ }
+#align smooth_map.comp_left_ring_hom SmoothMap.compLeftRingHom
+
+variable (I') {N}
+
+/-- For a "smooth ring" `R` and open sets `U ⊆ V` in `N`, the "restriction" ring homomorphism from
+`C^∞⟮I, V; I', R⟯` to `C^∞⟮I, U; I', R⟯`. -/
+def restrictRingHom (R : Type _) [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
+    {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', R⟯ →+* C^∞⟮I, U; I', R⟯ :=
+  { SmoothMap.restrictMonoidHom I I' R h, SmoothMap.restrict_add_monoid_hom I I' R h with
+    toFun := fun f => ⟨f ∘ Set.inclusion h, f.Smooth.comp (smooth_inclusion h)⟩ }
+#align smooth_map.restrict_ring_hom SmoothMap.restrictRingHom
+
+variable {I N I' N'}
+
 /-- Coercion to a function as a `ring_hom`. -/
 @[simps]
 def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
Diff
@@ -19,7 +19,7 @@ In this file, we define instances of algebraic structures over smooth functions.
 
 noncomputable section
 
-open Manifold
+open scoped Manifold
 
 variable {𝕜 : Type _} [NontriviallyNormedField 𝕜] {E : Type _} [NormedAddCommGroup E]
   [NormedSpace 𝕜 E] {E' : Type _} [NormedAddCommGroup E'] [NormedSpace 𝕜 E'] {H : Type _}
Diff
@@ -35,7 +35,7 @@ instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [H
     Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.Smooth.mul g.Smooth⟩⟩
 #align smooth_map.has_mul SmoothMap.hasMul
-#align smooth_map.has_add SmoothMap.hasAdd
+#align smooth_map.has_add SmoothMap.has_add
 
 @[simp, to_additive]
 theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
@@ -80,7 +80,7 @@ instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace
     [HasSmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.hasMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
 #align smooth_map.semigroup SmoothMap.semigroup
-#align smooth_map.add_semigroup SmoothMap.addSemigroup
+#align smooth_map.add_semigroup SmoothMap.add_semigroup
 
 @[to_additive]
 instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
@@ -90,7 +90,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     one_mul := fun a => by ext <;> exact one_mul _
     mul_one := fun a => by ext <;> exact mul_one _ }
 #align smooth_map.monoid SmoothMap.monoid
-#align smooth_map.add_monoid SmoothMap.addMonoid
+#align smooth_map.add_monoid SmoothMap.add_monoid
 
 /-- Coercion to a function as an `monoid_hom`. Similar to `monoid_hom.coe_fn`. -/
 @[to_additive "Coercion to a function as an `add_monoid_hom`. Similar to `add_monoid_hom.coe_fn`.",
@@ -102,14 +102,14 @@ def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H'
   map_one' := coe_one
   map_mul' := coe_mul
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
-#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coeFnAddMonoidHom
+#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coe_fn_add_monoid_hom
 
 @[to_additive]
 instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [HasSmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid, SmoothMap.hasOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
 #align smooth_map.comm_monoid SmoothMap.commMonoid
-#align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
+#align smooth_map.add_comm_monoid SmoothMap.add_comm_monoid
 
 @[to_additive]
 instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
@@ -120,7 +120,7 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
     div := fun f g => ⟨f / g, f.Smooth.div g.Smooth⟩
     div_eq_mul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
 #align smooth_map.group SmoothMap.group
-#align smooth_map.add_group SmoothMap.addGroup
+#align smooth_map.add_group SmoothMap.add_group
 
 @[simp, to_additive]
 theorem coe_inv {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
@@ -141,7 +141,7 @@ instance commGroup {G : Type _} [CommGroup G] [TopologicalSpace G] [ChartedSpace
     [LieGroup I' G] : CommGroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.group, SmoothMap.commMonoid with }
 #align smooth_map.comm_group SmoothMap.commGroup
-#align smooth_map.add_comm_group SmoothMap.addCommGroup
+#align smooth_map.add_comm_group SmoothMap.add_comm_group
 
 end GroupStructure
 
@@ -157,7 +157,7 @@ under pointwise multiplication.
 
 instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : Semiring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.addCommMonoid,
+  { SmoothMap.add_comm_monoid,
     SmoothMap.monoid with
     left_distrib := fun a b c => by ext <;> exact left_distrib _ _ _
     right_distrib := fun a b c => by ext <;> exact right_distrib _ _ _
@@ -167,19 +167,19 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
 
 instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
     Ring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.addCommGroup with }
+  { SmoothMap.semiring, SmoothMap.add_comm_group with }
 #align smooth_map.ring SmoothMap.ring
 
 instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : CommRing C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.addCommGroup, SmoothMap.commMonoid with }
+  { SmoothMap.semiring, SmoothMap.add_comm_group, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
 
 /-- Coercion to a function as a `ring_hom`. -/
 @[simps]
 def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : C^∞⟮I, N; I', R⟯ →+* N → R :=
-  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coeFnAddMonoidHom : C^∞⟮I, N; I', R⟯ →+ _) with
+  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coe_fn_add_monoid_hom : C^∞⟮I, N; I', R⟯ →+ _) with
     toFun := coeFn }
 #align smooth_map.coe_fn_ring_hom SmoothMap.coeFnRingHom
 
@@ -220,7 +220,7 @@ theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r :
 
 instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
-  Function.Injective.module 𝕜 coeFnAddMonoidHom ContMdiffMap.coe_inj coe_smul
+  Function.Injective.module 𝕜 coe_fn_add_monoid_hom ContMdiffMap.coe_inj coe_smul
 #align smooth_map.module SmoothMap.module
 
 /-- Coercion to a function as a `linear_map`. -/
@@ -228,8 +228,8 @@ instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
 def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →ₗ[𝕜] N → V :=
   {
-    (coeFnAddMonoidHom : C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+
-        _) with
+    (coe_fn_add_monoid_hom :
+      C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+ _) with
     toFun := coeFn
     map_smul' := coe_smul }
 #align smooth_map.coe_fn_linear_map SmoothMap.coeFnLinearMap
Diff
@@ -161,8 +161,8 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
     SmoothMap.monoid with
     left_distrib := fun a b c => by ext <;> exact left_distrib _ _ _
     right_distrib := fun a b c => by ext <;> exact right_distrib _ _ _
-    zero_mul := fun a => by ext <;> exact zero_mul _
-    mul_zero := fun a => by ext <;> exact mul_zero _ }
+    zero_mul := fun a => by ext <;> exact MulZeroClass.zero_mul _
+    mul_zero := fun a => by ext <;> exact MulZeroClass.mul_zero _ }
 #align smooth_map.semiring SmoothMap.semiring
 
 instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
Diff
@@ -35,7 +35,7 @@ instance hasMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [H
     Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.Smooth.mul g.Smooth⟩⟩
 #align smooth_map.has_mul SmoothMap.hasMul
-#align smooth_map.has_add SmoothMap.has_add
+#align smooth_map.has_add SmoothMap.hasAdd
 
 @[simp, to_additive]
 theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [HasSmoothMul I' G]
@@ -80,7 +80,7 @@ instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace
     [HasSmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.hasMul with mul_assoc := fun a b c => by ext <;> exact mul_assoc _ _ _ }
 #align smooth_map.semigroup SmoothMap.semigroup
-#align smooth_map.add_semigroup SmoothMap.add_semigroup
+#align smooth_map.add_semigroup SmoothMap.addSemigroup
 
 @[to_additive]
 instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
@@ -90,7 +90,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     one_mul := fun a => by ext <;> exact one_mul _
     mul_one := fun a => by ext <;> exact mul_one _ }
 #align smooth_map.monoid SmoothMap.monoid
-#align smooth_map.add_monoid SmoothMap.add_monoid
+#align smooth_map.add_monoid SmoothMap.addMonoid
 
 /-- Coercion to a function as an `monoid_hom`. Similar to `monoid_hom.coe_fn`. -/
 @[to_additive "Coercion to a function as an `add_monoid_hom`. Similar to `add_monoid_hom.coe_fn`.",
@@ -102,14 +102,14 @@ def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H'
   map_one' := coe_one
   map_mul' := coe_mul
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
-#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coe_fn_add_monoid_hom
+#align smooth_map.coe_fn_add_monoid_hom SmoothMap.coeFnAddMonoidHom
 
 @[to_additive]
 instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [HasSmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid, SmoothMap.hasOne with mul_comm := fun a b => by ext <;> exact mul_comm _ _ }
 #align smooth_map.comm_monoid SmoothMap.commMonoid
-#align smooth_map.add_comm_monoid SmoothMap.add_comm_monoid
+#align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
 
 @[to_additive]
 instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
@@ -120,7 +120,7 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
     div := fun f g => ⟨f / g, f.Smooth.div g.Smooth⟩
     div_eq_mul_inv := fun f g => by ext <;> exact div_eq_mul_inv _ _ }
 #align smooth_map.group SmoothMap.group
-#align smooth_map.add_group SmoothMap.add_group
+#align smooth_map.add_group SmoothMap.addGroup
 
 @[simp, to_additive]
 theorem coe_inv {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
@@ -141,7 +141,7 @@ instance commGroup {G : Type _} [CommGroup G] [TopologicalSpace G] [ChartedSpace
     [LieGroup I' G] : CommGroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.group, SmoothMap.commMonoid with }
 #align smooth_map.comm_group SmoothMap.commGroup
-#align smooth_map.add_comm_group SmoothMap.add_comm_group
+#align smooth_map.add_comm_group SmoothMap.addCommGroup
 
 end GroupStructure
 
@@ -157,7 +157,7 @@ under pointwise multiplication.
 
 instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : Semiring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.add_comm_monoid,
+  { SmoothMap.addCommMonoid,
     SmoothMap.monoid with
     left_distrib := fun a b c => by ext <;> exact left_distrib _ _ _
     right_distrib := fun a b c => by ext <;> exact right_distrib _ _ _
@@ -167,19 +167,19 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
 
 instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
     Ring C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.add_comm_group with }
+  { SmoothMap.semiring, SmoothMap.addCommGroup with }
 #align smooth_map.ring SmoothMap.ring
 
 instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : CommRing C^∞⟮I, N; I', R⟯ :=
-  { SmoothMap.semiring, SmoothMap.add_comm_group, SmoothMap.commMonoid with }
+  { SmoothMap.semiring, SmoothMap.addCommGroup, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
 
 /-- Coercion to a function as a `ring_hom`. -/
 @[simps]
 def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : C^∞⟮I, N; I', R⟯ →+* N → R :=
-  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coe_fn_add_monoid_hom : C^∞⟮I, N; I', R⟯ →+ _) with
+  { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coeFnAddMonoidHom : C^∞⟮I, N; I', R⟯ →+ _) with
     toFun := coeFn }
 #align smooth_map.coe_fn_ring_hom SmoothMap.coeFnRingHom
 
@@ -220,7 +220,7 @@ theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r :
 
 instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
-  Function.Injective.module 𝕜 coe_fn_add_monoid_hom ContMdiffMap.coe_inj coe_smul
+  Function.Injective.module 𝕜 coeFnAddMonoidHom ContMdiffMap.coe_inj coe_smul
 #align smooth_map.module SmoothMap.module
 
 /-- Coercion to a function as a `linear_map`. -/
@@ -228,8 +228,8 @@ instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
 def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →ₗ[𝕜] N → V :=
   {
-    (coe_fn_add_monoid_hom :
-      C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+ _) with
+    (coeFnAddMonoidHom : C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+
+        _) with
     toFun := coeFn
     map_smul' := coe_smul }
 #align smooth_map.coe_fn_linear_map SmoothMap.coeFnLinearMap

Changes in mathlib4

mathlib3
mathlib4
chore: classify todo porting notes (#11216)

Classifies by adding issue number #11215 to porting notes claiming "TODO".

Diff
@@ -132,7 +132,7 @@ def compLeftMonoidHom {G' : Type*} [Monoid G'] [TopologicalSpace G'] [ChartedSpa
 
 variable (I') {N}
 
--- Porting note: TODO: generalize to any smooth map instead of `Set.inclusion`
+-- Porting note (#11215): TODO: generalize to any smooth map instead of `Set.inclusion`
 /-- For a Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group homomorphism from
 `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`. -/
 @[to_additive "For an additive Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group
style: homogenise porting notes (#11145)

Homogenises porting notes via capitalisation and addition of whitespace.

It makes the following changes:

  • converts "--porting note" into "-- Porting note";
  • converts "porting note" into "Porting note".
Diff
@@ -132,7 +132,7 @@ def compLeftMonoidHom {G' : Type*} [Monoid G'] [TopologicalSpace G'] [ChartedSpa
 
 variable (I') {N}
 
--- porting note: TODO: generalize to any smooth map instead of `Set.inclusion`
+-- Porting note: TODO: generalize to any smooth map instead of `Set.inclusion`
 /-- For a Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group homomorphism from
 `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`. -/
 @[to_additive "For an additive Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group
chore(*): rename FunLike to DFunLike (#9785)

This prepares for the introduction of a non-dependent synonym of FunLike, which helps a lot with keeping #8386 readable.

This is entirely search-and-replace in 680197f combined with manual fixes in 4145626, e900597 and b8428f8. The commands that generated this change:

sed -i 's/\bFunLike\b/DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoFunLike\b/toDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/import Mathlib.Data.DFunLike/import Mathlib.Data.FunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bHom_FunLike\b/Hom_DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean     
sed -i 's/\binstFunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bfunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoo many metavariables to apply `fun_like.has_coe_to_fun`/too many metavariables to apply `DFunLike.hasCoeToFun`/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean

Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>

Diff
@@ -91,14 +91,14 @@ under pointwise multiplication.
 @[to_additive]
 instance semigroup {G : Type*} [Semigroup G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
-  FunLike.coe_injective.semigroup _ coe_mul
+  DFunLike.coe_injective.semigroup _ coe_mul
 #align smooth_map.semigroup SmoothMap.semigroup
 #align smooth_map.add_semigroup SmoothMap.addSemigroup
 
 @[to_additive]
 instance monoid {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Monoid C^∞⟮I, N; I', G⟯ :=
-  FunLike.coe_injective.monoid _ coe_one coe_mul coe_pow
+  DFunLike.coe_injective.monoid _ coe_one coe_mul coe_pow
 #align smooth_map.monoid SmoothMap.monoid
 #align smooth_map.add_monoid SmoothMap.addMonoid
 
@@ -107,7 +107,7 @@ instance monoid {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
   Similar to `AddMonoidHom.coeFn`."]
 def coeFnMonoidHom {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : C^∞⟮I, N; I', G⟯ →* N → G where
-  toFun := FunLike.coe
+  toFun := DFunLike.coe
   map_one' := coe_one
   map_mul' := coe_mul
 #align smooth_map.coe_fn_monoid_hom SmoothMap.coeFnMonoidHom
@@ -150,7 +150,7 @@ variable {I I'}
 @[to_additive]
 instance commMonoid {G : Type*} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
-  FunLike.coe_injective.commMonoid _ coe_one coe_mul coe_pow
+  DFunLike.coe_injective.commMonoid _ coe_one coe_mul coe_pow
 #align smooth_map.comm_monoid SmoothMap.commMonoid
 #align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
 
style: add missing spaces around colons (#8293)

This is not exhaustive

Diff
@@ -141,7 +141,7 @@ def restrictMonoidHom (G : Type*) [Monoid G] [TopologicalSpace G] [ChartedSpace
     [SmoothMul I' G] {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', G⟯ →* C^∞⟮I, U; I', G⟯ where
   toFun f := ⟨f ∘ Set.inclusion h, f.smooth.comp (smooth_inclusion h)⟩
   map_one' := rfl
-  map_mul' _ _:= rfl
+  map_mul' _ _ := rfl
 #align smooth_map.restrict_monoid_hom SmoothMap.restrictMonoidHom
 #align smooth_map.restrict_add_monoid_hom SmoothMap.restrictAddMonoidHom
 
chore: tidy various files (#7137)
Diff
@@ -262,17 +262,17 @@ end RingStructure
 section ModuleStructure
 
 /-!
-### Semiodule stucture
+### Semimodule stucture
 
 In this section we show that smooth functions valued in a vector space `M` over a normed
 field `𝕜` inherit a vector space structure.
 -/
 
 
-instance hasSmul {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance instSMul {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun r f => ⟨r • ⇑f, smooth_const.smul f.smooth⟩⟩
-#align smooth_map.has_smul SmoothMap.hasSmul
+#align smooth_map.has_smul SmoothMap.instSMul
 
 @[simp]
 theorem coe_smul {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
@@ -355,10 +355,10 @@ If `V` is a module over `𝕜`, then we show that the space of smooth functions
 is naturally a vector space over the ring of smooth functions from `N` to `𝕜`. -/
 
 
-instance instSmul' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance instSMul' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul C^∞⟮I, N; 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun f g => ⟨fun x => f x • g x, Smooth.smul f.2 g.2⟩⟩
-#align smooth_map.has_smul' SmoothMap.instSmul'
+#align smooth_map.has_smul' SmoothMap.instSMul'
 
 @[simp]
 theorem smul_comp' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (f : C^∞⟮I'', N'; 𝕜⟯)
chore: drop MulZeroClass. in mul_zero/zero_mul (#6682)

Search&replace MulZeroClass.mul_zero -> mul_zero, MulZeroClass.zero_mul -> zero_mul.

These were introduced by Mathport, as the full name of mul_zero is actually MulZeroClass.mul_zero (it's exported with the short name).

Diff
@@ -204,8 +204,8 @@ instance semiring {R : Type*} [Semiring R] [TopologicalSpace R] [ChartedSpace H'
     SmoothMap.monoid with
     left_distrib := fun a b c => by ext; exact left_distrib _ _ _
     right_distrib := fun a b c => by ext; exact right_distrib _ _ _
-    zero_mul := fun a => by ext; exact MulZeroClass.zero_mul _
-    mul_zero := fun a => by ext; exact MulZeroClass.mul_zero _ }
+    zero_mul := fun a => by ext; exact zero_mul _
+    mul_zero := fun a => by ext; exact mul_zero _ }
 #align smooth_map.semiring SmoothMap.semiring
 
 instance ring {R : Type*} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
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
@@ -20,61 +20,61 @@ open scoped Manifold
 
 open TopologicalSpace
 
-variable {𝕜 : Type _} [NontriviallyNormedField 𝕜] {E : Type _} [NormedAddCommGroup E]
-  [NormedSpace 𝕜 E] {E' : Type _} [NormedAddCommGroup E'] [NormedSpace 𝕜 E'] {H : Type _}
-  [TopologicalSpace H] {I : ModelWithCorners 𝕜 E H} {H' : Type _} [TopologicalSpace H']
-  {I' : ModelWithCorners 𝕜 E' H'} {N : Type _} [TopologicalSpace N] [ChartedSpace H N]
-  {E'' : Type _} [NormedAddCommGroup E''] [NormedSpace 𝕜 E''] {H'' : Type _} [TopologicalSpace H'']
-  {I'' : ModelWithCorners 𝕜 E'' H''} {N' : Type _} [TopologicalSpace N'] [ChartedSpace H'' N']
+variable {𝕜 : Type*} [NontriviallyNormedField 𝕜] {E : Type*} [NormedAddCommGroup E]
+  [NormedSpace 𝕜 E] {E' : Type*} [NormedAddCommGroup E'] [NormedSpace 𝕜 E'] {H : Type*}
+  [TopologicalSpace H] {I : ModelWithCorners 𝕜 E H} {H' : Type*} [TopologicalSpace H']
+  {I' : ModelWithCorners 𝕜 E' H'} {N : Type*} [TopologicalSpace N] [ChartedSpace H N]
+  {E'' : Type*} [NormedAddCommGroup E''] [NormedSpace 𝕜 E''] {H'' : Type*} [TopologicalSpace H'']
+  {I'' : ModelWithCorners 𝕜 E'' H''} {N' : Type*} [TopologicalSpace N'] [ChartedSpace H'' N']
 
 namespace SmoothMap
 
 @[to_additive]
-protected instance instMul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G]
+protected instance instMul {G : Type*} [Mul G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Mul C^∞⟮I, N; I', G⟯ :=
   ⟨fun f g => ⟨f * g, f.smooth.mul g.smooth⟩⟩
 #align smooth_map.has_mul SmoothMap.instMul
 #align smooth_map.has_add SmoothMap.instAdd
 
 @[to_additive (attr := simp)]
-theorem coe_mul {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
+theorem coe_mul {G : Type*} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I, N; I', G⟯) : ⇑(f * g) = f * g :=
   rfl
 #align smooth_map.coe_mul SmoothMap.coe_mul
 #align smooth_map.coe_add SmoothMap.coe_add
 
 @[to_additive (attr := simp)]
-theorem mul_comp {G : Type _} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
+theorem mul_comp {G : Type*} [Mul G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f g : C^∞⟮I'', N'; I', G⟯) (h : C^∞⟮I, N; I'', N'⟯) : (f * g).comp h = f.comp h * g.comp h :=
   rfl
 #align smooth_map.mul_comp SmoothMap.mul_comp
 #align smooth_map.add_comp SmoothMap.add_comp
 
 @[to_additive]
-protected instance instOne {G : Type _} [One G] [TopologicalSpace G] [ChartedSpace H' G] :
+protected instance instOne {G : Type*} [One G] [TopologicalSpace G] [ChartedSpace H' G] :
     One C^∞⟮I, N; I', G⟯ :=
   ⟨ContMDiffMap.const (1 : G)⟩
 #align smooth_map.has_one SmoothMap.instOne
 #align smooth_map.has_zero SmoothMap.instZero
 
 @[to_additive (attr := simp)]
-theorem coe_one {G : Type _} [One G] [TopologicalSpace G] [ChartedSpace H' G] :
+theorem coe_one {G : Type*} [One G] [TopologicalSpace G] [ChartedSpace H' G] :
     ⇑(1 : C^∞⟮I, N; I', G⟯) = 1 :=
   rfl
 #align smooth_map.coe_one SmoothMap.coe_one
 #align smooth_map.coe_zero SmoothMap.coe_zero
 
-instance instNSMul {G : Type _} [AddMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
+instance instNSMul {G : Type*} [AddMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothAdd I' G] : SMul ℕ C^∞⟮I, N; I', G⟯ where
   smul n f := ⟨n • (f : N → G), (smooth_nsmul n).comp f.smooth⟩
 
 @[to_additive existing]
-instance instPow {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
+instance instPow {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G] :
     Pow C^∞⟮I, N; I', G⟯ ℕ where
   pow f n := ⟨(f : N → G) ^ n, (smooth_pow n).comp f.smooth⟩
 
 @[to_additive (attr := simp)]
-theorem coe_pow {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
+theorem coe_pow {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G] [SmoothMul I' G]
     (f : C^∞⟮I, N; I', G⟯) (n : ℕ) :
     ⇑(f ^ n) = (f : N → G) ^ n :=
   rfl
@@ -89,14 +89,14 @@ under pointwise multiplication.
 -/
 
 @[to_additive]
-instance semigroup {G : Type _} [Semigroup G] [TopologicalSpace G] [ChartedSpace H' G]
+instance semigroup {G : Type*} [Semigroup G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Semigroup C^∞⟮I, N; I', G⟯ :=
   FunLike.coe_injective.semigroup _ coe_mul
 #align smooth_map.semigroup SmoothMap.semigroup
 #align smooth_map.add_semigroup SmoothMap.addSemigroup
 
 @[to_additive]
-instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
+instance monoid {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : Monoid C^∞⟮I, N; I', G⟯ :=
   FunLike.coe_injective.monoid _ coe_one coe_mul coe_pow
 #align smooth_map.monoid SmoothMap.monoid
@@ -105,7 +105,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
 /-- Coercion to a function as a `MonoidHom`. Similar to `MonoidHom.coeFn`. -/
 @[to_additive (attr := simps) "Coercion to a function as an `AddMonoidHom`.
   Similar to `AddMonoidHom.coeFn`."]
-def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
+def coeFnMonoidHom {G : Type*} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : C^∞⟮I, N; I', G⟯ →* N → G where
   toFun := FunLike.coe
   map_one' := coe_one
@@ -120,8 +120,8 @@ variable (I N)
 @[to_additive "For a manifold `N` and a smooth homomorphism `φ` between additive Lie groups `G'`,
 `G''`, the 'left-composition-by-`φ`' group homomorphism from `C^∞⟮I, N; I', G'⟯` to
 `C^∞⟮I, N; I'', G''⟯`."]
-def compLeftMonoidHom {G' : Type _} [Monoid G'] [TopologicalSpace G'] [ChartedSpace H' G']
-    [SmoothMul I' G'] {G'' : Type _} [Monoid G''] [TopologicalSpace G''] [ChartedSpace H'' G'']
+def compLeftMonoidHom {G' : Type*} [Monoid G'] [TopologicalSpace G'] [ChartedSpace H' G']
+    [SmoothMul I' G'] {G'' : Type*} [Monoid G''] [TopologicalSpace G''] [ChartedSpace H'' G'']
     [SmoothMul I'' G''] (φ : G' →* G'') (hφ : Smooth I' I'' φ) :
     C^∞⟮I, N; I', G'⟯ →* C^∞⟮I, N; I'', G''⟯ where
   toFun f := ⟨φ ∘ f, fun x => (hφ.smooth _).comp x (f.contMDiff x)⟩
@@ -137,7 +137,7 @@ variable (I') {N}
 `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`. -/
 @[to_additive "For an additive Lie group `G` and open sets `U ⊆ V` in `N`, the 'restriction' group
 homomorphism from `C^∞⟮I, V; I', G⟯` to `C^∞⟮I, U; I', G⟯`."]
-def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
+def restrictMonoidHom (G : Type*) [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', G⟯ →* C^∞⟮I, U; I', G⟯ where
   toFun f := ⟨f ∘ Set.inclusion h, f.smooth.comp (smooth_inclusion h)⟩
   map_one' := rfl
@@ -148,14 +148,14 @@ def restrictMonoidHom (G : Type _) [Monoid G] [TopologicalSpace G] [ChartedSpace
 variable {I I'}
 
 @[to_additive]
-instance commMonoid {G : Type _} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
+instance commMonoid {G : Type*} [CommMonoid G] [TopologicalSpace G] [ChartedSpace H' G]
     [SmoothMul I' G] : CommMonoid C^∞⟮I, N; I', G⟯ :=
   FunLike.coe_injective.commMonoid _ coe_one coe_mul coe_pow
 #align smooth_map.comm_monoid SmoothMap.commMonoid
 #align smooth_map.add_comm_monoid SmoothMap.addCommMonoid
 
 @[to_additive]
-instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
+instance group {G : Type*} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G] :
     Group C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.monoid with
     inv := fun f => ⟨fun x => (f x)⁻¹, f.smooth.inv⟩
@@ -166,21 +166,21 @@ instance group {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [
 #align smooth_map.add_group SmoothMap.addGroup
 
 @[to_additive (attr := simp)]
-theorem coe_inv {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
+theorem coe_inv {G : Type*} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
     (f : C^∞⟮I, N; I', G⟯) : ⇑f⁻¹ = (⇑f)⁻¹ :=
   rfl
 #align smooth_map.coe_inv SmoothMap.coe_inv
 #align smooth_map.coe_neg SmoothMap.coe_neg
 
 @[to_additive (attr := simp)]
-theorem coe_div {G : Type _} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
+theorem coe_div {G : Type*} [Group G] [TopologicalSpace G] [ChartedSpace H' G] [LieGroup I' G]
     (f g : C^∞⟮I, N; I', G⟯) : ⇑(f / g) = f / g :=
   rfl
 #align smooth_map.coe_div SmoothMap.coe_div
 #align smooth_map.coe_sub SmoothMap.coe_sub
 
 @[to_additive]
-instance commGroup {G : Type _} [CommGroup G] [TopologicalSpace G] [ChartedSpace H' G]
+instance commGroup {G : Type*} [CommGroup G] [TopologicalSpace G] [ChartedSpace H' G]
     [LieGroup I' G] : CommGroup C^∞⟮I, N; I', G⟯ :=
   { SmoothMap.group, SmoothMap.commMonoid with }
 #align smooth_map.comm_group SmoothMap.commGroup
@@ -198,7 +198,7 @@ under pointwise multiplication.
 -/
 
 
-instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
+instance semiring {R : Type*} [Semiring R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : Semiring C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.addCommMonoid,
     SmoothMap.monoid with
@@ -208,12 +208,12 @@ instance semiring {R : Type _} [Semiring R] [TopologicalSpace R] [ChartedSpace H
     mul_zero := fun a => by ext; exact MulZeroClass.mul_zero _ }
 #align smooth_map.semiring SmoothMap.semiring
 
-instance ring {R : Type _} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
+instance ring {R : Type*} [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R] :
     Ring C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.semiring, SmoothMap.addCommGroup with }
 #align smooth_map.ring SmoothMap.ring
 
-instance commRing {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
+instance commRing {R : Type*} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : CommRing C^∞⟮I, N; I', R⟯ :=
   { SmoothMap.semiring, SmoothMap.addCommGroup, SmoothMap.commMonoid with }
 #align smooth_map.comm_ring SmoothMap.commRing
@@ -222,8 +222,8 @@ variable (I N)
 
 /-- For a manifold `N` and a smooth homomorphism `φ` between smooth rings `R'`, `R''`, the
 'left-composition-by-`φ`' ring homomorphism from `C^∞⟮I, N; I', R'⟯` to `C^∞⟮I, N; I'', R''⟯`. -/
-def compLeftRingHom {R' : Type _} [Ring R'] [TopologicalSpace R'] [ChartedSpace H' R']
-    [SmoothRing I' R'] {R'' : Type _} [Ring R''] [TopologicalSpace R''] [ChartedSpace H'' R'']
+def compLeftRingHom {R' : Type*} [Ring R'] [TopologicalSpace R'] [ChartedSpace H' R']
+    [SmoothRing I' R'] {R'' : Type*} [Ring R''] [TopologicalSpace R''] [ChartedSpace H'' R'']
     [SmoothRing I'' R''] (φ : R' →+* R'') (hφ : Smooth I' I'' φ) :
     C^∞⟮I, N; I', R'⟯ →+* C^∞⟮I, N; I'', R''⟯ :=
   { SmoothMap.compLeftMonoidHom I N φ.toMonoidHom hφ,
@@ -235,7 +235,7 @@ variable (I') {N}
 
 /-- For a "smooth ring" `R` and open sets `U ⊆ V` in `N`, the "restriction" ring homomorphism from
 `C^∞⟮I, V; I', R⟯` to `C^∞⟮I, U; I', R⟯`. -/
-def restrictRingHom (R : Type _) [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
+def restrictRingHom (R : Type*) [Ring R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
     {U V : Opens N} (h : U ≤ V) : C^∞⟮I, V; I', R⟯ →+* C^∞⟮I, U; I', R⟯ :=
   { SmoothMap.restrictMonoidHom I I' R h, SmoothMap.restrictAddMonoidHom I I' R h with
     toFun := fun f => ⟨f ∘ Set.inclusion h, f.smooth.comp (smooth_inclusion h)⟩ }
@@ -245,14 +245,14 @@ variable {I I'}
 
 /-- Coercion to a function as a `RingHom`. -/
 @[simps]
-def coeFnRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
+def coeFnRingHom {R : Type*} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R]
     [SmoothRing I' R] : C^∞⟮I, N; I', R⟯ →+* N → R :=
   { (coeFnMonoidHom : C^∞⟮I, N; I', R⟯ →* _), (coeFnAddMonoidHom : C^∞⟮I, N; I', R⟯ →+ _) with
     toFun := (↑) }
 #align smooth_map.coe_fn_ring_hom SmoothMap.coeFnRingHom
 
 /-- `Function.eval` as a `RingHom` on the ring of smooth functions. -/
-def evalRingHom {R : Type _} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
+def evalRingHom {R : Type*} [CommRing R] [TopologicalSpace R] [ChartedSpace H' R] [SmoothRing I' R]
     (n : N) : C^∞⟮I, N; I', R⟯ →+* R :=
   (Pi.evalRingHom _ n : (N → R) →+* R).comp SmoothMap.coeFnRingHom
 #align smooth_map.eval_ring_hom SmoothMap.evalRingHom
@@ -269,31 +269,31 @@ field `𝕜` inherit a vector space structure.
 -/
 
 
-instance hasSmul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance hasSmul {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun r f => ⟨r • ⇑f, smooth_const.smul f.smooth⟩⟩
 #align smooth_map.has_smul SmoothMap.hasSmul
 
 @[simp]
-theorem coe_smul {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
+theorem coe_smul {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
     (f : C^∞⟮I, N; 𝓘(𝕜, V), V⟯) : ⇑(r • f) = r • ⇑f :=
   rfl
 #align smooth_map.coe_smul SmoothMap.coe_smul
 
 @[simp]
-theorem smul_comp {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
+theorem smul_comp {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (r : 𝕜)
     (g : C^∞⟮I'', N'; 𝓘(𝕜, V), V⟯) (h : C^∞⟮I, N; I'', N'⟯) : (r • g).comp h = r • g.comp h :=
   rfl
 #align smooth_map.smul_comp SmoothMap.smul_comp
 
-instance module {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance module {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module 𝕜 C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   Function.Injective.module 𝕜 coeFnAddMonoidHom ContMDiffMap.coe_injective coe_smul
 #align smooth_map.module SmoothMap.module
 
 /-- Coercion to a function as a `LinearMap`. -/
 @[simps]
-def coeFnLinearMap {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+def coeFnLinearMap {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →ₗ[𝕜] N → V :=
   { (coeFnAddMonoidHom : C^∞⟮I, N; 𝓘(𝕜, V), V⟯ →+ _) with
     toFun := (↑)
@@ -312,7 +312,7 @@ inherit an algebra structure.
 -/
 
 
-variable {A : Type _} [NormedRing A] [NormedAlgebra 𝕜 A] [SmoothRing 𝓘(𝕜, A) A]
+variable {A : Type*} [NormedRing A] [NormedAlgebra 𝕜 A] [SmoothRing 𝓘(𝕜, A) A]
 
 /-- Smooth constant functions as a `RingHom`. -/
 def C : 𝕜 →+* C^∞⟮I, N; 𝓘(𝕜, A), A⟯ where
@@ -355,19 +355,19 @@ If `V` is a module over `𝕜`, then we show that the space of smooth functions
 is naturally a vector space over the ring of smooth functions from `N` to `𝕜`. -/
 
 
-instance instSmul' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance instSmul' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     SMul C^∞⟮I, N; 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯ :=
   ⟨fun f g => ⟨fun x => f x • g x, Smooth.smul f.2 g.2⟩⟩
 #align smooth_map.has_smul' SmoothMap.instSmul'
 
 @[simp]
-theorem smul_comp' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (f : C^∞⟮I'', N'; 𝕜⟯)
+theorem smul_comp' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] (f : C^∞⟮I'', N'; 𝕜⟯)
     (g : C^∞⟮I'', N'; 𝓘(𝕜, V), V⟯) (h : C^∞⟮I, N; I'', N'⟯) :
     (f • g).comp h = f.comp h • g.comp h :=
   rfl
 #align smooth_map.smul_comp' SmoothMap.smul_comp'
 
-instance module' {V : Type _} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
+instance module' {V : Type*} [NormedAddCommGroup V] [NormedSpace 𝕜 V] :
     Module C^∞⟮I, N; 𝓘(𝕜), 𝕜⟯ C^∞⟮I, N; 𝓘(𝕜, V), V⟯ where
   smul := (· • ·)
   smul_add c f g := by ext x; exact smul_add (c x) (f x) (g x)
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,14 +2,11 @@
 Copyright © 2020 Nicolò Cavalleri. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Nicolò Cavalleri
-
-! This file was ported from Lean 3 source module geometry.manifold.algebra.smooth_functions
-! leanprover-community/mathlib commit e5ab837fc252451f3eb9124ae6e7b6f57455e7b9
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Geometry.Manifold.Algebra.Structures
 
+#align_import geometry.manifold.algebra.smooth_functions from "leanprover-community/mathlib"@"e5ab837fc252451f3eb9124ae6e7b6f57455e7b9"
+
 /-!
 # Algebraic structures over smooth functions
 
chore: fix grammar in docs (#5668)
Diff
@@ -105,7 +105,7 @@ instance monoid {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
 #align smooth_map.monoid SmoothMap.monoid
 #align smooth_map.add_monoid SmoothMap.addMonoid
 
-/-- Coercion to a function as an `MonoidHom`. Similar to `MonoidHom.coeFn`. -/
+/-- Coercion to a function as a `MonoidHom`. Similar to `MonoidHom.coeFn`. -/
 @[to_additive (attr := simps) "Coercion to a function as an `AddMonoidHom`.
   Similar to `AddMonoidHom.coeFn`."]
 def coeFnMonoidHom {G : Type _} [Monoid G] [TopologicalSpace G] [ChartedSpace H' G]
feat: port Geometry.Manifold.Algebra.SmoothFunctions (#5461)

Co-authored-by: int-y1 <jason_yuen2007@hotmail.com> Co-authored-by: Jason Yuen <jason_yuen2007@hotmail.com>

Dependencies 12 + 881

882 files ported (98.7%)
392333 lines ported (98.6%)
Show graph

The unported dependencies are

The following 1 dependencies have changed in mathlib3 since they were ported, which may complicate porting this file