-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: rename/redefine
homeomorphUnitBall
(#6030)
* Add `Equiv.toLocalEquivOfImageEq` and `Homeomorph.toLocalHomeomorphOfImageEq`. * Rename `homeomorphUnitBall` to `Homeomorph.unitBall`. * Add `LocalHomeomorph.univUnitBall`, a `LocalHomeomorph` version of `Homeomorph.unitBall`. * Add `LocalHomeomorph.unitBallBall` and `LocalHomeomorph.univBall`. Inspired by a definition from the sphere eversion project.
- Loading branch information
Showing
6 changed files
with
228 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,152 @@ | ||
/- | ||
Copyright (c) 2021 Yury Kudryashov. All rights reserved. | ||
Released under Apache 2.0 license as described in the file LICENSE. | ||
Authors: Yury Kudryashov, Oliver Nash | ||
-/ | ||
import Mathlib.Topology.LocalHomeomorph | ||
import Mathlib.Analysis.NormedSpace.AddTorsor | ||
import Mathlib.Analysis.NormedSpace.Pointwise | ||
|
||
#align_import analysis.normed_space.basic from "leanprover-community/mathlib"@"bc91ed7093bf098d253401e69df601fc33dde156" | ||
|
||
/-! | ||
# (Local) homeomorphism between a normed space and a ball | ||
In this file we show that a real (semi)normed vector space is homeomorphic to the unit ball. | ||
We formalize it in two ways: | ||
- as a `Homeomorph`, see `Homeomorph.unitBall`; | ||
- as a `LocalHomeomorph` with `source = Set.univ` and `target = Metric.ball (0 : E) 1`. | ||
While the former approach is more natural, the latter approach provides us | ||
with a globally defined inverse function which makes it easier to say | ||
that this homeomorphism is in fact a diffeomorphism. | ||
We also show that the unit ball `Metric.ball (0 : E) 1` is homeomorphic | ||
to a ball of positive radius in an affine space over `E`, see `LocalHomeomorph.unitBallBall`. | ||
## Tags | ||
homeomorphism, ball | ||
-/ | ||
|
||
open Set Metric Pointwise | ||
variable {E : Type _} [SeminormedAddCommGroup E] [NormedSpace ℝ E] | ||
|
||
noncomputable section | ||
|
||
/-- Local homeomorphism between a real (semi)normed space and the unit ball. | ||
See also `Homeomorph.unitBall`. -/ | ||
@[simps (config := .lemmasOnly)] | ||
def LocalHomeomorph.univUnitBall : LocalHomeomorph E E where | ||
toFun x := (1 + ‖x‖ ^ 2).sqrt⁻¹ • x | ||
invFun y := (1 - ‖(y : E)‖ ^ 2).sqrt⁻¹ • (y : E) | ||
source := univ | ||
target := ball 0 1 | ||
map_source' x _ := by | ||
have : 0 < 1 + ‖x‖ ^ 2 := by positivity | ||
rw [mem_ball_zero_iff, norm_smul, Real.norm_eq_abs, abs_inv, ← _root_.div_eq_inv_mul, | ||
div_lt_one (abs_pos.mpr <| Real.sqrt_ne_zero'.mpr this), ← abs_norm x, ← sq_lt_sq, | ||
abs_norm, Real.sq_sqrt this.le] | ||
exact lt_one_add _ | ||
map_target' _ _ := trivial | ||
left_inv' x _ := by | ||
field_simp [norm_smul, smul_smul, (zero_lt_one_add_norm_sq x).ne', sq_abs, | ||
Real.sq_sqrt (zero_lt_one_add_norm_sq x).le, ← Real.sqrt_div (zero_lt_one_add_norm_sq x).le] | ||
right_inv' y hy := by | ||
have : 0 < 1 - ‖y‖ ^ 2 := by nlinarith [norm_nonneg y, mem_ball_zero_iff.1 hy] | ||
field_simp [norm_smul, smul_smul, this.ne', sq_abs, Real.sq_sqrt this.le, | ||
← Real.sqrt_div this.le] | ||
open_source := isOpen_univ | ||
open_target := isOpen_ball | ||
continuous_toFun := by | ||
suffices Continuous fun (x:E) => (1 + ‖x‖ ^ 2).sqrt⁻¹ | ||
from (this.smul continuous_id).continuousOn | ||
refine' Continuous.inv₀ _ fun x => Real.sqrt_ne_zero'.mpr (by positivity) | ||
continuity | ||
continuous_invFun := by | ||
have : ∀ y ∈ ball (0 : E) 1, (1 - ‖(y : E)‖ ^ 2).sqrt ≠ 0 := fun y hy ↦ by | ||
rw [Real.sqrt_ne_zero'] | ||
nlinarith [norm_nonneg y, mem_ball_zero_iff.1 hy] | ||
exact ContinuousOn.smul (ContinuousOn.inv₀ | ||
(continuousOn_const.sub (continuous_norm.continuousOn.pow _)).sqrt this) continuousOn_id | ||
|
||
@[simp] | ||
theorem LocalHomeomorph.univUnitBall_apply_zero : univUnitBall (0 : E) = 0 := by | ||
simp [LocalHomeomorph.univUnitBall_apply] | ||
|
||
@[simp] | ||
theorem LocalHomeomorph.univUnitBall_symm_apply_zero : univUnitBall.symm (0 : E) = 0 := by | ||
simp [LocalHomeomorph.univUnitBall_symm_apply] | ||
|
||
/-- A (semi) normed real vector space is homeomorphic to the unit ball in the same space. | ||
This homeomorphism sends `x : E` to `(1 + ‖x‖²)^(- ½) • x`. | ||
In many cases the actual implementation is not important, so we don't mark the projection lemmas | ||
`Homeomorph.unitBall_apply_coe` and `Homeomorph.unitBall_symm_apply` as `@[simp]`. | ||
See also `Homeomorph.contDiff_unitBall` and `LocalHomeomorph.contDiffOn_unitBall_symm` | ||
for smoothness properties that hold when `E` is an inner-product space. -/ | ||
@[simps! (config := .lemmasOnly)] | ||
def Homeomorph.unitBall : E ≃ₜ ball (0 : E) 1 := | ||
(Homeomorph.Set.univ _).symm.trans LocalHomeomorph.univUnitBall.toHomeomorphSourceTarget | ||
#align homeomorph_unit_ball Homeomorph.unitBall | ||
|
||
@[simp] | ||
theorem Homeomorph.coe_unitBall_apply_zero : | ||
(Homeomorph.unitBall (0 : E) : E) = 0 := | ||
LocalHomeomorph.univUnitBall_apply_zero | ||
#align coe_homeomorph_unit_ball_apply_zero Homeomorph.coe_unitBall_apply_zero | ||
|
||
variable {P : Type _} [PseudoMetricSpace P] [NormedAddTorsor E P] | ||
|
||
namespace LocalHomeomorph | ||
|
||
/-- Affine homeomorphism `(r • · +ᵥ c)` between a normed space and an add torsor over this space, | ||
interpreted as a `LocalHomeomorph` between `Metric.ball 0 1` and `Metric.ball c r`. -/ | ||
@[simps!] | ||
def unitBallBall (c : P) (r : ℝ) (hr : 0 < r) : LocalHomeomorph E P := | ||
((Homeomorph.smulOfNeZero r hr.ne').trans | ||
(IsometryEquiv.vaddConst c).toHomeomorph).toLocalHomeomorphOfImageEq | ||
(ball 0 1) isOpen_ball (ball c r) <| by | ||
change (IsometryEquiv.vaddConst c) ∘ (r • ·) '' ball (0 : E) 1 = ball c r | ||
rw [image_comp, image_smul, smul_unitBall hr.ne', IsometryEquiv.image_ball] | ||
simp [abs_of_pos hr] | ||
|
||
/-- If `r > 0`, then `LocalHomeomorph.univBall c r` is a smooth local homeomorphism | ||
with `source = Set.univ` and `target = Metric.ball c r`. | ||
Otherwise, it is the translation by `c`. | ||
Thus in all cases, it sends `0` to `c`, see `LocalHomeomorph.univBall_apply_zero`. -/ | ||
def univBall (c : P) (r : ℝ) : LocalHomeomorph E P := | ||
if h : 0 < r then univUnitBall.trans' (unitBallBall c r h) rfl | ||
else (IsometryEquiv.vaddConst c).toHomeomorph.toLocalHomeomorph | ||
|
||
@[simp] | ||
theorem univBall_source (c : P) (r : ℝ) : (univBall c r).source = univ := by | ||
unfold univBall; split_ifs <;> rfl | ||
|
||
theorem univBall_target (c : P) {r : ℝ} (hr : 0 < r) : (univBall c r).target = ball c r := by | ||
rw [univBall, dif_pos hr]; rfl | ||
|
||
theorem ball_subset_univBall_target (c : P) (r : ℝ) : ball c r ⊆ (univBall c r).target := by | ||
by_cases hr : 0 < r | ||
· rw [univBall_target c hr] | ||
· rw [univBall, dif_neg hr] | ||
exact subset_univ _ | ||
|
||
@[simp] | ||
theorem univBall_apply_zero (c : P) (r : ℝ) : univBall c r 0 = c := by | ||
unfold univBall; split_ifs <;> simp | ||
|
||
@[simp] | ||
theorem univBall_symm_apply_center (c : P) (r : ℝ) : (univBall c r).symm c = 0 := by | ||
have : 0 ∈ (univBall c r).source := by simp | ||
simpa only [univBall_apply_zero] using (univBall c r).left_inv this | ||
|
||
@[continuity] | ||
theorem continuous_univBall (c : P) (r : ℝ) : Continuous (univBall c r) := by | ||
simpa [continuous_iff_continuousOn_univ] using (univBall c r).continuousOn | ||
|
||
theorem continuousOn_univBall_symm (c : P) (r : ℝ) : ContinuousOn (univBall c r).symm (ball c r) := | ||
(univBall c r).symm.continuousOn.mono <| ball_subset_univBall_target c r |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters