import PoincareLib.Geometry.RicciFlow.Curvature.Calculus import PoincareLib.Geometry.RicciFlow.Harnack.Matrix.Positivity.InputAction import PoincareLib.Geometry.RicciFlow.Harnack.Matrix.Positivity.BlockContact import PoincareLib.Geometry.RicciFlow.Harnack.Matrix.Evolution.QuadraticHeat import PoincareLib.Geometry.RicciFlow.Harnack.Matrix.Spacetime.M /-! # Ordinary time contact for the Hamilton block The Ricci action on tensor slots is induced by a simultaneous linear change of input frame. Its contraction vanishes at a null positive-semidefinite Hamilton direction, so ordinary and covariant time contacts agree there. Reference: Chow et al., Part II, Theorem 15.16 and Section 15.4.5, pp. 272-287. -/ set_option autoImplicit false set_option backward.isDefEq.respectTransparency false set_option maxHeartbeats 800000 open scoped Manifold ContDiff Bundle BigOperators Topology universe u namespace Poincare.RicciFlow.Harnack open PoincareMT variable {n : โ„•} {M : Type u} [TopologicalSpace M] [ChartedSpace (EuclideanSpace โ„ (Fin n)) M] [IsManifold (๐“ก n) โˆž M] /-- The joint smoothness producer supplies ordinary time differentiability of Hamilton's two-tensor on fixed tangent inputs. -/ lemma differentiableAt_hamiltonM (hC : RicciFlowCurvatureCalculus.{u}) {J : Set โ„} (F : RicciFlow n M J) (Tโ‚€ : โ„) {t : โ„} (ht : t โˆˆ interior J) (hฯ„ : t - Tโ‚€ โ‰  0) (x : M) (a c : TangentSpace (๐“ก n) x) : DifferentiableAt โ„ (fun s => hamiltonM (F.connection s) (s - Tโ‚€) x a c) t := by let X := fun i : Fin 2 => FiberBundle.extend (EuclideanSpace โ„ (Fin n)) (![a, c] i) have hX (i : Fin 2) : ContMDiffAt (๐“ก n) ((๐“ก n).prod (๐“ก n)) โˆž (T% (X i)) x := FiberBundle.contMDiffAt_extend (๐“ก n) (EuclideanSpace โ„ (Fin n)) (![a, c] i) have h := contMDiffAt_hamiltonM_fields hC F Tโ‚€ ht hฯ„ hX have hp : ContMDiffAt ๐“˜(โ„, โ„) (๐“˜(โ„, โ„).prod (๐“ก n)) โˆž (fun s : โ„ => (s, x)) t := contMDiffAt_id.prodMk contMDiffAt_const have hd := ((h.comp t hp).contDiffAt.differentiableAt (by simp)) simpa only [Function.comp_def, X, FiberBundle.extend_apply_self, Matrix.cons_val_zero, Matrix.cons_val_one] using hd /-- Ricci slot corrections vanish in the actual geometric null quadratic. -/ lemma hamilton_ricci_action_zero_at_null {Tโ‚€ Tโ‚ : โ„} (F : RicciFlow n M (Set.Ioo Tโ‚€ Tโ‚)) (t ฯ„ : โ„) (x : M) (U : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (W : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (hQ : HamiltonBlockPos F t x ฯ„) (hnull : let D := F.connection t let b := (F.metric t).orthonormalBasis x (โˆ‘ a, โˆ‘ c, hamiltonM D ฯ„ x (b a) (b c) * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, hamiltonP D x (b a) (b c) (b d) * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, D.curvatureTensor x (b a) (b c) (b d) (b e) * U a c * U d e) = 0) : let D := F.connection t let b := (F.metric t).orthonormalBasis x (โˆ‘ a, โˆ‘ c, D.ricciTensorAction (fun y z => hamiltonM D ฯ„ y (z 0) (z 1)) x ![b a, b c] * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, D.ricciTensorAction (fun y z => hamiltonP D y (z 0) (z 1) (z 2)) x ![b a, b c, b d] * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, D.ricciTensorAction D.riemannEvaluation x ![b a, b c, b d, b e] * U a c * U d e) = 0 := by let D := F.connection t let b := (F.metric t).orthonormalBasis x have h := hamiltonBlock_input_action_zero (fun a c d e => D.curvatureTensor x (b a) (b c) (b d) (b e)) (fun a c d => hamiltonP D x (b a) (b c) (b d)) (fun a c => hamiltonM D ฯ„ x (b a) (b c)) U (fun a c => D.ricci x (b a) (b c)) W hQ hnull dsimp only [D, b] at h dsimp only simp only [LeviCivitaData.ricciTensorAction, Fin.sum_univ_two, Fin.sum_univ_three, Fin.sum_univ_four, Function.update_apply, Matrix.cons_val_zero, Matrix.cons_val_one, Matrix.cons_val_two, Matrix.cons_val_three, Matrix.head_cons, Matrix.tail_cons, LeviCivitaData.riemannEvaluation] simp only [Finset.sum_add_distrib] at h exact h /-- At a spatial null direction of the positive Hamilton block, its ordinary time derivative is nonnegative on the fixed tangent inputs. -/ theorem hamilton_time_quadratic_nonneg_at_null [T2Space M] (hC : RicciFlowCurvatureTheory.{u}) {Tโ‚€ Tโ‚ : โ„} (F : RicciFlow n M (Set.Ioo Tโ‚€ Tโ‚)) {t : โ„} (ht : t โˆˆ Set.Ioo Tโ‚€ Tโ‚) (x : M) (U : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (W : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (hU : โˆ€ a c, U a c = -U c a) (hQ : โˆ€แถ  y in ๐“ x, HamiltonBlockPos F t y (t - Tโ‚€)) (hnull : let D := F.connection t let b := (F.metric t).orthonormalBasis x (โˆ‘ a, โˆ‘ c, hamiltonM D (t - Tโ‚€) x (b a) (b c) * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, hamiltonP D x (b a) (b c) (b d) * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, D.curvatureTensor x (b a) (b c) (b d) (b e) * U a c * U d e) = 0) : let b := (F.metric t).orthonormalBasis x 0 โ‰ค (โˆ‘ a, โˆ‘ c, deriv (fun s => hamiltonM (F.connection s) (s - Tโ‚€) x (b a) (b c)) t * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, deriv (fun s => hamiltonP (F.connection s) x (b a) (b c) (b d)) t * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, deriv (fun s => (F.connection s).curvatureTensor x (b a) (b c) (b d) (b e)) t * U a c * U d e) := by classical let D := F.connection t let b := (F.metric t).orthonormalBasis x let Ric := fun a c => D.ricci x (b a) (b c) let k := (2 * (t - Tโ‚€))โปยน let V := fun e a c => ((Ric e a + k * (if e = a then 1 else 0)) * W c - W a * (Ric e c + k * (if e = c then 1 else 0))) / 2 have hheat := hamilton_heat_quadratic_nonneg_at_null hC F ht x U W hU hQ.self_of_nhds hnull have hspace := hamilton_diffusion_quadratic_nonneg_at_null hC F t (t - Tโ‚€) x U W hQ hnull V have haction := hamilton_ricci_action_zero_at_null F t (t - Tโ‚€) x U W hQ.self_of_nhds hnull dsimp only [V, Ric, k, D, b] at hspace dsimp only at hheat hspace haction โŠข simp only [RicciFlow.tensorHeatOperator, LeviCivitaData.riemannEvaluation, Matrix.cons_val_zero, Matrix.cons_val_one, Matrix.cons_val_two, Matrix.cons_val_three, Matrix.head_cons, Matrix.tail_cons, add_mul, sub_mul, Finset.sum_add_distrib, Finset.sum_sub_distrib, mul_assoc] at hheat hspace haction โŠข linarith only [hheat, hspace, haction] /-- The fixed-input Hamilton quadratic has a nonnegative ordinary derivative at a spatial null direction. -/ theorem deriv_hamilton_quadratic_nonneg_at_null [T2Space M] (hC : RicciFlowCurvatureTheory.{u}) {Tโ‚€ Tโ‚ : โ„} (F : RicciFlow n M (Set.Ioo Tโ‚€ Tโ‚)) {t : โ„} (ht : t โˆˆ Set.Ioo Tโ‚€ Tโ‚) (x : M) (U : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (W : Fin (Module.finrank โ„ (TangentSpace (๐“ก n) x)) โ†’ โ„) (hU : โˆ€ a c, U a c = -U c a) (hQ : โˆ€แถ  y in ๐“ x, HamiltonBlockPos F t y (t - Tโ‚€)) (hnull : let D := F.connection t let b := (F.metric t).orthonormalBasis x (โˆ‘ a, โˆ‘ c, hamiltonM D (t - Tโ‚€) x (b a) (b c) * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, hamiltonP D x (b a) (b c) (b d) * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, D.curvatureTensor x (b a) (b c) (b d) (b e) * U a c * U d e) = 0) : let b := (F.metric t).orthonormalBasis x 0 โ‰ค deriv (fun s => (โˆ‘ a, โˆ‘ c, hamiltonM (F.connection s) (s - Tโ‚€) x (b a) (b c) * W a * W c) + 2 * (โˆ‘ a, โˆ‘ c, โˆ‘ d, hamiltonP (F.connection s) x (b a) (b c) (b d) * U a c * W d) + (โˆ‘ a, โˆ‘ c, โˆ‘ d, โˆ‘ e, (F.connection s).curvatureTensor x (b a) (b c) (b d) (b e) * U a c * U d e)) t := by classical let b := (F.metric t).orthonormalBasis x have ht' : t โˆˆ interior (Set.Ioo Tโ‚€ Tโ‚) := by simpa only [interior_Ioo] using ht have hM := HasDerivAt.fun_sum (u := Finset.univ) fun a _ => HasDerivAt.fun_sum (u := Finset.univ) fun c _ => (((differentiableAt_hamiltonM hC F Tโ‚€ ht' (ne_of_gt (sub_pos.mpr ht.1)) x (b a) (b c)).hasDerivAt.mul_const (W a)).mul_const (W c)) have hP := HasDerivAt.fun_sum (u := Finset.univ) fun a _ => HasDerivAt.fun_sum (u := Finset.univ) fun c _ => HasDerivAt.fun_sum (u := Finset.univ) fun d _ => by have hd := (hasDerivAt_hamiltonP_evolution hC F ht' x (b a) (b c) (b d)).differentiableAt.hasDerivAt exact (hd.mul_const (U a c)).mul_const (W d) have hR := HasDerivAt.fun_sum (u := Finset.univ) fun a _ => HasDerivAt.fun_sum (u := Finset.univ) fun c _ => HasDerivAt.fun_sum (u := Finset.univ) fun d _ => HasDerivAt.fun_sum (u := Finset.univ) fun e _ => by have hd := ((hC.curvature_evolution n M (Set.Ioo Tโ‚€ Tโ‚) F t ht x (b a) (b c) (b d) (b e)).hasDerivAt (mem_interior_iff_mem_nhds.mp ht')).differentiableAt.hasDerivAt exact (hd.mul_const (U a c)).mul_const (U d e) dsimp only have hd := ((hM.add (hP.const_mul 2)).add hR).deriv simp only [Pi.add_def, b] at hd rw [hd] exact hamilton_time_quadratic_nonneg_at_null hC F ht x U W hU hQ hnull end Poincare.RicciFlow.Harnack