import PoincareLib.Geometry.RicciFlow.ReducedGeometry.LGeometry.Path.ReferenceEnergy /-! Adapted from Mapher `PoincareMT/Proofs/M08/SquareEnergy.lean` at `f927d9e1f0810042766d3b5f64d3f4da02ee93cc`. -/ /-! # Removing the backward-time energy weight All admissible paths, including competitors with no endpoint derivative, have the stated energy identity after squaring time. -/ set_option autoImplicit false set_option backward.isDefEq.respectTransparency false open scoped Manifold ContDiff Bundle intervalIntegral Topology open MeasureTheory universe u namespace PoincareMT.LGeometry variable {n : โ„•} {M : Type u} [TopologicalSpace M] [ChartedSpace (EuclideanSpace โ„ (Fin n)) M] [IsManifold (๐“ก n) โˆž M] theorem squarePath_continuousOn {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) : ContinuousOn (squareReparameterizedCurve p.curve) (sqrtParameterInterval ฯ„โ‚ ฯ„โ‚‚) := by apply p.continuous.comp (continuous_id.pow 2).continuousOn intro s hs change ฯ„โ‚ โ‰ค s ^ 2 โˆง s ^ 2 โ‰ค ฯ„โ‚‚ constructor ยท simpa only [Real.sq_sqrt p.nonnegative] using (sq_le_sqโ‚€ (Real.sqrt_nonneg ฯ„โ‚) ((Real.sqrt_nonneg ฯ„โ‚).trans hs.1)).mpr hs.1 ยท simpa only [Real.sq_sqrt (p.nonnegative.trans p.ordered.le)] using (sq_le_sqโ‚€ ((Real.sqrt_nonneg ฯ„โ‚).trans hs.1) (Real.sqrt_nonneg ฯ„โ‚‚)).mpr hs.2 theorem squarePath_regular {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) : ContMDiffOn (๐“˜(โ„, โ„)) (๐“ก n) 1 (squareReparameterizedCurve p.curve) (Set.Ioo (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚)) := by exact p.regular.comp ((contDiff_id.pow 2).contMDiff.contMDiffOn) (fun s hs โ†ฆ (sq_mem_backward_interior p.nonnegative hs).2) theorem squarePath_referenceSpeedSq {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) (g : RiemannianMetric n M) {s : โ„} (hs : s โˆˆ Set.Ioo (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚)) : referenceSpeedSq g (squareReparameterizedCurve p.curve) s = 2 * ((Real.sqrt (s ^ 2) * referenceSpeedSq g p.curve (s ^ 2)) * (2 * s)) := by have hpos := (sq_mem_backward_interior p.nonnegative hs).1 have hฯ„ := (sq_mem_backward_interior p.nonnegative hs).2 have hฮณ := (p.regular _ hฯ„).contMDiffAt (isOpen_Ioo.mem_nhds hฯ„) have hv := curveVelocity_comp_sq (hฮณ.mdifferentiableAt one_ne_zero) unfold referenceSpeedSq squareReparameterizedCurve rw [hv, Real.sqrt_sq hpos.le] simp only [map_smul, smul_apply, smul_eq_mul] ring /-- The squared-time reference energy is twice the weighted original energy. -/ theorem squarePath_referenceEnergy {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) (g : RiemannianMetric n M) (hW : IntervalIntegrable (fun ฯ„ โ†ฆ Real.sqrt ฯ„ * referenceSpeedSq g p.curve ฯ„) volume ฯ„โ‚ ฯ„โ‚‚) : IntervalIntegrable (referenceSpeedSq g (squareReparameterizedCurve p.curve)) volume (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚) โˆง (โˆซ s in Real.sqrt ฯ„โ‚..Real.sqrt ฯ„โ‚‚, referenceSpeedSq g (squareReparameterizedCurve p.curve) s) = 2 * โˆซ ฯ„ in ฯ„โ‚..ฯ„โ‚‚, Real.sqrt ฯ„ * referenceSpeedSq g p.curve ฯ„ := by let W := fun ฯ„ โ†ฆ Real.sqrt ฯ„ * referenceSpeedSq g p.curve ฯ„ have hle := Real.sqrt_le_sqrt p.ordered.le have hderiv (s : โ„) : HasDerivAt (fun r : โ„ โ†ฆ r ^ 2) (2 * s) s := by simpa using hasDerivAt_pow 2 s have hnonneg : โˆ€ s โˆˆ Set.uIoo (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚), 0 โ‰ค 2 * s := by intro s hs rw [Set.uIoo_of_le hle] at hs exact mul_nonneg (by norm_num) ((Real.sqrt_nonneg ฯ„โ‚).trans hs.1.le) have htrans : IntervalIntegrable (fun s โ†ฆ W (s ^ 2) * (2 * s)) volume (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚) := by apply (intervalIntegral.integrable_comp_mul_deriv_iff_of_deriv_nonneg (f := fun s : โ„ โ†ฆ s ^ 2) (f' := fun s โ†ฆ 2 * s) (g := W) (continuous_id.pow 2).continuousOn (fun s _ โ†ฆ hderiv s) hnonneg).mpr simpa only [Real.sq_sqrt p.nonnegative, Real.sq_sqrt (p.nonnegative.trans p.ordered.le)] using hW have hidentity : (โˆซ s in Real.sqrt ฯ„โ‚..Real.sqrt ฯ„โ‚‚, W (s ^ 2) * (2 * s)) = โˆซ ฯ„ in ฯ„โ‚..ฯ„โ‚‚, W ฯ„ := by have h := intervalIntegral.integral_comp_mul_deriv_of_deriv_nonneg (f := fun s : โ„ โ†ฆ s ^ 2) (f' := fun s โ†ฆ 2 * s) (g := W) (continuous_id.pow 2).continuousOn (fun s _ โ†ฆ hderiv s) hnonneg simpa only [Function.comp_apply, Real.sq_sqrt p.nonnegative, Real.sq_sqrt (p.nonnegative.trans p.ordered.le)] using h constructor ยท apply (htrans.const_mul 2).congr_uIoo intro s hs rw [Set.uIoo_of_le hle] at hs exact (squarePath_referenceSpeedSq p g hs).symm ยท calc _ = โˆซ s in Real.sqrt ฯ„โ‚..Real.sqrt ฯ„โ‚‚, 2 * (W (s ^ 2) * (2 * s)) := intervalIntegral.integral_congr_Ioo_of_le hle (fun s hs โ†ฆ squarePath_referenceSpeedSq p g hs) _ = 2 * โˆซ s in Real.sqrt ฯ„โ‚..Real.sqrt ฯ„โ‚‚, W (s ^ 2) * (2 * s) := intervalIntegral.integral_const_mul _ _ _ = _ := by rw [hidentity] theorem squarePath_regularizedIntegrand {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) {s : โ„} (hs : s โˆˆ Set.Ioo (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚)) : regularizedLIntegrand F T (squareReparameterizedCurve p.curve) s = backwardLIntegrand F T p.curve (s ^ 2) * (2 * s) := by have hpos := (sq_mem_backward_interior p.nonnegative hs).1 have hฯ„ := (sq_mem_backward_interior p.nonnegative hs).2 have hฮณ := (p.regular _ hฯ„).contMDiffAt (isOpen_Ioo.mem_nhds hฯ„) have hv := curveVelocity_comp_sq (hฮณ.mdifferentiableAt one_ne_zero) unfold regularizedLIntegrand backwardLIntegrand squareReparameterizedCurve rw [hv, Real.sqrt_sq hpos.le] simp only [map_smul, smul_apply, smul_eq_mul] ring /-- The square representative of every frozen competitor has the same action. -/ theorem squarePath_action {J : Set โ„} {F : RicciFlow n M J} {T ฯ„โ‚ ฯ„โ‚‚ : โ„} (p : BackwardTimePath F T ฯ„โ‚ ฯ„โ‚‚) : IntervalIntegrable (regularizedLIntegrand F T (squareReparameterizedCurve p.curve)) volume (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚) โˆง regularizedLAction F T ฯ„โ‚ ฯ„โ‚‚ (squareReparameterizedCurve p.curve) = backwardLLength F T ฯ„โ‚ ฯ„โ‚‚ p.curve := by have hle := Real.sqrt_le_sqrt p.ordered.le have htrans : IntervalIntegrable (fun s โ†ฆ backwardLIntegrand F T p.curve (s ^ 2) * (2 * s)) volume (Real.sqrt ฯ„โ‚) (Real.sqrt ฯ„โ‚‚) := by apply (intervalIntegral.integrable_comp_mul_deriv_iff_of_deriv_nonneg (f := fun s : โ„ โ†ฆ s ^ 2) (f' := fun s โ†ฆ 2 * s) (g := backwardLIntegrand F T p.curve) (continuous_id.pow 2).continuousOn (fun s _ โ†ฆ by simpa using hasDerivAt_pow 2 s) ?_).mpr ยท simpa only [Real.sq_sqrt p.nonnegative, Real.sq_sqrt (p.nonnegative.trans p.ordered.le)] using p.l_integrable ยท intro s hs have hspos : 0 < s := (Real.sqrt_nonneg ฯ„โ‚).trans_lt (by simpa [min_eq_left hle] using hs.1) exact mul_nonneg (by norm_num) hspos.le constructor ยท apply htrans.congr_uIoo intro s hs rw [Set.uIoo_of_le hle] at hs exact (squarePath_regularizedIntegrand p hs).symm ยท rw [backwardLLength_eq_transformed p] exact intervalIntegral.integral_congr_Ioo_of_le hle (fun s hs โ†ฆ squarePath_regularizedIntegrand p hs) /- The converse square substitution is needed when a smooth square-root representative is used to manufacture a `BackwardTimePath`. -/ theorem intervalIntegrable_of_square_transform {a b : โ„} (ha : 0 โ‰ค a) (hab : a โ‰ค b) {g r : โ„ โ†’ โ„} (hr : IntervalIntegrable r volume (Real.sqrt a) (Real.sqrt b)) (heq : โˆ€ s โˆˆ Set.Ioo (Real.sqrt a) (Real.sqrt b), r s = g (s ^ 2) * (2 * s)) : IntervalIntegrable g volume a b := by have hsqrt : Real.sqrt a โ‰ค Real.sqrt b := Real.sqrt_le_sqrt hab have hnonneg : โˆ€ s โˆˆ Set.uIoo (Real.sqrt a) (Real.sqrt b), 0 โ‰ค 2 * s := by intro s hs rw [Set.uIoo_of_le hsqrt] at hs exact mul_nonneg (by norm_num) ((Real.sqrt_nonneg a).trans hs.1.le) have hiff := intervalIntegral.integrable_comp_mul_deriv_iff_of_deriv_nonneg (f := fun s : โ„ โ†ฆ s ^ 2) (f' := fun s โ†ฆ 2 * s) (g := g) (continuous_id.pow 2).continuousOn (fun s _ โ†ฆ by simpa using hasDerivAt_pow 2 s) hnonneg have htrans : IntervalIntegrable (fun s โ†ฆ g (s ^ 2) * (2 * s)) volume (Real.sqrt a) (Real.sqrt b) := by apply hr.congr_uIoo intro s hs rw [Set.uIoo_of_le hsqrt] at hs exact heq s hs simpa only [Real.sq_sqrt ha, Real.sq_sqrt (ha.trans hab)] using hiff.mp htrans end PoincareMT.LGeometry