From e1c47b017e36cac31a587c2b128fb48028aa830d Mon Sep 17 00:00:00 2001 From: Michael Rothgang Date: Wed, 6 May 2026 15:28:28 +0200 Subject: [PATCH 1/4] chore: use no_expose for immersions, part 1 --- Mathlib/Geometry/Manifold/Immersion.lean | 63 +++++++++--------------- 1 file changed, 24 insertions(+), 39 deletions(-) diff --git a/Mathlib/Geometry/Manifold/Immersion.lean b/Mathlib/Geometry/Manifold/Immersion.lean index 1c94e4b8106691..d0a215f3ddcfb2 100644 --- a/Mathlib/Geometry/Manifold/Immersion.lean +++ b/Mathlib/Geometry/Manifold/Immersion.lean @@ -155,7 +155,7 @@ in some settings, such as proving that embedded submanifolds are locally given e immersion or a submersion. Unless you have a particular reason, prefer to use `IsImmersionAt` instead. -/ -irreducible_def IsImmersionAtOfComplement (f : M β†’ N) (x : M) : Prop := +@[no_expose] def IsImmersionAtOfComplement (f : M β†’ N) (x : M) : Prop := LiftSourceTargetPropertyAt I J n f x (ImmersionAtProp F I J M N) -- Lift the universe from `E''`, to avoid a free universe parameter. @@ -188,7 +188,6 @@ lemma mk_of_charts (equiv : (E Γ— F) ≃L[π•œ] E'') (domChart : OpenPartialHome (hsource : domChart.source βŠ† f ⁻¹' codChart.source) (hwrittenInExtend : EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target) : IsImmersionAtOfComplement F I J n f x := by - rw [IsImmersionAtOfComplement_def] use domChart, codChart use equiv @@ -203,7 +202,6 @@ lemma mk_of_continuousAt {f : M β†’ N} {x : M} (hf : ContinuousAt f x) (equiv : (hcodChart : codChart ∈ IsManifold.maximalAtlas J n N) (hwrittenInExtend : EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target) : IsImmersionAtOfComplement F I J n f x := by - rw [IsImmersionAtOfComplement_def] exact LiftSourceTargetPropertyAt.mk_of_continuousAt hf isLocalSourceTargetProperty_immersionAtProp _ _ hx hfx hdomChart hcodChart ⟨equiv, hwrittenInExtend⟩ @@ -212,59 +210,48 @@ w.r.t. this chart and the data `h.codChart` and `h.equiv`, `f` will look like an inclusion `u ↦ (u, 0)` in these extended charts. The particular chart is arbitrary, but this choice matches the witnesses given by `h.codChart` and `h.codChart`. -/ -def domChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph M H := by - rw [IsImmersionAtOfComplement_def] at h - exact LiftSourceTargetPropertyAt.domChart h +@[no_expose] def domChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph M H := + LiftSourceTargetPropertyAt.domChart h /-- A choice of chart on the co-domain `N` of an immersion `f` at `x`: w.r.t. this chart and the data `h.domChart` and `h.equiv`, `f` will look like an inclusion `u ↦ (u, 0)` in these extended charts. The particular chart is arbitrary, but this choice matches the witnesses given by `h.equiv` and `h.domChart`. -/ -def codChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph N G := by - rw [IsImmersionAtOfComplement_def] at h - exact LiftSourceTargetPropertyAt.codChart h +@[no_expose] def codChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph N G := + LiftSourceTargetPropertyAt.codChart h -lemma mem_domChart_source (h : IsImmersionAtOfComplement F I J n f x) : x ∈ h.domChart.source := by - rw [IsImmersionAtOfComplement_def] at h - exact LiftSourceTargetPropertyAt.mem_domChart_source h +lemma mem_domChart_source (h : IsImmersionAtOfComplement F I J n f x) : x ∈ h.domChart.source := + LiftSourceTargetPropertyAt.mem_domChart_source h -lemma mem_codChart_source (h : IsImmersionAtOfComplement F I J n f x) : - f x ∈ h.codChart.source := by - rw [IsImmersionAtOfComplement_def] at h - exact LiftSourceTargetPropertyAt.mem_codChart_source h +lemma mem_codChart_source (h : IsImmersionAtOfComplement F I J n f x) : f x ∈ h.codChart.source := + LiftSourceTargetPropertyAt.mem_codChart_source h lemma domChart_mem_maximalAtlas (h : IsImmersionAtOfComplement F I J n f x) : - h.domChart ∈ IsManifold.maximalAtlas I n M := by - rw [IsImmersionAtOfComplement_def] at h - exact LiftSourceTargetPropertyAt.domChart_mem_maximalAtlas h + h.domChart ∈ IsManifold.maximalAtlas I n M := + LiftSourceTargetPropertyAt.domChart_mem_maximalAtlas h lemma codChart_mem_maximalAtlas (h : IsImmersionAtOfComplement F I J n f x) : h.codChart ∈ IsManifold.maximalAtlas J n N := by - rw [IsImmersionAtOfComplement_def] at h exact LiftSourceTargetPropertyAt.codChart_mem_maximalAtlas h lemma source_subset_preimage_source (h : IsImmersionAtOfComplement F I J n f x) : h.domChart.source βŠ† f ⁻¹' h.codChart.source := by - rw [IsImmersionAtOfComplement_def] at h exact LiftSourceTargetPropertyAt.source_subset_preimage_source h /-- A linear equivalence `E Γ— F ≃L[π•œ] E''` which belongs to the data of an immersion `f` at `x`: the particular equivalence is arbitrary, but this choice matches the witnesses given by `h.domChart` and `h.codChart`. -/ @[no_expose] def equiv (h : IsImmersionAtOfComplement F I J n f x) : (E Γ— F) ≃L[π•œ] E'' := by - rw [IsImmersionAtOfComplement_def] at h exact Classical.choose <| LiftSourceTargetPropertyAt.property h lemma writtenInCharts (h : IsImmersionAtOfComplement F I J n f x) : EqOn ((h.codChart.extend J) ∘ f ∘ (h.domChart.extend I).symm) (h.equiv ∘ (Β·, 0)) (h.domChart.extend I).target := by - rw [IsImmersionAtOfComplement_def] at h exact Classical.choose_spec <| LiftSourceTargetPropertyAt.property h lemma property (h : IsImmersionAtOfComplement F I J n f x) : - LiftSourceTargetPropertyAt I J n f x (ImmersionAtProp F I J M N) := by - rwa [IsImmersionAtOfComplement_def] at h + LiftSourceTargetPropertyAt I J n f x (ImmersionAtProp F I J M N) := h /-- If `f` is an immersion at `x`, it maps its domain chart's target `(h.domChart.extend I).target` @@ -305,7 +292,6 @@ lemma target_subset_preimage_target (h : IsImmersionAtOfComplement F I J n f x) then `g` is an immersion at `x`. -/ lemma congr_of_eventuallyEq (hf : IsImmersionAtOfComplement F I J n f x) (hfg : f =αΆ [𝓝 x] g) : IsImmersionAtOfComplement F I J n g x := by - rw [IsImmersionAtOfComplement_def] exact LiftSourceTargetPropertyAt.congr_of_eventuallyEq isLocalSourceTargetProperty_immersionAtProp hf.property hfg @@ -313,8 +299,7 @@ lemma congr_of_eventuallyEq (hf : IsImmersionAtOfComplement F I J n f x) (hfg : then `f` is an immersion at `x` if and only if `g` is an immersion at `x`. -/ lemma congr_iff_of_eventuallyEq (hfg : f =αΆ [𝓝 x] g) : IsImmersionAtOfComplement F I J n f x ↔ IsImmersionAtOfComplement F I J n g x := by - simpa only [IsImmersionAtOfComplement_def] using - LiftSourceTargetPropertyAt.congr_iff_of_eventuallyEq + exact LiftSourceTargetPropertyAt.congr_iff_of_eventuallyEq isLocalSourceTargetProperty_immersionAtProp hfg lemma small (hf : IsImmersionAtOfComplement F I J n f x) : Small.{u} F := @@ -344,7 +329,6 @@ def smallEquiv (hf : IsImmersionAtOfComplement F I J n f x) : F ≃L[π•œ] hf.sm lemma trans_F (h : IsImmersionAtOfComplement F I J n f x) (e : F ≃L[π•œ] F') : IsImmersionAtOfComplement F' I J n f x := by - rewrite [IsImmersionAtOfComplement_def] refine ⟨h.domChart, h.codChart, h.mem_domChart_source, h.mem_codChart_source, h.domChart_mem_maximalAtlas, h.codChart_mem_maximalAtlas, h.source_subset_preimage_source, ?_⟩ use ((ContinuousLinearEquiv.refl π•œ E).prodCongr e.symm).trans h.equiv @@ -359,9 +343,8 @@ lemma congr_F (e : F ≃L[π•œ] F') : /- The set of points where `IsImmersionAtOfComplement` holds is open. -/ lemma _root_.IsOpen.isImmersionAtOfComplement : - IsOpen {x | IsImmersionAtOfComplement F I J n f x} := by - simp_rw [IsImmersionAtOfComplement_def] - exact .liftSourceTargetPropertyAt + IsOpen {x | IsImmersionAtOfComplement F I J n f x} := + IsOpen.liftSourceTargetPropertyAt set_option backward.isDefEq.respectTransparency false in /-- If `f: M β†’ N` and `g: M' Γ— N'` are immersions at `x` and `x'`, respectively, @@ -370,7 +353,6 @@ theorem prodMap {f : M β†’ N} {g : M' β†’ N'} {x' : M'} [IsManifold I n M] [IsManifold I' n M'] [IsManifold J n N] [IsManifold J' n N'] (hf : IsImmersionAtOfComplement F I J n f x) (hg : IsImmersionAtOfComplement F' I' J' n g x') : IsImmersionAtOfComplement (F Γ— F') (I.prod I') (J.prod J') n (Prod.map f g) (x, x') := by - rw [IsImmersionAtOfComplement_def] apply LiftSourceTargetPropertyAt.prodMap hf.property hg.property rintro f φ₁ Οˆβ‚ g Ο†β‚‚ Οˆβ‚‚ ⟨equiv₁, hfprop⟩ ⟨equivβ‚‚, hgprop⟩ use (ContinuousLinearEquiv.prodProdProdComm π•œ E E' F F').trans (equiv₁.prodCongr equivβ‚‚) @@ -702,8 +684,9 @@ is not conclusive. If `E''` is infinite-dimensional, this dimension can indeed c different connected components of `M`. -/ lemma isImmersionAt (h : IsImmersion I J n f) (x : M) : IsImmersionAt I J n f x := by - rw [IsImmersionAt_def] - use h.complement, by infer_instance, by infer_instance, h.isImmersionOfComplement_complement x + rw [IsImmersionAt] + use h.complement, by infer_instance, by infer_instance + exact h.isImmersionOfComplement_complement x /-- If `f = g` and `f` is an immersion, so is `g`. -/ theorem congr (h : IsImmersion I J n f) (heq : f = g) : IsImmersion I J n g := @@ -719,13 +702,15 @@ theorem prodMap {f : M β†’ N} {g : M' β†’ N'} open IsManifold in /-- The identity map is an immersion. -/ -protected lemma id [IsManifold I n M] : IsImmersion I I n (@id M) := - ⟨PUnit, by infer_instance, by infer_instance, IsImmersionOfComplement.id⟩ +protected lemma id [IsManifold I n M] : IsImmersion I I n (@id M) := by + use PUnit, by infer_instance, by infer_instance + exact IsImmersionOfComplement.id /- The inclusion of an open subset `s` of a smooth manifold `M` is an immersion. -/ lemma of_opens [IsManifold I n M] (s : TopologicalSpace.Opens M) : - IsImmersion I I n (Subtype.val : s β†’ M) := - ⟨PUnit, by infer_instance, by infer_instance, IsImmersionOfComplement.of_opens s⟩ + IsImmersion I I n (Subtype.val : s β†’ M) := by + use PUnit, by infer_instance, by infer_instance + exact IsImmersionOfComplement.of_opens s @[deprecated (since := "2025-12-16")] alias ofOpen := of_opens From 02ee9160894d3caa25d2dd24772e18ed912add6d Mon Sep 17 00:00:00 2001 From: Michael Rothgang Date: Wed, 6 May 2026 15:29:02 +0200 Subject: [PATCH 2/4] no_expose ImmersionAtProp --- Mathlib/Geometry/Manifold/Immersion.lean | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Mathlib/Geometry/Manifold/Immersion.lean b/Mathlib/Geometry/Manifold/Immersion.lean index d0a215f3ddcfb2..3fc93e569dcc2d 100644 --- a/Mathlib/Geometry/Manifold/Immersion.lean +++ b/Mathlib/Geometry/Manifold/Immersion.lean @@ -124,7 +124,7 @@ charts, `f` looks like the inclusion `u ↦ (u, 0)`. This definition has a fixed parameter `F`, which is a choice of complement of `E` in the model normed space `E'` of `N`: being an immersion at `x` includes a choice of linear isomorphism between `E Γ— F` and `E'`. -/ -def ImmersionAtProp : (M β†’ N) β†’ OpenPartialHomeomorph M H β†’ OpenPartialHomeomorph N G β†’ Prop := +@[no_expose] def ImmersionAtProp : (M β†’ N) β†’ OpenPartialHomeomorph M H β†’ OpenPartialHomeomorph N G β†’ Prop := fun f domChart codChart ↦ βˆƒ equiv : (E Γ— F) ≃L[π•œ] E'', EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target From 710f2ce1369052f100818f896dccc12a619bab62 Mon Sep 17 00:00:00 2001 From: Michael Rothgang Date: Wed, 6 May 2026 15:30:28 +0200 Subject: [PATCH 3/4] chore: more no_expose --- Mathlib/Geometry/Manifold/Immersion.lean | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/Mathlib/Geometry/Manifold/Immersion.lean b/Mathlib/Geometry/Manifold/Immersion.lean index 3fc93e569dcc2d..37de65cd6c1292 100644 --- a/Mathlib/Geometry/Manifold/Immersion.lean +++ b/Mathlib/Geometry/Manifold/Immersion.lean @@ -172,7 +172,7 @@ immersion at `x` includes a choice of linear isomorphism between `E Γ— F` and `E where the choice of `F` enters. If you need stronger control over the complement `F`, use `IsImmersionAtOfComplement` instead. -/ -irreducible_def IsImmersionAt (f : M β†’ N) (x : M) : Prop := +@[no_expose] def IsImmersionAt (f : M β†’ N) (x : M) : Prop := βˆƒ (F : Type u) (_ : NormedAddCommGroup F) (_ : NormedSpace π•œ F), IsImmersionAtOfComplement F I J n f x @@ -367,7 +367,6 @@ the model normed space of `N`. This is solved by `smallComplement` and `smallEqu -/ lemma isImmersionAt (h : IsImmersionAtOfComplement F I J n f x) : IsImmersionAt I J n f x := by - rw [IsImmersionAt_def] use h.smallComplement, by infer_instance, by infer_instance exact (IsImmersionAtOfComplement.congr_F h.smallEquiv).mp h @@ -396,7 +395,6 @@ lemma mk_of_charts (equiv : (E Γ— F) ≃L[π•œ] E'') (hsource : domChart.source βŠ† f ⁻¹' codChart.source) (hwrittenInExtend : EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target) : IsImmersionAt I J n f x := by - rw [IsImmersionAt_def] have aux : IsImmersionAtOfComplement F I J n f x := by apply IsImmersionAtOfComplement.mk_of_charts <;> assumption use aux.smallComplement, by infer_instance, by infer_instance @@ -413,7 +411,6 @@ lemma mk_of_continuousAt {f : M β†’ N} {x : M} (hf : ContinuousAt f x) (equiv : (hcodChart : codChart ∈ IsManifold.maximalAtlas J n N) (hwrittenInExtend : EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target) : IsImmersionAt I J n f x := by - rw [IsImmersionAt_def] have aux : IsImmersionAtOfComplement F I J n f x := by apply IsImmersionAtOfComplement.mk_of_continuousAt <;> assumption use aux.smallComplement, by infer_instance, by infer_instance @@ -421,22 +418,19 @@ lemma mk_of_continuousAt {f : M β†’ N} {x : M} (hf : ContinuousAt f x) (equiv : /-- A choice of complement of the model normed space `E` of `M` in the model normed space `E'` of `N` -/ -def complement (h : IsImmersionAt I J n f x) : Type u := by - rw [IsImmersionAt_def] at h +@[no_expose] def complement (h : IsImmersionAt I J n f x) : Type u := by exact Classical.choose h -instance (h : IsImmersionAt I J n f x) : NormedAddCommGroup h.complement := by - rw [IsImmersionAt_def] at h +@[no_expose] instance (h : IsImmersionAt I J n f x) : NormedAddCommGroup h.complement := by exact Classical.choose <| Classical.choose_spec h +@[no_expose] instance (h : IsImmersionAt I J n f x) : NormedSpace π•œ h.complement := by - rw [IsImmersionAt_def] at h exact Classical.choose <| Classical.choose_spec <| Classical.choose_spec h lemma isImmersionAtOfComplement_complement (h : IsImmersionAt I J n f x) : - IsImmersionAtOfComplement h.complement I J n f x := by - rw [IsImmersionAt_def] at h - exact Classical.choose_spec <| Classical.choose_spec <| Classical.choose_spec h + IsImmersionAtOfComplement h.complement I J n f x := + Classical.choose_spec <| Classical.choose_spec <| Classical.choose_spec h /-- A choice of chart on the domain `M` of an immersion `f` at `x`: w.r.t. this chart and the data `h.codChart` and `h.equiv`, @@ -521,7 +515,6 @@ lemma target_subset_preimage_target (h : IsImmersionAt I J n f x) : then `g` is an immersion at `x`. -/ lemma congr_of_eventuallyEq (hf : IsImmersionAt I J n f x) (hfg : f =αΆ [𝓝 x] g) : IsImmersionAt I J n g x := by - rw [IsImmersionAt_def] use hf.complement, by infer_instance, by infer_instance exact hf.isImmersionAtOfComplement_complement.congr_of_eventuallyEq hfg @@ -551,7 +544,6 @@ theorem prodMap {f : M β†’ N} {g : M' β†’ N'} {x' : M'} /- The inclusion of an open subset `s` of a smooth manifold `M` is an immersion at every point. -/ lemma of_opens [IsManifold I n M] (s : TopologicalSpace.Opens M) (hx : x ∈ s) : IsImmersionAt I I n (Subtype.val : s β†’ M) ⟨x, hx⟩ := by - rw [IsImmersionAt_def] use PUnit, by infer_instance, by infer_instance apply Manifold.IsImmersionAtOfComplement.of_opens From 255c03bf63d9d5c77079abd2b5266fc285ab1a61 Mon Sep 17 00:00:00 2001 From: Michael Rothgang Date: Wed, 6 May 2026 15:35:00 +0200 Subject: [PATCH 4/4] Switch default --- Mathlib/Geometry/Manifold/Immersion.lean | 56 ++++++++++++------------ 1 file changed, 27 insertions(+), 29 deletions(-) diff --git a/Mathlib/Geometry/Manifold/Immersion.lean b/Mathlib/Geometry/Manifold/Immersion.lean index 37de65cd6c1292..e3d7a87d24183f 100644 --- a/Mathlib/Geometry/Manifold/Immersion.lean +++ b/Mathlib/Geometry/Manifold/Immersion.lean @@ -94,7 +94,7 @@ This shortens the overall argument, as the definition of submersions has the sam open scoped Topology ContDiff open Function Set -@[expose] public noncomputable section +public noncomputable section namespace Manifold @@ -124,7 +124,7 @@ charts, `f` looks like the inclusion `u ↦ (u, 0)`. This definition has a fixed parameter `F`, which is a choice of complement of `E` in the model normed space `E'` of `N`: being an immersion at `x` includes a choice of linear isomorphism between `E Γ— F` and `E'`. -/ -@[no_expose] def ImmersionAtProp : (M β†’ N) β†’ OpenPartialHomeomorph M H β†’ OpenPartialHomeomorph N G β†’ Prop := +def ImmersionAtProp : (M β†’ N) β†’ OpenPartialHomeomorph M H β†’ OpenPartialHomeomorph N G β†’ Prop := fun f domChart codChart ↦ βˆƒ equiv : (E Γ— F) ≃L[π•œ] E'', EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) (domChart.extend I).target @@ -155,7 +155,7 @@ in some settings, such as proving that embedded submanifolds are locally given e immersion or a submersion. Unless you have a particular reason, prefer to use `IsImmersionAt` instead. -/ -@[no_expose] def IsImmersionAtOfComplement (f : M β†’ N) (x : M) : Prop := +def IsImmersionAtOfComplement (f : M β†’ N) (x : M) : Prop := LiftSourceTargetPropertyAt I J n f x (ImmersionAtProp F I J M N) -- Lift the universe from `E''`, to avoid a free universe parameter. @@ -172,7 +172,7 @@ immersion at `x` includes a choice of linear isomorphism between `E Γ— F` and `E where the choice of `F` enters. If you need stronger control over the complement `F`, use `IsImmersionAtOfComplement` instead. -/ -@[no_expose] def IsImmersionAt (f : M β†’ N) (x : M) : Prop := +def IsImmersionAt (f : M β†’ N) (x : M) : Prop := βˆƒ (F : Type u) (_ : NormedAddCommGroup F) (_ : NormedSpace π•œ F), IsImmersionAtOfComplement F I J n f x @@ -201,8 +201,8 @@ lemma mk_of_continuousAt {f : M β†’ N} {x : M} (hf : ContinuousAt f x) (equiv : (hdomChart : domChart ∈ IsManifold.maximalAtlas I n M) (hcodChart : codChart ∈ IsManifold.maximalAtlas J n N) (hwrittenInExtend : EqOn ((codChart.extend J) ∘ f ∘ (domChart.extend I).symm) (equiv ∘ (Β·, 0)) - (domChart.extend I).target) : IsImmersionAtOfComplement F I J n f x := by - exact LiftSourceTargetPropertyAt.mk_of_continuousAt hf isLocalSourceTargetProperty_immersionAtProp + (domChart.extend I).target) : IsImmersionAtOfComplement F I J n f x := + LiftSourceTargetPropertyAt.mk_of_continuousAt hf isLocalSourceTargetProperty_immersionAtProp _ _ hx hfx hdomChart hcodChart ⟨equiv, hwrittenInExtend⟩ /-- A choice of chart on the domain `M` of an immersion `f` at `x`: @@ -210,7 +210,7 @@ w.r.t. this chart and the data `h.codChart` and `h.equiv`, `f` will look like an inclusion `u ↦ (u, 0)` in these extended charts. The particular chart is arbitrary, but this choice matches the witnesses given by `h.codChart` and `h.codChart`. -/ -@[no_expose] def domChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph M H := +def domChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph M H := LiftSourceTargetPropertyAt.domChart h /-- A choice of chart on the co-domain `N` of an immersion `f` at `x`: @@ -218,7 +218,7 @@ w.r.t. this chart and the data `h.domChart` and `h.equiv`, `f` will look like an inclusion `u ↦ (u, 0)` in these extended charts. The particular chart is arbitrary, but this choice matches the witnesses given by `h.equiv` and `h.domChart`. -/ -@[no_expose] def codChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph N G := +def codChart (h : IsImmersionAtOfComplement F I J n f x) : OpenPartialHomeomorph N G := LiftSourceTargetPropertyAt.codChart h lemma mem_domChart_source (h : IsImmersionAtOfComplement F I J n f x) : x ∈ h.domChart.source := @@ -232,23 +232,23 @@ lemma domChart_mem_maximalAtlas (h : IsImmersionAtOfComplement F I J n f x) : LiftSourceTargetPropertyAt.domChart_mem_maximalAtlas h lemma codChart_mem_maximalAtlas (h : IsImmersionAtOfComplement F I J n f x) : - h.codChart ∈ IsManifold.maximalAtlas J n N := by - exact LiftSourceTargetPropertyAt.codChart_mem_maximalAtlas h + h.codChart ∈ IsManifold.maximalAtlas J n N := + LiftSourceTargetPropertyAt.codChart_mem_maximalAtlas h lemma source_subset_preimage_source (h : IsImmersionAtOfComplement F I J n f x) : - h.domChart.source βŠ† f ⁻¹' h.codChart.source := by - exact LiftSourceTargetPropertyAt.source_subset_preimage_source h + h.domChart.source βŠ† f ⁻¹' h.codChart.source := + LiftSourceTargetPropertyAt.source_subset_preimage_source h /-- A linear equivalence `E Γ— F ≃L[π•œ] E''` which belongs to the data of an immersion `f` at `x`: the particular equivalence is arbitrary, but this choice matches the witnesses given by `h.domChart` and `h.codChart`. -/ -@[no_expose] def equiv (h : IsImmersionAtOfComplement F I J n f x) : (E Γ— F) ≃L[π•œ] E'' := by - exact Classical.choose <| LiftSourceTargetPropertyAt.property h +def equiv (h : IsImmersionAtOfComplement F I J n f x) : (E Γ— F) ≃L[π•œ] E'' := + Classical.choose <| LiftSourceTargetPropertyAt.property h lemma writtenInCharts (h : IsImmersionAtOfComplement F I J n f x) : EqOn ((h.codChart.extend J) ∘ f ∘ (h.domChart.extend I).symm) (h.equiv ∘ (Β·, 0)) - (h.domChart.extend I).target := by - exact Classical.choose_spec <| LiftSourceTargetPropertyAt.property h + (h.domChart.extend I).target := + Classical.choose_spec <| LiftSourceTargetPropertyAt.property h lemma property (h : IsImmersionAtOfComplement F I J n f x) : LiftSourceTargetPropertyAt I J n f x (ImmersionAtProp F I J M N) := h @@ -291,15 +291,15 @@ lemma target_subset_preimage_target (h : IsImmersionAtOfComplement F I J n f x) /-- If `f` is an immersion at `x` and `g = f` on some neighbourhood of `x`, then `g` is an immersion at `x`. -/ lemma congr_of_eventuallyEq (hf : IsImmersionAtOfComplement F I J n f x) (hfg : f =αΆ [𝓝 x] g) : - IsImmersionAtOfComplement F I J n g x := by - exact LiftSourceTargetPropertyAt.congr_of_eventuallyEq + IsImmersionAtOfComplement F I J n g x := + LiftSourceTargetPropertyAt.congr_of_eventuallyEq isLocalSourceTargetProperty_immersionAtProp hf.property hfg /-- If `f = g` on some neighbourhood of `x`, then `f` is an immersion at `x` if and only if `g` is an immersion at `x`. -/ lemma congr_iff_of_eventuallyEq (hfg : f =αΆ [𝓝 x] g) : - IsImmersionAtOfComplement F I J n f x ↔ IsImmersionAtOfComplement F I J n g x := by - exact LiftSourceTargetPropertyAt.congr_iff_of_eventuallyEq + IsImmersionAtOfComplement F I J n f x ↔ IsImmersionAtOfComplement F I J n g x := + LiftSourceTargetPropertyAt.congr_iff_of_eventuallyEq isLocalSourceTargetProperty_immersionAtProp hfg lemma small (hf : IsImmersionAtOfComplement F I J n f x) : Small.{u} F := @@ -418,15 +418,13 @@ lemma mk_of_continuousAt {f : M β†’ N} {x : M} (hf : ContinuousAt f x) (equiv : /-- A choice of complement of the model normed space `E` of `M` in the model normed space `E'` of `N` -/ -@[no_expose] def complement (h : IsImmersionAt I J n f x) : Type u := by - exact Classical.choose h +def complement (h : IsImmersionAt I J n f x) : Type u := Classical.choose h -@[no_expose] instance (h : IsImmersionAt I J n f x) : NormedAddCommGroup h.complement := by - exact Classical.choose <| Classical.choose_spec h +@[no_expose] instance (h : IsImmersionAt I J n f x) : NormedAddCommGroup h.complement := + Classical.choose <| Classical.choose_spec h -@[no_expose] -instance (h : IsImmersionAt I J n f x) : NormedSpace π•œ h.complement := by - exact Classical.choose <| Classical.choose_spec <| Classical.choose_spec h +@[no_expose] instance (h : IsImmersionAt I J n f x) : NormedSpace π•œ h.complement := + Classical.choose <| Classical.choose_spec <| Classical.choose_spec h lemma isImmersionAtOfComplement_complement (h : IsImmersionAt I J n f x) : IsImmersionAtOfComplement h.complement I J n f x := @@ -654,10 +652,10 @@ variable {f g : M β†’ N} `E'` of `N` -/ def complement (h : IsImmersion I J n f) : Type u := Classical.choose h -instance (h : IsImmersion I J n f) : NormedAddCommGroup h.complement := +@[no_expose] instance (h : IsImmersion I J n f) : NormedAddCommGroup h.complement := Classical.choose <| Classical.choose_spec h -instance (h : IsImmersion I J n f) : NormedSpace π•œ h.complement := +@[no_expose] instance (h : IsImmersion I J n f) : NormedSpace π•œ h.complement := Classical.choose <| Classical.choose_spec <| Classical.choose_spec h lemma isImmersionOfComplement_complement (h : IsImmersion I J n f) :