import Mathlib.Geometry.Manifold.Diffeomorph open Set open scoped Manifold ContDiff noncomputable section set_option autoImplicit false set_option backward.isDefEq.respectTransparency false /-! # Linear changes of manifold model spaces A continuous linear equivalence transports each chart and gives the identity map as a smooth equivalence between the old and new manifold structures. -/ namespace Poincare.Manifold variable {E E' : Type*} [NormedAddCommGroup E] [NormedSpace โ„ E] [NormedAddCommGroup E'] [NormedSpace โ„ E'] {M : Type*} [TopologicalSpace M] [ChartedSpace E M] [IsManifold ๐“˜(โ„,E) โˆž M] @[instance_reducible] def linearRechart (A : E โ‰ƒL[โ„] E') : ChartedSpace E' M where atlas := (fun e : OpenPartialHomeomorph M E => e.trans A.toHomeomorph.toOpenPartialHomeomorph) '' atlas E M chartAt x := (chartAt E x).trans A.toHomeomorph.toOpenPartialHomeomorph mem_chart_source x := by simp only [OpenPartialHomeomorph.trans_source, Homeomorph.toOpenPartialHomeomorph_source, preimage_univ, inter_univ, mem_chart_source] chart_mem_atlas x := โŸจchartAt E x, chart_mem_atlas E x, rflโŸฉ theorem isManifold_linearRechart (A : E โ‰ƒL[โ„] E') : let := linearRechart (M := M) A IsManifold ๐“˜(โ„,E') โˆž M := by let := linearRechart (M := M) A apply isManifold_of_contDiffOn rintro _ _ โŸจe, he, rflโŸฉ โŸจe', he', rflโŸฉ have h := (๐“˜(โ„,E)).contDiffOn_extendCoordChange (IsManifold.subset_maximalAtlas (I := ๐“˜(โ„,E)) (n := โˆž) he) (IsManifold.subset_maximalAtlas (I := ๐“˜(โ„,E)) (n := โˆž) he') have h' := A.contDiff.comp_contDiffOn (h.comp A.symm.contDiff.contDiffOn (by intro x hx; exact hx)) convert h' using 1 <;> simp [mfld_simps, Function.comp_def] rfl omit [IsManifold ๐“˜(โ„,E) โˆž M] in theorem contMDiff_linearRechart_id (A : E โ‰ƒL[โ„] E') : let := linearRechart (M := M) A ContMDiff ๐“˜(โ„,E) ๐“˜(โ„,E') โˆž (id : M โ†’ M) := by let := linearRechart (M := M) A dsimp only intro x rw [contMDiffAt_iff] refine โŸจcontinuousAt_id, ?_โŸฉ apply ContDiffAt.contDiffWithinAt apply A.contDiff.contDiffAt.congr_of_eventuallyEq filter_upwards [(chartAt E x).open_target.mem_nhds (mem_chart_target E x)] with z hz simp only [extChartAt, mfld_simps] change A (chartAt E x ((chartAt E x).symm z)) = A z rw [(chartAt E x).right_inv hz] omit [IsManifold ๐“˜(โ„,E) โˆž M] in theorem contMDiff_linearRechart_id_symm (A : E โ‰ƒL[โ„] E') : let := linearRechart (M := M) A ContMDiff ๐“˜(โ„,E') ๐“˜(โ„,E) โˆž (id : M โ†’ M) := by let := linearRechart (M := M) A dsimp only intro x rw [contMDiffAt_iff] refine โŸจcontinuousAt_id, ?_โŸฉ apply ContDiffAt.contDiffWithinAt apply A.symm.contDiff.contDiffAt.congr_of_eventuallyEq have hnh : โˆ€แถ  z in nhds (A (chartAt E x x)), A.symm z โˆˆ (chartAt E x).target := A.symm.continuous.tendsto _ |>.eventually ((chartAt E x).open_target.mem_nhds (by simp)) filter_upwards [hnh] with z hz simp only [extChartAt, mfld_simps] change chartAt E x ((chartAt E x).symm (A.symm z)) = A.symm z rw [(chartAt E x).right_inv hz] def linearRechartDiffeomorph (A : E โ‰ƒL[โ„] E') : let := linearRechart (M := M) A M โ‰ƒโ‚˜โŸฎ๐“˜(โ„,E),๐“˜(โ„,E')โŸฏ M := by let := linearRechart (M := M) A exact { toEquiv := Equiv.refl M contMDiff_toFun := contMDiff_linearRechart_id A contMDiff_invFun := contMDiff_linearRechart_id_symm A } end Poincare.Manifold