diff --git a/lean/OAI/Analysis/BackwardIntertwiners/CoefficientSupport.lean b/lean/OAI/Analysis/BackwardIntertwiners/CoefficientSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..06045d5dbd4b3a56a0a243182ba935bd7d3d38e2 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/CoefficientSupport.lean @@ -0,0 +1,314 @@ +import OAI.Analysis.BackwardIntertwiners.ConvolutionBounds + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + + +def coefficientObstacle (d : ℕ → ℂ) : Set ℕ := {n | 0 < n ∧ d n ≠ 0} + +def coefficientEnvelope (d : ℕ → ℂ) : ℕ → ℝ := + convexEnvelope (coefficientObstacle d) (fun n => -Real.log ‖d n‖) + +namespace CoefficientEnvelope + +variable {d : ℕ → ℂ} {G : ℕ → ℝ} +variable (hu : ∀ n : ℕ, ∃ k, n < k ∧ d k ≠ 0) +variable (hG : DiscreteConvex G) (hG0 : G 0 = 0) +variable (hb : ∀ n, ‖d n‖ ≤ Real.exp (-G n)) + +include hu in +lemma unbounded : ∀ n : ℕ, ∃ k, n < k ∧ k ∈ coefficientObstacle d := by + intro n + obtain ⟨k, hk, hd⟩ := hu n + exact ⟨k, hk, by exact ⟨by omega, hd⟩⟩ + +include hG hG0 hb in +lemma minorant : G ∈ convexMinorants (coefficientObstacle d) (fun n => -Real.log ‖d n‖) := by + refine ⟨hG0, hG, ?_⟩ + intro n hn + have hn0 : 0 < ‖d n‖ := norm_pos_iff.mpr hn.2 + have hh := Real.log_le_log hn0 (hb n) + rw [Real.log_exp] at hh + linarith + +include hu hG hG0 hb in +lemma properties : + coefficientEnvelope d 0 = 0 ∧ DiscreteConvex (coefficientEnvelope d) ∧ + (∀ n, G n ≤ coefficientEnvelope d n) ∧ + (∀ n, ‖d n‖ ≤ Real.exp (-coefficientEnvelope d n)) ∧ + (∀ n, 0 < coefficientEnvelope d (n+2) - 2*coefficientEnvelope d (n+1) + + coefficientEnvelope d n → ‖d (n+1)‖ = Real.exp (-coefficientEnvelope d (n+1))) := by + have hm := minorant hG hG0 hb + have he : (convexMinorants (coefficientObstacle d) (fun n => -Real.log ‖d n‖)).Nonempty := ⟨G, hm⟩ + have hU := unbounded hu + refine ⟨ConvexEnvelope.zero hU he, ConvexEnvelope.convex hU he, + ConvexEnvelope.le_envelope hU hm, ?_, ?_⟩ + · intro n + by_cases hn : n = 0 + · subst n + simpa only [coefficientEnvelope, ConvexEnvelope.zero hU he, hG0] using hb 0 + · by_cases hd : d n = 0 + · simp only [hd, norm_zero]; exact (Real.exp_pos _).le + · have hbelow := ConvexEnvelope.below he (show n ∈ coefficientObstacle d from ⟨by omega, hd⟩) + have hlog : Real.log ‖d n‖ ≤ -coefficientEnvelope d n := by + change coefficientEnvelope d n ≤ -Real.log ‖d n‖ at hbelow + linarith + simpa only [Real.exp_log (norm_pos_iff.mpr hd)] using Real.exp_le_exp.mpr hlog + · intro n hn + obtain ⟨hd, hc⟩ := ConvexEnvelope.contact hU he n hn + change coefficientEnvelope d (n+1) = -Real.log ‖d (n+1)‖ at hc + rw [hc, neg_neg, Real.exp_log (norm_pos_iff.mpr hd.2)] + +end CoefficientEnvelope + + + +theorem no_both_unbounded {P Q : ℕ → ℝ} {b c : ℤ → ℂ} + (hb : EnvelopeBounds P Q b c) (hP : DiscreteConvex P) (hQ : DiscreteConvex Q) + (hP0 : P 0 = 0) (hQ0 : Q 0 = 0) {lam δ : ℝ} + (hlam : Real.log 3 < lam) (hδ : lam < δ) + (hqp : ∀ᶠ n : ℕ in atTop, δ*(n : ℝ)^2 ≤ P n) + (hqq : ∀ᶠ n : ℕ in atTop, δ*(n : ℝ)^2 ≤ Q n) + (hbu : ∀ n : ℕ, ∃ k, n < k ∧ b (k : ℤ) ≠ 0) + (hcu : ∀ n : ℕ, ∃ k, n < k ∧ c (-(k : ℤ)) ≠ 0) + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : False := by + obtain ⟨hA0, hA, hPA, hcA, hcontactA⟩ := + CoefficientEnvelope.properties hcu hP hP0 hb.c_neg + obtain ⟨hB0, hB, hQB, hbB, hcontactB⟩ := + CoefficientEnvelope.properties hbu hQ hQ0 hb.b_pos + let A := coefficientEnvelope (fun n => c (-(n : ℤ))) + let B := coefficientEnvelope (fun n => b (n : ℤ)) + apply no_correlation_of_envelopes (A := A) (B := B) (b := b) (c := c) + ?_ hA hB hA0 hB0 hlam hδ ?_ ?_ hcontactA hcontactB hz + · refine ⟨hbB, ?_, ?_, hcA⟩ + · intro n + exact (hb.b_neg n).trans (Real.exp_le_exp.mpr (hPA n)) + · intro n + exact (hb.c_pos n).trans (Real.exp_le_exp.mpr (hQB n)) + · filter_upwards [hqp] with n hn using hn.trans (hPA n) + · filter_upwards [hqq] with n hn using hn.trans (hQB n) + + +def boundedSideTail (B : ℕ → ℝ) (c : ℤ → ℂ) (h : ℤ) (p k : ℕ) : ℝ := + Real.exp (B p - B (p+k+1)) * ‖c (h+(k:ℤ)+1)‖ + +lemma boundedSideTail_nonneg (B : ℕ → ℝ) (c : ℤ → ℂ) (h : ℤ) (p k : ℕ) : + 0 ≤ boundedSideTail B c h p k := mul_nonneg (Real.exp_pos _).le (norm_nonneg _) + +lemma boundedSideTail_mono {B : ℕ → ℝ} (hB : DiscreteConvex B) + (c : ℤ → ℂ) (h : ℤ) {p₀ p : ℕ} (hpp : p₀ ≤ p) (k : ℕ) : + boundedSideTail B c h p k ≤ boundedSideTail B c h p₀ k := by + have hh := hB.increment_mono hpp (k+1) + unfold boundedSideTail + apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) + apply Real.exp_le_exp.mpr + simp only [← Nat.add_assoc] at hh + linarith + +lemma boundedSideTail_tendsto {B : ℕ → ℝ} (hB : DiscreteConvex B) + (hs : Tendsto (fun n => B (n+1)-B n) atTop atTop) + (c : ℤ → ℂ) (h : ℤ) {p₀ : ℕ} (hsum : Summable (boundedSideTail B c h p₀)) : + Tendsto (fun p => ∑' k, boundedSideTail B c h p k) atTop (𝓝 0) := by + have hpoint (k : ℕ) : Tendsto (fun p => boundedSideTail B c h p k) atTop (𝓝 0) := by + have heq : (fun p => boundedSideTail B c h p k) = + (fun p => normalizedTailTerm B p k * (Real.exp (-B (k+1)) * ‖c (h+(k:ℤ)+1)‖)) := by + funext p + unfold boundedSideTail normalizedTailTerm + rw [← mul_assoc, ← Real.exp_add] + congr 2 + ring + rw [heq] + simpa using (hB.tail_term_tendsto hs k).mul_const + (Real.exp (-B (k+1)) * ‖c (h+(k:ℤ)+1)‖) + have ht := tendsto_tsum_of_dominated_convergence hsum hpoint + (show ∀ᶠ p : ℕ in atTop, ∀ k, + ‖boundedSideTail B c h p k‖ ≤ boundedSideTail B c h p₀ k from ?_) + · simpa using ht + · filter_upwards [eventually_ge_atTop p₀] with p hp k + rw [Real.norm_eq_abs, abs_of_nonneg (boundedSideTail_nonneg _ _ _ _ _)] + exact boundedSideTail_mono hB c h hp k + + + +theorem no_unbounded_against_min {B : ℕ → ℝ} {b c : ℤ → ℂ} + (hB : DiscreteConvex B) (hB0 : B 0 = 0) {δ : ℝ} (hδ : 0 < δ) + (hquad : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ B n) + (hb : ∀ n : ℕ, ‖b n‖ ≤ Real.exp (-B n)) + (hc : ∀ n, 0 < B (n+2) - 2*B (n+1) + B n → + ‖b ((n+1:ℕ):ℤ)‖ = Real.exp (-B (n+1))) + {h : ℤ} (hch : c h ≠ 0) (hcmin : ∀ j : ℤ, j < h → c j = 0) + {p₀ : ℕ} (hsum : Summable (boundedSideTail B c h p₀)) + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : False := by + have hchpos := norm_pos_iff.mpr hch + have ht := boundedSideTail_tendsto hB (hB.slopes_tendsto hB0 hδ hquad) c h hsum + obtain ⟨N, hN⟩ := eventually_atTop.1 (ht (eventually_lt_nhds hchpos)) + obtain ⟨n, hn, hcurv⟩ := large_curvature hδ hδ hquad (max N (max p₀ (h.toNat+1))) + let p := n+1 + have hp₀ : p₀ ≤ p := by dsimp [p]; omega + have hpN : N ≤ p := by dsimp [p]; omega + have hph : h < (p : ℤ) := by dsimp [p]; omega + have hcontact : ‖b (p : ℤ)‖ = Real.exp (-B p) := hc n (by simpa using hcurv) + have htailsum : Summable (boundedSideTail B c h p) := by + apply hsum.of_norm_bounded + intro k + rw [Real.norm_eq_abs, abs_of_nonneg (boundedSideTail_nonneg _ _ _ _ _)] + exact boundedSideTail_mono hB c h hp₀ k + let f := fun i : ℤ => b ((p:ℤ)+i) * c (h+i) + have hfneg : ∀ k : ℕ, f (-((k:ℤ)+1)) = 0 := by + intro k + dsimp [f] + rw [hcmin _ (by omega), mul_zero] + have hfbound (k : ℕ) : ‖f ((k:ℤ)+1)‖ ≤ Real.exp (-B p) * boundedSideTail B c h p k := by + dsimp [f, boundedSideTail] + rw [norm_mul, ← mul_assoc, ← Real.exp_add] + have he : -B p + (B p - B (p+k+1)) = -B (p+k+1) := by ring + rw [he] + have hi : (p:ℤ)+((k:ℤ)+1) = ((p+k+1:ℕ):ℤ) := by omega + rw [hi] + simpa only [add_assoc] using mul_le_mul_of_nonneg_right (hb (p+k+1)) (norm_nonneg (c (h+(k:ℤ)+1))) + have hfpos : Summable (fun k : ℕ => ‖f ((k:ℤ)+1)‖) := by + apply (htailsum.mul_left (Real.exp (-B p))).of_norm_bounded + intro k + simpa only [Real.norm_eq_abs, abs_of_nonneg (norm_nonneg _)] using hfbound k + have hfn : Summable (fun k : ℕ => ‖f (-((k:ℤ)+1))‖) := by + simp only [hfneg, norm_zero] + exact summable_zero + have hzcenter : (∑' i : ℤ, f i) = 0 := by + let r := ((p:ℤ)-h).toNat + have hr : 1 ≤ r := by dsimp [r]; omega + have hri : (r:ℤ) = (p:ℤ)-h := by dsimp [r]; omega + calc (∑' i : ℤ, f i) = ∑' i : ℤ, b ((p:ℤ)+i) * c (((p:ℤ)+i)-(r:ℤ)) := by + apply tsum_congr + intro i + dsimp [f] + congr 2 + omega + _ = ∑' j : ℤ, b j * c (j-r) := by + simpa only [Equiv.coe_addLeft] using + (Equiv.addLeft (p:ℤ)).tsum_eq (fun j : ℤ => b j * c (j-r)) + _ = 0 := hz r hr + have hcentral := central_norm_le_of_correlation_zero f hfpos hfn hzcenter + simp only [hfneg, norm_zero, tsum_zero, add_zero] at hcentral + have hcentral' : Real.exp (-B p) * ‖c h‖ ≤ + Real.exp (-B p) * ∑' k, boundedSideTail B c h p k := by + calc Real.exp (-B p) * ‖c h‖ = ‖f 0‖ := by simp [f, hcontact] + _ ≤ ∑' k : ℕ, ‖f ((k:ℤ)+1)‖ := hcentral + _ ≤ ∑' k, Real.exp (-B p) * boundedSideTail B c h p k := + hfpos.tsum_le_tsum hfbound (htailsum.mul_left _) + _ = _ := tsum_mul_left + have hle := (mul_le_mul_iff_right₀ (Real.exp_pos (-B p))).mp hcentral' + exact (not_lt_of_ge hle) (hN p hpN) + + +def positiveLog (w : ℤ → ℝ) (n : ℕ) : ℝ := -Real.log (w n) +def negativeLog (w : ℤ → ℝ) (n : ℕ) : ℝ := Real.log (w (-(n:ℤ))) +def stepRatio (w : ℤ → ℝ) (j : ℤ) : ℝ := w (j+1) / w j + +lemma stepRatio_summable {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) (hw0 : w 0 = 1) + (hP : DiscreteConvex (negativeLog w)) (hQ : DiscreteConvex (positiveLog w)) + {δ : ℝ} (hδ : 0 < δ) + (hqp : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ negativeLog w n) + (hqq : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ positiveLog w n) : + Summable (stepRatio w) := by + have hP0 : negativeLog w 0 = 0 := by simp [negativeLog, hw0] + have hQ0 : positiveLog w 0 = 0 := by simp [positiveLog, hw0] + have hsP := hP.summable_exp_neg_slope hP0 hδ hqp + have hsQ := hQ.summable_exp_neg_slope hQ0 hδ hqq + apply Summable.of_nat_of_neg_add_one + · apply hsQ.congr + intro n + unfold stepRatio positiveLog + have he : -(-Real.log (w (n+1)) - -Real.log (w n)) = + Real.log (w (n+1)) - Real.log (w n) := by ring + push_cast + rw [he, Real.exp_sub, Real.exp_log (hw _), Real.exp_log (hw _)] + · apply hsP.congr + intro n + unfold stepRatio negativeLog + have hi : -((n:ℤ)+1)+1 = -(n:ℤ) := by omega + rw [hi] + push_cast + rw [neg_sub, Real.exp_sub, Real.exp_log (hw _), Real.exp_log (hw _)] + +lemma bounds_of_weight {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) {b c : ℤ → ℂ} + (hb : ∀ j, ‖b j‖ ≤ w j) (hc : ∀ j, ‖c j‖ * w j ≤ 1) : + EnvelopeBounds (negativeLog w) (positiveLog w) b c := by + have hc' (j : ℤ) : ‖c j‖ ≤ (w j)⁻¹ := by + simpa only [one_div] using (le_div_iff₀ (hw j)).mpr (hc j) + constructor + · intro n + simpa [positiveLog, Real.exp_log (hw _)] using hb n + · intro n + simpa [negativeLog, Real.exp_log (hw _)] using hb (-(n:ℤ)) + · intro n + simpa [positiveLog, Real.exp_neg, Real.exp_log (hw _)] using hc' n + · intro n + simpa [negativeLog, Real.exp_neg, Real.exp_log (hw _)] using hc' (-(n:ℤ)) + +lemma boundedSideTail_summable {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) + (hdec : Antitone w) (hs : Summable (stepRatio w)) + {B : ℕ → ℝ} (hBw : ∀ n : ℕ, Real.exp (-B n) ≤ w n) + {c : ℤ → ℂ} (hc : ∀ j, ‖c j‖ * w j ≤ 1) + (h : ℤ) {p₀ : ℕ} (hp₀ : h+1 ≤ (p₀:ℤ)) : + Summable (boundedSideTail B c h p₀) := by + have hsm := hs.comp_injective (i := fun k : ℕ => h+(k:ℤ)+1) (by + intro a b hab; dsimp only at hab; omega) + apply (hsm.mul_left (Real.exp (B p₀))).of_norm_bounded + intro k + rw [Real.norm_eq_abs, abs_of_nonneg (boundedSideTail_nonneg _ _ _ _ _)] + change boundedSideTail B c h p₀ k ≤ Real.exp (B p₀) * stepRatio w (h+(k:ℤ)+1) + have hwle : Real.exp (-B (p₀+k+1)) ≤ w (h+(k:ℤ)+1+1) := by + exact (hBw _).trans (hdec (by omega)) + have hcw : ‖c (h+(k:ℤ)+1)‖ ≤ 1 / w (h+(k:ℤ)+1) := + (le_div_iff₀ (hw _)).mpr (hc _) + unfold boundedSideTail stepRatio + rw [Real.exp_sub, div_eq_mul_inv, ← Real.exp_neg, mul_assoc] + apply mul_le_mul_of_nonneg_left _ (Real.exp_pos _).le + calc Real.exp (-B (p₀+k+1)) * ‖c (h+(k:ℤ)+1)‖ ≤ + w (h+(k:ℤ)+1+1) * (1 / w (h+(k:ℤ)+1)) := + mul_le_mul hwle hcw (norm_nonneg _) (hw _).le + _ = _ := by ring + +lemma nat_support_unbounded {d : ℤ → ℂ} + (hu : ¬∃ m : ℤ, ∀ j : ℤ, d j ≠ 0 → j ≤ m) : + ∀ n : ℕ, ∃ k, n < k ∧ d (k:ℤ) ≠ 0 := by + push Not at hu + intro n + obtain ⟨j, hd, hj⟩ := hu n + refine ⟨j.toNat, by omega, ?_⟩ + have he : (j.toNat:ℤ) = j := by omega + simpa only [he] using hd + + + +lemma bounded_above_of_min {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) + (hdec : Antitone w) (hw0 : w 0 = 1) (hs : Summable (stepRatio w)) + (hQ : DiscreteConvex (positiveLog w)) {δ : ℝ} (hδ : 0 < δ) + (hqq : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ positiveLog w n) + {b c : ℤ → ℂ} (hb : ∀ j, ‖b j‖ ≤ w j) (hc : ∀ j, ‖c j‖*w j ≤ 1) + {h : ℤ} (hch : c h ≠ 0) (hcmin : ∀ j : ℤ, j < h → c j = 0) + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : + ∃ m : ℤ, ∀ j : ℤ, b j ≠ 0 → j ≤ m := by + by_contra hu + have hbu := nat_support_unbounded hu + have hQ0 : positiveLog w 0 = 0 := by simp [positiveLog, hw0] + obtain ⟨hB0, hB, hQB, hbB, hcontactB⟩ := + CoefficientEnvelope.properties hbu hQ hQ0 (bounds_of_weight hw hb hc).b_pos + let B := coefficientEnvelope (fun n => b (n:ℤ)) + have hquad : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ B n := by + filter_upwards [hqq] with n hn using hn.trans (hQB n) + have hBw (n : ℕ) : Real.exp (-B n) ≤ w n := by + have hh := Real.exp_le_exp.mpr (neg_le_neg (hQB n)) + simpa only [positiveLog, neg_neg, Real.exp_log (hw _)] using hh + exact no_unbounded_against_min hB hB0 hδ hquad hbB hcontactB hch hcmin + (boundedSideTail_summable hw hdec hs hBw hc h (p₀ := h.toNat+1) (by omega)) hz + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ConvexEnvelope.lean b/lean/OAI/Analysis/BackwardIntertwiners/ConvexEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..a868ded268873dd48b9f09908f542caa6cc3c7f8 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ConvexEnvelope.lean @@ -0,0 +1,398 @@ +import Mathlib + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + + + +def DiscreteConvex (F : ℕ → ℝ) : Prop := + Monotone (fun n => F (n + 1) - F n) + +namespace DiscreteConvex + +variable {F : ℕ → ℝ} + +lemma of_step (h : ∀ n, F (n+1) - F n ≤ F (n+2) - F (n+1)) : + DiscreteConvex F := by + exact monotone_nat_of_le_succ h + +lemma step (h : DiscreteConvex F) (n : ℕ) : + F (n+1) - F n ≤ F (n+2) - F (n+1) := by + exact h (Nat.le_succ n) + +lemma sub_zero_le (h : DiscreteConvex F) (n : ℕ) : + F n - F 0 ≤ (n : ℝ) * (F (n+1) - F n) := by + induction n with + | zero => simp + | succ n hn => + have hs := h.step n + have hn0 : (0 : ℝ) ≤ n := Nat.cast_nonneg n + push_cast + nlinarith + +lemma secant_le (h : DiscreteConvex F) {n m : ℕ} (hnm : n ≤ m) : + (m : ℝ) * (F n - F 0) ≤ (n : ℝ) * (F m - F 0) := by + induction m, hnm using Nat.le_induction with + | base => rfl + | succ m hnm ih => + have hs := h.sub_zero_le n + have hd := h hnm + have hn0 : (0 : ℝ) ≤ n := Nat.cast_nonneg n + have ht : F n - F 0 ≤ (n : ℝ) * (F (m+1) - F m) := by + calc F n - F 0 ≤ (n : ℝ) * (F (n+1) - F n) := hs + _ ≤ (n : ℝ) * (F (m+1) - F m) := mul_le_mul_of_nonneg_left hd hn0 + push_cast + nlinarith + +lemma le_endpoint (h : DiscreteConvex F) (h0 : F 0 = 0) + {n m : ℕ} (hnm : n ≤ m) (hm : 0 < m) (B : ℝ) (hB : 0 ≤ B) + (hend : F m ≤ B) : F n ≤ B := by + have hs := h.secant_le hnm + rw [h0, sub_zero, sub_zero] at hs + have hn0 : (0 : ℝ) ≤ n := Nat.cast_nonneg n + have hm0 : (0 : ℝ) < m := Nat.cast_pos.mpr hm + have hnm' : (n : ℝ) ≤ m := Nat.cast_le.mpr hnm + have hh : (m : ℝ) * F n ≤ (m : ℝ) * B := calc + (m : ℝ) * F n ≤ (n : ℝ) * F m := hs + _ ≤ (n : ℝ) * B := mul_le_mul_of_nonneg_left hend hn0 + _ ≤ (m : ℝ) * B := mul_le_mul_of_nonneg_right hnm' hB + exact (mul_le_mul_iff_right₀ hm0).mp hh + + +lemma bump (h : DiscreteConvex F) (n : ℕ) {ε : ℝ} (hε : 0 ≤ ε) + (hgap : 2 * ε ≤ F (n+2) - 2 * F (n+1) + F n) : + DiscreteConvex (fun k => F k + if k = n+1 then ε else 0) := by + apply of_step + intro k + by_cases hk : k = n + · subst k + have hne : n ≠ n+1 := by omega + have hne' : n+2 ≠ n+1 := by omega + simp only [ite_eq_right hne, ite_eq_right hne', ite_true, add_zero] + linarith + · have hmid : k+1 ≠ n+1 := by omega + have hlo : F k ≤ F k + if k = n+1 then ε else 0 := by + split_ifs <;> linarith + have hhi : F (k+2) ≤ F (k+2) + if k+2 = n+1 then ε else 0 := by + split_ifs <;> linarith + simp only [ite_eq_right hmid, add_zero] + have hs := h.step k + linarith + +end DiscreteConvex + + + + +def convexMinorants (I : Set ℕ) (f : ℕ → ℝ) : Set (ℕ → ℝ) := + {F | F 0 = 0 ∧ DiscreteConvex F ∧ ∀ n ∈ I, F n ≤ f n} + + +def convexEnvelope (I : Set ℕ) (f : ℕ → ℝ) (n : ℕ) : ℝ := + sSup ((fun F : ℕ → ℝ => F n) '' convexMinorants I f) + +namespace ConvexEnvelope + +variable {I : Set ℕ} {f : ℕ → ℝ} +variable (hunbounded : ∀ n : ℕ, ∃ k, n < k ∧ k ∈ I) +variable (hne : (convexMinorants I f).Nonempty) + +include hunbounded in +lemma bddAbove (n : ℕ) : + BddAbove ((fun F : ℕ → ℝ => F n) '' convexMinorants I f) := by + obtain ⟨k, hnk, hkI⟩ := hunbounded n + refine ⟨max 0 (f k), ?_⟩ + rintro _ ⟨F, hF, rfl⟩ + exact hF.2.1.le_endpoint hF.1 (Nat.le_of_lt hnk) (by omega) + _ (le_max_left _ _) ((hF.2.2 k hkI).trans (le_max_right _ _)) + +include hunbounded in +lemma le_envelope {F : ℕ → ℝ} (hF : F ∈ convexMinorants I f) (n : ℕ) : + F n ≤ convexEnvelope I f n := by + exact le_csSup (bddAbove hunbounded n) ⟨F, hF, rfl⟩ + +include hunbounded hne in +lemma zero : convexEnvelope I f 0 = 0 := by + apply le_antisymm + · apply csSup_le (hne.image _) + rintro _ ⟨F, hF, rfl⟩ + exact le_of_eq hF.1 + · obtain ⟨F, hF⟩ := hne + simpa only [hF.1] using le_envelope hunbounded hF 0 + +include hunbounded hne in +lemma convex : DiscreteConvex (convexEnvelope I f) := by + apply DiscreteConvex.of_step + intro n + have hh : convexEnvelope I f (n+1) ≤ + (convexEnvelope I f n + convexEnvelope I f (n+2)) / 2 := by + apply csSup_le (hne.image _) + rintro _ ⟨F, hF, rfl⟩ + have hc := hF.2.1.step n + have hl := le_envelope hunbounded hF n + have hr := le_envelope hunbounded hF (n+2) + linarith + linarith + +include hne in +lemma below {n : ℕ} (hn : n ∈ I) : convexEnvelope I f n ≤ f n := by + apply csSup_le (hne.image _) + rintro _ ⟨F, hF, rfl⟩ + exact hF.2.2 n hn + +include hunbounded hne in +lemma mem : convexEnvelope I f ∈ convexMinorants I f := + ⟨zero hunbounded hne, convex hunbounded hne, fun _ hn => below hne hn⟩ + +include hunbounded hne in + +lemma contact (n : ℕ) + (hgap : 0 < convexEnvelope I f (n+2) - 2 * convexEnvelope I f (n+1) + + convexEnvelope I f n) : + n+1 ∈ I ∧ convexEnvelope I f (n+1) = f (n+1) := by + let F := convexEnvelope I f + let δ := F (n+2) - 2 * F (n+1) + F n + have hδ : 0 < δ := hgap + have hF : F ∈ convexMinorants I f := mem hunbounded hne + have maximal : ∀ ε : ℝ, 0 < ε → 2*ε ≤ δ → + (n+1 ∈ I → F (n+1)+ε ≤ f (n+1)) → False := by + intro ε hε hεgap hεobs + let G := fun k => F k + if k = n+1 then ε else 0 + have hG : G ∈ convexMinorants I f := by + refine ⟨?_, hF.2.1.bump n hε.le hεgap, ?_⟩ + · simp [G, hF.1] + · intro k hk + by_cases he : k = n+1 + · subst k + simpa [G] using hεobs hk + · simpa [G, he] using hF.2.2 k hk + have hle := le_envelope hunbounded hG (n+1) + simp only [G, ite_true] at hle + change F (n+1) + ε ≤ F (n+1) at hle + linarith + have hi : n+1 ∈ I := by + by_contra hn + exact maximal (δ/4) (by positivity) (by linarith) (by simp [hn]) + refine ⟨hi, ?_⟩ + have hle := hF.2.2 (n+1) hi + by_contra hneq + have hlt : F (n+1) < f (n+1) := lt_of_le_of_ne hle hneq + let ε := min (δ/4) ((f (n+1) - F (n+1))/2) + have hε : 0 < ε := lt_min (by positivity) (by linarith) + have hε₁ : ε ≤ δ/4 := min_le_left _ _ + have hε₂ : ε ≤ (f (n+1) - F (n+1))/2 := min_le_right _ _ + exact maximal ε hε (by linarith) (by intro _; linarith) + +end ConvexEnvelope + +namespace DiscreteConvex + +variable {F : ℕ → ℝ} + + +lemma slopes_tendsto (h : DiscreteConvex F) (h0 : F 0 = 0) + {δ : ℝ} (hδ : 0 < δ) + (hq : ∀ᶠ n : ℕ in atTop, δ * (n : ℝ)^2 ≤ F n) : + Tendsto (fun n => F (n+1) - F n) atTop atTop := by + apply tendsto_atTop.2 + intro b + have hn : ∀ᶠ n : ℕ in atTop, b / δ ≤ (n : ℝ) := + (tendsto_natCast_atTop_atTop : Tendsto (fun n : ℕ => (n : ℝ)) atTop atTop) + (eventually_ge_atTop _) + filter_upwards [hq, hn, eventually_ge_atTop 1] with n hqn hbn hn1 + have hnpos : (0 : ℝ) < n := Nat.cast_pos.mpr (by omega) + have hs := h.sub_zero_le n + rw [h0, sub_zero] at hs + have hb : b ≤ δ * n := (div_le_iff₀ hδ).mp hbn |>.trans_eq (mul_comm _ _) + have hd : δ * n ≤ F (n+1) - F n := by nlinarith + exact hb.trans hd + +end DiscreteConvex + + + +lemma quadratic_upper_of_curvature {F : ℕ → ℝ} {lam : ℝ} (N : ℕ) + (h : ∀ n, N ≤ n → F (n+2) - 2*F (n+1) + F n ≤ 2*lam) (k : ℕ) : + F (N+k) ≤ F N + (k : ℝ) * (F (N+1) - F N) + lam * k * (k-1) := by + have hs (k : ℕ) : F (N+k+1) - F (N+k) ≤ + F (N+1) - F N + 2*lam*k := by + induction k with + | zero => simp + | succ k ih => + have hh := h (N+k) (Nat.le_add_right _ _) + have e₁ : N + (k+1) + 1 = N+k+2 := by omega + have e₂ : N + (k+1) = N+k+1 := by omega + rw [e₁, e₂] + push_cast + linarith + induction k with + | zero => simp + | succ k ih => + have hh := hs k + have e : N + (k+1) = N+k+1 := by omega + rw [e] + push_cast + nlinarith + + + + +lemma large_curvature {F : ℕ → ℝ} {lam μ : ℝ} (hμ : 0 < μ) (hlamμ : lam < μ) + (hq : ∀ᶠ n : ℕ in atTop, μ * (n : ℝ)^2 ≤ F n) : + ∀ N : ℕ, ∃ n, N ≤ n ∧ 2*lam < F (n+2) - 2*F (n+1) + F n := by + intro N + by_contra! h + obtain ⟨Q, hQ⟩ := eventually_atTop.1 hq + let C := |F (N+1) - F N - lam| + |F N| + obtain ⟨k, hk⟩ := exists_nat_gt (max (max (Q : ℝ) 1) (C / (μ-lam))) + have hkQ : (Q : ℝ) < k := lt_of_le_of_lt (le_trans (le_max_left _ _) (le_max_left _ _)) hk + have hk1 : (1 : ℝ) < k := lt_of_le_of_lt (le_trans (le_max_right _ _) (le_max_left _ _)) hk + have hkC : C / (μ-lam) < k := lt_of_le_of_lt (le_max_right _ _) hk + have hk0 : (0 : ℝ) < k := lt_trans zero_lt_one hk1 + have hQN : Q ≤ N+k := by exact Nat.le_trans (Nat.le_of_lt (Nat.cast_lt.mp hkQ)) (Nat.le_add_left _ _) + have hlo := hQ (N+k) hQN + have hhi := quadratic_upper_of_curvature N h k + have hNC : (0 : ℝ) ≤ N := Nat.cast_nonneg _ + have hlow : μ * (k : ℝ)^2 ≤ F (N+k) := by + push_cast at hlo + calc μ * (k : ℝ)^2 ≤ μ * ((N : ℝ) + k)^2 := by gcongr; linarith + _ ≤ F (N+k) := hlo + have hF0 : F N ≤ |F N| * k := calc + F N ≤ |F N| := le_abs_self _ + _ ≤ |F N| * k := le_mul_of_one_le_right (abs_nonneg _) hk1.le + have hF1 : (F (N+1) - F N - lam) * k ≤ |F (N+1) - F N - lam| * k := + mul_le_mul_of_nonneg_right (le_abs_self _) hk0.le + have hup : F (N+k) ≤ lam * (k : ℝ)^2 + C*k := by + dsimp [C] + nlinarith [hhi] + have hlarge : C < (k : ℝ) * (μ-lam) := (div_lt_iff₀ (sub_pos.mpr hlamμ)).mp hkC + have hstrict := mul_lt_mul_of_pos_right hlarge hk0 + nlinarith + +namespace DiscreteConvex + +variable {F : ℕ → ℝ} + +lemma increment_mono (h : DiscreteConvex F) {i j : ℕ} (hij : i ≤ j) (k : ℕ) : + F (i+k) - F i ≤ F (j+k) - F j := by + induction k with + | zero => simp + | succ k ih => + have hh := h (Nat.add_le_add_right hij k) + have e₁ : i + (k+1) = i+k+1 := by omega + have e₂ : j + (k+1) = j+k+1 := by omega + rw [e₁, e₂] + linarith + +lemma increment_lower (h : DiscreteConvex F) (q k : ℕ) : + (k : ℝ) * (F (q+1) - F q) ≤ F (q+k) - F q := by + induction k with + | zero => simp + | succ k ih => + have hh := h (Nat.le_add_right q k) + have e : q + (k+1) = q+k+1 := by omega + rw [e] + push_cast + nlinarith + +lemma increment_upper (h : DiscreteConvex F) (q k r : ℕ) (hkr : q+k ≤ r+1) : + F (q+k) - F q ≤ (k : ℝ) * (F (r+1) - F r) := by + induction k with + | zero => simp + | succ k ih => + have hh := h (show q+k ≤ r by omega) + have ih' := ih (by omega) + have e : q + (k+1) = q+k+1 := by omega + rw [e] + push_cast + nlinarith + +lemma summable_exp_neg_slope (h : DiscreteConvex F) (h0 : F 0 = 0) + {δ : ℝ} (hδ : 0 < δ) + (hq : ∀ᶠ n : ℕ in atTop, δ * (n : ℝ)^2 ≤ F n) : + Summable (fun n => Real.exp (-(F (n+1) - F n))) := by + have hgeo : Summable (fun n : ℕ => Real.exp (-δ) ^ n) := + summable_geometric_of_lt_one (Real.exp_pos _).le (by simpa using hδ) + apply hgeo.of_norm_bounded_eventually_nat + filter_upwards [hq, eventually_ge_atTop 1] with n hqn hn1 + have hnpos : (0 : ℝ) < n := Nat.cast_pos.mpr (by omega) + have hs := h.sub_zero_le n + rw [h0, sub_zero] at hs + have hd : δ * n ≤ F (n+1) - F n := by nlinarith + rw [Real.norm_eq_abs, abs_of_pos (Real.exp_pos _), ← Real.exp_nat_mul] + exact Real.exp_le_exp.mpr (by nlinarith) + +end DiscreteConvex + + +def normalizedTailTerm (F : ℕ → ℝ) (q k : ℕ) : ℝ := + Real.exp (F (k+1) + F q - F (q+k+1)) + +namespace DiscreteConvex + +variable {F : ℕ → ℝ} + +lemma tail_term_bound (h : DiscreteConvex F) {q : ℕ} (hq : 1 ≤ q) (k : ℕ) : + normalizedTailTerm F q k ≤ + Real.exp (F 1) * Real.exp (-(F (k+2) - F (k+1))) := by + have hi := h.increment_mono hq (k+1) + have e₁ : 1+(k+1) = k+2 := by omega + have e₂ : q+(k+1) = q+k+1 := by omega + rw [e₁, e₂] at hi + rw [normalizedTailTerm, ← Real.exp_add] + exact Real.exp_le_exp.mpr (by linarith) + +lemma tail_term_tendsto (h : DiscreteConvex F) + (hs : Tendsto (fun n => F (n+1) - F n) atTop atTop) (k : ℕ) : + Tendsto (fun q => normalizedTailTerm F q k) atTop (𝓝 0) := by + apply Real.tendsto_exp_atBot.comp + apply tendsto_atBot.2 + intro b + have hsl := hs (eventually_ge_atTop (max 0 (F (k+1) - b))) + filter_upwards [hsl] with q hq + have hs0 : 0 ≤ F (q+1) - F q := (le_max_left _ _).trans hq + have hsb : F (k+1) - b ≤ F (q+1) - F q := (le_max_right _ _).trans hq + have hi := h.increment_lower q (k+1) + have e : q+(k+1) = q+k+1 := by omega + rw [e] at hi + have hk0 : (0 : ℝ) ≤ k := Nat.cast_nonneg k + push_cast at hi + change F (k+1) + F q - F (q+k+1) ≤ b + nlinarith + +lemma tail_summable (h : DiscreteConvex F) + (hsum : Summable (fun n => Real.exp (-(F (n+1) - F n)))) + {q : ℕ} (hq : 1 ≤ q) : Summable (normalizedTailTerm F q) := by + have hmajor := ((summable_nat_add_iff 1).mpr hsum).mul_left (Real.exp (F 1)) + apply hmajor.of_norm_bounded + intro k + rw [Real.norm_eq_abs, abs_of_pos (show 0 < normalizedTailTerm F q k from Real.exp_pos _)] + simpa only [Nat.add_assoc] using h.tail_term_bound hq k + + + +lemma tail_tsum_tendsto (h : DiscreteConvex F) + (hsum : Summable (fun n => Real.exp (-(F (n+1) - F n)))) + (hs : Tendsto (fun n => F (n+1) - F n) atTop atTop) : + Tendsto (fun q => ∑' k, normalizedTailTerm F q k) atTop (𝓝 0) := by + have hmajor := ((summable_nat_add_iff 1).mpr hsum).mul_left (Real.exp (F 1)) + have hh := tendsto_tsum_of_dominated_convergence hmajor + (fun k => h.tail_term_tendsto hs k) (show ∀ᶠ q : ℕ in atTop, ∀ k, + ‖normalizedTailTerm F q k‖ ≤ + Real.exp (F 1) * Real.exp (-(F (k+1+1) - F (k+1))) from ?_) + · simpa using hh + · filter_upwards [eventually_ge_atTop 1] with q hq k + rw [Real.norm_eq_abs, abs_of_pos (show 0 < normalizedTailTerm F q k from Real.exp_pos _)] + simpa only [Nat.add_assoc] using h.tail_term_bound hq k + +end DiscreteConvex + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ConvolutionBounds.lean b/lean/OAI/Analysis/BackwardIntertwiners/ConvolutionBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..51e742a6a0219bcd2648a0685e46a1be5cfa88cb --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ConvolutionBounds.lean @@ -0,0 +1,320 @@ +import OAI.Analysis.BackwardIntertwiners.ConvexEnvelope + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + + +structure EnvelopeBounds (A B : ℕ → ℝ) (b c : ℤ → ℂ) : Prop where + b_pos : ∀ n : ℕ, ‖b n‖ ≤ Real.exp (-B n) + b_neg : ∀ n : ℕ, ‖b (-(n : ℤ))‖ ≤ Real.exp (A n) + c_pos : ∀ n : ℕ, ‖c n‖ ≤ Real.exp (B n) + c_neg : ∀ n : ℕ, ‖c (-(n : ℤ))‖ ≤ Real.exp (-A n) + +lemma middle_exponent {A B : ℕ → ℝ} (hA : DiscreteConvex A) (hB : DiscreteConvex B) + {m : ℕ} (hm : 1 ≤ m) (p k : ℕ) (hk : k ≤ m) {lam : ℝ} + (hbridge : A m - A (m-1) + lam ≤ B (p+1) - B p) : + -B (p+k) - A (m-k) ≤ -B p - A m - lam * k := by + have hlow := hB.increment_lower p k + have hupp := hA.increment_upper (m-k) k (m-1) (by omega) + rw [Nat.sub_add_cancel hk, Nat.sub_add_cancel hm] at hupp + have hmul := mul_le_mul_of_nonneg_left hbridge (Nat.cast_nonneg k : (0 : ℝ) ≤ k) + nlinarith + + +def centeredCorrelation (b c : ℤ → ℂ) (m p : ℕ) (n : ℤ) : ℂ := + b ((p : ℤ)+n) * c (-(m : ℤ)+n) + +namespace EnvelopeBounds + +variable {A B : ℕ → ℝ} {b c : ℤ → ℂ} + +lemma reflected (hb : EnvelopeBounds A B b c) : + EnvelopeBounds B A (fun n => c (-n)) (fun n => b (-n)) where + b_pos := hb.c_neg + b_neg := by simpa only [neg_neg] using hb.c_pos + c_pos := hb.b_neg + c_neg := by simpa only [neg_neg] using hb.b_pos + +lemma central_norm (_ : EnvelopeBounds A B b c) {m p : ℕ} + (hp : ‖b (p : ℤ)‖ = Real.exp (-B p)) + (hm : ‖c (-(m : ℤ))‖ = Real.exp (-A m)) : + ‖centeredCorrelation b c m p 0‖ = Real.exp (-B p - A m) := by + simp only [centeredCorrelation, add_zero, norm_mul, hp, hm] + rw [← Real.exp_add] + congr 1 + +lemma middle_pos (hb : EnvelopeBounds A B b c) + (hA : DiscreteConvex A) (hB : DiscreteConvex B) + {m : ℕ} (hm : 1 ≤ m) (p k : ℕ) (hk : k ≤ m) {lam : ℝ} + (hbridge : A m - A (m-1) + lam ≤ B (p+1) - B p) : + ‖centeredCorrelation b c m p k‖ ≤ + Real.exp (-B p - A m) * Real.exp (-lam * k) := by + have he : -(m : ℤ) + k = -((m-k : ℕ) : ℤ) := by omega + rw [centeredCorrelation, he, ← Nat.cast_add, norm_mul] + calc ‖b ((p+k : ℕ) : ℤ)‖ * ‖c (-((m-k : ℕ) : ℤ))‖ ≤ + Real.exp (-B (p+k)) * Real.exp (-A (m-k)) := + mul_le_mul (hb.b_pos _) (hb.c_neg _) (norm_nonneg _) (Real.exp_pos _).le + _ ≤ Real.exp (-B p - A m) * Real.exp (-lam * k) := by + rw [← Real.exp_add, ← Real.exp_add] + apply Real.exp_le_exp.mpr + simpa only [sub_eq_add_neg, neg_mul] using middle_exponent hA hB hm p k hk hbridge + +lemma middle_neg (hb : EnvelopeBounds A B b c) + (hA : DiscreteConvex A) (hB : DiscreteConvex B) + {p : ℕ} (hp : 1 ≤ p) (m k : ℕ) (hk : k ≤ p) {lam : ℝ} + (hbridge : B p - B (p-1) + lam ≤ A (m+1) - A m) : + ‖centeredCorrelation b c m p (-(k : ℤ))‖ ≤ + Real.exp (-B p - A m) * Real.exp (-lam * k) := by + have hh := hb.reflected.middle_pos hB hA hp m k hk hbridge + simpa only [centeredCorrelation, neg_add, neg_neg, mul_comm, neg_add_rev, + sub_eq_add_neg, add_comm] using hh + +lemma tail_pos (hb : EnvelopeBounds A B b c) (m p k : ℕ) + (hend : B p + A m ≤ B (m+p)) : + ‖centeredCorrelation b c m p ((m+k+1 : ℕ) : ℤ)‖ ≤ + Real.exp (-B p - A m) * normalizedTailTerm B (m+p) k := by + have e₁ : (p : ℤ) + ((m+k+1 : ℕ) : ℤ) = ((m+p+k+1 : ℕ) : ℤ) := by omega + have e₂ : -(m : ℤ) + ((m+k+1 : ℕ) : ℤ) = ((k+1 : ℕ) : ℤ) := by omega + rw [centeredCorrelation, e₁, e₂, norm_mul] + calc ‖b ((m+p+k+1 : ℕ) : ℤ)‖ * ‖c ((k+1 : ℕ) : ℤ)‖ ≤ + Real.exp (-B (m+p+k+1)) * Real.exp (B (k+1)) := + mul_le_mul (hb.b_pos _) (hb.c_pos _) (norm_nonneg _) (Real.exp_pos _).le + _ ≤ _ := by + rw [normalizedTailTerm, ← Real.exp_add, ← Real.exp_add] + exact Real.exp_le_exp.mpr (by linarith) + +lemma tail_neg (hb : EnvelopeBounds A B b c) (m p k : ℕ) + (hend : B p + A m ≤ A (m+p)) : + ‖centeredCorrelation b c m p (-((p+k+1 : ℕ) : ℤ))‖ ≤ + Real.exp (-B p - A m) * normalizedTailTerm A (m+p) k := by + have hh := hb.reflected.tail_pos p m k (by simpa [add_comm] using hend) + simpa only [centeredCorrelation, neg_add, neg_neg, mul_comm, neg_add_rev, + sub_eq_add_neg, add_comm, Nat.add_comm] using hh + +end EnvelopeBounds + + + +lemma tsum_bound_middle_tail {g t u : ℕ → ℝ} {M : ℝ} (hM : 0 ≤ M) (m : ℕ) + (hg : ∀ k, 0 ≤ g k) (ht : ∀ k, 0 ≤ t k) + (hst : Summable t) (hsu : Summable u) + (hmiddle : ∀ k, k < m → g k ≤ M * t k) + (htail : ∀ k, g (k+m) ≤ M * u k) : + Summable g ∧ (∑' k, g k) ≤ M * (∑' k, t k) + M * (∑' k, u k) := by + have htailSum : Summable (fun k => g (k+m)) := by + apply (hsu.mul_left M).of_norm_bounded + intro k + rw [Real.norm_eq_abs, abs_of_nonneg (hg _)] + exact htail k + have hsum : Summable g := (summable_nat_add_iff m).mp htailSum + refine ⟨hsum, ?_⟩ + rw [← hsum.sum_add_tsum_nat_add m] + apply add_le_add + · calc ∑ k ∈ Finset.range m, g k ≤ ∑ k ∈ Finset.range m, M * t k := + Finset.sum_le_sum (fun k hk => hmiddle k (Finset.mem_range.mp hk)) + _ ≤ ∑' k, M * t k := (hst.mul_left M).sum_le_tsum _ (fun k _ => mul_nonneg hM (ht k)) + _ = M * ∑' k, t k := tsum_mul_left + · calc ∑' k, g (k+m) ≤ ∑' k, M * u k := htailSum.tsum_le_tsum htail (hsu.mul_left M) + _ = M * ∑' k, u k := tsum_mul_left + +lemma central_norm_le_of_correlation_zero (f : ℤ → ℂ) + (hp : Summable (fun n : ℕ => ‖f (n+1)‖)) + (hn : Summable (fun n : ℕ => ‖f (-(n+1))‖)) + (hz : (∑' n : ℤ, f n) = 0) : + ‖f 0‖ ≤ (∑' n : ℕ, ‖f (n+1)‖) + ∑' n : ℕ, ‖f (-(n+1))‖ := by + rw [tsum_of_add_one_of_neg_add_one hp.of_norm hn.of_norm] at hz + have he : f 0 = -((∑' n : ℕ, f (n+1)) + ∑' n : ℕ, f (-(n+1))) := by + linear_combination hz + rw [he, norm_neg] + exact (norm_add_le _ _).trans (add_le_add (norm_tsum_le_tsum_norm hp) (norm_tsum_le_tsum_norm hn)) + + +def geometricMiddle (lam : ℝ) (k : ℕ) : ℝ := Real.exp (-lam * ((k : ℝ)+1)) + +lemma geometricMiddle_hasSum {lam : ℝ} (hlam : 0 < lam) : + HasSum (geometricMiddle lam) (Real.exp (-lam) / (1-Real.exp (-lam))) := by + have hr : Real.exp (-lam) < 1 := by simpa using hlam + have hh := (hasSum_geometric_of_lt_one (Real.exp_pos (-lam)).le hr).mul_left (Real.exp (-lam)) + have heq : geometricMiddle lam = (fun k : ℕ => Real.exp (-lam) * Real.exp (-lam)^k) := by + funext k + rw [geometricMiddle, ← Real.exp_nat_mul, ← Real.exp_add] + congr 1 + ring + rw [heq, div_eq_mul_inv] + exact hh + +lemma geometricMiddle_budget {lam : ℝ} (hlam : Real.log 3 < lam) : + 2 * (∑' k, geometricMiddle lam k) < 1 := by + have hl0 : 0 < lam := (Real.log_pos (by norm_num : (1 : ℝ) < 3)).trans hlam + rw [(geometricMiddle_hasSum hl0).tsum_eq] + have he : (3 : ℝ) < Real.exp lam := by + have h := Real.exp_lt_exp.mpr hlam + rw [Real.exp_log (by norm_num : (0 : ℝ) < 3)] at h + exact h + have hrpos : 0 < Real.exp (-lam) := Real.exp_pos _ + have hrlt : Real.exp (-lam) < 1 := by simpa using hl0 + have hprod : Real.exp lam * Real.exp (-lam) = 1 := by + rw [← Real.exp_add]; simp + have hsmall := mul_lt_mul_of_pos_right he hrpos + rw [hprod] at hsmall + have hden : 0 < 1 - Real.exp (-lam) := sub_pos.mpr hrlt + calc 2 * (Real.exp (-lam) / (1-Real.exp (-lam))) = + (2 * Real.exp (-lam)) / (1-Real.exp (-lam)) := by ring + _ < 1 := (div_lt_one hden).mpr (by linarith) + +namespace EnvelopeBounds + +variable {A B : ℕ → ℝ} {b c : ℤ → ℂ} + + + +lemma correlation_budget (hb : EnvelopeBounds A B b c) + (hA : DiscreteConvex A) (hB : DiscreteConvex B) + (hA0 : A 0 = 0) (hB0 : B 0 = 0) + (hsA : Summable (fun n => Real.exp (-(A (n+1) - A n)))) + (hsB : Summable (fun n => Real.exp (-(B (n+1) - B n)))) + {m p : ℕ} (hm : 1 ≤ m) (hp : 1 ≤ p) {lam : ℝ} (hlam : 0 < lam) + (hbridge₁ : A m - A (m-1) + lam ≤ B (p+1) - B p) + (hbridge₂ : B p - B (p-1) + lam ≤ A (m+1) - A m) + (hcB : ‖b (p : ℤ)‖ = Real.exp (-B p)) + (hcA : ‖c (-(m : ℤ))‖ = Real.exp (-A m)) + (hz : (∑' n : ℤ, centeredCorrelation b c m p n) = 0) : + 1 ≤ 2 * (∑' k, geometricMiddle lam k) + + (∑' k, normalizedTailTerm A (m+p) k) + + (∑' k, normalizedTailTerm B (m+p) k) := by + let M := Real.exp (-B p - A m) + have hM : 0 < M := Real.exp_pos _ + have hq : 1 ≤ m+p := by omega + have hendB : B p + A m ≤ B (m+p) := by + have hh := middle_exponent hA hB hm p m le_rfl hbridge₁ + simp only [Nat.sub_self, hA0, sub_zero] at hh + rw [Nat.add_comm p m] at hh + have hmul := mul_nonneg hlam.le (Nat.cast_nonneg m : (0 : ℝ) ≤ m) + linarith + have hendA : B p + A m ≤ A (m+p) := by + have hh := middle_exponent hB hA hp m p le_rfl hbridge₂ + simp only [Nat.sub_self, hB0, sub_zero] at hh + have hmul := mul_nonneg hlam.le (Nat.cast_nonneg p : (0 : ℝ) ≤ p) + linarith + have hpos := tsum_bound_middle_tail hM.le m + (g := fun k : ℕ => ‖centeredCorrelation b c m p ((k : ℤ)+1)‖) + (t := geometricMiddle lam) (u := normalizedTailTerm B (m+p)) + (fun _ => norm_nonneg _) (fun _ => (Real.exp_pos _).le) + (geometricMiddle_hasSum hlam).summable (hB.tail_summable hsB hq) ?_ ?_ + · have hneg := tsum_bound_middle_tail hM.le p + (g := fun k : ℕ => ‖centeredCorrelation b c m p (-((k : ℤ)+1))‖) + (t := geometricMiddle lam) (u := normalizedTailTerm A (m+p)) + (fun _ => norm_nonneg _) (fun _ => (Real.exp_pos _).le) + (geometricMiddle_hasSum hlam).summable (hA.tail_summable hsA hq) ?_ ?_ + · have hh := central_norm_le_of_correlation_zero _ hpos.1 hneg.1 hz + rw [hb.central_norm hcB hcA] at hh + change M ≤ _ at hh + have hmul : M * 1 ≤ M * (2 * (∑' k, geometricMiddle lam k) + + (∑' k, normalizedTailTerm A (m+p) k) + + (∑' k, normalizedTailTerm B (m+p) k)) := by + nlinarith [hpos.2, hneg.2] + exact (mul_le_mul_iff_right₀ hM).mp hmul + · intro k hk + simpa [geometricMiddle, M] using + hb.middle_neg hA hB hp m (k+1) (by omega) hbridge₂ + · intro k + simpa only [Nat.cast_add, Nat.cast_one, add_assoc, add_comm, add_left_comm, M] + using hb.tail_neg m p k hendA + · intro k hk + simpa [geometricMiddle, M] using + hb.middle_pos hA hB hm p (k+1) (by omega) hbridge₁ + · intro k + simpa only [Nat.cast_add, Nat.cast_one, add_assoc, add_comm, add_left_comm, M] + using hb.tail_pos m p k hendB + +end EnvelopeBounds + + + +theorem no_correlation_of_envelopes {A B : ℕ → ℝ} {b c : ℤ → ℂ} + (hb : EnvelopeBounds A B b c) + (hA : DiscreteConvex A) (hB : DiscreteConvex B) + (hA0 : A 0 = 0) (hB0 : B 0 = 0) + {lam δ : ℝ} (hlam : Real.log 3 < lam) (hδ : lam < δ) + (hqa : ∀ᶠ n : ℕ in atTop, δ * (n : ℝ)^2 ≤ A n) + (hqb : ∀ᶠ n : ℕ in atTop, δ * (n : ℝ)^2 ≤ B n) + (hcA : ∀ n, 0 < A (n+2) - 2*A (n+1) + A n → + ‖c (-((n+1 : ℕ) : ℤ))‖ = Real.exp (-A (n+1))) + (hcB : ∀ n, 0 < B (n+2) - 2*B (n+1) + B n → + ‖b ((n+1 : ℕ) : ℤ)‖ = Real.exp (-B (n+1))) + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : False := by + have hl0 : 0 < lam := (Real.log_pos (by norm_num : (1 : ℝ) < 3)).trans hlam + have hδ0 : 0 < δ := hl0.trans hδ + have hsA := hA.summable_exp_neg_slope hA0 hδ0 hqa + have hsB := hB.summable_exp_neg_slope hB0 hδ0 hqb + have htA := hA.slopes_tendsto hA0 hδ0 hqa + have htB := hB.slopes_tendsto hB0 hδ0 hqb + have ht : Tendsto (fun q => 2 * (∑' k, geometricMiddle lam k) + + (∑' k, normalizedTailTerm A q k) + (∑' k, normalizedTailTerm B q k)) + atTop (𝓝 (2 * ∑' k, geometricMiddle lam k)) := by + simpa using (tendsto_const_nhds.add (hA.tail_tsum_tendsto hsA htA)).add + (hB.tail_tsum_tendsto hsB htB) + obtain ⟨N, hN⟩ := eventually_atTop.1 (ht (eventually_lt_nhds (geometricMiddle_budget hlam))) + obtain ⟨K, hK⟩ := eventually_atTop.1 (htA (eventually_ge_atTop (B 1 - B 0 - lam))) + obtain ⟨n, hn, hcurv⟩ := large_curvature hδ0 hδ hqa (max N K) + let m := n+1 + have hm : 1 ≤ m := by dsimp [m]; omega + have hthreshold : B 1 - B 0 ≤ A m - A (m-1) + lam := by + have hh := hK n (le_trans (le_max_right _ _) hn) + change B 1 - B 0 - lam ≤ A (n+1) - A n at hh + dsimp [m] + simpa only [Nat.add_sub_cancel] using (show B 1 - B 0 ≤ A (n+1) - A n + lam by linarith) + let C := A m - A (m-1) + lam + have hex : ∃ p : ℕ, C < B (p+1) - B p := by + have he : ∀ᶠ p : ℕ in atTop, C < B (p+1) - B p := htB (eventually_gt_atTop C) + exact he.exists + let p := Nat.find hex + have hright : C < B (p+1) - B p := Nat.find_spec hex + have hp : 1 ≤ p := by + by_contra! hh + have hp0 : p = 0 := by omega + rw [hp0] at hright + simp only [zero_add] at hright + exact (not_lt_of_ge hthreshold) hright + have hleft : B p - B (p-1) ≤ C := by + have hh := Nat.find_min hex (show p-1 < p by omega) + simpa only [Nat.sub_add_cancel hp, not_lt] using hh + have hcontact : 0 < B ((p-1)+2) - 2*B ((p-1)+1) + B (p-1) := by + have e₁ : p-1+1 = p := by omega + have e₂ : p-1+2 = p+1 := by omega + rw [e₁, e₂] + linarith + have hcB' : ‖b (p : ℤ)‖ = Real.exp (-B p) := by + simpa only [Nat.sub_add_cancel hp] using hcB (p-1) hcontact + have hcA' : ‖c (-(m : ℤ))‖ = Real.exp (-A m) := hcA n (by linarith) + have hbridge₂ : B p - B (p-1) + lam ≤ A (m+1) - A m := by + dsimp [C, m] at hleft ⊢ + have e : n+1+1 = n+2 := by omega + rw [e] + linarith + have hzcenter : (∑' i : ℤ, centeredCorrelation b c m p i) = 0 := by + calc (∑' i : ℤ, centeredCorrelation b c m p i) = + ∑' i : ℤ, b ((p : ℤ)+i) * c (((p : ℤ)+i) - ((m+p : ℕ) : ℤ)) := by + apply tsum_congr + intro i + unfold centeredCorrelation + congr 2 + omega + _ = ∑' j : ℤ, b j * c (j-((m+p : ℕ) : ℤ)) := by + simpa only [Equiv.coe_addLeft, add_comm] using + (Equiv.addLeft (p : ℤ)).tsum_eq (fun j : ℤ => b j * c (j-((m+p : ℕ) : ℤ))) + _ = 0 := hz (m+p) (by omega) + have hbudget := hb.correlation_budget hA hB hA0 hB0 hsA hsB hm hp hl0 hright.le + hbridge₂ hcB' hcA' hzcenter + have hqN : N ≤ m+p := by dsimp [m]; have := le_trans (le_max_left N K) hn; omega + exact (not_lt_of_ge hbudget) (hN (m+p) hqN) + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/DiagonalSymbols.lean b/lean/OAI/Analysis/BackwardIntertwiners/DiagonalSymbols.lean new file mode 100644 index 0000000000000000000000000000000000000000..b97ca14ff25745803734faacf284ab6bfb16b62b --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/DiagonalSymbols.lean @@ -0,0 +1,176 @@ +import OAI.Analysis.BackwardIntertwiners.OrdinaryStructure + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + + +open scoped Classical + +def diagonalSymbols : StarSubalgebra ℂ (Base → ℤ → ℂ) where + carrier := {a | (∀ j, Measurable (fun x => a x j)) ∧ + ∃ C : ℝ, 0 ≤ C ∧ ∀ x j, ‖a x j‖ ≤ C} + zero_mem' := ⟨fun _ => measurable_const, 0, le_rfl, by simp⟩ + one_mem' := ⟨fun _ => measurable_const, 1, zero_le_one, by simp⟩ + add_mem' := by + rintro a b ⟨ha,C,hC,hCa⟩ ⟨hb,D,hD,hDb⟩ + exact ⟨fun j => (ha j).add (hb j), C+D, add_nonneg hC hD, + fun x j => (norm_add_le _ _).trans (add_le_add (hCa x j) (hDb x j))⟩ + mul_mem' := by + rintro a b ⟨ha,C,hC,hCa⟩ ⟨hb,D,hD,hDb⟩ + refine ⟨fun j => (ha j).mul (hb j), C*D, mul_nonneg hC hD, fun x j => ?_⟩ + change ‖a x j * b x j‖ ≤ C*D + rw [norm_mul] + exact mul_le_mul (hCa x j) (hDb x j) (norm_nonneg _) hC + algebraMap_mem' c := ⟨fun _ => measurable_const, ‖c‖, norm_nonneg c, fun _ _ => le_rfl⟩ + star_mem' := by + rintro a ⟨ha,C,hC,hCa⟩ + refine ⟨fun j => continuous_star.measurable.comp (ha j), C,hC, fun x j => ?_⟩ + simpa using hCa x j +abbrev DiagonalSymbol := ↥diagonalSymbols +namespace DiagonalSymbol +instance : CoeFun DiagonalSymbol (fun _ => Base → ℤ → ℂ) := ⟨fun a => a.val⟩ +lemma measurable (a : DiagonalSymbol) (j : ℤ) : Measurable (fun x => a x j) := a.property.1 j +noncomputable def bound (a : DiagonalSymbol) : ℝ := a.property.2.choose +lemma bound_nonneg (a : DiagonalSymbol) : 0 ≤ a.bound := a.property.2.choose_spec.1 +lemma norm_le_bound (a : DiagonalSymbol) (x : Base) (j : ℤ) : ‖a x j‖ ≤ a.bound := + a.property.2.choose_spec.2 x j +@[simp] lemma zero_apply (x : Base) (j : ℤ) : (0 : DiagonalSymbol) x j = 0 := rfl +@[simp] lemma one_apply (x : Base) (j : ℤ) : (1 : DiagonalSymbol) x j = 1 := rfl +@[simp] lemma add_apply (a b : DiagonalSymbol) (x : Base) (j : ℤ) : (a+b) x j = a x j + b x j := rfl +@[simp] lemma mul_apply (a b : DiagonalSymbol) (x : Base) (j : ℤ) : (a*b) x j = a x j * b x j := rfl +@[simp] lemma sub_apply (a b : DiagonalSymbol) (x : Base) (j : ℤ) : (a-b) x j = a x j - b x j := rfl +@[simp] lemma star_apply (a : DiagonalSymbol) (x : Base) (j : ℤ) : (star a) x j = star (a x j) := rfl +@[simp] lemma smul_apply (c : ℂ) (a : DiagonalSymbol) (x : Base) (j : ℤ) : (c • a) x j = c * a x j := rfl +@[simp] lemma algebraMap_apply (c : ℂ) (x : Base) (j : ℤ) : + algebraMap ℂ DiagonalSymbol c x j = c := rfl +@[simp] lemma pow_apply (a : DiagonalSymbol) (n : ℕ) (x : Base) (j : ℤ) : + (a^n) x j = (a x j)^n := by induction n <;> simp_all [pow_succ] +end DiagonalSymbol + +def diagonalFiber (a : DiagonalSymbol) (x : Base) : Fiber →L[ℂ] Fiber := + fiberMultiplier (a x) a.bound a.bound_nonneg (a.norm_le_bound x) +@[simp] lemma diagonalFiber_apply (a : DiagonalSymbol) (x : Base) (v : Fiber) (j : ℤ) : + diagonalFiber a x v j = a x j*v j := rfl +lemma diagonalFiber_norm (a : DiagonalSymbol) (x : Base) : ‖diagonalFiber a x‖ ≤ a.bound := + fiberMultiplier_norm_le _ _ _ _ +lemma diagonalFiber_measurable (a : DiagonalSymbol) (f : Base → Fiber) + (hf : AEStronglyMeasurable f baseMeasure) : + AEStronglyMeasurable (fun x => diagonalFiber a x (f x)) baseMeasure := + weightedPermutation_aestronglyMeasurable (Equiv.refl ℤ) a a.bound a.bound_nonneg + a.norm_le_bound a.measurable hf + +def diagonalOperator (a : DiagonalSymbol) : GlobalHilbert →L[ℂ] GlobalHilbert := + fieldOperator (diagonalFiber a) a.bound a.bound_nonneg (diagonalFiber_norm a) + (diagonalFiber_measurable a) +lemma diagonalOperator_ae (a : DiagonalSymbol) (f : GlobalHilbert) : + diagonalOperator a f =ᵐ[baseMeasure] fun x => diagonalFiber a x (f x) := + fieldOperator_ae _ _ _ _ _ _ +lemma diagonalOperator_coord (a : DiagonalSymbol) (f : GlobalHilbert) : + ∀ᵐ x ∂baseMeasure, ∀ j, diagonalOperator a f x j = a x j*f x j := by + filter_upwards [diagonalOperator_ae a f] with x hx j + rw [hx]; rfl +lemma diagonalOperator_norm_le (a : DiagonalSymbol) {C : ℝ} (hC : 0 ≤ C) + (ha : ∀ x j, ‖a x j‖ ≤ C) : ‖diagonalOperator a‖ ≤ C := by + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro f + calc + _ ≤ ‖(C:ℂ) • f‖ := by + apply Lp.norm_le_norm_of_ae_le + filter_upwards [diagonalOperator_ae a f, Lp.coeFn_smul (C:ℂ) f] with x hx hs + rw [hx,hs,Pi.smul_apply] + apply lp.norm_mono (by norm_num : (2:ENNReal) ≠ 0) + intro j + simp only [diagonalFiber_apply,lp.coeFn_smul,Pi.smul_apply,norm_smul,norm_mul, + Complex.norm_real,Real.norm_of_nonneg hC] + exact mul_le_mul_of_nonneg_right (ha x j) (norm_nonneg _) + _ = C*‖f‖ := by rw [norm_smul,Complex.norm_real,Real.norm_of_nonneg hC] +lemma diagonalOperator_zero : diagonalOperator 0 = 0 := by + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord 0 f,Lp.coeFn_zero Fiber 2 baseMeasure] with x hx h0 + ext j + change diagonalOperator 0 f x j = (0 : GlobalHilbert) x j + rw [hx,h0]; simp +lemma diagonalOperator_one : diagonalOperator 1 = 1 := by + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord 1 f] with x hx + ext j + simpa using hx j +lemma diagonalOperator_add (a b : DiagonalSymbol) : + diagonalOperator (a+b) = diagonalOperator a + diagonalOperator b := by + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord (a+b) f, diagonalOperator_coord a f, + diagonalOperator_coord b f, Lp.coeFn_add (diagonalOperator a f) (diagonalOperator b f)] with x hab ha hb hs + ext j + change diagonalOperator (a+b) f x j = (diagonalOperator a f + diagonalOperator b f) x j + rw [hs,Pi.add_apply,lp.coeFn_add,Pi.add_apply,hab,ha,hb,DiagonalSymbol.add_apply,add_mul] +lemma diagonalOperator_mul (a b : DiagonalSymbol) : + diagonalOperator (a*b) = diagonalOperator a * diagonalOperator b := by + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord (a*b) f, diagonalOperator_coord a (diagonalOperator b f), + diagonalOperator_coord b f] with x hab ha hb + ext j + change diagonalOperator (a*b) f x j = diagonalOperator a (diagonalOperator b f) x j + rw [hab,ha,hb,DiagonalSymbol.mul_apply,mul_assoc] +lemma diagonalOperator_smul (c : ℂ) (a : DiagonalSymbol) : + diagonalOperator (c • a) = c • diagonalOperator a := by + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord (c • a) f, diagonalOperator_coord a f, + Lp.coeFn_smul c (diagonalOperator a f)] with x hca ha hs + ext j + change diagonalOperator (c • a) f x j = (c • diagonalOperator a f) x j + rw [hs,Pi.smul_apply,lp.coeFn_smul,Pi.smul_apply,hca,ha,DiagonalSymbol.smul_apply,smul_eq_mul,mul_assoc] +lemma diagonalFiber_inner (a : DiagonalSymbol) (x : Base) (v z : Fiber) : + inner ℂ (diagonalFiber a x v) z = inner ℂ v (diagonalFiber (star a) x z) := by + simp only [lp.inner_eq_tsum] + apply tsum_congr + intro j + simp only [diagonalFiber_apply,DiagonalSymbol.star_apply,RCLike.inner_apply,map_mul,starRingEnd_apply] + ring +lemma diagonalOperator_star (a : DiagonalSymbol) : + diagonalOperator (star a) = star (diagonalOperator a) := by + ext1 f + apply ext_inner_left ℂ + intro g + change inner ℂ g (diagonalOperator (star a) f) = inner ℂ g ((diagonalOperator a).adjoint f) + rw [ContinuousLinearMap.adjoint_inner_right] + simp only [L2.inner_def] + apply integral_congr_ae + filter_upwards [diagonalOperator_ae (star a) f, diagonalOperator_ae a g] with x hf hg + rw [hf,hg,diagonalFiber_inner] + +def diagonalRepresentation : DiagonalSymbol →⋆ₐ[ℂ] (GlobalHilbert →L[ℂ] GlobalHilbert) where + toFun := diagonalOperator + map_zero' := diagonalOperator_zero + map_one' := diagonalOperator_one + map_add' := diagonalOperator_add + map_mul' := diagonalOperator_mul + map_star' := diagonalOperator_star + commutes' c := by + have he : algebraMap ℂ DiagonalSymbol c = c • (1 : DiagonalSymbol) := by + apply Subtype.ext + funext x j + simp + rw [he,diagonalOperator_smul,diagonalOperator_one] + exact (Algebra.algebraMap_eq_smul_one c).symm + +def fullMultiplierAlgebra : StarSubalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert) := + diagonalRepresentation.range + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ErgodicTransitivity.lean b/lean/OAI/Analysis/BackwardIntertwiners/ErgodicTransitivity.lean new file mode 100644 index 0000000000000000000000000000000000000000..6963b083ec39a377cb9c96af966c128dd00d1f59 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ErgodicTransitivity.lean @@ -0,0 +1,380 @@ +import OAI.Analysis.BackwardIntertwiners.GlobalOperators + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + + + +lemma ergodic_late_intersection {X : Type*} [MeasurableSpace X] {μ : Measure X} + [IsFiniteMeasure μ] {θ : X → X} (hθ : Ergodic θ μ) + {A B : Set X} (_ : MeasurableSet A) (hB : MeasurableSet B) + (hA0 : μ A ≠ 0) (hB0 : μ B ≠ 0) (N : ℕ) : + ∃ n : ℕ, N ≤ n ∧ μ (A ∩ (θ^[n]) ⁻¹' B) ≠ 0 := by + let U : Set X := ⋃ n : ℕ, (θ^[n+N]) ⁻¹' B + have hUmeas : MeasurableSet U := MeasurableSet.iUnion fun n => + hB.preimage (hθ.measurable.iterate (n+N)) + have hsub : θ ⁻¹' U ⊆ U := by + intro x hx + obtain ⟨n,hn⟩ := Set.mem_iUnion.mp hx + apply Set.mem_iUnion.mpr + refine ⟨n+1, ?_⟩ + change θ^[n+1+N] x ∈ B + have hi : n+1+N = (n+N)+1 := by omega + rw [hi,Function.iterate_succ_apply] + exact hn + have hU0 : μ U ≠ 0 := by + intro h + have hs : (θ^[N]) ⁻¹' B ⊆ U := by + intro x hx + exact Set.mem_iUnion.mpr ⟨0, by simpa using hx⟩ + have he := (hθ.toMeasurePreserving.iterate N).measure_preimage hB.nullMeasurableSet + exact hB0 (le_antisymm (by rw [← he]; exact (measure_mono hs).trans (by rw [h])) bot_le) + have hUfull : U =ᵐ[μ] Set.univ := by + obtain he | he := hθ.ae_empty_or_univ_of_preimage_ae_le hUmeas.nullMeasurableSet + (Filter.Eventually.of_forall hsub) + · exact False.elim (hU0 (by rw [measure_congr he,measure_empty])) + · exact he + by_contra! hn + have hzero : μ (A ∩ U) = 0 := by + rw [show A ∩ U = ⋃ n : ℕ, A ∩ (θ^[n+N]) ⁻¹' B from Set.inter_iUnion _ _] + exact measure_iUnion_null fun n => hn (n+N) (by omega) + have he : (A ∩ U : Set X) =ᵐ[μ] A := by + filter_upwards [hUfull] with x hx + apply propext + change (x ∈ A ∧ x ∈ U) ↔ x ∈ A + have hxU : x ∈ U := (eq_iff_iff.mp hx).mpr (Set.mem_univ x) + simp [hxU] + exact hA0 ((measure_congr he).symm.trans hzero) + +section Localization +variable {X : Type*} [MeasurableSpace X] {μ : Measure X} [finiteMeasure : IsFiniteMeasure μ] + +omit finiteMeasure in +lemma measurable_global_coordinate [IsFiniteMeasure μ] (f : Lp Fiber 2 μ) (j : ℤ) : Measurable (fun x => f x j) := + ((lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j).continuous.comp_stronglyMeasurable (Lp.stronglyMeasurable f)).measurable + +omit finiteMeasure in +lemma exists_coordinate_support_nonnull [IsFiniteMeasure μ] {f : Lp Fiber 2 μ} (hf : f ≠ 0) : + ∃ j : ℤ, μ {x | f x j ≠ 0} ≠ 0 := by + by_contra! h + apply hf + rw [Lp.eq_zero_iff_ae_eq_zero] + have ha : ∀ j : ℤ, ∀ᵐ x ∂μ, f x j = 0 := fun j => by + exact ae_iff.mpr (h j) + filter_upwards [ae_all_iff.mpr ha] with x hx + ext j + exact hx j + + + + +lemma scalar_invariant_pointwise_orthogonal {L : Submodule ℂ (Lp Fiber 2 μ)} + (hL : ∀ g : Lp ℂ ∞ μ, ∀ f ∈ L, scalarMultiplier g f ∈ L) + {f z : Lp Fiber 2 μ} (hf : f ∈ L) (hz : z ∈ L.orthogonal) : + ∀ᵐ x ∂μ, inner ℂ (z x) (f x) = 0 := by + apply (L2.integrable_inner z f).ae_eq_zero_of_forall_setIntegral_eq_zero + intro s hs _ + let g : Lp ℂ ∞ μ := indicatorConstLp ∞ hs (measure_ne_top μ s) (1:ℂ) + have hg : g =ᵐ[μ] s.indicator (fun _ => (1:ℂ)) := indicatorConstLp_coeFn + rw [← integral_indicator hs] + calc + _ = ∫ x, inner ℂ (z x) (scalarMultiplier g f x) ∂μ := by + apply integral_congr_ae + filter_upwards [scalarMultiplier_ae g f, hg] with x hx hgx + rw [hx,hgx] + by_cases hxs : x ∈ s + · simp [Set.indicator_of_mem hxs] + · simp [Set.indicator_of_notMem hxs] + _ = inner ℂ z (scalarMultiplier g f) := (L2.inner_def _ _).symm + _ = 0 := Submodule.inner_left_of_mem_orthogonal (hL g f hf) hz +end Localization + +lemma fiber_cyclic_orthogonal_order {w : ℤ → ℝ} (hw : QuadraticWeights w) + {T : Fiber →L[ℂ] Fiber} + (hT : ∀ v j, T v j = (w j / w (j-1) : ℂ) * v (j-1)) + {v z : Fiber} (horth : ∀ r : ℕ, inner ℂ z ((T^r) v) = 0) + {i j : ℤ} (hzi : z i ≠ 0) (hvj : v j ≠ 0) : i < j := by + let b := fun k : ℤ => star (z k) * (w k:ℂ) + let c := fun k : ℤ => v k / (w k:ℂ) + have hwC (k : ℤ) : (w k:ℂ) ≠ 0 := by exact_mod_cast (ne_of_gt (hw.positive k)) + have hbi : b i ≠ 0 := mul_ne_zero (by simpa using hzi) (hwC i) + have hcj : c j ≠ 0 := div_ne_zero hvj (hwC j) + have hb (k : ℤ) : ‖b k‖ ≤ (‖z‖+1)*w k := by + dsimp [b] + rw [norm_mul, RCLike.norm_conj, Complex.norm_real, Real.norm_of_nonneg (hw.positive k).le] + apply mul_le_mul_of_nonneg_right _ (hw.positive k).le + exact (lp.norm_apply_le_norm (by norm_num : (2 : ENNReal) ≠ 0) z k).trans (by linarith) + have hc (k : ℤ) : ‖c k‖*w k ≤ ‖v‖+1 := by + dsimp [c] + rw [norm_div, Complex.norm_real, Real.norm_of_nonneg (hw.positive k).le, + div_mul_cancel₀ _ (ne_of_gt (hw.positive k))] + exact (lp.norm_apply_le_norm (by norm_num : (2 : ENNReal) ≠ 0) v k).trans (by linarith) + have hcor (r : ℕ) : (∑' k : ℤ, b k*c (k-r)) = 0 := by + calc (∑' k : ℤ, b k*c (k-r)) = inner ℂ z ((T^r) v) := by + rw [lp.inner_eq_tsum] + apply tsum_congr + intro k + rw [RCLike.inner_apply, weighted_shift_pow hw.positive hT] + dsimp [b, c] + simp only [← Complex.star_def] + ring + _ = 0 := horth r + exact (quadratic_support_separation w hw).strict_order ⟨i,hbi⟩ ⟨j,hcj⟩ + (by positivity : 0 < ‖z‖+1) (by positivity : 0 < ‖v‖+1) hb hc hcor hbi hcj + + +lemma explicitWeight_quadratic (x : Base) : QuadraticWeights (explicitWeight x) := + bilateralWeight_quadratic (plusResidue_bounds x) (minusResidue_bounds x) + +lemma forwardFiber_weight_coordinates (x : Base) (v : Fiber) (j : ℤ) : + forwardFiber x v j = (explicitWeight x j / explicitWeight x (j-1) : ℂ) * v (j-1) := by + rw [forwardFiber_apply, ← explicitWeight_ratio x (j-1)] + simp only [sub_add_cancel, Complex.ofReal_div] + +lemma forwardFiber_lattice (x : Base) (L : Submodule ℂ Fiber) : + (IsClosed (L : Set Fiber) ∧ OperatorInvariant L (forwardFiber x)) ↔ + L = ⊥ ∨ L = ⊤ ∨ ∃ h : ℤ, L = coordinateTail h := by + constructor + · rintro ⟨hcl, hinv⟩ + exact quadratic_fiber_tails _ (explicitWeight_quadratic x) _ (forwardFiber_weight_coordinates x) L hcl hinv + · rintro (rfl | rfl | ⟨h,rfl⟩) + · refine ⟨?_, ?_⟩ + · simpa only [Submodule.bot_coe] using (isClosed_singleton : IsClosed ({0} : Set Fiber)) + · intro v hv + simpa only [Submodule.mem_bot, map_zero] using congrArg (forwardFiber x) (show v = 0 from hv) + · exact ⟨isClosed_univ, fun _ _ => trivial⟩ + · exact ⟨coordinateTail_isClosed h, fun _ hv => forwardFiber_tail x h hv⟩ + +lemma inverseOdometer_ergodic : Ergodic inverseOdometer baseMeasure := + Ergodic.symm (e := odometerMeasurableEquiv) odometer_ergodic + +lemma backwardOperator_power_nonzero (n : ℕ) (f : GlobalHilbert) (j : ℤ) : + ∀ᵐ x ∂baseMeasure, f (inverseOdometer^[n] x) j ≠ 0 → + ((backwardOperator^n) f) x (j-n) ≠ 0 := by + induction n with + | zero => filter_upwards [] with x; simp + | succ n ih => + rw [pow_succ', mul_apply_eq_comp] + filter_upwards [backwardOperator_ae_inverse ((backwardOperator^n) f), + inverseOdometer_preserving.quasiMeasurePreserving.tendsto_ae.eventually ih, + inverseOdometer_preserving.quasiMeasurePreserving.tendsto_ae.eventually backwardCoeff_ae_pos] + with x hx hi hp + intro hn + rw [hx, backwardFiber_apply] + have he : j - (n+1:ℕ) + 1 = j - n := by omega + rw [he] + apply mul_ne_zero + · exact_mod_cast (ne_of_gt (hp (j-n))) + · apply hi + simpa only [Function.iterate_succ_apply] using hn + +lemma global_invariant_pow {T : GlobalHilbert →L[ℂ] GlobalHilbert} + {L : Submodule ℂ GlobalHilbert} (hi : OperatorInvariant L T) + {v : GlobalHilbert} (hv : v ∈ L) (n : ℕ) : (T^n) v ∈ L := by + induction n with + | zero => simpa using hv + | succ n ih => simpa only [pow_succ', mul_apply_eq_comp] using hi _ ih + +lemma invariant_pointwise_order {L : Submodule ℂ GlobalHilbert} + (hS : OperatorInvariant L forwardOperator) + (hM : ∀ g : Lp ℂ ∞ baseMeasure, OperatorInvariant L (scalarMultiplier g)) + {f z : GlobalHilbert} (hf : f ∈ L) (hz : z ∈ L.orthogonal) : + ∀ᵐ x ∂baseMeasure, ∀ i j : ℤ, z x i ≠ 0 → f x j ≠ 0 → i < j := by + have horth (r : ℕ) : ∀ᵐ x ∂baseMeasure, inner ℂ (z x) (((forwardOperator^r) f) x) = 0 := + scalar_invariant_pointwise_orthogonal hM (global_invariant_pow hS hf r) hz + filter_upwards [ae_all_iff.mpr horth, + ae_all_iff.mpr (fun r => forwardOperator_power_ae r f)] with x hx hxpow + intro i j hzi hfj + apply fiber_cyclic_orthogonal_order (explicitWeight_quadratic x) (forwardFiber_weight_coordinates x) ?_ hzi hfj + intro r + rw [← hxpow r] + exact hx r + + + + +lemma forward_backward_scalar_transitive (L : Submodule ℂ GlobalHilbert) + (hclosed : IsClosed (L : Set GlobalHilbert)) + (hS : OperatorInvariant L forwardOperator) + (hV : OperatorInvariant L backwardOperator) + (hM : ∀ g : Lp ℂ ∞ baseMeasure, OperatorInvariant L (scalarMultiplier g)) : + L = ⊥ ∨ L = ⊤ := by + by_contra! hproper + have hOO : L.orthogonal.orthogonal = L := by + rw [Submodule.orthogonal_orthogonal_eq_closure, hclosed.submodule_topologicalClosure_eq] + have hnotOrth : L.orthogonal ≠ ⊥ := by + intro hh + rw [hh, Submodule.bot_orthogonal_eq_top] at hOO + exact hproper.2 hOO.symm + obtain ⟨f,hf,hf0⟩ := (Submodule.ne_bot_iff L).mp hproper.1 + obtain ⟨z,hz,hz0⟩ := (Submodule.ne_bot_iff L.orthogonal).mp hnotOrth + obtain ⟨j,hA0⟩ := exists_coordinate_support_nonnull hf0 + obtain ⟨i,hB0⟩ := exists_coordinate_support_nonnull hz0 + let A : Set Base := {x | f x j ≠ 0} + let B : Set Base := {x | z x i ≠ 0} + have hA : MeasurableSet A := (measurableSet_eq_fun (measurable_global_coordinate f j) measurable_const).compl + have hB : MeasurableSet B := (measurableSet_eq_fun (measurable_global_coordinate z i) measurable_const).compl + obtain ⟨n,hn,hinter⟩ := ergodic_late_intersection inverseOdometer_ergodic hB hA hB0 hA0 (j-i).toNat + have horder := invariant_pointwise_order hS hM (global_invariant_pow hV hf n) hz + have hnull : ∀ᵐ x ∂baseMeasure, x ∉ B ∩ (inverseOdometer^[n]) ⁻¹' A := by + filter_upwards [horder, backwardOperator_power_nonzero n f j] with x hx hp + intro hmem + have hzi : z x i ≠ 0 := hmem.1 + have hfj : f (inverseOdometer^[n] x) j ≠ 0 := hmem.2 + have hh := hx i (j-n) hzi (hp hfj) + have hnat : (j-i) ≤ ((j-i).toNat : ℤ) := by omega + have hnn : ((j-i).toNat : ℤ) ≤ (n:ℤ) := by exact_mod_cast hn + omega + apply hinter + convert ae_iff.mp hnull using 1 + congr 1 + ext x + simp only [Set.mem_ofPred_eq, not_not] + +lemma generated_transitive : AlgebraTransitive (generatedAlgebra forwardOperator backwardOperator) := by + intro L hclosed hInv + apply forward_backward_scalar_transitive L hclosed + · exact hInv _ (Algebra.subset_adjoin (Or.inl (Set.mem_insert _ _))) + · exact hInv _ (Algebra.subset_adjoin (Or.inl (Set.mem_insert_of_mem _ (Set.mem_singleton _)))) + · intro g + exact hInv _ (Algebra.subset_adjoin (Or.inr ⟨g,rfl⟩)) + + +def explicitDirectModel : DirectModelData := + ⟨forwardFiber, forwardOperator, backwardCoeff, backwardFiber, backwardOperator⟩ + +lemma explicitDirectModel_properties : DirectModelProperties explicitDirectModel where + beta_measurable := measurable_explicitBeta + beta_positive := explicitBeta_pos + forward_coordinates := forwardFiber_apply + forward_field := forwardOperator_ae + fiber_lattice := forwardFiber_lattice + S_nonzero := forwardOperator_ne_zero + S_norm := forwardOperator_norm + power_bound := fun n _ => forwardOperator_power_norm n + V_contraction := backwardOperator_norm + commute := forward_backward_commute + backward_measurable := measurable_backwardCoeff + backward_bounds := backwardCoeff_bounds + backward_coordinates := backwardFiber_apply + backward_field := backwardOperator_ae + common_conull := by + refine ⟨goodBase, measurableSet_goodBase, ?_, ?_, ?_⟩ + · exact ae_iff.mp ae_goodBase + · ext x + exact goodBase_odometer x + · intro x hx + exact ⟨backwardCoeff_pos hx, backwardFiber_tail_closure hx, backwardFiber_denseRange hx⟩ + transitive := generated_transitive + +theorem direct_model : ∃ D : DirectModelData, DirectModelProperties D := + ⟨explicitDirectModel, explicitDirectModel_properties⟩ + +def rankOneCoordinate (i j : ℤ) : Fiber →L[ℂ] Fiber := + (lp.singleContinuousLinearMap ℂ (fun _ : ℤ => ℂ) 2 i).comp (lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j) +@[simp] lemma rankOneCoordinate_apply (i j : ℤ) (v : Fiber) : + rankOneCoordinate i j v = lp.single 2 i (v j) := rfl +lemma rankOneCoordinate_compact (i j : ℤ) : IsCompactOperator (rankOneCoordinate i j) := + (isCompactOperator_of_locallyCompactSpace_dom (lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j)).clm_comp + (lp.singleContinuousLinearMap ℂ (fun _ : ℤ => ℂ) 2 i) + +def finiteShift (x : Base) (n : ℕ) : Fiber →L[ℂ] Fiber := + ∑ j ∈ Finset.Icc (-(n:ℤ)) n, (explicitBeta x j:ℂ) • rankOneCoordinate (j+1) j +lemma finiteShift_compact (x : Base) (n : ℕ) : IsCompactOperator (finiteShift x n) := by + change finiteShift x n ∈ compactOperator (RingHom.id ℂ) Fiber Fiber + exact Submodule.sum_mem _ fun j hj => Submodule.smul_mem _ _ (rankOneCoordinate_compact (j+1) j) +lemma finiteShift_apply (x : Base) (n : ℕ) (v : Fiber) (j : ℤ) : + finiteShift x n v (j+1) = if j ∈ Finset.Icc (-(n:ℤ)) n then (explicitBeta x j:ℂ) * v j else 0 := by + classical + simp only [finiteShift, sum_apply, smul_apply, + lp.coeFn_sum, Finset.sum_apply, lp.coeFn_smul, Pi.smul_apply, rankOneCoordinate_apply] + by_cases hj : j ∈ Finset.Icc (-(n:ℤ)) n + · rw [ite_eq_left hj, Finset.sum_eq_single_of_mem j hj] + · simp only [lp.single_apply_self, smul_eq_mul] + · intro k hk hkj + rw [lp.single_apply_ne _ _ _ (by omega), smul_zero] + · rw [ite_eq_right hj] + apply Finset.sum_eq_zero + intro k hk + have hkj : j+1 ≠ k+1 := by + intro hh + have he : j=k := by omega + subst k + exact hj hk + rw [lp.single_apply_ne _ _ _ hkj, smul_zero] +lemma explicitBeta_outside_bound (x : Base) (n : ℕ) (j : ℤ) + (hj : j ∉ Finset.Icc (-(n:ℤ)) n) : explicitBeta x j ≤ Real.exp (-10*(n:ℝ)) := by + apply Real.exp_le_exp.mpr + change -explicitExponent x j ≤ -10*(n:ℝ) + have hd := explicitExponent_distance x j + have hh : (n:ℤ) ≤ coordinateDistance j := by + simp only [Finset.mem_Icc, not_and_or, not_le] at hj + rcases hj with hj | hj + · exact (by omega : (n:ℤ) ≤ -j).trans (le_max_right _ _) + · exact (by omega : (n:ℤ) ≤ j+1).trans (le_max_left _ _) + have hR : (n:ℝ) ≤ (coordinateDistance j : ℝ) := by exact_mod_cast hh + linarith +lemma finiteShift_error (x : Base) (n : ℕ) : + ‖forwardFiber x - finiteShift x n‖ ≤ Real.exp (-10*(n:ℝ)) := by + let C := Real.exp (-10*(n:ℝ)) + have hC : 0 ≤ C := (Real.exp_pos _).le + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro v + calc + _ ≤ ‖(C:ℂ) • v‖ := by + let vr := fiberReindex (Equiv.addRight (1:ℤ)) ((forwardFiber x - finiteShift x n) v) + rw [← (fiberReindex (Equiv.addRight (1:ℤ))).norm_map ((forwardFiber x - finiteShift x n) v)] + apply lp.norm_mono (by norm_num : (2:ENNReal) ≠ 0) + intro j + change ‖(forwardFiber x - finiteShift x n) v (j+1)‖ ≤ ‖(C:ℂ) * v j‖ + rw [sub_apply, lp.coeFn_sub, Pi.sub_apply, forwardFiber_apply, add_sub_cancel_right, finiteShift_apply] + by_cases hj : j ∈ Finset.Icc (-(n:ℤ)) n + · rw [ite_eq_left hj, sub_self, norm_zero] + exact norm_nonneg _ + · rw [ite_eq_right hj, sub_zero, norm_mul, norm_mul, Complex.norm_real, Complex.norm_real, + Real.norm_of_nonneg (explicitBeta_pos x j).le, Real.norm_of_nonneg hC] + exact mul_le_mul_of_nonneg_right (explicitBeta_outside_bound x n j hj) (norm_nonneg _) + _ = C*‖v‖ := by rw [norm_smul, Complex.norm_real, Real.norm_of_nonneg hC] +lemma forwardFiber_compact (x : Base) : IsCompactOperator (forwardFiber x) := by + apply isCompactOperator_of_tendsto (l:=atTop) (F:=finiteShift x) ?_ (Filter.Eventually.of_forall (finiteShift_compact x)) + rw [tendsto_iff_norm_sub_tendsto_zero] + have he : Tendsto (fun n : ℕ => Real.exp (-10*(n:ℝ))) atTop (𝓝 0) := by + apply Real.tendsto_exp_atBot.comp + exact tendsto_const_nhds.neg_mul_atTop (by norm_num) tendsto_natCast_atTop_atTop + apply squeeze_zero (fun _ => norm_nonneg _) ?_ he + intro n + rw [norm_sub_rev] + exact finiteShift_error x n + +abbrev ScalarHilbert := Lp ℂ 2 baseMeasure + +def coordinateL2 (j : ℤ) : GlobalHilbert →L[ℂ] ScalarHilbert := + (lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j).compLpL 2 baseMeasure + +def singleL2 (j : ℤ) : ScalarHilbert →L[ℂ] GlobalHilbert := + (lp.singleContinuousLinearMap ℂ (fun _ : ℤ => ℂ) 2 j).compLpL 2 baseMeasure + +lemma coordinateL2_ae (j : ℤ) (f : GlobalHilbert) : + coordinateL2 j f =ᵐ[baseMeasure] fun x => f x j := + ContinuousLinearMap.coeFn_compLpL _ _ +lemma singleL2_ae (j : ℤ) (f : ScalarHilbert) : + singleL2 j f =ᵐ[baseMeasure] fun x => lp.single 2 j (f x) := + ContinuousLinearMap.coeFn_compLpL _ _ +lemma coordinateL2_singleL2 (j : ℤ) (f : ScalarHilbert) : + coordinateL2 j (singleL2 j f) = f := by + apply Lp.ext + filter_upwards [coordinateL2_ae j (singleL2 j f), singleL2_ae j f] with x h₁ h₂ + simp only [h₁, h₂, lp.single_apply_self] + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ExplicitWeights.lean b/lean/OAI/Analysis/BackwardIntertwiners/ExplicitWeights.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ebea79865ea24f1de19d630daff227776df3111 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ExplicitWeights.lean @@ -0,0 +1,288 @@ +import OAI.Analysis.BackwardIntertwiners.FiberTails + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + + +def weightBlock (k : ℕ) : ℕ := Nat.log 8 k + 1 +def residueScale (k : ℕ) : ℕ := 2 ^ weightBlock k + +def residueCorrection (t : ℕ → ℕ) (k : ℕ) : ℝ := + if k = 0 then 0 else 100 * ((residueScale k : ℝ) - 2 + t (weightBlock k)) +def halfExponent (t : ℕ → ℕ) (k : ℕ) : ℝ := + 10 * ((k : ℝ) + 1) + residueCorrection t k + +def ResidueBounds (t : ℕ → ℕ) : Prop := ∀ m, t m < 2 ^ m + +lemma residueScale_ge_two (k : ℕ) : 2 ≤ residueScale k := by + dsimp [residueScale, weightBlock] + simpa using (Nat.pow_le_pow_right (by norm_num : 0 < 2) (by omega : 1 ≤ Nat.log 8 k + 1)) + +lemma residueCorrection_nonneg (t : ℕ → ℕ) (k : ℕ) : 0 ≤ residueCorrection t k := by + dsimp [residueCorrection] + split_ifs + · rfl + · have hh : (2:ℝ) ≤ residueScale k := by exact_mod_cast residueScale_ge_two k + positivity + +lemma residueCorrection_le {t : ℕ → ℕ} (ht : ResidueBounds t) (k : ℕ) : + residueCorrection t k ≤ 200 * residueScale k := by + have hN : (0:ℝ) ≤ residueScale k := Nat.cast_nonneg _ + dsimp [residueCorrection] + split_ifs + · positivity + · have hr : (t (weightBlock k):ℝ) < residueScale k := by exact_mod_cast ht (weightBlock k) + linarith + +lemma residueCorrection_mono {t : ℕ → ℕ} (ht : ResidueBounds t) : + Monotone (residueCorrection t) := by + intro k l hkl + by_cases hk : k = 0 + · simpa [hk, residueCorrection] using residueCorrection_nonneg t l + have hl : l ≠ 0 := by omega + have hq : weightBlock k ≤ weightBlock l := Nat.add_le_add_right (Nat.log_mono_right hkl) 1 + dsimp only [residueCorrection] + rw [ite_eq_right hk, ite_eq_right hl] + rcases hq.eq_or_lt with hq | hq + · simp [hq, residueScale] + · have hNN : 2 * residueScale k ≤ residueScale l := by + dsimp [residueScale] + rw [← pow_succ'] + exact Nat.pow_le_pow_right (by norm_num) (by omega) + have hNk : (2 * residueScale k : ℝ) ≤ residueScale l := by exact_mod_cast hNN + have htk : (t (weightBlock k) : ℝ) < residueScale k := by exact_mod_cast ht _ + have htl : (0:ℝ) ≤ t (weightBlock l) := Nat.cast_nonneg _ + linarith + +lemma halfExponent_mono {t : ℕ → ℕ} (ht : ResidueBounds t) : Monotone (halfExponent t) := by + intro k l hkl + have hc := residueCorrection_mono ht hkl + have hkl' : (k:ℝ) ≤ l := by exact_mod_cast hkl + dsimp [halfExponent] + linarith + +lemma halfExponent_lower (t : ℕ → ℕ) (k : ℕ) : + 10*((k:ℝ)+1) ≤ halfExponent t k := by + have hh := residueCorrection_nonneg t k + dsimp [halfExponent] + linarith + +@[simp] lemma halfExponent_zero (t : ℕ → ℕ) : halfExponent t 0 = 10 := by + norm_num [halfExponent, residueCorrection] + +lemma residueScale_sq_le {k : ℕ} (hk : k ≠ 0) : (residueScale k)^2 ≤ 4*k := by + let q := Nat.log 8 k + have hq : 8 ^ q ≤ k := Nat.pow_log_le_self 8 hk + have h4 : 4 ^ q ≤ 8 ^ q := Nat.pow_le_pow_left (by norm_num) q + have he : (residueScale k)^2 = 4 * 4 ^ q := by + change (2 ^ (q+1))^2 = 4 * 4^q + rw [pow_succ (2:ℕ) q, mul_pow, ← pow_mul, mul_comm q 2, pow_mul] + norm_num + ring + rw [he] + omega + +lemma residueCorrection_sqrt_bound {t : ℕ → ℕ} (ht : ResidueBounds t) (k : ℕ) : + residueCorrection t k ≤ 400 * Real.sqrt k := by + by_cases hk : k = 0 + · simp [hk, residueCorrection] + have hs : (residueScale k : ℝ)^2 ≤ 4*(k:ℝ) := by exact_mod_cast residueScale_sq_le hk + have hroot := Real.sq_sqrt (Nat.cast_nonneg k : (0:ℝ) ≤ k) + have hroot0 := Real.sqrt_nonneg (k:ℝ) + have hN0 : (0:ℝ) ≤ residueScale k := Nat.cast_nonneg _ + have hNr : (residueScale k : ℝ) ≤ 2*Real.sqrt k := by nlinarith + exact (residueCorrection_le ht k).trans (by linarith) + +def halfSum (t : ℕ → ℕ) (n : ℕ) : ℝ := ∑ k ∈ Finset.range n, halfExponent t k + +@[simp] lemma halfSum_zero (t : ℕ → ℕ) : halfSum t 0 = 0 := by simp [halfSum] +@[simp] lemma halfSum_succ (t : ℕ → ℕ) (n : ℕ) : + halfSum t (n+1) = halfSum t n + halfExponent t n := by simp [halfSum, Finset.sum_range_succ] + +lemma halfSum_linear (n : ℕ) : + (∑ k ∈ Finset.range n, (10:ℝ)*((k:ℝ)+1)) = 5*(n:ℝ)*((n:ℝ)+1) := by + induction n with + | zero => simp + | succ n ih => + rw [Finset.sum_range_succ, ih] + push_cast + ring + +lemma halfSum_bounds {t : ℕ → ℕ} (ht : ResidueBounds t) (n : ℕ) : + 5*(n:ℝ)*((n:ℝ)+1) ≤ halfSum t n ∧ + halfSum t n ≤ 5*(n:ℝ)*((n:ℝ)+1) + 400*(n:ℝ)*Real.sqrt n := by + have he : halfSum t n = 5*(n:ℝ)*((n:ℝ)+1) + + ∑ k ∈ Finset.range n, residueCorrection t k := by + simp only [halfSum, halfExponent, Finset.sum_add_distrib, halfSum_linear] + rw [he] + constructor + · exact le_add_of_nonneg_right (Finset.sum_nonneg (fun k _ => residueCorrection_nonneg t k)) + · have hh : (∑ k ∈ Finset.range n, residueCorrection t k) ≤ + ∑ _k ∈ Finset.range n, 400*Real.sqrt n := by + apply Finset.sum_le_sum + intro k hk + have hkn : (k:ℝ) ≤ n := by exact_mod_cast (Finset.mem_range.mp hk).le + exact (residueCorrection_sqrt_bound ht k).trans + (mul_le_mul_of_nonneg_left (Real.sqrt_le_sqrt hkn) (by norm_num)) + simp only [Finset.sum_const, Finset.card_range, nsmul_eq_mul] at hh + nlinarith + +lemma halfSum_quadratic {t : ℕ → ℕ} (ht : ResidueBounds t) : + Tendsto (fun n : ℕ => halfSum t n / (n:ℝ)^2) atTop (𝓝 5) := by + have hn : Tendsto (fun n : ℕ => (n:ℝ)) atTop atTop := tendsto_natCast_atTop_atTop + have hi : Tendsto (fun n : ℕ => (n:ℝ)⁻¹) atTop (𝓝 0) := tendsto_inv_atTop_zero.comp hn + have hs : Tendsto (fun n : ℕ => (Real.sqrt (n:ℝ))⁻¹) atTop (𝓝 0) := + tendsto_inv_atTop_zero.comp (Real.tendsto_sqrt_atTop.comp hn) + have hz : Tendsto (fun n : ℕ => halfSum t n / (n:ℝ)^2 - 5) atTop (𝓝 0) := by + apply squeeze_zero' (g := fun n : ℕ => 5*(n:ℝ)⁻¹ + 400*(Real.sqrt (n:ℝ))⁻¹) ?_ ?_ + (by simpa using (hi.const_mul 5).add (hs.const_mul 400)) + · filter_upwards [eventually_ge_atTop 1] with n hn + have hn0 : (0:ℝ) < n := by exact_mod_cast (by omega : 0 < n) + have hh := (halfSum_bounds ht n).1 + have hdiv := (le_div_iff₀ (sq_pos_of_pos hn0)).mpr (show 5*(n:ℝ)^2 ≤ halfSum t n by nlinarith) + linarith + · filter_upwards [eventually_ge_atTop 1] with n hn + have hn0 : (0:ℝ) < n := by exact_mod_cast (by omega : 0 < n) + have hr0 : 0 < Real.sqrt (n:ℝ) := Real.sqrt_pos.mpr hn0 + have hr := Real.sq_sqrt hn0.le + have hh := (halfSum_bounds ht n).2 + have he : (5*(n:ℝ)*((n:ℝ)+1) + 400*(n:ℝ)*Real.sqrt n) / (n:ℝ)^2 - 5 = + 5*(n:ℝ)⁻¹ + 400*(Real.sqrt (n:ℝ))⁻¹ := by + field_simp + nlinarith + rw [← he] + exact sub_le_sub_right (div_le_div_of_nonneg_right hh (sq_nonneg _)) 5 + simpa only [sub_add_cancel, zero_add] using hz.add_const 5 + + +def bilateralExponent (t u : ℕ → ℕ) : ℤ → ℝ + | .ofNat n => halfExponent t n + | .negSucc n => halfExponent u n + +def bilateralBeta (t u : ℕ → ℕ) (j : ℤ) : ℝ := Real.exp (-bilateralExponent t u j) + + +def bilateralWeight (t u : ℕ → ℕ) : ℤ → ℝ + | .ofNat n => Real.exp (-halfSum t n) + | .negSucc n => Real.exp (halfSum u (n+1)) + +@[simp] lemma bilateralWeight_nat (t u : ℕ → ℕ) (n : ℕ) : + bilateralWeight t u n = Real.exp (-halfSum t n) := rfl +@[simp] lemma bilateralWeight_neg_nat (t u : ℕ → ℕ) (n : ℕ) : + bilateralWeight t u (-(n:ℤ)) = Real.exp (halfSum u n) := by + cases n with + | zero => simp [bilateralWeight] + | succ n => rfl + +lemma bilateralExponent_nonneg (t u : ℕ → ℕ) (j : ℤ) : 10 ≤ bilateralExponent t u j := by + cases j with + | ofNat n => + have hh := halfExponent_lower t n + change 10 ≤ halfExponent t n + have hn : (0:ℝ) ≤ n := Nat.cast_nonneg _ + linarith + | negSucc n => + have hh := halfExponent_lower u n + change 10 ≤ halfExponent u n + have hn : (0:ℝ) ≤ n := Nat.cast_nonneg _ + linarith + +lemma bilateralWeight_pos (t u : ℕ → ℕ) (j : ℤ) : 0 < bilateralWeight t u j := by + cases j <;> exact Real.exp_pos _ + +lemma bilateralWeight_ratio (t u : ℕ → ℕ) (j : ℤ) : + bilateralWeight t u (j+1) / bilateralWeight t u j = bilateralBeta t u j := by + cases j with + | ofNat n => + change Real.exp (-halfSum t (n+1)) / Real.exp (-halfSum t n) = Real.exp (-halfExponent t n) + rw [← Real.exp_sub, halfSum_succ] + congr 1 + ring + | negSucc n => + cases n with + | zero => + change Real.exp (-halfSum t 0) / Real.exp (halfSum u 1) = Real.exp (-halfExponent u 0) + simp [halfSum_succ, Real.exp_neg] + | succ n => + change Real.exp (halfSum u (n+1)) / Real.exp (halfSum u (n+1+1)) = Real.exp (-halfExponent u (n+1)) + rw [← Real.exp_sub, halfSum_succ u (n+1)] + congr 1 + ring + +lemma bilateralWeight_antitone (t u : ℕ → ℕ) : Antitone (bilateralWeight t u) := by + apply antitone_int_of_succ_le + intro j + have hr := bilateralWeight_ratio t u j + have he : bilateralBeta t u j ≤ 1 := by + rw [bilateralBeta, Real.exp_le_one_iff] + have hh := bilateralExponent_nonneg t u j + linarith + exact (div_le_one (bilateralWeight_pos t u j)).mp (hr.le.trans he) + +lemma halfSum_discreteConvex {t : ℕ → ℕ} (ht : ResidueBounds t) : DiscreteConvex (halfSum t) := by + unfold DiscreteConvex + simpa only [halfSum_succ, add_sub_cancel_left] using halfExponent_mono ht + +lemma halfSum_root_bound {t : ℕ → ℕ} (ht : ResidueBounds t) {n : ℕ} (hn : 0 < n) : + -halfSum t n / (n:ℝ) ≤ -5*(n:ℝ) := by + have hn' : (0:ℝ) < n := Nat.cast_pos.mpr hn + apply (div_le_iff₀ hn').mpr + have hh := (halfSum_bounds ht n).1 + nlinarith + +lemma bilateralWeight_roots_summable {t u : ℕ → ℕ} (ht : ResidueBounds t) (hu : ResidueBounds u) : + Summable (fun j : ℤ => if j = 0 then (0:ℝ) else bilateralWeight t u j ^ (1/(j:ℝ))) := by + have hs : Summable (fun n : ℕ => Real.exp (-5*(n:ℝ))) := by + simpa only [mul_comm (-5:ℝ)] using Real.summable_exp_nat_mul_iff.mpr (by norm_num : (-5:ℝ) < 0) + apply Summable.of_nat_of_neg_add_one + · apply hs.of_nonneg_of_le + · intro n + split_ifs + · rfl + · exact Real.rpow_nonneg (bilateralWeight_pos t u _).le _ + · intro n + by_cases hn : n = 0 + · simp [hn] + · rw [ite_eq_right (by exact_mod_cast hn), bilateralWeight_nat, ← Real.exp_mul] + apply Real.exp_le_exp.mpr + simpa only [mul_one_div, Int.cast_natCast] using halfSum_root_bound ht (Nat.pos_of_ne_zero hn) + · have hs' : Summable (fun n : ℕ => Real.exp (-5*((n:ℝ)+1))) := by + simpa only [mul_add, mul_one, Real.exp_add] using hs.mul_right (Real.exp (-5)) + apply hs'.of_nonneg_of_le + · intro n + split_ifs + · rfl + · exact Real.rpow_nonneg (bilateralWeight_pos t u _).le _ + · intro n + have hj : -((n:ℤ)+1) = -((n+1:ℕ):ℤ) := by omega + rw [hj, ite_eq_right (by omega), bilateralWeight_neg_nat, ← Real.exp_mul] + apply Real.exp_le_exp.mpr + have hb := halfSum_root_bound hu (Nat.zero_lt_succ n) + convert hb using 1 <;> + simp only [Int.cast_neg, Int.cast_add, Int.cast_one, Int.cast_natCast, Nat.succ_eq_add_one, inv_neg, + div_eq_mul_inv, Nat.cast_add, Nat.cast_one] ; ring + +lemma bilateralWeight_quadratic {t u : ℕ → ℕ} (ht : ResidueBounds t) (hu : ResidueBounds u) : + QuadraticWeights (bilateralWeight t u) where + positive := bilateralWeight_pos t u + decreasing := bilateralWeight_antitone t u + convex_negative := by + simpa only [bilateralWeight_neg_nat, Real.log_exp] using halfSum_discreteConvex hu + concave_positive := by + simpa only [bilateralWeight_nat, Real.log_exp, neg_neg] using halfSum_discreteConvex ht + root_sum := bilateralWeight_roots_summable ht hu + quadratic := by + refine ⟨5, ?_, ?_, ?_⟩ + · exact (Real.log_lt_sub_one_of_pos (by norm_num) (by norm_num : (3:ℝ) ≠ 1)).trans (by norm_num) + · simpa only [bilateralWeight_nat, Real.log_exp, neg_div] using (halfSum_quadratic ht).neg + · simpa only [bilateralWeight_neg_nat, Real.log_exp] using halfSum_quadratic hu + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/FiberMaps.lean b/lean/OAI/Analysis/BackwardIntertwiners/FiberMaps.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca128153fe086c3308a18e9f080f28c250654d27 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/FiberMaps.lean @@ -0,0 +1,159 @@ +import OAI.Analysis.BackwardIntertwiners.HaarBase + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +def coordinateDistance (j : ℤ) : ℤ := max (j+1) (-j) +def powerCost (n : ℕ) : ℕ := (n+1)^2/4 + +lemma powerCost_add_two (n : ℕ) : powerCost (n+2) = powerCost n + n+2 := by + unfold powerCost + have he : (n+2+1)^2 = (n+1)^2 + 4*(n+2) := by ring + rw [he] + omega + +lemma coordinateDistance_pos (j : ℤ) : 1 ≤ coordinateDistance j := by + unfold coordinateDistance + omega + +lemma coordinateDistance_endpoints (j : ℤ) (n : ℕ) : + (n:ℤ)+2 ≤ coordinateDistance j + coordinateDistance (j+(n:ℤ)+1) := by + have h₁ : -j ≤ coordinateDistance j := le_max_right _ _ + have h₂ : j+(n:ℤ)+1+1 ≤ coordinateDistance (j+(n:ℤ)+1) := le_max_left _ _ + omega + +lemma sum_coordinateDistance_lower (n : ℕ) (j : ℤ) : + (powerCost n : ℤ) ≤ ∑ r ∈ Finset.range n, coordinateDistance (j+(r:ℤ)) := by + induction n using Nat.twoStepInduction generalizing j with + | zero => simp [powerCost] + | one => simpa [powerCost] using coordinateDistance_pos j + | more n ih _ => + have hsum : (∑ r ∈ Finset.range (n+2), coordinateDistance (j+(r:ℤ))) = + coordinateDistance j + (∑ r ∈ Finset.range n, coordinateDistance ((j+1)+(r:ℤ))) + + coordinateDistance (j+(n:ℤ)+1) := by + rw [Finset.sum_range_succ, Finset.sum_range_succ'] + simp only [Nat.cast_add, Nat.cast_one, Nat.cast_zero, add_zero] + congr 1 + · rw [add_comm] + congr 1 + apply Finset.sum_congr rfl + intro r hr + congr 1 + ring + · congr 1 + ring + rw [hsum, powerCost_add_two] + have hmid := ih (j+1) + have hend := coordinateDistance_endpoints j n + push_cast + omega + + +def fiberReindexVector (e : ℤ ≃ ℤ) (v : Fiber) : Fiber := + ⟨fun j => v (e j), by + apply memℓp_gen + exact ((lp.memℓp v).summable (by norm_num)).comp_injective e.injective⟩ + +lemma fiberReindex_norm (e : ℤ ≃ ℤ) (v : Fiber) : ‖fiberReindexVector e v‖ = ‖v‖ := by + have he : ‖fiberReindexVector e v‖^2 = ‖v‖^2 := by + have h₁ := lp.norm_rpow_eq_tsum (by norm_num : (0:ℝ) < (2:ENNReal).toReal) (fiberReindexVector e v) + have h₂ := lp.norm_rpow_eq_tsum (by norm_num : (0:ℝ) < (2:ENNReal).toReal) v + simp only [ENNReal.toReal_ofNat, Real.rpow_two] at h₁ h₂ + rw [h₁, h₂] + exact e.tsum_eq (fun j => ‖v j‖^2) + nlinarith [norm_nonneg (fiberReindexVector e v), norm_nonneg v] + + +def fiberReindex (e : ℤ ≃ ℤ) : Fiber ≃ₗᵢ[ℂ] Fiber where + toFun := fiberReindexVector e + invFun := fiberReindexVector e.symm + left_inv v := by ext j; exact congrArg v (e.apply_symm_apply j) + right_inv v := by ext j; exact congrArg v (e.symm_apply_apply j) + map_add' v z := by ext j; rfl + map_smul' c v := by ext j; rfl + norm_map' := fiberReindex_norm e + +@[simp] lemma fiberReindex_apply (e : ℤ ≃ ℤ) (v : Fiber) (j : ℤ) : + (fiberReindex e v) j = v (e j) := rfl + +lemma fiberMultiplier_mem {a : ℤ → ℂ} {C : ℝ} (hC : 0 ≤ C) + (ha : ∀ j, ‖a j‖ ≤ C) (v : Fiber) : Memℓp (fun j => a j*v j) 2 := by + apply ((lp.memℓp v).const_smul (C:ℂ)).mono' + intro j + simp only [Pi.smul_apply, norm_smul, Complex.norm_real, Real.norm_of_nonneg hC, norm_mul] + exact mul_le_mul_of_nonneg_right (ha j) (norm_nonneg _) + +def fiberMultiplierVector (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ j, ‖a j‖ ≤ C) + (v : Fiber) : Fiber := ⟨fun j => a j*v j, fiberMultiplier_mem hC ha v⟩ + +lemma fiberMultiplierVector_bound (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ j, ‖a j‖ ≤ C) + (v : Fiber) : ‖fiberMultiplierVector a C hC ha v‖ ≤ C*‖v‖ := by + calc + _ ≤ ‖(C:ℂ) • v‖ := by + apply lp.norm_mono (by norm_num : (2:ENNReal) ≠ 0) + intro j + change ‖a j*v j‖ ≤ ‖(C:ℂ)*v j‖ + rw [norm_mul, norm_mul, Complex.norm_real, Real.norm_of_nonneg hC] + exact mul_le_mul_of_nonneg_right (ha j) (norm_nonneg _) + _ = C*‖v‖ := by rw [norm_smul, Complex.norm_real, Real.norm_of_nonneg hC] + +def fiberMultiplier (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ j, ‖a j‖ ≤ C) : + Fiber →L[ℂ] Fiber := + LinearMap.mkContinuous + { toFun := fiberMultiplierVector a C hC ha + map_add' := by intro v z; ext j; exact mul_add _ _ _ + map_smul' := by intro c v; ext j; exact mul_left_comm _ _ _ } + C (fiberMultiplierVector_bound a C hC ha) + +@[simp] lemma fiberMultiplier_apply (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ j, ‖a j‖ ≤ C) + (v : Fiber) (j : ℤ) : fiberMultiplier a C hC ha v j = a j*v j := rfl + +lemma fiberMultiplier_norm_le (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ j, ‖a j‖ ≤ C) : + ‖fiberMultiplier a C hC ha‖ ≤ C := + ContinuousLinearMap.opNorm_le_bound _ hC (fiberMultiplierVector_bound a C hC ha) + + +def fiberWeightedPermutation (e : ℤ ≃ ℤ) (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) + (ha : ∀ j, ‖a j‖ ≤ C) : Fiber →L[ℂ] Fiber := + (fiberReindex e).toLinearIsometry.toContinuousLinearMap.comp (fiberMultiplier a C hC ha) + +@[simp] lemma fiberWeightedPermutation_apply (e : ℤ ≃ ℤ) (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) + (ha : ∀ j, ‖a j‖ ≤ C) (v : Fiber) (j : ℤ) : + fiberWeightedPermutation e a C hC ha v j = a (e j)*v (e j) := rfl + +lemma fiberWeightedPermutation_norm_le (e : ℤ ≃ ℤ) (a : ℤ → ℂ) (C : ℝ) (hC : 0 ≤ C) + (ha : ∀ j, ‖a j‖ ≤ C) : ‖fiberWeightedPermutation e a C hC ha‖ ≤ C := by + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro v + change ‖fiberReindex e (fiberMultiplier a C hC ha v)‖ ≤ _ + rw [(fiberReindex e).norm_map] + exact fiberMultiplierVector_bound a C hC ha v + + + +lemma fiberCoordinates_stronglyMeasurable {X : Type*} [MeasurableSpace X] + (f : X → Fiber) (hf : ∀ n : ℤ, Measurable (fun x => f x n)) : StronglyMeasurable f := by + apply stronglyMeasurable_of_tendsto (atTop : Filter (Finset ℤ)) + (f := fun s x => ∑ n ∈ s, lp.single 2 n (f x n)) + · intro s + have h (n : ℤ) : StronglyMeasurable (fun x => (lp.single 2 n (f x n) : Fiber)) := + (lp.singleContinuousLinearMap ℂ (fun _ : ℤ => ℂ) 2 n).continuous.comp_stronglyMeasurable + (hf n).stronglyMeasurable + convert Finset.stronglyMeasurable_sum s (fun n _ => h n) using 1 + funext x + simp only [Finset.sum_apply] + · rw [tendsto_pi_nhds] + intro x + exact lp.hasSum_single (by norm_num : (2 : ENNReal) ≠ ∞) (f x) + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/FiberTails.lean b/lean/OAI/Analysis/BackwardIntertwiners/FiberTails.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc94955064e6425683fae4383700fa071831c98a --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/FiberTails.lean @@ -0,0 +1,165 @@ +import OAI.Analysis.BackwardIntertwiners.WeightSeparation + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +abbrev Fiber := lp (fun _ : ℤ => ℂ) 2 + + +def coordinateTail (h : ℤ) : Submodule ℂ Fiber where + carrier := {v | ∀ j : ℤ, j < h → v j = 0} + zero_mem' := by simp + add_mem' := by intro v z hv hz j hj; simp [hv j hj, hz j hj] + smul_mem' := by intro a v hv j hj; simp [hv j hj] + +lemma fiber_exists_coordinate {v : Fiber} (hv : v ≠ 0) : ∃ j : ℤ, v j ≠ 0 := by + by_contra! h + apply hv + ext j + exact h j + +lemma weighted_shift_pow {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) + {T : Fiber →L[ℂ] Fiber} + (hT : ∀ v j, T v j = (w j / w (j-1) : ℂ) * v (j-1)) + (n : ℕ) (v : Fiber) (j : ℤ) : + (T^n) v j = (w j / w (j-(n:ℤ)) : ℂ) * v (j-(n:ℤ)) := by + have hwC (k : ℤ) : (w k:ℂ) ≠ 0 := by exact_mod_cast (ne_of_gt (hw k)) + induction n generalizing j with + | zero => simp [hwC] + | succ n ih => + rw [pow_succ'] + change T ((T^n) v) j = _ + rw [hT, ih] + have hi : j-1-(n:ℤ) = j-((n+1:ℕ):ℤ) := by omega + rw [hi] + field_simp [hwC] + +lemma invariant_pow {T : Fiber →L[ℂ] Fiber} {L : Submodule ℂ Fiber} + (hi : ∀ v ∈ L, T v ∈ L) {v : Fiber} (hv : v ∈ L) (n : ℕ) : (T^n) v ∈ L := by + induction n with + | zero => simpa using hv + | succ n ih => simpa only [pow_succ', mul_apply_eq_comp] using hi _ ih + + + +lemma SupportSeparation.strict_order {w : ℤ → ℝ} (hsep : SupportSeparation w) + {b c : ℤ → ℂ} (hbn : ∃ j, b j ≠ 0) (hcn : ∃ j, c j ≠ 0) + {B C : ℝ} (hB : 0 < B) (hC : 0 < C) + (hb : ∀ j, ‖b j‖ ≤ B*w j) (hc : ∀ j, ‖c j‖*w j ≤ C) + (hz : ∀ r : ℕ, (∑' j : ℤ, b j * c (j-r)) = 0) + {i j : ℤ} (hbi : b i ≠ 0) (hcj : c j ≠ 0) : i < j := by + obtain ⟨t, h, hbt, hch, hbmax, hcmin, hth⟩ := + hsep.of_bounded hbn hcn hB hC hb hc (fun r _ => hz r) + have hit : i ≤ t := by by_contra! hh; exact hbi (hbmax i hh) + have hhj : h ≤ j := by by_contra! hh; exact hcj (hcmin j hh) + have hstrict : t < h := by + by_contra! hht + have he : t = h := le_antisymm hth hht + have hsingle : (∑' k : ℤ, b k*c k) = b t*c h := by + rw [tsum_eq_single t, he] + intro k hk + by_cases hkt : t < k + · simp [hbmax k hkt] + · rw [hcmin k (by omega), mul_zero] + have hzero := hz 0 + simp only [Nat.cast_zero, sub_zero] at hzero + rw [hsingle] at hzero + exact (mul_ne_zero hbt hch) hzero + omega + + + +lemma fiber_orthogonal_order {w : ℤ → ℝ} (hw : QuadraticWeights w) + {T : Fiber →L[ℂ] Fiber} + (hT : ∀ v j, T v j = (w j / w (j-1) : ℂ) * v (j-1)) + {L : Submodule ℂ Fiber} (hinvariant : ∀ v ∈ L, T v ∈ L) + {v z : Fiber} (hv : v ∈ L) (hz : z ∈ L.orthogonal) + {i j : ℤ} (hzi : z i ≠ 0) (hvj : v j ≠ 0) : i < j := by + let b := fun k : ℤ => star (z k) * (w k:ℂ) + let c := fun k : ℤ => v k / (w k:ℂ) + have hwC (k : ℤ) : (w k:ℂ) ≠ 0 := by exact_mod_cast (ne_of_gt (hw.positive k)) + have hbi : b i ≠ 0 := mul_ne_zero (by simpa using hzi) (hwC i) + have hcj : c j ≠ 0 := div_ne_zero hvj (hwC j) + have hb (k : ℤ) : ‖b k‖ ≤ (‖z‖+1)*w k := by + dsimp [b] + rw [norm_mul, RCLike.norm_conj, Complex.norm_real, Real.norm_of_nonneg (hw.positive k).le] + apply mul_le_mul_of_nonneg_right _ (hw.positive k).le + exact (lp.norm_apply_le_norm (by norm_num : (2 : ENNReal) ≠ 0) z k).trans (by linarith) + have hc (k : ℤ) : ‖c k‖*w k ≤ ‖v‖+1 := by + dsimp [c] + rw [norm_div, Complex.norm_real, Real.norm_of_nonneg (hw.positive k).le, + div_mul_cancel₀ _ (ne_of_gt (hw.positive k))] + exact (lp.norm_apply_le_norm (by norm_num : (2 : ENNReal) ≠ 0) v k).trans (by linarith) + have hcor (r : ℕ) : (∑' k : ℤ, b k*c (k-r)) = 0 := by + calc (∑' k : ℤ, b k*c (k-r)) = inner ℂ z ((T^r) v) := by + rw [lp.inner_eq_tsum] + apply tsum_congr + intro k + rw [RCLike.inner_apply, weighted_shift_pow hw.positive hT] + dsimp [b, c] + simp only [← Complex.star_def] + ring + _ = 0 := Submodule.inner_left_of_mem_orthogonal (invariant_pow hinvariant hv r) hz + exact (quadratic_support_separation w hw).strict_order ⟨i,hbi⟩ ⟨j,hcj⟩ + (by positivity : 0 < ‖z‖+1) (by positivity : 0 < ‖v‖+1) hb hc hcor hbi hcj + + +theorem quadratic_fiber_tails (w : ℤ → ℝ) (hw : QuadraticWeights w) + (T : Fiber →L[ℂ] Fiber) + (hT : ∀ v j, T v j = (w j / w (j-1) : ℂ) * v (j-1)) + (L : Submodule ℂ Fiber) (hclosed : IsClosed (L : Set Fiber)) + (hinvariant : ∀ v ∈ L, T v ∈ L) : + L = ⊥ ∨ L = ⊤ ∨ ∃ h : ℤ, L = coordinateTail h := by + by_cases hbot : L = ⊥ + · exact Or.inl hbot + by_cases htop : L = ⊤ + · exact Or.inr (Or.inl htop) + have hOO : L.orthogonal.orthogonal = L := by + rw [Submodule.orthogonal_orthogonal_eq_closure, hclosed.submodule_topologicalClosure_eq] + have hnotOrth : L.orthogonal ≠ ⊥ := by + intro hh + rw [hh, Submodule.bot_orthogonal_eq_top] at hOO + exact htop hOO.symm + obtain ⟨z, hz, hzne⟩ := (Submodule.ne_bot_iff L.orthogonal).mp hnotOrth + obtain ⟨i, hzi⟩ := fiber_exists_coordinate hzne + obtain ⟨v, hv, hvne⟩ := (Submodule.ne_bot_iff L).mp hbot + obtain ⟨j, hvj⟩ := fiber_exists_coordinate hvne + let P := fun k : ℤ => ∃ c : Fiber, c ∈ L ∧ c k ≠ 0 + have hPnonempty : ∃ k, P k := ⟨j, v, hv, hvj⟩ + have hPbound : ∃ a : ℤ, ∀ k : ℤ, P k → a ≤ k := by + refine ⟨i+1, ?_⟩ + rintro k ⟨c, hc, hck⟩ + have hh := fiber_orthogonal_order hw hT hinvariant hc hz hzi hck + omega + obtain ⟨h, hhP, hhmin⟩ := Int.exists_least_of_bdd hPbound hPnonempty + obtain ⟨v₀, hv₀, hv₀h⟩ := hhP + refine Or.inr (Or.inr ⟨h, le_antisymm ?_ ?_⟩) + · intro c hc k hk + by_contra hck + have hh := hhmin k ⟨c, hc, hck⟩ + omega + · intro c hc + rw [← hOO] + apply (Submodule.mem_orthogonal _ c).mpr + intro u hu + rw [lp.inner_eq_tsum] + apply Eq.trans (tsum_congr (g := fun _ : ℤ => (0:ℂ)) ?_) tsum_zero + intro k + rw [RCLike.inner_apply] + by_cases hkh : k < h + · rw [hc k hkh, zero_mul] + · have huk : u k = 0 := by + by_contra hne + have hh := fiber_orthogonal_order hw hT hinvariant hv₀ hu hne hv₀h + exact hkh hh + simp [huk] + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/GlobalOperators.lean b/lean/OAI/Analysis/BackwardIntertwiners/GlobalOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..b52c94d62bccbf51a0bffbd0c2094d94a43cb375 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/GlobalOperators.lean @@ -0,0 +1,473 @@ +import OAI.Analysis.BackwardIntertwiners.BackwardWeights + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +section Fields +variable {X : Type*} [MeasurableSpace X] {μ : Measure X} + +lemma weightedPermutation_stronglyMeasurable (e : ℤ ≃ ℤ) (a : X → ℤ → ℂ) + (C : ℝ) (hC : 0 ≤ C) (ha : ∀ x j, ‖a x j‖ ≤ C) + (hm : ∀ j, Measurable (fun x => a x j)) + {f : X → Fiber} (hf : StronglyMeasurable f) : + StronglyMeasurable (fun x => fiberWeightedPermutation e (a x) C hC (ha x) (f x)) := by + apply fiberCoordinates_stronglyMeasurable + intro j + exact (hm (e j)).mul (((lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 (e j)).continuous.comp_stronglyMeasurable hf).measurable) + +lemma weightedPermutation_aestronglyMeasurable (e : ℤ ≃ ℤ) (a : X → ℤ → ℂ) + (C : ℝ) (hC : 0 ≤ C) (ha : ∀ x j, ‖a x j‖ ≤ C) + (hm : ∀ j, Measurable (fun x => a x j)) + {f : X → Fiber} (hf : AEStronglyMeasurable f μ) : + AEStronglyMeasurable (fun x => fiberWeightedPermutation e (a x) C hC (ha x) (f x)) μ := by + apply (weightedPermutation_stronglyMeasurable e a C hC ha hm hf.stronglyMeasurable_mk).aestronglyMeasurable.congr + filter_upwards [hf.ae_eq_mk] with x hx + rw [hx] + + +def scalarMultiplier (g : Lp ℂ ∞ μ) : Lp Fiber 2 μ →L[ℂ] Lp Fiber 2 μ := + LinearMap.mkContinuous + { toFun := fun f => g • f + map_add' := Lp.add_smul g + map_smul' := fun c f => (Lp.smul_comm c g f).symm } + ‖g‖ (Lp.norm_smul_le g) + +def fieldVector (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) + (f : Lp Fiber 2 μ) : Lp Fiber 2 μ := + ((Lp.memLp f).of_le_mul (hm f (Lp.aestronglyMeasurable f)) + (Filter.Eventually.of_forall fun x => + (A x).le_opNorm (f x) |>.trans (mul_le_mul_of_nonneg_right (hA x) (norm_nonneg _)))).toLp _ + +lemma fieldVector_ae (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) + (f : Lp Fiber 2 μ) : fieldVector A C hA hm f =ᵐ[μ] fun x => A x (f x) := + MemLp.coeFn_toLp _ + +lemma fieldVector_norm (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) (hC : 0 ≤ C) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) + (f : Lp Fiber 2 μ) : ‖fieldVector A C hA hm f‖ ≤ C*‖f‖ := by + calc + _ ≤ ‖(C:ℂ) • f‖ := by + apply Lp.norm_le_norm_of_ae_le + filter_upwards [fieldVector_ae A C hA hm f, Lp.coeFn_smul (C:ℂ) f] with x hx hs + rw [hx, hs, Pi.smul_apply, norm_smul, Complex.norm_real, Real.norm_of_nonneg hC] + exact (A x).le_opNorm (f x) |>.trans (mul_le_mul_of_nonneg_right (hA x) (norm_nonneg _)) + _ = C*‖f‖ := by rw [norm_smul, Complex.norm_real, Real.norm_of_nonneg hC] + +def fieldOperator (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) (hC : 0 ≤ C) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) : + Lp Fiber 2 μ →L[ℂ] Lp Fiber 2 μ := + LinearMap.mkContinuous + { toFun := fieldVector A C hA hm + map_add' := by + intro f g + apply Lp.ext + filter_upwards [fieldVector_ae A C hA hm (f+g), fieldVector_ae A C hA hm f, + fieldVector_ae A C hA hm g, Lp.coeFn_add f g, + Lp.coeFn_add (fieldVector A C hA hm f) (fieldVector A C hA hm g)] with x h₁ h₂ h₃ h₄ h₅ + simp only [h₁,h₂,h₃,h₄,h₅,Pi.add_apply,map_add] + map_smul' := by + intro c f + apply Lp.ext + filter_upwards [fieldVector_ae A C hA hm (c • f), fieldVector_ae A C hA hm f, + Lp.coeFn_smul c f, Lp.coeFn_smul c (fieldVector A C hA hm f)] with x h₁ h₂ h₃ h₄ + simp only [RingHom.id_apply, h₁,h₂,h₃,h₄,Pi.smul_apply,map_smul] } + C (fieldVector_norm A C hC hA hm) + +lemma fieldOperator_ae (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) (hC : 0 ≤ C) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) + (f : Lp Fiber 2 μ) : fieldOperator A C hC hA hm f =ᵐ[μ] fun x => A x (f x) := + fieldVector_ae A C hA hm f + +lemma fieldOperator_norm (A : X → Fiber →L[ℂ] Fiber) (C : ℝ) (hC : 0 ≤ C) + (hA : ∀ x, ‖A x‖ ≤ C) + (hm : ∀ f : X → Fiber, AEStronglyMeasurable f μ → AEStronglyMeasurable (fun x => A x (f x)) μ) : + ‖fieldOperator A C hC hA hm‖ ≤ C := + ContinuousLinearMap.opNorm_le_bound _ hC (fieldVector_norm A C hC hA hm) + +lemma scalarMultiplier_ae (g : Lp ℂ ∞ μ) (f : Lp Fiber 2 μ) : + scalarMultiplier g f =ᵐ[μ] fun x => g x • f x := Lp.coeFn_lpSMul g f +lemma scalarMultiplier_norm_le (g : Lp ℂ ∞ μ) : ‖scalarMultiplier (μ := μ) g‖ ≤ ‖g‖ := + ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg g) (Lp.norm_smul_le g) +end Fields + +abbrev GlobalHilbert := Lp Fiber 2 baseMeasure + +def OperatorInvariant {H : Type*} [NormedAddCommGroup H] [NormedSpace ℂ H] + (L : Submodule ℂ H) (T : H →L[ℂ] H) : Prop := ∀ v ∈ L, T v ∈ L + +def generatedAlgebra (S V : GlobalHilbert →L[ℂ] GlobalHilbert) : + Subalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert) := + Algebra.adjoin ℂ ({S,V} ∪ Set.range (scalarMultiplier (μ := baseMeasure))) + +def AlgebraTransitive (A : Subalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert)) : Prop := + ∀ L : Submodule ℂ GlobalHilbert, IsClosed (L : Set GlobalHilbert) → + (∀ T ∈ A, OperatorInvariant L T) → L = ⊥ ∨ L = ⊤ + + +structure DirectModelData where + Sx : Base → Fiber →L[ℂ] Fiber + S : GlobalHilbert →L[ℂ] GlobalHilbert + b : Base → ℤ → ℝ + Vx : Base → Fiber →L[ℂ] Fiber + V : GlobalHilbert →L[ℂ] GlobalHilbert + + + + +structure DirectModelProperties (D : DirectModelData) : Prop where + beta_measurable : ∀ j, Measurable (fun x => explicitBeta x j) + beta_positive : ∀ x j, 0 < explicitBeta x j + forward_coordinates : ∀ x v j, D.Sx x v j = (explicitBeta x (j-1):ℂ)*v (j-1) + forward_field : ∀ f, D.S f =ᵐ[baseMeasure] fun x => D.Sx x (f x) + fiber_lattice : ∀ x (L : Submodule ℂ Fiber), + (IsClosed (L : Set Fiber) ∧ OperatorInvariant L (D.Sx x)) ↔ + L = ⊥ ∨ L = ⊤ ∨ ∃ h : ℤ, L = coordinateTail h + S_nonzero : D.S ≠ 0 + S_norm : ‖D.S‖ = Real.exp (-10) + power_bound : ∀ n : ℕ, 1 ≤ n → ‖D.S^n‖ ≤ Real.exp (-10*(((n+1)^2/4:ℕ):ℝ)) + V_contraction : ‖D.V‖ ≤ 1 + commute : D.S * D.V = D.V * D.S + backward_measurable : ∀ j, Measurable (fun x => D.b x j) + backward_bounds : ∀ x j, 0 ≤ D.b x j ∧ D.b x j ≤ 1 + backward_coordinates : ∀ x v j, D.Vx x v j = (D.b x (j+1):ℂ)*v (j+1) + backward_field : ∀ f, ∀ᵐ x ∂baseMeasure, D.V f (odometer x) = D.Vx x (f x) + common_conull : ∃ Xstar : Set Base, MeasurableSet Xstar ∧ baseMeasure Xstarᶜ = 0 ∧ + odometer ⁻¹' Xstar = Xstar ∧ ∀ x ∈ Xstar, + (∀ j, 0 < D.b x j) ∧ + (∀ h : ℤ, ((coordinateTail h).map (D.Vx x).toLinearMap).topologicalClosure = coordinateTail (h-1)) ∧ + DenseRange (D.Vx x) + transitive : AlgebraTransitive (generatedAlgebra D.S D.V) + + + +def forwardFiber (x : Base) : Fiber →L[ℂ] Fiber := + fiberWeightedPermutation (Equiv.subRight 1) (fun j => (explicitBeta x j:ℂ)) + (Real.exp (-10)) (Real.exp_pos _).le + (fun j => by simpa only [Complex.norm_real, Real.norm_of_nonneg (explicitBeta_pos x j).le] using explicitBeta_le x j) +def backwardFiber (x : Base) : Fiber →L[ℂ] Fiber := + fiberWeightedPermutation (Equiv.addRight 1) (fun j => (backwardCoeff x j:ℂ)) 1 (by norm_num) + (fun j => by simpa only [Complex.norm_real, Real.norm_of_nonneg (backwardCoeff_bounds x j).1] using (backwardCoeff_bounds x j).2) +@[simp] lemma forwardFiber_apply (x : Base) (v : Fiber) (j : ℤ) : + forwardFiber x v j = (explicitBeta x (j-1):ℂ) * v (j-1) := rfl +@[simp] lemma backwardFiber_apply (x : Base) (v : Fiber) (j : ℤ) : + backwardFiber x v j = (backwardCoeff x (j+1):ℂ) * v (j+1) := rfl +lemma forwardFiber_norm_le (x : Base) : ‖forwardFiber x‖ ≤ Real.exp (-10) := + fiberWeightedPermutation_norm_le _ _ _ _ _ +lemma backwardFiber_norm_le (x : Base) : ‖backwardFiber x‖ ≤ 1 := + fiberWeightedPermutation_norm_le _ _ _ _ _ +lemma forwardFiber_single (x : Base) (j : ℤ) (c : ℂ) : + forwardFiber x (lp.single 2 j c) = lp.single 2 (j+1) ((explicitBeta x j:ℂ)*c) := by + ext k + rw [forwardFiber_apply] + by_cases hk : k = j+1 + · subst k + simp + · have hj : k-1 ≠ j := by omega + simp only [lp.single_apply_ne _ _ _ hk, lp.single_apply_ne _ _ _ hj, mul_zero] +lemma backwardFiber_single (x : Base) (j : ℤ) (c : ℂ) : + backwardFiber x (lp.single 2 j c) = lp.single 2 (j-1) ((backwardCoeff x j:ℂ)*c) := by + ext k + rw [backwardFiber_apply] + by_cases hk : k = j-1 + · subst k + simp + · have hj : k+1 ≠ j := by omega + simp only [lp.single_apply_ne _ _ _ hk, lp.single_apply_ne _ _ _ hj, mul_zero] +lemma forwardFiber_norm (x : Base) : ‖forwardFiber x‖ = Real.exp (-10) := by + apply le_antisymm (forwardFiber_norm_le x) + have hh := (forwardFiber x).le_opNorm (lp.single 2 0 (1:ℂ)) + rw [forwardFiber_single, explicitBeta_zero, mul_one, lp.norm_single (by norm_num : (0:ENNReal)<2), + lp.norm_single (by norm_num : (0:ENNReal)<2), norm_one, mul_one, + Complex.norm_real, Real.norm_of_nonneg (Real.exp_pos _).le] at hh + exact hh + +lemma backwardFiber_intertwines (x : Base) : + forwardFiber (odometer x) * backwardFiber x = backwardFiber x * forwardFiber x := by + ext v j + simp only [mul_apply_eq_comp, forwardFiber_apply, backwardFiber_apply, + sub_add_cancel, add_sub_cancel_right] + have hc := congrArg (fun r : ℝ => (r:ℂ)) (backwardCoeff_recurrence x j) + push_cast at hc + linear_combination -hc * v j + +lemma coordinateTail_isClosed (h : ℤ) : IsClosed (coordinateTail h : Set Fiber) := by + have he : (coordinateTail h : Set Fiber) = ⋂ j : ℤ, ⋂ _ : j < h, {v : Fiber | v j = 0} := by + ext v + change (∀ j : ℤ, j < h → v j = 0) ↔ _ + simp only [Set.mem_iInter, Set.mem_ofPred_eq] + rw [he] + exact isClosed_iInter fun j => isClosed_iInter fun _ => + isClosed_eq (lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j).continuous continuous_const +lemma forwardFiber_tail (x : Base) (h : ℤ) {v : Fiber} (hv : v ∈ coordinateTail h) : + forwardFiber x v ∈ coordinateTail h := by + intro j hj + rw [forwardFiber_apply, hv _ (by omega), mul_zero] +lemma backwardFiber_tail (x : Base) (h : ℤ) {v : Fiber} (hv : v ∈ coordinateTail h) : + backwardFiber x v ∈ coordinateTail (h-1) := by + intro j hj + rw [backwardFiber_apply, hv _ (by omega), mul_zero] +lemma single_mem_coordinateTail {h j : ℤ} (hj : h ≤ j) (c : ℂ) : + (lp.single 2 j c : Fiber) ∈ coordinateTail h := by + intro k hk + exact lp.single_apply_ne _ _ _ (by omega) + +lemma backwardFiber_tail_closure {x : Base} (hx : x ∈ goodBase) (h : ℤ) : + ((coordinateTail h).map (backwardFiber x).toLinearMap).topologicalClosure = coordinateTail (h-1) := by + apply le_antisymm + · apply Submodule.topologicalClosure_minimal _ ?_ (coordinateTail_isClosed (h-1)) + rintro _ ⟨v,hv,rfl⟩ + exact backwardFiber_tail x h hv + · intro v hv + let P := ((coordinateTail h).map (backwardFiber x).toLinearMap).topologicalClosure + have hP : IsClosed (P : Set Fiber) := Submodule.isClosed_topologicalClosure _ + apply hP.mem_of_tendsto (lp.hasSum_single (by norm_num : (2:ENNReal) ≠ ∞) v) + apply Filter.Eventually.of_forall + intro s + apply P.sum_mem + intro j _ + by_cases hj : j < h-1 + · rw [hv j hj, lp.single_zero] + exact P.zero_mem + · apply (Submodule.le_topologicalClosure ((coordinateTail h).map (backwardFiber x).toLinearMap)) + refine ⟨lp.single 2 (j+1) (v j / (backwardCoeff x (j+1):ℂ)), + single_mem_coordinateTail (by omega) _, ?_⟩ + change backwardFiber x (_) = _ + rw [backwardFiber_single, add_sub_cancel_right, mul_div_cancel₀] + exact_mod_cast ne_of_gt (backwardCoeff_pos hx (j+1)) + +lemma backwardFiber_denseRange {x : Base} (hx : x ∈ goodBase) : DenseRange (backwardFiber x) := by + intro v + have hcl : IsClosed (closure (Set.range (backwardFiber x))) := isClosed_closure + apply hcl.mem_of_tendsto (lp.hasSum_single (by norm_num : (2:ENNReal) ≠ ∞) v) + apply Filter.Eventually.of_forall + intro s + apply subset_closure + refine ⟨∑ j ∈ s, lp.single 2 (j+1) (v j / (backwardCoeff x (j+1):ℂ)), ?_⟩ + rw [map_sum] + apply Finset.sum_congr rfl + intro j _ + rw [backwardFiber_single, add_sub_cancel_right, mul_div_cancel₀] + exact_mod_cast ne_of_gt (backwardCoeff_pos hx (j+1)) + +lemma explicitExponent_distance (x : Base) (j : ℤ) : + 10*(coordinateDistance j:ℝ) ≤ explicitExponent x j := by + cases j with + | ofNat n => + have hd : coordinateDistance (n:ℤ) = (n:ℤ)+1 := by + unfold coordinateDistance + omega + change 10*(coordinateDistance (n:ℤ):ℝ) ≤ halfExponent (plusResidue x) n + rw [hd] + simpa only [Int.cast_add, Int.cast_one, Int.cast_natCast] using halfExponent_lower (plusResidue x) n + | negSucc n => + have hd : coordinateDistance (Int.negSucc n) = (n:ℤ)+1 := by + unfold coordinateDistance + omega + rw [hd] + change _ ≤ halfExponent (minusResidue x) n + simpa only [Int.cast_add, Int.cast_one, Int.cast_natCast] using halfExponent_lower (minusResidue x) n + +lemma interval_exponent_lower (x : Base) (n : ℕ) (j : ℤ) : + 10*(powerCost n:ℝ) ≤ ∑ r ∈ Finset.range n, explicitExponent x (j+(r:ℤ)) := by + have hc : (powerCost n:ℝ) ≤ ∑ r ∈ Finset.range n, (coordinateDistance (j+(r:ℤ)):ℝ) := by + exact_mod_cast sum_coordinateDistance_lower n j + calc + _ ≤ 10*(∑ r ∈ Finset.range n, (coordinateDistance (j+(r:ℤ)):ℝ)) := by linarith + _ = ∑ r ∈ Finset.range n, 10*(coordinateDistance (j+(r:ℤ)):ℝ) := by rw [Finset.mul_sum] + _ ≤ _ := Finset.sum_le_sum fun _ _ => explicitExponent_distance x _ + +lemma forwardFiber_power_input (x : Base) (n : ℕ) (v : Fiber) (j : ℤ) : + (forwardFiber x ^ n) v (j+(n:ℤ)) = + (Real.exp (-(∑ r ∈ Finset.range n, explicitExponent x (j+(r:ℤ)))):ℂ)*v j := by + induction n with + | zero => simp + | succ n ih => + rw [pow_succ', mul_apply_eq_comp, forwardFiber_apply] + have hi : j+((n+1:ℕ):ℤ)-1 = j+(n:ℤ) := by omega + rw [hi, ih, Finset.sum_range_succ] + change (Real.exp (-explicitExponent x (j+(n:ℤ))):ℂ)* + ((Real.exp (-(∑ r ∈ Finset.range n, explicitExponent x (j+(r:ℤ)))):ℂ)*v j) = _ + rw [← mul_assoc, ← Complex.ofReal_mul, ← Real.exp_add] + rw [neg_add_rev] + +lemma forwardFiber_power_norm (x : Base) (n : ℕ) : + ‖forwardFiber x ^ n‖ ≤ Real.exp (-10*(powerCost n:ℝ)) := by + let C := Real.exp (-10*(powerCost n:ℝ)) + have hC : 0 ≤ C := (Real.exp_pos _).le + apply ContinuousLinearMap.opNorm_le_bound _ (Real.exp_pos _).le + intro v + calc + _ ≤ ‖(C:ℂ) • fiberReindex (Equiv.subRight (n:ℤ)) v‖ := by + apply lp.norm_mono (by norm_num : (2:ENNReal) ≠ 0) + intro j + have hi : j = (j-(n:ℤ))+(n:ℤ) := by omega + conv_lhs => rw [hi, forwardFiber_power_input] + simp only [lp.coeFn_smul, Pi.smul_apply, norm_smul, fiberReindex_apply, Equiv.subRight_apply, + norm_mul, Complex.norm_real, Real.norm_of_nonneg (Real.exp_pos _).le, Real.norm_of_nonneg hC] + apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) + apply Real.exp_le_exp.mpr + simpa only [neg_mul] using neg_le_neg (interval_exponent_lower x n (j-(n:ℤ))) + _ = C*‖v‖ := by + rw [norm_smul, Complex.norm_real, Real.norm_of_nonneg (Real.exp_pos _).le, (fiberReindex _).norm_map] + + +lemma forwardFiber_aestronglyMeasurable (f : Base → Fiber) (hf : AEStronglyMeasurable f baseMeasure) : + AEStronglyMeasurable (fun x => forwardFiber x (f x)) baseMeasure := by + apply weightedPermutation_aestronglyMeasurable + · exact fun j => Complex.measurable_ofReal.comp (measurable_explicitBeta j) + · exact hf +lemma backwardFiber_aestronglyMeasurable (f : Base → Fiber) (hf : AEStronglyMeasurable f baseMeasure) : + AEStronglyMeasurable (fun x => backwardFiber x (f x)) baseMeasure := by + apply weightedPermutation_aestronglyMeasurable + · exact fun j => Complex.measurable_ofReal.comp (measurable_backwardCoeff j) + · exact hf + +def forwardOperator : GlobalHilbert →L[ℂ] GlobalHilbert := + fieldOperator forwardFiber (Real.exp (-10)) (Real.exp_pos _).le + forwardFiber_norm_le forwardFiber_aestronglyMeasurable +lemma forwardOperator_ae (f : GlobalHilbert) : + forwardOperator f =ᵐ[baseMeasure] fun x => forwardFiber x (f x) := + fieldOperator_ae _ _ _ _ _ f +lemma forwardOperator_norm_le : ‖forwardOperator‖ ≤ Real.exp (-10) := + fieldOperator_norm _ _ _ _ _ + +def inverseOdometer (x : Base) : Base := (show PadicInt 2 from x)-1 +@[simp] lemma inverseOdometer_odometer (x : Base) : inverseOdometer (odometer x) = x := by + change ((show PadicInt 2 from x)+1)-1 = _ + exact add_sub_cancel_right _ _ +@[simp] lemma odometer_inverseOdometer (x : Base) : odometer (inverseOdometer x) = x := by + change ((show PadicInt 2 from x)-1)+1 = _ + exact sub_add_cancel _ _ +lemma inverseOdometer_preserving : MeasurePreserving inverseOdometer baseMeasure baseMeasure := by + have hh := measurePreserving_completion (α := PadicInt 2) (measurePreserving_add_right baseHaar (-1)) + have he : inverseOdometer = (show Base → Base from fun x : PadicInt 2 => x + (-1)) := by + funext x + exact @sub_eq_add_neg (PadicInt 2) _ (show PadicInt 2 from x) 1 + rw [he] + exact hh + +def odometerMeasurableEquiv : Base ≃ᵐ Base where + toFun := odometer + invFun := inverseOdometer + left_inv := inverseOdometer_odometer + right_inv := odometer_inverseOdometer + measurable_toFun := odometer_ergodic.measurable + measurable_invFun := inverseOdometer_preserving.measurable + +def backwardFieldOperator : GlobalHilbert →L[ℂ] GlobalHilbert := + fieldOperator backwardFiber 1 (by norm_num) backwardFiber_norm_le backwardFiber_aestronglyMeasurable + +def backwardOperator : GlobalHilbert →L[ℂ] GlobalHilbert := + (Lp.compMeasurePreservingₗᵢ ℂ inverseOdometer inverseOdometer_preserving).toContinuousLinearMap.comp backwardFieldOperator + +lemma backwardOperator_ae_inverse (f : GlobalHilbert) : + backwardOperator f =ᵐ[baseMeasure] fun x => backwardFiber (inverseOdometer x) (f (inverseOdometer x)) := by + have h₁ := Lp.coeFn_compMeasurePreserving (backwardFieldOperator f) inverseOdometer_preserving + have h₂ := (fieldOperator_ae backwardFiber 1 (by norm_num) backwardFiber_norm_le + backwardFiber_aestronglyMeasurable f).comp_tendsto inverseOdometer_preserving.quasiMeasurePreserving.tendsto_ae + exact h₁.trans h₂ + +lemma backwardOperator_ae (f : GlobalHilbert) : + ∀ᵐ x ∂baseMeasure, backwardOperator f (odometer x) = backwardFiber x (f x) := by + filter_upwards [(backwardOperator_ae_inverse f).comp_tendsto + odometer_ergodic.quasiMeasurePreserving.tendsto_ae] with x hx + simpa only [Function.comp_def,inverseOdometer_odometer] using hx + +lemma backwardOperator_norm : ‖backwardOperator‖ ≤ 1 := by + apply ContinuousLinearMap.opNorm_le_bound _ (by norm_num) + intro f + change ‖Lp.compMeasurePreserving inverseOdometer inverseOdometer_preserving (backwardFieldOperator f)‖ ≤ _ + rw [Lp.norm_compMeasurePreserving] + exact fieldVector_norm backwardFiber 1 (by norm_num) backwardFiber_norm_le backwardFiber_aestronglyMeasurable f + +lemma forward_backward_commute : forwardOperator * backwardOperator = backwardOperator * forwardOperator := by + ext1 f + apply Lp.ext + filter_upwards [forwardOperator_ae (backwardOperator f), backwardOperator_ae_inverse f, + backwardOperator_ae_inverse (forwardOperator f), + (forwardOperator_ae f).comp_tendsto inverseOdometer_preserving.quasiMeasurePreserving.tendsto_ae] with x h₁ h₂ h₃ h₄ + change forwardOperator (backwardOperator f) x = backwardOperator (forwardOperator f) x + rw [h₁,h₂,h₃] + + dsimp only [Function.comp_def] at h₄ + rw [h₄] + have hh := congrArg (fun A : Fiber →L[ℂ] Fiber => A (f (inverseOdometer x))) (backwardFiber_intertwines (inverseOdometer x)) + simpa only [mul_apply_eq_comp, odometer_inverseOdometer] using hh + +lemma forward_scalar_commute (g : Lp ℂ ∞ baseMeasure) : + forwardOperator * scalarMultiplier g = scalarMultiplier g * forwardOperator := by + ext1 f + apply Lp.ext + filter_upwards [forwardOperator_ae (scalarMultiplier g f), scalarMultiplier_ae g f, + scalarMultiplier_ae g (forwardOperator f), forwardOperator_ae f] with x h₁ h₂ h₃ h₄ + change forwardOperator (scalarMultiplier g f) x = scalarMultiplier g (forwardOperator f) x + simp only [h₁,h₂,h₃,h₄,map_smul] + +def constantBasis (j : ℤ) : GlobalHilbert := Lp.const 2 baseMeasure (lp.single 2 j (1:ℂ)) +lemma constantBasis_norm (j : ℤ) : ‖constantBasis j‖ = 1 := by + rw [constantBasis, Lp.norm_const 2 baseMeasure _ (by norm_num), lp.norm_single (by norm_num : (0:ENNReal)<2)] + simp +lemma constantBasis_ae (j : ℤ) : constantBasis j =ᵐ[baseMeasure] fun _ => lp.single 2 j (1:ℂ) := + Lp.coeFn_const _ _ _ +lemma forwardOperator_constantBasis_zero : + forwardOperator (constantBasis 0) = (Real.exp (-10):ℂ) • constantBasis 1 := by + apply Lp.ext + filter_upwards [forwardOperator_ae (constantBasis 0), constantBasis_ae 0, constantBasis_ae 1, + Lp.coeFn_smul (Real.exp (-10):ℂ) (constantBasis 1)] with x h₁ h₂ h₃ h₄ + rw [h₁,h₂,h₄,Pi.smul_apply,h₃,forwardFiber_single,explicitBeta_zero,mul_one] + rw [← lp.single_smul] + simp +lemma forwardOperator_norm : ‖forwardOperator‖ = Real.exp (-10) := by + apply le_antisymm forwardOperator_norm_le + have h := forwardOperator.le_opNorm (constantBasis 0) + rw [forwardOperator_constantBasis_zero, norm_smul, constantBasis_norm, constantBasis_norm, + mul_one, mul_one, Complex.norm_real, Real.norm_of_nonneg (Real.exp_pos _).le] at h + exact h +lemma forwardOperator_ne_zero : forwardOperator ≠ 0 := by + intro h + have hh := forwardOperator_norm + rw [h, norm_zero] at hh + exact (Real.exp_ne_zero (-10)) hh.symm + +lemma forwardOperator_power_ae (n : ℕ) (f : GlobalHilbert) : + (forwardOperator^n) f =ᵐ[baseMeasure] fun x => (forwardFiber x ^ n) (f x) := by + induction n with + | zero => filter_upwards [] with x; rfl + | succ n ih => + rw [pow_succ', mul_apply_eq_comp] + filter_upwards [forwardOperator_ae ((forwardOperator^n) f), ih] with x h₁ h₂ + simp only [h₁,h₂,pow_succ',mul_apply_eq_comp] +lemma forwardOperator_power_norm (n : ℕ) : + ‖forwardOperator^n‖ ≤ Real.exp (-10*(powerCost n:ℝ)) := by + let C := Real.exp (-10*(powerCost n:ℝ)) + have hC : 0 ≤ C := (Real.exp_pos _).le + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro f + calc + _ ≤ ‖(C:ℂ) • f‖ := by + apply Lp.norm_le_norm_of_ae_le + filter_upwards [forwardOperator_power_ae n f, Lp.coeFn_smul (C:ℂ) f] with x h₁ h₂ + rw [h₁,h₂,Pi.smul_apply,norm_smul,Complex.norm_real,Real.norm_of_nonneg hC] + exact (forwardFiber x ^ n).le_opNorm (f x) |>.trans + (mul_le_mul_of_nonneg_right (forwardFiber_power_norm x n) (norm_nonneg _)) + _ = C*‖f‖ := by rw [norm_smul,Complex.norm_real,Real.norm_of_nonneg hC] + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/HaarBase.lean b/lean/OAI/Analysis/BackwardIntertwiners/HaarBase.lean new file mode 100644 index 0000000000000000000000000000000000000000..a02027272ab87fa4faf9ec0c0ab9ba14c7c346cd --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/HaarBase.lean @@ -0,0 +1,195 @@ +import OAI.Analysis.BackwardIntertwiners.ExplicitWeights + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +instance padicBorel : MeasurableSpace (PadicInt 2) := borel _ +instance padicBorelSpace : BorelSpace (PadicInt 2) := ⟨rfl⟩ + +def baseHaar : Measure (PadicInt 2) := Measure.addHaarMeasure ⊤ +instance baseHaar_probability : IsProbabilityMeasure baseHaar := by + constructor + exact Measure.addHaarMeasure_self +instance baseHaar_regular : baseHaar.Regular := inferInstanceAs ((Measure.addHaarMeasure ⊤).Regular) +instance baseHaar_addHaar : baseHaar.IsAddHaarMeasure := + inferInstanceAs ((Measure.addHaarMeasure ⊤).IsAddHaarMeasure) + +def odometerBorel (x : PadicInt 2) : PadicInt 2 := x + 1 +lemma odometerBorel_ergodic : Ergodic odometerBorel baseHaar := by + have hd : DenseRange (fun n : ℤ => n • (1 : PadicInt 2)) := by + simpa only [zsmul_one] using (PadicInt.denseRange_intCast (p := 2)) + have he : (fun x : PadicInt 2 => 1+x) = odometerBorel := funext fun x => add_comm 1 x + rw [← he] + exact ergodic_add_left_of_denseRange_zsmul hd baseHaar + +lemma continuous_twoResidue (m : ℕ) : Continuous (PadicInt.toZModPow (p := 2) m) := by + apply IsLocallyConstant.continuous + rw [IsLocallyConstant.iff_eventually_eq] + intro x + have hp : 0 < (2:ℝ)^(-(m:ℤ)) := zpow_pos (by norm_num) _ + filter_upwards [Metric.ball_mem_nhds x hp] with y hy + have hnorm : ‖y-x‖ ≤ (2:ℝ)^(-(m:ℤ)) := (by simpa [dist_eq_norm] using hy : ‖y-x‖ < _).le + have hmem := (PadicInt.norm_le_pow_iff_mem_span_pow (y-x) m).mp hnorm + rw [← PadicInt.ker_toZModPow, RingHom.mem_ker, map_sub, sub_eq_zero] at hmem + exact hmem + +def twoResidue (m : ℕ) (x : PadicInt 2) : ℕ := (PadicInt.toZModPow m x).val +lemma twoResidue_lt (m : ℕ) (x : PadicInt 2) : twoResidue m x < 2^m := ZMod.val_lt _ +lemma measurable_twoResidue (m : ℕ) : Measurable (twoResidue m) := + (measurable_of_countable (f := ZMod.val)).comp (continuous_twoResidue m).measurable + +lemma baseHaar_singleton_eq (x y : PadicInt 2) : baseHaar {x} = baseHaar {y} := by + have he : (fun z : PadicInt 2 => (y-x)+z) ⁻¹' {y} = {x} := by + ext z + change (y-x)+z = y ↔ z = x + constructor + · intro h + have hh := congrArg (fun v : PadicInt 2 => v-(y-x)) h + abel_nf at hh + exact hh + · rintro rfl + abel + rw [← he] + exact measure_preimage_add baseHaar (y-x) {y} + +instance baseHaar_nullSingleton : NullSingletonClass baseHaar := by + constructor + intro x + by_contra hx + have hd : Pairwise (fun i j : ℕ => Disjoint ({(i:PadicInt 2)} : Set (PadicInt 2)) {(j:PadicInt 2)}) := by + intro i j hij + apply Set.disjoint_singleton.mpr + exact_mod_cast hij + have hs : (∑' _n : ℕ, baseHaar {x}) ≤ 1 := calc + _ = ∑' n : ℕ, baseHaar {(n:PadicInt 2)} := tsum_congr fun n => baseHaar_singleton_eq _ _ + _ = baseHaar (⋃ n : ℕ, {(n:PadicInt 2)}) := (measure_iUnion hd (fun _ => measurableSet_singleton _)).symm + _ ≤ 1 := by simpa using (measure_mono (Set.subset_univ _) : baseHaar _ ≤ baseHaar Set.univ) + rw [ENNReal.tsum_const_eq_top_of_ne_zero hx] at hs + exact (not_le_of_gt ENNReal.one_lt_top) hs + + + +lemma measurePreserving_completion {α : Type*} [MeasurableSpace α] {μ : Measure α} + {f : α → α} (hf : MeasurePreserving f μ μ) : + @MeasurePreserving (NullMeasurableSpace α μ) (NullMeasurableSpace α μ) _ _ + f μ.completion μ.completion := by + have hm : @Measurable (NullMeasurableSpace α μ) (NullMeasurableSpace α μ) _ _ f := by + intro s hs + change NullMeasurableSet (f ⁻¹' s) μ + exact NullMeasurableSet.preimage (μb := μ) (show NullMeasurableSet (show Set α from s) μ from hs) hf.quasiMeasurePreserving + refine ⟨hm, ?_⟩ + apply Measure.ext + intro s hs + rw [Measure.map_apply hm hs] + exact hf.measure_preimage hs + +lemma ergodic_completion {α : Type*} [MeasurableSpace α] {μ : Measure α} + {f : α → α} (hf : Ergodic f μ) : + @Ergodic (NullMeasurableSpace α μ) _ f μ.completion := by + refine ⟨measurePreserving_completion hf.toMeasurePreserving, ?_⟩ + constructor + intro s hs he + exact hf.quasiErgodic.aeconst_set₀ hs (Filter.EventuallyEq.of_eq he) + + +abbrev Base := NullMeasurableSpace (PadicInt 2) baseHaar +abbrev baseMeasure : Measure Base := baseHaar.completion +instance base_probability : IsProbabilityMeasure baseMeasure := ⟨measure_univ (μ := baseHaar)⟩ +instance base_nullSingleton : NullSingletonClass baseMeasure := by + constructor + intro x + change baseHaar { (show PadicInt 2 from x) } = 0 + exact measure_singleton _ +instance base_measurableSingleton : MeasurableSingletonClass Base := by + constructor + intro x + exact measurableSet_of_null (μ := baseMeasure) (measure_singleton x) + +def odometer : Base → Base := odometerBorel +lemma odometer_ergodic : Ergodic odometer baseMeasure := by + change @Ergodic (NullMeasurableSpace (PadicInt 2) baseHaar) _ odometerBorel baseHaar.completion + exact ergodic_completion (α := PadicInt 2) odometerBorel_ergodic + +def residue (m : ℕ) (x : Base) : ℕ := twoResidue m x +lemma residue_lt (m : ℕ) (x : Base) : residue m x < 2^m := twoResidue_lt m x +lemma measurable_residue (m : ℕ) : Measurable (residue m) := + (measurable_twoResidue m).nullMeasurable.measurable' + + + +def goodBase : Set Base := (Set.range (fun n : ℤ => (show Base from (n : PadicInt 2))))ᶜ +lemma measurableSet_goodBase : MeasurableSet goodBase := by + apply MeasurableSet.compl + exact (Set.countable_range _).measurableSet +lemma ae_goodBase : ∀ᵐ x ∂baseMeasure, x ∈ goodBase := + (Set.countable_range (fun n : ℤ => (show Base from (n : PadicInt 2)))).ae_notMem baseMeasure +lemma goodBase_odometer (x : Base) : odometer x ∈ goodBase ↔ x ∈ goodBase := by + change ((show PadicInt 2 from x)+1:PadicInt 2) ∉ Set.range (Int.cast : ℤ → PadicInt 2) ↔ + x ∉ Set.range (Int.cast : ℤ → PadicInt 2) + apply not_congr + constructor + · rintro ⟨n, hn⟩ + refine ⟨n-1, ?_⟩ + push_cast + rw [hn] + change ((show PadicInt 2 from x)+1)-1 = (show PadicInt 2 from x) + exact add_sub_cancel_right _ _ + · rintro ⟨n, rfl⟩ + exact ⟨n+1, by push_cast; rfl⟩ + +lemma zmod_val_neg_one {N : ℕ} (hN : 0 < N) : (-1 : ZMod N).val = N-1 := by + obtain ⟨n, rfl⟩ := Nat.exists_eq_succ_of_ne_zero (Nat.ne_of_gt hN) + simp [ZMod.val_neg_one] + +lemma residue_exceptional_iff (m : ℕ) (x : Base) : + residue m x = 2^m-1 ↔ PadicInt.toZModPow m x = (-1 : ZMod (2^m)) := by + change (PadicInt.toZModPow m x).val = _ ↔ _ + rw [← zmod_val_neg_one (pow_pos (by norm_num : 0 < 2) m)] + exact (ZMod.val_injective (2^m)).eq_iff + +lemma goodBase_eventually_nonexceptional {x : Base} (hx : x ∈ goodBase) : + ∃ M : ℕ, ∀ m ≥ M, residue m x ≠ 2^m-1 := by + have hx' : (show PadicInt 2 from x) ≠ -1 := by + intro h + apply hx + refine ⟨-1, ?_⟩ + change ((-1:ℤ):PadicInt 2) = (show PadicInt 2 from x) + simpa using h.symm + have hex : ∃ M, PadicInt.toZModPow M x ≠ PadicInt.toZModPow M (-1:PadicInt 2) := by + by_contra! h + exact hx' (PadicInt.ext_of_toZModPow.mp h) + obtain ⟨M, hM⟩ := hex + refine ⟨M, fun m hm he => hM ?_⟩ + have heq := (residue_exceptional_iff m x).mp he + have hc := congrArg (ZMod.castHom (pow_dvd_pow 2 hm) (ZMod (2^M))) heq + change ZMod.cast (PadicInt.toZModPow m (show PadicInt 2 from x)) = _ at hc + rw [PadicInt.cast_toZModPow M m hm] at hc + simpa only [map_neg, map_one] using hc + +lemma residue_step {m : ℕ} (hm : 1 ≤ m) (x : Base) : + residue m (odometer x) = if residue m x = 2^m-1 then 0 else residue m x + 1 := by + have hN' : 2 ≤ 2^m := by simpa using Nat.pow_le_pow_right (by norm_num : 0 < 2) hm + have hN : 1 < 2^m := by omega + have : Fact (1 < 2^m) := ⟨hN⟩ + change ((PadicInt.toZModPow m) ((show PadicInt 2 from x)+1)).val = _ + rw [map_add, map_one, ZMod.val_add, ZMod.val_one] + change (residue m x + 1) % 2^m = _ + have hr := residue_lt m x + split_ifs with h + · have he : residue m x+1 = 2^m := by omega + simp [he] + · exact Nat.mod_eq_of_lt (by omega) + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/HilbertClassification.lean b/lean/OAI/Analysis/BackwardIntertwiners/HilbertClassification.lean new file mode 100644 index 0000000000000000000000000000000000000000..64ec6fb55c07dbe7baf8f629934c17ca6ee429bf --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/HilbertClassification.lean @@ -0,0 +1,101 @@ +import OAI.Analysis.BackwardIntertwiners.ModelProperties + +namespace OAI + +namespace Hyperinvariant233 +open Filter +open scoped Topology +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + + +def commutant (T : H →L[ℂ] H) : Subalgebra ℂ (H →L[ℂ] H) := + Subalgebra.centralizer ℂ ({T} : Set (H →L[ℂ] H)) + + +def TransitiveCommutant (T : H →L[ℂ] H) : Prop := + ∀ K : Submodule ℂ H, IsClosed (K : Set H) → + (∀ A : H →L[ℂ] H, A * T = T * A → ∀ x ∈ K, A x ∈ K) → + K = ⊥ ∨ K = ⊤ + + +@[instance_reducible] +def strongOperatorTopology : TopologicalSpace (H →L[ℂ] H) := + TopologicalSpace.induced (fun A : H →L[ℂ] H => (fun x : H => A x)) inferInstance + + +def MainClaim : Prop := + ∃ T : H →L[ℂ] H, T ≠ 0 ∧ + Tendsto (fun n : ℕ => ‖T ^ n‖ ^ (1 / (n : ℝ))) atTop (𝓝 0) ∧ + TransitiveCommutant T + + +def FullClaim : Prop := + ∃ T : H →L[ℂ] H, T ≠ 0 ∧ + Tendsto (fun n : ℕ => ‖T ^ n‖ ^ (1 / (n : ℝ))) atTop (𝓝 0) ∧ + TransitiveCommutant T ∧ commutant T ≠ ⊤ ∧ + @IsClosed (H →L[ℂ] H) strongOperatorTopology (commutant T : Set (H →L[ℂ] H)) + +end Hyperinvariant233 + + +namespace Hyperinvariant233 +open Submodule TopologicalSpace +universe u v +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + [CompleteSpace H] [SeparableSpace H] + + +theorem orthonormal_subtype_countable (w : Set H) + (hw : Orthonormal ℂ (Subtype.val : w → H)) : Countable w := by + classical + let : DiscreteTopology w := discreteTopology_iff_isOpen_singleton.mpr (by + intro i + have ho : IsOpen {j : w | (1 / 2 : ℝ) < ‖inner ℂ (i : H) (j : H)‖} := + isOpen_lt continuous_const (continuous_const.inner continuous_subtype_val).norm + have he : {j : w | (1 / 2 : ℝ) < ‖inner ℂ (i : H) (j : H)‖} = {i} := by + ext j + rw [Set.mem_ofPred_eq, orthonormal_iff_ite.mp hw i j] + by_cases hij : i = j <;> norm_num [hij, eq_comm] + rwa [he] at ho) + exact separableSpace_iff_countable.mp inferInstance + + + +theorem exists_nat_hilbertBasis (hInf : ¬FiniteDimensional ℂ H) : + Nonempty (HilbertBasis ℕ ℂ H) := by + classical + obtain ⟨w, b, hb⟩ := exists_hilbertBasis ℂ H + have hw : Orthonormal ℂ (Subtype.val : w → H) := by + simpa only [hb] using b.orthonormal + let : Countable w := orthonormal_subtype_countable w hw + let : Infinite w := by + refine not_finite_iff_infinite.mp ?_ + intro hfin + let : Finite w := hfin + let : Fintype w := Fintype.ofFinite w + exact hInf (Module.Finite.of_basis b.toOrthonormalBasis.toBasis) + let e : ℕ ≃ w := Classical.choice (inferInstance : Nonempty (ℕ ≃ w)) + have ho : Orthonormal ℂ (b ∘ e) := b.orthonormal.comp e e.injective + have hr : Set.range (b ∘ e) = Set.range b := by + ext x + constructor + · rintro ⟨n, rfl⟩ + exact ⟨e n, rfl⟩ + · rintro ⟨i, rfl⟩ + exact ⟨e.symm i, by simp⟩ + exact ⟨HilbertBasis.mk ho (by rw [hr, b.dense_span])⟩ + + +theorem nonempty_linearIsometryEquiv + {K : Type v} [NormedAddCommGroup K] [InnerProductSpace ℂ K] + [CompleteSpace K] [SeparableSpace K] + (hH : ¬FiniteDimensional ℂ H) (hK : ¬FiniteDimensional ℂ K) : + Nonempty (H ≃ₗᵢ[ℂ] K) := by + obtain ⟨bH⟩ := exists_nat_hilbertBasis hH + obtain ⟨bK⟩ := exists_nat_hilbertBasis hK + exact ⟨bH.repr.trans bK.repr.symm⟩ + +end Hyperinvariant233 + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ModelProperties.lean b/lean/OAI/Analysis/BackwardIntertwiners/ModelProperties.lean new file mode 100644 index 0000000000000000000000000000000000000000..15781e2242372244755dec4cd126e8319da82ce1 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ModelProperties.lean @@ -0,0 +1,133 @@ +import OAI.Analysis.BackwardIntertwiners.ProductSymbols + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +attribute [local instance] realOperatorTower realOperatorCommute complexNormalCalculus complexClosedCalculus realSelfAdjointCalculus + +open InnerProductSpace ContinuousLinearMap + + +structure OrdinaryStructuralProperties (D : DirectModelData) : Prop where + tails : ∀ h : ℤ, ∃ L : Submodule ℂ GlobalHilbert, + (∀ f : GlobalHilbert, f ∈ L ↔ ∀ᵐ x ∂baseMeasure, f x ∈ coordinateTail h) ∧ + IsClosed (L : Set GlobalHilbert) ∧ L ≠ ⊥ ∧ L ≠ ⊤ ∧ + OperatorInvariant L D.S ∧ ¬OperatorInvariant L D.V + fiber_compact : ∀ x : Base, IsCompactOperator (D.Sx x) + global_not_compact : ¬IsCompactOperator D.S + multiplier_witness : ∃ Q : GlobalHilbert →L[ℂ] GlobalHilbert, + IsStarProjection Q ∧ + (∀ f : GlobalHilbert, Q f =ᵐ[baseMeasure] fun x => lp.single 2 0 (f x 0)) ∧ + Q * D.S ≠ D.S * Q ∧ + (∀ g : Lp ℂ ∞ baseMeasure, Q * scalarMultiplier g = scalarMultiplier g * Q) ∧ + Q ∉ Set.range (scalarMultiplier (μ:=baseMeasure)) + + + + +structure PolarFamilyProperties (D : DirectModelData) + (U : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) + (A : ℤ → GlobalHilbert →L[ℂ] GlobalHilbert) : Prop where + unitary : star (U : GlobalHilbert →L[ℂ] GlobalHilbert) = + ((U⁻¹ : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) : GlobalHilbert →L[ℂ] GlobalHilbert) + unitary_coordinates : ∀ f : GlobalHilbert, ∀ᵐ x ∂baseMeasure, ∀ j : ℤ, + (U : GlobalHilbert →L[ℂ] GlobalHilbert) f x j = f x (j-1) + modulus : A 0 = CFC.sqrt (star D.S * D.S) + polar : D.S = (U : GlobalHilbert →L[ℂ] GlobalHilbert) * A 0 + injective : Function.Injective (A 0) + dense_range : DenseRange (A 0) + conjugates : ∀ n : ℤ, A n = + ((U^(-n) : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) : GlobalHilbert →L[ℂ] GlobalHilbert) * + A 0 * ((U^n : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) : GlobalHilbert →L[ℂ] GlobalHilbert) + diagonal : ∀ n : ℤ, ∀ f : GlobalHilbert, ∀ᵐ x ∂baseMeasure, ∀ j : ℤ, + A n f x j = (explicitBeta x (j+n):ℂ) * f x j + finite_atomic : ∀ F : Finset ℤ, AtomicAlgebra (strongGenerated (A '' (F : Set ℤ))) + modulus_pure_point : PurePointResolution (A 0) + full_multiplication : ∀ T : GlobalHilbert →L[ℂ] GlobalHilbert, + T ∈ strongGenerated (Set.range A) ↔ IsProductMultiplier T + abelian : ∀ T ∈ strongGenerated (Set.range A), ∀ R ∈ strongGenerated (Set.range A), T*R=R*T + diffuse : DiffuseAlgebra (strongGenerated (Set.range A)) + not_contained_in_commutant : ∃ T ∈ strongGenerated (Set.range A), T * D.S ≠ D.S * T + +def PolarStructuralProperties (D : DirectModelData) : Prop := + ∃ (U : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) + (A : ℤ → GlobalHilbert →L[ℂ] GlobalHilbert), PolarFamilyProperties D U A + + +lemma coordinateTail_eq_closedSpan (h : ℤ) : + coordinateTail h = (Submodule.span ℂ + (Set.range (fun j : {j : ℤ // h ≤ j} => (lp.single 2 j.val (1:ℂ) : Fiber)))).topologicalClosure := by + let P := Submodule.span ℂ (Set.range (fun j : {j : ℤ // h ≤ j} => (lp.single 2 j.val (1:ℂ) : Fiber))) + apply le_antisymm + · intro v hv + apply (Submodule.isClosed_topologicalClosure P).mem_of_tendsto + (lp.hasSum_single (by norm_num : (2:ENNReal) ≠ ∞) v) + apply Eventually.of_forall + intro s + apply P.topologicalClosure.sum_mem + intro j _ + by_cases hj : j < h + · rw [hv j hj,lp.single_zero] + exact P.topologicalClosure.zero_mem + · apply Submodule.le_topologicalClosure + have hg : (lp.single 2 j (1:ℂ) : Fiber) ∈ P := + Submodule.subset_span ⟨⟨j,by omega⟩,rfl⟩ + simpa only [←lp.single_smul,smul_eq_mul,mul_one] using P.smul_mem (v j) hg + · apply Submodule.topologicalClosure_minimal _ ?_ (coordinateTail_isClosed h) + apply Submodule.span_le.mpr + rintro v ⟨j,rfl⟩ + exact single_mem_coordinateTail j.property 1 + +lemma explicitDirectModel_ordinary : OrdinaryStructuralProperties explicitDirectModel where + tails h := ⟨globalTail h, fun f => mem_globalTail h f, + globalTail_closed h,globalTail_nonzero h,globalTail_proper h, + globalTail_forward h,globalTail_not_backward h⟩ + fiber_compact := forwardFiber_compact + global_not_compact := forwardOperator_not_compact + multiplier_witness := ⟨sliceProjection 0, sliceProjection_isStarProjection 0, + sliceProjection_ae 0,sliceProjection_zero_not_commute, + sliceProjection_scalar_commute 0,sliceProjection_zero_not_scalar⟩ + +lemma explicitDirectModel_polarFamily : PolarFamilyProperties explicitDirectModel shiftUnit polarDiagonal where + unitary := coordinateShift_star 1 + unitary_coordinates := coordinateShift_ae 1 + modulus := polar_modulus.symm + polar := forward_polar_factor + injective := polarDiagonal_injective + dense_range := polarDiagonal_denseRange + conjugates n := by + rw [shiftUnit_zpow,shiftUnit_zpow] + exact (polarDiagonal_conjugate n).symm + diagonal := polarDiagonal_ae + finite_atomic := finitePolarAlgebra_atomic + modulus_pure_point := polarDiagonal_purePoint + full_multiplication := polarAlgebra_mem_iff_productMultiplier + abelian := fun _ hT _ hR => polarAlgebra_commutative hT hR + diffuse := polarAlgebra_diffuse + not_contained_in_commutant := ⟨polarDiagonal 0,polarDiagonal_mem 0,polarDiagonal_not_commute⟩ + + + + +theorem direct_model_complete : ∃ D : DirectModelData, + DirectModelProperties D ∧ OrdinaryStructuralProperties D ∧ PolarStructuralProperties D := by + exact ⟨explicitDirectModel,explicitDirectModel_properties, + explicitDirectModel_ordinary,shiftUnit,polarDiagonal,explicitDirectModel_polarFamily⟩ + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/OperatorTransport.lean b/lean/OAI/Analysis/BackwardIntertwiners/OperatorTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..98b52bbfd8388f37ea31c0b108e73e484b86e94c --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/OperatorTransport.lean @@ -0,0 +1,157 @@ +import OAI.Analysis.BackwardIntertwiners.HilbertClassification + +namespace OAI + +namespace Hyperinvariant233 +open Filter +open scoped Topology +universe u v +variable {H : Type u} {K : Type v} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem norm_conjugate_le (e : H ≃ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : + ‖e.conjStarAlgEquiv T‖ ≤ ‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + change ‖e (T (e.symm x))‖ ≤ ‖T‖ * ‖x‖ + rw [e.norm_map] + simpa only [e.symm.norm_map] using T.le_opNorm (e.symm x) + +theorem norm_conjugate (e : H ≃ₗᵢ[ℂ] K) (T : H →L[ℂ] H) : + ‖e.conjStarAlgEquiv T‖ = ‖T‖ := by + apply le_antisymm (norm_conjugate_le e T) + have he : e.symm.conjStarAlgEquiv (e.conjStarAlgEquiv T) = T := by + ext x + simp only [LinearIsometryEquiv.conjStarAlgEquiv_apply_apply, + LinearIsometryEquiv.symm_symm, LinearIsometryEquiv.symm_apply_apply] + have h := norm_conjugate_le e.symm (e.conjStarAlgEquiv T) + rwa [he] at h + + +theorem transitiveCommutant_conjugate (e : H ≃ₗᵢ[ℂ] K) (T : H →L[ℂ] H) + (hT : TransitiveCommutant T) : TransitiveCommutant (e.conjStarAlgEquiv T) := by + intro W hW hInv + let U : Submodule ℂ H := W.comap e.toLinearMap + have hU : IsClosed (U : Set H) := hW.preimage e.continuous + have hUI : ∀ A : H →L[ℂ] H, A * T = T * A → ∀ x ∈ U, A x ∈ U := by + intro A hA x hx + change e (A x) ∈ W + have hc : e.conjStarAlgEquiv A * e.conjStarAlgEquiv T = + e.conjStarAlgEquiv T * e.conjStarAlgEquiv A := by + simpa only [map_mul] using congrArg e.conjStarAlgEquiv hA + have hm := hInv (e.conjStarAlgEquiv A) hc (e x) hx + simpa using hm + rcases hT U hU hUI with hz | ho + · left + apply le_antisymm _ bot_le + intro y hy + have hx : e.symm y ∈ U := by change e (e.symm y) ∈ W; simpa using hy + rw [hz] at hx + have hzero : e.symm y = 0 := hx + have := congrArg e hzero + simpa using this + · right + apply le_antisymm le_top + intro y _ + have hx : e.symm y ∈ U := by rw [ho]; trivial + change e (e.symm y) ∈ W at hx + simpa using hx + + +theorem mainClaim_transport (e : H ≃ₗᵢ[ℂ] K) (h : MainClaim (H := H)) : + MainClaim (H := K) := by + obtain ⟨T, hT0, hq, ht⟩ := h + refine ⟨e.conjStarAlgEquiv T, ?_, ?_, transitiveCommutant_conjugate e T ht⟩ + · exact fun hzero => hT0 (e.conjStarAlgEquiv.injective (by simpa using hzero)) + · have he : (fun n : ℕ => ‖(e.conjStarAlgEquiv T) ^ n‖ ^ (1 / (n : ℝ))) = + (fun n : ℕ => ‖T ^ n‖ ^ (1 / (n : ℝ))) := by + funext n + rw [← map_pow, norm_conjugate] + rwa [he] + +end Hyperinvariant233 + + +namespace Hyperinvariant233 +open Filter +open scoped Topology +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] + + +theorem mem_commutant_iff (T A : H →L[ℂ] H) : + A ∈ commutant T ↔ A * T = T * A := by + simp only [commutant, Subalgebra.mem_centralizer_iff, Set.mem_singleton_iff, forall_eq] + exact eq_comm + +variable [completeSpace : CompleteSpace H] + + + +omit completeSpace in +theorem commutant_isClosed_strong [CompleteSpace H] (T : H →L[ℂ] H) : + @IsClosed (H →L[ℂ] H) strongOperatorTopology (commutant T : Set (H →L[ℂ] H)) := by + let : TopologicalSpace (H →L[ℂ] H) := strongOperatorTopology + have heval : ∀ x : H, Continuous (fun A : H →L[ℂ] H => A x) := by + intro x + exact (continuous_apply x).comp continuous_induced_dom + have hset : (commutant T : Set (H →L[ℂ] H)) = + ⋂ x : H, {A : H →L[ℂ] H | A (T x) = T (A x)} := by + ext A + simp only [Set.mem_iInter, Set.mem_ofPred_eq, SetLike.mem_coe, mem_commutant_iff] + constructor + · intro h x + exact congrArg (fun B : H →L[ℂ] H => B x) h + · intro h + ext x + exact h x + rw [hset] + exact isClosed_iInter (fun x => isClosed_eq (heval (T x)) (T.continuous.comp (heval x))) + + + +omit completeSpace in +theorem scalar_of_commutant_top [CompleteSpace H] (T : H →L[ℂ] H) (h : commutant T = ⊤) : + ∃ c : ℂ, algebraMap ℂ (H →L[ℂ] H) c = T := by + have hc : T ∈ Subalgebra.center ℂ (H →L[ℂ] H) := by + rw [Subalgebra.mem_center_iff] + intro A + apply (mem_commutant_iff T A).mp + rw [h] + trivial + rw [Algebra.IsCentral.center_eq_bot] at hc + exact Algebra.mem_bot.mp hc + + + +theorem commutant_ne_top_of_nonzero_quasinilpotent [Nontrivial H] + (T : H →L[ℂ] H) (hT : T ≠ 0) + (hlim : Tendsto (fun n : ℕ => ‖T ^ n‖ ^ (1 / (n : ℝ))) atTop (𝓝 0)) : + commutant T ≠ ⊤ := by + intro htop + obtain ⟨c, hc⟩ := scalar_of_commutant_top T htop + have hroot (n : ℕ) (hn : n ≠ 0) : ‖T ^ n‖ ^ (1 / (n : ℝ)) = ‖c‖ := by + rw [← hc, Algebra.algebraMap_eq_smul_one, smul_pow, one_pow, + norm_smul, norm_pow, norm_one, mul_one, one_div] + exact Real.pow_rpow_inv_natCast (norm_nonneg c) hn + have hevent : (fun n : ℕ => ‖T ^ n‖ ^ (1 / (n : ℝ))) =ᶠ[atTop] + (fun _ : ℕ => ‖c‖) := by + filter_upwards [eventually_gt_atTop 0] with n hn + exact hroot n (Nat.ne_of_gt hn) + have hconst : Tendsto (fun _ : ℕ => ‖c‖) atTop (𝓝 0) := hlim.congr' hevent + have hc0 : ‖c‖ = 0 := tendsto_nhds_unique tendsto_const_nhds hconst + apply hT + rw [← hc, norm_eq_zero.mp hc0, map_zero] + + +theorem fullClaim_of_mainClaim [Nontrivial H] (h : MainClaim (H := H)) : + FullClaim (H := H) := by + obtain ⟨T, hT, hlim, htrans⟩ := h + exact ⟨T, hT, hlim, htrans, + commutant_ne_top_of_nonzero_quasinilpotent T hT hlim, + commutant_isClosed_strong T⟩ + +end Hyperinvariant233 + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/OrdinaryStructure.lean b/lean/OAI/Analysis/BackwardIntertwiners/OrdinaryStructure.lean new file mode 100644 index 0000000000000000000000000000000000000000..8bc6738555cc40db54be0dbda20a86492bae7b95 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/OrdinaryStructure.lean @@ -0,0 +1,253 @@ +import OAI.Analysis.BackwardIntertwiners.ErgodicTransitivity + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + + +def globalTail (h : ℤ) : Submodule ℂ GlobalHilbert := + ⨅ j : ℤ, ⨅ _ : j < h, (coordinateL2 j).ker +lemma mem_globalTail (h : ℤ) (f : GlobalHilbert) : + f ∈ globalTail h ↔ ∀ᵐ x ∂baseMeasure, f x ∈ coordinateTail h := by + simp only [globalTail, Submodule.mem_iInf, LinearMap.mem_ker] + constructor + · intro hf + have h (j : ℤ) : ∀ᵐ x ∂baseMeasure, j < h → f x j = 0 := by + by_cases hj : j < h + · have hh := (Lp.eq_zero_iff_ae_eq_zero.mp (hf j hj)) + filter_upwards [coordinateL2_ae j f, hh] with x hx hzero + intro _ + exact hx.symm.trans hzero + · exact Filter.Eventually.of_forall fun _ => fun h => False.elim (hj h) + exact ae_all_iff.mpr h + · intro hf j hj + apply Lp.eq_zero_iff_ae_eq_zero.mpr + filter_upwards [hf, coordinateL2_ae j f] with x hx hcoord + exact hcoord.trans (hx j hj) +lemma globalTail_closed (h : ℤ) : IsClosed (globalTail h : Set GlobalHilbert) := by + have he : (globalTail h : Set GlobalHilbert) = ⋂ j : ℤ, ⋂ _ : j < h, + {f : GlobalHilbert | coordinateL2 j f = 0} := by ext; simp [globalTail] + rw [he] + exact isClosed_iInter fun j => isClosed_iInter fun _ => + isClosed_eq (coordinateL2 j).continuous continuous_const +lemma constantBasis_mem_globalTail {h j : ℤ} (hj : h ≤ j) : constantBasis j ∈ globalTail h := by + rw [mem_globalTail] + filter_upwards [constantBasis_ae j] with x hx + rw [hx] + exact single_mem_coordinateTail hj 1 +lemma constantBasis_not_mem_globalTail {h j : ℤ} (hj : j < h) : constantBasis j ∉ globalTail h := by + intro hm + have hh := (mem_globalTail h _).mp hm + have hz : ∀ᵐ x ∂baseMeasure, (1:ℂ) = 0 := by + filter_upwards [hh, constantBasis_ae j] with x hx he + simpa only [he, lp.single_apply_self] using hx j hj + exact one_ne_zero hz.exists.choose_spec +lemma globalTail_nonzero (h : ℤ) : globalTail h ≠ ⊥ := by + intro he + have hmem := constantBasis_mem_globalTail (le_refl h) + rw [he] at hmem + have hm : constantBasis h = 0 := hmem + have hn := constantBasis_norm h + rw [hm, norm_zero] at hn + norm_num at hn +lemma globalTail_proper (h : ℤ) : globalTail h ≠ ⊤ := by + intro he + apply constantBasis_not_mem_globalTail (show h-1 lp.single 2 j (f x j) := by + filter_upwards [singleL2_ae j (coordinateL2 j f), coordinateL2_ae j f] with x h₁ h₂ + change singleL2 j (coordinateL2 j f) x = _ + rw [h₁, h₂] +lemma sliceProjection_singleL2 (j : ℤ) (f : ScalarHilbert) : + sliceProjection j (singleL2 j f) = singleL2 j f := by + change singleL2 j (coordinateL2 j (singleL2 j f)) = _ + rw [coordinateL2_singleL2] +lemma sliceProjection_idempotent (j : ℤ) : sliceProjection j * sliceProjection j = sliceProjection j := by + ext1 f + exact sliceProjection_singleL2 j (coordinateL2 j f) +lemma sliceProjection_constantBasis (j k : ℤ) : + sliceProjection j (constantBasis k) = if j=k then constantBasis k else 0 := by + classical + apply Lp.ext + filter_upwards [sliceProjection_ae j (constantBasis k), constantBasis_ae k, + Lp.coeFn_zero (E:=Fiber) (p:=2) (μ:=baseMeasure)] with x hx he hz + rw [hx, he] + by_cases hh : j=k + · simp [hh, he] + · simp only [ite_eq_right hh, lp.single_apply_ne _ _ _ hh, lp.single_zero, hz, Pi.zero_apply] +lemma sliceProjection_scalar_commute (j : ℤ) (g : Lp ℂ ∞ baseMeasure) : + sliceProjection j * scalarMultiplier g = scalarMultiplier g * sliceProjection j := by + ext1 f + apply Lp.ext + filter_upwards [sliceProjection_ae j (scalarMultiplier g f), scalarMultiplier_ae g f, + scalarMultiplier_ae g (sliceProjection j f), sliceProjection_ae j f] with x h₁ h₂ h₃ h₄ + change sliceProjection j (scalarMultiplier g f) x = scalarMultiplier g (sliceProjection j f) x + rw [h₁,h₂,h₃,h₄] + exact lp.single_smul (E:=fun _ : ℤ => ℂ) 2 j (g x) (f x j) +lemma sliceProjection_zero_not_commute : + sliceProjection 0 * forwardOperator ≠ forwardOperator * sliceProjection 0 := by + intro he + have h := congrArg (fun T : GlobalHilbert →L[ℂ] GlobalHilbert => T (constantBasis 0)) he + simp only [mul_apply_eq_comp, forwardOperator_constantBasis_zero, map_smul, + sliceProjection_constantBasis] at h + norm_num at h + have hh := congrArg norm h + rw [norm_zero, forwardOperator_constantBasis_zero, norm_smul, constantBasis_norm, mul_one, Complex.norm_real, + Real.norm_of_nonneg (Real.exp_pos _).le] at hh + exact (Real.exp_ne_zero (-10)) hh.symm +lemma sliceProjection_zero_not_scalar : + sliceProjection 0 ∉ Set.range (scalarMultiplier (μ:=baseMeasure)) := by + rintro ⟨g,hg⟩ + have he0 : scalarMultiplier g (constantBasis 0) = constantBasis 0 := by + rw [hg, sliceProjection_constantBasis]; simp + have he1 : scalarMultiplier g (constantBasis 1) = 0 := by + rw [hg, sliceProjection_constantBasis]; norm_num + have h₀ := scalarMultiplier_ae g (constantBasis 0) + have h₁ := scalarMultiplier_ae g (constantBasis 1) + rw [he0] at h₀ + rw [he1] at h₁ + have hfalse : ∀ᵐ x ∂baseMeasure, False := by + filter_upwards [h₀,h₁,constantBasis_ae 0, constantBasis_ae 1, + Lp.coeFn_zero (E:=Fiber) (p:=2) (μ:=baseMeasure)] with x hv₀ hv₁ he₀ he₁ hz + have hc₀ := congrArg (fun v : Fiber => v 0) hv₀ + have hc₁ := congrArg (fun v : Fiber => v 1) hv₁ + simp only [he₀, lp.single_apply_self, lp.coeFn_smul, Pi.smul_apply, smul_eq_mul, mul_one] at hc₀ + simp only [hz, he₁, lp.single_apply_self, lp.coeFn_smul, Pi.smul_apply, smul_eq_mul, mul_one, lp.coeFn_zero, Pi.zero_apply] at hc₁ + exact one_ne_zero (hc₀.trans hc₁.symm) + exact hfalse.exists.choose_spec + +lemma residue_separates {x y : Base} (h : ∀ m : ℕ, residue m x = residue m y) : x = y := by + apply PadicInt.ext_of_toZModPow.mp + intro m + apply ZMod.val_injective + exact h m + +def residueClass (m t : ℕ) : Set Base := {x | residue m x = t} +lemma measurableSet_residueClass (m t : ℕ) : MeasurableSet (residueClass m t) := + measurableSet_eq_fun (measurable_residue m) measurable_const +lemma residueClass_nonnull {m t : ℕ} (ht : t < 2^m) : baseMeasure (residueClass m t) ≠ 0 := by + change baseHaar {x : PadicInt 2 | twoResidue m x = t} ≠ 0 + have hcont : Continuous (twoResidue m) := + continuous_of_discreteTopology.comp (continuous_twoResidue m) + have hOpen : IsOpen {x : PadicInt 2 | twoResidue m x = t} := + (isOpen_discrete ({t}:Set ℕ)).preimage hcont + have hmem : twoResidue m (t : PadicInt 2) = t := by + simp only [twoResidue, map_natCast] + exact ZMod.val_natCast_of_lt ht + exact (hOpen.measure_pos baseHaar ⟨(t : PadicInt 2),hmem⟩).ne' + + +def residueIndicator (m t : ℕ) : ScalarHilbert := + indicatorConstLp 2 (measurableSet_residueClass m t) (measure_ne_top baseMeasure _) (1:ℂ) +lemma residueIndicator_ae (m t : ℕ) : residueIndicator m t =ᵐ[baseMeasure] + (residueClass m t).indicator (fun _ => (1:ℂ)) := indicatorConstLp_coeFn +lemma residueIndicator_ne_zero {m t : ℕ} (ht : t < 2^m) : residueIndicator m t ≠ 0 := by + intro hz + apply residueClass_nonnull ht + rw [measure_eq_zero_iff_ae_notMem] + have he := Lp.eq_zero_iff_ae_eq_zero.mp hz + filter_upwards [he,residueIndicator_ae m t] with x hx hi + intro hmem + have h10 : (1:ℂ)=0 := by rw [← Set.indicator_of_mem hmem (fun _ => (1:ℂ)), ← hi]; exact hx + exact one_ne_zero h10 +lemma residueIndicator_orthogonal (m : ℕ) {s t : ℕ} (hst : s ≠ t) : + inner ℂ (residueIndicator m s) (residueIndicator m t) = 0 := by + rw [L2.inner_def] + apply integral_eq_zero_of_ae + filter_upwards [residueIndicator_ae m s, residueIndicator_ae m t] with x hs ht + rw [hs,ht] + by_cases hxs : x ∈ residueClass m s + · have hxt : x ∉ residueClass m t := fun hx => hst (hxs.symm.trans hx) + simp [Set.indicator_of_notMem hxt] + · simp [Set.indicator_of_notMem hxs] +lemma residueIndicator_independent (m : ℕ) : + LinearIndependent ℂ (fun t : Fin (2^m) => residueIndicator m t) := by + apply linearIndependent_of_ne_zero_of_inner_eq_zero + · intro t; exact residueIndicator_ne_zero t.isLt + · intro s t hst + exact residueIndicator_orthogonal m (fun he => hst (Fin.ext he)) +lemma scalarHilbert_infinite : ¬FiniteDimensional ℂ ScalarHilbert := by + intro hfin + let := hfin + have hh := (residueIndicator_independent (Module.finrank ℂ ScalarHilbert + 1)).fintype_card_le_finrank + simp only [Fintype.card_fin] at hh + have hlt := Nat.lt_two_pow_self (n:=Module.finrank ℂ ScalarHilbert + 1) + omega + +lemma forwardOperator_singleL2_zero (f : ScalarHilbert) : + forwardOperator (singleL2 0 f) = (Real.exp (-10):ℂ) • singleL2 1 f := by + apply Lp.ext + filter_upwards [forwardOperator_ae (singleL2 0 f), singleL2_ae 0 f, singleL2_ae 1 f, + Lp.coeFn_smul (Real.exp (-10):ℂ) (singleL2 1 f)] with x h₁ h₂ h₃ h₄ + rw [h₁,h₂,h₄,Pi.smul_apply,h₃,forwardFiber_single,explicitBeta_zero] + exact lp.single_smul (E:=fun _ : ℤ => ℂ) 2 1 (Real.exp (-10):ℂ) (f x) +lemma coordinate_forward_single : + (coordinateL2 1).comp (forwardOperator.comp (singleL2 0)) = + (Real.exp (-10):ℂ) • (1 : ScalarHilbert →L[ℂ] ScalarHilbert) := by + ext1 f + change coordinateL2 1 (forwardOperator (singleL2 0 f)) = (Real.exp (-10):ℂ) • f + rw [forwardOperator_singleL2_zero, map_smul, coordinateL2_singleL2] +lemma forwardOperator_not_compact : ¬IsCompactOperator forwardOperator := by + intro hcomp + have hc : IsCompactOperator ((coordinateL2 1).comp (forwardOperator.comp (singleL2 0))) := + (hcomp.comp_clm (singleL2 0)).clm_comp (coordinateL2 1) + rw [coordinate_forward_single] at hc + have he : (Real.exp (-10):ℂ) ≠ 0 := by exact_mod_cast Real.exp_ne_zero (-10) + have hid : IsCompactOperator (id : ScalarHilbert → ScalarHilbert) := + (IsCompactOperator.smul_iff₀ he).mp hc + exact scalarHilbert_infinite (FiniteDimensional.of_isCompactOperator_id hid) +lemma globalHilbert_infinite : ¬FiniteDimensional ℂ GlobalHilbert := by + intro hfin + let := hfin + apply scalarHilbert_infinite + apply FiniteDimensional.of_injective (singleL2 0).toLinearMap + intro f g he + have he' : singleL2 0 f = singleL2 0 g := he + simpa only [coordinateL2_singleL2] using congrArg (coordinateL2 0) he' + +lemma sliceProjection_selfAdjoint (j : ℤ) : IsSelfAdjoint (sliceProjection j) := by + apply ContinuousLinearMap.isSelfAdjoint_iff_isSymmetric.mpr + intro f g + change inner ℂ (sliceProjection j f) g = inner ℂ f (sliceProjection j g) + simp only [L2.inner_def] + apply integral_congr_ae + filter_upwards [sliceProjection_ae j f, sliceProjection_ae j g] with x hf hg + rw [hf,hg,lp.inner_single_left,lp.inner_single_right] +lemma sliceProjection_isStarProjection (j : ℤ) : IsStarProjection (sliceProjection j) := + ⟨sliceProjection_idempotent j, sliceProjection_selfAdjoint j⟩ + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/PolarDiagonals.lean b/lean/OAI/Analysis/BackwardIntertwiners/PolarDiagonals.lean new file mode 100644 index 0000000000000000000000000000000000000000..952260ad7be158b8900f6f0623808ce95d412333 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/PolarDiagonals.lean @@ -0,0 +1,368 @@ +import OAI.Analysis.BackwardIntertwiners.StrongClosure + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + + +def betaSymbol (n : ℤ) : DiagonalSymbol := + ⟨fun x j => (explicitBeta x (j+n):ℂ), + ⟨fun j => Complex.continuous_ofReal.measurable.comp (measurable_explicitBeta (j+n)), + Real.exp (-10), (Real.exp_pos _).le, fun x j => by + simpa only [Complex.norm_real,Real.norm_of_nonneg (explicitBeta_pos _ _).le] using explicitBeta_le x (j+n)⟩⟩ +@[simp] lemma betaSymbol_apply (n : ℤ) (x : Base) (j : ℤ) : + betaSymbol n x j = (explicitBeta x (j+n):ℂ) := rfl +lemma betaSymbol_star (n : ℤ) : star (betaSymbol n) = betaSymbol n := by + apply Subtype.ext + funext x j + simp + +def polarDiagonal (n : ℤ) : GlobalHilbert →L[ℂ] GlobalHilbert := diagonalOperator (betaSymbol n) +lemma polarDiagonal_ae (n : ℤ) (f : GlobalHilbert) : + ∀ᵐ x ∂baseMeasure, ∀ j, polarDiagonal n f x j = (explicitBeta x (j+n):ℂ)*f x j := + diagonalOperator_coord _ _ +lemma polarDiagonal_selfAdjoint (n : ℤ) : IsSelfAdjoint (polarDiagonal n) := by + change star (diagonalOperator (betaSymbol n)) = diagonalOperator (betaSymbol n) + rw [←diagonalOperator_star,betaSymbol_star] +lemma polarDiagonal_commute (m n : ℤ) : polarDiagonal m * polarDiagonal n = polarDiagonal n * polarDiagonal m := by + change diagonalRepresentation (betaSymbol m) * diagonalRepresentation (betaSymbol n) = diagonalRepresentation (betaSymbol n) * diagonalRepresentation (betaSymbol m) + rw [←map_mul,mul_comm,map_mul] + + + +def projectionSymbol (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : DiagonalSymbol := + ⟨fun x j => (E j).indicator (fun _ => (1:ℂ)) x, + ⟨fun j => measurable_const.indicator (hE j), 1, zero_le_one, fun x j => by + by_cases hx : x ∈ E j <;> simp [hx]⟩⟩ +@[simp] lemma projectionSymbol_apply (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) + (x : Base) (j : ℤ) : projectionSymbol E hE x j = if x ∈ E j then 1 else 0 := rfl +lemma projectionSymbol_norm_le (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) + (x : Base) (j : ℤ) : ‖projectionSymbol E hE x j‖ ≤ 1 := by + by_cases hx : x ∈ E j <;> simp [hx] +lemma projectionSymbol_star (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : + star (projectionSymbol E hE) = projectionSymbol E hE := by + apply Subtype.ext + funext x j + change star (projectionSymbol E hE x j) = projectionSymbol E hE x j + by_cases hx : x ∈ E j <;> simp [hx] +lemma projectionSymbol_idempotent (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : + projectionSymbol E hE * projectionSymbol E hE = projectionSymbol E hE := by + apply Subtype.ext + funext x j + change projectionSymbol E hE x j * projectionSymbol E hE x j = projectionSymbol E hE x j + by_cases hx : x ∈ E j <;> simp [hx] + +def diagonalProjection (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : GlobalHilbert →L[ℂ] GlobalHilbert := + diagonalOperator (projectionSymbol E hE) +lemma diagonalProjection_ae (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) (f : GlobalHilbert) : + ∀ᵐ x ∂baseMeasure, ∀ j, diagonalProjection E hE f x j = if x ∈ E j then f x j else 0 := by + filter_upwards [diagonalOperator_coord (projectionSymbol E hE) f] with x hx j + change diagonalOperator (projectionSymbol E hE) f x j = _ + rw [hx,projectionSymbol_apply] + split_ifs <;> simp +lemma diagonalProjection_isStarProjection (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : + IsStarProjection (diagonalProjection E hE) := by + constructor + · change diagonalOperator (projectionSymbol E hE) * diagonalOperator (projectionSymbol E hE) = _ + rw [←diagonalOperator_mul,projectionSymbol_idempotent] + rfl + · change star (diagonalOperator (projectionSymbol E hE)) = diagonalOperator (projectionSymbol E hE) + rw [←diagonalOperator_star,projectionSymbol_star] +lemma diagonalProjection_mul (E F : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) + (hF : ∀ j, MeasurableSet (F j)) : + diagonalProjection E hE * diagonalProjection F hF = + diagonalProjection (fun j => E j ∩ F j) (fun j => (hE j).inter (hF j)) := by + change diagonalOperator _ * diagonalOperator _ = diagonalOperator _ + rw [←diagonalOperator_mul] + congr 1 + apply Subtype.ext + funext x j + change projectionSymbol E hE x j * projectionSymbol F hF x j = projectionSymbol _ _ x j + by_cases hx : x ∈ E j <;> by_cases hy : x ∈ F j <;> simp [hx,hy] +lemma diagonalProjection_compl (E : ℤ → Set Base) (hE : ∀ j, MeasurableSet (E j)) : + diagonalProjection (fun j => (E j)ᶜ) (fun j => (hE j).compl) = 1-diagonalProjection E hE := by + change diagonalRepresentation _ = 1-diagonalRepresentation _ + rw [←map_one diagonalRepresentation,←map_sub] + congr 1 + apply Subtype.ext + funext x j + change projectionSymbol _ _ x j = 1-projectionSymbol E hE x j + by_cases hx : x ∈ E j <;> simp [hx] +lemma diagonalProjection_empty : diagonalProjection (fun _ => ∅) (fun _ => MeasurableSet.empty) = 0 := by + have h : projectionSymbol (fun _ => ∅) (fun _ => MeasurableSet.empty) = 0 := by + apply Subtype.ext; funext x j; simp + exact congrArg diagonalOperator h |>.trans diagonalOperator_zero +lemma diagonalProjection_univ : diagonalProjection (fun _ => Set.univ) (fun _ => MeasurableSet.univ) = 1 := by + have h : projectionSymbol (fun _ => Set.univ) (fun _ => MeasurableSet.univ) = 1 := by + apply Subtype.ext; funext x j; simp + exact congrArg diagonalOperator h |>.trans diagonalOperator_one +lemma diagonalProjection_ext {E F : ℤ → Set Base} {hE : ∀ j, MeasurableSet (E j)} + {hF : ∀ j, MeasurableSet (F j)} (h : ∀ j, E j =ᵐ[baseMeasure] F j) : + diagonalProjection E hE = diagonalProjection F hF := by + ext1 f + apply Lp.ext + filter_upwards [diagonalProjection_ae E hE f,diagonalProjection_ae F hF f, + ae_all_iff.mpr h] with x hx hy he + ext j + rw [hx,hy] + have hh : (x ∈ E j) = (x ∈ F j) := he j + simp only [hh] +lemma diagonalProjection_nonzero {E : ℤ → Set Base} {hE : ∀ j, MeasurableSet (E j)} + (j : ℤ) (hj : baseMeasure (E j) ≠ 0) : diagonalProjection E hE ≠ 0 := by + intro he + apply hj + apply measure_eq_zero_iff_ae_notMem.mpr + filter_upwards [diagonalProjection_ae E hE (constantBasis j),constantBasis_ae j, + Lp.coeFn_zero Fiber 2 baseMeasure] with x hx hb hz + intro hxE + have h := hx j + rw [he] at h + change (0 : GlobalHilbert) x j = _ at h + rw [hz,hb] at h + simp [hxE] at h + + +lemma explicitBeta_le_one (x : Base) (j : ℤ) : explicitBeta x j ≤ 1 := + (explicitBeta_le x j).trans (Real.exp_le_one_iff.mpr (by norm_num)) + +def levelProjection (n : ℤ) (t : ℝ) : GlobalHilbert →L[ℂ] GlobalHilbert := + diagonalProjection (fun j => {x | explicitBeta x (j+n) = t}) + (fun j => measurableSet_eq_fun (measurable_explicitBeta (j+n)) measurable_const) + +lemma peak_nonneg {b t : ℝ} (hb₀ : 0 ≤ b) (hb₁ : b ≤ 1) (ht₀ : 0 ≤ t) (ht₁ : t ≤ 1) : + 0 ≤ 1-(b-t)^2 := by + have h₁ : 0 ≤ (1-(b-t))*(1+(b-t)) := mul_nonneg (by linarith) (by linarith) + nlinarith +lemma peak_le_one (b t : ℝ) : 1-(b-t)^2 ≤ 1 := by nlinarith [sq_nonneg (b-t)] +lemma peak_lt_one {b t : ℝ} (h : b ≠ t) : 1-(b-t)^2 < 1 := by + have h' : 0 < (b-t)^2 := sq_pos_of_ne_zero (sub_ne_zero.mpr h) + linarith + +def peakSymbol (n : ℤ) (t : ℝ) : DiagonalSymbol := 1-(betaSymbol n - (t:ℂ) • 1)^2 +@[simp] lemma peakSymbol_apply (n : ℤ) (t : ℝ) (x : Base) (j : ℤ) : + peakSymbol n t x j = ((1-(explicitBeta x (j+n)-t)^2:ℝ):ℂ) := by + simp [peakSymbol,Complex.ofReal_sub,Complex.ofReal_pow] +lemma peakSymbol_bound (n : ℤ) {t : ℝ} (ht₀ : 0 ≤ t) (ht₁ : t ≤ 1) (x : Base) (j : ℤ) : + ‖peakSymbol n t x j‖ ≤ 1 := by + rw [peakSymbol_apply,Complex.norm_real,Real.norm_of_nonneg + (peak_nonneg (explicitBeta_pos _ _).le (explicitBeta_le_one _ _) ht₀ ht₁)] + exact peak_le_one _ _ +lemma peakSymbol_powers_tendsto (n : ℤ) {t : ℝ} (ht₀ : 0 ≤ t) (ht₁ : t ≤ 1) + (x : Base) (j : ℤ) : + Tendsto (fun k : ℕ => (peakSymbol n t ^k) x j) atTop + (𝓝 (if explicitBeta x (j+n)=t then (1:ℂ) else 0)) := by + simp only [DiagonalSymbol.pow_apply,peakSymbol_apply] + by_cases he : explicitBeta x (j+n)=t + · simp [he] + · simp only [he,↓reduceIte] + apply tendsto_pow_atTop_nhds_zero_of_norm_lt_one + rw [Complex.norm_real,Real.norm_of_nonneg + (peak_nonneg (explicitBeta_pos _ _).le (explicitBeta_le_one _ _) ht₀ ht₁)] + exact peak_lt_one he +lemma levelProjection_mem {A : StarSubalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert)} + (hA : StronglyClosed A) (n : ℤ) {t : ℝ} (ht₀ : 0 ≤ t) (ht₁ : t ≤ 1) + (hn : polarDiagonal n ∈ A) : levelProjection n t ∈ A := by + have hq : diagonalOperator (peakSymbol n t) ∈ A := by + change diagonalRepresentation (1-(betaSymbol n - (t:ℂ) • 1)^2) ∈ A + rw [map_sub,map_one,map_pow,map_sub,map_smul,map_one] + exact A.sub_mem A.one_mem (A.pow_mem (A.sub_mem hn (A.smul_mem A.one_mem _)) _) + apply hA.mem_of_tendsto (l:=atTop) (T:=fun k : ℕ => diagonalOperator (peakSymbol n t ^k)) + · exact Eventually.of_forall fun k => by + change diagonalRepresentation (peakSymbol n t ^k) ∈ A + rw [map_pow] + exact A.pow_mem hq _ + · intro f + apply diagonalOperator_tendsto (C:=1) _ _ zero_le_one + · intro k x j + rw [DiagonalSymbol.pow_apply,norm_pow] + exact pow_le_one₀ (norm_nonneg _) (peakSymbol_bound n ht₀ ht₁ x j) + · exact projectionSymbol_norm_le _ _ + · exact Eventually.of_forall fun x j => by + simpa using peakSymbol_powers_tendsto n ht₀ ht₁ x j + + + +def baseProjection (E : Set Base) (hE : MeasurableSet E) : GlobalHilbert →L[ℂ] GlobalHilbert := + diagonalProjection (fun _ => E) (fun _ => hE) +lemma baseProjection_ae (E : Set Base) (hE : MeasurableSet E) (f : GlobalHilbert) : + baseProjection E hE f =ᵐ[baseMeasure] E.indicator f := by + filter_upwards [diagonalProjection_ae (fun _ => E) (fun _ => hE) f] with x hx + ext j + by_cases he : x ∈ E <;> simpa [baseProjection,he] using hx j +lemma baseProjection_mem_full (E : Set Base) (hE : MeasurableSet E) : + baseProjection E hE ∈ fullMultiplierAlgebra := ⟨projectionSymbol _ _,rfl⟩ +lemma diagonal_commute (a b : DiagonalSymbol) : + diagonalOperator a * diagonalOperator b = diagonalOperator b * diagonalOperator a := by + rw [←diagonalOperator_mul,←diagonalOperator_mul,mul_comm] +lemma fullMultiplier_commute {A B : GlobalHilbert →L[ℂ] GlobalHilbert} + (hA : A ∈ fullMultiplierAlgebra) (hB : B ∈ fullMultiplierAlgebra) : A*B=B*A := by + obtain ⟨a,rfl⟩ := hA + obtain ⟨b,rfl⟩ := hB + exact diagonal_commute a b +lemma baseProjection_constant (E : Set Base) (hE : MeasurableSet E) (v : Fiber) : + baseProjection E hE (Lp.const 2 baseMeasure v) = + indicatorConstLp 2 hE (measure_ne_top baseMeasure E) v := by + apply Lp.ext + filter_upwards [baseProjection_ae E hE (Lp.const 2 baseMeasure v),Lp.coeFn_const 2 baseMeasure v, + (indicatorConstLp_coeFn (p:=2) (hs:=hE) (hμs:=measure_ne_top baseMeasure E) (c:=v))] with x hx hv hi + rw [hx,hi] + by_cases he : x ∈ E <;> simp [he] +lemma L2_norm_sq (f : GlobalHilbert) : ‖f‖^2 = ∫ x, ‖f x‖^2 ∂baseMeasure := by + rw [L2_norm_eq_sqrt,Real.sq_sqrt (integral_nonneg fun _ => sq_nonneg _)] +lemma baseProjection_norm_sq (E : Set Base) (hE : MeasurableSet E) (f : GlobalHilbert) : + ‖baseProjection E hE f‖^2 = ∫ x in E, ‖f x‖^2 ∂baseMeasure := by + rw [L2_norm_sq,←integral_indicator hE] + apply integral_congr_ae + filter_upwards [baseProjection_ae E hE f] with x hx + rw [hx] + by_cases he : x ∈ E <;> simp [he] +lemma local_operator_energy_bound (T : GlobalHilbert →L[ℂ] GlobalHilbert) + (hT : ∀ E (hE : MeasurableSet E), baseProjection E hE * T = T * baseProjection E hE) + (f : GlobalHilbert) : ∀ᵐ x ∂baseMeasure, ‖T f x‖^2 ≤ ‖T‖^2 * ‖f x‖^2 := by + have hI (g : GlobalHilbert) : Integrable (fun x : Base => ‖g x‖^2) baseMeasure := + (Lp.memLp g).integrable_norm_pow (by norm_num : (2:ℕ) ≠ 0) + apply ae_le_of_forall_setIntegral_le (μ:=baseMeasure) (hI (T f)) ((hI f).const_mul (‖T‖^2)) + intro E hE _ + rw [←baseProjection_norm_sq E hE,integral_const_mul,←baseProjection_norm_sq E hE] + have he : baseProjection E hE (T f) = T (baseProjection E hE f) := DFunLike.congr_fun (hT E hE) f + rw [he] + simpa only [mul_pow] using pow_le_pow_left₀ (norm_nonneg _) (T.le_opNorm (baseProjection E hE f)) 2 + +lemma sliceProjection_diagonal (j : ℤ) : sliceProjection j = + diagonalProjection (fun k => if k=j then Set.univ else ∅) + (fun k => by split_ifs <;> measurability) := by + ext1 f + apply Lp.ext + filter_upwards [sliceProjection_ae j f,diagonalProjection_ae (fun k => if k=j then Set.univ else ∅) + (fun k => by split_ifs <;> measurability) f] with x hx hy + ext k + rw [hx,hy] + by_cases he : k=j <;> simp [he,lp.single_apply] +lemma sliceProjection_mem_full (j : ℤ) : sliceProjection j ∈ fullMultiplierAlgebra := by + rw [sliceProjection_diagonal] + exact ⟨projectionSymbol _ _,rfl⟩ + + +def columnSymbol (T : GlobalHilbert →L[ℂ] GlobalHilbert) : DiagonalSymbol := + ⟨fun x j => if ‖T (constantBasis j) x j‖ ≤ ‖T‖ then T (constantBasis j) x j else 0, + ⟨fun j => by + have hm : Measurable (fun x => T (constantBasis j) x j) := + ((lp.evalCLM ℂ (fun _ : ℤ => ℂ) 2 j).continuous.comp_stronglyMeasurable + (Lp.stronglyMeasurable (T (constantBasis j)))).measurable + exact hm.ite (measurableSet_le hm.norm measurable_const) measurable_const, + ‖T‖,norm_nonneg T,fun x j => by dsimp only; split_ifs with h <;> simp_all⟩⟩ +lemma columnSymbol_ae (T : GlobalHilbert →L[ℂ] GlobalHilbert) + (hT : ∀ E (hE : MeasurableSet E), baseProjection E hE * T = T * baseProjection E hE) + (j : ℤ) : ∀ᵐ x ∂baseMeasure, columnSymbol T x j = T (constantBasis j) x j := by + filter_upwards [local_operator_energy_bound T hT (constantBasis j),constantBasis_ae j] with x hx hj + have hh : ‖T (constantBasis j) x‖ ≤ ‖T‖ := by + have h₁ : ‖constantBasis j x‖=1 := by rw [hj]; simp + rw [h₁] at hx + nlinarith [norm_nonneg (T (constantBasis j) x),norm_nonneg T] + have hc : ‖T (constantBasis j) x j‖ ≤ ‖T‖ := (lp.norm_apply_le_norm (by norm_num : (2:ENNReal) ≠ 0) _ j).trans hh + exact ite_eq_left hc + +lemma columnSymbol_basis (T : GlobalHilbert →L[ℂ] GlobalHilbert) + (hT : ∀ E (hE : MeasurableSet E), baseProjection E hE * T = T * baseProjection E hE) + (hS : ∀ j, sliceProjection j * T = T * sliceProjection j) (j : ℤ) : + diagonalOperator (columnSymbol T) (constantBasis j) = T (constantBasis j) := by + have he : sliceProjection j (T (constantBasis j)) = T (constantBasis j) := by + rw [show sliceProjection j (T (constantBasis j)) = T (sliceProjection j (constantBasis j)) from DFunLike.congr_fun (hS j) _] + simp [sliceProjection_constantBasis] + apply Lp.ext + filter_upwards [diagonalOperator_coord (columnSymbol T) (constantBasis j),constantBasis_ae j, + columnSymbol_ae T hT j,sliceProjection_ae j (T (constantBasis j))] with x hx hj hc hs + rw [he] at hs + ext k + rw [hx,hj,hs] + by_cases hk : k=j + · subst k; simp [hc] + · simp [lp.single_apply,hk] + +lemma operators_equal_of_constantBasis {T D : GlobalHilbert →L[ℂ] GlobalHilbert} + (hc : ∀ j, T (constantBasis j)=D (constantBasis j)) + (hT : ∀ E (hE : MeasurableSet E), baseProjection E hE*T=T*baseProjection E hE) + (hD : ∀ E (hE : MeasurableSet E), baseProjection E hE*D=D*baseProjection E hE) : T=D := by + have hconst (v : Fiber) : T (Lp.const 2 baseMeasure v)=D (Lp.const 2 baseMeasure v) := by + let L := (Lp.constL 2 baseMeasure ℂ : Fiber →L[ℂ] GlobalHilbert) + have h₁ := (lp.hasSum_single (by norm_num : (2:ENNReal) ≠ ∞) v).map (T.comp L).toAddMonoidHom (T.comp L).continuous + have h₂ := (lp.hasSum_single (by norm_num : (2:ENNReal) ≠ ∞) v).map (D.comp L).toAddMonoidHom (D.comp L).continuous + have hh (j : ℤ) : (T.comp L) (lp.single 2 j (v j)) = (D.comp L) (lp.single 2 j (v j)) := by + have he : (lp.single 2 j (v j) : Fiber) = (v j) • lp.single 2 j (1:ℂ) := by + rw [←lp.single_smul]; simp + rw [he,map_smul,map_smul] + exact congrArg (fun w : GlobalHilbert => v j • w) (hc j) + exact h₁.unique (h₂.congr_fun hh) + ext1 f + apply Lp.induction (by norm_num : (2:ENNReal) ≠ ∞) (fun f : GlobalHilbert => T f=D f) (f:=f) + · intro v E hE hfin + rw [Lp.simpleFunc.coe_indicatorConst,←baseProjection_constant E hE v] + have heT := DFunLike.congr_fun (hT E hE) (Lp.const 2 baseMeasure v) + have heD := DFunLike.congr_fun (hD E hE) (Lp.const 2 baseMeasure v) + change baseProjection E hE (T _) = T (baseProjection E hE _) at heT + change baseProjection E hE (D _) = D (baseProjection E hE _) at heD + rw [←heT,←heD,hconst] + · intro f g hf hg _ h₁ h₂ + simp only [map_add,h₁,h₂] + · exact isClosed_eq T.continuous D.continuous + +lemma fullMultiplier_centralizer_eq : StarSubalgebra.centralizer ℂ (fullMultiplierAlgebra : Set _) = + fullMultiplierAlgebra := by + apply le_antisymm + · intro T hT + have hcomm {P : GlobalHilbert →L[ℂ] GlobalHilbert} (hP : P ∈ fullMultiplierAlgebra) : P*T=T*P := + ((StarSubalgebra.mem_centralizer_iff ℂ).mp hT P hP).1 + have hbase : ∀ E (hE : MeasurableSet E), baseProjection E hE*T=T*baseProjection E hE := + fun E hE => hcomm (baseProjection_mem_full E hE) + refine ⟨columnSymbol T, ?_⟩ + apply operators_equal_of_constantBasis (columnSymbol_basis T hbase (fun j => hcomm (sliceProjection_mem_full j))) + · intro E hE + exact diagonal_commute _ _ + · exact hbase + · intro T hT + apply (StarSubalgebra.mem_centralizer_iff ℂ).mpr + intro P hP + exact ⟨fullMultiplier_commute hP hT,fullMultiplier_commute (fullMultiplierAlgebra.star_mem' hP) hT⟩ +lemma fullMultiplier_stronglyClosed : StronglyClosed fullMultiplierAlgebra := by + rw [←fullMultiplier_centralizer_eq] + exact strong_centralizer_closed _ + +lemma levelProjection_mem_all {A : StarSubalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert)} + (hA : StronglyClosed A) (n : ℤ) (t : ℝ) (hn : polarDiagonal n ∈ A) : levelProjection n t ∈ A := by + by_cases ht : 0 ≤ t ∧ t ≤ 1 + · exact levelProjection_mem hA n ht.1 ht.2 hn + have he : levelProjection n t = 0 := by + unfold levelProjection + rw [←diagonalProjection_empty] + apply diagonalProjection_ext + intro j + apply EventuallyEq.of_eq + ext x + change (explicitBeta x (j+n)=t) ↔ False + constructor + · intro hx + apply ht + rw [←hx] + exact ⟨(explicitBeta_pos _ _).le,explicitBeta_le_one _ _⟩ + · exact False.elim + rw [he] + exact A.zero_mem + + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/PolarFactors.lean b/lean/OAI/Analysis/BackwardIntertwiners/PolarFactors.lean new file mode 100644 index 0000000000000000000000000000000000000000..728f549686c1784afceca57023fcb86594b45c85 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/PolarFactors.lean @@ -0,0 +1,169 @@ +import OAI.Analysis.BackwardIntertwiners.SpectralProjections + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def coordinateShift (n : ℤ) : GlobalHilbert →L[ℂ] GlobalHilbert := + (fiberReindex (Equiv.addRight (-n))).toLinearIsometry.toContinuousLinearMap.compLpL 2 baseMeasure +lemma coordinateShift_ae (n : ℤ) (f : GlobalHilbert) : + ∀ᵐ x ∂baseMeasure, ∀ j, coordinateShift n f x j = f x (j-n) := by + filter_upwards [ContinuousLinearMap.coeFn_compLpL + (fiberReindex (Equiv.addRight (-n))).toLinearIsometry.toContinuousLinearMap f] with x hx j + change coordinateShift n f x = fiberReindex (Equiv.addRight (-n)) (f x) at hx + rw [hx] + rfl +lemma coordinateShift_zero : coordinateShift 0 = 1 := by + ext1 f + apply Lp.ext + filter_upwards [coordinateShift_ae 0 f] with x hx + ext j + simpa using hx j +lemma coordinateShift_add (m n : ℤ) : coordinateShift (m+n) = coordinateShift m * coordinateShift n := by + ext1 f + apply Lp.ext + filter_upwards [coordinateShift_ae (m+n) f,coordinateShift_ae m (coordinateShift n f), + coordinateShift_ae n f] with x hmn hm hn + ext j + change coordinateShift (m+n) f x j = coordinateShift m (coordinateShift n f) x j + rw [hmn,hm,hn] + exact congrArg (fun k : ℤ => f x k) (by omega) +lemma coordinateShift_norm_le (n : ℤ) (f : GlobalHilbert) : ‖coordinateShift n f‖ ≤ ‖f‖ := by + apply Lp.norm_le_norm_of_ae_le + filter_upwards [ContinuousLinearMap.coeFn_compLpL + (fiberReindex (Equiv.addRight (-n))).toLinearIsometry.toContinuousLinearMap f] with x hx + change coordinateShift n f x = fiberReindex (Equiv.addRight (-n)) (f x) at hx + rw [hx] + exact le_of_eq ((fiberReindex _).norm_map _) +lemma coordinateShift_norm (n : ℤ) (f : GlobalHilbert) : ‖coordinateShift n f‖ = ‖f‖ := by + apply le_antisymm (coordinateShift_norm_le n f) + have h : coordinateShift (-n) (coordinateShift n f) = f := by + have hh := congrArg (fun T : GlobalHilbert →L[ℂ] GlobalHilbert => T f) (coordinateShift_add (-n) n) + simpa only [neg_add_cancel,coordinateShift_zero,one_apply_eq_self,mul_apply_eq_comp] using hh.symm + have hn := coordinateShift_norm_le (-n) (coordinateShift n f) + rwa [h] at hn + + +def shiftIsometry (n : ℤ) : GlobalHilbert ≃ₗᵢ[ℂ] GlobalHilbert where + toFun := coordinateShift n + invFun := coordinateShift (-n) + map_add' := (coordinateShift n).map_add + map_smul' := (coordinateShift n).map_smul + left_inv f := by + have h := congrArg (fun T : GlobalHilbert →L[ℂ] GlobalHilbert => T f) (coordinateShift_add (-n) n) + simpa only [neg_add_cancel,coordinateShift_zero,one_apply_eq_self,mul_apply_eq_comp] using h.symm + right_inv f := by + have h := congrArg (fun T : GlobalHilbert →L[ℂ] GlobalHilbert => T f) (coordinateShift_add n (-n)) + simpa only [add_neg_cancel,coordinateShift_zero,one_apply_eq_self,mul_apply_eq_comp] using h.symm + norm_map' := coordinateShift_norm n +lemma coordinateShift_star (n : ℤ) : star (coordinateShift n) = coordinateShift (-n) := by + change (coordinateShift n).adjoint = _ + exact (ContinuousLinearMap.eq_adjoint_iff _ _).mpr (by + intro f g + change inner ℂ (shiftIsometry (-n) f) g = inner ℂ f (shiftIsometry n g) + have h := (shiftIsometry n).inner_map_map (shiftIsometry (-n) f) g + have he : shiftIsometry n (shiftIsometry (-n) f) = f := (shiftIsometry n).apply_symm_apply f + rw [he] at h + exact h.symm) |>.symm + +def shiftUnit : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ where + val := coordinateShift 1 + inv := coordinateShift (-1) + val_inv := by rw [←coordinateShift_add]; norm_num [coordinateShift_zero] + inv_val := by rw [←coordinateShift_add]; norm_num [coordinateShift_zero] +lemma shiftUnit_zpow (n : ℤ) : ((shiftUnit^n : (GlobalHilbert →L[ℂ] GlobalHilbert)ˣ) : GlobalHilbert →L[ℂ] GlobalHilbert) = coordinateShift n := by + induction n using Int.induction_on with + | zero => simp [coordinateShift_zero] + | succ n ih => rw [zpow_add_one,Units.val_mul,ih]; exact (coordinateShift_add _ _).symm + | pred n ih => rw [zpow_sub_one,Units.val_mul,ih]; exact (coordinateShift_add _ _).symm + +lemma forward_polar_factor : forwardOperator = coordinateShift 1 * polarDiagonal 0 := by + ext1 f + apply Lp.ext + filter_upwards [forwardOperator_ae f,coordinateShift_ae 1 (polarDiagonal 0 f),polarDiagonal_ae 0 f] with x hs hu hd + ext j + change forwardOperator f x j = coordinateShift 1 (polarDiagonal 0 f) x j + rw [hs,forwardFiber_apply,hu,hd,add_zero] +lemma polarDiagonal_conjugate (n : ℤ) : + coordinateShift (-n) * polarDiagonal 0 * coordinateShift n = polarDiagonal n := by + ext1 f + apply Lp.ext + filter_upwards [coordinateShift_ae (-n) (polarDiagonal 0 (coordinateShift n f)), + polarDiagonal_ae 0 (coordinateShift n f),coordinateShift_ae n f,polarDiagonal_ae n f] with x hu hd hv ha + ext j + change coordinateShift (-n) (polarDiagonal 0 (coordinateShift n f)) x j = polarDiagonal n f x j + rw [hu,hd,hv,ha] + simp only [sub_neg_eq_add,add_zero,add_sub_cancel_right] + +def betaRootSymbol : DiagonalSymbol := + ⟨fun x j => (Real.sqrt (explicitBeta x j):ℂ), + ⟨fun j => Complex.continuous_ofReal.measurable.comp (Real.continuous_sqrt.measurable.comp (measurable_explicitBeta j)), + 1, zero_le_one, fun x j => by + simp only [Complex.norm_real,Real.norm_of_nonneg (Real.sqrt_nonneg _)] + apply Real.sqrt_le_one.mpr + exact (explicitBeta_le x j).trans (Real.exp_le_one_iff.mpr (by norm_num))⟩⟩ +lemma betaRootSymbol_star : star betaRootSymbol = betaRootSymbol := by + apply Subtype.ext + funext x j + exact Complex.conj_ofReal _ +lemma betaRootSymbol_sq : betaRootSymbol * betaRootSymbol = betaSymbol 0 := by + apply Subtype.ext + funext x j + change (Real.sqrt (explicitBeta x j):ℂ) * (Real.sqrt (explicitBeta x j):ℂ) = (explicitBeta x (j+0):ℂ) + rw [add_zero,←Complex.ofReal_mul,Real.mul_self_sqrt (explicitBeta_pos _ _).le] +lemma polarDiagonal_nonneg : 0 ≤ polarDiagonal 0 := by + have h := star_mul_self_nonneg (diagonalOperator betaRootSymbol) + rwa [←diagonalOperator_star,betaRootSymbol_star,←diagonalOperator_mul,betaRootSymbol_sq] at h +local instance realOperatorTower : IsScalarTower ℝ (GlobalHilbert →L[ℂ] GlobalHilbert) (GlobalHilbert →L[ℂ] GlobalHilbert) where + smul_assoc scalar first second := by ext vector; rfl +local instance realOperatorCommute : SMulCommClass ℝ (GlobalHilbert →L[ℂ] GlobalHilbert) (GlobalHilbert →L[ℂ] GlobalHilbert) where + smul_comm scalar first second := by + apply ContinuousLinearMap.ext + intro vector + exact (first.map_smul_of_tower scalar (second vector)).symm +local instance complexNormalCalculus : ContinuousFunctionalCalculus ℂ (GlobalHilbert →L[ℂ] GlobalHilbert) IsStarNormal := + IsStarNormal.instContinuousFunctionalCalculus +local instance complexClosedCalculus : NonUnitalClosedEmbeddingContinuousFunctionalCalculus ℂ (GlobalHilbert →L[ℂ] GlobalHilbert) IsStarNormal := + IsStarNormal.instNonUnitalContinuousFunctionalCalculus +local instance realSelfAdjointCalculus : NonUnitalContinuousFunctionalCalculus ℝ (GlobalHilbert →L[ℂ] GlobalHilbert) IsSelfAdjoint := + IsSelfAdjoint.instNonUnitalContinuousFunctionalCalculus (A := GlobalHilbert →L[ℂ] GlobalHilbert) +lemma polar_modulus : CFC.sqrt (star forwardOperator * forwardOperator) = polarDiagonal 0 := by + rw [forward_polar_factor,star_mul,coordinateShift_star,mul_assoc, + ←mul_assoc (coordinateShift (-1)) (coordinateShift 1),←coordinateShift_add] + norm_num only [Int.reduceNeg,Int.reduceAdd,coordinateShift_zero,one_mul] + rw [(polarDiagonal_selfAdjoint 0).star_eq] + exact CFC.sqrt_mul_self _ polarDiagonal_nonneg +lemma polarDiagonal_injective : Function.Injective (polarDiagonal 0) := by + intro f g he + apply Lp.ext + filter_upwards [polarDiagonal_ae 0 f,polarDiagonal_ae 0 g] with x hf hg + ext j + have h := congrArg (fun v : GlobalHilbert => v x j) he + rw [hf,hg] at h + exact mul_left_cancel₀ (by exact_mod_cast (explicitBeta_pos x (j+0)).ne') h +lemma polarDiagonal_denseRange : DenseRange (polarDiagonal 0) := by + have hk : (polarDiagonal 0).ker = ⊥ := LinearMap.ker_eq_bot.mpr polarDiagonal_injective + have hadj : (polarDiagonal 0).adjoint = polarDiagonal 0 := (polarDiagonal_selfAdjoint 0).star_eq + have hc : (polarDiagonal 0).range.topologicalClosure = ⊤ := by + rw [←Submodule.orthogonal_orthogonal_eq_closure,ContinuousLinearMap.orthogonal_range,hadj,hk,Submodule.bot_orthogonal_eq_top] + intro v + change v ∈ (polarDiagonal 0).range.topologicalClosure + rw [hc] + trivial + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/ProductSymbols.lean b/lean/OAI/Analysis/BackwardIntertwiners/ProductSymbols.lean new file mode 100644 index 0000000000000000000000000000000000000000..f1a65e2c61506d182382129b1e40aa6a537b82f8 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/ProductSymbols.lean @@ -0,0 +1,111 @@ +import OAI.Analysis.BackwardIntertwiners.AtomicAlgebras + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +attribute [local instance] realOperatorTower realOperatorCommute complexNormalCalculus complexClosedCalculus realSelfAdjointCalculus + +open InnerProductSpace ContinuousLinearMap + +lemma linfty_ae_norm_le {X : Type*} [MeasurableSpace X] {μ : Measure X} (g : Lp ℂ ∞ μ) : + ∀ᵐ z ∂μ, ‖g z‖ ≤ ‖g‖ := by + filter_upwards [enorm_ae_le_eLpNormEssSup g μ] with z hz + have hg : eLpNormEssSup g μ ≠ ∞ := by + simpa only [eLpNorm_exponent_top (Lp.aestronglyMeasurable g)] using Lp.eLpNorm_ne_top g + have hh := ENNReal.toReal_mono hg hz + simpa only [Lp.norm_def,eLpNorm_exponent_top (Lp.aestronglyMeasurable g), toReal_enorm] using hh + +lemma ae_prod_count_iff {X : Type*} [MeasurableSpace X] {μ : Measure X} + {p : X × ℤ → Prop} (hp : MeasurableSet {z | p z}) : + (∀ᵐ z ∂μ.prod Measure.count, p z) ↔ ∀ᵐ x ∂μ, ∀ j : ℤ, p (x,j) := by + rw [Measure.ae_prod_iff_ae_ae hp] + simp_rw [Measure.ae_count_iff] + + + +abbrev productMeasure : Measure (Base × ℤ) := baseMeasure.prod Measure.count + +def IsProductMultiplier (T : GlobalHilbert →L[ℂ] GlobalHilbert) : Prop := + ∃ g : Lp ℂ ∞ productMeasure, ∀ f : GlobalHilbert, + ∀ᵐ x ∂baseMeasure, ∀ j : ℤ, T f x j = g (x,j) * f x j + +lemma DiagonalSymbol.product_measurable (a : DiagonalSymbol) : + Measurable (fun z : Base × ℤ => a z.1 z.2) := + measurable_from_prod_countable_left a.measurable +lemma DiagonalSymbol.product_memLp (a : DiagonalSymbol) : + MemLp (fun z : Base × ℤ => a z.1 z.2) ∞ productMeasure := + memLp_top_of_bound a.product_measurable.aestronglyMeasurable a.bound + (Eventually.of_forall fun z => a.norm_le_bound z.1 z.2) +lemma diagonalOperator_isProductMultiplier (a : DiagonalSymbol) : + IsProductMultiplier (diagonalOperator a) := by + let g : Lp ℂ ∞ productMeasure := a.product_memLp.toLp (fun z : Base × ℤ => a z.1 z.2) + have hg : ∀ᵐ x ∂baseMeasure, ∀ j : ℤ, g (x,j) = a x j := by + have hh := Measure.ae_ae_of_ae_prod (MemLp.coeFn_toLp a.product_memLp) + simpa only [Measure.ae_count_iff] using hh + refine ⟨g,fun f => ?_⟩ + filter_upwards [diagonalOperator_coord a f,hg] with x hx hgx j + rw [hx,hgx] + +def productBoundedSymbol (g : Lp ℂ ∞ productMeasure) : DiagonalSymbol := + ⟨fun x j => if ‖g (x,j)‖ ≤ ‖g‖ then g (x,j) else 0, + (by + refine ⟨?_,‖g‖,norm_nonneg _,?_⟩ + · intro j + have hm : Measurable (fun x : Base => g (x,j)) := + (Lp.stronglyMeasurable g).measurable.comp (measurable_id.prodMk measurable_const) + exact Measurable.ite (measurableSet_le hm.norm measurable_const) hm measurable_const + · intro x j + dsimp only + split_ifs with h + · exact h + · simp)⟩ +lemma productBoundedSymbol_ae (g : Lp ℂ ∞ productMeasure) : + ∀ᵐ x ∂baseMeasure, ∀ j : ℤ, productBoundedSymbol g x j = g (x,j) := by + have hh := Measure.ae_ae_of_ae_prod (linfty_ae_norm_le g) + simp_rw [Measure.ae_count_iff] at hh + filter_upwards [hh] with x hx j + exact ite_eq_left (hx j) +lemma isProductMultiplier_mem_full {T : GlobalHilbert →L[ℂ] GlobalHilbert} + (hT : IsProductMultiplier T) : T ∈ fullMultiplierAlgebra := by + obtain ⟨g,hg⟩ := hT + refine ⟨productBoundedSymbol g,?_⟩ + ext1 f + apply Lp.ext + filter_upwards [diagonalOperator_coord (productBoundedSymbol g) f, + productBoundedSymbol_ae g,hg f] with x ha hsym hT + ext j + change diagonalOperator (productBoundedSymbol g) f x j = T f x j + rw [ha,hsym,hT] +lemma fullMultiplier_mem_iff_productMultiplier (T : GlobalHilbert →L[ℂ] GlobalHilbert) : + T ∈ fullMultiplierAlgebra ↔ IsProductMultiplier T := by + constructor + · rintro ⟨a,rfl⟩ + exact diagonalOperator_isProductMultiplier a + · exact isProductMultiplier_mem_full + + + +theorem polarAlgebra_mem_iff_productMultiplier (T : GlobalHilbert →L[ℂ] GlobalHilbert) : + T ∈ polarAlgebra ↔ IsProductMultiplier T := by + rw [polarAlgebra_eq_fullMultiplier] + exact fullMultiplier_mem_iff_productMultiplier T + + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/SpectralProjections.lean b/lean/OAI/Analysis/BackwardIntertwiners/SpectralProjections.lean new file mode 100644 index 0000000000000000000000000000000000000000..b4ce1a59f5f2931accb9d227eec2f61edad6ac6a --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/SpectralProjections.lean @@ -0,0 +1,369 @@ +import OAI.Analysis.BackwardIntertwiners.PolarDiagonals + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + + +def polarAlgebra : StarSubalgebra ℂ (GlobalHilbert →L[ℂ] GlobalHilbert) := strongGenerated (Set.range polarDiagonal) +lemma polarDiagonal_mem (n : ℤ) : polarDiagonal n ∈ polarAlgebra := subset_strongGenerated _ ⟨n,rfl⟩ +lemma polarAlgebra_closed : StronglyClosed polarAlgebra := strongGenerated_closed _ +lemma polarAlgebra_le_full : polarAlgebra ≤ fullMultiplierAlgebra := by + apply strongGenerated_le fullMultiplier_stronglyClosed + rintro _ ⟨n,rfl⟩ + exact ⟨betaSymbol n,rfl⟩ +lemma polarAlgebra_commutative {A B : GlobalHilbert →L[ℂ] GlobalHilbert} + (hA : A ∈ polarAlgebra) (hB : B ∈ polarAlgebra) : A*B=B*A := + fullMultiplier_commute (polarAlgebra_le_full hA) (polarAlgebra_le_full hB) + +lemma halfExponent_eq_ten_iff (t : ℕ → ℕ) (k : ℕ) : halfExponent t k=10 ↔ k=0 := by + constructor + · intro h + have hl := halfExponent_lower t k + rw [h] at hl + have hk : (k:ℝ)=0 := by have := Nat.cast_nonneg (α:=ℝ) k; nlinarith + exact_mod_cast hk + · rintro rfl + simp [halfExponent,residueCorrection] +lemma explicitBeta_central (x : Base) (j : ℤ) : explicitBeta x j=Real.exp (-10) ↔ j=-1 ∨ j=0 := by + have hh (t : ℕ → ℕ) (k : ℕ) : Real.exp (-halfExponent t k)=Real.exp (-10) ↔ k=0 := by + rw [Real.exp_eq_exp,neg_inj,halfExponent_eq_ten_iff] + cases j with + | ofNat k => + change Real.exp (-halfExponent (plusResidue x) k)=Real.exp (-10) ↔ _ + rw [hh] + change k=0 ↔ (k:ℤ) = -1 ∨ (k:ℤ) = 0 + omega + | negSucc k => + change Real.exp (-halfExponent (minusResidue x) k)=Real.exp (-10) ↔ _ + rw [hh] + omega +lemma sliceProjection_central (r : ℤ) : sliceProjection r= + levelProjection (-r-1) (Real.exp (-10)) * levelProjection (-r) (Real.exp (-10)) := by + rw [sliceProjection_diagonal,levelProjection,levelProjection,diagonalProjection_mul] + apply diagonalProjection_ext + intro j + apply EventuallyEq.of_eq + ext x + change (x ∈ if j=r then Set.univ else ∅) ↔ + (explicitBeta x (j+(-r-1))=Real.exp (-10) ∧ explicitBeta x (j+-r)=Real.exp (-10)) + simp only [explicitBeta_central] + by_cases hj : j=r <;> simp [hj] <;> omega +lemma sliceProjection_mem_polar (r : ℤ) : sliceProjection r ∈ polarAlgebra := by + rw [sliceProjection_central] + exact polarAlgebra.mul_mem + (levelProjection_mem_all polarAlgebra_closed _ _ (polarDiagonal_mem _)) + (levelProjection_mem_all polarAlgebra_closed _ _ (polarDiagonal_mem _)) + + +def rectangleProjection (r : ℤ) (E : Set Base) (hE : MeasurableSet E) : GlobalHilbert →L[ℂ] GlobalHilbert := + diagonalProjection (fun j => if j=r then E else ∅) (fun j => by split_ifs; exact hE; exact MeasurableSet.empty) +lemma rectangleProjection_univ (r : ℤ) : rectangleProjection r Set.univ MeasurableSet.univ=sliceProjection r := + (sliceProjection_diagonal r).symm +lemma rectangleProjection_empty (r : ℤ) : rectangleProjection r ∅ MeasurableSet.empty=0 := by + unfold rectangleProjection + convert diagonalProjection_empty using 2 + ext j x + simp +lemma rectangleProjection_ext {r : ℤ} {E F : Set Base} {hE : MeasurableSet E} {hF : MeasurableSet F} + (he : E=ᵐ[baseMeasure] F) : rectangleProjection r E hE=rectangleProjection r F hF := by + apply diagonalProjection_ext + intro j + by_cases hj : j=r <;> simp only [hj,↓reduceIte] + · exact he + · exact Filter.EventuallyEq.rfl +lemma rectangleProjection_mul (r : ℤ) (E F : Set Base) (hE : MeasurableSet E) (hF : MeasurableSet F) : + rectangleProjection r E hE * rectangleProjection r F hF=rectangleProjection r (E∩F) (hE.inter hF) := by + rw [rectangleProjection,rectangleProjection,diagonalProjection_mul] + apply diagonalProjection_ext + intro j + apply EventuallyEq.of_eq + by_cases hj : j=r <;> simp only [hj,↓reduceIte,Set.inter_empty] +lemma rectangleProjection_compl (r : ℤ) (E : Set Base) (hE : MeasurableSet E) : + rectangleProjection r Eᶜ hE.compl = sliceProjection r - rectangleProjection r E hE := by + rw [sliceProjection_diagonal] + change diagonalRepresentation _ = diagonalRepresentation _ - diagonalRepresentation _ + rw [←map_sub] + congr 1 + apply Subtype.ext + funext x j + change projectionSymbol _ _ x j = projectionSymbol _ _ x j - projectionSymbol _ _ x j + by_cases hj : j=r <;> by_cases he : x∈E <;> simp [hj,he] +lemma rectangleProjection_union (r : ℤ) (E F : Set Base) (hE : MeasurableSet E) (hF : MeasurableSet F) : + rectangleProjection r (E∪F) (hE.union hF) = rectangleProjection r E hE+rectangleProjection r F hF- + rectangleProjection r E hE * rectangleProjection r F hF := by + change diagonalRepresentation _ = diagonalRepresentation _+diagonalRepresentation _-diagonalRepresentation _*diagonalRepresentation _ + rw [←map_mul,←map_add,←map_sub] + congr 1 + apply Subtype.ext + funext x j + change projectionSymbol _ _ x j = projectionSymbol _ _ x j + projectionSymbol _ _ x j - projectionSymbol _ _ x j * projectionSymbol _ _ x j + by_cases hj : j=r <;> by_cases he : x∈E <;> by_cases hf : x∈F <;> simp [hj,he,hf] + +def blockAnchor (m : ℕ) : ℕ := 8^(m-1) +lemma blockAnchor_ne_zero (m : ℕ) : blockAnchor m ≠ 0 := pow_ne_zero _ (by norm_num) +lemma blockAnchor_block {m : ℕ} (hm : 1 ≤ m) : weightBlock (blockAnchor m)=m := by + rw [weightBlock,blockAnchor,Nat.log_pow (by norm_num : 1<8)] + omega +def residueEigenvalue (m t : ℕ) : ℝ := + Real.exp (-(10*((blockAnchor m:ℝ)+1)+100*((2^m:ℝ)-2+(t:ℝ)))) +lemma beta_anchor_residue {m : ℕ} (hm : 1 ≤ m) (t : ℕ) (x : Base) : + explicitBeta x (blockAnchor m) = residueEigenvalue m t ↔ residue m x=t := by + change Real.exp (-halfExponent (plusResidue x) (blockAnchor m))=residueEigenvalue m t ↔ _ + rw [residueEigenvalue,Real.exp_eq_exp,neg_inj] + simp only [halfExponent,residueCorrection,blockAnchor_ne_zero,↓reduceIte, + residueScale,blockAnchor_block hm,plusResidue] + push_cast + constructor + · intro h + have he : (residue m x:ℝ)=(t:ℝ) := by linarith + exact_mod_cast he + · intro h + rw [h] +lemma residue_rectangle_spectral {m : ℕ} (hm : 1 ≤ m) (t : ℕ) (r : ℤ) : + rectangleProjection r (residueClass m t) (measurableSet_residueClass m t) = + sliceProjection r * levelProjection ((blockAnchor m:ℤ)-r) (residueEigenvalue m t) := by + rw [sliceProjection_diagonal,levelProjection,diagonalProjection_mul] + apply diagonalProjection_ext + intro j + apply EventuallyEq.of_eq + ext x + by_cases hj : j=r + · subst j + + + simp only [↓reduceIte,Set.mem_inter_iff,Set.mem_univ,true_and,Set.mem_ofPred_eq] + change residue m x=t ↔ explicitBeta x (r+((blockAnchor m:ℤ)-r))=residueEigenvalue m t + rw [show r+((blockAnchor m:ℤ)-r)=(blockAnchor m:ℤ) by omega] + exact (beta_anchor_residue hm t x).symm + · simp [hj] +lemma residue_rectangle_mem (m t : ℕ) (r : ℤ) : + rectangleProjection r (residueClass m t) (measurableSet_residueClass m t) ∈ polarAlgebra := by + by_cases hm : m=0 + · subst m + have hz (x : Base) : residue 0 x=0 := by have := residue_lt 0 x; norm_num at this; omega + by_cases ht : t=0 + · have he : residueClass 0 t=Set.univ := by ext x; simp [residueClass,hz,ht] + have hr : rectangleProjection r (residueClass 0 t) (measurableSet_residueClass 0 t)=sliceProjection r := by + exact (rectangleProjection_ext (EventuallyEq.of_eq he)).trans (rectangleProjection_univ r) + rw [hr] + exact sliceProjection_mem_polar _ + · have he : residueClass 0 t=∅ := by ext x; simp [residueClass,hz,Ne.symm ht] + have hr : rectangleProjection r (residueClass 0 t) (measurableSet_residueClass 0 t)=0 := by + exact (rectangleProjection_ext (EventuallyEq.of_eq he)).trans (rectangleProjection_empty r) + rw [hr] + exact polarAlgebra.zero_mem + · rw [residue_rectangle_spectral (by omega : 1 ≤ m)] + exact polarAlgebra.mul_mem (sliceProjection_mem_polar _) + (levelProjection_mem_all polarAlgebra_closed _ _ (polarDiagonal_mem _)) + +lemma borel_le_of_residue_measurable (m : MeasurableSpace (PadicInt 2)) + (hm : ∀ n t : ℕ, @MeasurableSet (PadicInt 2) m {x | twoResidue n x=t}) : + padicBorel ≤ m := by + let : MeasurableSpace (PadicInt 2) := padicBorel + let R : PadicInt 2 → ℕ → ℕ := fun x n => twoResidue n x + have hc : Continuous R := continuous_pi fun n => + continuous_of_discreteTopology.comp (continuous_twoResidue n) + have hi : Function.Injective R := by + intro x y h + apply PadicInt.ext_of_toZModPow.mp + intro n + apply ZMod.val_injective + exact congrFun h n + have he : MeasurableEmbedding R := (hc.isClosedEmbedding hi).measurableEmbedding + have hr : @Measurable _ _ m inferInstance R := by + let : MeasurableSpace (PadicInt 2) := m + apply Measurable.of_eval + intro n + exact measurable_to_countable' (hm n) + exact he.comap_eq.symm.le.trans hr.comap_le + +lemma rectangleProjection_finiteUnion_mem (r : ℤ) (E : ℕ → Set Base) + (hE : ∀ i, MeasurableSet (E i)) (hmem : ∀ i, rectangleProjection r (E i) (hE i) ∈ polarAlgebra) + (s : Finset ℕ) : rectangleProjection r (⋃ i ∈ s, E i) (by measurability) ∈ polarAlgebra := by + induction s using Finset.induction_on with + | empty => + have he : (⋃ i ∈ (∅:Finset ℕ), E i)=∅ := by simp + have hp : rectangleProjection r (⋃ i ∈ (∅ : Finset ℕ), E i) (by measurability) = + rectangleProjection r ∅ MeasurableSet.empty := rectangleProjection_ext (EventuallyEq.of_eq he) + rw [hp, rectangleProjection_empty] + exact polarAlgebra.zero_mem + | @insert i s hi hs => + have he : (⋃ k ∈ insert i s, E k)=E i ∪ ⋃ k ∈ s,E k := by simp + have hp : rectangleProjection r (⋃ k ∈ insert i s, E k) (by measurability) = + rectangleProjection r (E i ∪ ⋃ k ∈ s, E k) ((hE i).union (by measurability)) := + rectangleProjection_ext (EventuallyEq.of_eq he) + rw [hp, + rectangleProjection_union r (E i) (⋃ k∈s,E k) (hE i) (by measurability)] + exact polarAlgebra.sub_mem (polarAlgebra.add_mem (hmem i) hs) (polarAlgebra.mul_mem (hmem i) hs) + +lemma rectangleProjection_iUnion_mem (r : ℤ) (E : ℕ → Set Base) + (hE : ∀ i, MeasurableSet (E i)) (hmem : ∀ i, rectangleProjection r (E i) (hE i) ∈ polarAlgebra) : + rectangleProjection r (⋃ i, E i) (MeasurableSet.iUnion hE) ∈ polarAlgebra := by + let a (s : Finset ℕ) : DiagonalSymbol := projectionSymbol + (fun j => if j=r then ⋃i∈s,E i else ∅) (fun j => by split_ifs <;> measurability) + let b : DiagonalSymbol := projectionSymbol + (fun j => if j=r then ⋃i,E i else ∅) (fun j => by split_ifs <;> measurability) + apply polarAlgebra_closed.mem_of_tendsto (l:=atTop) (T:=fun s => diagonalOperator (a s)) + · exact Eventually.of_forall (rectangleProjection_finiteUnion_mem r E hE hmem) + · intro f + apply diagonalOperator_tendsto (b:=b) a zero_le_one + (fun s => projectionSymbol_norm_le _ _) (projectionSymbol_norm_le _ _) + apply Eventually.of_forall + intro x j + apply tendsto_const_nhds.congr' + by_cases hj : j=r + · by_cases hx : x ∈ ⋃i,E i + · obtain ⟨i,hi⟩ := Set.mem_iUnion.mp hx + filter_upwards [eventually_ge_atTop ({i}:Finset ℕ)] with s hs + have his : i∈s := Finset.singleton_subset_iff.mp hs + have hxs : x∈⋃i∈s,E i := Set.mem_iUnion.mpr ⟨i,Set.mem_iUnion.mpr ⟨his,hi⟩⟩ + simp [a,b,hj,hx,hxs] + · exact Eventually.of_forall (fun s => by + have hxs : x ∉ ⋃i∈s,E i := fun h => hx (by + obtain ⟨i,hi,hiE⟩ := Set.mem_iUnion.mp h |>.imp (fun i hi => Set.mem_iUnion.mp hi) + exact Set.mem_iUnion.mpr ⟨i,hiE⟩) + simp [a,b,hj,hx,hxs]) + · exact Eventually.of_forall (fun s=>by simp [a,b,hj]) + + +@[instance_reducible] +def polarProjectionMeasurableSpace (r : ℤ) : MeasurableSpace Base where + MeasurableSet' E := ∃ hE : MeasurableSet E, rectangleProjection r E hE ∈ polarAlgebra + measurableSet_empty := ⟨MeasurableSet.empty,by rw [rectangleProjection_empty]; exact polarAlgebra.zero_mem⟩ + measurableSet_compl E h := by + obtain ⟨hE,hm⟩ := h + refine ⟨hE.compl,?_⟩ + rw [rectangleProjection_compl r E hE] + exact polarAlgebra.sub_mem (sliceProjection_mem_polar r) hm + measurableSet_iUnion E h := by + choose hE hm using h + exact ⟨MeasurableSet.iUnion hE,rectangleProjection_iUnion_mem r E hE hm⟩ + +lemma rectangleProjection_borel_mem (r : ℤ) {E : Set (PadicInt 2)} (hE : MeasurableSet E) : + rectangleProjection r E (hE.nullMeasurableSet (μ:=baseHaar)) ∈ polarAlgebra := by + have hm : padicBorel ≤ polarProjectionMeasurableSpace r := + borel_le_of_residue_measurable _ (fun m t => + ⟨measurableSet_residueClass m t,residue_rectangle_mem m t r⟩) + exact (hm E hE).choose_spec + +lemma rectangleProjection_mem (r : ℤ) (E : Set Base) (hE : MeasurableSet E) : + rectangleProjection r E hE ∈ polarAlgebra := by + obtain ⟨F,hsub,hF,he⟩ := (show NullMeasurableSet (show Set (PadicInt 2) from E) baseHaar from hE).exists_measurable_superset_ae_eq + have he' : (show Set Base from F)=ᵐ[baseMeasure] E := he + rw [←rectangleProjection_ext (hE:=hF.nullMeasurableSet (μ:=baseHaar)) he'] + exact rectangleProjection_borel_mem r hF +lemma DiagonalSymbol.sum_apply {ι : Type*} (s : Finset ι) (a : ι → DiagonalSymbol) (x : Base) (j : ℤ) : + (∑ i ∈ s, a i) x j = ∑ i ∈ s, a i x j := by + induction s using Finset.induction_on with + | empty => simp + | @insert i s hi hs => simp [Finset.sum_insert,hi,hs] + + +def simpleSliceSymbol (r : ℤ) (f : SimpleFunc Base ℂ) : DiagonalSymbol := + ∑ t ∈ f.range, t • projectionSymbol + (fun j => if j=r then f ⁻¹' {t} else ∅) + (fun j=>by split_ifs; exact f.measurableSet_fiber t; exact MeasurableSet.empty) +lemma simpleSliceSymbol_apply (r : ℤ) (f : SimpleFunc Base ℂ) (x : Base) (j : ℤ) : + simpleSliceSymbol r f x j=if j=r then f x else 0 := by + simp only [simpleSliceSymbol,DiagonalSymbol.sum_apply,DiagonalSymbol.smul_apply,projectionSymbol_apply] + by_cases hj : j=r + · simp only [hj,↓reduceIte,Set.mem_preimage,Set.mem_singleton_iff,mul_ite,mul_one,mul_zero] + rw [Finset.sum_eq_single (f x)] + · simp + · intro b hb hbx + simp [Ne.symm hbx] + · exact fun hn => (hn (f.mem_range_self x)).elim + · simp [hj] +lemma simpleSliceSymbol_mem (r : ℤ) (f : SimpleFunc Base ℂ) : diagonalOperator (simpleSliceSymbol r f) ∈ polarAlgebra := by + change diagonalRepresentation (∑ t ∈ f.range, _) ∈ polarAlgebra + rw [map_sum] + apply polarAlgebra.sum_mem + intro t ht + rw [map_smul] + exact polarAlgebra.smul_mem (rectangleProjection_mem r (f ⁻¹' {t}) (f.measurableSet_fiber t)) t + +def sliceSymbol (r : ℤ) (a : DiagonalSymbol) : DiagonalSymbol := + a * projectionSymbol (fun j=>if j=r then Set.univ else ∅) (fun j=>by split_ifs <;> measurability) +lemma sliceSymbol_apply (r : ℤ) (a : DiagonalSymbol) (x : Base) (j : ℤ) : + sliceSymbol r a x j=if j=r then a x r else 0 := by + by_cases hj : j=r <;> simp [sliceSymbol,hj] +lemma sliceSymbol_norm_le (r : ℤ) (a : DiagonalSymbol) (x : Base) (j : ℤ) : + ‖sliceSymbol r a x j‖ ≤ a.bound := by + rw [sliceSymbol_apply] + split_ifs + · exact a.norm_le_bound x r + · simpa using a.bound_nonneg +lemma sliceSymbol_mem (r : ℤ) (a : DiagonalSymbol) : diagonalOperator (sliceSymbol r a) ∈ polarAlgebra := by + let f (n : ℕ) : SimpleFunc Base ℂ := SimpleFunc.approxOn (fun x=>a x r) (a.measurable r) Set.univ 0 (Set.mem_univ _) n + apply polarAlgebra_closed.mem_of_tendsto (l:=atTop) (T:=fun n=>diagonalOperator (simpleSliceSymbol r (f n))) + · exact Eventually.of_forall (fun n=>simpleSliceSymbol_mem r (f n)) + · intro v + apply diagonalOperator_tendsto (C:=2*a.bound) _ _ (mul_nonneg (by norm_num) a.bound_nonneg) + · intro n x j + rw [simpleSliceSymbol_apply] + split_ifs + · exact (SimpleFunc.norm_approxOn_zero_le (a.measurable r) (Set.mem_univ (0:ℂ)) x n).trans + (by linarith [a.norm_le_bound x r]) + · simpa using mul_nonneg (by norm_num : (0:ℝ) ≤ 2) a.bound_nonneg + · intro x j + exact (sliceSymbol_norm_le r a x j).trans (by linarith [a.bound_nonneg]) + · apply Eventually.of_forall + intro x j + simp only [simpleSliceSymbol_apply,sliceSymbol_apply] + by_cases hj : j=r + · simp only [hj,↓reduceIte] + exact SimpleFunc.tendsto_approxOn (a.measurable r) (Set.mem_univ (0:ℂ)) (by simp) + · simp only [hj,↓reduceIte] + exact tendsto_const_nhds + +lemma finiteSliceSymbol_apply (s : Finset ℤ) (a : DiagonalSymbol) (x : Base) (j : ℤ) : + (∑ r ∈ s,sliceSymbol r a) x j=if j∈s then a x j else 0 := by + rw [DiagonalSymbol.sum_apply] + simp_rw [sliceSymbol_apply] + simp +lemma diagonalOperator_mem_polar (a : DiagonalSymbol) : diagonalOperator a ∈ polarAlgebra := by + let T (s : Finset ℤ) : GlobalHilbert →L[ℂ] GlobalHilbert := diagonalOperator (∑ r ∈ s,sliceSymbol r a) + apply polarAlgebra_closed.mem_of_tendsto (l:=atTop) (T:=T) + · apply Eventually.of_forall + intro s + change diagonalRepresentation (∑ r ∈ s,sliceSymbol r a) ∈ polarAlgebra + rw [map_sum] + exact polarAlgebra.sum_mem (fun r _=>sliceSymbol_mem r a) + · intro v + apply diagonalOperator_tendsto (C:=a.bound) _ _ a.bound_nonneg + · intro s x j + rw [finiteSliceSymbol_apply] + split_ifs + · exact a.norm_le_bound x j + · simpa using a.bound_nonneg + · exact a.norm_le_bound + · apply Eventually.of_forall + intro x j + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop ({j}:Finset ℤ)] with s hs + rw [finiteSliceSymbol_apply,ite_eq_left (Finset.singleton_subset_iff.mp hs)] + + + +theorem polarAlgebra_eq_fullMultiplier : polarAlgebra=fullMultiplierAlgebra := by + apply le_antisymm polarAlgebra_le_full + rintro T ⟨a,rfl⟩ + exact diagonalOperator_mem_polar a + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/StrongClosure.lean b/lean/OAI/Analysis/BackwardIntertwiners/StrongClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..e8fed7ff3b92b1a819377ed5e3ecc45c4f270f50 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/StrongClosure.lean @@ -0,0 +1,208 @@ +import OAI.Analysis.BackwardIntertwiners.DiagonalSymbols + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + +open Topology MeasureTheory Set +open scoped ENNReal + +open scoped Classical + +lemma L2_norm_eq_sqrt {X E : Type*} [MeasurableSpace X] [NormedAddCommGroup E] + {μ : Measure X} (f : Lp E 2 μ) : + ‖f‖ = Real.sqrt (∫ x, ‖f x‖^2 ∂μ) := by + rw [Lp.norm_def, toReal_eLpNorm, + lpNorm_eq_integral_norm_rpow_toReal (by norm_num : (2:ENNReal) ≠ 0) + (by norm_num : (2:ENNReal) ≠ ∞) (Lp.aestronglyMeasurable f)] + simp [Real.sqrt_eq_rpow] + +lemma L2_tendsto_zero_of_dominated {X E ι : Type*} {l : Filter ι} [l.IsCountablyGenerated] [MeasurableSpace X] [NormedAddCommGroup E] + {μ : Measure X} (F : ι → Lp E 2 μ) (b : X → ℝ) + (hb : Integrable (fun x => b x ^ 2) μ) + (hB : ∀ n, ∀ᵐ x ∂μ, ‖F n x‖ ≤ b x) + (hlim : ∀ᵐ x ∂μ, Tendsto (fun n => F n x) l (𝓝 0)) : + Tendsto F l (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + have hi : Tendsto (fun n => ∫ x, ‖F n x‖^2 ∂μ) l (𝓝 0) := by + simpa using tendsto_integral_filter_of_dominated_convergence (f:=fun _ : X => (0:ℝ)) + (fun x => b x^2) + (Eventually.of_forall fun n => ((Lp.aestronglyMeasurable (F n)).norm.aemeasurable.pow_const 2).aestronglyMeasurable) + (Eventually.of_forall fun n => (hB n).mono fun x hx => by + rw [Real.norm_of_nonneg (sq_nonneg _)] + exact pow_le_pow_left₀ (norm_nonneg _) hx 2) hb + (hlim.mono fun x hx => by simpa using hx.norm.pow 2) + simpa only [Function.comp_def, Real.sqrt_zero, L2_norm_eq_sqrt] using Real.continuous_sqrt.continuousAt.tendsto.comp hi + +lemma fiber_norm_sq (v : Fiber) : ‖v‖^2 = ∑' j, ‖v j‖^2 := by + simpa using lp.norm_rpow_eq_tsum (by norm_num : (0:ℝ) < (2:ENNReal).toReal) v +lemma fiber_tendsto_zero_of_dominated {ι : Type*} {l : Filter ι} (v : ι → Fiber) (b : ℤ → ℝ) + (hb : Summable (fun j => b j^2)) + (hB : ∀ n j, ‖v n j‖ ≤ b j) + (hlim : ∀ j, Tendsto (fun n => v n j) l (𝓝 0)) : + Tendsto v l (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + have hi : Tendsto (fun n => ‖v n‖^2) l (𝓝 0) := by + simp_rw [fiber_norm_sq] + simpa using tendsto_tsum_of_dominated_convergence (g:=fun _ : ℤ => (0:ℝ)) hb + (fun j => by simpa using (hlim j).norm.pow 2) + (Filter.Eventually.of_forall fun n j => by + rw [Real.norm_of_nonneg (sq_nonneg _)] + exact pow_le_pow_left₀ (norm_nonneg _) (hB n j) 2) + simpa only [Function.comp_def, Real.sqrt_zero, Real.sqrt_sq_eq_abs,abs_of_nonneg (norm_nonneg _)] + using Real.continuous_sqrt.continuousAt.tendsto.comp hi +lemma diagonalFiber_bound (a : DiagonalSymbol) {C : ℝ} (hC : 0 ≤ C) + (ha : ∀ x j, ‖a x j‖ ≤ C) (x : Base) (v : Fiber) : + ‖diagonalFiber a x v‖ ≤ C*‖v‖ := by + calc + _ ≤ ‖(C:ℂ) • v‖ := by + apply lp.norm_mono (by norm_num : (2:ENNReal) ≠ 0) + intro j + simp only [diagonalFiber_apply,lp.coeFn_smul,Pi.smul_apply,norm_smul,norm_mul, + Complex.norm_real,Real.norm_of_nonneg hC] + exact mul_le_mul_of_nonneg_right (ha x j) (norm_nonneg _) + _ = C*‖v‖ := by rw [norm_smul,Complex.norm_real,Real.norm_of_nonneg hC] + +lemma diagonalFiber_tendsto_zero {ι : Type*} {l : Filter ι} (a : ι → DiagonalSymbol) {C : ℝ} + (ha : ∀ n x j, ‖a n x j‖ ≤ C) (x : Base) (v : Fiber) + (hlim : ∀ j, Tendsto (fun n => a n x j) l (𝓝 0)) : + Tendsto (fun n => diagonalFiber (a n) x v) l (𝓝 0) := by + apply fiber_tendsto_zero_of_dominated _ (fun j => C*‖v j‖) + · have hv : Summable (fun j => ‖v j‖^2) := by + simpa using (lp.memℓp v).summable (by norm_num : (0:ℝ) < (2:ENNReal).toReal) + simpa only [mul_pow] using hv.mul_left (C^2) + · intro n j + rw [diagonalFiber_apply,norm_mul] + exact mul_le_mul_of_nonneg_right (ha n x j) (norm_nonneg _) + · intro j + simpa using (hlim j).mul_const (v j) +lemma L2_integrable_bound_sq (f : GlobalHilbert) (C : ℝ) : + Integrable (fun x => (C*‖f x‖)^2) baseMeasure := by + have hf : Integrable (fun x => ‖f x‖^2) baseMeasure := + (Lp.memLp f).integrable_norm_pow (by norm_num : (2:ℕ) ≠ 0) + simpa only [mul_pow] using hf.const_mul (C^2) +lemma diagonalOperator_tendsto_zero {ι : Type*} [Countable ι] {l : Filter ι} [l.IsCountablyGenerated] (a : ι → DiagonalSymbol) {C : ℝ} + (hC : 0 ≤ C) (ha : ∀ n x j, ‖a n x j‖ ≤ C) + (hlim : ∀ᵐ x ∂baseMeasure, ∀ j, Tendsto (fun n => a n x j) l (𝓝 0)) + (f : GlobalHilbert) : Tendsto (fun n => diagonalOperator (a n) f) l (𝓝 0) := by + apply L2_tendsto_zero_of_dominated _ (fun x => C*‖f x‖) (L2_integrable_bound_sq f C) + · intro n + filter_upwards [diagonalOperator_ae (a n) f] with x hx + rw [hx] + exact diagonalFiber_bound _ hC (ha n) _ _ + · filter_upwards [hlim,ae_all_iff.mpr (fun n => diagonalOperator_ae (a n) f)] with x hx hn + have he : (fun n => diagonalOperator (a n) f x) = (fun n => diagonalFiber (a n) x (f x)) := funext hn + rw [he] + exact diagonalFiber_tendsto_zero a ha x (f x) hx +lemma diagonalOperator_tendsto {ι : Type*} [Countable ι] {l : Filter ι} [l.IsCountablyGenerated] (a : ι → DiagonalSymbol) (b : DiagonalSymbol) + {C : ℝ} (hC : 0 ≤ C) (ha : ∀ n x j, ‖a n x j‖ ≤ C) + (hb : ∀ x j, ‖b x j‖ ≤ C) + (hlim : ∀ᵐ x ∂baseMeasure, ∀ j, Tendsto (fun n => a n x j) l (𝓝 (b x j))) + (f : GlobalHilbert) : + Tendsto (fun n => diagonalOperator (a n) f) l (𝓝 (diagonalOperator b f)) := by + have hB : ∀ n x j, ‖(a n-b) x j‖ ≤ 2*C := fun n x j => + (norm_sub_le _ _).trans ((add_le_add (ha n x j) (hb x j)).trans_eq (by ring)) + have hl : ∀ᵐ x ∂baseMeasure, ∀ j, Tendsto (fun n => (a n-b) x j) l (𝓝 0) := by + filter_upwards [hlim] with x hx j + simpa only [DiagonalSymbol.sub_apply,sub_self] using (hx j).sub_const (b x j) + have hh := diagonalOperator_tendsto_zero (fun n => a n-b) (mul_nonneg (by norm_num) hC) hB hl f + have he (n : ι) : diagonalOperator (a n-b) f = diagonalOperator (a n) f - diagonalOperator b f := + congrArg (fun T : GlobalHilbert →L[ℂ] GlobalHilbert => T f) (map_sub diagonalRepresentation (a n) b) + simp_rw [he] at hh + exact tendsto_sub_nhds_zero_iff.mp hh + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [completeSpace : CompleteSpace H] + +@[instance_reducible] +def strongOperatorTopology : TopologicalSpace (H →L[ℂ] H) := + TopologicalSpace.induced (fun T : H →L[ℂ] H => (fun v : H => T v)) inferInstance + +def StronglyClosed (A : StarSubalgebra ℂ (H →L[ℂ] H)) : Prop := + @IsClosed (H →L[ℂ] H) strongOperatorTopology A + +omit completeSpace in +lemma strong_continuous_apply [CompleteSpace H] (v : H) : + @Continuous (H →L[ℂ] H) H strongOperatorTopology inferInstance (fun T => T v) := by + let := strongOperatorTopology (H:=H) + exact (continuous_apply v).comp continuous_induced_dom + +lemma StronglyClosed.mem_of_tendsto {A : StarSubalgebra ℂ (H →L[ℂ] H)} + (hA : StronglyClosed A) {ι : Type*} {l : Filter ι} [l.NeBot] + {T : ι → H →L[ℂ] H} {S : H →L[ℂ] H} + (hT : ∀ᶠ i in l, T i ∈ A) (hlim : ∀ v, Tendsto (fun i => T i v) l (𝓝 (S v))) : + S ∈ A := by + let := strongOperatorTopology (H:=H) + refine IsClosed.mem_of_tendsto hA (f:=T) ?_ hT + change Tendsto T l (@nhds (H →L[ℂ] H) (TopologicalSpace.induced _ _) S) + rw [nhds_induced,Filter.tendsto_comap_iff] + exact tendsto_pi_nhds.mpr hlim + + +def strongGenerated (s : Set (H →L[ℂ] H)) : StarSubalgebra ℂ (H →L[ℂ] H) := + sInf {A | StronglyClosed A ∧ s ⊆ A} +lemma mem_strongGenerated {s : Set (H →L[ℂ] H)} {T : H →L[ℂ] H} : + T ∈ strongGenerated s ↔ ∀ A : StarSubalgebra ℂ (H →L[ℂ] H), + StronglyClosed A → s ⊆ A → T ∈ A := by + simp [strongGenerated,StarSubalgebra.mem_sInf] +lemma subset_strongGenerated (s : Set (H →L[ℂ] H)) : s ⊆ strongGenerated s := by + intro T hT + exact mem_strongGenerated.mpr fun _ _ hs => hs hT +lemma strongGenerated_le {s : Set (H →L[ℂ] H)} {A : StarSubalgebra ℂ (H →L[ℂ] H)} + (hA : StronglyClosed A) (hs : s ⊆ A) : strongGenerated s ≤ A := + fun _ hT => mem_strongGenerated.mp hT A hA hs +lemma strongGenerated_closed (s : Set (H →L[ℂ] H)) : StronglyClosed (strongGenerated s) := by + let := strongOperatorTopology (H:=H) + have he : (strongGenerated s : Set (H →L[ℂ] H)) = + ⋂ A : StarSubalgebra ℂ (H →L[ℂ] H), ⋂ (_ : StronglyClosed A ∧ s ⊆ A), (A : Set _) := by + ext T + simp [mem_strongGenerated] + rw [StronglyClosed,he] + exact isClosed_iInter fun A => isClosed_iInter fun h => h.1 +lemma strongGenerated_mono {s t : Set (H →L[ℂ] H)} (hst : s ⊆ t) : + strongGenerated s ≤ strongGenerated t := + strongGenerated_le (strongGenerated_closed t) (hst.trans (subset_strongGenerated t)) + +lemma strong_centralizer_closed (s : Set (H →L[ℂ] H)) : + StronglyClosed (StarSubalgebra.centralizer ℂ s) := by + let := strongOperatorTopology (H:=H) + have he : (StarSubalgebra.centralizer ℂ s : Set (H →L[ℂ] H)) = + ⋂ A ∈ s ∪ star s, ⋂ v : H, {T | A (T v) = T (A v)} := by + ext T + change (∀ A ∈ s ∪ star s, A*T=T*A) ↔ _ + simp only [mem_iInter,mem_ofPred_eq] + exact forall₂_congr fun A hA => ⟨fun h v => DFunLike.congr_fun h v, + fun h => ContinuousLinearMap.ext h⟩ + rw [StronglyClosed,he] + exact isClosed_iInter fun A => isClosed_iInter fun _ => isClosed_iInter fun v => + isClosed_eq (A.continuous.comp (strong_continuous_apply v)) (strong_continuous_apply (A v)) + + +lemma strongGenerated_commutative {s : Set (H →L[ℂ] H)} + (hs : ∀ A ∈ s, IsSelfAdjoint A) (hc : ∀ A ∈ s, ∀ B ∈ s, A*B=B*A) : + ∀ A ∈ strongGenerated s, ∀ B ∈ strongGenerated s, A*B=B*A := by + have hle : strongGenerated s ≤ StarSubalgebra.centralizer ℂ s := by + apply strongGenerated_le (strong_centralizer_closed s) + intro B hB + apply (StarSubalgebra.mem_centralizer_iff ℂ).mpr + intro A hA + exact ⟨hc A hA B hB, by rw [(hs A hA).star_eq]; exact hc A hA B hB⟩ + have hle' : strongGenerated s ≤ StarSubalgebra.centralizer ℂ (strongGenerated s : Set _) := by + apply strongGenerated_le (strong_centralizer_closed _) + intro B hB + apply (StarSubalgebra.mem_centralizer_iff ℂ).mpr + intro A hA + refine ⟨((StarSubalgebra.mem_centralizer_iff ℂ).mp (hle hA) B hB).1.symm, ?_⟩ + exact ((StarSubalgebra.mem_centralizer_iff ℂ).mp (hle ((strongGenerated s).star_mem' hA)) B hB).1.symm + intro A hA B hB + exact ((StarSubalgebra.mem_centralizer_iff ℂ).mp (hle' hB) A hA).1 + + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BackwardIntertwiners/WeightSeparation.lean b/lean/OAI/Analysis/BackwardIntertwiners/WeightSeparation.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce040b790a2276ce2433cac0cd807dd4e5ae69a7 --- /dev/null +++ b/lean/OAI/Analysis/BackwardIntertwiners/WeightSeparation.lean @@ -0,0 +1,296 @@ +import OAI.Analysis.BackwardIntertwiners.CoefficientSupport + +namespace OAI + +namespace BackwardIntertwiners +open Filter +open scoped Topology +noncomputable section + + +structure QuadraticWeights (w : ℤ → ℝ) : Prop where + positive : ∀ j, 0 < w j + decreasing : Antitone w + convex_negative : DiscreteConvex (fun n => Real.log (w (-(n : ℤ)))) + concave_positive : DiscreteConvex (fun n => -Real.log (w n)) + root_sum : Summable (fun j : ℤ => if j = 0 then 0 else w j ^ (1 / (j : ℝ))) + quadratic : ∃ a : ℝ, Real.log 3 < a ∧ + Tendsto (fun n : ℕ => Real.log (w n) / (n : ℝ)^2) atTop (𝓝 (-a)) ∧ + Tendsto (fun n : ℕ => Real.log (w (-(n : ℤ))) / (n : ℝ)^2) atTop (𝓝 a) + + +def SupportSeparation (w : ℤ → ℝ) : Prop := + ∀ b c : ℤ → ℂ, + (∃ j, b j ≠ 0) → (∃ j, c j ≠ 0) → + (∀ j, ‖b j‖ ≤ w j) → (∀ j, ‖c j‖ * w j ≤ 1) → + (∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j - r)) = 0) → + ∃ t h : ℤ, b t ≠ 0 ∧ c h ≠ 0 ∧ + (∀ j, t < j → b j = 0) ∧ (∀ j, j < h → c j = 0) ∧ t ≤ h + +def reflectedWeight (w : ℤ → ℝ) (j : ℤ) : ℝ := (w (-j))⁻¹ + +lemma reflectedWeight_pos {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) (j : ℤ) : + 0 < reflectedWeight w j := inv_pos.mpr (hw _) + +lemma reflectedWeight_antitone {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) (hdec : Antitone w) : + Antitone (reflectedWeight w) := by + intro i j hij + exact (inv_le_inv₀ (hw _) (hw _)).mpr (hdec (neg_le_neg hij)) + +lemma reflected_positiveLog (w : ℤ → ℝ) : positiveLog (reflectedWeight w) = negativeLog w := by + funext n + simp [positiveLog, negativeLog, reflectedWeight, Real.log_inv] + +lemma reflected_negativeLog (w : ℤ → ℝ) : negativeLog (reflectedWeight w) = positiveLog w := by + funext n + simp [positiveLog, negativeLog, reflectedWeight, Real.log_inv] + +lemma reflected_stepRatio_summable {w : ℤ → ℝ} (hs : Summable (stepRatio w)) : + Summable (stepRatio (reflectedWeight w)) := by + have hh := hs.comp_injective (i := fun j : ℤ => -j-1) (by + intro a b hab; dsimp only at hab; omega) + apply hh.congr + intro j + dsimp [stepRatio, reflectedWeight] + have e₁ : -j-1+1 = -j := by omega + have e₂ : -(j+1) = -j-1 := by omega + rw [e₁, e₂, inv_div_inv] + +lemma reflected_correlations {b c : ℤ → ℂ} + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : + ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, c (-j) * b (-(j-r))) = 0 := by + intro r hr + let e : ℤ ≃ ℤ := ⟨fun j => (r:ℤ)-j, fun j => (r:ℤ)-j, by intro j; dsimp only; omega, by intro j; dsimp only; omega⟩ + calc (∑' j : ℤ, c (-j) * b (-(j-r))) = + ∑' j : ℤ, b (e j) * c (e j-r) := by + apply tsum_congr + intro j + dsimp [e] + have e₁ : (r:ℤ)-j = -(j-r) := by omega + have e₂ : (r:ℤ)-j-r = -j := by omega + rw [e₁, show -(j-(r:ℤ))-(r:ℤ) = -j by omega, mul_comm] + _ = ∑' j : ℤ, b j * c (j-r) := e.tsum_eq (fun j : ℤ => b j * c (j-r)) + _ = 0 := hz r hr + +lemma reflected_bounds {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) {b c : ℤ → ℂ} + (hb : ∀ j, ‖b j‖ ≤ w j) (hc : ∀ j, ‖c j‖*w j ≤ 1) : + (∀ j, ‖c (-j)‖ ≤ reflectedWeight w j) ∧ + (∀ j, ‖b (-j)‖*reflectedWeight w j ≤ 1) := by + constructor + · intro j + simpa only [reflectedWeight, one_div] using (le_div_iff₀ (hw (-j))).mpr (hc (-j)) + · intro j + dsimp [reflectedWeight] + rw [← div_eq_mul_inv] + exact (div_le_one (hw _)).mpr (hb _) + + + +theorem normalized_support_separation {w : ℤ → ℝ} (hw : ∀ j, 0 < w j) + (hdec : Antitone w) (hw0 : w 0 = 1) + (hP : DiscreteConvex (negativeLog w)) (hQ : DiscreteConvex (positiveLog w)) + {lam δ : ℝ} (hlam : Real.log 3 < lam) (hδ : lam < δ) + (hqp : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ negativeLog w n) + (hqq : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ positiveLog w n) : + SupportSeparation w := by + intro b c hbn hcn hb hc hz + have hδ0 : 0 < δ := lt_trans (lt_trans (Real.log_pos (by norm_num : (1:ℝ)<3)) hlam) hδ + have hP0 : negativeLog w 0 = 0 := by simp [negativeLog, hw0] + have hQ0 : positiveLog w 0 = 0 := by simp [positiveLog, hw0] + have hs := stepRatio_summable hw hw0 hP hQ hδ0 hqp hqq + have hb_bd : ∃ m : ℤ, ∀ j : ℤ, b j ≠ 0 → j ≤ m := by + by_cases hc_bd : ∃ m : ℤ, ∀ j : ℤ, c j ≠ 0 → m ≤ j + · obtain ⟨h, hch, hh⟩ := Int.exists_least_of_bdd hc_bd hcn + apply bounded_above_of_min hw hdec hw0 hs hQ hδ0 hqq hb hc hch ?_ hz + intro j hj + by_contra hne + have := hh j hne + omega + · by_contra hbu + have hcu : ¬∃ m : ℤ, ∀ j : ℤ, c (-j) ≠ 0 → j ≤ m := by + rintro ⟨m, hm⟩ + apply hc_bd + refine ⟨-m, ?_⟩ + intro j hj + have hh := hm (-j) (by simpa using hj) + omega + exact no_both_unbounded (bounds_of_weight hw hb hc) hP hQ hP0 hQ0 hlam hδ hqp hqq + (nat_support_unbounded hbu) (nat_support_unbounded hcu) hz + obtain ⟨t, hbt, ht⟩ := Int.exists_greatest_of_bdd hb_bd hbn + have hc_bd : ∃ m : ℤ, ∀ j : ℤ, c j ≠ 0 → m ≤ j := by + have hwr0 : reflectedWeight w 0 = 1 := by simp [reflectedWeight, hw0] + have hQr : DiscreteConvex (positiveLog (reflectedWeight w)) := by + rw [reflected_positiveLog]; exact hP + have hqpr : ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ positiveLog (reflectedWeight w) n := by + simpa only [reflected_positiveLog] using hqp + obtain ⟨hbr, hcr⟩ := reflected_bounds hw hb hc + have hzref := reflected_correlations hz + have hm := bounded_above_of_min (reflectedWeight_pos hw) (reflectedWeight_antitone hw hdec) + hwr0 (reflected_stepRatio_summable hs) hQr hδ0 hqpr hbr hcr + (h := -t) (by simpa using hbt) (by + intro j hj + by_contra hne + have hh := ht (-j) hne + omega) hzref + obtain ⟨m, hm⟩ := hm + refine ⟨-m, ?_⟩ + intro j hj + have hh := hm (-j) (by simpa using hj) + omega + obtain ⟨h, hch, hh⟩ := Int.exists_least_of_bdd hc_bd hcn + have hbmax : ∀ j : ℤ, t < j → b j = 0 := by + intro j hj + by_contra hne + have := ht j hne + omega + have hcmin : ∀ j : ℤ, j < h → c j = 0 := by + intro j hj + by_contra hne + have := hh j hne + omega + refine ⟨t, h, hbt, hch, hbmax, hcmin, ?_⟩ + by_contra! hth + let r := (t-h).toNat + have hr : 1 ≤ r := by dsimp [r]; omega + have hri : (r:ℤ) = t-h := by dsimp [r]; omega + have he : (∑' j : ℤ, b j * c (j-r)) = b t * c h := by + rw [tsum_eq_single t] + · congr 2 + omega + · intro j hj + by_cases hbj : b j = 0 + · simp [hbj] + · have htj := ht j hbj + rw [hcmin _ (by omega), mul_zero] + have hzero := hz r hr + rw [he] at hzero + exact (mul_ne_zero hbt hch) hzero + +lemma DiscreteConvex.add_const {G : ℕ → ℝ} (h : DiscreteConvex G) (c : ℝ) : + DiscreteConvex (fun n => G n+c) := by + intro i j hij + simpa only [add_sub_add_right_eq_sub] using h hij + +lemma eventually_quadratic_lower {G : ℕ → ℝ} {a δ : ℝ} (hδa : δ < a) + (ht : Tendsto (fun n => G n / (n:ℝ)^2) atTop (𝓝 a)) : + ∀ᶠ n : ℕ in atTop, δ*(n:ℝ)^2 ≤ G n := by + filter_upwards [ht (eventually_gt_nhds hδa), eventually_ge_atTop 1] with n hn hn1 + have hnpos : 0 < (n:ℝ)^2 := sq_pos_of_pos (Nat.cast_pos.mpr (by omega)) + exact ((lt_div_iff₀ hnpos).mp hn).le + + + + +theorem quadratic_support_separation (w : ℤ → ℝ) (hw : QuadraticWeights w) : + SupportSeparation w := by + let W := fun j : ℤ => w j / w 0 + have hw0 : 0 < w 0 := hw.positive 0 + have hWpos (j : ℤ) : 0 < W j := div_pos (hw.positive j) hw0 + have hWdec : Antitone W := by + intro i j hij + exact div_le_div_of_nonneg_right (hw.decreasing hij) hw0.le + have hW0 : W 0 = 1 := div_self (ne_of_gt hw0) + have hlog (j : ℤ) : Real.log (w j / w 0) = Real.log (w j) - Real.log (w 0) := + Real.log_div (ne_of_gt (hw.positive j)) (ne_of_gt hw0) + have hP : DiscreteConvex (negativeLog W) := by + have heq : negativeLog W = fun n : ℕ => Real.log (w (-(n:ℤ))) + -Real.log (w 0) := by + funext n + simp only [negativeLog, W, hlog, sub_eq_add_neg] + rw [heq] + exact hw.convex_negative.add_const _ + have hQ : DiscreteConvex (positiveLog W) := by + have heq : positiveLog W = fun n : ℕ => -Real.log (w n) + Real.log (w 0) := by + funext n + simp only [positiveLog, W, hlog] + ring + rw [heq] + exact hw.concave_positive.add_const _ + obtain ⟨a, ha, hqa, hpa⟩ := hw.quadratic + have hnat : Tendsto (fun n : ℕ => (n:ℝ)^2) atTop atTop := by + exact (tendsto_pow_atTop (by norm_num : 2 ≠ 0)).comp tendsto_natCast_atTop_atTop + have hsmall : Tendsto (fun n : ℕ => Real.log (w 0) / (n:ℝ)^2) atTop (𝓝 0) := by + simpa only [div_eq_mul_inv, mul_zero, Function.comp_def] using + (tendsto_inv_atTop_zero.comp hnat).const_mul (Real.log (w 0)) + have htP : Tendsto (fun n : ℕ => negativeLog W n / (n:ℝ)^2) atTop (𝓝 a) := by + simpa only [negativeLog, W, hlog, sub_div, sub_zero] using hpa.sub hsmall + have htQ : Tendsto (fun n : ℕ => positiveLog W n / (n:ℝ)^2) atTop (𝓝 a) := by + have heq : (fun n : ℕ => positiveLog W n / (n:ℝ)^2) = + (fun n : ℕ => -(Real.log (w n) / (n:ℝ)^2) + Real.log (w 0) / (n:ℝ)^2) := by + funext n + simp only [positiveLog, W, hlog] + ring + rw [heq] + simpa only [neg_neg, add_zero] using hqa.neg.add hsmall + obtain ⟨lam, hlam, hlama⟩ := exists_between ha + obtain ⟨δ, hδ, hδa⟩ := exists_between hlama + have hsep := normalized_support_separation hWpos hWdec hW0 hP hQ hlam hδ + (eventually_quadratic_lower hδa htP) (eventually_quadratic_lower hδa htQ) + intro b c hbn hcn hb hc hz + let C : ℂ := (w 0 : ℂ) + have hC : C ≠ 0 := by dsimp [C]; exact_mod_cast (ne_of_gt hw0) + have hCnorm : ‖C‖ = w 0 := by simpa [C] using Real.norm_of_nonneg hw0.le + let b' := fun j => b j / C + let c' := fun j => C * c j + have hbn' : ∃ j, b' j ≠ 0 := by + obtain ⟨j, hj⟩ := hbn + exact ⟨j, div_ne_zero hj hC⟩ + have hcn' : ∃ j, c' j ≠ 0 := by + obtain ⟨j, hj⟩ := hcn + exact ⟨j, mul_ne_zero hC hj⟩ + have hb' (j : ℤ) : ‖b' j‖ ≤ W j := by + dsimp [b', W] + rw [norm_div, hCnorm] + exact div_le_div_of_nonneg_right (hb j) hw0.le + have hc' (j : ℤ) : ‖c' j‖ * W j ≤ 1 := by + dsimp [c', W] + rw [norm_mul, hCnorm] + have he : w 0 * ‖c j‖ * (w j / w 0) = ‖c j‖ * w j := by field_simp + rw [he] + exact hc j + have hz' (r : ℕ) (hr : 1 ≤ r) : (∑' j : ℤ, b' j * c' (j-r)) = 0 := by + have he (j : ℤ) : b' j * c' (j-r) = b j * c (j-r) := by + dsimp [b', c'] + field_simp + simp only [he] + exact hz r hr + have hh := hsep b' c' hbn' hcn' hb' hc' hz' + simpa [b', c', hC] using hh + + +lemma SupportSeparation.of_bounded {w : ℤ → ℝ} (hsep : SupportSeparation w) + {b c : ℤ → ℂ} (hbn : ∃ j, b j ≠ 0) (hcn : ∃ j, c j ≠ 0) + {B C : ℝ} (hB : 0 < B) (hC : 0 < C) + (hb : ∀ j, ‖b j‖ ≤ B*w j) (hc : ∀ j, ‖c j‖*w j ≤ C) + (hz : ∀ r : ℕ, 1 ≤ r → (∑' j : ℤ, b j * c (j-r)) = 0) : + ∃ t h : ℤ, b t ≠ 0 ∧ c h ≠ 0 ∧ + (∀ j, t < j → b j = 0) ∧ (∀ j, j < h → c j = 0) ∧ t ≤ h := by + have hBC : (B:ℂ) ≠ 0 := by exact_mod_cast (ne_of_gt hB) + have hCC : (C:ℂ) ≠ 0 := by exact_mod_cast (ne_of_gt hC) + let b' := fun j => b j / (B:ℂ) + let c' := fun j => c j / (C:ℂ) + have hbn' : ∃ j, b' j ≠ 0 := by + obtain ⟨j, hj⟩ := hbn + exact ⟨j, div_ne_zero hj hBC⟩ + have hcn' : ∃ j, c' j ≠ 0 := by + obtain ⟨j, hj⟩ := hcn + exact ⟨j, div_ne_zero hj hCC⟩ + have hb' (j : ℤ) : ‖b' j‖ ≤ w j := by + dsimp [b'] + rw [norm_div, Complex.norm_real, Real.norm_of_nonneg hB.le] + exact (div_le_iff₀ hB).mpr (by simpa only [mul_comm] using hb j) + have hc' (j : ℤ) : ‖c' j‖*w j ≤ 1 := by + dsimp [c'] + rw [norm_div, Complex.norm_real, Real.norm_of_nonneg hC.le, div_mul_eq_mul_div] + exact (div_le_one hC).mpr (hc j) + have hz' (r : ℕ) (hr : 1 ≤ r) : (∑' j : ℤ, b' j * c' (j-r)) = 0 := by + have he (j : ℤ) : b' j * c' (j-r) = (b j*c (j-r)) / ((B:ℂ)*(C:ℂ)) := by + dsimp [b', c']; ring + simp only [he, tsum_div_const, hz r hr, zero_div] + have hh := hsep b' c' hbn' hcn' hb' hc' hz' + simpa [b', c', hBC, hCC] using hh + + +end +end BackwardIntertwiners + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/BoundedCalibration.lean b/lean/OAI/Analysis/BernoulliCone/BoundedCalibration.lean new file mode 100644 index 0000000000000000000000000000000000000000..1287bdaff850655b3dff9d0d840d7edfb568f2f6 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/BoundedCalibration.lean @@ -0,0 +1,121 @@ +import OAI.Analysis.BernoulliCone.ExteriorCalibration + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.DeSilvaJerison + +def upperFlux (p:Space 7×ℝ) : Space 7 := + if U p.1 + Cylindrical.radiusSq axis ((upperParameter z.1 z.2)⁻¹ • z.1)) p:= + (Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.continuousAt.comp + (((upperParameter_contDiffAt hp hq).continuousAt.inv₀ hl).smul continuous_fst.continuousAt) + filter_upwards [hn,hc.eventually_ne hq] with z hz hzq + exact upperFlux_eq_calibration hz hzq +lemma upperFlux_contDiffAt {p:Space 7×ℝ} (hp:U p.1upperParameter z.1 z.2) := by + let S:Set (Space 7×ℝ):={z|U z.1upperParameter z.1 z.2) (fun _=>0)):= + upperParameter_continuousOn.measurable_piecewise continuousOn_const hS.measurableSet + convert hh using 1 + ext z + by_cases hz:U z.1(upperParameter z.1 z.2)⁻¹ • z.1):= + upperParameter_measurable.inv.smul measurable_fst + have hq:Measurable (fun z:Space 7×ℝ=>Cylindrical.radiusSq axis ((upperParameter z.1 z.2)⁻¹ • z.1)):= + (Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.measurable.comp hi + have h1:MeasurableSet {z:Space 7×ℝ|U z.1.ite h1 measurable_const + +/-- The height primitive is integrable and has linear growth, using the actual +field's uniform bound, independently of seam choices. -/ +lemma upperFlux_intervalIntegrable (x:Space 7) (a b:ℝ) : + IntervalIntegrable (fun s:ℝ=>upperFlux (x,s)) MeasureTheory.volume a b := by + obtain ⟨C,hC,hbound⟩:=upperFlux_uniform_bound + rw [intervalIntegrable_iff] + apply MeasureTheory.Integrable.mono' (g:=fun _:ℝ=>C) + (intervalIntegrable_const (a:=a) (b:=b) (c:=C)).def' + · exact (upperFlux_measurable.comp (measurable_const.prodMk measurable_id)).aestronglyMeasurable + · exact Filter.Eventually.of_forall fun s=>hbound (x,s) +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CalibrationTraces.lean b/lean/OAI/Analysis/BernoulliCone/CalibrationTraces.lean new file mode 100644 index 0000000000000000000000000000000000000000..aac5df14181e5881448cc137a556f8e16a093d6c --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CalibrationTraces.lean @@ -0,0 +1,89 @@ +import OAI.Analysis.BernoulliCone.OuterSlope + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison +lemma gradient_dilation {f:Space 7→ℝ} {x:Space 7} {l:ℝ} (hl:l≠0) + (hf:DifferentiableAt ℝ f (l⁻¹ • x)) : + gradient (fun y=>κ*l*f (l⁻¹ • y)) x=κ • gradient f (l⁻¹ • x) := by + have hd:HasFDerivAt (fun y:Space 7=>l⁻¹ • y) + (l⁻¹ • ContinuousLinearMap.id ℝ (Space 7)) x := (hasFDerivAt_id x).const_smul l⁻¹ + have hh:HasFDerivAt (fun y:Space 7=>κ*l*f (l⁻¹ • y)) + ((κ*l) • (fderiv ℝ f (l⁻¹ • x) ∘L (l⁻¹ • ContinuousLinearMap.id ℝ (Space 7)))) x := + (hf.hasFDerivAt.comp x hd).const_mul (κ*l) + apply ext_inner_right ℝ + intro v + rw [inner_gradient_left,hh.fderiv,real_inner_smul_left,inner_gradient_left] + simp only [smul_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.id_apply,map_smul,smul_eq_mul] + field_simp + +lemma upperFamily_gradient {x:Space 7} {l:ℝ} (hl:0upperSigned (l⁻¹ • y)) x:= + hf.continuousAt.comp ((continuous_id.const_smul l⁻¹).continuousAt) + have hpos:0κ*l*upperSigned (l⁻¹ • y)) := by + filter_upwards [hs.eventually (lt_mem_nhds hpos)] with y hy + exact congrArg (κ*l* ·) (max_eq_left hy.le) + rw [gradient,he.fderiv_eq] + exact gradient_dilation hl.ne' (hf.differentiableAt (by simp)) + +lemma upperCalibration_eq {p:Space 7×ℝ} (hp:U p.1V q b) (D q b/2) q := by + convert! (((hasDerivAt_const q (203/200-b)).add ((hasDerivAt_id q).const_mul b)).sub + (((hasDerivAt_id q).pow 2).const_mul (3/200))) using 1 + dsimp [V,D] + ring +lemma hasDerivAt_D (q b:ℝ) : HasDerivAt (fun q=>D q b) (-3/50) q := by + convert! (hasDerivAt_const q (2*b)).sub ((hasDerivAt_id q).const_mul (3/50)) using 1 + ring +lemma hasDerivAt_E (q b:ℝ) : HasDerivAt (fun q=>E q b) (-9/50) q := by + convert! (hasDerivAt_const q (2*b)).sub ((hasDerivAt_id q).const_mul (9/50)) using 1 + ring +lemma hasDerivAt_H (q b:ℝ) : HasDerivAt (fun q=>H q b) (9/16*D q b*E q b) q := by + convert! (hasDerivAt_const q (1:ℝ)).add + ((((hasDerivAt_id q).const_mul (9/16)).mul ((hasDerivAt_D q b).pow 2))) using 1 + dsimp [D,E] + ring +lemma V_contDiff (b:ℝ) {n:WithTop ℕ∞} : ContDiff ℝ n (fun q=>V q b) := by + exact (contDiff_const.add (contDiff_const.mul contDiff_id)).sub (contDiff_const.mul (contDiff_id.pow 2)) +lemma H_contDiff (b:ℝ) {n:WithTop ℕ∞} : ContDiff ℝ n (fun q=>H q b) := by + exact contDiff_const.add ((contDiff_const.mul contDiff_id).mul + ((contDiff_const.sub (contDiff_const.mul contDiff_id)).pow 2)) +/-- The cap prefactor in squared transverse coordinates. -/ +def Y (q b C:ℝ) :ℝ := C*V q b/Real.sqrt (H q b) +def Y1 (q b C:ℝ) :ℝ := + C*(D q b/2/Real.sqrt (H q b)-V q b*(9/16*D q b*E q b)/(2*(Real.sqrt (H q b))^3)) +def Y2 (q b C:ℝ) :ℝ := + C*((-3/100)/Real.sqrt (H q b)-D q b/2*(9/16*D q b*E q b)/(Real.sqrt (H q b))^3- + V q b*(9/16*((-3/50)*E q b+D q b*(-9/50)))/(2*(Real.sqrt (H q b))^3)+ + 3*V q b*(9/16*D q b*E q b)^2/(4*(Real.sqrt (H q b))^5)) +lemma Y_contDiffAt {q b C:ℝ} (hH:0Y q b C) q := + (contDiffAt_const.mul (V_contDiff b (n:=n)).contDiffAt).div ((H_contDiff b (n:=n)).contDiffAt.sqrt hH.ne') + (Real.sqrt_pos.mpr hH).ne' +lemma hasDerivAt_Y {q b C:ℝ} (hH:0Y q b C) (Y1 q b C) q := by + have hS:=Real.sqrt_pos.mpr hH + have hSsq:=Real.sq_sqrt hH.le + convert! ((hasDerivAt_V q b).const_mul C).div ((hasDerivAt_H q b).sqrt hH.ne') hS.ne' using 1 + simp only [Y1] + field_simp +lemma hasDerivAt_Y1 {q b C:ℝ} (hH:0Y1 q b C) (Y2 q b C) q := by + have hS:=Real.sqrt_pos.mpr hH + have hs := (hasDerivAt_H q b).sqrt hH.ne' + have hd := hasDerivAt_D q b + have he := hasDerivAt_E q b + have hv := hasDerivAt_V q b + convert! (((hd.div_const 2).div hs hS.ne').sub + ((hv.mul ((hd.const_mul (9/16)).mul he)).div ((hs.pow 3).const_mul 2) (mul_ne_zero (by norm_num) (pow_ne_zero _ hS.ne')))).const_mul C using 1 + dsimp [Y1,Y2] + field_simp + ring +lemma deriv_Y {q b C:ℝ} (hH:0Y q b C) q=Y1 q b C := (hasDerivAt_Y hH).deriv +lemma deriv2_Y {q b C:ℝ} (hH:0Y q b C)) q=Y2 q b C := by + have hh : deriv (fun q=>Y q b C)=ᶠ[𝓝 q] fun q=>Y1 q b C := by + filter_upwards [(H_contDiff b (n:=∞)).continuous.continuousAt.eventually (Ioi_mem_nhds hH)] with t ht + exact deriv_Y ht + rw [hh.deriv_eq] + exact (hasDerivAt_Y1 hH).deriv +lemma hasDerivAt_invV {q b:ℝ} (hv:V q b≠0) : + HasDerivAt (fun q=>(V q b)⁻¹) (-D q b/(2*(V q b)^2)) q := by + convert! (hasDerivAt_V q b).inv hv using 1 + ring +lemma deriv2_invV {q b:ℝ} (hv:V q b≠0) : + deriv (deriv (fun q=>(V q b)⁻¹)) q= (D q b)^2/(2*(V q b)^3)+3/(100*(V q b)^2) := by + have hh : deriv (fun q=>(V q b)⁻¹)=ᶠ[𝓝 q] fun q=>-D q b/(2*(V q b)^2) := by + filter_upwards [((V_contDiff b (n:=∞)).continuous.continuousAt.eventually_ne hv)] with t ht + exact (hasDerivAt_invV ht).deriv + rw [hh.deriv_eq] + have hd := ((hasDerivAt_D q b).neg.div (((hasDerivAt_V q b).pow 2).const_mul 2) (by positivity : 2*(V q b)^2≠0)).deriv + change deriv (fun q=>-D q b/(2*(V q b)^2)) q = _ at hd + rw [hd] + simp only [Pi.pow_apply,Pi.neg_apply] + field_simp + ring +lemma lap_Y {q b C:ℝ} (hV:V q b≠0) (hH:0(capRadius_pos x).ne') + have hf : ContDiff ℝ ∞ (fun s=>f (capAngle s)) := by + apply contDiff_iff_contDiffAt.mpr + intro s + exact (contDiffAt_f (capAngle_mem s)).comp s ht.contDiffAt + exact (hr.mul hf).add (contDiff_const.mul (contDiff_const.add (contDiff_const.mul (contDiff_id.pow 2)))) + +lemma deriv2_capH (s:ℝ) : deriv (deriv capH) s=-5*(capRadius s)^3+4*capAmplitude := by + have hh : deriv capH=capHP := funext fun t=>(hasDerivAt_capH t).deriv + rw [hh] + exact (hasDerivAt_capHP s).deriv + +def capC :ℝ := Real.sqrt (1+9/16*capP^2) +def smoothCap (x:Space 7) :ℝ := Cylindrical.lift axis (fun q=>CapAlgebra.Y q capB capC) + (fun q=>(CapAlgebra.V q capB)⁻¹) capH x + +lemma smoothCap_contDiffAt {x:Space 7} (hx:Cylindrical.radiusSq axis x≤1) : + ContDiffAt ℝ ∞ smoothCap x := by + have hq:=Cylindrical.radiusSq_nonneg axis x axis_norm + have hv := (CapAlgebra.V_bounds hq hx capB_bounds.1 capB_bounds.2).1 + exact Cylindrical.contDiffAt_lift (CapAlgebra.Y_contDiffAt (CapAlgebra.H_pos hq)) + ((CapAlgebra.V_contDiff capB).contDiffAt.inv hv.ne') capH_contDiff.contDiffAt + +lemma laplacian_smoothCap {x:Space 7} (hx:Cylindrical.radiusSq axis x≤1) : + let q := Cylindrical.radiusSq axis x + let V := CapAlgebra.V q capB + let ξ := Cylindrical.axis axis x/V + Δ smoothCap x = CapAlgebra.Y q capB capC/V^2 * + ((-5*(capRadius ξ)^3+4*capAmplitude)*(1+q*ξ^2*(CapAlgebra.D q capB)^2)- + ξ*capHP ξ*V*(CapAlgebra.MN q capB/CapAlgebra.H q capB)+ + capH ξ*V*(CapAlgebra.NN q capB/(CapAlgebra.H q capB)^2)) := by + dsimp only + let q := Cylindrical.radiusSq axis x + let a := Cylindrical.axis axis x + have hq : 0≤q := Cylindrical.radiusSq_nonneg axis x axis_norm + have hv := (CapAlgebra.V_bounds hq hx capB_bounds.1 capB_bounds.2).1 + have hh := CapAlgebra.H_pos (b:=capB) hq + have hc := Cylindrical.laplacian_lift axis_norm + (CapAlgebra.Y_contDiffAt (C:=capC) (n:=2) hh) + ((CapAlgebra.V_contDiff capB (n:=2)).contDiffAt.inv hv.ne') + (capH_contDiff.of_le (by norm_cast : (2:WithTop ℕ∞)≤∞)).contDiffAt + change Δ smoothCap x=_ at hc + simp only [Space,finrank_euclideanSpace_fin,Nat.cast_ofNat] at hc + norm_num only at hc + change Δ smoothCap x = + CapAlgebra.Y q capB capC * deriv (deriv capH) (a*(CapAlgebra.V q capB)⁻¹) * + (((CapAlgebra.V q capB)⁻¹)^2+4*q*a^2*deriv (fun q=>(CapAlgebra.V q capB)⁻¹) q^2)+ + deriv capH (a*(CapAlgebra.V q capB)⁻¹)* + (a*CapAlgebra.Y q capB capC*(4*q*deriv (deriv (fun q=>(CapAlgebra.V q capB)⁻¹)) q+ + 12*deriv (fun q=>(CapAlgebra.V q capB)⁻¹) q)+ + 8*q*a*deriv (fun q=>CapAlgebra.Y q capB capC) q*deriv (fun q=>(CapAlgebra.V q capB)⁻¹) q)+ + capH (a*(CapAlgebra.V q capB)⁻¹)*(4*q*deriv (deriv (fun q=>CapAlgebra.Y q capB capC)) q+ + 12*deriv (fun q=>CapAlgebra.Y q capB capC) q) at hc + rw [hc] + simp only [CapAlgebra.deriv_Y hh, CapAlgebra.deriv2_Y hh, + (CapAlgebra.hasDerivAt_invV hv.ne').deriv, CapAlgebra.deriv2_invV hv.ne', + deriv2_capH,(hasDerivAt_capH _).deriv] + change _ = CapAlgebra.Y q capB capC/(CapAlgebra.V q capB)^2 * _ + have hm:=CapAlgebra.invV_mixed (C:=capC) hv.ne' hh + have hn:=CapAlgebra.lap_Y (C:=capC) hv.ne' hh + have h1 : ((CapAlgebra.V q capB)⁻¹)^2+4*q*a^2*(-CapAlgebra.D q capB/(2*(CapAlgebra.V q capB)^2))^2 = + (1+q*(a/CapAlgebra.V q capB)^2*(CapAlgebra.D q capB)^2)/(CapAlgebra.V q capB)^2 := by + field_simp + ring + have h2 : a*CapAlgebra.Y q capB capC* + (4*q*((CapAlgebra.D q capB)^2/(2*(CapAlgebra.V q capB)^3)+3/(100*(CapAlgebra.V q capB)^2))+ + 12*(-CapAlgebra.D q capB/(2*(CapAlgebra.V q capB)^2)))+ + 8*q*a*CapAlgebra.Y1 q capB capC*(-CapAlgebra.D q capB/(2*(CapAlgebra.V q capB)^2)) = + -a*CapAlgebra.Y q capB capC/(CapAlgebra.V q capB)^2*(CapAlgebra.MN q capB/CapAlgebra.H q capB) := by + calc + _ = a*(CapAlgebra.Y q capB capC* + (4*q*((CapAlgebra.D q capB)^2/(2*(CapAlgebra.V q capB)^3)+3/(100*(CapAlgebra.V q capB)^2))+ + 12*(-CapAlgebra.D q capB/(2*(CapAlgebra.V q capB)^2)))+ + 8*q*CapAlgebra.Y1 q capB capC*(-CapAlgebra.D q capB/(2*(CapAlgebra.V q capB)^2))) := by ring + _ = _ := by rw [hm]; ring + rw [h1,h2,hn] + change _=CapAlgebra.Y q capB capC/(CapAlgebra.V q capB)^2 * + ((-5*(capRadius (a/CapAlgebra.V q capB))^3+4*capAmplitude)*(1+q*(a/CapAlgebra.V q capB)^2*(CapAlgebra.D q capB)^2)- + (a/CapAlgebra.V q capB)*capHP (a/CapAlgebra.V q capB)*CapAlgebra.V q capB*(CapAlgebra.MN q capB/CapAlgebra.H q capB)+ + capH (a/CapAlgebra.V q capB)*CapAlgebra.V q capB*(CapAlgebra.NN q capB/(CapAlgebra.H q capB)^2)) + simp only [← div_eq_mul_inv] + field_simp + ring +lemma cap_sHP_nonpos (s:ℝ) : s*capHP s≤0 := by + rcases le_total 0 s with h|h + · exact mul_nonpos_of_nonneg_of_nonpos h (capHP_nonpos h) + · have hh:=mul_nonpos_of_nonneg_of_nonpos (neg_nonneg.mpr h) (capHP_nonpos (neg_nonneg.mpr h)) + simpa only [capHP_odd,neg_mul_neg] using hh + +/-- The actual smooth cylindrical cap is superharmonic on its positive strip. -/ +theorem smoothCap_laplacian_nonpos {x:Space 7} (hx:Cylindrical.radiusSq axis x≤1) + (hs:|Cylindrical.axis axis x/CapAlgebra.V (Cylindrical.radiusSq axis x) capB|≤3/4) : + Δ smoothCap x≤0 := by + let q:=Cylindrical.radiusSq axis x + let V:=CapAlgebra.V q capB + let s:=Cylindrical.axis axis x/V + have hq:0≤q:=Cylindrical.radiusSq_nonneg axis x axis_norm + obtain ⟨hv,hv1⟩:=CapAlgebra.V_bounds hq hx capB_bounds.1 capB_bounds.2 + obtain ⟨hM,hM1,hN,hN1⟩:=CapAlgebra.coeff_bounds hq hx capB_bounds.1 capB_bounds.2 + have hh:=capH_nonneg hs + have hph:=capHPP_nonpos s + have hsp:=cap_sHP_nonpos s + have hK:=cap_K_nonpos hs + change -5*capRadius s^3+4*capAmplitude-(673/250)*s*capHP s+(431/200)*capH s≤0 at hK + have hvm : V*(CapAlgebra.MN q capB/CapAlgebra.H q capB)≤673/250 := + (mul_le_mul_of_nonneg_right hv1 hM).trans (by simpa using hM1) + have hvn : V*(CapAlgebra.NN q capB/(CapAlgebra.H q capB)^2)≤431/200 := + (mul_le_mul_of_nonneg_right hv1 hN).trans (by simpa using hN1) + have h0:=mul_nonpos_of_nonpos_of_nonneg hph + (show 0≤q*s^2*(CapAlgebra.D q capB)^2 by positivity) + have h1:=mul_le_mul_of_nonneg_left hvm (neg_nonneg.mpr hsp) + have h2:=mul_le_mul_of_nonneg_left hvn hh + have hbr : (-5*capRadius s^3+4*capAmplitude)*(1+q*s^2*(CapAlgebra.D q capB)^2)- + s*capHP s*V*(CapAlgebra.MN q capB/CapAlgebra.H q capB)+ + capH s*V*(CapAlgebra.NN q capB/(CapAlgebra.H q capB)^2)≤0 := by + nlinarith only [h0,h1,h2,hK] + rw [laplacian_smoothCap hx] + have hY:0≤CapAlgebra.Y q capB capC := by unfold CapAlgebra.Y capC; positivity + exact mul_nonpos_of_nonneg_of_nonpos (div_nonneg hY (sq_nonneg V)) hbr + +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CapExtension.lean b/lean/OAI/Analysis/BernoulliCone/CapExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..5685ac6f40b15cda23654225174cb008d481f9b4 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CapExtension.lean @@ -0,0 +1,90 @@ +import OAI.Analysis.BernoulliCone.BoundedCalibration + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.DeSilvaJerison + +lemma upperFamily_eq_cap {x:Space 7} {l:ℝ} (hl:0κ*z.2*smoothCap (z.2⁻¹ • z.1.1)-z.1.2 + have hi:ContDiffAt ℝ ∞ (fun z:(Space 7×ℝ)×ℝ=>z.2⁻¹ • z.1.1) (p,l):= + (contDiffAt_snd.inv hl.ne').smul (contDiffAt_fst.fst) + have hF:ContDiffAt ℝ ∞ F (p,l):= + ((contDiffAt_const.mul contDiffAt_snd).mul (hc.comp (p,l) hi)).sub contDiffAt_fst.snd + let ρ:=κ*(smoothCap (l⁻¹ • p.1)-inner ℝ (l⁻¹ • p.1) (gradient smoothCap (l⁻¹ • p.1))) + have hρ:0<ρ:=mul_pos κ_pos (smoothCap_radial_defect_pos hq hpc) + have hd:HasDerivAt (fun s:ℝ=>F (p,s)) ρ l := by + have hh:=((Foliation.hasDerivAt_dilate p.1 hl.ne' + (hc.differentiableAt (by simp))).const_mul κ).sub_const p.2 + simpa only [F,mul_assoc] using hh + obtain ⟨ψ,hψ,hψ0,hψeq,huniq⟩:=Foliation.scalar_implicit_unique hF hd hρ.ne' + refine ⟨ψ,hψ,hψ0,?_⟩ + have hF0:F (p,l)=0:=by + dsimp [F] + rw [←upperFamily_eq_cap hl hpos hq,he,sub_self] + have ht:Tendsto (fun z:Space 7×ℝ=>(z,upperParameter z.1 z.2)) (𝓝 p) (𝓝 (p,l)):= + tendsto_id.prodMk_nhds (upperParameter_continuousAt hp) + filter_upwards [ht.eventually huniq] with z hz hzp hzq + apply hz.mp + rw [hF0] + dsimp [F] + have hzpos:0κ • gradient smoothCap ((ψ z)⁻¹ • z.1) + have hψp:ψ p≠0:=by rw [hψ0]; exact (upperParameter_spec hp).1.ne' + have hn:ContDiffAt ℝ ∞ (fun z:Space 7×ℝ=>(ψ z)⁻¹ • z.1) p:= + (hψ.inv hψp).smul contDiffAt_fst + have hg:ContDiffAt ℝ ∞ (gradient smoothCap) ((ψ p)⁻¹ • p.1):=by + rw [hψ0]; exact gradient_smoothCap_contDiffAt hq + refine ⟨B,(hg.comp p hn).const_smul κ,?_,?_⟩ + · simp only [B,hψ0,upperFlux,ite_eq_left hp,ite_eq_left hq] + · filter_upwards [he] with z hz hzp hzq + simp only [B,hz hzp hzq,upperFlux,ite_eq_left hzp,ite_eq_left hzq] +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CapFoliation.lean b/lean/OAI/Analysis/BernoulliCone/CapFoliation.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec3e8583c332305a077218a24a1ab6235a348487 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CapFoliation.lean @@ -0,0 +1,139 @@ +import OAI.Analysis.BernoulliCone.CapGeometry + +namespace OAI + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison + +lemma capHP_mul_nonpos (s:ℝ) : s*capHP s≤0 := by + rcases le_total 0 s with h|h + · exact mul_nonpos_of_nonneg_of_nonpos h (capHP_nonpos h) + · have hh:=capHP_nonpos (s:= -s) (by linarith) + rw [capHP_odd] at hh + exact mul_nonpos_of_nonpos_of_nonneg h (by linarith) + +lemma capHP_neg {s:ℝ} (hs:0.differentiableAt (by norm_num)) + (CapAlgebra.hasDerivAt_invV hv.ne').differentiableAt + (hasDerivAt_capH _).differentiableAt + change gradient smoothCap x= _ at hg + change gradient smoothCap x= + (2*deriv (fun q=>CapAlgebra.Y q capB capC) q*capH (a*(CapAlgebra.V q capB)⁻¹)) • Cylindrical.transverse axis x+ + (CapAlgebra.Y q capB capC*deriv capH (a*(CapAlgebra.V q capB)⁻¹)) • + ((CapAlgebra.V q capB)⁻¹ • axis+(2*a*deriv (fun q=>(CapAlgebra.V q capB)⁻¹) q) • Cylindrical.transverse axis x) at hg + rw [hg] + simp only [CapAlgebra.deriv_Y hh,(CapAlgebra.hasDerivAt_invV hv.ne').deriv, + (hasDerivAt_capH _).deriv,←div_eq_mul_inv] + have he:2*a*(-CapAlgebra.D q capB/(2*CapAlgebra.V q capB^2)) = -a*CapAlgebra.D q capB/CapAlgebra.V q capB^2 := by ring + rw [he] + +/-- Constant free-boundary slope of the actual cylindrical cap, including the +transverse axis. The result is for the genuine Euclidean gradient. -/ +theorem smoothCap_boundary_gradient {x:Space 7} (hx:Cylindrical.radiusSq axis x≤1) + (hs:|Cylindrical.axis axis x/CapAlgebra.V (Cylindrical.radiusSq axis x) capB|=3/4) : + ‖gradient smoothCap x‖^2=capC^2*(capHP (3/4))^2 := by + let q:=Cylindrical.radiusSq axis x + let a:=Cylindrical.axis axis x + let V:=CapAlgebra.V q capB + let H:=CapAlgebra.H q capB + let s:=a/V + have hq:0≤q:=Cylindrical.radiusSq_nonneg axis x axis_norm + have hv:0A (x,s)):=hA.comp (continuous_const.prodMk continuous_id) + unfold graphPotential ParametricIntegral.heightPrimitive + rw [←intervalIntegral.integral_interval_sub_left (hc.intervalIntegrable 0 (v x)) + (hc.intervalIntegrable 0 (u x))] + +lemma clamped_integral_identity {F A B:E×ℝ→E} (hA:Continuous A) (hB:Continuous B) + {u σ v:E→ℝ} {x:E} (huv:u x≤v x) + (hFi:∀a b:ℝ,IntervalIntegrable (fun t:ℝ=>F (x,t)) volume a b) + (hAe:∀t∈Ioo (u x) (v x),t<σ x → F (x,t)=A (x,t)) + (hBe:∀t∈Ioo (u x) (v x),σ xhAe t ⟨ht.1,ht.2.trans_le hwv⟩ + (below_clampedHeight ht.1 ht.2)) + have heB:(∫s in w..v x,F (x,s))=∫s in w..v x,B (x,s):= + intervalIntegral.integral_congr_Ioo_of_le hwv (fun t ht=>hBe t ⟨huw.trans_lt ht.1,ht.2⟩ + (above_clampedHeight ht.1 ht.2)) + rw [splitGraphPotential,graphPotential_eq_integral hA,graphPotential_eq_integral hB] + rw [←intervalIntegral.integral_add_adjacent_intervals (hFi (u x) w) (hFi w (v x)),heA,heB,smul_add] + +lemma integrated_bulk_open {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) (x:E) {a b:ℝ} (hab:a≤b) + (hbulk:∀s∈Ioo a b,divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) : + 2*(∫s in a..b,divergence (fun y:E=>A (y,s)) x)≤‖A (x,a)‖^2-‖A (x,b)‖^2 := by + rcases hab.eq_or_lt with he|hlt + · subst b; simp + · apply integrated_bulk hA x hab + have hAC:ContDiff ℝ 1 (fun s:ℝ=>A (x,s)):=hA.comp (contDiff_const.prodMk contDiff_id) + have hc:Continuous (fun s:ℝ=>divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)):= + (continuous_spatial_divergence hA x).add (hAC.continuous.inner (hAC.continuous_deriv (by norm_num))) + exact fun s hs=>le_on_closure hbulk hc.continuousOn continuousOn_const (by rwa [closure_Ioo hlt.ne]) + +lemma graphPotential_locallyLipschitz {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} (hu:LocallyLipschitz u) (hv:LocallyLipschitz v) : + LocallyLipschitz (graphPotential A u v) := by + have hh:= (ParametricIntegral.heightPrimitive_contDiff_one hA).locallyLipschitz + exact ((2:ℝ) • ContinuousLinearMap.id ℝ E).lipschitzWith.locallyLipschitz.comp + ((hh.comp (LocallyLipschitz.id.prodMk hv)).sub (hh.comp (LocallyLipschitz.id.prodMk hu))) + +lemma clamped_split_locallyLipschitz {A B:E×ℝ→E} (hA:ContDiff ℝ 1 A) (hB:ContDiff ℝ 1 B) + {u σ v:E→ℝ} (hu:LocallyLipschitz u) (hv:LocallyLipschitz v) (hσ:LocallyLipschitz σ) : + LocallyLipschitz (splitGraphPotential A B u (clampedHeight u σ v) v) := by + have hw:LocallyLipschitz (clampedHeight u σ v):=hu.max (hv.min hσ) + exact (graphPotential_locallyLipschitz hA hu hw).add (graphPotential_locallyLipschitz hB hw hv) +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ClampedGraphBound.lean b/lean/OAI/Analysis/BernoulliCone/ClampedGraphBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb12d7e2fffa576d3138e06a9151b4409f78ad99 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ClampedGraphBound.lean @@ -0,0 +1,87 @@ +import OAI.Analysis.BernoulliCone.ClampedSeam + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff +namespace Bernoulli.Foliation +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma gradient_eq_of_order_contact {u v:E→ℝ} {x:E} + (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) + (hle:∀y,u y≤v y) (he:u x=v x) : gradient u x=gradient v x := by + have hm:IsLocalMin (fun y=>v y-u y) x:=by + filter_upwards [] with y + change v x-u x≤v y-u y + rw [←he,sub_self] + exact sub_nonneg.mpr (hle y) + have hh:=hm.hasFDerivAt_eq_zero (hv.hasFDerivAt.sub hu.hasFDerivAt) + exact congrArg ((toDual ℝ E).symm) (sub_eq_zero.mp hh).symm + +lemma graph_divergence_zero_contact {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) + (hle:∀y,u y≤v y) (he:u x=v x) : divergence (graphPotential A u v) x=0 := by + rw [graph_potential_identity hA hu hv,he,gradient_eq_of_order_contact hu hv hle he] + simp + +lemma graph_potential_bulk_bound_open {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) + (huv:u x≤v x) + (hbulk:∀s∈Ioo (u x) (v x),divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) : + divergence (graphPotential A u v) x≤‖gradient v x‖^2+ + ‖A (x,u x)‖^2-2*inner ℝ (A (x,u x)) (gradient u x) := by + have hi:=integrated_bulk_open hA x huv hbulk + have hs:0≤‖gradient v x-A (x,v x)‖^2:=sq_nonneg _ + have he:inner ℝ (gradient v x) (A (x,v x))=inner ℝ (A (x,v x)) (gradient v x):=real_inner_comm _ _ + rw [norm_sub_sq_real,he] at hs + rw [graph_potential_identity hA hu hv] + linarith + +/-- The clamped primitive only needs a jump condition when the seam lies +strictly between the endpoint graphs. On contact sets the two gradients +agree, so the spurious branch cancels exactly. -/ +lemma split_graph_bound_open {A B:E×ℝ→E} (hA:ContDiff ℝ 1 A) (hB:ContDiff ℝ 1 B) + {u w v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hw:DifferentiableAt ℝ w x) + (hv:DifferentiableAt ℝ v x) (huw:∀y,u y≤w y) (hwv:∀y,w y≤v y) + (hbulkA:∀s∈Ioo (u x) (w x),divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) + (hbulkB:∀s∈Ioo (w x) (v x),divergence (fun y:E=>B (y,s)) x+ + inner ℝ (B (x,s)) (deriv (fun t:ℝ=>B (x,t)) s)≤0) + (hjump:u xh.2 + obtain ⟨K,V,hV,hL⟩:=hu x + refine ⟨K,V∩{y|clampedHeight u seamHeight v y=u y},inter_mem hV (hn.mono fun y hy=>clamped_seam_le_lower (huU y) hy),?_⟩ + intro y hy z hz + rw [hy.2,hz.2] + exact hL hy.1 hz.1 + · obtain ⟨σ,hσ,hσe⟩:=seamHeight_smooth_germ hl + have hw:LocallyLipschitz (clampedHeight u σ v):=hu.max (hv.min hσ.locallyLipschitz) + obtain ⟨K,V,hV,hL⟩:=hw x + refine ⟨K,V∩{y|σ y=seamHeight y},inter_mem hV hσe,?_⟩ + intro y hy z hz + have he1:clampedHeight u seamHeight v y=clampedHeight u σ v y:=by + change max (u y) (min (v y) (seamHeight y))=max (u y) (min (v y) (σ y)) + rw [hy.2] + have he2:clampedHeight u seamHeight v z=clampedHeight u σ v z:=by + change max (u z) (min (v z) (seamHeight z))=max (u z) (min (v z) (σ z)) + rw [hz.2] + rw [he1,he2] + exact hL hy.1 hz.1 + +lemma clamped_sub_lower_compact {u v:Space 7→ℝ} (h:HasCompactSupport (fun x=>v x-u x)) : + HasCompactSupport (fun x=>clampedHeight u seamHeight v x-u x) := by + apply HasCompactSupport.intro h + intro x hx + have hvu:v x=u x:=sub_eq_zero.mp (image_eq_zero_of_notMem_tsupport (f:=fun y=>v y-u y) hx) + change max (u x) (min (v x) (seamHeight x))-u x=0 + rw [hvu,max_eq_left (min_le_left _ _),sub_self] + +theorem clamped_seam_lipschitz {u v:Space 7→ℝ} {K L:ℝ≥0} + (hu:LipschitzWith K u) (hv:LipschitzWith L v) (huU:∀y,U yv x-u x)) : + ∃M:ℝ≥0,LipschitzWith M (clampedHeight u seamHeight v) := by + have hh:=clamped_seam_locallyLipschitz hu.locallyLipschitz hv.locallyLipschitz huU + obtain ⟨C,hC⟩:=locallyLipschitz_compact_lipschitz (hh.sub hu.locallyLipschitz) (clamped_sub_lower_compact hc) + refine ⟨C+K,?_⟩ + convert! hC.add hu using 1 + ext x + exact (sub_add_cancel _ _).symm +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ClosedGermExtension.lean b/lean/OAI/Analysis/BernoulliCone/ClosedGermExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..e3d7e6f5c80a53504eaeaca30465d6897d544154 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ClosedGermExtension.lean @@ -0,0 +1,50 @@ +import OAI.Analysis.BernoulliCone.SeamHeight + +namespace OAI + +universe uE uG + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Manifold +namespace Bernoulli.LocalExtension +variable {E : Type uE} {G : Type uG} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup G] [NormedSpace ℝ G] +/-- C1 germs agreeing on a closed subset glue to a global C1 extension. +This is an application of the actual smooth partition of unity, not a Whitney +extension premise. -/ +lemma exists_contDiff_one_of_closed_germs {S:Set E} (hS:IsClosed S) {F:E→G} + (hg:∀x∈S,∃B:E→G,ContDiffAt ℝ 1 B x ∧ ∀ᶠ y in 𝓝 x,y∈S→B y=F y) : + ∃B:E→G,ContDiff ℝ 1 B ∧ EqOn B F S := by + classical + let t:E→Set G:=fun x=>if x∈S then {F x} else univ + have ht(x:E):Convex ℝ (t x):=by + by_cases hx:x∈S + · simpa only [t,ite_eq_left hx] using convex_singleton (F x) + · simpa only [t,ite_eq_right hx] using (convex_univ : Convex ℝ (univ:Set G)) + have hl(x:E):∃U∈𝓝 x,∃g:E→G,ContMDiffOn 𝓘(ℝ,E) 𝓘(ℝ,G) 1 g U ∧ + ∀y∈U,g y∈t y := by + by_cases hx:x∈S + · obtain ⟨g,hgc,hge⟩:=hg x hx + obtain ⟨V,hV,hgV⟩:=hgc.contDiffOn le_rfl (by norm_num) + refine ⟨V∩{y|y∈S → g y=F y},inter_mem hV hge,g,?_,?_⟩ + · exact (hgV.mono inter_subset_left).contMDiffOn + · intro y hy + by_cases hyS:y∈S + · simp only [t,ite_eq_left hyS,mem_singleton_iff] + exact hy.2 hyS + · simp only [t,ite_eq_right hyS,mem_univ] + · refine ⟨Sᶜ,hS.isOpen_compl.mem_nhds hx,fun _=>0,contMDiffOn_const,?_⟩ + intro y hy + simp only [t,ite_eq_right hy,mem_univ] + obtain ⟨B,hB⟩:=exists_contMDiffMap_forall_mem_convex_of_local 𝓘(ℝ,E) ht hl + refine ⟨B,B.contMDiff.contDiff,?_⟩ + intro x hx + simpa only [t,ite_eq_left hx,mem_singleton_iff] using hB x +end Bernoulli.LocalExtension + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CompactGradient.lean b/lean/OAI/Analysis/BernoulliCone/CompactGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..2412a280d60d0a1bd625606b96bac01a9e6e65a5 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CompactGradient.lean @@ -0,0 +1,42 @@ +import OAI.Analysis.BernoulliCone.HalfspaceDifferential + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} + +lemma integral_gradient_compact {q : Space d → ℝ} {K : ℝ≥0} + (hq : LipschitzWith K q) (hc : HasCompactSupport q) (e : Space d) : + (∫ x, inner ℝ (gradient q x) e) = 0 := by + have hh := (LipschitzWith.const (1:ℝ)).integral_lineDeriv_mul_eq + (μ:=volume) hq hc (-e) + have he : (fun x => lineDeriv ℝ q x (-(-e)) * (1:ℝ)) =ᵐ[volume] + (fun x => inner ℝ (gradient q x) e) := by + filter_upwards [hq.ae_differentiableAt] with x hx + simp only [neg_neg,mul_one,hx.lineDeriv_eq_fderiv,inner_gradient_left] + rw [integral_congr_ae he] at hh + have hz (x : Space d) : lineDeriv ℝ (fun _ : Space d => (1:ℝ)) x (-e)=0 := by + rw [(differentiableAt_const (1:ℝ)).lineDeriv_eq_fderiv] + simp + simpa only [hz,zero_mul,integral_zero] using hh.symm + +lemma setIntegral_gradient_compact {q : Space d → ℝ} {K : ℝ≥0} + (hq : LipschitzWith K q) (hc : HasCompactSupport q) + {D : Set (Space d)} (hD : tsupport q ⊆ D) (e : Space d) : + (∫ x in D, inner ℝ (gradient q x) e) = 0 := by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero] + · exact integral_gradient_compact hq hc e + · intro x hx + have hn : x∉tsupport q := fun hh => hx (hD hh) + simp [gradient,fderiv_of_notMem_tsupport ℝ hn] +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CompactLipschitzDivergence.lean b/lean/OAI/Analysis/BernoulliCone/CompactLipschitzDivergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..975b82c511e30960ec936573cebb8fcae70b1398 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CompactLipschitzDivergence.lean @@ -0,0 +1,149 @@ +import OAI.Analysis.BernoulliCone.FluxSeam + +namespace OAI + +universe uE uG + +section +noncomputable section +open MeasureTheory Set Filter InnerProductSpace +open scoped Topology ContDiff NNReal +namespace Bernoulli.Foliation +variable {E : Type uE} {G : Type uG} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + [NormedAddCommGroup G] [NormedSpace ℝ G] + +omit [NormedSpace ℝ G] in +lemma locallyLipschitz_compact_lipschitz [NormedSpace ℝ G] {F:E→G} (hl:LocallyLipschitz F) + (hc:HasCompactSupport F) : ∃K:ℝ≥0,LipschitzWith K F := by + obtain ⟨R,hR⟩:=hc.isBounded.subset_ball (0:E) + obtain ⟨K,hK⟩:=hl.locallyLipschitzOn.exists_lipschitzOnWith_of_compact + (isCompact_closedBall (0:E) (R+1)) + obtain ⟨M,hM⟩:=hc.exists_bound_of_continuousOn hl.continuous.continuousOn + let C:ℝ≥0:=⟨max (K:ℝ) (max M 0),le_max_of_le_right (le_max_right _ _)⟩ + have hKC:(K:ℝ)≤C:=le_max_left _ _ + have hMC:M≤(C:ℝ):=(le_max_left M 0).trans (le_max_right _ _) + have hbound (x y:E) (hx:x∈tsupport F) (hy:y∉Metric.closedBall (0:E) (R+1)): + dist (F x) (F y)≤(C:ℝ)*dist x y := by + have hFx:dist x 0?_⟩ + by_cases hx:x∈tsupport F + · by_cases hy:y∈Metric.closedBall (0:E) (R+1) + · have hxB:x∈Metric.closedBall (0:E) (R+1):=by + have hh:=hR hx + change dist x 0fderiv ℝ f x v * φ x)=(fun x=>fderiv ℝ f x v):=by + funext x + by_cases hx:x∈tsupport f + · have he:φ x=1:=(show φ =ᶠ[𝓝 x] (fun _=>1) from hφ1.filter_mono (nhds_le_nhdsSet hx)).self_of_nhds + rw [he,mul_one] + · rw [fderiv_of_notMem_tsupport ℝ hx,zero_apply,zero_mul] + have he:(fun x:Space d=>f x*(fderiv ℝ φ x) v)=0:=by + funext x + by_cases hx:x∈tsupport f + · have heq:φ =ᶠ[𝓝 x] (fun _=>1):=hφ1.filter_mono (nhds_le_nhdsSet hx) + simp only [heq.fderiv_eq,fderiv_fun_const,zero_apply,mul_zero,Pi.zero_apply] + · rw [image_eq_zero_of_notMem_tsupport hx,zero_mul] + rfl + rw [hr,he] at hh + simpa only [integral_zero,Pi.zero_def,zero_eq_neg] using hh +lemma integrable_directional_compact {d:ℕ} {f:Space d→ℝ} {K:ℝ≥0} + (hf:LipschitzWith K f) (hc:HasCompactSupport f) (v:Space d) : + Integrable (fun x=>fderiv ℝ f x v) := by + have hs:Function.support (fun x=>fderiv ℝ f x v)⊆tsupport f:= + (subset_tsupport _).trans (tsupport_fderiv_apply_subset ℝ v) + apply (integrableOn_iff_integrable_of_support_subset hs).mp + apply (integrableOn_const (μ:=volume) (C:=((K:ℝ)*‖v‖)) hc.measure_ne_top).mono' + (((continuous_id.clm_apply continuous_const : Continuous (fun L:Space d→L[ℝ]ℝ=>L v)).measurable.comp (measurable_fderiv ℝ f)).aestronglyMeasurable.restrict) + filter_upwards [] with x + exact ((fderiv ℝ f x).le_opNorm v).trans + (mul_le_mul_of_nonneg_right (norm_fderiv_le_of_lipschitz ℝ hf) (norm_nonneg v)) + +lemma integrable_divergence_compact {d:ℕ} {F:Space d→Space d} {K:ℝ≥0} + (hF:LipschitzWith K F) (hc:HasCompactSupport F) : Integrable (divergence F) := by + let e:=stdOrthonormalBasis ℝ (Space d) + let f:=fun i x=>inner ℝ (e i) (F x) + have hf i:LipschitzWith (‖innerSL ℝ (e i)‖₊*K) (f i):= + (innerSL ℝ (e i)).lipschitzWith.comp hF + have hfc i:HasCompactSupport (f i):=by + apply HasCompactSupport.intro hc + intro x hx + simp only [f,image_eq_zero_of_notMem_tsupport hx,inner_zero_right] + have he:divergence F =ᵐ[volume] (fun x=>∑i,fderiv ℝ (f i) x (e i)):=by + filter_upwards [hF.ae_differentiableAt] with x hx + unfold divergence + apply Finset.sum_congr rfl + intro i hi + have hd:HasFDerivAt (f i) ((innerSL ℝ (e i)) ∘L fderiv ℝ F x) x:= + (innerSL ℝ (e i)).hasFDerivAt.comp x hx.hasFDerivAt + rw [hd.fderiv] + rfl + exact (integrable_finsetSum _ (fun i hi=>integrable_directional_compact (hf i) (hfc i) (e i))).congr he.symm + +lemma divergence_zero_outside_support {d:ℕ} {F:Space d→Space d} {x:Space d} + (hx:x∉tsupport F) : divergence F x=0 := by + unfold divergence + simp only [fderiv_of_notMem_tsupport ℝ hx,zero_apply,inner_zero_right, + Finset.sum_const_zero] + +/-- The divergence of a genuine compactly supported Lipschitz vector field +has integral zero, with the a.e. derivative justified by Rademacher. -/ +theorem integral_divergence_compact {d:ℕ} {F:Space d→Space d} {K:ℝ≥0} + (hF:LipschitzWith K F) (hc:HasCompactSupport F) : + (∫x,divergence F x)=0 := by + let e:=stdOrthonormalBasis ℝ (Space d) + let f:=fun i x=>inner ℝ (e i) (F x) + have hf i:LipschitzWith (‖innerSL ℝ (e i)‖₊*K) (f i):= + (innerSL ℝ (e i)).lipschitzWith.comp hF + have hfc i:HasCompactSupport (f i):=by + apply HasCompactSupport.intro hc + intro x hx + simp only [f,image_eq_zero_of_notMem_tsupport hx,inner_zero_right] + have he:divergence F =ᵐ[volume] (fun x=>∑i,fderiv ℝ (f i) x (e i)):=by + filter_upwards [hF.ae_differentiableAt] with x hx + unfold divergence + apply Finset.sum_congr rfl + intro i hi + have hd:HasFDerivAt (f i) ((innerSL ℝ (e i)) ∘L fderiv ℝ F x) x:= + (innerSL ℝ (e i)).hasFDerivAt.comp x hx.hasFDerivAt + rw [hd.fderiv] + rfl + rw [integral_congr_ae he,integral_finsetSum _ (fun i hi=>integrable_directional_compact (hf i) (hfc i) (e i))] + simp only [integral_directional_compact (hf _) (hfc _),Finset.sum_const_zero] +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CompactZeroFiber.lean b/lean/OAI/Analysis/BernoulliCone/CompactZeroFiber.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce294b0ee203c6e4c0520f4ecb939f6539d96b03 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CompactZeroFiber.lean @@ -0,0 +1,33 @@ +import OAI.Analysis.BernoulliCone.PositiveTrace + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology +namespace Bernoulli.Foliation +variable {E : Type uE} [TopologicalSpace E] +/-- Compact zero-fiber control. No convergence of the selected root is needed. -/ +lemma eventually_near_zero_fiber {K:Set E} (hK:IsCompact K) {f g:E→ℝ} {C:ℝ} + (hf:∀x∈K,ContinuousAt f x) (hg:∀x∈K,ContinuousAt g x) + (hzero:∀x∈K,f x=0 → g xhp + · have hn:f x-(0:ℝ)≠0:=by simpa using hz + have hh:∀ᶠ p:ℝ×E in 𝓝 (0,x),f p.2-p.1≠0:= + (((hf x hx).comp continuous_snd.continuousAt).sub continuous_fst.continuousAt).eventually_ne hn + exact hh.mono fun p hp he=>False.elim (hp (sub_eq_zero.mpr he)) +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ConePicone.lean b/lean/OAI/Analysis/BernoulliCone/ConePicone.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd5271ed23f5287b4ca2227dd02c1d72e24f8efa --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ConePicone.lean @@ -0,0 +1,134 @@ +import OAI.Analysis.BernoulliCone.DominatedVariation + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Halfspace +open HarmonicKernel +variable {d : ℕ} + +lemma positiveSquareRatio_hasFDerivAt {u v : Space d → ℝ} {x : Space d} + (hu : DifferentiableAt ℝ u x) (hv : DifferentiableAt ℝ v x) (hu0 : 0v y^2/u y) := by + filter_upwards [hu.continuousAt.preimage_mem_nhds (Ioi_mem_nhds hu0)] with y hy + change 0potential y*positiveSquareRatio v u y) x = + positiveSquareRatio v u x • gradient potential x + + potential x • gradient (positiveSquareRatio v u) x := by + apply ext_inner_right ℝ + intro z + have hh := (contDiff_potential.differentiable (by simp) x).hasFDerivAt.mul + (positiveSquareRatio_hasFDerivAt hu hv hu0) + change HasFDerivAt (fun y=>potential y*positiveSquareRatio v u y) _ x at hh + rw [inner_gradient_left,hh.fderiv] + simp only [inner_add_left,real_inner_smul_left,inner_gradient_left,add_apply,smul_apply,smul_eq_mul] + rw [(positiveSquareRatio_hasFDerivAt hu hv hu0).fderiv] + ring + +/-- Picone ground-state equality from full minimizing comparison. It is a +consequence, not a stationarity or regularity assumption in `GlobalMinimizer`. -/ +theorem picone_gradient_equality {u v : Space d → ℝ} {L M C : ℝ≥0} + (hm : GlobalMinimizer u) (hL : LipschitzWith L u) (hM : LipschitzWith M v) + (hom : ∀r:ℝ, 0potential x*positiveSquareRatio v u x + have hφ : Test B potential := radial_potential_test + obtain ⟨K,hφL⟩ := ContDiff.lipschitzWith_of_hasCompactSupport hφ.2.1 hφ.1 (by simp) + obtain ⟨J,hq'⟩ := lipschitz_mul_compact (positiveSquareRatio_lipschitz hL hM hC hn hbound) hφL hφ.2.1 + have hq : LipschitzWith J q := by simpa only [q,mul_comm] using hq' + have hc : HasCompactSupport q := hφ.2.1.mul_right + have hs : tsupport q ⊆ B := tsupport_mul_subset_left.trans hφ.2.2 + obtain ⟨A,hA⟩ := hφ.2.1.exists_bound_of_continuous contDiff_potential.continuous + have hC0 : 0<(C:ℝ) := lt_of_lt_of_le zero_lt_one (show 1≤(C:ℝ) from hC) + have hqbound : ∀x, |q x| ≤ ((|A|+1)*(C:ℝ)^2)*u x := by + intro x + rw [show q x=potential x*positiveSquareRatio v u x from rfl,abs_mul, + abs_of_nonneg (positiveSquareRatio_nonneg x)] + have hb := positiveSquareRatio_bound C.coe_nonneg hn hbound x + have hφb : |potential x| ≤ |A|+1 := (hA x).trans (by linarith [le_abs_self A]) + calc + _ ≤ (|A|+1)*((C:ℝ)^2*u x) := mul_le_mul hφb hb (positiveSquareRatio_nonneg x) (by positivity) + _ = _ := by ring + have hqI := hm.dominatedVariation hL (by norm_num : 0<(2:ℝ)) + (LipschitzSobolev.h10 hq hc isOpen_ball hs) + (show 0<(|A|+1)*(C:ℝ)^2 by positivity) (Eventually.of_forall hqbound) + have hu0 := SobolevCalculus.gradient_zero_on_zero_set isOpen_ball (LipschitzSobolev.h1_ball hL 0 2) + have hv0 := SobolevCalculus.gradient_zero_on_zero_set isOpen_ball (LipschitzSobolev.h1_ball hM 0 2) + have hq0 := SobolevCalculus.gradient_zero_on_zero_set isOpen_ball (LipschitzSobolev.h1_ball hq 0 2) + let F := fun x=>potential x*‖gradient v x‖^2-rawKernel x*v x^2 + let E := fun x=>inner ℝ (gradient u x) (gradient q x) + let R := fun x=>potential x*‖gradient v x-(v x/u x) • gradient u x‖^2 + have hRE : R =ᵐ[μ] (fun x=>F x-E x) := by + filter_upwards [ae_restrict_of_ae hL.ae_differentiableAt, + ae_restrict_of_ae hM.ae_differentiableAt,hu0,hv0,hq0] with x hux hvx hug hvg hqg + by_cases hup : 0mul_nonneg (potential_nonneg x) (sq_nonneg _))) hRi).mp hRI + have hle : volume.restrict (ball (0:Space d) 1)≤μ := + Measure.restrict_mono (ball_subset_ball (by norm_num)) le_rfl + filter_upwards [ae_mono hle haz,ae_restrict_mem measurableSet_ball] with x hx hxb + have hsq : ‖gradient v x-(v x/u x) • gradient u x‖^2=0 := + (mul_eq_zero.mp hx).resolve_left (potential_pos hxb).ne' + exact sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp hsq)) +end Bernoulli.Halfspace + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/CylindricalCalculus.lean b/lean/OAI/Analysis/BernoulliCone/CylindricalCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..b1b70fbad209b706eb620c60f5cd37edc8f9ed92 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/CylindricalCalculus.lean @@ -0,0 +1,195 @@ +import OAI.Analysis.BernoulliCone.ScalarLaplacian + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter Finset +open scoped Topology ContDiff Laplacian +namespace Bernoulli.Cylindrical +open ScalarLaplacian +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] +def axis (e x:E) : ℝ := inner ℝ x e +def transverse (e x:E) : E := x-axis e x • e +def radiusSq (e x:E) : ℝ := ‖x‖^2-(axis e x)^2 + +omit [FiniteDimensional ℝ E] in +theorem transverse_inner [FiniteDimensional ℝ E] (e x:E) (he:‖e‖=1) : inner ℝ (transverse e x) e=0 := by + simp [transverse,axis,inner_sub_left,real_inner_smul_left,he] +omit [FiniteDimensional ℝ E] in +theorem transverse_sq [FiniteDimensional ℝ E] (e x:E) (he:‖e‖=1) : ‖transverse e x‖^2=radiusSq e x := by + rw [transverse,norm_sub_sq_real,norm_smul,Real.norm_eq_abs,mul_pow,sq_abs,he, + real_inner_smul_right] + unfold radiusSq axis + ring +lemma radiusSq_nonneg (e x:E) (he:‖e‖=1) : 0≤radiusSq e x := by + rw [←transverse_sq e x he]; positivity +omit [FiniteDimensional ℝ E] in +lemma axis_contDiff [FiniteDimensional ℝ E] (e:E) {n:WithTop ℕ∞} : ContDiff ℝ n (axis e) := contDiff_id.inner ℝ contDiff_const +lemma radiusSq_contDiff (e:E) {n:WithTop ℕ∞} : ContDiff ℝ n (radiusSq e) := + (contDiff_norm_sq (𝕜:=ℝ) (E:=E) (n:=n)).sub ((axis_contDiff e).pow 2) +lemma gradient_axis (e x:E) : gradient (axis e) x=e := by + apply ext_inner_right ℝ + intro v + rw [←line_deriv (axis_contDiff e (n:=1) |>.differentiable (by norm_num) x) v] + have hh:=Axisymmetric.hasDerivAt_axis x v e 0 + change deriv (fun t:ℝ=>inner ℝ (x+t • v) e) 0 = _ + rw [hh.deriv,real_inner_comm] +lemma gradient_norm_sq (x:E) : gradient (fun z:E=>‖z‖^2) x=(2:ℝ) • x := by + apply ext_inner_right ℝ + intro v + rw [←line_deriv (contDiff_norm_sq (𝕜:=ℝ) (E:=E) (n:=1) |>.differentiable (by norm_num) x) v] + have hl : HasDerivAt (fun t:ℝ=>x+t • v) v 0 := by + simpa using ((hasDerivAt_id (0:ℝ)).smul_const v).const_add x + rw [hl.norm_sq.deriv] + simp [real_inner_smul_left] +lemma laplacian_axis (e x:E) : Δ (axis e) x=0 := by + rw [laplacian_sum_line (axis_contDiff e).contDiffAt] + apply Finset.sum_eq_zero + intro i hi + have hh : deriv (fun t:ℝ=>axis e (x+t • stdOrthonormalBasis ℝ E i))= + fun _=>inner ℝ (stdOrthonormalBasis ℝ E i) e := by + funext t; exact (Axisymmetric.hasDerivAt_axis x _ e t).deriv + rw [hh,deriv_const] +lemma laplacian_norm_sq (x:E) : Δ (fun z:E=>‖z‖^2) x=2*(Module.finrank ℝ E : ℝ) := by + rw [laplacian_sum_line (contDiff_norm_sq (𝕜:=ℝ) (E:=E) (n:=2)).contDiffAt] + have hh (v:E) : deriv (deriv (fun t:ℝ=>‖x+t • v‖^2)) 0=2*‖v‖^2 := by + have hl (t:ℝ) : HasDerivAt (fun s:ℝ=>x+s • v) v t := by + simpa using ((hasDerivAt_id t).smul_const v).const_add x + have he : deriv (fun t:ℝ=>‖x+t • v‖^2)=fun t=>2*inner ℝ (x+t • v) v := by + funext t; exact (hl t).norm_sq.deriv + rw [he] + have hd:=((hl 0).inner ℝ (hasDerivAt_const (0:ℝ) v)).const_mul 2 + simpa using hd.deriv + simp_rw [hh] + simp [mul_comm] +lemma gradient_radiusSq (e x:E) : gradient (radiusSq e) x=(2:ℝ) • transverse e x := by + have ha := (axis_contDiff e (n:=1)).differentiable (by norm_num) x + have hn := (contDiff_norm_sq (𝕜:=ℝ) (E:=E) (n:=1)).differentiable (by norm_num) x + apply ext_inner_right ℝ + intro v + rw [inner_gradient_left] + change (fderiv ℝ (fun z:E=>‖z‖^2-(axis e z)^2) x) v = _ + have hh:=hn.hasFDerivAt.sub (ha.hasFDerivAt.pow 2) + change (fderiv ℝ ((fun z:E=>‖z‖^2)-(fun z:E=>(axis e z)^2)) x) v = _ + rw [hh.fderiv] + simp only [sub_apply,smul_apply] + rw [←inner_gradient_left,gradient_norm_sq,←inner_gradient_left,gradient_axis] + dsimp [transverse] + simp only [real_inner_smul_left,inner_sub_left] + ring +lemma laplacian_radiusSq (e x:E) (he:‖e‖=1) : Δ (radiusSq e) x=2*((Module.finrank ℝ E : ℝ)-1) := by + have hφ : ContDiffAt ℝ 2 (fun s:ℝ=>s^2) (axis e x) := contDiffAt_id.pow 2 + have hh:=laplacian_comp hφ (axis_contDiff e).contDiffAt + have hder : deriv (fun s:ℝ=>s^2) = fun s=>2*s := by funext s; simp + have hder2 : deriv (deriv (fun s:ℝ=>s^2)) (axis e x)=2 := by rw [hder]; simp + rw [hder2,gradient_axis,he,laplacian_axis] at hh + change Δ ((fun z:E=>‖z‖^2)-(fun z:E=>(axis e z)^2)) x = _ + rw [(contDiff_norm_sq (𝕜:=ℝ) (E:=E) (n:=2)).contDiffAt.laplacian_sub ((axis_contDiff e).pow 2).contDiffAt, + laplacian_norm_sq,hh] + ring + +/-- A smooth cylindrical cap, expressed using the squared transverse radius so +that the symmetry axis is included without a singular-coordinate convention. -/ +def lift (e:E) (y k h:ℝ→ℝ) (x:E) : ℝ := y (radiusSq e x)*h (axis e x*k (radiusSq e x)) +lemma contDiffAt_lift {e x:E} {y k h:ℝ→ℝ} {n:WithTop ℕ∞} + (hy:ContDiffAt ℝ n y (radiusSq e x)) (hk:ContDiffAt ℝ n k (radiusSq e x)) + (hh:ContDiffAt ℝ n h (axis e x*k (radiusSq e x))) : ContDiffAt ℝ n (lift e y k h) x := by + exact (hy.comp x (radiusSq_contDiff e).contDiffAt).mul + (hh.comp x ((axis_contDiff e).contDiffAt.mul (hk.comp x (radiusSq_contDiff e).contDiffAt))) + +lemma gradient_lift {e x:E} {y k h:ℝ→ℝ} + (hy:DifferentiableAt ℝ y (radiusSq e x)) (hk:DifferentiableAt ℝ k (radiusSq e x)) + (hh:DifferentiableAt ℝ h (axis e x*k (radiusSq e x))) : + gradient (lift e y k h) x = + (2*deriv y (radiusSq e x)*h (axis e x*k (radiusSq e x))) • transverse e x+ + (y (radiusSq e x)*deriv h (axis e x*k (radiusSq e x))) • + (k (radiusSq e x) • e+(2*axis e x*deriv k (radiusSq e x)) • transverse e x) := by + have hq: DifferentiableAt ℝ (radiusSq e) x := + (radiusSq_contDiff e (n:=1)).differentiable (by norm_num) x + have ha: DifferentiableAt ℝ (axis e) x := + (axis_contDiff e (n:=1)).differentiable (by norm_num) x + have hyq : DifferentiableAt ℝ (fun z=>y (radiusSq e z)) x := hy.comp x hq + have hkq : DifferentiableAt ℝ (fun z=>k (radiusSq e z)) x := hk.comp x hq + have hs : DifferentiableAt ℝ (fun z=>axis e z*k (radiusSq e z)) x := ha.mul hkq + have hhs : DifferentiableAt ℝ (fun z=>h (axis e z*k (radiusSq e z))) x := hh.comp x hs + change gradient (fun z=>y (radiusSq e z)*h (axis e z*k (radiusSq e z))) x=_ + rw [gradient_mul hyq hhs,gradient_comp hy hq,gradient_comp (f:=fun z:E=>axis e z*k (radiusSq e z)) hh hs, + gradient_mul ha hkq,gradient_comp hk hq,gradient_radiusSq,gradient_axis] + simp only [smul_smul] + module + +lemma laplacian_lift {e x:E} (he:‖e‖=1) {y k h:ℝ→ℝ} + (hy:ContDiffAt ℝ 2 y (radiusSq e x)) (hk:ContDiffAt ℝ 2 k (radiusSq e x)) + (hh:ContDiffAt ℝ 2 h (axis e x*k (radiusSq e x))) : + Δ (lift e y k h) x = + y (radiusSq e x)*deriv (deriv h) (axis e x*k (radiusSq e x))* + ((k (radiusSq e x))^2+4*radiusSq e x*(axis e x)^2*(deriv k (radiusSq e x))^2)+ + deriv h (axis e x*k (radiusSq e x))* + (axis e x*y (radiusSq e x)*(4*radiusSq e x*deriv (deriv k) (radiusSq e x)+ + 2*((Module.finrank ℝ E:ℝ)-1)*deriv k (radiusSq e x))+ + 8*radiusSq e x*axis e x*deriv y (radiusSq e x)*deriv k (radiusSq e x))+ + h (axis e x*k (radiusSq e x))*(4*radiusSq e x*deriv (deriv y) (radiusSq e x)+ + 2*((Module.finrank ℝ E:ℝ)-1)*deriv y (radiusSq e x)) := by + let q := radiusSq e + let a := axis e + let Y := fun z=>y (q z) + let K := fun z=>k (q z) + let s := fun z=>a z*K z + have hq : ContDiffAt ℝ 2 q x := (radiusSq_contDiff e).contDiffAt + have ha : ContDiffAt ℝ 2 a x := (axis_contDiff e).contDiffAt + have hY : ContDiffAt ℝ 2 Y x := hy.comp x hq + have hK : ContDiffAt ℝ 2 K x := hk.comp x hq + have hs : ContDiffAt ℝ 2 s x := ha.mul hK + have gY : gradient Y x=deriv y (q x) • ((2:ℝ) • transverse e x) := by + rw [gradient_comp (hy.differentiableAt (by norm_num)) (hq.differentiableAt (by norm_num))] + rw [show gradient q x=(2:ℝ) • transverse e x from gradient_radiusSq e x] + have gK : gradient K x=deriv k (q x) • ((2:ℝ) • transverse e x) := by + rw [gradient_comp (hk.differentiableAt (by norm_num)) (hq.differentiableAt (by norm_num))] + rw [show gradient q x=(2:ℝ) • transverse e x from gradient_radiusSq e x] + have gs : gradient s x=K x • e+(a x*deriv k (q x)*2) • transverse e x := by + rw [gradient_mul (ha.differentiableAt (by norm_num)) (hK.differentiableAt (by norm_num)),gK] + rw [show gradient a x=e from gradient_axis e x] + simp [smul_smul,mul_assoc] + have gn : ‖gradient q x‖^2=4*q x := by + rw [show gradient q x=(2:ℝ) • transverse e x from gradient_radiusSq e x,norm_smul,mul_pow, + Real.norm_eq_abs,transverse_sq e x he] + norm_num [q] + have gort : inner ℝ e (transverse e x)=0 := by rw [real_inner_comm,transverse_inner e x he] + have gsn : ‖gradient s x‖^2=(K x)^2+4*q x*(a x)^2*(deriv k (q x))^2 := by + rw [gs,norm_add_sq_real] + simp only [norm_smul,mul_pow,Real.norm_eq_abs,sq_abs,he,mul_one, + real_inner_smul_left,real_inner_smul_right,gort,mul_zero,add_zero,transverse_sq e x he] + dsimp [q]; ring + have gaK : inner ℝ (gradient a x) (gradient K x)=0 := by + rw [show gradient a x=e from gradient_axis e x,gK] + simp [real_inner_smul_right,gort] + have gYs : inner ℝ (gradient Y x) (gradient s x)=4*q x*a x*deriv y (q x)*deriv k (q x) := by + rw [gY,gs] + simp only [inner_add_right,real_inner_smul_left,real_inner_smul_right, + transverse_inner e x he,mul_zero,zero_add,real_inner_self_eq_norm_sq,transverse_sq e x he] + dsimp [q]; ring + have lY : Δ Y x=deriv (deriv y) (q x)*(4*q x)+deriv y (q x)*(2*((Module.finrank ℝ E:ℝ)-1)) := by + rw [laplacian_comp hy hq,gn,show Δ q x=2*((Module.finrank ℝ E:ℝ)-1) from laplacian_radiusSq e x he] + have lK : Δ K x=deriv (deriv k) (q x)*(4*q x)+deriv k (q x)*(2*((Module.finrank ℝ E:ℝ)-1)) := by + rw [laplacian_comp hk hq,gn,show Δ q x=2*((Module.finrank ℝ E:ℝ)-1) from laplacian_radiusSq e x he] + have ls : Δ s x=a x*Δ K x := by + rw [laplacian_mul ha hK,show Δ a x=0 from laplacian_axis e x,gaK] + ring + have gH : gradient (fun z=>h (s z)) x=deriv h (s x) • gradient s x := + gradient_comp (hh.differentiableAt (by norm_num)) (hs.differentiableAt (by norm_num)) + change Δ (fun z=>Y z*h (s z)) x = _ + have hH : ContDiffAt ℝ 2 (fun z=>h (s z)) x := hh.comp x hs + rw [laplacian_mul hY hH,laplacian_comp (f:=s) hh hs,gH, + real_inner_smul_right,gYs,gsn,ls,lK,lY] + dsimp [Y,K,s,a,q] + ring +end Bernoulli.Cylindrical + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/DominatedVariation.lean b/lean/OAI/Analysis/BernoulliCone/DominatedVariation.lean new file mode 100644 index 0000000000000000000000000000000000000000..34fb6a03bba1e93b5d8f885f107de185f101df0e --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/DominatedVariation.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BernoulliCone.HalfspaceGroundstate + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} + +lemma dominatedVariation_of_comparison [IsFiniteMeasure (volume.restrict D)] + {u v : Space d → ℝ} {G V : Space d → Space d} + (hu : H1 D u G) (hv : H10 D v V) + (hn : ∀ᵐ x ∂volume.restrict D, 0≤u x) + {C : ℝ} (hC : 0w x-u x) (fun x=>W x-G x) → energy D u G≤energy D w W) : + (∫ x in D, inner ℝ (G x) (V x))=0 := by + apply linear_coefficient_eq_zero _ (∫ x in D, ‖V x‖^2) (inv_pos.mpr hC) + intro t ht + have htC : |t| * C<1 := by + calc |t| * C < C⁻¹*C := mul_lt_mul_of_pos_right ht hC + _ = 1 := inv_mul_cancel₀ hC.ne' + have hcontrol : ∀ᵐ x ∂volume.restrict D, + 0≤u x+t*v x ∧ ((0u x+t*v x) (fun x=>G x+t • V x) + (hu.add (hv.1.const_smul t)) (hcontrol.mono fun _ hx=>hx.1) + (by simpa only [add_sub_cancel_left] using hv.const_smul t) + rw [energy_affine hu.1 hu.2.1 hv.1.2.1 t (hcontrol.mono fun _ hx=>hx.2)] at hc + linarith + +lemma GlobalMinimizer.dominatedVariation {u v : Space d → ℝ} {L : ℝ≥0} + (hm : GlobalMinimizer u) (hL : LipschitzWith L u) + {a : Space d} {R C : ℝ} (hR : 0κ*(Zsigned y+capAmplitude*l^3*KSup y)) := by + filter_upwards [((Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.continuousAt).eventually (lt_mem_nhds hq), + (upperFamily_continuous l).continuousAt.eventually (lt_mem_nhds hp)] with y hy hpy + rw [upperFamily_outer_formula hl hy.le] at hpy ⊢ + have hh:0κ*(Zsigned y+capAmplitude*l^3*KSup y)) x=_ + have hdf:DifferentiableAt ℝ (fun y=>Zsigned y+capAmplitude*l^3*KSup y) x:= + hdZ.add (hdK.const_mul (capAmplitude*l^3)) + rw [gradient_const_mul κ hdf, + gradient_add' hdZ (hdK.const_mul (capAmplitude*l^3)),gradient_const_mul (capAmplitude*l^3) hdK,smul_add,smul_smul] + congr 2 + ring + +/-- On the actual exterior branch the inverse leaf parameter cancels completely. +The calibration extends affinely to the lower graph; there is no cube-root +singularity in the field itself. -/ +theorem upperCalibration_outer_affine {p:Space 7×ℝ} (hp:U p.11:=by + rw [inv_pow,←div_eq_inv_mul] + change 1a • gradient KSup p.1) + apply (eq_div_iff hK).mpr + nlinarith [hh] +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/FluxBounds.lean b/lean/OAI/Analysis/BernoulliCone/FluxBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..11dfab13a6f58e5811109756f5115ff29113f2a1 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/FluxBounds.lean @@ -0,0 +1,99 @@ +import OAI.Analysis.BernoulliCone.CalibrationTraces + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.DeSilvaJerison +open Axisymmetric +lemma cap_positive_bounded {x:Space 7} (hq:Cylindrical.radiusSq axis x≤1) + (hp:0|f t|+|fp t|+capAmplitude*(2*|gSup t|+|gSup1 t|) + have hR:ContinuousOn R (Icc (-3/5:ℝ) (3/5)):=by + intro t ht + have ht1:t∈Ioo (-1:ℝ) 1:=⟨by linarith [ht.1],by linarith [ht.2]⟩ + have ht2:|t|<1:=abs_lt.mpr ht1 + exact (((hasDerivAt_f ht1).continuousAt.abs.add (hasDerivAt_fp ht1).continuousAt.abs).add + (continuousAt_const.mul (((hasDerivAt_gSup ht2).continuousAt.abs.const_mul 2).add + (hasDerivAt_gSup1 ht2).continuousAt.abs))).continuousWithinAt + obtain ⟨C,hC⟩:=isCompact_Icc.exists_bound_of_continuousOn hR + refine ⟨|C|+1,by positivity,?_⟩ + intro x hq hp + obtain ⟨hx,ha⟩:=radiusSq_pos_data (show 0hs ((normalized_radius_eq_one_iff hp hq).mp h)) + +lemma exteriorFlux_eventually_eq {p:Space 7×ℝ} (hp:U p.1κ*l*outerSigned (l⁻¹ • y)) =ᶠ[𝓝 x] + (fun y=>κ*(Zsigned y+capAmplitude*l^3*KSup y)):=by + filter_upwards [((Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.continuousAt).eventually (lt_mem_nhds hq)] with y hy + exact outerSigned_dilation_formula hl hy + rw [←gradient_dilation hl.ne' ((outerSigned_contDiffAt (n:=1) hyn hya).differentiableAt (by simp)),gradient,he.fderiv_eq] + change gradient (fun y=>κ*(Zsigned y+capAmplitude*l^3*KSup y)) x=_ + have hdf:DifferentiableAt ℝ (fun y=>Zsigned y+capAmplitude*l^3*KSup y) x:= + hdz.add (hdk.const_mul (capAmplitude*l^3)) + rw [gradient_const_mul κ hdf,gradient_add' hdz (hdk.const_mul (capAmplitude*l^3)), + gradient_const_mul (capAmplitude*l^3) hdk,smul_add,smul_smul] + congr 2 + ring + +lemma seamHeight_signed_dilation {x:Space 7} (hq:0A (x,p.2)) p.1+inner ℝ (A p) (deriv (fun t=>A (p.1,t)) p.2) +lemma bulkExpression_congr {A B:E×ℝ→E} {p:E×ℝ} (he:A =ᶠ[𝓝 p] B) : + bulkExpression A p=bulkExpression B p := by + have hx:(fun x=>A (x,p.2)) =ᶠ[𝓝 p.1] (fun x=>B (x,p.2)):= + he.comp_tendsto (continuousAt_id.prodMk continuousAt_const) + have ht:(fun t=>A (p.1,t)) =ᶠ[𝓝 p.2] (fun t=>B (p.1,t)):= + he.comp_tendsto (continuousAt_const.prodMk continuousAt_id) + unfold bulkExpression divergence + rw [hx.fderiv_eq,he.self_of_nhds,ht.deriv_eq] +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/FoliationDifferential.lean b/lean/OAI/Analysis/BernoulliCone/FoliationDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..94c595300f6050e90af1581e234d9b3a884662ad --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/FoliationDifferential.lean @@ -0,0 +1,168 @@ +import OAI.Analysis.BernoulliCone.UpperSmoothLeaves + +namespace OAI + +universe uE uG + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff Laplacian +namespace Bernoulli.Foliation +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +/-- Spatial gradient of a smooth one-parameter family, as a joint field. -/ +def spatialGradient (F:E×ℝ→ℝ) (p:E×ℝ) : E := + (toDual ℝ E).symm (fderiv ℝ F p ∘L ContinuousLinearMap.inl ℝ E ℝ) + +def divergence (V:E→E) (x:E) : ℝ := + ∑ i, inner ℝ (stdOrthonormalBasis ℝ E i) (fderiv ℝ V x (stdOrthonormalBasis ℝ E i)) + +lemma inner_spatialGradient (F:E×ℝ→ℝ) (p:E×ℝ) (v:E) : + inner ℝ (spatialGradient F p) v = fderiv ℝ F p (v,0) := by + rw [spatialGradient,←toDual_apply_apply (𝕜:=ℝ),LinearIsometryEquiv.apply_symm_apply] + rfl + +omit [FiniteDimensional ℝ E] in +lemma linear_prod_decomposition {G : Type uG} [NormedAddCommGroup G] [NormedSpace ℝ G] + (L:E×ℝ→L[ℝ] G) (v:E) (s:ℝ) : L (v,s)=L (v,0)+s • L (0,1) := by + calc + _ = L ((v,0)+s • ((0:E),(1:ℝ))) := by congr 1; ext <;> simp + _ = _ := by rw [map_add,map_smul] + +omit [FiniteDimensional ℝ E] in +lemma sliceLeft_hasFDerivAt {G : Type uG} [NormedAddCommGroup G] [NormedSpace ℝ G] + {F:E×ℝ→G} {p:E×ℝ} (hF:DifferentiableAt ℝ F p) : + HasFDerivAt (fun x:E=>F (x,p.2)) (fderiv ℝ F p ∘L ContinuousLinearMap.inl ℝ E ℝ) p.1 := by + rcases p with ⟨x,t⟩ + have hi:HasFDerivAt (fun y:E=>(y,t)) (ContinuousLinearMap.inl ℝ E ℝ) x := by + simpa only [ContinuousLinearMap.inl,id_eq] using (hasFDerivAt_id (𝕜:=ℝ) x).prodMk (hasFDerivAt_const t x) + exact hF.hasFDerivAt.comp x hi + +lemma spatialGradient_eq {F:E×ℝ→ℝ} {p:E×ℝ} (hF:DifferentiableAt ℝ F p) : + spatialGradient F p=gradient (fun x:E=>F (x,p.2)) p.1 := by + apply ext_inner_right ℝ + intro v + rw [inner_spatialGradient,inner_gradient_left] + have hd := sliceLeft_hasFDerivAt hF + rw [hd.fderiv] + simp + +lemma spatialGradient_contDiffAt {F:E×ℝ→ℝ} {p:E×ℝ} (hF:ContDiffAt ℝ ∞ F p) : + ContDiffAt ℝ ∞ (spatialGradient F) p := by + have hpart : ContDiffAt ℝ ∞ (fun q:E×ℝ=>fderiv ℝ F q ∘L ContinuousLinearMap.inl ℝ E ℝ) p := + (hF.fderiv_right (by simp)).clm_comp contDiffAt_const + exact (toDual ℝ E).symm.toContinuousLinearEquiv.contDiff.contDiffAt.comp p hpart + +lemma parameter_directional {F:E×ℝ→ℝ} {L:E×ℝ→ℝ} {p:E×ℝ} + (hF:DifferentiableAt ℝ F (p.1,L p)) (hL:DifferentiableAt ℝ L p) + (he:∀ᶠ z in 𝓝 p,F (z.1,L z)=z.2) + (hρ:fderiv ℝ F (p.1,L p) (0,1)≠0) (v:E) (s:ℝ) : + fderiv ℝ L p (v,s)=(s-inner ℝ (spatialGradient F (p.1,L p)) v)/ + fderiv ℝ F (p.1,L p) (0,1) := by + have hd := hF.hasFDerivAt.comp p ((hasFDerivAt_fst (p:=p)).prodMk hL.hasFDerivAt) + have hh := congrArg (fun T:E×ℝ→L[ℝ] ℝ=>T (v,s)) + ((hd.congr_of_eventuallyEq (he.mono (fun _ h=>h.symm))).unique (hasFDerivAt_snd (p:=p))) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ] at hh + rw [linear_prod_decomposition,smul_eq_mul,←inner_spatialGradient] at hh + change inner ℝ (spatialGradient F (p.1,L p)) v + + fderiv ℝ L p (v,s) * fderiv ℝ F (p.1,L p) (0,1) = s at hh + apply (eq_div_iff hρ).mpr + linarith + +lemma divergence_gradient {f:E→ℝ} {x:E} (hf:ContDiffAt ℝ ∞ f x) : + divergence (gradient f) x=Δ f x := by + have hg:ContDiffAt ℝ ∞ (gradient f) x := + (toDual ℝ E).symm.toContinuousLinearEquiv.contDiff.contDiffAt.comp x (hf.fderiv_right (by simp)) + rw [divergence,laplacian_eq_iteratedFDeriv_stdOrthonormalBasis] + apply Finset.sum_congr rfl + intro i _ + let v:=stdOrthonormalBasis ℝ E i + have he:(fun y=>inner ℝ (gradient f y) v)=(fun y=>fderiv ℝ f y v) := by + ext y + exact inner_gradient_left + have hh := congrArg (fun T:E→L[ℝ] ℝ=>T v) (congrArg (fun a:E→ℝ=>fderiv ℝ a x) he) + have hdir: DifferentiableAt ℝ (fderiv ℝ f) x := + (hf.fderiv_right (m:=∞) (by simp)).differentiableAt (by simp) + rw [((hg.differentiableAt (by simp)).hasFDerivAt.inner ℝ (hasFDerivAt_const v x)).fderiv, + fderiv_clm_apply hdir (differentiableAt_const v)] at hh + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + zero_apply,add_apply,ContinuousLinearMap.flip_apply, + fderiv_const_apply,map_zero,zero_add] at hh + simp only [fderivInnerCLM_apply,inner_zero_right,zero_add] at hh + rw [real_inner_comm] at hh + rw [iteratedFDeriv_two_apply] + simpa only [Fin.isValue, Matrix.cons_val_zero, Matrix.cons_val_one, Matrix.cons_val_fin_one] using hh + +/-- Cancellation of the parameter derivatives in the extended calibration. +This is the differential identity for an actual foliation, not an assumed PDE. -/ +lemma foliation_divergence {F:E×ℝ→ℝ} {L:E×ℝ→ℝ} {p:E×ℝ} + (hF:ContDiffAt ℝ ∞ F (p.1,L p)) (hL:ContDiffAt ℝ ∞ L p) + (he:∀ᶠ z in 𝓝 p,F (z.1,L z)=z.2) + (hρ:fderiv ℝ F (p.1,L p) (0,1)≠0) : + let A:E×ℝ→E:=fun z=>spatialGradient F (z.1,L z) + divergence (fun x=>A (x,p.2)) p.1+ + inner ℝ (A p) (deriv (fun t=>A (p.1,t)) p.2)= + Δ (fun x:E=>F (x,L p)) p.1 := by + dsimp only + let q:E×ℝ:=(p.1,L p) + let B:=spatialGradient F + let A:E×ℝ→E:=fun z=>B (z.1,L z) + let T:=fderiv ℝ B q (0,1) + let ρ:=fderiv ℝ F q (0,1) + have hBd:DifferentiableAt ℝ B q:=(spatialGradient_contDiffAt hF).differentiableAt (by simp) + have hLd:DifferentiableAt ℝ L p:=hL.differentiableAt (by simp) + have hFd:DifferentiableAt ℝ F q:=hF.differentiableAt (by simp) + have hmap:HasFDerivAt (fun z:E×ℝ=>(z.1,L z)) + ((ContinuousLinearMap.fst ℝ E ℝ).prod (fderiv ℝ L p)) p := + hasFDerivAt_fst.prodMk hLd.hasFDerivAt + have hAd:HasFDerivAt A (fderiv ℝ B q ∘L + ((ContinuousLinearMap.fst ℝ E ℝ).prod (fderiv ℝ L p))) p := + by simpa only [A,Function.comp_def,q] using hBd.hasFDerivAt.comp p hmap + have hd (v:E) (s:ℝ) : fderiv ℝ A p (v,s)=fderiv ℝ B q (v,0)+ + ((s-inner ℝ (B q) v)/ρ) • T := by + rw [hAd.fderiv] + change fderiv ℝ B q (v,fderiv ℝ L p (v,s)) = _ + rw [linear_prod_decomposition,parameter_directional hFd hLd he hρ] + have hx (v:E) : fderiv ℝ (fun x:E=>A (x,p.2)) p.1 v=fderiv ℝ A p (v,0) := by + rw [(sliceLeft_hasFDerivAt hAd.differentiableAt).fderiv] + simp + have ht : deriv (fun t:ℝ=>A (p.1,t)) p.2=ρ⁻¹ • T := by + have hh:=hAd.comp_hasDerivAt p.2 ((hasDerivAt_const p.2 p.1).prodMk (hasDerivAt_id p.2)) + change HasDerivAt (fun t:ℝ=>A (p.1,t)) _ p.2 at hh + rw [←hAd.fderiv] at hh + rw [hh.deriv] + rw [hd] + simp only [inner_zero_right,sub_zero,one_div] + rw [show ((0:E),(0:ℝ))=(0:E×ℝ) from rfl,map_zero,zero_add] + have hspatial : divergence (fun x:E=>B (x,L p)) p.1=Δ (fun x:E=>F (x,L p)) p.1 := by + have heq:(fun x:E=>B (x,L p)) =ᶠ[𝓝 p.1] gradient (fun x:E=>F (x,L p)) := by + have hn:Tendsto (fun x:E=>(x,L p)) (𝓝 p.1) (𝓝 q):=continuousAt_id.prodMk continuousAt_const + have hF1:ContDiffAt ℝ 1 F q:=hF.of_le (by simp) + filter_upwards [hn.eventually (hF1.eventually (by simp))] with x hx + exact spatialGradient_eq (hx.differentiableAt (by simp)) + have hfs:ContDiffAt ℝ ∞ (fun x:E=>F (x,L p)) p.1 := + hF.comp p.1 (contDiffAt_id.prodMk contDiffAt_const) + rw [divergence,heq.fderiv_eq] + exact divergence_gradient hfs + have hbase (v:E):fderiv ℝ (fun x:E=>B (x,L p)) p.1 v=fderiv ℝ B q (v,0) := by + rw [(sliceLeft_hasFDerivAt hBd).fderiv] + simp + change divergence (fun x=>A (x,p.2)) p.1+inner ℝ (B q) (deriv (fun t=>A (p.1,t)) p.2)=_ + rw [ht,←hspatial,divergence,divergence] + simp_rw [hx,hbase,hd,inner_add_right,real_inner_smul_right,zero_sub,neg_div] + rw [Finset.sum_add_distrib] + have hec:(∑ i, -(inner ℝ (B q) (stdOrthonormalBasis ℝ E i)/ρ)* + inner ℝ (stdOrthonormalBasis ℝ E i) T) = - (inner ℝ (B q) T/ρ) := by + simp only [neg_mul,Finset.sum_neg_distrib,div_mul_eq_mul_div,←Finset.sum_div] + rw [(stdOrthonormalBasis ℝ E).sum_inner_mul_inner] + rw [hec] + ring +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/FoliationGraph.lean b/lean/OAI/Analysis/BernoulliCone/FoliationGraph.lean new file mode 100644 index 0000000000000000000000000000000000000000..7f46fcc2af4271bdb9d1002d07e10b20d35ae41f --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/FoliationGraph.lean @@ -0,0 +1,131 @@ +import OAI.Analysis.BernoulliCone.JointIntervalIntegral + +namespace OAI + +universe uE + +section +noncomputable section +open MeasureTheory Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.Foliation +open ParametricIntegral +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] +lemma divergence_graph_primitive {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) : + divergence (fun y:E=>heightPrimitive A (y,u y)) x= + (∫s in (0:ℝ)..u x,divergence (fun y:E=>A (y,s)) x)+ + inner ℝ (A (x,u x)) (gradient u x) := by + let e:=stdOrthonormalBasis ℝ E + have hc:Continuous (fun s:ℝ=>fderiv ℝ A (x,s)):= + (hA.continuous_fderiv (by norm_num)).comp (continuous_const.prodMk continuous_id) + have hci (i):Continuous (fun s:ℝ=>inner ℝ (e i) (fderiv ℝ A (x,s) (e i,0))):= + continuous_const.inner (hc.clm_apply continuous_const) + have hi (s:ℝ) (v:E):fderiv ℝ (fun y:E=>A (y,s)) x v=fderiv ℝ A (x,s) (v,0):=by + rw [(sliceLeft_hasFDerivAt ((hA.differentiable (by norm_num)) (x,s))).fderiv] + simp + have he (v:E):inner ℝ v (∫s in (0:ℝ)..u x,fderiv ℝ A (x,s) (v,0))= + ∫s in (0:ℝ)..u x,inner ℝ v (fderiv ℝ A (x,s) (v,0)) := + ((innerSL ℝ v).intervalIntegral_comp_comm + ((hc.clm_apply continuous_const).intervalIntegrable 0 (u x))).symm + rw [divergence] + simp_rw [graph_fderiv hA hu,inner_add_right,real_inner_smul_right,he] + rw [Finset.sum_add_distrib] + congr 1 + · rw [←intervalIntegral.integral_finsetSum (fun i _=>(hci i).intervalIntegrable 0 (u x))] + apply intervalIntegral.integral_congr + intro s _ + simp only [divergence,hi] + rfl + · simp_rw [←inner_gradient_left] + rw [(stdOrthonormalBasis ℝ E).sum_inner_mul_inner] + exact real_inner_comm _ _ +lemma continuous_spatial_divergence {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) (x:E) : + Continuous (fun s:ℝ=>divergence (fun y:E=>A (y,s)) x) := by + have hc:Continuous (fun s:ℝ=>fderiv ℝ A (x,s)):= + (hA.continuous_fderiv (by norm_num)).comp (continuous_const.prodMk continuous_id) + have hi (s:ℝ) (v:E):fderiv ℝ (fun y:E=>A (y,s)) x v=fderiv ℝ A (x,s) (v,0):=by + rw [(sliceLeft_hasFDerivAt ((hA.differentiable (by norm_num)) (x,s))).fderiv] + simp + simp only [divergence,hi] + exact continuous_finsetSum _ (fun i _=>continuous_const.inner (hc.clm_apply continuous_const)) + +/-- Integrating the nonlinear bulk inequality gives exactly the flux difference. +This is FTC and parameter differentiation, not a postulated graph comparison. -/ +lemma integrated_bulk {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) (x:E) {a b:ℝ} (hab:a≤b) + (hbulk:∀s∈Icc a b,divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) : + 2*(∫s in a..b,divergence (fun y:E=>A (y,s)) x)≤‖A (x,a)‖^2-‖A (x,b)‖^2 := by + have hAC:ContDiff ℝ 1 (fun s:ℝ=>A (x,s)):=hA.comp (contDiff_const.prodMk contDiff_id) + have hDC:Continuous (deriv (fun t:ℝ=>A (x,t))) := hAC.continuous_deriv (by norm_num) + have hAD(s:ℝ):HasDerivAt (fun t:ℝ=>A (x,t)) (deriv (fun t:ℝ=>A (x,t)) s) s:= + (hAC.differentiable (by norm_num) s).hasDerivAt + have hN(s:ℝ):HasDerivAt (fun t:ℝ=>‖A (x,t)‖^2) + (2*inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)) s:=by + simpa only [real_inner_self_eq_norm_sq,real_inner_comm (deriv (fun t:ℝ=>A (x,t)) s),two_mul] using + (hAD s).inner ℝ (hAD s) + have hc:Continuous (fun s:ℝ=>2*inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)):= + continuous_const.mul (hAC.continuous.inner hDC) + have hFTC:(∫s in a..b,2*inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s))= + ‖A (x,b)‖^2-‖A (x,a)‖^2:= + intervalIntegral.integral_eq_sub_of_hasDerivAt (fun s _=>hN s) (hc.intervalIntegrable a b) + have hi:IntervalIntegrable (fun s:ℝ=>2*divergence (fun y:E=>A (y,s)) x) volume a b:= + (continuous_const.mul (continuous_spatial_divergence hA x)).intervalIntegrable a b + have hle:(∫s in a..b,2*divergence (fun y:E=>A (y,s)) x+ + 2*inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s))≤0 := by + have hh:=intervalIntegral.integral_mono_on hab (hi.add (hc.intervalIntegrable a b)) + (intervalIntegrable_const (c:=(0:ℝ))) (fun s hs=>by linarith [hbulk s hs]) + simpa using hh + rw [intervalIntegral.integral_add hi (hc.intervalIntegrable a b),hFTC, + intervalIntegral.integral_const_mul] at hle + linarith +lemma divergence_smul_sub {f g:E→E} {x:E} + (hf:DifferentiableAt ℝ f x) (hg:DifferentiableAt ℝ g x) (c:ℝ) : + divergence (fun y=>c • (f y-g y)) x=c*(divergence f x-divergence g x) := by + have hh:HasFDerivAt (fun y=>c • (f y-g y)) (c • (fderiv ℝ f x-fderiv ℝ g x)) x:= + (hf.hasFDerivAt.sub hg.hasFDerivAt).const_smul c + rw [divergence,hh.fderiv] + simp only [smul_apply,sub_apply, + real_inner_smul_right,inner_sub_right,Finset.mul_sum,Finset.sum_sub_distrib,divergence,mul_sub] + +def graphPotential (A:E×ℝ→E) (u v:E→ℝ) (x:E) : E := + (2:ℝ) • (heightPrimitive A (x,v x)-heightPrimitive A (x,u x)) +lemma graph_potential_identity {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) : + divergence (graphPotential A u v) x= + 2*(∫s in u x..v x,divergence (fun y:E=>A (y,s)) x)+ + 2*inner ℝ (A (x,v x)) (gradient v x)-2*inner ℝ (A (x,u x)) (gradient u x) := by + have hd(w:E→ℝ)(hw:DifferentiableAt ℝ w x): + DifferentiableAt ℝ (fun y:E=>heightPrimitive A (y,w y)) x:= + DifferentiableAt.comp (f:=fun y:E=>(y,w y)) (g:=heightPrimitive A) x + (heightPrimitive_differentiable hA (x,w x)) (differentiableAt_id.prodMk hw) + unfold graphPotential + rw [divergence_smul_sub (hd v hv) (hd u hu), + divergence_graph_primitive hA hv,divergence_graph_primitive hA hu] + have hi:=intervalIntegral.integral_interval_sub_left (μ:=volume) + ((continuous_spatial_divergence hA x).intervalIntegrable 0 (v x)) + ((continuous_spatial_divergence hA x).intervalIntegrable 0 (u x)) + rw [←hi] + ring + +lemma graph_potential_bulk_bound {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) + (huv:u x≤v x) + (hbulk:∀s∈Icc (u x) (v x),divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) : + divergence (graphPotential A u v) x≤‖gradient v x‖^2+ + ‖A (x,u x)‖^2-2*inner ℝ (A (x,u x)) (gradient u x) := by + have hi:=integrated_bulk hA x huv hbulk + have hs:0≤‖gradient v x-A (x,v x)‖^2:=sq_nonneg _ + rw [norm_sub_sq_real] at hs + have he:inner ℝ (gradient v x) (A (x,v x))=inner ℝ (A (x,v x)) (gradient v x):=real_inner_comm _ _ + rw [he] at hs + rw [graph_potential_identity hA hu hv] + linarith +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/FoliationSeam.lean b/lean/OAI/Analysis/BernoulliCone/FoliationSeam.lean new file mode 100644 index 0000000000000000000000000000000000000000..bb7d6fab7bba9bdfcc1e5659617ce50f6c6f49fd --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/FoliationSeam.lean @@ -0,0 +1,43 @@ +import OAI.Analysis.BernoulliCone.UpperCalibration + +namespace OAI + +universe uE + +section +noncomputable section +open scoped RealInnerProductSpace +namespace Bernoulli.Foliation +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +/-- The extended calibration jump across the graph of a matching seam. -/ +lemma seam_flux_identity (Gp Gm H N:E) (ρp ρm:ℝ) + (hp:H=Gp+ρp • N) (hm:H=Gm+ρm • N) : + ‖Gp‖^2-‖Gm‖^2-2*inner ℝ (Gp-Gm) H= + -(ρp+ρm)*inner ℝ (Gp-Gm) N := by + have hh:Gp+Gm-(2:ℝ) • H=-(ρp+ρm) • N := by + rw [hp] at hm + have hg:Gm=Gp+(ρp-ρm) • N := by + calc + Gm = (Gm+ρm • N)-ρm • N := by abel + _ = _ := by rw [←hm]; module + rw [hg,hp] + module + have hid:inner ℝ (Gp-Gm) (Gp+Gm-(2:ℝ) • H)= + ‖Gp‖^2-‖Gm‖^2-2*inner ℝ (Gp-Gm) H := by + simp only [inner_sub_right,inner_add_right,inner_sub_left,real_inner_smul_right, + real_inner_self_eq_norm_sq] + rw [real_inner_comm Gm Gp] + ring + rw [←hid,hh,real_inner_smul_right] +lemma seam_flux_nonpos (Gp Gm H N:E) (ρp ρm:ℝ) + (hp:H=Gp+ρp • N) (hm:H=Gm+ρm • N) + (hρ:0≤ρp+ρm) (hj:0 ≤ inner ℝ (Gp-Gm) N) : + ‖Gp‖^2-‖Gm‖^2-2*inner ℝ (Gp-Gm) H≤0 := by + rw [seam_flux_identity Gp Gm H N ρp ρm hp hm] + exact mul_nonpos_of_nonpos_of_nonneg (neg_nonpos.mpr hρ) hj +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/GlobalMinimizer.lean b/lean/OAI/Analysis/BernoulliCone/GlobalMinimizer.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0ed6819068ab8e4e1da8079d317e85c432f1f0c --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/GlobalMinimizer.lean @@ -0,0 +1,84 @@ +import OAI.Analysis.BernoulliCone.UpperComparison + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison + +/-- The constructed double-cone is a global energy minimizer against the full +arbitrary Sobolev competitor class. Upper and lower comparisons are joined by +the exact Sobolev lattice identity, including its contact-level gradients. -/ +theorem U_global_minimizer : GlobalMinimizer U := by + refine ⟨isOpen_univ,gradient U,U_h1loc,?_,?_⟩ + · simpa only [Measure.restrict_univ] using (Eventually.of_forall U_nonneg : ∀ᵐ x:Space 7 ∂volume,0≤U x) + intro c r hr hB v V hv hvn htrace + let B:=Metric.ball c r + let G:=gradient U + have hu:H1 B U G:=U_h1loc c r hr (subset_univ _) + have hpos:=SobolevCalculus.h10_positivePart Metric.isOpen_ball htrace + have hneg:H10 B (fun x=>max (U x-v x) 0) + (fun x=>(if 0U x+max (v x-U x) 0 + let P:=fun x=>G x+(if 0U x-max (U x-v x) 0 + let M:=fun x=>G x-(if 0p x-U x) (fun x=>P x-G x):=by + apply hpos.congr + · exact Eventually.of_forall (fun x=>by dsimp [p]; ring) + · exact Eventually.of_forall (fun x=>by dsimp [P]; abel) + have hmt:H10 B (fun x=>m x-U x) (fun x=>M x-G x):=by + apply hneg.neg.congr + · exact Eventually.of_forall (fun x=>by dsimp [m]; ring) + · exact Eventually.of_forall (fun x=>by dsimp [M]; abel) + have hUp:∀ᵐ x ∂volume.restrict B,U x≤p x:= + Eventually.of_forall fun x=>le_add_of_nonneg_right (le_max_right _ _) + have hmU:∀ᵐ x ∂volume.restrict B,m x≤U x:= + Eventually.of_forall fun x=>sub_le_self _ (le_max_right _ _) + have hmn:∀ᵐ x ∂volume.restrict B, 0 ≤ m x:=by + filter_upwards [hvn] with x hx + change 0≤U x-max (U x-v x) 0 + exact sub_nonneg.mpr (max_le (by linarith) (U_nonneg x)) + have hupper:=U_upper_comparison c r hr hp hUp hpt + have hlower:=U_lower_comparison c r hr hm hmn hmU hmt + let :IsFiniteMeasure (volume.restrict B):=isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + have hI {f:Space 7→ℝ} {F:Space 7→Space 7} (h:H1 B f F): + Integrable (fun x=>‖F x‖^2+if 0χ x*Y x,?_,hχc.mul_right,?_⟩ + · rw [contDiff_iff_contDiffAt] + intro x + by_cases hx : x∈tsupport χ + · exact hχ.contDiffAt.mul (hY.contDiffAt (hD.mem_nhds (hχD hx))) + · apply (contDiffAt_const (c:=(0:ℝ))).congr_of_eventuallyEq + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + simp [hy] + · intro x hx + filter_upwards [hχ1.filter_mono (nhds_le_nhdsSet hx)] with y hy + simp [hy] + +lemma compact_green {F φ : Space d → ℝ} (hF : ContDiff ℝ ∞ F) + (hc : HasCompactSupport F) (hφ : Test univ φ) : + (∫x, inner ℝ (gradient F x) (gradient φ x)) = -(∫x, Δ F x*φ x) := by + have hi := (show Test univ F from ⟨hF,hc,subset_univ _⟩).h1.laplacian_ibp hφ + simp only [Measure.restrict_univ] at hi + have hs := SchwartzMap.integral_mul_laplacian_right_eq_left + (hc.toSchwartzMap hF) (hφ.2.1.toSchwartzMap hφ.1) (μ:=volume) + simp only [SchwartzMap.laplacian_apply] at hs + change (∫x, F x*Δ φ x)=(∫x, Δ F x*φ x) at hs + linarith + +lemma local_green (hD : IsOpen D) {Y φ : Space d → ℝ} + (hY : ContDiffOn ℝ ∞ Y D) (hφ : Test D φ) : + (∫x, inner ℝ (gradient Y x) (gradient φ x)) = -(∫x, Δ Y x*φ x) := by + obtain ⟨F,hF,hFc,hFY⟩ := compact_extension_near_test hD hY hφ + have hi := compact_green hF hFc (show Test univ φ from ⟨hφ.1,hφ.2.1,subset_univ _⟩) + convert! hi using 1 + · apply integral_congr_ae + exact ae_of_all _ fun x=>by + by_cases hx : x∈tsupport φ + · dsimp only + simp only [gradient,(hFY x hx).fderiv_eq] + · have hz : gradient φ x=0 := by rw [gradient,fderiv_of_notMem_tsupport ℝ hx,map_zero] + simp [hz] + · congr 1 + apply integral_congr_ae + exact ae_of_all _ fun x=>by + by_cases hx : x∈tsupport φ + · dsimp only + rw [(InnerProductSpace.laplacian_congr_nhds (hFY x hx)).eq_of_nhds] + · simp [image_eq_zero_of_notMem_tsupport hx] + +lemma local_green_integrable (hD : IsOpen D) {Y φ : Space d → ℝ} + (hY : ContDiffOn ℝ ∞ Y D) (hφ : Test D φ) : + Integrable (fun x=>inner ℝ (gradient Y x) (gradient φ x)) ∧ + Integrable (fun x=>Δ Y x*φ x) := by + obtain ⟨F,hF,hFc,hFY⟩ := compact_extension_near_test hD hY hφ + have hFtest : Test univ F := ⟨hF,hFc,subset_univ _⟩ + have hφtest : Test univ φ := ⟨hφ.1,hφ.2.1,subset_univ _⟩ + have hgrad := integrable_inner_of_memLp hFtest.memLp_gradient hφtest.memLp_gradient + simp only [Measure.restrict_univ] at hgrad + have hLap : Continuous (Δ F) := by + let S := hFc.toSchwartzMap hF + have he : (Laplacian.laplacian S : Space d → ℝ)=Δ F := funext fun x=>SchwartzMap.laplacian_apply S x + exact he ▸ (Laplacian.laplacian S).continuous + have hi : Integrable (fun x=>Δ F x*φ x) volume := + (hLap.mul hφ.1.continuous).integrable_of_hasCompactSupport hφ.2.1.mul_left + constructor + · apply hgrad.congr + exact ae_of_all _ fun x=>by + by_cases hx : x∈tsupport φ + · dsimp only + simp only [gradient,(hFY x hx).fderiv_eq] + · have hz : gradient φ x=0 := by rw [gradient,fderiv_of_notMem_tsupport ℝ hx,map_zero] + simp [hz] + · apply hi.congr + exact ae_of_all _ fun x=>by + by_cases hx : x∈tsupport φ + · dsimp only + rw [(InnerProductSpace.laplacian_congr_nhds (hFY x hx)).eq_of_nhds] + · simp [image_eq_zero_of_notMem_tsupport hx] + +open Halfspace + +lemma square_ratio_test (hD : IsOpen D) {Y φ : Space d → ℝ} + (hY : ContDiffOn ℝ ∞ Y D) (hYp : ∀x∈D, 0φ y^2/Y y) := by + filter_upwards [hy.continuousAt.preimage_mem_nhds (Ioi_mem_nhds hp)] with y hh + change 0 < Y y at hh + simp only [positiveSquareRatio,ite_eq_left hh] + exact ((hφ.1.contDiffAt.pow 2).div hy hp.ne').congr_of_eventuallyEq he + · apply (contDiffAt_const (c:=(0:ℝ))).congr_of_eventuallyEq + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + change φ y = 0 at hy + simp [positiveSquareRatio,hy] + +lemma picone_identity (hD : IsOpen D) {Y φ : Space d → ℝ} + (hY : ContDiffOn ℝ ∞ Y D) (hYp : ∀x∈D, 0gradient φ x-(φ x/Y x) • gradient Y x) 2 volume := by + have hc : Continuous (fun x=>(φ x/Y x) • gradient Y x) := by + rw [continuous_iff_continuousAt] + intro x + by_cases hx : x∈tsupport φ + · have hy := hY.contDiffAt (hD.mem_nhds (hφ.2.2 hx)) + exact (hφ.1.continuous.continuousAt.div hy.continuousAt (hYp x (hφ.2.2 hx)).ne').smul + ((InnerProductSpace.toDual ℝ (Space d)).symm.continuous.continuousAt.comp + (hy.continuousAt_fderiv (by simp))) + · apply (continuousAt_const (y:=(0:Space d))).congr_of_eventuallyEq + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + change φ y=0 at hy + simp [hy] + have hs : HasCompactSupport (fun x=>(φ x/Y x) • gradient Y x) := by + apply hφ.2.1.of_isClosed_subset (isClosed_tsupport _) + apply closure_mono + intro x hx + change (φ x/Y x) • gradient Y x ≠ 0 at hx + change φ x ≠ 0 + intro hz + exact hx (by simp [hz]) + have hφt : Test univ φ := ⟨hφ.1,hφ.2.1,subset_univ _⟩ + have hg := hφt.memLp_gradient + simp only [Measure.restrict_univ] at hg + exact hg.sub (hc.memLp_of_hasCompactSupport hs) + +lemma integral_norm_sq_eq {F : Type uF} [NormedAddCommGroup F] [InnerProductSpace ℝ F] + {μ : Measure (Space d)} {f : Space d → F} (hf : MemLp f 2 μ) : + (∫x, ‖f x‖^2 ∂μ)=‖hf.toLp f‖^2 := by + rw [← real_inner_self_eq_norm_sq,L2.inner_def] + apply integral_congr_ae + filter_upwards [hf.coeFn_toLp] with x hx + rw [hx,real_inner_self_eq_norm_sq] + +lemma picone_test_eLpNorm (hD : IsOpen D) {Y φ : Space d → ℝ} + (hY : ContDiffOn ℝ ∞ Y D) (hYp : ∀x∈D, 0gradient φ x-(φ x/Y x) • gradient Y x) 2 (volume.restrict D) ≤ + eLpNorm (gradient φ) 2 (volume.restrict D) := by + have hφt : Test univ φ := ⟨hφ.1,hφ.2.1,subset_univ _⟩ + have hg := hφt.memLp_gradient + simp only [Measure.restrict_univ] at hg + have hl := drift_test_memLp hD hY hYp hφ + have hi := picone_test hD hY hYp hLap hφ + rw [integral_norm_sq_eq hl,integral_norm_sq_eq hg] at hi + have hn : ‖hl.toLp _‖ ≤ ‖hg.toLp _‖ := (sq_le_sq₀ (norm_nonneg _) (norm_nonneg _)).mp hi + have hh : eLpNorm (fun x=>gradient φ x-(φ x/Y x) • gradient Y x) 2 volume ≤ + eLpNorm (gradient φ) 2 volume := by + rw [← Lp.enorm_toLp hl,← Lp.enorm_toLp hg,← ofReal_norm,← ofReal_norm] + exact ENNReal.ofReal_le_ofReal hn + have he : eLpNorm (gradient φ) 2 (volume.restrict D)=eLpNorm (gradient φ) 2 volume := by + rw [← eLpNorm_indicator_eq_eLpNorm_restrict hD.measurableSet] + congr 1 + ext x + by_cases hx : x∈D + · simp [hx] + · simp [hx,hφ.gradient_eq_zero_outside hx] + rw [he] + exact (eLpNorm_mono_measure _ Measure.restrict_le_self).trans hh + +/-- The full H¹₀ ground-state inequality. Fatou's lemma handles the singular +coefficient at the boundary or cone vertex; no bounded-drift or Hardy hypothesis +is imposed. -/ +theorem picone_h10_eLpNorm (hD : IsOpen D) {Y w : Space d → ℝ} {G : Space d → Space d} + (hY : ContDiffOn ℝ ∞ Y D) (hYp : ∀x∈D, 0G x-(w x/Y x) • gradient Y x) 2 (volume.restrict D) ∧ + eLpNorm (fun x=>G x-(w x/Y x) • gradient Y x) 2 (volume.restrict D) ≤ + eLpNorm G 2 (volume.restrict D) := by + obtain ⟨φ,hφ,hφw,hφG⟩ := SobolevCalculus.H10_sequence hw + have htψ := tendstoInMeasure_of_tendsto_eLpNorm (by norm_num : (2:ENNReal)≠0) + hφw + have htG := tendstoInMeasure_of_tendsto_eLpNorm (by norm_num : (2:ENNReal)≠0) + hφG + obtain ⟨a,ha,haw⟩ := htψ.exists_seq_tendsto_ae + obtain ⟨b,hb,hbG⟩ := (htG.comp ha.tendsto_atTop).exists_seq_tendsto_ae + let ψ := fun n=>φ (a (b n)) + have hψ : ∀n, Test D (ψ n) := fun n=>hφ (a (b n)) + let T := fun n x=>gradient (ψ n) x-(ψ n x/Y x) • gradient Y x + let L := fun x=>G x-(w x/Y x) • gradient Y x + have hT : ∀n, MemLp (T n) 2 (volume.restrict D) := fun n=> + (drift_test_memLp hD hY hYp (hψ n)).mono_measure Measure.restrict_le_self + have hTL : ∀ᵐ x ∂volume.restrict D, Tendsto (fun n=>T n x) atTop (𝓝 (L x)) := by + filter_upwards [haw,hbG] with x hx hy + exact hy.sub (((hx.comp hb.tendsto_atTop).div_const (Y x)).smul tendsto_const_nhds) + have hLm := aestronglyMeasurable_of_tendsto_ae _ + (fun n=>(hT n).aestronglyMeasurable) hTL + have hl := Lp.eLpNorm_lim_le_liminf_eLpNorm (p:=2) + (fun n=>(hT n).aestronglyMeasurable) L hLm hTL + have hGnorm : Tendsto (fun n=>eLpNorm (gradient (ψ n)) 2 (volume.restrict D)) atTop + (𝓝 (eLpNorm G 2 (volume.restrict D))) := by + have hLp : Tendsto (fun n=>(hφ n).memLp_gradient.toLp (gradient (φ n))) atTop + (𝓝 (hw.1.2.1.toLp G)) := by + apply tendsto_iff_enorm_sub_tendsto_zero.mpr + simpa only [← MemLp.toLp_sub,Lp.enorm_toLp] using hφG + have hh := hLp.enorm.comp (ha.tendsto_atTop.comp hb.tendsto_atTop) + simpa only [Lp.enorm_toLp,Function.comp_def,ψ] using hh + have hbound : eLpNorm L 2 (volume.restrict D) ≤ eLpNorm G 2 (volume.restrict D) := by + refine hl.trans ?_ + rw [← hGnorm.liminf_eq] + apply Filter.liminf_le_liminf + · exact Eventually.of_forall fun n=>picone_test_eLpNorm hD hY hYp hLap (hψ n) + all_goals isBoundedDefault + exact ⟨hbound.trans_lt hw.1.2.1,hbound⟩ + +theorem picone_h10 (hD : IsOpen D) {Y w : Space d → ℝ} {G : Space d → Space d} + (hY : ContDiffOn ℝ ∞ Y D) (hYp : ∀x∈D, 0 (hf n).memLp_gradient.toLp (gradient (f n))) + atTop (𝓝 (hv.1.2.1.toLp V)) := by + apply tendsto_iff_enorm_sub_tendsto_zero.mpr + simpa only [← MemLp.toLp_sub,Lp.enorm_toLp] using hfG + have hi : Tendsto (fun n => inner ℝ (hG.toLp G) + ((hf n).memLp_gradient.toLp (gradient (f n)))) atTop + (𝓝 (inner ℝ (hG.toLp G) (hv.1.2.1.toLp V))) := tendsto_const_nhds.inner hl + have he n : inner ℝ (hG.toLp G) ((hf n).memLp_gradient.toLp (gradient (f n)))=0 := by + rw [L2.inner_def] + convert! ht (f n) (hf n) using 1 + apply integral_congr_ae + filter_upwards [hG.coeFn_toLp,(hf n).memLp_gradient.coeFn_toLp] with x hx hy + rw [hx,hy] + simp only [he] at hi + have hz := tendsto_nhds_unique hi tendsto_const_nhds + rw [L2.inner_def] at hz + convert! hz using 1 + apply integral_congr_ae + filter_upwards [hG.coeFn_toLp,hv.1.2.1.coeFn_toLp] with x hx hy + rw [hx,hy] + +theorem harmonic_h10 (hD : IsOpen D) {u w : Space d → ℝ} {G : Space d → Space d} + (hu : ContDiffOn ℝ ∞ u D) (hLap : ∀x∈D, Δ u x=0) + (hG : MemLp (gradient u) 2 (volume.restrict D)) (hw : H10 D w G) : + (∫x in D, inner ℝ (gradient u x) (G x))=0 := by + apply orthogonal_h10_of_tests hG _ w G hw + intro φ hφ + rw [setIntegral_eq_integral_of_forall_compl_eq_zero + (fun x hx=>by rw [hφ.gradient_eq_zero_outside hx,inner_zero_right])] + rw [local_green hD hu hφ] + suffices hh : (fun x=>Δ u x*φ x)=(fun _=>0) by rw [hh,integral_zero,neg_zero] + ext x + by_cases hx:x∈D + · simp [hLap x hx] + · simp [hφ.eq_zero_outside hx] + +end GroundState +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspaceDensity.lean b/lean/OAI/Analysis/BernoulliCone/HalfspaceDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..9b89354a0b5580653704fa9ab9696bf1948d7df3 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspaceDensity.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BernoulliCone.HalfspacePullback + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology NNReal +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +def density (u : E → ℝ) (x : E) : ℝ := ‖gradient u x‖^2+if 0 < u x then 1 else 0 + +def firstTerm (φ : E → ℝ) (e : E) (x : E) : ℝ := + if 0 < inner ℝ e x then fderiv ℝ φ x e else 0 + +lemma density_nonneg (u : E → ℝ) (x : E) : 0 ≤ density u x := by + unfold density + split_ifs <;> positivity + +lemma gradient_norm_le_lipschitz {φ : E → ℝ} {C : ℝ≥0} + (hφ : LipschitzWith C φ) {x : E} (hd : DifferentiableAt ℝ φ x) : + ‖gradient φ x‖ ≤ C := by + rw [gradient,LinearIsometryEquiv.norm_map] + exact hd.hasFDerivAt.le_of_lipschitz hφ + +lemma density_pullback_bound {φ : E → ℝ} {C : ℝ≥0} {x : E} + (hφ : DifferentiableAt ℝ φ x) (hLip : LipschitzWith C φ) + (e : E) (t : ℝ) (h : (1:ℝ)/2 ≤ 1+t*fderiv ℝ φ x e) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) (hx : inner ℝ e x ≠ 0) : + (1+t*fderiv ℝ φ x e)*density (fun y => positiveLinear e (g.symm y)) (g x) ≤ + density (positiveLinear e) x + t*(1-‖e‖^2)*firstTerm φ e x + + t^2*(2*‖e‖^4*C^2) := by + have hpos : 0 < 1+t*fderiv ℝ φ x e := lt_of_lt_of_le (by norm_num) h + have hne := hpos.ne' + have hv : positiveLinear e (g.symm (g x)) = positiveLinear e x := by rw [g.symm_apply_apply] + rcases lt_or_gt_of_ne hx with hx|hx + · rw [density,pullback_gradient_neg hφ e t hne g hg hx,hv,density, + positiveLinear_gradient_neg e hx,firstTerm] + simp only [positiveLinear,max_eq_right hx.le,lt_self_iff_false,ite_false,norm_zero,zero_pow, + ne_eq,OfNat.ofNat_ne_zero,not_false_eq_true,zero_add,mul_zero,add_zero,not_lt.mpr hx.le] + positivity + · have hgNorm := gradient_norm_le_lipschitz hLip hφ + have hsq : ‖gradient φ x‖^2 ≤ (C:ℝ)^2 := by nlinarith [norm_nonneg (gradient φ x),C.coe_nonneg] + have hnum : 0 ≤ t^2*‖e‖^4 := mul_nonneg (sq_nonneg _) (pow_nonneg (norm_nonneg _) _) + have hn : 0 ≤ t^2*‖e‖^4*(C:ℝ)^2 := mul_nonneg hnum (sq_nonneg _) + have hr : t^2*‖e‖^4*‖gradient φ x‖^2/(1+t*fderiv ℝ φ x e) ≤ + t^2*(2*‖e‖^4*C^2) := by + apply (div_le_iff₀ hpos).mpr + have h1 := mul_le_mul_of_nonneg_left hsq hnum + have h2 : t^2*‖e‖^4*(C:ℝ)^2 ≤ (2*(t^2*‖e‖^4*(C:ℝ)^2))*(1+t*fderiv ℝ φ x e) := by + nlinarith + apply h1.trans + calc + _ ≤ (2*(t^2*‖e‖^4*(C:ℝ)^2))*(1+t*fderiv ℝ φ x e) := h2 + _ = _ := by ring + have hc := pullback_density_algebra e (gradient φ x) t (by simpa only [inner_gradient_right,conj_trivial] using hne) + simp only [inner_gradient_right,conj_trivial] at hc + rw [density,pullback_gradient_pos hφ e t hne g hg hx,hv,density, + positiveLinear_gradient_pos e hx,firstTerm,ite_eq_left hx] + simp only [positiveLinear,max_eq_left hx.le,ite_eq_left hx] + linarith +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspaceDifferential.lean b/lean/OAI/Analysis/BernoulliCone/HalfspaceDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd0d7e5b19450f0c6b34ce991f93f2096bc23bfe --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspaceDifferential.lean @@ -0,0 +1,93 @@ +import OAI.Analysis.BernoulliCone.HomogeneousCalculus + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Halfspace +open HarmonicKernel +variable {d : ℕ} + +lemma squareQuotient_hasFDerivAt {u : Space d → ℝ} {e x : Space d} + (hu : DifferentiableAt ℝ u x) (ht : 0 < inner ℝ x e) : + HasFDerivAt (squareQuotient u e) + ((inner ℝ x e)⁻¹ • ((2*u x) • fderiv ℝ u x)- + (u x^2/(inner ℝ x e)^2) • innerSL ℝ e) x := by + have hi : HasFDerivAt (fun y : Space d => inner ℝ y e) (innerSL ℝ e) x := by + convert! (innerSL ℝ e).hasFDerivAt (x:=x) using 1 + funext y + exact (real_inner_comm y e).symm + have hh := (hu.hasFDerivAt.pow 2).mul ((hasDerivAt_inv ht.ne').comp_hasFDerivAt x hi) + have he : (squareQuotient u e) =ᶠ[𝓝 x] (fun y=>u y^2/inner ℝ y e) := by + filter_upwards [(continuous_id.inner continuous_const).continuousAt.preimage_mem_nhds + (Ioi_mem_nhds ht)] with y hy + change 0 < inner ℝ y e at hy + simp only [squareQuotient,ite_eq_left hy] + simp only [Function.comp_apply] at hh + convert! hh.congr_of_eventuallyEq he using 1 + ext v + simp only [sub_apply,smul_apply,smul_eq_mul,innerSL_apply_apply,add_apply, + Nat.cast_ofNat,pow_one,Nat.reduceSub,nsmul_eq_mul] + field_simp + ring + +lemma potential_gradient (x : Space d) : + gradient (potential : Space d → ℝ) x = -rawKernel x • x := by + apply ext_inner_right ℝ + intro e + rw [inner_gradient_left,real_inner_smul_left] + have hh := radial_directional (contDiff_profile.differentiable (by simp)) x e + rw [show (fun y : Space d=>profile (‖y‖^2))=potential from rfl] at hh + rw [hh] + simp only [rawKernel,kernelProfile] + ring + +lemma potential_nonneg (x : Space d) : 0 ≤ potential x := expNegInvGlue.nonneg _ +lemma potential_pos {x : Space d} (hx : x∈ball (0:Space d) 1) : 0 < potential x := by + apply expNegInvGlue.pos_of_pos + rw [mem_ball_zero_iff] at hx + nlinarith [norm_nonneg x] + +lemma weightedQuotient_directional {u : Space d → ℝ} {e x : Space d} + (hu : DifferentiableAt ℝ u x) (ht : 0 < inner ℝ x e) (he : ‖e‖=1) : + inner ℝ (gradient (fun y=>potential y*squareQuotient u e y) x) e = + -rawKernel x*u x^2 + potential x*( + 2*(u x/inner ℝ x e)*inner ℝ (gradient u x) e-(u x/inner ℝ x e)^2) := by + have hφ := (contDiff_potential.differentiable (by simp) x).hasFDerivAt + have hq := squareQuotient_hasFDerivAt hu ht + have hp := hφ.mul hq + change HasFDerivAt (fun y=>potential y*squareQuotient u e y) _ x at hp + rw [inner_gradient_left,hp.fderiv] + simp only [add_apply,smul_apply,smul_eq_mul,sub_apply,innerSL_apply_apply] + simp only [← inner_gradient_left,potential_gradient,real_inner_smul_left, + real_inner_self_eq_norm_sq,he] + simp only [squareQuotient,ite_eq_left ht,one_pow,mul_one] + field_simp + ring + +lemma radial_outer_identity {u : Space d → ℝ} {L : ℝ≥0} + (hm : GlobalMinimizer u) (hL : LipschitzWith L u) + (hom : ∀r:ℝ, 0 f e) hh + simpa [a] using h + exact he ((inner_self_eq_zero).mp hx) + have hker : volume (LinearMap.ker a.toLinearMap : Set (Space d))=0 := by + apply Measure.addHaar_submodule + rw [Ne,LinearMap.ker_eq_top] + intro hh + exact ha (ContinuousLinearMap.coe_injective hh) + rw [ae_iff] + change volume {x | ¬ inner ℝ e x ≠ 0}=0 + change volume {x | inner ℝ e x=0}=0 at hker + simpa only [not_not] using hker + +lemma density_integrable_ball {u : Space d → ℝ} {C : ℝ≥0} (hu : LipschitzWith C u) + (a : Space d) (R : ℝ) : IntegrableOn (density u) (ball a R) := by + let : IsFiniteMeasure (volume.restrict (ball a R)) := + isFiniteMeasure_restrict.mpr (measure_ball_lt_top.ne) + have hh := LipschitzSobolev.h1_ball hu a R + exact (hh.2.1.integrable_norm_pow (by norm_num)).add (integrable_phase hh.1.aestronglyMeasurable) + +lemma firstTerm_integrable_ball {φ : Space d → ℝ} (hφ : ContDiff ℝ ∞ φ) + (e a : Space d) (R : ℝ) : IntegrableOn (firstTerm φ e) (ball a R) := by + have hc : Continuous (fun x => fderiv ℝ φ x e) := (hφ.continuous_fderiv (by simp)).clm_apply continuous_const + have hi : IntegrableOn (fun x => fderiv ℝ φ x e) (ball a R) volume := + (hc.continuousOn.integrableOn_compact (isCompact_closedBall a R)).mono_set ball_subset_closedBall + have hpos : MeasurableSet {x : Space d | 0 < inner ℝ e x} := + (isOpen_lt continuous_const (innerSL ℝ e).continuous).measurableSet + exact hi.indicator hpos + +lemma energy_pullback_upper {φ : Space d → ℝ} {C : ℝ≥0} + (hφ : ContDiff ℝ ∞ φ) (hLip : LipschitzWith C φ) + {e : Space d} (he : e ≠ 0) (t : ℝ) + (hdet : ∀ x, (1:ℝ)/2 ≤ 1+t*fderiv ℝ φ x e) + (g : Space d ≃ₜ Space d) (hg : ∀ y, g y=deform φ e t y) + (a : Space d) (R : ℝ) (hfix : ∀ x ∉ ball a R, φ x=0) : + energy (ball a R) (fun y => positiveLinear e (g.symm y)) + (gradient (fun y => positiveLinear e (g.symm y))) ≤ + energy (ball a R) (positiveLinear e) (gradient (positiveLinear e)) + + t*(1-‖e‖^2)*(∫ x in ball a R, firstTerm φ e x) + + t^2*(2*‖e‖^4*C^2)*(volume (ball a R)).toReal := by + let : IsFiniteMeasure (volume.restrict (ball a R)) := + isFiniteMeasure_restrict.mpr (measure_ball_lt_top.ne) + let v := fun y => positiveLinear e (g.symm y) + have him : g '' ball a R=ball a R := image_eq_of_fixed_compl g _ (by + intro x hx + rw [hg] + simp [deform,hfix x hx]) + have hchange := integral_image_eq_integral_abs_det_fderiv_smul (s:=ball a R) volume measurableSet_ball + (f:=g) (f':=fun x => rankOneMap (fderiv ℝ φ x) e t) + (fun x _ => (show HasFDerivAt g (rankOneMap (fderiv ℝ φ x) e t) x from by + rw [show (g : Space d → Space d)=deform φ e t from funext hg] + exact hasFDerivAt_deform ((hφ.differentiable (by simp)) x).hasFDerivAt e t).hasFDerivWithinAt) (g.injective.injOn) (density v) + rw [him] at hchange + have hdetpos (x : Space d) : 0 ≤ 1+t*fderiv ℝ φ x e := le_trans (by norm_num) (hdet x) + simp_rw [rankOneMap_det,abs_of_nonneg (hdetpos _),smul_eq_mul] at hchange + change energy (ball a R) v (gradient v) = _ at hchange + rw [hchange] + have hi : Integrable (fun x => density (positiveLinear e) x+t*(1-‖e‖^2)*firstTerm φ e x+ + t^2*(2*‖e‖^4*C^2)) (volume.restrict (ball a R)) := by + convert ((density_integrable_ball (positiveLinear_lipschitz e) a R).add + ((firstTerm_integrable_ball hφ e a R).const_mul (t*(1-‖e‖^2)))).add + (integrable_const (t^2*(2*‖e‖^4*C^2))) using 1; rfl + have hm := integral_mono_of_nonneg + (μ:=volume.restrict (ball a R)) + (f:=fun x => (1+t*fderiv ℝ φ x e)*density v (g x)) + (g:=fun x => density (positiveLinear e) x+t*(1-‖e‖^2)*firstTerm φ e x+ + t^2*(2*‖e‖^4*C^2)) + (Eventually.of_forall (fun x => mul_nonneg (hdetpos x) (density_nonneg v (g x)))) hi + (by + filter_upwards [ae_restrict_of_ae (inner_ne_zero_ae he)] with x hx + exact density_pullback_bound ((hφ.differentiable (by simp)) x) hLip e t (hdet x) g hg hx) + have hiE := density_integrable_ball (positiveLinear_lipschitz e) a R + have hiF := (firstTerm_integrable_ball hφ e a R).const_mul (t*(1-‖e‖^2)) + have hsum : (∫ x in ball a R, density (positiveLinear e) x+t*(1-‖e‖^2)*firstTerm φ e x+ + t^2*(2*‖e‖^4*C^2)) = + energy (ball a R) (positiveLinear e) (gradient (positiveLinear e)) + + t*(1-‖e‖^2)*(∫ x in ball a R, firstTerm φ e x) + + t^2*(2*‖e‖^4*C^2)*(volume (ball a R)).toReal := by + have hadd := integral_add (hiE.add hiF) (integrable_const (t^2*(2*‖e‖^4*C^2))) + have hadd2 := integral_add hiE hiF + simp only [Pi.add_apply] at hadd + rw [hadd2,integral_const_mul,integral_const] at hadd + convert hadd using 1; first | rfl | (simp only [Measure.restrict_apply_univ,Measure.real,smul_eq_mul]; dsimp [energy,density]; ring) + rw [hsum] at hm + exact hm +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspaceGroundstate.lean b/lean/OAI/Analysis/BernoulliCone/HalfspaceGroundstate.lean new file mode 100644 index 0000000000000000000000000000000000000000..22d2dc9231ab7480ee0f2c622d4f440f5820a738 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspaceGroundstate.lean @@ -0,0 +1,88 @@ +import OAI.Analysis.BernoulliCone.CompactGradient + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Halfspace +open HarmonicKernel +variable {d : ℕ} + +lemma radial_potential_test : Test (ball (0:Space d) 2) potential := by + have he : (potential : Space d → ℝ)=scaledPotential 1 0 := by + funext x; simp [potential,scaledPotential] + rw [he] + exact scaledPotential_test (by norm_num) 0 (closedBall_subset_ball (by norm_num)) + +lemma radial_outer_integrable {u : Space d → ℝ} {L : ℝ≥0} (hL : LipschitzWith L u) : + IntegrableOn (fun x=> potential x*‖gradient u x‖^2-rawKernel x*u x^2) (ball (0:Space d) 2) := by + have hu := LipschitzSobolev.h1_ball hL 0 2 + have hi := (memLp_two_iff_integrable_sq_norm hu.2.1.aestronglyMeasurable).mp hu.2.1 + obtain ⟨C,hC⟩ := (radial_potential_test (d:=d)).2.1.exists_bound_of_continuous contDiff_potential.continuous + have hi' := hi.bdd_mul contDiff_potential.continuous.aestronglyMeasurable (Eventually.of_forall hC) + have hq : Integrable (fun x=>rawKernel x*u x^2) volume := + (contDiff_rawKernel.continuous.mul (hL.continuous.pow 2)).integrable_of_hasCompactSupport rawKernel_compact.mul_right + exact hi'.sub hq.integrableOn + +/-- Ground-state equality for a true homogeneous minimizing cone supported in +one closed halfspace. This uses a Lipschitz perspective competitor, not a +regularity assumption or a boundary trace quotient. -/ +theorem gradient_parallel_of_halfspace_support {u : Space d → ℝ} {L : ℝ≥0} + (hm : GlobalMinimizer u) (hL : LipschitzWith L u) + (hom : ∀r:ℝ, 0potential x*squareQuotient u e x + have hφ : Test B potential := radial_potential_test + obtain ⟨K,hφL⟩ := ContDiff.lipschitzWith_of_hasCompactSupport hφ.2.1 hφ.1 (by simp) + obtain ⟨C,hq'⟩ := lipschitz_mul_compact (squareQuotient_lipschitz hL he hz) hφL hφ.2.1 + have hq : LipschitzWith C q := by + simpa only [q,mul_comm] using hq' + have hc : HasCompactSupport q := hφ.2.1.mul_right + have hs : tsupport q ⊆ B := tsupport_mul_subset_left.trans hφ.2.2 + have hq0 := setIntegral_gradient_compact hq hc hs e + have hu0 := SobolevCalculus.gradient_zero_on_zero_set isOpen_ball (LipschitzSobolev.h1_ball hL 0 2) + have hqz := SobolevCalculus.gradient_zero_on_zero_set isOpen_ball (LipschitzSobolev.h1_ball hq 0 2) + let F := fun x=>potential x*‖gradient u x‖^2-rawKernel x*u x^2 + let R := fun x=>potential x*‖gradient u x-(u x/inner ℝ x e) • e‖^2 + have hR : R =ᵐ[μ] (fun x=>F x-inner ℝ (gradient q x) e) := by + filter_upwards [ae_restrict_of_ae hL.ae_differentiableAt,hu0,hqz] with x hx hux hqx + by_cases ht : 0 < inner ℝ x e + · dsimp [R,F,q] + rw [weightedQuotient_directional hx ht he] + rw [← real_inner_self_eq_norm_sq] + simp only [inner_sub_left,inner_sub_right,real_inner_smul_left,real_inner_smul_right, + real_inner_self_eq_norm_sq, norm_smul, Real.norm_eq_abs, he, mul_one, sq_abs, real_inner_comm e (gradient u x)] + ring + · have hu : u x=0 := hz x (not_lt.mp ht) + have hqv : q x=0 := by simp [q,squareQuotient,ht] + simp only [R,F,hu,hux hu,hqx hqv,zero_div,zero_smul,sub_self,norm_zero,zero_pow (by norm_num : 2≠0), + mul_zero,inner_zero_left] + have hFi : Integrable F μ := radial_outer_integrable hL + have hQi : Integrable (fun x=>inner ℝ (gradient q x) e) μ := + (memLp_inner_const (LipschitzSobolev.h1_ball hq 0 2).2.1 e).integrable (by norm_num) + have hRi : Integrable R μ := (hFi.sub hQi).congr hR.symm + have hRint : (∫ x, R x ∂μ)=0 := by + rw [integral_congr_ae hR,integral_sub hFi hQi] + change (∫ x in B, F x)-(∫ x in B, inner ℝ (gradient q x) e)=0 + rw [radial_outer_identity hm hL hom,hq0,sub_self] + have haz : R =ᵐ[μ] 0 := (integral_eq_zero_iff_of_nonneg_ae + (Eventually.of_forall (fun x=>mul_nonneg (potential_nonneg x) (sq_nonneg _))) hRi).mp hRint + have hle : volume.restrict (ball (0:Space d) 1) ≤ μ := + Measure.restrict_mono (ball_subset_ball (by norm_num)) le_rfl + filter_upwards [ae_mono hle haz,ae_restrict_mem measurableSet_ball] with x hx hxb + have hsq : ‖gradient u x-(u x/inner ℝ x e) • e‖^2=0 := + (mul_eq_zero.mp hx).resolve_left (potential_pos hxb).ne' + exact sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp hsq)) +end Bernoulli.Halfspace + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspacePullback.lean b/lean/OAI/Analysis/BernoulliCone/HalfspacePullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..8117544507150e042270d81550619a09c3e1dd3d --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspacePullback.lean @@ -0,0 +1,90 @@ +import OAI.Analysis.BernoulliCone.ShapeDiffeomorphism + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +def positiveLinear (e : E) (x : E) : ℝ := max (inner ℝ e x) 0 + +omit [CompleteSpace E] in +lemma positiveLinear_lipschitz (e : E) : LipschitzWith ‖innerSL ℝ e‖₊ (positiveLinear e) := + (innerSL ℝ e).lipschitzWith.max_const 0 + +omit [CompleteSpace E] in +lemma positiveLinear_deriv_pos (e : E) {x : E} (hx : 0 < inner ℝ e x) : + HasFDerivAt (positiveLinear e) (innerSL ℝ e) x := by + have he : positiveLinear e =ᶠ[𝓝 x] (innerSL ℝ e) := by + filter_upwards [(isOpen_lt continuous_const (innerSL ℝ e).continuous).mem_nhds hx] with y hy + exact max_eq_left hy.le + exact (innerSL ℝ e).hasFDerivAt.congr_of_eventuallyEq he + +omit [CompleteSpace E] in +lemma positiveLinear_deriv_neg (e : E) {x : E} (hx : inner ℝ e x < 0) : + HasFDerivAt (positiveLinear e) (0 : E →L[ℝ] ℝ) x := by + have he : positiveLinear e =ᶠ[𝓝 x] (fun _ => (0:ℝ)) := by + filter_upwards [(isOpen_lt (innerSL ℝ e).continuous continuous_const).mem_nhds hx] with y hy + exact max_eq_right hy.le + exact (hasFDerivAt_const (𝕜:=ℝ) (0:ℝ) x).congr_of_eventuallyEq he + +lemma positiveLinear_gradient_pos (e : E) {x : E} (hx : 0 < inner ℝ e x) : + gradient (positiveLinear e) x=e := by + apply ext_inner_right ℝ + intro y + rw [inner_gradient_left,(positiveLinear_deriv_pos e hx).fderiv] + rfl + +lemma positiveLinear_gradient_neg (e : E) {x : E} (hx : inner ℝ e x < 0) : + gradient (positiveLinear e) x=0 := by + rw [gradient,(positiveLinear_deriv_neg e hx).fderiv,map_zero] + +lemma pullback_gradient_pos {φ : E → ℝ} {x : E} (hφ : DifferentiableAt ℝ φ x) + (e : E) (t : ℝ) (h : 1+t*fderiv ℝ φ x e ≠ 0) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) (hx : 0 < inner ℝ e x) : + gradient (fun y => positiveLinear e (g.symm y)) (g x) = + e - (t*‖e‖^2/(1+t*fderiv ℝ φ x e)) • gradient φ x := by + have hi := inverse_hasFDerivAt_deform hφ.hasFDerivAt e t h g hg + have ho : HasFDerivAt (positiveLinear e) (innerSL ℝ e) (g.symm (g x)) := by + simpa using positiveLinear_deriv_pos e hx + have hf := ho.comp (g x) hi + apply ext_inner_right ℝ + intro y + rw [inner_gradient_left] + change fderiv ℝ (positiveLinear e ∘ g.symm) (g x) y = _ + rw [hf.fderiv,dual_rankOneInverse] + simp only [sub_apply,smul_apply,smul_eq_mul, + innerSL_apply_apply,real_inner_self_eq_norm_sq,inner_sub_left,real_inner_smul_left, + inner_gradient_left] + +lemma pullback_gradient_neg {φ : E → ℝ} {x : E} (hφ : DifferentiableAt ℝ φ x) + (e : E) (t : ℝ) (h : 1+t*fderiv ℝ φ x e ≠ 0) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) (hx : inner ℝ e x < 0) : + gradient (fun y => positiveLinear e (g.symm y)) (g x) = 0 := by + have hi := inverse_hasFDerivAt_deform hφ.hasFDerivAt e t h g hg + have ho : HasFDerivAt (positiveLinear e) (0 : E →L[ℝ] ℝ) (g.symm (g x)) := by + simpa using positiveLinear_deriv_neg e hx + have hf := ho.comp (g x) hi + change gradient (positiveLinear e ∘ g.symm) (g x) = 0 + rw [gradient,hf.fderiv] + simp + +omit [CompleteSpace E] in +lemma pullback_density_algebra (e z : E) (t : ℝ) (h : 1+t*inner ℝ e z ≠ 0) : + (1+t*inner ℝ e z) * (‖e-(t*‖e‖^2/(1+t*inner ℝ e z)) • z‖^2+1) - + (‖e‖^2+1) = t*(1-‖e‖^2)*inner ℝ e z + + t^2*‖e‖^4*‖z‖^2/(1+t*inner ℝ e z) := by + rw [norm_sub_sq_real,real_inner_smul_right,norm_smul,mul_pow,Real.norm_eq_abs,sq_abs] + field_simp + ring +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspaceQuotient.lean b/lean/OAI/Analysis/BernoulliCone/HalfspaceQuotient.lean new file mode 100644 index 0000000000000000000000000000000000000000..60994ce054621a94db777676d8b8d4a782e590b3 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspaceQuotient.lean @@ -0,0 +1,107 @@ +import OAI.Analysis.BernoulliCone.LipschitzProduct + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Halfspace +variable {d : ℕ} + +/-- The perspective of the square, with its zero trace value. -/ +def squareQuotient (u : Space d → ℝ) (e : Space d) (x : Space d) : ℝ := + if 0 < inner ℝ x e then u x ^ 2 / inner ℝ x e else 0 + +lemma height_bound {u : Space d → ℝ} {L : ℝ≥0} (hL : LipschitzWith L u) + {e : Space d} (he : ‖e‖=1) (hz : ∀ x, inner ℝ x e ≤ 0 → u x=0) (x : Space d) : + |u x| ≤ (L:ℝ)*max (inner ℝ x e) 0 := by + by_cases ht : 0 ≤ inner ℝ x e + · let y := x-(inner ℝ x e) • e + have hy : inner ℝ y e=0 := by simp [y,inner_sub_left,real_inner_smul_left,he] + have hh := hL.norm_sub_le x y + rw [hz y hy.le, sub_zero, Real.norm_eq_abs] at hh + have hd : dist x y=inner ℝ x e := by + rw [dist_eq_norm] + simp only [y,sub_sub_cancel,norm_smul,Real.norm_eq_abs,abs_of_nonneg ht,he,mul_one] + rw [← dist_eq_norm,hd] at hh + simpa only [max_eq_left ht] using hh + · rw [hz x (le_of_not_ge ht),abs_zero,max_eq_right (le_of_not_ge ht),mul_zero] + +lemma perspective_estimate {a b t s C ρ : ℝ} (hC : 0 ≤ C) (hρ : 0 ≤ ρ) + (ht : 0 < t) (hs : 0 < s) (hst : s ≤ t) + (ha : |a| ≤ C*t) (hb : |b| ≤ C*s) + (hab : |a-b| ≤ C*ρ) (hts : t-s ≤ ρ) : + |a^2/t-b^2/s| ≤ 3*C^2*ρ := by + have hst0 : 0 ≤ t-s := sub_nonneg.mpr hst + have hsq : |a^2-b^2| ≤ 2*C*t*(C*ρ) := by + calc + _ = |a+b| * |a-b| := by rw [← abs_mul]; congr 1; ring + _ ≤ (|a|+|b|)*(C*ρ) := mul_le_mul (abs_add_le _ _) hab (abs_nonneg _) (by positivity) + _ ≤ (C*t+C*t)*(C*ρ) := by gcongr; exact hb.trans (mul_le_mul_of_nonneg_left hst hC) + _ = _ := by ring + have hb2 : b^2 ≤ C^2*s^2 := by + simpa only [sq_abs,mul_pow] using pow_le_pow_left₀ (abs_nonneg b) hb 2 + have hsecond : b^2*(t-s)/(t*s) ≤ C^2*ρ := by + apply (div_le_iff₀ (mul_pos ht hs)).mpr + have ha1 := mul_le_mul_of_nonneg_right hb2 hst0 + have ha2 := mul_le_mul_of_nonneg_left hts (mul_nonneg (sq_nonneg C) (sq_nonneg s)) + have ha3 : C^2*s^2*ρ ≤ C^2*ρ*(t*s) := by + have hh : s^2 ≤ t*s := by nlinarith + nlinarith [mul_le_mul_of_nonneg_left hh (mul_nonneg (sq_nonneg C) hρ)] + nlinarith + calc + _ = |(a^2-b^2)/t-b^2*(t-s)/(t*s)| := by congr 1; field_simp; ring + _ ≤ |(a^2-b^2)/t|+|b^2*(t-s)/(t*s)| := abs_sub _ _ + _ = |a^2-b^2|/t+b^2*(t-s)/(t*s) := by + rw [abs_div,abs_of_pos ht,abs_of_nonneg (div_nonneg (mul_nonneg (sq_nonneg _) hst0) (mul_pos ht hs).le)] + _ ≤ 2*C^2*ρ + C^2*ρ := by + apply add_le_add _ hsecond + apply (div_le_iff₀ ht).mpr + nlinarith [hsq] + _ = _ := by ring + +lemma squareQuotient_lipschitz {u : Space d → ℝ} {L : ℝ≥0} (hL : LipschitzWith L u) + {e : Space d} (he : ‖e‖=1) (hz : ∀ x, inner ℝ x e ≤ 0 → u x=0) : + LipschitzWith (3*L^2) (squareQuotient u e) := by + have ht (x y : Space d) : |inner ℝ x e-inner ℝ y e| ≤ dist x y := by + rw [← inner_sub_left] + exact (abs_real_inner_le_norm _ _).trans_eq (by rw [he,mul_one,dist_eq_norm]) + have hmain (x y : Space d) (hxy : inner ℝ y e ≤ inner ℝ x e) : + |squareQuotient u e x-squareQuotient u e y| ≤ (3*(L:ℝ)^2)*dist x y := by + by_cases hx : 0 < inner ℝ x e + · by_cases hy : 0 < inner ℝ y e + · simp only [squareQuotient,ite_eq_left hx,ite_eq_left hy] + apply perspective_estimate L.coe_nonneg dist_nonneg hx hy hxy + · simpa only [max_eq_left hx.le] using height_bound hL he hz x + · simpa only [max_eq_left hy.le] using height_bound hL he hz y + · simpa only [Real.norm_eq_abs,dist_eq_norm] using hL.norm_sub_le x y + · exact (le_abs_self _).trans (ht x y) + · simp only [squareQuotient,ite_eq_left hx,ite_eq_right hy,sub_zero, + abs_of_nonneg (div_nonneg (sq_nonneg _) hx.le)] + apply (div_le_iff₀ hx).mpr + have hb := height_bound hL he hz x + rw [max_eq_left hx.le] at hb + have hu2 : u x^2 ≤ (L:ℝ)^2*(inner ℝ x e)^2 := by + simpa only [sq_abs,mul_pow] using pow_le_pow_left₀ (abs_nonneg (u x)) hb 2 + have hh : inner ℝ x e ≤ dist x y := by + have hh := (le_abs_self (inner ℝ x e-inner ℝ y e)).trans (ht x y) + linarith [not_lt.mp hy] + have hh2 := mul_le_mul_of_nonneg_left hh (mul_nonneg (sq_nonneg (L:ℝ)) hx.le) + nlinarith [sq_nonneg (L:ℝ),dist_nonneg (x:=x) (y:=y)] + · have hy : ¬0 < inner ℝ y e := by linarith + simp only [squareQuotient,ite_eq_right hx,ite_eq_right hy,sub_self,abs_zero] + positivity + apply LipschitzWith.of_dist_le_mul + intro x y + rw [Real.dist_eq] + change _ ≤ (3*(L:ℝ)^2)*dist x y + obtain hh|hh := le_total (inner ℝ y e) (inner ℝ x e) + · exact hmain x y hh + · simpa only [abs_sub_comm,dist_comm] using hmain y x hh +end Bernoulli.Halfspace + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HalfspaceUnitSlope.lean b/lean/OAI/Analysis/BernoulliCone/HalfspaceUnitSlope.lean new file mode 100644 index 0000000000000000000000000000000000000000..de572978c82c590cfddebf42baeb450dcfdf3a29 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HalfspaceUnitSlope.lean @@ -0,0 +1,79 @@ +import OAI.Analysis.BernoulliCone.RadialShapeTest + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Shape +variable {d : ℕ} + +lemma small_parameter_bounds {φ : Space d → ℝ} {C : ℝ≥0} + (hφ : ContDiff ℝ ∞ φ) (hLip : LipschitzWith C φ) + (e : Space d) {t : ℝ} (ht : |t| < (4*((C:ℝ)*‖e‖+1))⁻¹) : + ‖t‖₊*C*‖e‖₊ < 1 ∧ ∀ x, (1:ℝ)/2 ≤ 1+t*fderiv ℝ φ x e := by + have hC : 0 ≤ (C:ℝ)*‖e‖ := mul_nonneg C.coe_nonneg (norm_nonneg _) + have hp : 0 < 4*((C:ℝ)*‖e‖+1) := by positivity + have hh : |t| *(4*((C:ℝ)*‖e‖+1)) < 1 := (lt_div_iff₀ hp).mp (by simpa only [one_div] using ht) + have hprod : |t| *(C:ℝ)*‖e‖ < (1:ℝ)/4 := by nlinarith [abs_nonneg t] + constructor + · change ‖t‖*(C:ℝ)*‖e‖ < 1 + rw [Real.norm_eq_abs] + linarith + · intro x + have hb := (fderiv ℝ φ x).le_opNorm e + have hn := ((hφ.differentiable (by simp)) x).hasFDerivAt.le_of_lipschitz hLip + have hb' : |fderiv ℝ φ x e| ≤ (C:ℝ)*‖e‖ := by + rw [← Real.norm_eq_abs] + exact hb.trans (mul_le_mul_of_nonneg_right hn (norm_nonneg _)) + have hh' : |t*fderiv ℝ φ x e| < (1:ℝ)/4 := by + rw [abs_mul] + exact lt_of_le_of_lt (mul_le_mul_of_nonneg_left hb' (abs_nonneg _)) (by simpa only [mul_assoc] using hprod) + have hneg := neg_abs_le (t*fderiv ℝ φ x e) + linarith + +/-- Domain comparisons for the *actual* Bernoulli energy force the unit slope +of a minimizing halfspace. No boundary condition is assumed. -/ +theorem positiveLinear_minimizer_unit {e : Space d} (he : e ≠ 0) + (hm : GlobalMinimizer (positiveLinear e)) : ‖e‖=1 := by + let φ : Space d → ℝ := HarmonicKernel.potential + have hφ : Test (ball (0:Space d) 2) φ := potential_test + obtain ⟨C,hLip⟩ := ContDiff.lipschitzWith_of_hasCompactSupport hφ.2.1 hφ.1 (by simp) + let I : ℝ := ∫ x in ball (0:Space d) 2, firstTerm φ e x + have hI : I ≠ 0 := firstTerm_potential_integral_ne_zero he + let B : ℝ := (2*‖e‖^4*(C:ℝ)^2)*(volume (ball (0:Space d) 2)).toReal + have hε : 0 < (4*((C:ℝ)*‖e‖+1))⁻¹ := by positivity + have hz : (1-‖e‖^2)*I/2 = 0 := by + apply linear_coefficient_eq_zero _ B hε + intro t ht + obtain ⟨hK,hdet⟩ := small_parameter_bounds hφ.1 hLip e ht + let hf := displacement_lipschitz hLip e t + let g : Space d ≃ₜ Space d := perturbationHomeomorph hf hK + have hg : ∀ x, g x=deform φ e t x := fun _ => rfl + let v := fun y => positiveLinear e (g.symm y) + have hvLip := (positiveLinear_lipschitz e).comp (perturbationHomeomorph_symm_lipschitz hf hK) + have hsup : tsupport (fun x => v x-positiveLinear e x) ⊆ tsupport φ := + pullback_diff_support (u:=positiveLinear e) e t g hg + have hc : HasCompactSupport (fun x => v x-positiveLinear e x) := + hφ.2.1.of_isClosed_subset (isClosed_tsupport _) hsup + have hcB := hsup.trans hφ.2.2 + have hcomp := hm.compare_lipschitz (positiveLinear_lipschitz e) hvLip 0 (by norm_num : 0 < (2:ℝ)) + (Eventually.of_forall (fun _ => le_max_right _ _)) hc hcB + have hupper := energy_pullback_upper hφ.1 hLip he t hdet g hg 0 2 (by + intro x hx + by_contra hh + exact hx (hφ.2.2 (subset_tsupport φ hh))) + change energy (ball (0:Space d) 2) v (gradient v) ≤ _ at hupper + have hboth := hcomp.trans hupper + dsimp [B,I] + nlinarith + have hz' : (1-‖e‖^2)*I=0 := (div_eq_zero_iff).mp hz |>.resolve_right (by norm_num) + have hn : 1-‖e‖^2=0 := (mul_eq_zero.mp hz').resolve_right hI + nlinarith [norm_nonneg e] +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HarmonicCaccioppoli.lean b/lean/OAI/Analysis/BernoulliCone/HarmonicCaccioppoli.lean new file mode 100644 index 0000000000000000000000000000000000000000..93e441a50a65262216854e221a006c33d9269dd1 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HarmonicCaccioppoli.lean @@ -0,0 +1,60 @@ +import OAI.Analysis.BernoulliCone.HarmonicReplacement + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +namespace HarmonicReplacement +variable {d : ℕ} {D : Set (Space d)} + +/-- Caccioppoli's inequality for the genuine weak harmonic replacement. +The only test inserted is a proved H¹₀ product; no smoothness of u is used. -/ +lemma caccioppoli {u : Space d → ℝ} {G : Space d → Space d} + (hD : IsOpen D) (hu : H1 D u G) + (ho : ∀ v V, H10 D v V → (∫ x in D, inner ℝ (G x) (V x)) = 0) + {η : Space d → ℝ} (hη : Test D η) : + (∫ x in D, ‖η x • G x‖^2) ≤ 4 * (∫ x in D, ‖u x • gradient η x‖^2) := by + let A : Space d → Space d := fun x => η x • G x + let B : Space d → Space d := fun x => u x • gradient η x + let V : Space d → Space d := fun x => + (η x * η x) • G x + u x • gradient (fun y => η y * η y) x + have hA : MemLp A 2 (volume.restrict D) := hη.memLp_top.smul hu.2.1 + have hB : MemLp B 2 (volume.restrict D) := hu.1.smul hη.memLp_gradient_top + have ht := SobolevDensity.h10_mul_test hu hD (hη.mul hη) + have hv : MemLp V 2 (volume.restrict D) := ht.1.2.1 + have hz : (∫ x in D, inner ℝ (G x) (V x)) = 0 := ho _ _ ht + have hi : Integrable (fun x => inner ℝ (G x) (V x)) (volume.restrict D) := + integrable_inner_of_memLp hu.2.1 hv + have hA2 := hA.integrable_norm_pow (by norm_num : (2 : ℕ) ≠ 0) + have hB2 := hB.integrable_norm_pow (by norm_num : (2 : ℕ) ≠ 0) + have hp (x : Space d) : ‖A x‖^2 ≤ + 2 * inner ℝ (G x) (V x) + 4 * ‖B x‖^2 := by + have he : inner ℝ (G x) (V x) = ‖A x‖^2 + 2 * inner ℝ (A x) (B x) := by + dsimp only [A,B,V] + rw [hη.gradient_mul hη] + simp only [inner_add_right,real_inner_smul_right,smul_add, + real_inner_smul_left,norm_smul,Real.norm_eq_abs,mul_pow,sq_abs, + real_inner_self_eq_norm_sq] + ring + have hs := norm_add_sq_real (A x) ((2:ℝ) • B x) + simp only [inner_smul_right,norm_smul,Real.norm_of_nonneg (by norm_num : (0:ℝ) ≤ 2)] at hs + rw [he] + nlinarith only [hs,sq_nonneg ‖A x + (2:ℝ) • B x‖] + have hh := integral_mono_ae hA2 ((hi.const_mul 2).add (hB2.const_mul 4)) + (ae_of_all _ hp) + simp only [Pi.add_apply] at hh + rw [integral_add (hi.const_mul 2) (hB2.const_mul 4),integral_const_mul, + integral_const_mul,hz,mul_zero,zero_add] at hh + exact hh + +end HarmonicReplacement +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HarmonicKernel.lean b/lean/OAI/Analysis/BernoulliCone/HarmonicKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..83b0e6aa5f436041b573c2f6c5ca3e20dbe910f2 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HarmonicKernel.lean @@ -0,0 +1,107 @@ +import OAI.Analysis.BernoulliCone.HarmonicRadial + +namespace OAI + +section + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff BigOperators +namespace Bernoulli.HarmonicKernel +variable {d : ℕ} + +def profile (t : ℝ) : ℝ := expNegInvGlue (1-t) +def kernelProfile (t : ℝ) : ℝ := -2 * deriv profile t +def potential (x : Space d) : ℝ := profile (‖x‖^2) +def rawKernel (x : Space d) : ℝ := kernelProfile (‖x‖^2) + +lemma contDiff_profile : ContDiff ℝ ∞ profile := + expNegInvGlue.contDiff.comp (contDiff_const.sub contDiff_id) + +lemma deriv_profile (t : ℝ) : deriv profile t = -((1-t)⁻¹)^2 * profile t := by + have hh := (expNegInvGlue.hasDerivAt_polynomial_eval_inv_mul (1 : Polynomial ℝ) (1-t)).comp t + ((hasDerivAt_id t).const_sub 1) + have hh' : HasDerivAt profile (-((1-t)⁻¹)^2 * profile t) t := by + convert! hh using 1 + · funext s + simp [profile] + · simp [profile] + exact hh'.deriv + +lemma kernelProfile_eq (t : ℝ) : + kernelProfile t = 2 * ((1-t)⁻¹)^2 * profile t := by + rw [kernelProfile,deriv_profile] + ring + +lemma contDiff_kernelProfile : ContDiff ℝ ∞ kernelProfile := + contDiff_const.mul (contDiff_infty_iff_deriv.mp contDiff_profile).2 + +lemma profile_zero {t : ℝ} (ht : 1 ≤ t) : profile t = 0 := + expNegInvGlue.zero_of_nonpos (sub_nonpos.mpr ht) + +lemma kernelProfile_zero {t : ℝ} (ht : 1 ≤ t) : kernelProfile t = 0 := by + rw [kernelProfile_eq,profile_zero ht,mul_zero] + +lemma kernelProfile_nonneg (t : ℝ) : 0 ≤ kernelProfile t := by + rw [kernelProfile_eq] + exact mul_nonneg (mul_nonneg (by norm_num) (sq_nonneg _)) (expNegInvGlue.nonneg _) + +lemma kernelProfile_pos {t : ℝ} (ht : t < 1) : 0 < kernelProfile t := by + rw [kernelProfile_eq] + exact mul_pos (mul_pos (by norm_num) (sq_pos_of_pos (inv_pos.mpr (sub_pos.mpr ht)))) + (expNegInvGlue.pos_of_pos (sub_pos.mpr ht)) + +lemma contDiff_rawKernel : ContDiff ℝ ∞ (rawKernel : Space d → ℝ) := + contDiff_kernelProfile.comp (contDiff_id.norm_sq ℝ) + +lemma contDiff_potential : ContDiff ℝ ∞ (potential : Space d → ℝ) := + contDiff_profile.comp (contDiff_id.norm_sq ℝ) + +lemma rawKernel_zero {x : Space d} (hx : x ∉ Metric.closedBall 0 1) : rawKernel x = 0 := by + apply kernelProfile_zero + have hh : 1 < ‖x‖ := by simpa only [Metric.mem_closedBall,dist_zero_right,not_le] using hx + nlinarith + +lemma rawKernel_compact : HasCompactSupport (rawKernel : Space d → ℝ) := + HasCompactSupport.intro (isCompact_closedBall 0 1) (fun _ hx => rawKernel_zero hx) + +lemma rawKernel_nonneg (x : Space d) : 0 ≤ rawKernel x := kernelProfile_nonneg _ + +lemma rawKernel_mass_pos : 0 < ∫ x : Space d, rawKernel x := by + apply contDiff_rawKernel.continuous.integral_pos_of_hasCompactSupport_nonneg_nonzero + rawKernel_compact rawKernel_nonneg + exact (kernelProfile_pos (by simp : ‖(0 : Space d)‖^2 < 1)).ne' + +/-- Compact radial potential centered at `a` with positive radius `r`. +Its scale derivative produces an averaging kernel by the radial Laplacian. -/ +def scaledPotential (r : ℝ) (a x : Space d) : ℝ := profile (‖x-a‖^2 / r^2) + +lemma contDiff_scaledPotential (r : ℝ) (a : Space d) : + ContDiff ℝ ∞ (scaledPotential r a) := + contDiff_profile.comp (((contDiff_id.sub contDiff_const).norm_sq ℝ).div_const (r^2)) + +lemma scaledPotential_zero {r : ℝ} (hr : 0 < r) (a : Space d) {x : Space d} + (hx : x ∉ Metric.closedBall a r) : scaledPotential r a x = 0 := by + apply profile_zero + have hh : r < ‖x-a‖ := by simpa only [Metric.mem_closedBall,dist_eq_norm,not_le] using hx + apply (le_div_iff₀ (sq_pos_of_pos hr)).mpr + nlinarith + +lemma scaledPotential_support {r : ℝ} (hr : 0 < r) (a : Space d) : + tsupport (scaledPotential r a) ⊆ Metric.closedBall a r := by + apply closure_minimal _ Metric.isClosed_closedBall + intro x hx + by_contra hh + exact hx (scaledPotential_zero hr a hh) + +lemma scaledPotential_test {D : Set (Space d)} {r : ℝ} (hr : 0 < r) (a : Space d) + (hB : Metric.closedBall a r ⊆ D) : Test D (scaledPotential r a) := by + exact ⟨contDiff_scaledPotential r a, + HasCompactSupport.intro (isCompact_closedBall a r) (fun _ hx => scaledPotential_zero hr a hx), + (scaledPotential_support hr a).trans hB⟩ +end Bernoulli.HarmonicKernel + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HarmonicRadial.lean b/lean/OAI/Analysis/BernoulliCone/HarmonicRadial.lean new file mode 100644 index 0000000000000000000000000000000000000000..aa55268fc3e3e7c7d852292d310751afa3803f46 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HarmonicRadial.lean @@ -0,0 +1,82 @@ +import OAI.Analysis.BernoulliCone.StationarityIntegrability + +namespace OAI + +section + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff BigOperators +namespace Bernoulli +open scoped _root_.Bernoulli +namespace HarmonicKernel +variable {d : ℕ} + +lemma radial_hasFDerivAt {f : ℝ → ℝ} (hf : Differentiable ℝ f) (x : Space d) : + HasFDerivAt (fun y : Space d => f (‖y‖^2)) + (deriv f (‖x‖^2) • (2 • innerSL ℝ x)) x := by + exact (hf (‖x‖^2)).hasDerivAt.comp_hasFDerivAt x + (hasStrictFDerivAt_norm_sq x).hasFDerivAt + +lemma radial_directional {f : ℝ → ℝ} (hf : Differentiable ℝ f) (x e : Space d) : + fderiv ℝ (fun y : Space d => f (‖y‖^2)) x e = + 2 * deriv f (‖x‖^2) * inner ℝ x e := by + rw [(radial_hasFDerivAt hf x).fderiv] + simp only [smul_apply,smul_eq_mul,innerSL_apply_apply] + ring + +lemma radial_second_directional {f : ℝ → ℝ} (hf : ContDiff ℝ ∞ f) + (x e : Space d) : + fderiv ℝ (fun y : Space d => + fderiv ℝ (fun z : Space d => f (‖z‖^2)) y e) x e = + 4 * deriv (deriv f) (‖x‖^2) * (inner ℝ x e)^2 + + 2 * deriv f (‖x‖^2) * ‖e‖^2 := by + have hd := hf.differentiable (by simp) + have hd' := (contDiff_infty_iff_deriv.mp hf).2.differentiable (by simp) + simp_rw [radial_directional hd] + have hi : HasFDerivAt (fun y : Space d => inner ℝ y e) (innerSL ℝ e) x := by + convert (innerSL ℝ e).hasFDerivAt (x := x) using 1 + ext y + simp only [innerSL_apply_apply,real_inner_comm] + have ht := ((radial_hasFDerivAt hd' x).const_mul 2).mul hi + change HasFDerivAt (fun y => 2 * deriv f (‖y‖^2) * inner ℝ y e) _ x at ht + rw [ht.fderiv] + simp only [add_apply,smul_apply,smul_eq_mul,innerSL_apply_apply, + real_inner_self_eq_norm_sq] + ring + +/-- The full Euclidean radial Laplacian; no polar-coordinate convention is +hidden in this formula. It is used to build compact harmonic averaging kernels. -/ +lemma radial_laplacian {f : ℝ → ℝ} (hf : ContDiff ℝ ∞ f) (x : Space d) : + Laplacian.laplacian (fun y : Space d => f (‖y‖^2)) x = + 4 * deriv (deriv f) (‖x‖^2) * ‖x‖^2 + 2 * d * deriv f (‖x‖^2) := by + let b := stdOrthonormalBasis ℝ (Space d) + have hq : ContDiff ℝ ∞ (fun y : Space d => f (‖y‖^2)) := + hf.comp (contDiff_id.norm_sq ℝ) + rw [InnerProductSpace.laplacian_eq_iteratedFDeriv_orthonormalBasis _ b] + have he (e : Space d) : + iteratedFDeriv ℝ 2 (fun y : Space d => f (‖y‖^2)) x ![e,e] = + 4 * deriv (deriv f) (‖x‖^2) * (inner ℝ x e)^2 + + 2 * deriv f (‖x‖^2) * ‖e‖^2 := by + rw [iteratedFDeriv_two_apply] + have hd := (hq.fderiv_right (m := ∞) (by simp)).differentiable (by simp) x + have hh := fderiv_clm_apply hd (differentiableAt_const e) + have ht := radial_second_directional hf x e + rw [hh] at ht + simpa using ht + simp_rw [he,b.norm_eq_one,one_pow,mul_one] + rw [Finset.sum_add_distrib,← Finset.mul_sum] + have hs : ∑ i, (inner ℝ x (b i))^2 = ‖x‖^2 := by + have hs' := b.sum_inner_mul_inner x x + simpa only [real_inner_comm x,sq,real_inner_self_eq_norm_sq] using hs' + rw [hs] + simp only [Finset.sum_const,Finset.card_univ,Fintype.card_fin, + finrank_euclideanSpace, nsmul_eq_mul] + ring +end HarmonicKernel +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HarmonicReplacement.lean b/lean/OAI/Analysis/BernoulliCone/HarmonicReplacement.lean new file mode 100644 index 0000000000000000000000000000000000000000..b681d746cc87ee825cd4819bc4ea8b62e44fb273 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HarmonicReplacement.lean @@ -0,0 +1,496 @@ +import OAI.Analysis.BernoulliCone.UpperLipschitzComparison + +namespace OAI + +universe uα uE + +section + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} {u v : Space d → ℝ} {G V : Space d → Space d} + +lemma energy_positivePart_le [IsFiniteMeasure (volume.restrict D)] + (hv : MemLp v 2 (volume.restrict D)) (hV : MemLp V 2 (volume.restrict D)) : + energy D (fun x => max (v x) 0) + (fun x => (if 0 < v x then (1 : ℝ) else 0) • V x) ≤ energy D v V := by + have hvm := lipschitzWith_positivePart.comp_memLp (by simp) hv + have hVm : MemLp (fun x => (if 0 < v x then (1 : ℝ) else 0) • V x) 2 (volume.restrict D) := + (step_memLp_top hv.aestronglyMeasurable).smul hV + apply integral_mono_ae + ((hVm.integrable_norm_pow (by norm_num)).add (integrable_phase hvm.aestronglyMeasurable)) + ((hV.integrable_norm_pow (by norm_num)).add (integrable_phase hv.aestronglyMeasurable)) + exact Filter.Eventually.of_forall fun x => by + dsimp only + by_cases hx : 0 < v x + · simp [hx] + · simp [hx] + +/-- Full comparison with arbitrary signed Sobolev competitors follows from +precisely the nonnegative-competitor convention of the paper. -/ +lemma compare_signed [IsFiniteMeasure (volume.restrict D)] (hD : IsOpen D) + (hu : H1 D u G) (hn : ∀ᵐ x ∂volume.restrict D, 0 ≤ u x) + (hmin : ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 D v V → (∀ᵐ x ∂volume.restrict D, 0 ≤ v x) → + H10 D (fun x => v x - u x) (fun x => V x - G x) → + energy D u G ≤ energy D v V) + (hv : H1 D v V) (hvu : H10 D (fun x => v x-u x) (fun x => V x-G x)) : + energy D u G ≤ energy D v V := by + exact (hmin _ _ (h1_positivePart hD hv) + (Filter.Eventually.of_forall fun x => le_max_right (v x) 0) + (h10_positivePart_trace hD hu hn hv hvu)).trans (energy_positivePart_le hv.1 hv.2.1) + +lemma energy_affine_le [IsFiniteMeasure (volume.restrict D)] + {φ : Space d → ℝ} {W : Space d → Space d} + (hu : MemLp u 2 (volume.restrict D)) (hφ : MemLp φ 2 (volume.restrict D)) + (hG : MemLp G 2 (volume.restrict D)) (hW : MemLp W 2 (volume.restrict D)) (t : ℝ) + (hphase : ∀ᵐ x ∂volume.restrict D, 0 < u x + t*φ x → 0 < u x) : + energy D (fun x => u x+t*φ x) (fun x => G x+t • W x) ≤ + energy D u G + 2*t*(∫ x in D, inner ℝ (G x) (W x)) + + t^2*(∫ x in D, ‖W x‖^2) := by + have hG2 := hG.integrable_norm_pow (by norm_num : (2 : ℕ) ≠ 0) + have hW2 := hW.integrable_norm_pow (by norm_num : (2 : ℕ) ≠ 0) + have hGW := integrable_inner_of_memLp hG hW + have hI := integrable_phase hu.aestronglyMeasurable + have hF := (hG.add (hW.const_smul t)).integrable_norm_pow (by norm_num : (2 : ℕ) ≠ 0) + have hJ := integrable_phase (hu.add (hφ.const_smul t)).aestronglyMeasurable + have hb : energy D (fun x => u x+t*φ x) (fun x => G x+t • W x) ≤ + ∫ x in D, ((‖G x‖^2 + (if 0 < u x then (1 : ℝ) else 0)) + + (2*t)*inner ℝ (G x) (W x)) + t^2*‖W x‖^2 := by + apply integral_mono_ae (hF.add hJ) + (((hG2.add hI).add (hGW.const_mul (2*t))).add (hW2.const_mul (t^2))) + filter_upwards [hphase] with x hx + simp only [Pi.add_apply, Pi.smul_apply, smul_eq_mul] + rw [norm_add_sq_real, real_inner_smul_right, norm_smul, mul_pow, Real.norm_eq_abs, sq_abs] + have hi : (if 0 < u x+t*φ x then (1 : ℝ) else 0) ≤ if 0 < u x then 1 else 0 := by + split_ifs with h1 h2 h3 <;> norm_num at * + linarith [hx h1] + linarith + convert! hb using 1 + unfold energy + have hs := integral_add ((hG2.add hI).add (hGW.const_mul (2*t))) (hW2.const_mul (t^2)) + have hs' := integral_add (hG2.add hI) (hGW.const_mul (2*t)) + simp only [Pi.add_apply] at hs hs' + rw [hs, hs', integral_const_mul, integral_const_mul] + +lemma linear_coefficient_nonpositive (A B : ℝ) + (hq : ∀ t : ℝ, 0 < t → 0 ≤ -2*t*A+t^2*B) : A ≤ 0 := by + by_contra hn + have hA : 0 < A := lt_of_not_ge hn + let t := A/(|B|+1) + have ht : 0 < t := div_pos hA (by positivity) + have hid : t*(|B|+1)= A := div_mul_cancel₀ A (by positivity) + have hb : t*B < A := by + have hl := mul_le_mul_of_nonneg_left (le_abs_self B) ht.le + nlinarith + have hc := mul_lt_mul_of_pos_left hb ht + have hh := hq t ht + nlinarith [mul_pos ht hA] + +/-- Distributional subharmonicity follows without any continuity or +pointwise positivity assumption on the unknown minimizer. -/ +lemma subharmonic_of_comparison [IsFiniteMeasure (volume.restrict D)] (hD : IsOpen D) + (hu : H1 D u G) (hn : ∀ᵐ x ∂volume.restrict D, 0 ≤ u x) + (hmin : ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 D v V → (∀ᵐ x ∂volume.restrict D, 0 ≤ v x) → + H10 D (fun x => v x - u x) (fun x => V x - G x) → + energy D u G ≤ energy D v V) + {φ : Space d → ℝ} (hφ : Test D φ) + (hφn : ∀ᵐ x ∂volume.restrict D, 0 ≤ φ x) : + (∫ x in D, inner ℝ (G x) (gradient φ x)) ≤ 0 := by + apply linear_coefficient_nonpositive _ (∫ x in D, ‖gradient φ x‖^2) + intro t ht + have hv := hu.add (hφ.h1.const_smul (-t)) + have hvu : H10 D (fun x => (u x + -t*φ x)-u x) + (fun x => (G x + -t • gradient φ x)-G x) := by + simpa only [add_sub_cancel_left] using hφ.h10_const_mul (-t) + have hc := compare_signed hD hu hn hmin hv hvu + have he := energy_affine_le hu.1 hφ.memLp hu.2.1 hφ.memLp_gradient (-t) (by + filter_upwards [hφn] with x hx hp + have := mul_nonneg ht.le hx + linarith) + have hh := hc.trans he + nlinarith + +end Bernoulli.SobolevCalculus + +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} + +lemma LocalMinimizer.subharmonic {u : Space d → ℝ} (hu : LocalMinimizer D u) : + ∃ G : Space d → Space d, H1Loc D u G ∧ + ∀ (c : Space d) (r : ℝ), 0 < r → Metric.closedBall c r ⊆ D → + ∀ φ : Space d → ℝ, Test (Metric.ball c r) φ → + (∀ᵐ x ∂volume.restrict (Metric.ball c r), 0 ≤ φ x) → + (∫ x in Metric.ball c r, inner ℝ (G x) (gradient φ x)) ≤ 0 := by + obtain ⟨hD, G, hG, hn, hmin⟩ := hu + refine ⟨G, hG, fun c r hr hB φ hφ hφn => ?_⟩ + let : IsFiniteMeasure (volume.restrict (Metric.ball c r)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + exact SobolevCalculus.subharmonic_of_comparison Metric.isOpen_ball (hG c r hr hB) + (ae_restrict_of_ae_restrict_of_subset (Metric.ball_subset_closedBall.trans hB) hn) + (hmin c r hr hB) hφ hφn + +lemma LocalMinimizer.compare_signed {u : Space d → ℝ} (hu : LocalMinimizer D u) : + ∃ G : Space d → Space d, H1Loc D u G ∧ + ∀ (c : Space d) (r : ℝ), 0 < r → Metric.closedBall c r ⊆ D → + ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 (Metric.ball c r) v V → + H10 (Metric.ball c r) (fun x => v x-u x) (fun x => V x-G x) → + energy (Metric.ball c r) u G ≤ energy (Metric.ball c r) v V := by + obtain ⟨hD, G, hG, hn, hmin⟩ := hu + refine ⟨G, hG, fun c r hr hB v V hv hvu => ?_⟩ + let : IsFiniteMeasure (volume.restrict (Metric.ball c r)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + exact SobolevCalculus.compare_signed Metric.isOpen_ball (hG c r hr hB) + (ae_restrict_of_ae_restrict_of_subset (Metric.ball_subset_closedBall.trans hB) hn) + (hmin c r hr hB) hv hvu + +end Bernoulli + +noncomputable section +open MeasureTheory Set Filter +open scoped NNReal ENNReal Topology ContDiff +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} + +lemma gradient_norm_eq (f : Space d → ℝ) (x : Space d) : + ‖gradient f x‖ = ‖fderiv ℝ f x‖ := by + exact (InnerProductSpace.toDual ℝ (Space d)).symm.norm_map _ + +lemma test_gradient_norm {f : Space d → ℝ} (hf : Test D f) (p : ℝ≥0∞) : + eLpNorm (gradient f) p (volume.restrict D) = eLpNorm (fderiv ℝ f) p volume := by + have hdf := (hf.1.continuous_fderiv (by simp)).aestronglyMeasurable (μ := volume) + rw [eLpNorm_congr_norm_ae hf.memLp_gradient.aestronglyMeasurable hdf.restrict + (Filter.Eventually.of_forall (gradient_norm_eq f))] + exact eLpNorm_restrict_eq_of_support_subset hdf ((support_fderiv_subset ℝ).trans hf.2.2) + +lemma test_poincare (hd : 2 ≤ d) (hD : Bornology.IsBounded D) : + ∃ C : ℝ≥0, ∀ f : Space d → ℝ, Test D f → + eLpNorm f 2 (volume.restrict D) ≤ C * eLpNorm (gradient f) 2 (volume.restrict D) := by + by_cases hd2 : d = 2 + · subst d + let A := eLpNormLESNormFDerivOfLeConst ℝ (volume : Measure (Space 2)) D 1 2 + let B : ℝ≥0 := (volume D).toNNReal ^ ((1 : ℝ) / 2) + refine ⟨A * B, fun f hf => ?_⟩ + have hn := eLpNorm_le_eLpNorm_fderiv_of_le (volume : Measure (Space 2)) + (hf.1.of_le (by simp) : ContDiff ℝ 1 f) ((subset_tsupport f).trans hf.2.2) + (p := 1) (q := 2) (by norm_num) (by simp) (by norm_num) hD + have hm := eLpNorm_le_eLpNorm_mul_rpow_measure_univ + (μ := volume.restrict D) (p := 1) (q := 2) (f := gradient f) (by norm_num) + hf.memLp_gradient.aestronglyMeasurable + have hB : (volume.restrict D) univ ^ ((1 : ℝ) / (1 : ℝ≥0∞).toReal - + 1 / (2 : ℝ≥0∞).toReal) = (B : ℝ≥0∞) := by + dsimp [B] + rw [ENNReal.coe_rpow_of_nonneg _ (by positivity)] + norm_num [ENNReal.coe_toNNReal hD.measure_lt_top.ne] + rw [hB] at hm + calc + eLpNorm f 2 (volume.restrict D) = eLpNorm f 2 volume := + eLpNorm_restrict_eq_of_support_subset hf.1.continuous.aestronglyMeasurable + ((subset_tsupport f).trans hf.2.2) + _ ≤ A * eLpNorm (fderiv ℝ f) 1 volume := hn + _ = A * eLpNorm (gradient f) 1 (volume.restrict D) := by rw [test_gradient_norm hf] + _ ≤ A * (eLpNorm (gradient f) 2 (volume.restrict D) * B) := by gcongr + _ = (A * B : ℝ≥0) * eLpNorm (gradient f) 2 (volume.restrict D) := by + rw [ENNReal.coe_mul]; ring + · refine ⟨eLpNormLESNormFDerivOfLeConst ℝ (volume : Measure (Space d)) D 2 2, + fun f hf => ?_⟩ + have hn := eLpNorm_le_eLpNorm_fderiv (volume : Measure (Space d)) + (hf.1.of_le (by simp) : ContDiff ℝ 1 f) ((subset_tsupport f).trans hf.2.2) + (p := 2) (by norm_num) (by simpa using (show (2 : ℕ) < d by omega)) hD + rw [test_gradient_norm hf, + eLpNorm_restrict_eq_of_support_subset hf.1.continuous.aestronglyMeasurable + ((subset_tsupport f).trans hf.2.2)] + exact hn + +section LpContinuity +variable {α : Type uα} {E : Type uE} [MeasurableSpace α] {μ : Measure α} [NormedAddCommGroup E] + +lemma tendsto_eLpNorm_of_strong {f : ℕ → α → E} {u : α → E} + (hf : ∀ n, MemLp (f n) 2 μ) (hu : MemLp u 2 μ) + (ht : Tendsto (fun n => eLpNorm (f n - u) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (f n) 2 μ) atTop (𝓝 (eLpNorm u 2 μ)) := by + have hLp : Tendsto (fun n => (hf n).toLp (f n)) atTop (𝓝 (hu.toLp u)) := by + apply tendsto_iff_enorm_sub_tendsto_zero.mpr + simpa only [← MemLp.toLp_sub, Lp.enorm_toLp] using ht + simpa only [Function.comp_def, Lp.enorm_toLp] using (continuous_enorm.tendsto _).comp hLp +end LpContinuity + +/-- The Poincare inequality holds for arbitrary H1_0 competitors, not just +smooth or pointwise regular functions. -/ +lemma h10_poincare (hd : 2 ≤ d) (hD : Bornology.IsBounded D) : + ∃ C : ℝ≥0, ∀ (u : Space d → ℝ) (G : Space d → Space d), H10 D u G → + eLpNorm u 2 (volume.restrict D) ≤ C * eLpNorm G 2 (volume.restrict D) := by + obtain ⟨C, hC⟩ := test_poincare hd hD + refine ⟨C, fun u G hu => ?_⟩ + obtain ⟨f, hf, hfu, hfG⟩ := H10_sequence hu + have h1 := tendsto_eLpNorm_of_strong (fun n => (hf n).memLp) hu.1.1 hfu + have h2 := tendsto_eLpNorm_of_strong (fun n => (hf n).memLp_gradient) hu.1.2.1 hfG + exact le_of_tendsto_of_tendsto h1 + (ENNReal.Tendsto.const_mul h2 (Or.inr ENNReal.coe_ne_top)) + (Filter.Eventually.of_forall (fun n => hC (f n) (hf n))) +end Bernoulli.SobolevCalculus + +noncomputable section +open MeasureTheory Set Filter +open scoped NNReal ENNReal Topology ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} + +lemma Test.zero : Test D (fun _ => (0 : ℝ)) := by + exact ⟨contDiff_const, HasCompactSupport.zero, by simp⟩ + +lemma Test.add {f g : Space d → ℝ} (hf : Test D f) (hg : Test D g) : + Test D (f + g) := by + exact ⟨hf.1.add hg.1, hf.2.1.add hg.2.1, + (tsupport_add f g).trans (union_subset hf.2.2 hg.2.2)⟩ + +lemma Test.gradient_add {f g : Space d → ℝ} (hf : Test D f) (hg : Test D g) : + gradient (f + g) = gradient f + gradient g := by + funext x + apply ext_inner_right ℝ + intro h + simp only [Pi.add_apply, inner_add_left, inner_gradient_left, + fderiv_add (hf.1.differentiable (by simp) x) (hg.1.differentiable (by simp) x), + add_apply] + +lemma Test.sub {f g : Space d → ℝ} (hf : Test D f) (hg : Test D g) : + Test D (f - g) := by + convert hf.add (hg.const_mul (-1)) using 1 + ext x + simp [sub_eq_add_neg] + +lemma Test.gradient_sub {f g : Space d → ℝ} (hf : Test D f) (hg : Test D g) : + gradient (f - g) = gradient f - gradient g := by + funext x + apply ext_inner_right ℝ + intro h + simp only [Pi.sub_apply, inner_sub_left, inner_gradient_left, + fderiv_sub (hf.1.differentiable (by simp) x) (hg.1.differentiable (by simp) x), + sub_apply] + +lemma H10.const_smul {u : Space d → ℝ} {G : Space d → Space d} + (hu : H10 D u G) (t : ℝ) : + H10 D (fun x => t * u x) (fun x => t • G x) := by + obtain ⟨f, hf, hfu, hfG⟩ := SobolevCalculus.H10_sequence hu + refine SobolevCalculus.h10_of_strong (hu.1.const_smul t).1 (hu.1.const_smul t).2.1 + (fun n => (hf n).h10_const_mul t) ?_ ?_ + · have heq (n : ℕ) : (fun x => t * f n x) - (fun x => t * u x) = t • (f n - u) := by + ext x + simp only [Pi.sub_apply, Pi.smul_apply, smul_eq_mul, mul_sub] + simp_rw [heq, eLpNorm_const_smul] + simpa only [mul_zero] using + (ENNReal.Tendsto.const_mul hfu (a := ‖t‖ₑ) (Or.inr (by simp))) + · have heq (n : ℕ) : (fun x => t • gradient (f n) x) - (fun x => t • G x) = + t • (gradient (f n) - G) := by + ext x + simp only [Pi.sub_apply, Pi.smul_apply, smul_sub] + simp_rw [heq, eLpNorm_const_smul] + simpa only [mul_zero] using + (ENNReal.Tendsto.const_mul hfG (a := ‖t‖ₑ) (Or.inr (by simp))) + +lemma H10.neg {u : Space d → ℝ} {G : Space d → Space d} (hu : H10 D u G) : + H10 D (fun x => -u x) (fun x => -G x) := by + simpa using hu.const_smul (-1) + +namespace HarmonicReplacement + +abbrev VectorLp (D : Set (Space d)) := Lp (Space d) 2 (volume.restrict D) +abbrev ScalarLp (D : Set (Space d)) := Lp ℝ 2 (volume.restrict D) + +/-- Actual gradients of compactly supported smooth tests, in L2. -/ +def testGradients (D : Set (Space d)) : Submodule ℝ (VectorLp D) where + carrier := {F | ∃ (f : Space d → ℝ) (hf : Test D f), + F = hf.memLp_gradient.toLp (gradient f)} + zero_mem' := by + refine ⟨fun _ => 0, Test.zero, ?_⟩ + simp [show gradient (fun _ : Space d => (0 : ℝ)) = 0 by funext x; exact gradient_const x 0] + add_mem' := by + rintro F V ⟨f, hf, rfl⟩ ⟨g, hg, rfl⟩ + refine ⟨f + g, hf.add hg, ?_⟩ + simp only [hf.gradient_add hg] + convert! (MemLp.toLp_add hf.memLp_gradient hg.memLp_gradient).symm + smul_mem' := by + rintro t F ⟨f, hf, rfl⟩ + refine ⟨fun x => t * f x, hf.const_mul t, ?_⟩ + apply Lp.ext + filter_upwards [Lp.coeFn_smul t (hf.memLp_gradient.toLp (gradient f)), + hf.memLp_gradient.coeFn_toLp, (hf.const_mul t).memLp_gradient.coeFn_toLp] with x h1 h2 h3 + simp only [Pi.smul_apply] at h1 + rw [h1, h2, h3, congrFun (hf.gradient_const_mul t) x] + +/-- Closed gradient space used for Dirichlet harmonic replacement. -/ +def zeroGradients (D : Set (Space d)) : Submodule ℝ (VectorLp D) := + (testGradients D).topologicalClosure + +lemma h10_mem_zeroGradients {u : Space d → ℝ} {G : Space d → Space d} + (hu : H10 D u G) : hu.1.2.1.toLp G ∈ zeroGradients D := by + obtain ⟨f, hf, hfu, hfG⟩ := SobolevCalculus.H10_sequence hu + have hlim : Tendsto (fun n => (hf n).memLp_gradient.toLp (gradient (f n))) + atTop (𝓝 (hu.1.2.1.toLp G)) := by + apply tendsto_iff_enorm_sub_tendsto_zero.mpr + simpa only [← MemLp.toLp_sub, Lp.enorm_toLp] using hfG + exact (testGradients D).isClosed_topologicalClosure.mem_of_tendsto hlim + (Filter.Eventually.of_forall fun n => subset_closure ⟨f n, hf n, rfl⟩) + +lemma test_poincare_norm (hd : 2 ≤ d) (hD : Bornology.IsBounded D) : + ∃ C : ℝ≥0, ∀ (f : Space d → ℝ) (hf : Test D f), + ‖hf.memLp.toLp f‖ ≤ C * ‖hf.memLp_gradient.toLp (gradient f)‖ := by + obtain ⟨C, hC⟩ := SobolevCalculus.test_poincare hd hD + refine ⟨C, fun f hf => ?_⟩ + have hn := ENNReal.toReal_mono (ENNReal.mul_ne_top ENNReal.coe_ne_top hf.memLp_gradient.ne) + (hC f hf) + simpa only [Lp.norm_toLp, ENNReal.toReal_mul, ENNReal.coe_toReal] using hn + +lemma zeroGradients_h10 (hd : 2 ≤ d) (hD : Bornology.IsBounded D) + {F : VectorLp D} (hF : F ∈ zeroGradients D) : + ∃ u : ScalarLp D, H10 D u F := by + obtain ⟨C, hC⟩ := test_poincare_norm hd hD + obtain ⟨A, hA, ht⟩ := mem_closure_iff_seq_limit.mp hF + choose f hf heq using hA + let U : ℕ → ScalarLp D := fun n => (hf n).memLp.toLp (f n) + let V : ℕ → VectorLp D := fun n => (hf n).memLp_gradient.toLp (gradient (f n)) + have htV : Tendsto V atTop (𝓝 F) := by + have heq' : A = V := by funext n; exact heq n + rwa [heq'] at ht + have hdist (m n : ℕ) : dist (U m) (U n) ≤ C * dist (V m) (V n) := by + dsimp [U, V] + rw [dist_eq_norm, dist_eq_norm, ← MemLp.toLp_sub, ← MemLp.toLp_sub] + have hc := hC (f m - f n) ((hf m).sub (hf n)) + simpa only [(hf m).gradient_sub (hf n)] using hc + have hUc : CauchySeq U := by + apply Metric.cauchySeq_iff.mpr + intro ε hε + obtain ⟨N, hN⟩ := Metric.cauchySeq_iff.mp htV.cauchySeq (ε / (C + 1)) (by positivity) + refine ⟨N, fun m hm n hn => (hdist m n).trans_lt ?_⟩ + calc (C : ℝ) * dist (V m) (V n) + ≤ (C + 1) * dist (V m) (V n) := by gcongr; linarith + _ < (C + 1) * (ε / (C + 1)) := + mul_lt_mul_of_pos_left (hN m hm n hn) (by positivity) + _ = ε := by field_simp + obtain ⟨u, hu⟩ := cauchySeq_tendsto_of_complete hUc + refine ⟨u, SobolevCalculus.h10_of_strong (Lp.memLp u) (Lp.memLp F) (fun n => (hf n).h10) ?_ ?_⟩ + · have hu' : Tendsto U atTop (𝓝 ((Lp.memLp u).toLp u)) := by + simpa only [Lp.toLp_coeFn] using hu + have h := tendsto_iff_enorm_sub_tendsto_zero.mp hu' + simpa only [U, ← MemLp.toLp_sub, Lp.enorm_toLp] using h + · have hF' : Tendsto V atTop (𝓝 ((Lp.memLp F).toLp F)) := by + simpa only [Lp.toLp_coeFn] using htV + have h := tendsto_iff_enorm_sub_tendsto_zero.mp hF' + simpa only [V, ← MemLp.toLp_sub, Lp.enorm_toLp] using h + +theorem exists_replacement (hd : 2 ≤ d) (hD : Bornology.IsBounded D) + {u : Space d → ℝ} {G : Space d → Space d} (hu : H1 D u G) : + ∃ (h : Space d → ℝ) (H : Space d → Space d), H1 D h H ∧ + H10 D (h - u) (H - G) ∧ + ∀ (v : Space d → ℝ) (V : Space d → Space d), H10 D v V → + (∫ x in D, inner ℝ (H x) (V x)) = 0 := by + let K := zeroGradients D + let : CompleteSpace K := (testGradients D).isClosed_topologicalClosure.completeSpace_coe + let W : VectorLp D := K.starProjection (hu.2.1.toLp G) + obtain ⟨w, hw⟩ := zeroGradients_h10 hd hD (K.starProjection_apply_mem (hu.2.1.toLp G)) + refine ⟨u - w, G - W, hu.sub hw.1, ?_, ?_⟩ + · convert hw.neg using 1 <;> ext x <;> simp only [Pi.sub_apply, W] <;> abel_nf + · intro v V hv + have ho := K.starProjection_inner_eq_zero (hu.2.1.toLp G) (hv.1.2.1.toLp V) + (h10_mem_zeroGradients hv) + rw [L2.inner_def] at ho + calc + (∫ x in D, inner ℝ ((G - W) x) (V x)) = + ∫ x in D, inner ℝ ((hu.2.1.toLp G - W) x) (hv.1.2.1.toLp V x) := by + apply integral_congr_ae + filter_upwards [Lp.coeFn_sub (hu.2.1.toLp G) W, hu.2.1.coeFn_toLp, + hv.1.2.1.coeFn_toLp] with x hs hG hV + simp only [Pi.sub_apply] at hs ⊢ + rw [hs, hG, hV] + _ = 0 := ho + +lemma orthogonal_energy_identity {G H : Space d → Space d} + (hG : MemLp G 2 (volume.restrict D)) (hH : MemLp H 2 (volume.restrict D)) + (ho : (∫ x in D, inner ℝ (H x) ((G - H) x)) = 0) : + (∫ x in D, ‖(G - H) x‖^2) = + (∫ x in D, ‖G x‖^2) - (∫ x in D, ‖H x‖^2) := by + have hH2 := hH.integrable_norm_pow (by norm_num) + have hW2 := (hG.sub hH).integrable_norm_pow (by norm_num) + have hHW := integrable_inner_of_memLp hH (hG.sub hH) + have heq : (∫ x in D, ‖G x‖^2) = + ∫ x in D, (‖H x‖^2 + ‖(G - H) x‖^2) + 2 * inner ℝ (H x) ((G - H) x) := by + apply integral_congr_ae + exact Filter.Eventually.of_forall fun x => by + have hn := norm_add_sq_real (H x) ((G - H) x) + simp only [Pi.sub_apply, add_sub_cancel] at hn + dsimp only [Pi.sub_apply] + linarith only [hn] + have hadd := integral_add (hH2.add hW2) (hHW.const_mul 2) + have hadd' := integral_add hH2 hW2 + simp only [Pi.add_apply] at hadd hadd' + rw [hadd, hadd', integral_const_mul, ho, mul_zero, add_zero] at heq + linarith + +/-- The Bernoulli term is retained in the harmonic-replacement estimate. -/ +lemma replacement_energy_estimate [IsFiniteMeasure (volume.restrict D)] + {u h : Space d → ℝ} {G H : Space d → Space d} + (hu : H1 D u G) (hh : H1 D h H) + (ht : H10 D (h-u) (H-G)) + (ho : ∀ v V, H10 D v V → (∫ x in D, inner ℝ (H x) (V x)) = 0) + (hmin : energy D u G ≤ energy D h H) : + (∫ x in D, ‖(G-H) x‖^2) + + (∫ x in D, if 0 < u x then (1 : ℝ) else 0) ≤ (volume D).toReal := by + have hn : H10 D (u-h) (G-H) := by + convert ht.neg using 1 <;> ext x <;> simp only [Pi.sub_apply] <;> abel_nf + have hid := orthogonal_energy_identity hu.2.1 hh.2.1 (ho _ _ hn) + have he (f : Space d → ℝ) (F : Space d → Space d) (hf : H1 D f F) : + energy D f F = (∫ x in D, ‖F x‖^2) + + (∫ x in D, if 0 < f x then (1 : ℝ) else 0) := by + unfold energy + exact integral_add (hf.2.1.integrable_norm_pow (by norm_num)) + (integrable_phase hf.1.aestronglyMeasurable) + have hp : (∫ x in D, if 0 < h x then (1 : ℝ) else 0) ≤ (volume D).toReal := by + calc + _ ≤ ∫ _x in D, (1 : ℝ) := integral_mono_ae + (integrable_phase hh.1.aestronglyMeasurable) (integrable_const 1) + (Filter.Eventually.of_forall fun x => by dsimp only; split_ifs <;> norm_num) + _ = _ := by simp [Measure.real] + rw [he u G hu, he h H hh] at hmin + linarith + +end HarmonicReplacement + +/-- Actual Bernoulli minimizers admit harmonic replacements with the full +volume-term estimate, without a regularity assumption on the minimizer. -/ +lemma LocalMinimizer.harmonic_replacement (hd : 2 ≤ d) + {u : Space d → ℝ} (hu : LocalMinimizer D u) : + ∃ G : Space d → Space d, H1Loc D u G ∧ + ∀ (c : Space d) (r : ℝ), 0 < r → Metric.closedBall c r ⊆ D → + ∃ (h : Space d → ℝ) (H : Space d → Space d), + H1 (Metric.ball c r) h H ∧ H10 (Metric.ball c r) (h-u) (H-G) ∧ + (∀ v V, H10 (Metric.ball c r) v V → + (∫ x in Metric.ball c r, inner ℝ (H x) (V x)) = 0) ∧ + (∫ x in Metric.ball c r, ‖(G-H) x‖^2) + + (∫ x in Metric.ball c r, if 0 < u x then (1 : ℝ) else 0) ≤ + (volume (Metric.ball c r)).toReal := by + obtain ⟨G, hG, hc⟩ := hu.compare_signed + refine ⟨G, hG, fun c r hr hB => ?_⟩ + let : IsFiniteMeasure (volume.restrict (Metric.ball c r)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + obtain ⟨h, H, hh, ht, ho⟩ := HarmonicReplacement.exists_replacement hd + Metric.isBounded_ball (hG c r hr hB) + exact ⟨h, H, hh, ht, ho, HarmonicReplacement.replacement_energy_estimate + (hG c r hr hB) hh ht ho (hc c r hr hB h H hh ht)⟩ + +end Bernoulli + +end +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HarmonicWeakLaplacian.lean b/lean/OAI/Analysis/BernoulliCone/HarmonicWeakLaplacian.lean new file mode 100644 index 0000000000000000000000000000000000000000..8decf335aa8c0f5e81caeef8dcc6a12a46ac918c --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HarmonicWeakLaplacian.lean @@ -0,0 +1,67 @@ +import OAI.Analysis.BernoulliCone.HarmonicCaccioppoli + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff BigOperators +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} +namespace Test +lemma directional {φ : Space d → ℝ} (hφ : Test D φ) (e : Space d) : + Test D (fun x => fderiv ℝ φ x e) := by + refine ⟨(hφ.1.fderiv_right (by simp)).clm_apply contDiff_const, + hφ.2.1.fderiv_apply ℝ e, (tsupport_fderiv_apply_subset ℝ e).trans hφ.2.2⟩ +end Test + +/-- Distributional integration by parts against the Euclidean Laplacian; +no second derivatives of the Sobolev function occur in this statement. -/ +lemma H1.laplacian_ibp {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) {φ : Space d → ℝ} (hφ : Test D φ) : + (∫ x in D, u x * Laplacian.laplacian φ x) = + -(∫ x in D, inner ℝ (G x) (gradient φ x)) := by + let b := stdOrthonormalBasis ℝ (Space d) + have hi (i : Fin (Module.finrank ℝ (Space d))) := + hu.2.2 _ (hφ.directional (b i)) (b i) + have hs (x : Space d) : Laplacian.laplacian φ x = + ∑ i, fderiv ℝ (fun y => fderiv ℝ φ y (b i)) x (b i) := by + rw [InnerProductSpace.laplacian_eq_iteratedFDeriv_orthonormalBasis φ b] + apply Finset.sum_congr rfl + intro i _ + rw [iteratedFDeriv_two_apply] + -- evaluation of a continuously differentiable map into continuous linear maps + have hd := (hφ.1.fderiv_right (m := ∞) (by simp)).differentiable (by simp) x + rw [fderiv_clm_apply hd (differentiableAt_const (b i))] + simp + simp_rw [hs,Finset.mul_sum] + rw [integral_finsetSum _ (fun i _ => + integrable_deriv_product hu.1 (hφ.directional (b i)) (b i))] + simp_rw [hi] + rw [Finset.sum_neg_distrib,← integral_finsetSum _ (fun i _ => + integrable_inner_test hu.2.1 (hφ.directional (b i)) (b i))] + congr 1 + apply integral_congr_ae + exact ae_of_all _ fun x => by + calc + _ = ∑ i, inner ℝ (G x) (b i) * inner ℝ (b i) (gradient φ x) := by + apply Finset.sum_congr rfl + intro i _ + rw [real_inner_comm (gradient φ x) (b i),inner_gradient_left] + _ = _ := b.sum_inner_mul_inner (G x) (gradient φ x) + +namespace HarmonicReplacement +lemma weak_laplacian_zero {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) + (ho : ∀ v V, H10 D v V → (∫ x in D, inner ℝ (G x) (V x)) = 0) + {φ : Space d → ℝ} (hφ : Test D φ) : + (∫ x in D, u x * Laplacian.laplacian φ x) = 0 := by + rw [hu.laplacian_ibp hφ,ho _ _ hφ.h10,neg_zero] +end HarmonicReplacement +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/HomogeneousCalculus.lean b/lean/OAI/Analysis/BernoulliCone/HomogeneousCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..61d2c0e22139f797676362033b29108c9dc2ff12 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/HomogeneousCalculus.lean @@ -0,0 +1,60 @@ +import OAI.Analysis.BernoulliCone.PositiveQuotient + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff +namespace Bernoulli.ConeCalculus +variable {E : Type uE} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma euler_identity {f : E → ℝ} {x : E} (hf : DifferentiableAt ℝ f x) + (hom : ∀ r : ℝ, 0 < r → ∀ y, f (r • y) = r*f y) : + fderiv ℝ f x x = f x := by + have hc : HasDerivAt (fun r : ℝ => f (r • x)) (fderiv ℝ f x x) 1 := by + have hf1 : HasFDerivAt f (fderiv ℝ f x) ((fun r : ℝ => r • x) 1) := by simpa using hf.hasFDerivAt + convert! hf1.comp_hasDerivAt 1 ((hasDerivAt_id (1:ℝ)).smul_const x) using 1 + simp + have he : (fun r : ℝ => f (r • x)) =ᶠ[𝓝 1] (fun r => r*f x) := by + filter_upwards [eventually_gt_nhds (by norm_num : (0:ℝ)<1)] with r hr + exact hom r hr x + apply hc.unique + simpa using (((hasDerivAt_id (1:ℝ)).mul_const (f x)).congr_of_eventuallyEq he) + +/-- Euler's homogeneous identity differentiated on the actual open smooth +phase. No Hessian or angular equation is assumed. -/ +lemma hessian_radial {f : E → ℝ} {O : Set E} (hO : IsOpen O) + (hf : ContDiffOn ℝ ∞ f O) + (hom : ∀ r : ℝ, 0 < r → ∀ y, f (r • y) = r*f y) + {x : E} (hx : x∈O) (v : E) : + fderiv ℝ (fderiv ℝ f) x v x = 0 := by + have hs := hf.contDiffAt (hO.mem_nhds hx) + have hd := hs.differentiableAt (by simp) + have hD : DifferentiableAt ℝ (fderiv ℝ f) x := + (hs.fderiv_right (m:=1) (by change (↑(2 : ℕ∞) : WithTop ℕ∞) ≤ ↑(⊤ : ℕ∞); exact WithTop.coe_le_coe.mpr le_top)).differentiableAt (by simp) + have he : (fun y => fderiv ℝ f y y) =ᶠ[𝓝 x] f := by + filter_upwards [hO.mem_nhds hx] with y hy + exact euler_identity ((hf.contDiffAt (hO.mem_nhds hy)).differentiableAt (by simp)) hom + have hh := (hD.hasFDerivAt.clm_apply (hasFDerivAt_id x)).congr_of_eventuallyEq he.symm + have heq := congrArg (fun A : E →L[ℝ] ℝ => A v) (hh.unique hd.hasFDerivAt) + simp only [add_apply,ContinuousLinearMap.coe_comp, + Function.comp_apply,ContinuousLinearMap.id_apply,ContinuousLinearMap.flip_apply,id_eq] at heq + linarith + +variable {d : ℕ} + +lemma laplacian_trace (f : EuclideanSpace ℝ (Fin d) → ℝ) (x : EuclideanSpace ℝ (Fin d)) : + Laplacian.laplacian f x = ∑ i, fderiv ℝ (fderiv ℝ f) x + (EuclideanSpace.basisFun (Fin d) ℝ i) (EuclideanSpace.basisFun (Fin d) ℝ i) := by + rw [InnerProductSpace.laplacian_eq_iteratedFDeriv_orthonormalBasis f + (EuclideanSpace.basisFun (Fin d) ℝ)] + simp [iteratedFDeriv_two_apply] +end Bernoulli.ConeCalculus + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/IntegralUpperLimit.lean b/lean/OAI/Analysis/BernoulliCone/IntegralUpperLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ce399ccbe0abbd8e7658ee460fa86f8a9cb5f0c --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/IntegralUpperLimit.lean @@ -0,0 +1,59 @@ +import OAI.Analysis.BernoulliCone.IntegratedPrimitive + +namespace OAI + +universe uα + +section +noncomputable section +open MeasureTheory Filter +open scoped Topology +namespace Bernoulli +open scoped _root_.Bernoulli + +theorem integral_nonneg_of_dominated_upper_limit {α : Type uα} [MeasurableSpace α] + {μ:Measure α} {R:ℕ→α→ℝ} {D C:α→ℝ} + (hR:∀n,Integrable (R n) μ) (hD:Integrable D μ) (hC:Integrable C μ) + (hbound:∀n,∀ᵐ x ∂μ,‖R n x‖≤C x) + (hpos:∀n,0≤∫x,R n x ∂μ) + (hlim:∀ᵐ x ∂μ,∀η:ℝ,0<η → ∀ᶠ n in atTop,R n xmax (R n x-D x) 0 + have hEn n:∫x,E n x ∂μ≥0:=integral_nonneg (fun x=>le_max_right _ _) + have hEb n:∀ᵐ x ∂μ,‖E n x‖≤C x+‖D x‖:=by + filter_upwards [hbound n] with x hx + rw [Real.norm_eq_abs,abs_of_nonneg (le_max_right _ _)] + apply max_le + · calc + R n x-D x ≤ ‖R n x-D x‖ := le_abs_self _ + _ ≤ ‖R n x‖+‖D x‖ := norm_sub_le _ _ + _ ≤ C x+‖D x‖ := add_le_add hx le_rfl + · exact add_nonneg ((norm_nonneg _).trans hx) (norm_nonneg _) + have hEi n:Integrable (E n) μ:= + (hC.add hD.norm).mono' (((hR n).aestronglyMeasurable.aemeasurable.sub hD.aestronglyMeasurable.aemeasurable).max aemeasurable_const).aestronglyMeasurable (hEb n) + have hEc:∀ᵐ x ∂μ,Tendsto (fun n=>E n x) atTop (𝓝 0):=by + filter_upwards [hlim] with x hx + apply tendsto_order.2 + constructor + · intro a ha + exact Eventually.of_forall fun n=>ha.trans_le (le_max_right _ _) + · intro b hb + exact (hx b hb).mono fun n hn=>max_lt (by linarith) hb + have ht:Tendsto (fun n=>∫x,E n x ∂μ) atTop (𝓝 0):=by + simpa using tendsto_integral_of_dominated_convergence (C+fun x=>‖D x‖) + (fun n=>(hEi n).aestronglyMeasurable) (hC.add hD.norm) hEb hEc + have hi n:0≤(∫x,D x ∂μ)+(∫x,E n x ∂μ):=by + rw [←integral_add hD (hEi n)] + refine (hpos n).trans (integral_mono_ae (hR n) (hD.add (hEi n)) ?_) + filter_upwards [] with x + have hh:=le_max_left (R n x-D x) 0 + change R n x≤D x+max (R n x-D x) 0 + linarith + have h:=ge_of_tendsto (tendsto_const_nhds.add ht) (Eventually.of_forall hi) + simpa using h +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/IntegratedPrimitive.lean b/lean/OAI/Analysis/BernoulliCone/IntegratedPrimitive.lean new file mode 100644 index 0000000000000000000000000000000000000000..6056f3de7165362624caba45404e51f35a5c45e9 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/IntegratedPrimitive.lean @@ -0,0 +1,139 @@ +import OAI.Analysis.BernoulliCone.TraceBound + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison +open Foliation + +def shiftU (ε:ℝ) (x:Space 7):ℝ:=U x+ε +def ceilingGraph (ε:ℝ) (v:Space 7→ℝ) (x:Space 7):ℝ:=max (shiftU ε x) (v x) +def comparisonR (ε:ℝ) (v:Space 7→ℝ) (x:Space 7):ℝ:= + if U x+εv y-U y)) : ceilingGraph ε v x=shiftU ε x := by + have hv:v x=U x:=sub_eq_zero.mp (image_eq_zero_of_notMem_tsupport (f:=fun y=>v y-U y) hx) + exact max_eq_left (by dsimp [shiftU]; rw [hv]; linarith) +lemma ceiling_sub_compact {v:Space 7→ℝ} {ε:ℝ} (hε:0≤ε) + (hc:HasCompactSupport (fun y=>v y-U y)) : + HasCompactSupport (fun x=>ceilingGraph ε v x-shiftU ε x) := by + apply HasCompactSupport.intro hc + intro x hx + rw [ceiling_eq_shift_outside hε hx,sub_self] +lemma comparison_primitive_support {v:Space 7→ℝ} {ε:ℝ} (hε:0≤ε) : + tsupport (verticalPotential upperFlux (shiftU ε) (ceilingGraph ε v))⊆tsupport (fun y=>v y-U y) := by + apply closure_minimal _ (isClosed_tsupport _) + intro x hx + by_contra hn + have he:=ceiling_eq_shift_outside hε hn + exact hx (by simp [verticalPotential,he]) +lemma comparison_primitive_compact {v:Space 7→ℝ} {ε:ℝ} (hε:0≤ε) + (hc:HasCompactSupport (fun y=>v y-U y)) : + HasCompactSupport (verticalPotential upperFlux (shiftU ε) (ceilingGraph ε v)) := + hc.of_isClosed_subset (isClosed_tsupport _) (comparison_primitive_support hε) + +lemma shiftU_gradient {ε:ℝ} {x:Space 7} (hx:DifferentiableAt ℝ U x) : + gradient (shiftU ε) x=gradient U x := by + have hd:HasFDerivAt (shiftU ε) (fderiv ℝ U x) x:=hx.hasFDerivAt.add_const ε + unfold gradient + rw [hd.fderiv] +lemma ceilingGraph_gradient {ε:ℝ} {v:Space 7→ℝ} {x:Space 7} + (hv:ContinuousAt v x) (hlt:U x+εv y-U y)) : + ∀ᵐ x:Space 7 ∂volume, + divergence (verticalPotential upperFlux (shiftU ε) (ceilingGraph ε v)) x≤comparisonR ε v x := by + obtain ⟨K,hK⟩:=exists_lipschitz_U + have ha:=shiftU_lipschitz hK ε + have hb:=ceilingGraph_lipschitz hK hv ε + obtain ⟨M,hM⟩:=clamped_seam_lipschitz ha hb (fun x=>by dsimp [shiftU]; linarith) + (ceiling_sub_compact hε.le hc) + filter_upwards [radiusSq_pos_ae,hK.ae_differentiableAt,ha.ae_differentiableAt, + hb.ae_differentiableAt,hM.ae_differentiableAt] with x hqx hdu hda hdb hdw + have h:=upperFlux_primitive_bound ha.continuous.continuousAt hb.continuous.continuousAt + (fun y=>le_max_left _ _) (by dsimp [shiftU]; linarith) hqx hda hdb hdw + rw [shiftU_gradient hdu] at h + by_cases hlt:U x+εupperFlux (x,U x+ε)):= + upperFlux_measurable.comp (measurable_id.prodMk (U_continuous.measurable.add_const ε)) + exact ((LipschitzSobolev.measurable_gradient.norm.pow_const 2 |>.add (hA.norm.pow_const 2)).sub + ((hA.inner LipschitzSobolev.measurable_gradient).const_mul 2)).ite + (measurableSet_lt (U_continuous.measurable.add_const ε) hv) measurable_const + +lemma comparisonR_bound {v:Space 7→ℝ} {K L:ℝ≥0} (hK:LipschitzWith K U) + (hL:LipschitzWith L v) {C:ℝ} (hC:0≤C) (hA:∀p:Space 7×ℝ,‖upperFlux p‖≤C) (ε:ℝ) (x:Space 7): + ‖comparisonR ε v x‖≤(L:ℝ)^2+C^2+2*C*K := by + unfold comparisonR + split_ifs + · have h1:‖gradient v x‖^2≤(L:ℝ)^2:=sq_le_sq₀ (norm_nonneg _) L.2 |>.mpr (LipschitzSobolev.norm_gradient_le hL x) + have h2:‖upperFlux (x,U x+ε)‖^2≤C^2:=sq_le_sq₀ (norm_nonneg _) hC |>.mpr (hA _) + have h3:‖inner ℝ (upperFlux (x,U x+ε)) (gradient U x)‖≤C*K:= + (norm_inner_le_norm _ _).trans (mul_le_mul (hA _) (LipschitzSobolev.norm_gradient_le hK x) (norm_nonneg _) hC) + calc + _ ≤ ‖(‖gradient v x‖^2+‖upperFlux (x,U x+ε)‖^2)‖+‖2*inner ℝ (upperFlux (x,U x+ε)) (gradient U x)‖:=norm_sub_le _ _ + _ ≤ (L:ℝ)^2+C^2+2*C*K:=by + rw [Real.norm_eq_abs,abs_of_nonneg (add_nonneg (sq_nonneg _) (sq_nonneg _)),norm_mul] + norm_num only [Real.norm_ofNat] + nlinarith + · simp only [norm_zero]; positivity + +/-- The genuine compact graph primitive yields an integrated comparison at +positive height. Hypotheses concern a competitor, never desired minimality. -/ +theorem comparisonR_integral_nonneg {v:Space 7→ℝ} {L:ℝ≥0} (hv:LipschitzWith L v) + {ε:ℝ} (hε:0<ε) (hc:HasCompactSupport (fun y=>v y-U y)) + {c:Space 7} {r:ℝ} (hS:tsupport (fun y=>v y-U y)⊆Metric.ball c r) : + 0≤∫x in Metric.ball c r,comparisonR ε v x := by + let P:=verticalPotential upperFlux (shiftU ε) (ceilingGraph ε v) + obtain ⟨K,hK⟩:=exists_lipschitz_U + have hPc:HasCompactSupport P:=comparison_primitive_compact hε.le hc + have hPl:LocallyLipschitz P:=upperFlux_primitive_locallyLipschitz + (shiftU_lipschitz hK ε).locallyLipschitz (ceilingGraph_lipschitz hK hv ε).locallyLipschitz + (fun x=>le_max_left _ _) (fun x=>by dsimp [shiftU]; linarith) + obtain ⟨M,hM⟩:=locallyLipschitz_compact_lipschitz hPl hPc + obtain ⟨C,hC,hA⟩:=upperFlux_uniform_bound + have hR:IntegrableOn (comparisonR ε v) (Metric.ball c r):= + (integrableOn_const (μ:=volume) (C:=(L:ℝ)^2+C^2+2*C*K) (measure_ball_lt_top.ne)).mono' + (comparisonR_measurable hv.continuous.measurable ε).aestronglyMeasurable.restrict + (Eventually.of_forall (comparisonR_bound hK hv hC.le hA ε)) + have hz:(∫x in Metric.ball c r,divergence P x)=0:=by + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx=> + divergence_zero_outside_support (fun hp=>hx (hS (comparison_primitive_support hε.le hp))))] + exact integral_divergence_compact hM hPc + rw [←hz] + exact integral_mono_ae (integrable_divergence_compact hM hPc).integrableOn hR + ((comparisonR_ae_bound hv hε hc).filter_mono (ae_mono Measure.restrict_le_self)) +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/JointIntervalIntegral.lean b/lean/OAI/Analysis/BernoulliCone/JointIntervalIntegral.lean new file mode 100644 index 0000000000000000000000000000000000000000..c5e7a19f895a150519b933eacaa673fdd13b69a1 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/JointIntervalIntegral.lean @@ -0,0 +1,114 @@ +import OAI.Analysis.BernoulliCone.LocalFluxExtensions + +namespace OAI + +universe uE uG + +section +noncomputable section +open MeasureTheory Set Filter +open scoped Topology ContDiff +namespace Bernoulli.ParametricIntegral +variable {E : Type uE} {G : Type uG} [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] + [NormedAddCommGroup G] [NormedSpace ℝ G] [CompleteSpace G] + +omit [CompleteSpace G] in +/-- A compact-interval parameter derivative, with domination obtained from C1 +on an actual compact product. No derivative bound is an extra premise. -/ +theorem fixed_hasFDerivAt {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) (x:E) (a b:ℝ) : + HasFDerivAt (fun y:E=>∫t in a..b,F (y,t)) + (∫t in a..b,fderiv ℝ F (x,t) ∘L ContinuousLinearMap.inl ℝ E ℝ) x := by + let D:E×ℝ→E→L[ℝ] G:=fun p=>fderiv ℝ F p ∘L ContinuousLinearMap.inl ℝ E ℝ + have hD:Continuous D:=(hF.continuous_fderiv (by norm_num)).clm_comp continuous_const + have hc:IsCompact ((Metric.closedBall x 1)×ˢ(uIcc a b)):= + (isCompact_closedBall x 1).prod isCompact_uIcc + obtain ⟨C,hC⟩:=hc.exists_bound_of_continuousOn hD.continuousOn + have hFu (y:E):Continuous (fun t:ℝ=>F (y,t)):=hF.continuous.comp (continuous_const.prodMk continuous_id) + have hDu (y:E):Continuous (fun t:ℝ=>D (y,t)):=hD.comp (continuous_const.prodMk continuous_id) + apply intervalIntegral.hasFDerivAt_integral_of_dominated_of_fderiv_le + (F:=fun y t=>F (y,t)) (F':=fun y t=>D (y,t)) + (s:=Metric.closedBall x 1) (bound:=fun _=>C) (Metric.closedBall_mem_nhds x (by norm_num)) + · exact .of_forall fun y=>(hFu y).aestronglyMeasurable + · exact (hFu x).intervalIntegrable a b + · exact (hDu x).aestronglyMeasurable + · exact ae_of_all _ fun t ht y hy=>hC (y,t) ⟨hy,uIoc_subset_uIcc ht⟩ + · exact intervalIntegrable_const + · exact ae_of_all _ fun t _ y _=>by + have hi:HasFDerivAt (fun z:E=>(z,t)) (ContinuousLinearMap.inl ℝ E ℝ) y := by + simpa only [ContinuousLinearMap.inl,id_eq] using + (hasFDerivAt_id (𝕜:=ℝ) y).prodMk (hasFDerivAt_const t y) + exact ((hF.differentiable (by norm_num)) (y,t)).hasFDerivAt.comp y hi + +def heightPrimitive (F:E×ℝ→G) (p:E×ℝ) : G := ∫s in (0:ℝ)..p.2,F (p.1,s) + +omit [NormedAddCommGroup E] [NormedSpace ℝ E] [ProperSpace E] [CompleteSpace G] in +lemma heightPrimitive_rescale (F:E×ℝ→G) (p:E×ℝ) : + heightPrimitive F p=∫s in (0:ℝ)..1,p.2 • F (p.1,s*p.2) := by + by_cases ht:p.2=0 + · simp [heightPrimitive,ht] + · rw [intervalIntegral.integral_smul] + have hh:=intervalIntegral.integral_comp_mul_right (a:=0) (b:=1) (fun s:ℝ=>F (p.1,s)) ht + rw [hh] + simp only [zero_mul,one_mul,smul_smul,mul_inv_cancel₀ ht,one_smul,heightPrimitive] + +omit [CompleteSpace G] in +/-- Joint differentiability is proved, rather than inferred from separate +partial derivatives. Rescaling to [0,1] gives a compact dominated derivative. -/ +theorem heightPrimitive_differentiable [CompleteSpace G] {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) : + Differentiable ℝ (heightPrimitive F) := by + let B:(E×ℝ)×ℝ→G:=fun z=>z.1.2 • F (z.1.1,z.2*z.1.2) + have hB:ContDiff ℝ 1 B:=by + have hm:ContDiff ℝ 1 (fun z:(E×ℝ)×ℝ=>(z.1.1,z.2*z.1.2)):=by fun_prop + exact (contDiff_fst.snd).smul (hF.comp hm) + intro p + have hd: DifferentiableAt ℝ (fun y:E×ℝ=>∫s in (0:ℝ)..1,B (y,s)) p := + (fixed_hasFDerivAt hB p 0 1).differentiableAt + exact hd.congr_of_eventuallyEq (.of_forall fun q=>heightPrimitive_rescale F q) + +omit [NormedSpace ℝ E] [ProperSpace E] in +lemma heightPrimitive_height {F:E×ℝ→G} (hF:Continuous F) (p:E×ℝ) : + HasDerivAt (fun t:ℝ=>heightPrimitive F (p.1,t)) (F p) p.2 := by + have hc:Continuous (fun t:ℝ=>F (p.1,t)):=hF.comp (continuous_const.prodMk continuous_id) + exact intervalIntegral.integral_hasDerivAt_right (hc.intervalIntegrable 0 p.2) + hc.stronglyMeasurable.stronglyMeasurableAtFilter hc.continuousAt +lemma heightPrimitive_fderiv {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) (p:E×ℝ) (v:E) (r:ℝ) : + fderiv ℝ (heightPrimitive F) p (v,r)= + (∫s in (0:ℝ)..p.2,fderiv ℝ F (p.1,s) (v,0))+r • F p := by + have hd:HasFDerivAt (heightPrimitive F) (fderiv ℝ (heightPrimitive F) p) p:= + (heightPrimitive_differentiable hF p).hasFDerivAt + have hi:HasFDerivAt (fun y:E=>(y,p.2)) (ContinuousLinearMap.inl ℝ E ℝ) p.1:=by + simpa only [ContinuousLinearMap.inl,id_eq] using + (hasFDerivAt_id (𝕜:=ℝ) p.1).prodMk (hasFDerivAt_const p.2 p.1) + have he: fderiv ℝ (heightPrimitive F) p ∘L ContinuousLinearMap.inl ℝ E ℝ= + ∫s in (0:ℝ)..p.2,fderiv ℝ F (p.1,s) ∘L ContinuousLinearMap.inl ℝ E ℝ := + (HasFDerivAt.comp (g:=heightPrimitive F) (f:=fun y:E=>(y,p.2)) p.1 hd hi).unique + (fixed_hasFDerivAt hF p.1 0 p.2) + have hx:=congrArg (fun L:E→L[ℝ] G=>L v) he + have hDc:Continuous (fun s:ℝ=>fderiv ℝ F (p.1,s) ∘L ContinuousLinearMap.inl ℝ E ℝ):= + ((hF.continuous_fderiv (by norm_num)).comp (continuous_const.prodMk continuous_id)).clm_comp continuous_const + rw [ContinuousLinearMap.intervalIntegral_apply (hDc.intervalIntegrable 0 p.2)] at hx + have hh:=hd.comp_hasDerivAt p.2 ((hasDerivAt_const p.2 p.1).prodMk (hasDerivAt_id p.2)) + have ht:fderiv ℝ (heightPrimitive F) p (0,1)=F p:=hh.unique (heightPrimitive_height hF.continuous p) + calc + _=fderiv ℝ (heightPrimitive F) p ((v,0)+r • ((0:E),(1:ℝ))) := by congr 1; ext <;> simp + _=fderiv ℝ (heightPrimitive F) p (v,0)+r • fderiv ℝ (heightPrimitive F) p (0,1) := by rw [map_add,map_smul] + _=_ := by rw [ht]; exact congrArg (·+r • F p) hx + +lemma graph_fderiv {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) {u:E→ℝ} {x:E} + (hu:DifferentiableAt ℝ u x) (v:E) : + fderiv ℝ (fun y:E=>heightPrimitive F (y,u y)) x v= + (∫s in (0:ℝ)..u x,fderiv ℝ F (x,s) (v,0))+fderiv ℝ u x v • F (x,u x) := by + have hh:HasFDerivAt (fun y:E=>heightPrimitive F (y,u y)) + (fderiv ℝ (heightPrimitive F) (x,u x) ∘L + (ContinuousLinearMap.id ℝ E).prod (fderiv ℝ u x)) x := + HasFDerivAt.comp (g:=heightPrimitive F) (f:=fun y:E=>(y,u y)) x + (heightPrimitive_differentiable hF (x,u x)).hasFDerivAt + ((hasFDerivAt_id x).prodMk hu.hasFDerivAt) + rw [hh.fderiv] + exact heightPrimitive_fderiv hF (x,u x) v (fderiv ℝ u x v) +end Bernoulli.ParametricIntegral + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/LaplacianDilation.lean b/lean/OAI/Analysis/BernoulliCone/LaplacianDilation.lean new file mode 100644 index 0000000000000000000000000000000000000000..8e9afed87aee51b73ce5134e753be0e01a07437f --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/LaplacianDilation.lean @@ -0,0 +1,34 @@ +import OAI.Analysis.BernoulliCone.FoliationDifferential + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.ScalarLaplacian +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] +lemma laplacian_comp_smul {f:E→ℝ} {x:E} (a:ℝ) (hf:ContDiffAt ℝ 2 f (a • x)) : + Δ (fun y=>f (a • y)) x=a^2*Δ f (a • x) := by + have hg:ContDiffAt ℝ 2 (fun y:E=>f (a • y)) x:= + hf.comp x (contDiffAt_const.smul contDiffAt_id) + rw [laplacian_sum_line hg,laplacian_sum_line hf,Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + let v:=stdOrthonormalBasis ℝ E i + have he:(fun t:ℝ=>f (a • (x+t • v)))=(fun t:ℝ=>f (a • x+t • (a • v))) := by + ext t + rw [smul_add,smul_comm a t v] + change deriv (deriv (fun t:ℝ=>f (a • (x+t • v)))) 0 = _ + rw [he,Axisymmetric.line_second_derivative hf,Axisymmetric.line_second_derivative hf] + simp only [map_smul,smul_apply,smul_eq_mul] + ring +end Bernoulli.ScalarLaplacian + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/LipschitzProduct.lean b/lean/OAI/Analysis/BernoulliCone/LipschitzProduct.lean new file mode 100644 index 0000000000000000000000000000000000000000..0dcfbd3ca8998abb0ce3e6c1a25acb15fb6230b3 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/LipschitzProduct.lean @@ -0,0 +1,48 @@ +import OAI.Analysis.BernoulliCone.MinimizerOuterVariation + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} + +lemma lipschitz_mul_compact {u φ : Space d → ℝ} {L K : ℝ≥0} + (hu : LipschitzWith L u) (hφ : LipschitzWith K φ) + (hc : HasCompactSupport φ) : ∃ C, LipschitzWith C (fun x => u x*φ x) := by + obtain ⟨A,hA⟩ := hc.exists_bound_of_continuous hφ.continuous + obtain ⟨B,hB⟩ := (hc.isCompact.image hu.continuous).isBounded.exists_norm_le + let C : ℝ≥0 := ⟨|A| *L+|B| *K,by positivity⟩ + refine ⟨C,LipschitzWith.of_dist_le_mul ?_⟩ + have hbound (x : Space d) : |φ x| ≤ |A| := (hA x).trans (le_abs_self A) + have hboundu {x : Space d} (hx : φ x ≠ 0) : |u x| ≤ |B| := by + exact (hB _ (mem_image_of_mem u (subset_closure hx))).trans (le_abs_self B) + have ht (x y : Space d) (hy : φ y ≠ 0) : + |u x*φ x-u y*φ y| ≤ (C:ℝ)*dist x y := by + calc + _ = |φ x*(u x-u y)+u y*(φ x-φ y)| := by congr 1; ring + _ ≤ |φ x*(u x-u y)|+|u y*(φ x-φ y)| := abs_add_le _ _ + _ = |φ x| *|u x-u y|+|u y| *|φ x-φ y| := by rw [abs_mul,abs_mul] + _ ≤ |A| *(L*dist x y)+|B| *(K*dist x y) := by + apply add_le_add + · exact mul_le_mul (hbound x) (by simpa only [Real.norm_eq_abs,dist_eq_norm] using hu.norm_sub_le x y) + (abs_nonneg _) (abs_nonneg _) + · exact mul_le_mul (hboundu hy) (by simpa only [Real.norm_eq_abs,dist_eq_norm] using hφ.norm_sub_le x y) + (abs_nonneg _) (abs_nonneg _) + _ = _ := by change _=(|A| * (L:ℝ)+|B| * (K:ℝ))*dist x y; ring + intro x y + rw [Real.dist_eq] + by_cases hy : φ y=0 + · by_cases hx : φ x=0 + · simp only [hx,hy,mul_zero,sub_self,abs_zero]; positivity + · simpa only [abs_sub_comm,dist_comm] using ht y x hx + · exact ht x y hy +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/LocalFluxExtensions.lean b/lean/OAI/Analysis/BernoulliCone/LocalFluxExtensions.lean new file mode 100644 index 0000000000000000000000000000000000000000..c3a0ce202659329e352d75f742aa0c46805cfe59 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/LocalFluxExtensions.lean @@ -0,0 +1,74 @@ +import OAI.Analysis.BernoulliCone.SmoothLocalizedExtension + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.DeSilvaJerison + +def exteriorFlux (p:Space 7×ℝ):Space 7:=κ • gradient Zsigned p.1+ + ((p.2-κ*Zsigned p.1)/KSup p.1) • gradient KSup p.1 +lemma exteriorFlux_contDiffAt {p:Space 7×ℝ} (hq:0not_lt.mpr ((upperParameter_seam_iff hp hq).mp h) ht + have hqs:(upperParameter p.1 p.2)^2(exteriorFlux_contDiffAt hpd).of_le (by simp) |>.contDiffWithinAt) + let S:Set (Space 7×ℝ):={p∈K|seamHeight p.1≤p.2} + have hσ:ContinuousOn (fun p:Space 7×ℝ=>seamHeight p.1) K:=by + intro p hpk + exact ((seamHeight_contDiffAt (hq p hpk)).continuousAt.comp continuous_fst.continuousAt).continuousWithinAt + have hS:IsClosed S:=hK.isClosed.isClosed_le hσ continuousOn_snd + obtain ⟨B,hB,hBe⟩:=LocalExtension.exists_contDiff_one_of_closed_germs hS (F:=upperFlux) (by + intro p hps + have hqp:=((upperParameter_seam_iff (hp p hps.1) (hq p hps.1)).mpr hps.2) + obtain ⟨C,hC,hCp,hCe⟩:=upperFlux_cap_local_extension (hp p hps.1) hqp + refine ⟨C,hC.of_le (by simp),?_⟩ + filter_upwards [hCe] with y hy hys + exact hy (hp y hys.1) ((upperParameter_seam_iff (hp y hys.1) (hq y hys.1)).mpr hys.2)) + refine ⟨A,B,hA,hB,?_,?_⟩ + · intro p hpk + exact (hAe.filter_mono (nhds_le_nhdsSet hpk)).self_of_nhds + · intro p hpk hpt + exact hBe ⟨hpk,hpt⟩ +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/LowerComparison.lean b/lean/OAI/Analysis/BernoulliCone/LowerComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c512b48cf9f4db0187aa17a1a3d00dec0c6a6a9 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/LowerComparison.lean @@ -0,0 +1,226 @@ +import OAI.Analysis.BernoulliCone.SobolevIdeals + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff Laplacian +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} +namespace GroundState + +lemma lower_variation (c : Space d) (r : ℝ) (hr : 0G x-(w x/Y x) • gradient Y x) 2 (volume.restrict (Metric.ball c r)) ∧ + (∫x in Metric.ball c r, ‖G x-(w x/Y x) • gradient Y x‖^2) ≤ + (∫x in Metric.ball c r, ‖G x‖^2) := by + let B := Metric.ball c r + let S := Metric.ball c (r+1) + let Q := {x | 0E x-(w x/Y x) • gradient Y x + have hB : IsOpen B := Metric.isOpen_ball + have hS : IsOpen S := Metric.isOpen_ball + have hQ : IsOpen Q := (isOpen_lt continuous_const hu).inter hS + have hBS : closure B ⊆ S := by + change closure (Metric.ball c r) ⊆ Metric.ball c (r+1) + exact (closure_minimal Metric.ball_subset_closedBall Metric.isClosed_closedBall).trans + (Metric.closedBall_subset_ball (by linarith)) + + have hwQ : H10 Q w E := SobolevCalculus.h10_positive_domain_inter hS hBS hB + (Metric.isBounded_ball.isCompact_closure) hw hu hwn hwu hw0 + have hwE : H10 univ w E := by + have hh := hw.zero_extension hB.measurableSet (subset_univ B) + have he : B.indicator w=w := by + ext x + by_cases hx:x∈B + · simp [hx] + · simp [hx,hw0 x hx] + rwa [he] at hh + have hE0 : ∀ᵐ x ∂volume, w x=0 → E x=0 := by + simpa only [Measure.restrict_univ] using SobolevCalculus.gradient_zero_on_zero_set isOpen_univ hwE.1 + have hwQ0 : ∀x, x∉Q → w x=0 := by + intro x hx + by_cases hxu:0hx ⟨hxu,h⟩ + exact hw0 x (fun h=>hxS (hBS (subset_closure h))) + · have hu0 : u x = 0 := le_antisymm (not_lt.mp hxu) (hun x) + exact le_antisymm (by simpa only [hu0] using hwu x) (hwn x) + have hEint : (∫x in Q, ‖E x‖^2)=(∫x in B, ‖G x‖^2) := by + rw [setIntegral_eq_integral_of_ae_compl_eq_zero (s:=Q) (by + filter_upwards [hE0] with x hx hy + simp [hx (hwQ0 x hy)])] + rw [← integral_indicator hB.measurableSet] + apply integral_congr_ae + exact ae_of_all _ fun x=>by by_cases hx:x∈B <;> simp [E,hx] + have hEorth : (∫x in Q, inner ℝ (gradient u x) (E x))=(∫x in B, inner ℝ (gradient u x) (G x)) := by + rw [setIntegral_eq_integral_of_ae_compl_eq_zero (s:=Q) (by + filter_upwards [hE0] with x hx hy + simp [hx (hwQ0 x hy)])] + rw [← integral_indicator hB.measurableSet] + apply integral_congr_ae + exact ae_of_all _ fun x=>by by_cases hx:x∈B <;> simp [E,hx] + have hL0 : ∀ᵐ x ∂volume, x∉Q → L x=0 := by + filter_upwards [hE0] with x hx hy + simp [L,hwQ0 x hy,hx (hwQ0 x hy)] + have hLQ : MemLp L 2 (volume.restrict Q) := + (picone_h10_eLpNorm hQ (hY.mono inter_subset_left) (fun x hx=>hYp x hx.1) + (fun x hx=>hYlap x hx.1) hwQ).1 + have hLglobal : MemLp L 2 volume := by + apply ((memLp_indicator_iff_restrict hQ.measurableSet).mpr hLQ).ae_eq + filter_upwards [hL0] with x hx + by_cases hy:x∈Q <;> simp [hy,hx] + have hLB : MemLp (fun x=>G x-(w x/Y x) • gradient Y x) 2 (volume.restrict B) := by + apply (hLglobal.mono_measure Measure.restrict_le_self).ae_eq + filter_upwards [ae_restrict_mem hB.measurableSet] with x hx + simp [L,E,hx] + have hLint : (∫x in Q, ‖L x‖^2)=(∫x in B, ‖G x-(w x/Y x) • gradient Y x‖^2) := by + rw [setIntegral_eq_integral_of_ae_compl_eq_zero (s:=Q) (by + filter_upwards [hL0] with x hx hy + simp [hx hy])] + rw [← integral_indicator hB.measurableSet] + apply integral_congr_ae + exact ae_of_all _ fun x=>by + by_cases hx:x∈B + · simp [L,E,hx] + · simp [L,E,hx,hw0 x hx] + refine ⟨?_,hLB,?_⟩ + · rw [← hEorth] + exact harmonic_h10 hQ (huc.mono inter_subset_left) (fun x hx=>hul x hx.1) + ((huG c (r+1) (by linarith) (subset_univ _)).2.1.mono_measure + (Measure.restrict_mono inter_subset_right le_rfl)) hwQ + · rw [← hLint,← hEint] + exact picone_h10 hQ (hY.mono inter_subset_left) (fun x hx=>hYp x hx.1) + (fun x hx=>hYlap x hx.1) hwQ + +theorem lower_comparison (c : Space d) (r : ℝ) (hr : 0v x-u x) (fun x=>V x-gradient u x)) : + energy (Metric.ball c r) u (gradient u)≤energy (Metric.ball c r) v V := by + let B := Metric.ball c r + let A := gradient u + let G := fun x=>A x-V x + let w := B.indicator (fun x=>min (max (u x-v x) 0) (u x)) + have hB : IsOpen B := Metric.isOpen_ball + have hw0 : ∀x, x∉B → w x=0 := fun x hx=>by simp [w,hx] + have hwn : ∀x, 0≤w x := by + intro x + by_cases hx:x∈B + · simp only [w,indicator_of_mem hx] + exact le_min (le_max_right _ _) (hun x) + · simp [w,hx] + have hwu : ∀x, w x≤u x := by + intro x + by_cases hx:x∈B + · simp only [w,indicator_of_mem hx] + exact min_le_right _ _ + · simpa [w,hx] using hun x + have hweq : w =ᵐ[volume.restrict B] (fun x=>u x-v x) := by + filter_upwards [hvn,hvu,ae_restrict_mem hB.measurableSet] with x hx hy hz + simp [w,hz,max_eq_left (sub_nonneg.mpr hy),min_eq_left (by linarith : u x-v x≤u x)] + have hw : H10 B w G := by + apply htrace.neg.congr + · filter_upwards [hweq] with x hx + simp [hx] + · exact ae_of_all _ fun x=>neg_sub (V x) (A x) + obtain ⟨hort,hL,hlower⟩ := lower_variation c r hr hu hun huc hul huG hY hYp hYlap hw hwn hwu hw0 + let L := fun x=>G x-(w x/Y x) • gradient Y x + have huB := huG c r hr (subset_univ _) + let : IsFiniteMeasure (volume.restrict B) := isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + have hU2 := huB.2.1.integrable_norm_pow (by norm_num) + have hV2 := hv.2.1.integrable_norm_pow (by norm_num) + have hG : MemLp G 2 (volume.restrict B) := huB.2.1.sub hv.2.1 + have hG2 := hG.integrable_norm_pow (by norm_num) + have hL2 := hL.integrable_norm_pow (by norm_num) + have hUV := integrable_inner_of_memLp huB.2.1 hG + have hUE := hU2.add (integrable_phase huB.1.aestronglyMeasurable) + have hVE := hV2.add (integrable_phase hv.1.aestronglyMeasurable) + have hz := SobolevCalculus.gradient_zero_on_zero_set hB hv + change Integrable (fun x=>‖A x‖^2) (volume.restrict B) at hU2 + change Integrable (fun x=>‖L x‖^2) (volume.restrict B) at hL2 + change Integrable (fun x=>inner ℝ (A x) (G x)) (volume.restrict B) at hUV + change Integrable (fun x=>‖A x‖^2+(if 0‖V x‖^2+(if 0inner ℝ (A x) (G x)) + suffices hp : _ from by + have ht := hint hp + dsimp only [Pi.add_apply,Pi.sub_apply] at ht he he1 he2 he3 + change (∫x in B, ‖A x‖^2+(if 0v x-U x) (fun x=>V x-gradient U x)) : + energy (Metric.ball c r) U (gradient U)≤energy (Metric.ball c r) v V := by + apply GroundState.lower_comparison c r hr U_continuous U_nonneg U_smooth_positive + (fun x hx=>(U_harmonic x hx).2.self_of_nhds) U_h1loc (Y:=YSub) + (fun x hx=>(YSub_contDiffAt ((U_pos_iff x).mp hx).1).contDiffWithinAt) + (fun x hx=>YSub_pos ((U_pos_iff x).mp hx).1) + (fun x hx=>YSub_superharmonic ((U_pos_iff x).mp hx).1) + (fun x hx=>lower_groundstate_slope hx) hv hvn hvu htrace +end DeSilvaJerison +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/LowerSupport.lean b/lean/OAI/Analysis/BernoulliCone/LowerSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ee2d0427e4948ddf2bab036e7bc7d9bb8a0baa3 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/LowerSupport.lean @@ -0,0 +1,1347 @@ +import OAI.Analysis.BernoulliCone.SobolevCalculus + +namespace OAI + +universe uE uι + +section +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff + +noncomputable section +open Set Filter Finset +open scoped Topology +namespace Bernoulli.DeSilvaJerison + +/-- Half the logarithmic ratio; it is artanh on (-1,1). -/ +def A (t : ℝ) : ℝ := (Real.log (1+t) - Real.log (1-t))/2 + +/-- The even solution of (1-t²)f''-6tf'+6f=0 with f(0)=1. -/ +def f (t : ℝ) : ℝ := + (8-25*t^2+15*t^4)/(8*(1-t^2)^2) - (15/8)*t*A t + +/-- A convenient rational-logarithmic expression for f'. -/ +def fp (t : ℝ) : ℝ := + -t/(1-t^2)^3 - (5/4)*t/(1-t^2)^2 - (15/8)*t/(1-t^2) - (15/8)*A t + +lemma A_neg (t : ℝ) : A (-t) = -A t := by + simp only [A, sub_eq_add_neg, neg_neg] + ring + +@[simp] lemma A_zero : A 0 = 0 := by simp [A] +@[simp] lemma f_zero : f 0 = 1 := by norm_num [f] +@[simp] lemma fp_zero : fp 0 = 0 := by simp [fp] + +lemma f_neg (t : ℝ) : f (-t) = f t := by + simp only [f, neg_sq, A_neg] + ring + +lemma A_eq_half_log {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + A t = 1/2 * Real.log ((1+t)/(1-t)) := by + rw [Real.log_div (by linarith [ht.1] : 1+t≠0) (by linarith [ht.2] : 1-t≠0)] + unfold A + ring + +lemma hasDerivAt_A {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + HasDerivAt A (1/(1-t^2)) t := by + have hp : 1+t≠0 := by linarith [ht.1] + have hm : 1-t≠0 := by linarith [ht.2] + have hd : 1-t^2≠0 := by nlinarith [ht.1,ht.2] + apply (((((hasDerivAt_const t (1:ℝ)).add (hasDerivAt_id t)).log hp).sub + (((hasDerivAt_const t (1:ℝ)).sub (hasDerivAt_id t)).log hm)).div_const 2).congr_deriv + norm_num + field_simp [hd,hp,hm] + ring + +lemma hasDerivAt_f {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : HasDerivAt f (fp t) t := by + have hd : 1-t^2≠0 := by nlinarith [ht.1,ht.2] + have hden : 8*(1-t^2)^2≠0 := mul_ne_zero (by norm_num) (pow_ne_zero _ hd) + have hnum := ((hasDerivAt_const t (8:ℝ)).sub + (((hasDerivAt_id t).pow 2).const_mul 25)).add + (((hasDerivAt_id t).pow 4).const_mul 15) + have hden' := (((hasDerivAt_const t (1:ℝ)).sub ((hasDerivAt_id t).pow 2)).pow 2).const_mul 8 + apply ((hnum.div hden' hden).sub + (((hasDerivAt_id t).const_mul (15/8)).mul (hasDerivAt_A ht))).congr_deriv + norm_num [fp] + field_simp [hd] + ring + +lemma hasDerivAt_fp {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + HasDerivAt fp (-6/(1-t^2)^4) t := by + have hd : 1-t^2≠0 := by nlinarith [ht.1,ht.2] + have hD := (hasDerivAt_const t (1:ℝ)).sub ((hasDerivAt_id t).pow 2) + apply (((((hasDerivAt_id t).neg.div (hD.pow 3) (pow_ne_zero _ hd)).sub + (((hasDerivAt_id t).const_mul (5/4)).div (hD.pow 2) (pow_ne_zero _ hd))).sub + (((hasDerivAt_id t).const_mul (15/8)).div hD hd)).sub + ((hasDerivAt_A ht).const_mul (15/8))).congr_deriv + norm_num + field_simp [hd] + ring + +lemma f_relation {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + t * fp t - f t = -1/(1-t^2)^3 := by + have hd : 1-t^2≠0 := by nlinarith [ht.1,ht.2] + unfold fp f + field_simp + ring + +/-- The profile satisfies the differential equation `(1-t²)f''-6tf'+6f=0`. -/ +theorem profile_equation {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + (1-t^2) * deriv (deriv f) t - 6*t*deriv f t + 6*f t = 0 := by + have he : deriv f =ᶠ[𝓝 t] fp := by + filter_upwards [isOpen_Ioo.mem_nhds ht] with x hx + exact (hasDerivAt_f hx).deriv + rw [he.deriv_eq, (hasDerivAt_fp ht).deriv, (hasDerivAt_f ht).deriv] + have hr := f_relation ht + have hd : 1-t^2≠0 := by nlinarith [ht.1,ht.2] + field_simp at hr ⊢ + nlinarith [hr] + +lemma A_nonneg {t : ℝ} (ht : 0 ≤ t) (ht1 : t < 1) : 0 ≤ A t := by + rw [A_eq_half_log ⟨by linarith,ht1⟩] + exact mul_nonneg (by norm_num) (Real.log_nonneg ((one_le_div (by linarith)).mpr (by linarith))) + +lemma fp_neg {t : ℝ} (ht : 0 < t) (ht1 : t < 1) : fp t < 0 := by + have hD : 0<1-t^2 := by nlinarith + have hA := A_nonneg ht.le ht1 + have h1 : 0 < t/(1-t^2)^3 := div_pos ht (pow_pos hD _) + have h2 : 0 ≤ (5/4:ℝ)*t/(1-t^2)^2 := by positivity + have h3 : 0 ≤ (15/8:ℝ)*t/(1-t^2) := by positivity + unfold fp + rw [neg_div] + nlinarith + +lemma f_strictAnti : StrictAntiOn f (Ico (0 : ℝ) 1) := by + apply strictAntiOn_of_deriv_neg (convex_Ico 0 1) + · intro t ht + exact (hasDerivAt_f ⟨by linarith [ht.1],ht.2⟩).continuousAt.continuousWithinAt + · intro t ht + rw [interior_Ico] at ht + rw [(hasDerivAt_f ⟨by linarith [ht.1],ht.2⟩).deriv] + exact fp_neg ht.1 ht.2 + +/-- A certified enclosure, replacing the decimal root in the preprint. -/ +lemma f_lower_pos : 0 < f (517330/1000000) := by + have hA : A (517330/1000000) ≤ 5726875/10000000 := by + rw [A_eq_half_log (by norm_num)] + refine (Real.log_div_le_sum_range_add (by norm_num) (by norm_num) 12).trans ?_ + norm_num [Finset.sum_range_succ] + unfold f + norm_num at hA ⊢ + linarith + +lemma f_upper_neg : f (517331/1000000) < 0 := by + have hA : 572688/1000000 ≤ A (517331/1000000) := by + rw [A_eq_half_log (by norm_num)] + refine le_trans ?_ (Real.sum_range_le_log_div (by norm_num) (by norm_num) 12) + norm_num [Finset.sum_range_succ] + unfold f + norm_num at hA ⊢ + linarith + +lemma exists_profile_root : ∃ t ∈ Icc (517330/1000000 : ℝ) (517331/1000000), f t = 0 := by + have hc : ContinuousOn f (Icc (517330/1000000 : ℝ) (517331/1000000)) := by + intro t ht + exact (hasDerivAt_f ⟨by linarith [ht.1],by linarith [ht.2]⟩).continuousAt.continuousWithinAt + obtain ⟨t,ht,hft⟩ := intermediate_value_Icc' (by norm_num : (517330/1000000 : ℝ) ≤ 517331/1000000) + hc ⟨f_upper_neg.le, f_lower_pos.le⟩ + exact ⟨t,ht,hft⟩ + +/-- The first positive root t₇ of the normalized profile. -/ +def t7 : ℝ := exists_profile_root.choose + +lemma t7_bounds : t7 ∈ Icc (517330/1000000 : ℝ) (517331/1000000) := + exists_profile_root.choose_spec.1 + +@[simp] lemma f_t7 : f t7 = 0 := exists_profile_root.choose_spec.2 + +lemma t7_pos : 0 < t7 := by linarith [t7_bounds.1] +lemma t7_lt_one : t7 < 1 := by linarith [t7_bounds.2] + +lemma f_pos_of_abs_lt {t : ℝ} (ht : |t| < t7) : 0 < f t := by + have h : 0 < f |t| := by + rw [← f_t7] + exact f_strictAnti ⟨abs_nonneg t,lt_trans ht t7_lt_one⟩ + ⟨t7_pos.le,t7_lt_one⟩ ht + by_cases h0 : 0 ≤ t + · simpa [abs_of_nonneg h0] using h + · simpa [abs_of_neg (lt_of_not_ge h0), f_neg] using h + +lemma root_unique {t : ℝ} (ht : t ∈ Ico (0 : ℝ) 1) (hf : f t = 0) : t = t7 := by + exact f_strictAnti.injOn ht ⟨t7_pos.le,t7_lt_one⟩ (hf.trans f_t7.symm) + +lemma fp_t7 : fp t7 = -1 / (t7 * (1-t7^2)^3) := by + have h := f_relation ⟨by linarith [t7_pos],t7_lt_one⟩ + rw [f_t7,sub_zero] at h + calc + fp t7 = (-1 / (1-t7^2)^3) / t7 := + (eq_div_iff (ne_of_gt t7_pos)).mpr (by rw [mul_comm]; exact h) + _ = _ := by rw [div_div, mul_comm] + +/-- The square of the normal derivative of the unscaled conical function. -/ +def c7 : ℝ := (1-t7^2) * (fp t7)^2 + +lemma c7_pos : 0 < c7 := by + have hD : 0 < 1-t7^2 := by nlinarith [t7_pos,t7_lt_one] + exact mul_pos hD (sq_pos_of_neg (fp_neg t7_pos t7_lt_one)) + +lemma c7_eq : c7 = 1 / (t7^2 * (1-t7^2)^5) := by + have ht : t7≠0 := ne_of_gt t7_pos + have hd : 1-t7^2≠0 := ne_of_gt (show 0<1-t7^2 by nlinarith [t7_pos,t7_lt_one]) + rw [c7,fp_t7] + field_simp + +lemma contDiffAt_f {n : WithTop ℕ∞} {t : ℝ} (ht : t ∈ Ioo (-1 : ℝ) 1) : + ContDiffAt ℝ n f t := by + have hd : 8*(1-t^2)^2≠0 := by + apply mul_ne_zero (by norm_num) + exact pow_ne_zero _ (by nlinarith [ht.1,ht.2]) + have hp : 1+t≠0 := by linarith [ht.1] + have hm : 1-t≠0 := by linarith [ht.2] + unfold f A + fun_prop + +/-- Extend the positive spherical profile by zero outside its first two roots. -/ +def p (t : ℝ) : ℝ := f (min |t| t7) + +lemma f_abs (t : ℝ) : f |t| = f t := by + by_cases ht : 0 ≤ t + · rw [abs_of_nonneg ht] + · rw [abs_of_neg (lt_of_not_ge ht), f_neg] + +lemma p_eq_f {t : ℝ} (ht : |t| ≤ t7) : p t = f t := by + rw [p, min_eq_left ht, f_abs] + +lemma p_eq_zero {t : ℝ} (ht : t7 ≤ |t|) : p t = 0 := by + rw [p, min_eq_right ht, f_t7] + +lemma p_neg (t : ℝ) : p (-t) = p t := by simp only [p, abs_neg] +@[simp] lemma p_zero : p 0 = 1 := by rw [p_eq_f (by simpa using t7_pos.le), f_zero] + +lemma p_pos_iff (t : ℝ) : 0 < p t ↔ |t| < t7 := by + constructor + · intro ht + by_contra hn + rw [p_eq_zero (le_of_not_gt hn)] at ht + exact lt_irrefl 0 ht + · intro ht + rw [p_eq_f ht.le] + exact f_pos_of_abs_lt ht + +lemma p_nonneg (t : ℝ) : 0 ≤ p t := by + rcases lt_or_ge |t| t7 with ht | ht + · exact ((p_pos_iff t).mpr ht).le + · rw [p_eq_zero ht] + +lemma p_le_one (t : ℝ) : p t ≤ 1 := by + rw [p, ← f_zero] + apply f_strictAnti.antitoneOn ⟨le_rfl,by norm_num⟩ + ⟨le_min (abs_nonneg _) t7_pos.le, (min_le_right _ _).trans_lt t7_lt_one⟩ + exact le_min (abs_nonneg _) t7_pos.le + +lemma exists_lipschitz_p : ∃ K : NNReal, LipschitzWith K p := by + have hc : ContDiffOn ℝ 1 f (Icc 0 t7) := by + intro t ht + exact (contDiffAt_f ⟨by linarith [ht.1],ht.2.trans_lt t7_lt_one⟩).contDiffWithinAt + obtain ⟨K,hK⟩ := hc.exists_lipschitzOnWith (by norm_num) (convex_Icc 0 t7) isCompact_Icc + have hclip : LipschitzWith 1 (fun t : ℝ => min |t| t7) := by + simpa only [Real.norm_eq_abs] using ((lipschitzWith_one_norm : LipschitzWith 1 (fun t : ℝ => ‖t‖)).min_const t7) + refine ⟨K, LipschitzWith.of_dist_le_mul (fun x y => ?_)⟩ + have hm (t : ℝ) : min |t| t7 ∈ Icc 0 t7 := + ⟨le_min (abs_nonneg _) t7_pos.le, min_le_right _ _⟩ + exact (hK.dist_le_mul _ (hm x) _ (hm y)).trans (by + have hh := hclip.dist_le_mul x y + norm_num at hh + exact mul_le_mul_of_nonneg_left hh K.coe_nonneg) + +/-- The normalization imposed by the Bernoulli condition. -/ +def κ : ℝ := (Real.sqrt c7)⁻¹ + +lemma κ_pos : 0 < κ := inv_pos.mpr (Real.sqrt_pos.mpr c7_pos) +lemma κ_sq : κ^2 * c7 = 1 := by + rw [κ, inv_pow, Real.sq_sqrt c7_pos.le] + exact inv_mul_cancel₀ (ne_of_gt c7_pos) + +end Bernoulli.DeSilvaJerison + +/-! The concrete seven-dimensional cone belonging to the De Silva–Jerison profile. +These are actual function/Sobolev constructions, not an assumption of minimality. -/ +namespace Bernoulli.DeSilvaJerison + +/-- The homogeneous, nonnegative profile, prior to normalizing its boundary slope. -/ +def Z (x : Space 7) : ℝ := ‖x‖ * p (x 6 / ‖x‖) + +def U (x : Space 7) : ℝ := κ * Z x + +@[simp] lemma Z_zero : Z 0 = 0 := by simp [Z] +@[simp] lemma U_zero : U 0 = 0 := by simp [U] +lemma Z_nonneg (x : Space 7) : 0 ≤ Z x := mul_nonneg (norm_nonneg x) (p_nonneg _) +lemma U_nonneg (x : Space 7) : 0 ≤ U x := mul_nonneg κ_pos.le (Z_nonneg x) +lemma Z_le_norm (x : Space 7) : Z x ≤ ‖x‖ := by + calc Z x ≤ ‖x‖ * 1 := mul_le_mul_of_nonneg_left (p_le_one _) (norm_nonneg x) + _ = _ := mul_one _ +lemma U_even (x : Space 7) : U (-x) = U x := by + simp only [U,Z,norm_neg,PiLp.neg_apply,neg_div,p_neg] + +lemma coordinate_le_norm (x : Space 7) : |x 6| ≤ ‖x‖ := by + simpa only [Real.norm_eq_abs] using PiLp.norm_apply_le x (6 : Fin 7) + +lemma angular_estimate {x y : Space 7} (hx : x≠0) (hy : y≠0) : + ‖y‖ * |x 6/‖x‖ - y 6/‖y‖| ≤ 2*‖x-y‖ := by + have hr : 0<‖x‖ := norm_pos_iff.mpr hx + have hs : 0<‖y‖ := norm_pos_iff.mpr hy + have hq : |x 6/‖x‖| ≤ 1 := by + rw [abs_div,abs_of_pos hr] + exact (div_le_one hr).mpr (coordinate_le_norm x) + have hxy : |x 6-y 6| ≤ ‖x-y‖ := by + simpa only [PiLp.sub_apply] using coordinate_le_norm (x-y) + calc + ‖y‖ * |x 6/‖x‖ - y 6/‖y‖| = + |(‖y‖-‖x‖)*(x 6/‖x‖) + (x 6-y 6)| := by + rw [← abs_of_pos hs, ← abs_mul] + congr 1 + rw [abs_of_pos hs] + field_simp + ring + _ ≤ |‖y‖-‖x‖| * |x 6/‖x‖| + |x 6-y 6| := by + simpa only [abs_mul] using abs_add_le ((‖y‖-‖x‖)*(x 6/‖x‖)) (x 6-y 6) + _ ≤ |‖y‖-‖x‖| * 1 + ‖x-y‖ := by gcongr + _ ≤ ‖x-y‖ + ‖x-y‖ := by + rw [mul_one] + gcongr + simpa only [norm_sub_rev] using abs_norm_sub_norm_le y x + _ = _ := by ring + +lemma exists_lipschitz_Z : ∃ K : NNReal, LipschitzWith K Z := by + obtain ⟨K,hK⟩ := exists_lipschitz_p + refine ⟨1+2*K, LipschitzWith.of_dist_le_mul (fun x y => ?_)⟩ + simp only [dist_eq_norm, Real.norm_eq_abs, NNReal.coe_add, NNReal.coe_mul, + NNReal.coe_one, NNReal.coe_ofNat] + by_cases hx : x=0 + · subst x + rw [Z_zero,zero_sub,abs_neg,abs_of_nonneg (Z_nonneg y),zero_sub,norm_neg] + exact (Z_le_norm y).trans (by nlinarith [K.coe_nonneg,norm_nonneg y]) + by_cases hy : y=0 + · subst y + rw [Z_zero,sub_zero,abs_of_nonneg (Z_nonneg x),sub_zero] + exact (Z_le_norm x).trans (by nlinarith [K.coe_nonneg,norm_nonneg x]) + have hpd : |p (x 6/‖x‖)-p (y 6/‖y‖)| ≤ K * |x 6/‖x‖- y 6/‖y‖| := by + simpa only [Real.dist_eq] using hK.dist_le_mul (x 6/‖x‖) (y 6/‖y‖) + have hpb : |p (x 6/‖x‖)| ≤ 1 := by + rw [abs_of_nonneg (p_nonneg _)] + exact p_le_one _ + calc + |Z x-Z y| = |(‖x‖-‖y‖)*p (x 6/‖x‖) + ‖y‖*(p (x 6/‖x‖)-p (y 6/‖y‖))| := by + unfold Z + congr 1 + ring + _ ≤ |‖x‖-‖y‖| * |p (x 6/‖x‖)| + ‖y‖* |p (x 6/‖x‖)-p (y 6/‖y‖)| := by + simpa only [abs_mul, abs_of_nonneg (norm_nonneg y)] using + abs_add_le ((‖x‖-‖y‖)*p (x 6/‖x‖)) (‖y‖*(p (x 6/‖x‖)-p (y 6/‖y‖))) + _ ≤ |‖x‖-‖y‖| * 1 + ‖y‖*(K* |x 6/‖x‖-y 6/‖y‖|) := by gcongr + _ = |‖x‖-‖y‖| + K*(‖y‖* |x 6/‖x‖-y 6/‖y‖|) := by ring + _ ≤ ‖x-y‖ + K*(2*‖x-y‖) := by + exact add_le_add (abs_norm_sub_norm_le x y) + (mul_le_mul_of_nonneg_left (angular_estimate hx hy) K.coe_nonneg) + _ = _ := by ring + +lemma exists_lipschitz_U : ∃ K : NNReal, LipschitzWith K U := by + obtain ⟨K,hK⟩ := exists_lipschitz_Z + exact ⟨‖κ‖₊*K, (lipschitzWith_smul κ).comp hK⟩ + +lemma U_continuous : Continuous U := exists_lipschitz_U.choose_spec.continuous + +theorem U_h1loc : H1Loc univ U (gradient U) := by + obtain ⟨K,hK⟩ := exists_lipschitz_U + intro c r _ _ + exact LipschitzSobolev.h1_ball hK c r + +lemma U_smul (r : ℝ) (hr : 0 max (inner ℝ x e) 0) := by fun_prop + have heq := MeasureTheory.Measure.eq_of_ae_eq hae U_continuous hc + have hp := congrFun heq e + have hn := congrFun heq (-e) + rw [U_even] at hn + rw [real_inner_self_eq_norm_sq,he] at hp + rw [inner_neg_left,real_inner_self_eq_norm_sq,he] at hn + norm_num at hp hn + linarith + +end Bernoulli.DeSilvaJerison + +/-! Euclidean calculus for the actual De Silva–Jerison axisymmetric construction. +No free-boundary or variational conclusion is built into these definitions. -/ +noncomputable section +open Set Filter Finset +open scoped Topology ContDiff Laplacian +namespace Bernoulli.Axisymmetric +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma hasDerivAt_radius (x v : E) (t : ℝ) (h : x+t • v ≠ 0) : + HasDerivAt (fun a:ℝ=>‖x+a • v‖) + (inner ℝ (x+t • v) v / ‖x+t • v‖) t := by + have hc : HasDerivAt (fun a:ℝ=>x+a • v) v t := by + simpa using ((hasDerivAt_id t).smul_const v).const_add x + have hn : ‖x+t • v‖ ≠ 0 := norm_ne_zero_iff.mpr h + have hh := hc.norm_sq.sqrt (pow_ne_zero 2 hn) + simp only [Real.sqrt_sq (norm_nonneg _)] at hh + convert hh using 1; field_simp + +lemma hasDerivAt_axis (x v e : E) (t : ℝ) : + HasDerivAt (fun a:ℝ=>inner ℝ (x+a • v) e) (inner ℝ v e) t := by + have hc : HasDerivAt (fun a:ℝ=>x+a • v) v t := by + simpa using ((hasDerivAt_id t).smul_const v).const_add x + simpa using hc.inner ℝ (hasDerivAt_const t e) + +/-- Lift of a polar profile; values at the origin use the usual total operations. -/ +def lift (e : E) (α : ℝ) (φ : ℝ → ℝ) (x : E) : ℝ := + ‖x‖ ^ α * φ (inner ℝ x e / ‖x‖) + +lemma hasDerivAt_angular (x v e : E) (t : ℝ) (h : x+t • v≠0) : + HasDerivAt (fun a:ℝ=>inner ℝ (x+a • v) e / ‖x+a • v‖) + ((inner ℝ v e * ‖x+t • v‖^2 - inner ℝ (x+t • v) e * + inner ℝ (x+t • v) v) / ‖x+t • v‖^3) t := by + have hn := norm_ne_zero_iff.mpr h + apply ((hasDerivAt_axis x v e t).div (hasDerivAt_radius x v t h) hn).congr_deriv + field_simp + +lemma hasDerivAt_lift_line {φ : ℝ → ℝ} {φ' : ℝ} (e x v : E) (α t : ℝ) + (hx : x+t • v≠0) + (hφ : HasDerivAt φ φ' (inner ℝ (x+t • v) e / ‖x+t • v‖)) : + HasDerivAt (fun a:ℝ=>lift e α φ (x+a • v)) + (‖x+t • v‖^α * + (α * inner ℝ (x+t • v) v / ‖x+t • v‖^2 * φ (inner ℝ (x+t • v) e / ‖x+t • v‖) + + φ' * ((inner ℝ v e * ‖x+t • v‖^2 - inner ℝ (x+t • v) e * + inner ℝ (x+t • v) v) / ‖x+t • v‖^3))) t := by + have hn := norm_ne_zero_iff.mpr hx + have hr := (hasDerivAt_radius x v t hx).rpow_const (p:=α) (Or.inl hn) + have hp := hφ.comp t (hasDerivAt_angular x v e t hx) + apply (hr.mul hp).congr_deriv + simp only [Function.comp_def] + rw [Real.rpow_sub_one hn] + field_simp + +/-- The explicit first derivative along a line, used to avoid assuming an ODE +or a second derivative in the Euclidean Laplacian computation. -/ +def lineFirst (e x v : E) (α : ℝ) (φ φ₁ : ℝ → ℝ) (t : ℝ) : ℝ := + ‖x+t • v‖^α * + (α * inner ℝ (x+t • v) v / ‖x+t • v‖^2 * φ (inner ℝ (x+t • v) e / ‖x+t • v‖) + + φ₁ (inner ℝ (x+t • v) e / ‖x+t • v‖) * + ((inner ℝ v e * ‖x+t • v‖^2 - inner ℝ (x+t • v) e * + inner ℝ (x+t • v) v) / ‖x+t • v‖^3)) + +lemma hasDerivAt_lineFirst {φ φ₁ : ℝ → ℝ} {φ₂ : ℝ} (e x v : E) (α t : ℝ) + (hx : x+t • v≠0) + (hφ : HasDerivAt φ (φ₁ (inner ℝ (x+t • v) e / ‖x+t • v‖)) + (inner ℝ (x+t • v) e / ‖x+t • v‖)) + (hφ₁ : HasDerivAt φ₁ φ₂ (inner ℝ (x+t • v) e / ‖x+t • v‖)) : + HasDerivAt (lineFirst e x v α φ φ₁) + (‖x+t • v‖^α / ‖x+t • v‖^2 * + (α * φ (inner ℝ (x+t • v) e / ‖x+t • v‖) * ‖v‖^2 + + α * (α-2) * φ (inner ℝ (x+t • v) e / ‖x+t • v‖) * + (inner ℝ (x+t • v) v / ‖x+t • v‖)^2 + + 2*(α-1) * φ₁ (inner ℝ (x+t • v) e / ‖x+t • v‖) * + (inner ℝ (x+t • v) v / ‖x+t • v‖) * + (inner ℝ v e - inner ℝ (x+t • v) e / ‖x+t • v‖ * + (inner ℝ (x+t • v) v / ‖x+t • v‖)) - + inner ℝ (x+t • v) e / ‖x+t • v‖ * + φ₁ (inner ℝ (x+t • v) e / ‖x+t • v‖) * + (‖v‖^2-(inner ℝ (x+t • v) v / ‖x+t • v‖)^2) + + φ₂ * (inner ℝ v e - inner ℝ (x+t • v) e / ‖x+t • v‖ * + (inner ℝ (x+t • v) v / ‖x+t • v‖))^2)) t := by + have hn := norm_ne_zero_iff.mpr hx + have hr := hasDerivAt_radius x v t hx + have ha := hasDerivAt_axis x v e t + have hq : HasDerivAt (fun a:ℝ=>inner ℝ (x+a • v) v) (‖v‖^2) t := by + simpa only [real_inner_self_eq_norm_sq] using hasDerivAt_axis x v v t + have hs := hasDerivAt_angular x v e t hx + have hp := hφ.comp t hs + have hp₁ := hφ₁.comp t hs + have hQ := ((hq.const_mul α).div (hr.pow 2) (pow_ne_zero _ hn)).mul hp + have hS := (((hr.pow 2).const_mul (inner ℝ v e)).sub (ha.mul hq)).div + (hr.pow 3) (pow_ne_zero _ hn) + apply (((hr.rpow_const (p:=α) (Or.inl hn)).mul + (hQ.add (hp₁.mul hS)))).congr_deriv + simp only [Function.comp_def, Pi.pow_apply, Pi.div_apply, Pi.mul_apply, Pi.sub_apply, Pi.add_apply] + rw [Real.rpow_sub_one hn] + field_simp + ring + +/-- Scalar diagonal Hessian coefficient in a unit radial/angular frame. -/ +def secondCoeff (α F F₁ F₂ s p b n : ℝ) : ℝ := + α*F*n + α*(α-2)*F*p^2 + 2*(α-1)*F₁*p*(b-s*p) - + s*F₁*(n-p^2) + F₂*(b-s*p)^2 + +lemma secondCoeff_sum {ι : Type uι} [Fintype ι] + (α F F₁ F₂ s : ℝ) (p b : ι → ℝ) + (hp : ∑ i, (p i)^2 = 1) (hb : ∑ i, (b i)^2 = 1) + (hpb : ∑ i, p i*b i = s) : + ∑ i, secondCoeff α F F₁ F₂ s (p i) (b i) 1 = + α*(α+(Fintype.card ι : ℝ)-2)*F - ((Fintype.card ι : ℝ)-1)*s*F₁ + (1-s^2)*F₂ := by + have he (i:ι) : secondCoeff α F F₁ F₂ s (p i) (b i) 1 = + (α*F-s*F₁) + (α*(α-2)*F-(2*α-3)*s*F₁+s^2*F₂)*(p i)^2 + + (2*(α-1)*F₁-2*s*F₂)*(p i*b i) + F₂*(b i)^2 := by + unfold secondCoeff + ring + simp_rw [he, Finset.sum_add_distrib, ←Finset.mul_sum] + rw [hp,hb,hpb] + simp only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] + ring + +lemma contDiffAt_lift {φ : ℝ → ℝ} {e x : E} {α : ℝ} {n : WithTop ℕ∞} + (hx : x ≠ 0) (hf : ContDiffAt ℝ n φ (inner ℝ x e / ‖x‖)) : + ContDiffAt ℝ n (lift e α φ) x := by + have hn : ContDiffAt ℝ n (fun y:E=>‖y‖) x := contDiffAt_id.norm ℝ hx + have ha : ContDiffAt ℝ n (fun y:E=>inner ℝ y e / ‖y‖) x := + ((contDiffAt_id.inner ℝ contDiffAt_const).div hn (norm_ne_zero_iff.mpr hx)) + exact (hn.rpow_const_of_ne (norm_ne_zero_iff.mpr hx)).mul (hf.comp x ha) + +lemma lift_line_second {φ φ₁ : ℝ → ℝ} {φ₂ : ℝ} (e x v : E) (α : ℝ) + (hx : x≠0) + (hφ : ∀ᶠ s in 𝓝 (inner ℝ x e / ‖x‖), HasDerivAt φ (φ₁ s) s) + (hφ₁ : HasDerivAt φ₁ φ₂ (inner ℝ x e / ‖x‖)) : + deriv (deriv (fun t:ℝ=>lift e α φ (x+t • v))) 0 = + ‖x‖^α / ‖x‖^2 * secondCoeff α (φ (inner ℝ x e / ‖x‖)) + (φ₁ (inner ℝ x e / ‖x‖)) φ₂ (inner ℝ x e / ‖x‖) + (inner ℝ x v / ‖x‖) (inner ℝ v e) (‖v‖^2) := by + have hx0 : x+(0:ℝ) • v≠0 := by simpa + have hc : ContinuousAt (fun t:ℝ=>x+t • v) 0 := by fun_prop + have hnear : ∀ᶠ t:ℝ in 𝓝 0, x+t • v≠0 := + hc.eventually_ne hx0 + have hs := (hasDerivAt_angular x v e 0 hx0).continuousAt + have hp : ∀ᶠ t in 𝓝 (0:ℝ), HasDerivAt φ (φ₁ (inner ℝ (x+t • v) e / ‖x+t • v‖)) + (inner ℝ (x+t • v) e / ‖x+t • v‖) := by + exact hs.tendsto.eventually (p:=fun s=>HasDerivAt φ (φ₁ s) s) (by simpa using hφ) + have he : deriv (fun t:ℝ=>lift e α φ (x+t • v)) =ᶠ[𝓝 0] lineFirst e x v α φ φ₁ := by + filter_upwards [hnear,hp] with t ht hpt + exact (hasDerivAt_lift_line e x v α t ht hpt).deriv + rw [he.deriv_eq] + have hh := hasDerivAt_lineFirst e x v α 0 hx0 (by simpa using hφ.self_of_nhds) + (by simpa using hφ₁) + simpa only [zero_smul, add_zero, secondCoeff] using hh.deriv + +lemma line_second_derivative {f : E → ℝ} {x : E} (hf : ContDiffAt ℝ 2 f x) (v : E) : + deriv (deriv (fun t:ℝ=>f (x+t • v))) 0=(fderiv ℝ (fderiv ℝ f) x v) v := by + let c := fun t:ℝ=>x+t • v + let q := fun t:ℝ=>(fderiv ℝ f (c t)) v + have hc (t:ℝ) : HasDerivAt c v t := by + simpa only [one_smul,id_eq,c] using ((hasDerivAt_id t).smul_const v).const_add x + have hc0 : c 0=x := by simp [c] + have hnear : ∀ᶠ t in 𝓝 (0:ℝ), ContDiffAt ℝ 2 f (c t) := + (hc 0).continuousAt.tendsto.eventually (hc0 ▸ hf.eventually (by norm_num)) + have hq : deriv (fun t:ℝ=>f (x+t • v)) =ᶠ[𝓝 0] q := by + filter_upwards [hnear] with t ht + exact ((ht.differentiableAt (by norm_num)).hasFDerivAt.comp_hasDerivAt t (hc t)).deriv + have hff := (hf.fderiv_right (m:=1) (by norm_num)).differentiableAt (by norm_num) + have hff' : HasFDerivAt (fderiv ℝ f) (fderiv ℝ (fderiv ℝ f) x) (c 0) := hc0.symm ▸ hff.hasFDerivAt + have hh := (hff'.comp_hasDerivAt 0 (hc 0)).clm_apply (hasDerivAt_const 0 v) + have hqq : HasDerivAt q ((fderiv ℝ (fderiv ℝ f) x v) v) 0 := by + simpa only [Function.comp_def,ContinuousLinearMap.map_zero,add_zero,q] using hh + rw [hq.deriv_eq,hqq.deriv] + +lemma laplacian_lift [FiniteDimensional ℝ E] {φ φ₁ : ℝ → ℝ} {φ₂ : ℝ} + (e x : E) (α : ℝ) (he : ‖e‖=1) (hx : x≠0) + (hc : ContDiffAt ℝ 2 φ (inner ℝ x e / ‖x‖)) + (hφ : ∀ᶠ s in 𝓝 (inner ℝ x e / ‖x‖), HasDerivAt φ (φ₁ s) s) + (hφ₁ : HasDerivAt φ₁ φ₂ (inner ℝ x e / ‖x‖)) : + Δ (lift e α φ) x = ‖x‖^α / ‖x‖^2 * + (α*(α+(Module.finrank ℝ E : ℝ)-2)*φ (inner ℝ x e / ‖x‖) - + ((Module.finrank ℝ E : ℝ)-1)*(inner ℝ x e / ‖x‖)*φ₁ (inner ℝ x e / ‖x‖) + + (1-(inner ℝ x e / ‖x‖)^2)*φ₂) := by + let b := stdOrthonormalBasis ℝ E + have hn := norm_ne_zero_iff.mpr hx + have hp : ∑ i, (inner ℝ x (b i) / ‖x‖)^2 = 1 := by + simp_rw [div_pow, ←Finset.sum_div] + rw [b.sum_sq_inner_left] + exact div_self (pow_ne_zero _ hn) + have hb : ∑ i, (inner ℝ (b i) e)^2 = 1 := by + rw [b.sum_sq_inner_right,he] + norm_num + have hpb : ∑ i, (inner ℝ x (b i) / ‖x‖) * inner ℝ (b i) e = inner ℝ x e / ‖x‖ := by + simp_rw [div_mul_eq_mul_div, ←Finset.sum_div] + rw [b.sum_inner_mul_inner] + have hs := secondCoeff_sum α (φ (inner ℝ x e / ‖x‖)) (φ₁ (inner ℝ x e / ‖x‖)) φ₂ + (inner ℝ x e / ‖x‖) (fun i=>inner ℝ x (b i) / ‖x‖) (fun i=>inner ℝ (b i) e) hp hb hpb + rw [InnerProductSpace.laplacian_eq_iteratedFDeriv_stdOrthonormalBasis] + simp_rw [iteratedFDeriv_two_apply] + simp only [Fin.isValue,Matrix.cons_val_zero,Matrix.cons_val_one] + have hcc := contDiffAt_lift (α:=α) hx hc + simp_rw [←line_second_derivative hcc, lift_line_second e x _ α hx hφ hφ₁] + have hbunit (i:Fin (Module.finrank ℝ E)) : ‖b i‖^2 = (1:ℝ) := by simp + change (∑ i, ‖x‖^α / ‖x‖^2 * secondCoeff α (φ (inner ℝ x e / ‖x‖)) + (φ₁ (inner ℝ x e / ‖x‖)) φ₂ (inner ℝ x e / ‖x‖) + (inner ℝ x (b i) / ‖x‖) (inner ℝ (b i) e) (‖b i‖^2)) = _ + simp_rw [hbunit, ←Finset.mul_sum] + rw [hs] + simp + +/-- The radial unit vector (at nonzero points) and the tangential polar direction. -/ +def radial (x : E) : E := ‖x‖⁻¹ • x + +def polarGradient (e x : E) (a b : ℝ) : E := + a • radial x + b • (e - (inner ℝ x e / ‖x‖) • radial x) + +lemma radial_norm {x : E} (hx : x≠0) : ‖radial x‖=1 := by + rw [radial,norm_smul,Real.norm_eq_abs,abs_inv,abs_norm,inv_mul_cancel₀ (norm_ne_zero_iff.mpr hx)] + +lemma radial_inner (x e : E) : inner ℝ (radial x) e = inner ℝ x e / ‖x‖ := by + simp only [radial,real_inner_smul_left,div_eq_mul_inv,mul_comm] + +lemma norm_sq_polarGradient {e x : E} (he : ‖e‖=1) (hx : x≠0) (a b : ℝ) : + ‖polarGradient e x a b‖^2 = a^2 + (1-(inner ℝ x e / ‖x‖)^2)*b^2 := by + have hn : inner ℝ (radial x) (radial x)=1 := by + rw [real_inner_self_eq_norm_sq,radial_norm hx]; norm_num + have het : inner ℝ e e=1 := by rw [real_inner_self_eq_norm_sq,he]; norm_num + have hrev : inner ℝ e (radial x) = inner ℝ x e / ‖x‖ := + (real_inner_comm e (radial x)).symm.trans (radial_inner x e) + rw [←real_inner_self_eq_norm_sq] + simp only [polarGradient,inner_add_left,inner_add_right,inner_sub_left,inner_sub_right, + real_inner_smul_left,real_inner_smul_right,hn,het,hrev,radial_inner] + ring + +lemma hasGradientAt_lift [CompleteSpace E] {φ : ℝ → ℝ} {φ₁ : ℝ} + (e x : E) (α : ℝ) (hx : x≠0) + (hφ : HasDerivAt φ φ₁ (inner ℝ x e / ‖x‖)) : + HasGradientAt (lift e α φ) + ((‖x‖^α / ‖x‖) • polarGradient e x (α*φ (inner ℝ x e / ‖x‖)) φ₁) x := by + have hn := norm_ne_zero_iff.mpr hx + have hdN : DifferentiableAt ℝ (fun y:E=>‖y‖) x := differentiableAt_id.norm ℝ hx + have ha : ContDiffAt ℝ 1 (fun y:E=>inner ℝ y e / ‖y‖) x := + (contDiffAt_id.inner ℝ contDiffAt_const).div (contDiffAt_id.norm ℝ hx) hn + have hdA := ha.differentiableAt (by norm_num : (1 : WithTop ℕ∞) ≠ 0) + have hd : DifferentiableAt ℝ (lift e α φ) x := by + exact (hdN.rpow_const (Or.inl hn)).fun_mul (hφ.differentiableAt.comp x hdA) + apply hasGradientAt_iff_hasFDerivAt.mpr + apply hd.hasFDerivAt.congr_fderiv + ext v + have hl : HasDerivAt (fun t:ℝ=>x+t • v) v 0 := by + simpa using ((hasDerivAt_id (0:ℝ)).smul_const v).const_add x + have hd0 : HasFDerivAt (lift e α φ) (fderiv ℝ (lift e α φ) x) (x+(0:ℝ) • v) := by + simpa using hd.hasFDerivAt + have hcomp := hd0.comp_hasDerivAt (0:ℝ) hl + have hline := hasDerivAt_lift_line e x v α 0 (by simpa using hx) (by simpa using hφ) + simp only [zero_smul,add_zero] at hline + rw [hcomp.unique hline] + simp only [InnerProductSpace.toDual_apply_apply,real_inner_smul_left,polarGradient, + inner_add_left,inner_sub_left,real_inner_smul_left,radial,real_inner_smul_left, + real_inner_comm e v] + field_simp + +lemma gradient_lift_norm_sq [CompleteSpace E] {φ : ℝ → ℝ} {φ₁ : ℝ} + (e x : E) (α : ℝ) (he : ‖e‖=1) (hx : x≠0) + (hφ : HasDerivAt φ φ₁ (inner ℝ x e / ‖x‖)) : + ‖gradient (lift e α φ) x‖^2 = (‖x‖^α / ‖x‖)^2 * + ((α*φ (inner ℝ x e / ‖x‖))^2+(1-(inner ℝ x e / ‖x‖)^2)*φ₁^2) := by + rw [(hasGradientAt_lift e x α hx hφ).gradient,norm_smul,mul_pow] + rw [norm_sq_polarGradient he hx] + simp only [Real.norm_eq_abs,sq_abs] + +end Bernoulli.Axisymmetric + +namespace Bernoulli.DeSilvaJerison +open Axisymmetric InnerProductSpace +open scoped Laplacian ContDiff + +def axis : Space 7 := EuclideanSpace.single 6 1 + +def angle (x : Space 7) : ℝ := x 6 / ‖x‖ + +@[simp] lemma axis_norm : ‖axis‖=1 := by simp [axis] +@[simp] lemma inner_axis (x : Space 7) : inner ℝ x axis=x 6 := by + simp [axis, EuclideanSpace.inner_single_right] + +lemma angle_contDiffAt {x : Space 7} {n : WithTop ℕ∞} (hx : x≠0) : + ContDiffAt ℝ n angle x := by + have hn : ContDiffAt ℝ n (fun y:Space 7=>‖y‖) x := contDiffAt_id.norm ℝ hx + have hi : ContDiffAt ℝ n (fun y:Space 7=>inner ℝ y axis) x := + contDiffAt_id.inner ℝ contDiffAt_const + unfold angle + simpa only [inner_axis] using hi.fun_div hn (norm_ne_zero_iff.mpr hx) + +lemma U_pos_iff (x : Space 7) : 0U_eq_Usigned hy.le) + +/-- Positive-phase harmonicity is proved for the actual Sobolev candidate. -/ +theorem U_harmonic : HarmonicOnNhd U {x|0c*F y) x=c • gradient F x := by + rw [gradient, fderiv_const_mul hF] + simp only [map_smul,gradient] + +/-- The actual signed extension has exactly unit normal slope at every +nonvertex free-boundary point. This does not claim its energy comparison. -/ +theorem Usigned_boundary_slope {x : Space 7} (hx : x≠0) (ha : |angle x|=t7) : + ‖gradient Usigned x‖=1 := by + have hd : DifferentiableAt ℝ Zsigned x := + (signed_contDiffAt (n:=1) hx (ha.trans_lt t7_lt_one)).differentiableAt (by norm_num) + have he : gradient Usigned x=κ • gradient Zsigned x := gradient_const_mul κ hd + have hs : ‖gradient Usigned x‖^2=1 := by + rw [he,norm_smul,mul_pow,Real.norm_eq_abs,sq_abs,Zsigned_boundary_slope hx ha,κ_sq] + nlinarith [norm_nonneg (gradient Usigned x)] + +end Bernoulli.DeSilvaJerison + +namespace Bernoulli.DeSilvaJerison +open scoped BigOperators + +def B (n:ℕ) (u:ℝ) : ℝ := ∑ i ∈ Finset.range n, u^i / (2*i+1) + +lemma B_nonneg (n:ℕ) {u:ℝ} (hu:0≤u) : 0≤B n u := by + apply Finset.sum_nonneg + intro i hi + positivity + +lemma odd_sum_eq (n:ℕ) (t:ℝ) : + (∑ i ∈ Finset.range n, t^(2*i+1)/(2*i+1))=t*B n (t^2) := by + rw [B,Finset.mul_sum] + apply Finset.sum_congr rfl + intro i hi + rw [pow_add,pow_mul] + ring + +lemma A_series_bounds (n:ℕ) {t:ℝ} (ht:0≤t) (ht1:t<1) : + t*B n (t^2) ≤ A t ∧ A t ≤ t*(B n (t^2)+(t^2)^n/(1-t^2)) := by + have hI : t∈Ioo (-1:ℝ) 1 := ⟨by linarith,ht1⟩ + have hL := Real.sum_range_le_log_div ht ht1 n + have hU := Real.log_div_le_sum_range_add ht ht1 n + rw [odd_sum_eq,A_eq_half_log hI] at * + constructor + · exact hL + · convert hU using 1 + rw [pow_add,pow_mul] + ring + +lemma f_series_lower (n:ℕ) {t:ℝ} (ht:0≤t) (ht1:t<1) : + (8-25*t^2+15*(t^2)^2)/(8*(1-t^2)^2) + -15/8*t^2*(B n (t^2)+(t^2)^n/(1-t^2)) ≤ f t := by + have ha := (A_series_bounds n ht ht1).2 + have hp := mul_le_mul_of_nonneg_left ha (show (0:ℝ)≤15/8*t from by positivity) + unfold f + convert! sub_le_sub_left hp ((8-25*t^2+15*t^4)/(8*(1-t^2)^2)) using 1 + ring + +lemma fp_series_upper (n:ℕ) {t:ℝ} (ht:0≤t) (ht1:t<1) : + fp t ≤ -t*(1/(1-t^2)^3+5/4/(1-t^2)^2+15/8/(1-t^2)+15/8*B n (t^2)) := by + have ha := (A_series_bounds n ht ht1).1 + unfold fp + have hp := mul_le_mul_of_nonneg_left ha (show (0:ℝ)≤15/8 from by norm_num) + convert! sub_le_sub_left hp (-t/(1-t^2)^3-5/4*t/(1-t^2)^2-15/8*t/(1-t^2)) using 1 + ring + +end Bernoulli.DeSilvaJerison + +noncomputable section +open scoped BigOperators +namespace Bernoulli.DeSilvaJerison.Algebra +def g (u:ℝ) : ℝ := (1+u*((2869387/1000000:ℝ)+u*((589981/125000:ℝ)+u*((6566689/1000000:ℝ)+u*((4206127/500000:ℝ)+u*((10257227/1000000:ℝ)+u*((6050939/500000:ℝ)+u*((2789267/200000:ℝ)+u*(7895333/500000:ℝ))))))))) + +def g1 (u:ℝ) : ℝ := ((2869387/1000000:ℝ)+u*((589981/62500:ℝ)+u*((19700067/1000000:ℝ)+u*((4206127/125000:ℝ)+u*((10257227/200000:ℝ)+u*((18152817/250000:ℝ)+u*((19524869/200000:ℝ)+u*(7895333/62500:ℝ)))))))) + +def g2 (u:ℝ) : ℝ := ((589981/62500:ℝ)+u*((19700067/500000:ℝ)+u*((12618381/125000:ℝ)+u*((10257227/50000:ℝ)+u*((18152817/50000:ℝ)+u*((58574607/100000:ℝ)+u*(55267331/62500:ℝ))))))) + +def FlowNum (u:ℝ) : ℝ := (8+u*(-40+u*(40+u*(-8+u*((-8/7:ℝ)+u*((-8/21:ℝ)+u*((-40/231:ℝ)+u*((-460/33:ℝ)+u*(150/11:ℝ))))))))) + +def JlowNum (u:ℝ) : ℝ := (48+u*(-80+u*(48+u*((-48/7:ℝ)+u*((-16/21:ℝ)+u*((-16/77:ℝ)+u*((-95/77:ℝ)+u*((80/33:ℝ)+u*(-15/11:ℝ))))))))) + +def H (u:ℝ) : ℝ := + (1-(-643/200:ℝ))^2 * (FlowNum u)^2*(1-u)^2*(g u)^2 + +u*(1-u)*(JlowNum u*g u+2*FlowNum u*(1-u)*g1 u)^2 + -64*(177344/10000:ℝ)*(1-u)^6*(g u)^2 + +def bern (x:ℝ) :ℝ := + (1273/625:ℝ)*x^0*(1-x)^34 + + (18301700752813/39062500000:ℝ)*x^1*(1-x)^33 + + (215052290412518053937/15625000000000000:ℝ)*x^2*(1-x)^32 + + (4011660524023528296977/19531250000000000:ℝ)*x^3*(1-x)^31 + + (2737813200177456418780827/1367187500000000000:ℝ)*x^4*(1-x)^30 + + (36470062299690915838876891/2563476562500000000:ℝ)*x^5*(1-x)^29 + + (25224069904037561558116841153/322265625000000000000:ℝ)*x^6*(1-x)^28 + + (1140064408982925692415284885429/3289794921875000000000:ℝ)*x^7*(1-x)^27 + + (41702430755303183867323989789361/32897949218750000000000:ℝ)*x^8*(1-x)^26 + + (3302410109850186979935464577903227/845947265625000000000000:ℝ)*x^9*(1-x)^25 + + (607809096133375762153335847523839391/59216308593750000000000000:ℝ)*x^10*(1-x)^24 + + (8427099588852868346099742136229588957/361877441406250000000000000:ℝ)*x^11*(1-x)^23 + + (83162165720757436741420385026341254509/1809387207031250000000000000:ℝ)*x^12*(1-x)^22 + + (6465714023183326120974320513863787790989/81422424316406250000000000000:ℝ)*x^13*(1-x)^21 + + (3070489019357153411700150072588091455833/25444507598876953125000000000:ℝ)*x^14*(1-x)^20 + + (82369624574464912186052678411201103823739/508890151977539062500000000000:ℝ)*x^15*(1-x)^19 + + (3910314359275519861283649778682853171355229/20355606079101562500000000000000:ℝ)*x^16*(1-x)^18 + + (979175253390516279186463881299949127320211/4846572875976562500000000000000:ℝ)*x^17*(1-x)^17 + + (18263450287363530970672089631693726965414361/96931457519531250000000000000000:ℝ)*x^18*(1-x)^16 + + (17617068143172995639202711944743442184849557/113086700439453125000000000000000:ℝ)*x^19*(1-x)^15 + + (5805157568137808862325200615665450856083238073/50889015197753906250000000000000000:ℝ)*x^20*(1-x)^14 + + (106751395374573342818643134988112428956196041/1445710659027099609375000000000000:ℝ)*x^21*(1-x)^13 + + (13399476602886887470912830751358415258789263239/318056344985961914062500000000000000:ℝ)*x^22*(1-x)^12 + + (203394843320074906765348971241270582814374973/9638071060180664062500000000000000:ℝ)*x^23*(1-x)^11 + + (73412104728736551372464217800669117696986097123/7951408624649047851562500000000000000:ℝ)*x^24*(1-x)^10 + + (139309476218905417280721075386752271276084623033/39757043123245239257812500000000000000:ℝ)*x^25*(1-x)^9 + + (32477127068915750179291210097408098171730074813/28397887945175170898437500000000000000:ℝ)*x^26*(1-x)^8 + + (39433145196824909814460561789894422591933034093/124240759760141372680664062500000000000:ℝ)*x^27*(1-x)^7 + + (1852317908162190170035216935656039577364200647/25099143385887145996093750000000000000:ℝ)*x^28*(1-x)^6 + + (5836982899230309706402487066150347002468521567/414135865867137908935546875000000000000:ℝ)*x^29*(1-x)^5 + + (53440683331803983473324825254354074715316174661/24848151952028274536132812500000000000000:ℝ)*x^30*(1-x)^4 + + (1564303979409844850797520400352897238700085837/6212037988007068634033203125000000000000:ℝ)*x^31*(1-x)^3 + + (219633445088755317503000659291685432421229847/10353396646678447723388671875000000000000:ℝ)*x^32*(1-x)^2 + + (4437106302213137739667714564011045560602003/3882523742504417896270751953125000000000:ℝ)*x^33*(1-x)^1 + + (57307964213152837654157884692498315776209/1941261871252208948135375976562500000000:ℝ)*x^34*(1-x)^0 + +lemma identity (x:ℝ) : H ((1/5:ℝ)*x)=bern x := by + unfold H FlowNum JlowNum g g1 bern + ring + +lemma bern_nonneg {x:ℝ} (hx:0≤x) (hx1:x≤1) : 0≤bern x := by + have hy : 0≤1-x := sub_nonneg.mpr hx1 + unfold bern + positivity + +lemma H_nonneg {u:ℝ} (hu:0≤u) (hu1:u≤1/5) : 0≤H u := by + have he : u=(1/5:ℝ)*(u/(1/5)) := by ring + rw [he,identity] + apply bern_nonneg + · positivity + · rw [div_le_one (by norm_num : (0:ℝ)<1/5)] + exact hu1 + +lemma hasDerivAt_g (u:ℝ) : HasDerivAt g (g1 u) u := by + have hh := ((hasDerivAt_const u 1).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (2869387/1000000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (589981/125000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (6566689/1000000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (4206127/500000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (10257227/1000000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (6050939/500000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (2789267/200000:ℝ)).add ((hasDerivAt_id u).mul (hasDerivAt_const u (7895333/500000:ℝ)))))))))))))))))) + convert! hh using 1 + simp only [g1, Pi.add_apply, Pi.mul_apply, id_eq] + ring + +lemma hasDerivAt_g1 (u:ℝ) : HasDerivAt g1 (g2 u) u := by + have hh := ((hasDerivAt_const u (2869387/1000000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (589981/62500:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (19700067/1000000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (4206127/125000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (10257227/200000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (18152817/250000:ℝ)).add ((hasDerivAt_id u).mul ((hasDerivAt_const u (19524869/200000:ℝ)).add ((hasDerivAt_id u).mul (hasDerivAt_const u (7895333/62500:ℝ)))))))))))))))) + convert! hh using 1 + simp only [g2, Pi.add_apply, Pi.mul_apply, id_eq] + ring + +lemma g_ge_one {u:ℝ} (hu:0≤u) : 1≤g u := by + unfold g + have : 0≤u*((2869387/1000000:ℝ)+u*((589981/125000:ℝ)+u*((6566689/1000000:ℝ)+u*((4206127/500000:ℝ)+u*((10257227/1000000:ℝ)+u*((6050939/500000:ℝ)+u*((2789267/200000:ℝ)+u*(7895333/500000:ℝ)))))))) := by positivity + linarith + +lemma g1_nonneg {u:ℝ} (hu:0≤u) : 0≤g1 u := by unfold g1; positivity + +lemma g_residual_nonpos {u:ℝ} (hu:0≤u) : + (1-u)*(2*g1 u+4*u*g2 u)-12*u*g1 u+(-643/200:ℝ)*(-643/200+5)*g u ≤0 := by + have he : -((1-u)*(2*g1 u+4*u*g2 u)-12*u*g1 u+(-643/200:ℝ)*(-643/200+5)*g u) = + ((1/1000000:ℝ)+u*((335237/40000000000:ℝ)+u*((18531/5000000000:ℝ)+u*((26639/40000000000:ℝ)+u*((378977/20000000000:ℝ)+u*((2875077/40000000000:ℝ)+u*((1938389/20000000000:ℝ)+u*((1189117/8000000000:ℝ)+u*(107925657105483/20000000000:ℝ))))))))) := by unfold g g1 g2; ring + have hz : 0≤ -((1-u)*(2*g1 u+4*u*g2 u)-12*u*g1 u+(-643/200:ℝ)*(-643/200+5)*g u) := by + rw [he] + positivity + linarith + +lemma lower_logder {u:ℝ} (hu:0≤u) (hub:u≤(27/100:ℝ)) : 0≤2*(1-u)*g1 u-5*g u := by + let x:=u/(27/100:ℝ) + have hx:0≤x := by dsimp [x]; positivity + have hy:0≤1-x := by dsimp [x]; linarith + have he : 2*(1-u)*g1 u-5*g u = + (369387/500000:ℝ)*x^0*(1-x)^8 + (558448641/100000000:ℝ)*x^1*(1-x)^7 + (90906551829/5000000000:ℝ)*x^2*(1-x)^6 + (33087845213199/1000000000000:ℝ)*x^3*(1-x)^5 + (910658646456597/25000000000000:ℝ)*x^4*(1-x)^4 + (243550667389510017/10000000000000000:ℝ)*x^5*(1-x)^3 + (1156300362730287837/125000000000000000:ℝ)*x^6*(1-x)^2 + (160712254758181821273/100000000000000000000:ℝ)*x^7*(1-x)^1 + (141611539097570077017/5000000000000000000000:ℝ)*x^8*(1-x)^0 := by + dsimp [x] + unfold g g1 + ring + rw [he] + positivity + +lemma upper_logder {u:ℝ} (hu:0≤u) (hub:u≤(27/100:ℝ)) : 0≤2*g u-(13/25)*g1 u := by + let x:=u/(27/100:ℝ) + have hx:0≤x := by dsimp [x]; positivity + have hy:0≤1-x := by dsimp [x]; linarith + have he : 2*g u-(13/25)*g1 u = + (12697969/25000000:ℝ)*x^0*(1-x)^8 + (5359357177/1250000000:ℝ)*x^1*(1-x)^7 + (3933009652441/250000000000:ℝ)*x^2*(1-x)^6 + (408907285769443/12500000000000:ℝ)*x^3*(1-x)^5 + (21018853182775349/500000000000000:ℝ)*x^4*(1-x)^4 + (4252809530492624731/125000000000000000:ℝ)*x^5*(1-x)^3 + (83958125315148478907/5000000000000000000:ℝ)*x^6*(1-x)^2 + (5678700560736300182329/1250000000000000000000:ℝ)*x^7*(1-x)^1 + (1242771118592263674331/2500000000000000000000:ℝ)*x^8*(1-x)^0 := by + dsimp [x] + unfold g g1 + ring + rw [he] + positivity + +lemma FlowNum_nonneg {u:ℝ} (hu:0≤u) (hub:u≤(1/5:ℝ)) : 0≤FlowNum u := by + let x:=u/(1/5:ℝ) + have hx:0≤x := by dsimp [x]; positivity + have hy:0≤1-x := by dsimp [x]; linarith + have he : FlowNum u = + 8*x^0*(1-x)^8 + 56*x^1*(1-x)^7 + (848/5:ℝ)*x^2*(1-x)^6 + (36192/125:ℝ)*x^3*(1-x)^5 + (1328592/4375:ℝ)*x^4*(1-x)^4 + (13082512/65625:ℝ)*x^5*(1-x)^3 + (57279808/721875:ℝ)*x^6*(1-x)^2 + (62341556/3609375:ℝ)*x^7*(1-x)^1 + (5536402/3609375:ℝ)*x^8*(1-x)^0 := by + dsimp [x] + unfold FlowNum + ring + rw [he] + positivity + +end Bernoulli.DeSilvaJerison.Algebra + +namespace Bernoulli.DeSilvaJerison + +def gSub (t:ℝ) : ℝ := Algebra.g (t^2) +def gSub1 (t:ℝ) : ℝ := 2*t*Algebra.g1 (t^2) +def gSub2 (t:ℝ) : ℝ := 2*Algebra.g1 (t^2)+4*t^2*Algebra.g2 (t^2) +def qSub (t:ℝ) : ℝ := gSub1 t/gSub t + +lemma gSub_pos (t:ℝ) : 0 dsimp only [f,fp] <;> norm_num at ha ⊢ <;> linarith + +end Bernoulli.DeSilvaJerison + +namespace Bernoulli.DeSilvaJerison + +/-- The free-boundary gradient numerator for the explicit lower barrier. -/ +def GSub (t:ℝ) : ℝ := (1-(-643/200:ℝ))^2*(f t)^2+ + (1-t^2)*(fp t-f t*qSub t)^2 + +def FLo (t:ℝ) : ℝ := Algebra.FlowNum (t^2)/(8*(1-t^2)^2) +def JLo (t:ℝ) : ℝ := Algebra.JlowNum (t^2)/(8*(1-t^2)^3) + +lemma FLo_le {t:ℝ} (ht:0≤t) (ht1:t<1) : FLo t≤f t := by + have hd:1-t^2≠0 := by nlinarith + convert! f_series_lower 6 ht ht1 using 1 + unfold FLo Algebra.FlowNum B + norm_num [Finset.sum_range_succ] + field_simp [hd] + ring + +lemma fp_le_JLo {t:ℝ} (ht:0≤t) (ht1:t<1) : fp t≤-t*JLo t := by + have hd:1-t^2≠0 := by nlinarith + convert! fp_series_upper 6 ht ht1 using 1 + unfold JLo Algebra.JlowNum B + norm_num [Finset.sum_range_succ] + field_simp [hd] + ring_nf + simp + +lemma JLo_nonneg {t:ℝ} (ht:0≤t) (ht1:t<1) : 0≤JLo t := by + have hd:0<1-t^2 := by nlinarith + have he : JLo t=1/(1-t^2)^3+5/4/(1-t^2)^2+15/8/(1-t^2)+15/8*B 6 (t^2) := by + unfold JLo Algebra.JlowNum B + norm_num [Finset.sum_range_succ] + field_simp + ring + rw [he] + have hh:=B_nonneg 6 (sq_nonneg t) + positivity + +lemma GSub_low {t:ℝ} (ht:0≤t) (htb:t≤11/25) : c7≤GSub t := by + have ht1:t<1 := by linarith + have hd:0<1-t^2 := by nlinarith + have hu:t^2≤1/5 := by nlinarith + have hg:=gSub_pos t + have hF:0≤FLo t := div_nonneg (Algebra.FlowNum_nonneg (sq_nonneg t) hu) (by positivity) + have hL:=FLo_le ht ht1 + have hp:=fp_le_JLo ht ht1 + have hJ:=JLo_nonneg ht ht1 + have hq:=qSub_nonneg ht + have hB: t*JLo t+FLo t*qSub t ≤ -(fp t-f t*qSub t) := by + have hh:=mul_le_mul_of_nonneg_right hL hq + linarith + have hB0:0≤t*JLo t+FLo t*qSub t := by positivity + have hs1 := sq_le_sq₀ hF (hF.trans hL) |>.mpr hL + have hs2 := sq_le_sq₀ hB0 (hB0.trans hB) |>.mpr hB + have hH:=Algebra.H_nonneg (sq_nonneg t) hu + have he : Algebra.H (t^2) = + 64*(1-t^2)^6*(gSub t)^2 * + ((1-(-643/200:ℝ))^2*(FLo t)^2+(1-t^2)*(t*JLo t+FLo t*qSub t)^2-177344/10000) := by + unfold Algebra.H FLo JLo qSub gSub gSub1 + have hgn : Algebra.g (t^2) ≠ 0 := ne_of_gt hg + field_simp [ne_of_gt hd,hgn] + ring + rw [he] at hH + have hn := (mul_nonneg_iff_of_pos_left (by positivity : 0<64*(1-t^2)^6*(gSub t)^2)).mp hH + have hu1:=mul_le_mul_of_nonneg_left hs1 (show (0:ℝ)≤(1-(-643/200:ℝ))^2 by positivity) + have hu2:=mul_le_mul_of_nonneg_left hs2 hd.le + dsimp [GSub] + nlinarith [c7_upper] + +lemma hasDerivAt_qSub (t:ℝ) : + HasDerivAt qSub (gSub2 t/gSub t-(qSub t)^2) t := by + have hh := (hasDerivAt_gSub1 t).div (hasDerivAt_gSub t) (ne_of_gt (gSub_pos t)) + convert! hh using 1 + unfold qSub + field_simp + +lemma qSub_deriv_bound {t:ℝ} (_ht:0≤t) (_ht1:t<1) : + (1-t^2)*(gSub2 t/gSub t-(qSub t)^2) ≤ + 6*t*qSub t-(-643/200:ℝ)*(-643/200+5)-(1-t^2)*(qSub t)^2 := by + have hg:=gSub_pos t + have hh:=gSub_residual t + have he : (1-t^2)*(gSub2 t/gSub t-(qSub t)^2)- + (6*t*qSub t-(-643/200:ℝ)*(-643/200+5)-(1-t^2)*(qSub t)^2) = + ((1-t^2)*gSub2 t-6*t*gSub1 t+(-643/200:ℝ)*(-643/200+5)*gSub t)/gSub t := by + unfold qSub + field_simp + ring + have hz:=div_nonpos_of_nonpos_of_nonneg hh hg.le + linarith + +lemma hasDerivAt_GSub {t:ℝ} (ht:t∈Ioo (-1:ℝ) 1) : + HasDerivAt GSub + (2*((1-(-643/200:ℝ))^2*f t*fp t-t*(fp t-f t*qSub t)^2+ + (1-t^2)*(fp t-f t*qSub t)*(-6/(1-t^2)^4-fp t*qSub t-f t*(gSub2 t/gSub t-(qSub t)^2)))) t := by + have hh:=(((hasDerivAt_f ht).pow 2).const_mul ((1-(-643/200:ℝ))^2)).add + (((hasDerivAt_const t (1:ℝ)).sub ((hasDerivAt_id t).pow 2)).mul + (((hasDerivAt_fp ht).sub ((hasDerivAt_f ht).mul (hasDerivAt_qSub t))).pow 2)) + convert! hh using 1 + norm_num only [id_eq,pow_one,Pi.add_apply,Pi.sub_apply,Pi.mul_apply,Pi.pow_apply] + ring + +lemma GSub_nonpos_deriv {t:ℝ} (ht:11/25≤t) (ht7:t≤t7) : deriv GSub t ≤0 := by + have ht0:0≤t := by linarith + have ht1:t<1:=ht7.trans_lt t7_lt_one + have hI:t∈Ioo (-1:ℝ) 1:=⟨by linarith,ht1⟩ + have hd:0<1-t^2 := by nlinarith + have hf0:0≤f t := by + have hh:=f_strictAnti.antitoneOn ⟨ht0,ht1⟩ ⟨t7_pos.le,t7_lt_one⟩ ht7 + simpa only [f_t7] using hh + have hfall : f t ≤ f (11/25) := f_strictAnti.antitoneOn ⟨by norm_num,by norm_num⟩ ⟨ht0,ht1⟩ ht + have hfp : fp t ≤ fp (11/25) := fp_strictAnti.antitoneOn ⟨by norm_num,by norm_num⟩ ⟨ht0,ht1⟩ ht + have hf:f t≤1/3:=hfall.trans sub_endpoint_bounds.1 + have hp:fp t≤-7/2:=hfp.trans sub_endpoint_bounds.2 + have hq:=qSub_nonneg ht0 + obtain ⟨hqL,hqU⟩:=qSub_bounds ht0 ht7 + have hb:fp t-f t*qSub t≤0 := by nlinarith [mul_nonneg hf0 hq] + have hres:=qSub_deriv_bound ht0 ht1 + have hODE: (1-t^2)*(-6/(1-t^2)^4)=6*t*fp t-6*f t := by + have hh:=f_relation hI + field_simp at hh ⊢ + nlinarith + have hbd : (1-t^2)*(-6/(1-t^2)^4-fp t*qSub t-f t*(gSub2 t/gSub t-(qSub t)^2)) ≥ + 6*t*fp t-6*f t-(1-t^2)*fp t*qSub t- + f t*(6*t*qSub t-(-643/200:ℝ)*(-643/200+5)-(1-t^2)*(qSub t)^2) := by + have hh:=mul_le_mul_of_nonneg_left hres hf0 + nlinarith only [hh,hODE] + have hmul:=mul_le_mul_of_nonpos_left hbd hb + rw [(hasDerivAt_GSub hI).deriv] + have hfirst : (5*t-(1-t^2)*qSub t)*(fp t-f t*qSub t)^2 ≤0 := + mul_nonpos_of_nonpos_of_nonneg (by linarith) (sq_nonneg _) + have hlast : (6.02745:ℝ)*fp t+(11.738775:ℝ)*f t*qSub t≤0 := by + have hmul:=mul_le_mul hf hqU hq (by norm_num : (0:ℝ)≤1/3) + linarith + have hlast2:=mul_nonpos_of_nonneg_of_nonpos hf0 hlast + nlinarith only [hmul,hfirst,hlast2] + +lemma GSub_high {t:ℝ} (ht:11/25≤t) (ht7:t≤t7) : c7≤GSub t := by + have hcont:ContinuousOn GSub (Icc (11/25) t7) := by + intro x hx + exact (hasDerivAt_GSub ⟨by linarith [hx.1],hx.2.trans_lt t7_lt_one⟩).continuousAt.continuousWithinAt + have hanti:AntitoneOn GSub (Icc (11/25) t7) := by + apply antitoneOn_of_deriv_nonpos (convex_Icc _ _) hcont + · intro x hx + rw [interior_Icc] at hx + exact (hasDerivAt_GSub ⟨by linarith [hx.1],hx.2.trans t7_lt_one⟩).differentiableAt.differentiableWithinAt + · intro x hx + rw [interior_Icc] at hx + exact GSub_nonpos_deriv hx.1.le hx.2.le + have he:GSub t7=c7 := by simp [GSub,f_t7,c7] + rw [←he] + exact hanti ⟨ht,ht7⟩ ⟨by linarith [t7_bounds.1],le_rfl⟩ ht7 + +/-- Exact substitute for DSJ's numerical lower-barrier plot in dimension seven. -/ +theorem GSub_ge_c7 {t:ℝ} (ht:0≤t) (ht7:t≤t7) : c7≤GSub t := by + by_cases h:t≤11/25 + · exact GSub_low ht h + · exact GSub_high (le_of_lt (lt_of_not_ge h)) ht7 + +end Bernoulli.DeSilvaJerison + +namespace Bernoulli.DeSilvaJerison +open Axisymmetric InnerProductSpace +open scoped Laplacian ContDiff + +lemma qSub_neg (t:ℝ) : qSub (-t)= -qSub t := by + simp only [qSub,gSub,gSub1,neg_sq] + ring + +lemma GSub_neg (t:ℝ) : GSub (-t)=GSub t := by + rw [GSub,GSub,f_neg,fp_neg_arg,qSub_neg,neg_sq] + ring + +lemma GSub_ge_c7_abs {t:ℝ} (ht:|t|≤t7) : c7≤GSub t := by + have hh:=GSub_ge_c7 (abs_nonneg t) ht + rcases le_total 0 t with hp|hn + · simpa only [abs_of_nonneg hp] using hh + · simpa only [abs_of_nonpos hn,GSub_neg] using hh + +lemma gSub_contDiff {n:WithTop ℕ∞} : ContDiff ℝ n gSub := by + unfold gSub Algebra.g + fun_prop + +/-- Positive superharmonic ground state used by the lower comparison. -/ +def YSub : Space 7 → ℝ := lift axis (-643/200) gSub + +lemma YSub_pos {x:Space 7} (hx:x≠0) : 0 v x-u x) (fun x => V x-G x) → + energy D u G ≤ energy D v V) + {φ : Space d → ℝ} (hφ : Test D φ) : + (∫ x in D, inner ℝ (G x) (φ x • G x+u x • gradient φ x)) = 0 := by + let V : Space d → Space d := fun x => φ x • G x+u x • gradient φ x + have hp : H10 D (fun x => φ x*u x) V := SobolevDensity.h10_mul_test hu hD hφ + obtain ⟨C,hC⟩ := (hφ.1.continuous.norm.bddAbove_range_of_hasCompactSupport hφ.2.1.norm) + have hCB : ∀ x, |φ x| ≤ |C|+1 := by + intro x + have hx := hC (mem_range_self x) + change ‖φ x‖ ≤ C at hx + rw [Real.norm_eq_abs] at hx + linarith [le_abs_self C] + have hCpos : 0 < |C|+1 := by positivity + apply linear_coefficient_eq_zero _ (∫ x in D, ‖V x‖^2) (div_pos (by norm_num : (0:ℝ)<1) hCpos) + intro t ht + have hs : |t| *(|C|+1)<1 := (lt_div_iff₀ hCpos).mp ht + have hf (x : Space d) : 0 < 1+t*φ x := by + have hb : |t*φ x|<1 := by + rw [abs_mul] + exact lt_of_le_of_lt (mul_le_mul_of_nonneg_left (hCB x) (abs_nonneg t)) hs + linarith [neg_abs_le (t*φ x)] + have he (x : Space d) : u x+t*(φ x*u x)=(1+t*φ x)*u x := by ring + have hcontrol : ∀ᵐ x ∂volume.restrict D, + 0 ≤ u x+t*(φ x*u x) ∧ ((0 < u x+t*(φ x*u x)) ↔ 0 < u x) := by + filter_upwards [hn] with x hx + rw [he] + exact ⟨mul_nonneg (hf x).le hx, mul_pos_iff_of_pos_left (hf x)⟩ + have hc := hmin (fun x => u x+t*(φ x*u x)) (fun x => G x+t • V x) + (hu.add (hp.1.const_smul t)) (hcontrol.mono fun _ hx => hx.1) + (by simpa only [add_sub_cancel_left] using hp.const_smul t) + rw [energy_affine hu.1 hu.2.1 hp.1.2.1 t (hcontrol.mono fun _ hx => hx.2)] at hc + linarith + +lemma GlobalMinimizer.outerVariation {u : Space d → ℝ} {L : ℝ≥0} + (hm : GlobalMinimizer u) (huLip : LipschitzWith L u) + {a : Space d} {R : ℝ} (hR : 0 < R) + {φ : Space d → ℝ} (hφ : Test (ball a R) φ) : + (∫ x in ball a R, inner ℝ (gradient u x) + (φ x • gradient u x+u x • gradient φ x)) = 0 := by + let : IsFiniteMeasure (volume.restrict (ball a R)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + obtain ⟨_,G,hG,hn,hmin⟩ := hm + have hu := hG a R hR (subset_univ _) + have he := hu.gradient_unique isOpen_ball (LipschitzSobolev.h1_ball huLip a R) + have hh := outerVariation_of_comparison isOpen_ball hu + (ae_restrict_of_ae (by simpa only [Measure.restrict_univ] using hn)) + (hmin a R hR (subset_univ _)) hφ + rw [← hh] + apply integral_congr_ae + filter_upwards [he] with x hx + rw [hx] +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/MinimizerStationarity.lean b/lean/OAI/Analysis/BernoulliCone/MinimizerStationarity.lean new file mode 100644 index 0000000000000000000000000000000000000000..53cc027a65053b46ac74775c1380948feaca37c1 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/MinimizerStationarity.lean @@ -0,0 +1,65 @@ +import OAI.Analysis.BernoulliCone.StationarityEnergy + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli +open scoped _root_.Bernoulli +variable {d : ℕ} + +lemma GlobalMinimizer.nonneg_of_continuous {u : Space d → ℝ} + (hm : GlobalMinimizer u) (hc : Continuous u) : ∀ x, 0 ≤ u x := by + obtain ⟨_,G,_,hn,_⟩ := hm + simp only [Measure.restrict_univ] at hn + have heq := Measure.eq_of_ae_eq (hn.mono (fun _ hx => max_eq_left hx)) + (hc.max continuous_const) hc + intro x + have hx := congrFun heq x + rw [← hx] + exact le_max_right _ _ + +/-- Compact rank-one domain variations give the Bernoulli stress identity +from unrestricted Sobolev minimality, including the volume term. -/ +theorem GlobalMinimizer.stationarity {u : Space d → ℝ} {L : ℝ≥0} + (hm : GlobalMinimizer u) (huLip : LipschitzWith L u) + {a : Space d} {R : ℝ} (hR : 0 < R) + {φ : Space d → ℝ} (hφ : Test (ball a R) φ) (e : Space d) : + (∫ x in ball a R, Shape.stressTerm u φ e x) = 0 := by + obtain ⟨C,hLip⟩ := ContDiff.lipschitzWith_of_hasCompactSupport hφ.2.1 hφ.1 (by simp) + let I : ℝ := ∫ x in ball a R, Shape.stressTerm u φ e x + let B : ℝ := (2*(L:ℝ)^2*‖e‖^2*(C:ℝ)^2)*(volume (ball a R)).toReal + have hn := hm.nonneg_of_continuous huLip.continuous + have hε : 0 < (4*((C:ℝ)*‖e‖+1))⁻¹ := by positivity + have hz : I/2 = 0 := by + apply linear_coefficient_eq_zero _ B hε + intro t ht + obtain ⟨hK,hdet⟩ := Shape.small_parameter_bounds hφ.1 hLip e ht + let hf := Shape.displacement_lipschitz hLip e t + let g : Space d ≃ₜ Space d := Shape.perturbationHomeomorph hf hK + have hg : ∀ x, g x=Shape.deform φ e t x := fun _ => rfl + let v := fun y => u (g.symm y) + have hvLip := huLip.comp (Shape.perturbationHomeomorph_symm_lipschitz hf hK) + have hsup : tsupport (fun x => v x-u x) ⊆ tsupport φ := + Shape.pullback_diff_support (u:=u) e t g hg + have hc : HasCompactSupport (fun x => v x-u x) := + hφ.2.1.of_isClosed_subset (isClosed_tsupport _) hsup + have hcomp := hm.compare_lipschitz huLip hvLip a hR + (Eventually.of_forall (fun x => hn (g.symm x))) hc (hsup.trans hφ.2.2) + have hupper := Shape.general_energy_pullback_upper huLip hφ.1 hLip e t hdet g hg a R (by + intro x hx + by_contra hh + exact hx (hφ.2.2 (subset_tsupport φ hh))) + change energy (ball a R) v (gradient v) ≤ _ at hupper + have hboth := hcomp.trans hupper + dsimp [B,I] + nlinarith + exact (div_eq_zero_iff).mp hz |>.resolve_right (by norm_num) +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/Model.lean b/lean/OAI/Analysis/BernoulliCone/Model.lean new file mode 100644 index 0000000000000000000000000000000000000000..88b7c8966ca6313ae6e68296d3154a238585be01 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/Model.lean @@ -0,0 +1,84 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff + +namespace Bernoulli +open scoped _root_.Bernoulli + +abbrev Space (d : ℕ) := EuclideanSpace ℝ (Fin d) + +/-- Compactly supported smooth real tests in the open set. -/ +def Test {d : ℕ} (D : Set (Space d)) (φ : Space d → ℝ) : Prop := + ContDiff ℝ ∞ φ ∧ HasCompactSupport φ ∧ tsupport φ ⊆ D + +/-- Distributional gradient, tested in every constant direction. -/ +def WeakGradient {d : ℕ} (D : Set (Space d)) + (u : Space d → ℝ) (G : Space d → Space d) : Prop := + ∀ φ, Test D φ → ∀ h : Space d, + (∫ x in D, u x * (fderiv ℝ φ x) h) = + -(∫ x in D, inner ℝ (G x) h * φ x) + +/-- H¹(D), with its weak gradient. -/ +def H1 {d : ℕ} (D : Set (Space d)) + (u : Space d → ℝ) (G : Space d → Space d) : Prop := + MemLp u 2 (volume.restrict D) ∧ + MemLp G 2 (volume.restrict D) ∧ WeakGradient D u G + +/-- H¹₀(D) is H¹-closure of C∞ compactly supported functions. +Both L² errors tend to zero. This does not restrict competitors to smooth ones. -/ +def H10 {d : ℕ} (D : Set (Space d)) + (u : Space d → ℝ) (G : Space d → Space d) : Prop := + H1 D u G ∧ ∀ ε : ℝ, 0 < ε → ∃ φ : Space d → ℝ, + Test D φ ∧ + eLpNorm (fun x => u x - φ x) 2 (volume.restrict D) < ENNReal.ofReal ε ∧ + eLpNorm (fun x => G x - gradient φ x) 2 (volume.restrict D) < ENNReal.ofReal ε + +/-- Ballwise H¹_loc, on an open set (balls have compact closure inside D). -/ +def H1Loc {d : ℕ} (D : Set (Space d)) + (u : Space d → ℝ) (G : Space d → Space d) : Prop := + ∀ c : Space d, ∀ r : ℝ, 0 < r → Metric.closedBall c r ⊆ D → + H1 (Metric.ball c r) u G + +/-- The exact volume-one Bernoulli energy, not just Dirichlet energy. -/ +def energy {d : ℕ} (D : Set (Space d)) + (u : Space d → ℝ) (G : Space d → Space d) : ℝ := + ∫ x in D, ‖G x‖ ^ 2 + if 0 < u x then (1 : ℝ) else 0 + +/-- Full ballwise local comparison. Competitor and gradient are arbitrary +Sobolev representatives on the ball, with zero-trace difference. -/ +def LocalMinimizer {d : ℕ} (D : Set (Space d)) (u : Space d → ℝ) : Prop := + IsOpen D ∧ ∃ G : Space d → Space d, + H1Loc D u G ∧ (∀ᵐ x ∂volume.restrict D, 0 ≤ u x) ∧ + ∀ c : Space d, ∀ r : ℝ, 0 < r → Metric.closedBall c r ⊆ D → + ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 (Metric.ball c r) v V → + (∀ᵐ x ∂volume.restrict (Metric.ball c r), 0 ≤ v x) → + H10 (Metric.ball c r) (fun x => v x - u x) (fun x => V x - G x) → + energy (Metric.ball c r) u G ≤ energy (Metric.ball c r) v V + +/-- Nonnegative global minimizer, with all centers and all positive radii. -/ +def GlobalMinimizer {d : ℕ} (u : Space d → ℝ) : Prop := + LocalMinimizer Set.univ u + +def OneHomogeneous {d : ℕ} (u : Space d → ℝ) : Prop := + ∀ r : ℝ, 0 < r → ∀ᵐ x ∂volume, u (r • x) = r * u x + +def Nonzero {d : ℕ} (u : Space d → ℝ) : Prop := + ¬ (u =ᵐ[volume] fun _ => 0) + +/-- Flatness is a.e. equality of H¹ representatives. -/ +def Flat {d : ℕ} (u : Space d → ℝ) : Prop := + ∃ e : Space d, ‖e‖ = 1 ∧ ∀ᵐ x ∂volume, u x = max (inner ℝ x e) 0 + +end Bernoulli + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/OuterGeometry.lean b/lean/OAI/Analysis/BernoulliCone/OuterGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c8772f7d9b3191375bc84013a3e487b4a15e295 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/OuterGeometry.lean @@ -0,0 +1,145 @@ +import OAI.Analysis.BernoulliCone.CapFoliation + +namespace OAI + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison +open Axisymmetric + +def gSup2 (t:ℝ) :ℝ := (6+36*t^2+6*t^4)/(1-t^2)^4 +lemma hasDerivAt_gSup1 {t:ℝ} (ht:|t|<1) : HasDerivAt gSup1 (gSup2 t) t := by + have hd:1-t^2≠0 := by obtain ⟨h1,h2⟩:=abs_lt.mp ht; nlinarith + convert! ((((hasDerivAt_id t).const_mul 2).mul + ((hasDerivAt_const t (3:ℝ)).add ((hasDerivAt_id t).pow 2))).div + (((hasDerivAt_const t (1:ℝ)).sub ((hasDerivAt_id t).pow 2)).pow 3) + (pow_ne_zero 3 hd)) using 1 + norm_num only [gSup1,gSup2,id_eq,pow_one,Pi.add_apply,Pi.sub_apply,Pi.pow_apply,Pi.mul_apply] + field_simp [hd] + ring +lemma gSup_contDiffAt {t:ℝ} {n:WithTop ℕ∞} (ht:|t|<1) : ContDiffAt ℝ n gSup t := by + have hd:1-t^2≠0 := by obtain ⟨h1,h2⟩:=abs_lt.mp ht; nlinarith + exact (contDiffAt_const.add (contDiffAt_id.pow 2)).div + ((contDiffAt_const.sub (contDiffAt_id.pow 2)).pow 2) (pow_ne_zero 2 hd) +lemma gSup_equation {t:ℝ} (ht:|t|<1) : (1-t^2)*gSup2 t-6*t*gSup1 t-6*gSup t=0 := by + have hd:1-t^2≠0 := by obtain ⟨h1,h2⟩:=abs_lt.mp ht; nlinarith + unfold gSup2 gSup1 gSup + field_simp [hd] + ring + +def KSup : Space 7→ℝ := lift axis (-2) gSup +def outerSigned (x:Space 7) :ℝ := Zsigned x+capAmplitude*KSup x + +lemma KSup_pos {x:Space 7} (hx:x≠0) (ha:|angle x|<1) :0capAmplitude*KSup y) x := + contDiffAt_const.mul (KSup_contDiffAt hx ha) + have hadd : Δ outerSigned x=Δ Zsigned x+Δ (fun y:Space 7=>capAmplitude*KSup y) x := + (signed_contDiffAt hx ha).laplacian_add hc + have hmul : Δ (fun y:Space 7=>capAmplitude*KSup y) x=capAmplitude*Δ KSup x := + InnerProductSpace.laplacian_smul capAmplitude (KSup_contDiffAt hx ha) + rw [hadd,hmul,signed_laplacian hx ha,KSup_laplacian hx ha] + ring + +lemma polarGradient_inner_radial (x:Space 7) (hx:x≠0) (a b:ℝ) : + inner ℝ x (polarGradient axis x a b)=‖x‖*a := by + have hn:‖x‖≠0:=norm_ne_zero_iff.mpr hx + simp only [polarGradient,inner_add_right,inner_sub_right,real_inner_smul_right, + radial,real_inner_smul_right,real_inner_self_eq_norm_sq] + field_simp + ring +lemma gradient_add' {d:ℕ} {f g:Space d→ℝ} {x:Space d} + (hf:DifferentiableAt ℝ f x) (hg:DifferentiableAt ℝ g x) : + gradient (fun x=>f x+g x) x=gradient f x+gradient g x := by + apply ext_inner_right ℝ + intro v + rw [inner_add_left,inner_gradient_left,inner_gradient_left,inner_gradient_left] + change (fderiv ℝ (f+g) x) v=_ + rw [fderiv_add hf hg] + rfl +lemma outerSigned_radial_defect {x:Space 7} (hx:x≠0) (ha:|angle x|<1) : + outerSigned x-inner ℝ x (gradient outerSigned x)=3*capAmplitude*KSup x := by + have hdz: DifferentiableAt ℝ Zsigned x := (signed_contDiffAt (n:=1) hx ha).differentiableAt (by norm_num) + have hdk: DifferentiableAt ℝ KSup x := (KSup_contDiffAt (n:=1) hx ha).differentiableAt (by norm_num) + have hg:gradient Zsigned x=polarGradient axis x (f (angle x)) (fp (angle x)) := by + have hi:inner ℝ x axis/‖x‖∈Ioo (-1:ℝ) 1:=by simpa only [inner_axis,angle] using (show angle x∈Ioo (-1:ℝ) 1 from abs_lt.mp ha) + rw [Zsigned,(hasGradientAt_lift axis x 1 hx (hasDerivAt_f hi)).gradient] + simp only [Real.rpow_one,div_self (norm_ne_zero_iff.mpr hx),one_smul,one_mul,inner_axis,angle] + change Zsigned x+capAmplitude*KSup x-inner ℝ x (gradient (fun x=>Zsigned x+capAmplitude*KSup x) x)=_ + rw [gradient_add' hdz (hdk.const_mul capAmplitude),gradient_const_mul _ hdk,hg,KSup_gradient hx ha] + simp only [inner_add_right,real_inner_smul_right,polarGradient_inner_radial x hx] + rw [Zsigned_eq] + unfold KSup lift + simp only [inner_axis,angle] + field_simp + ring +lemma outerSigned_radial_defect_pos {x:Space 7} (hx:x≠0) (ha:|angle x|<1) : + 0Zsigned x+capAmplitude*KSup x) x=_ + rw [gradient_add' hdz (hdk.const_mul capAmplitude),gradient_const_mul _ hdk, + Zsigned_gradient hx ha,KSup_gradient hx ha,smul_smul] +lemma outer_zero_coefficient {x:Space 7} (hq:0f y+g y) x=divergence f x+divergence g x := by + have hd : fderiv ℝ (fun y=>f y+g y) x = fderiv ℝ f x + fderiv ℝ g x := + (hf.hasFDerivAt.add hg.hasFDerivAt).fderiv + rw [divergence,hd] + simp only [add_apply,inner_add_right,Finset.sum_add_distrib,divergence] +lemma graphPotential_differentiableAt {A:E×ℝ→E} (hA:ContDiff ℝ 1 A) + {u v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hv:DifferentiableAt ℝ v x) : + DifferentiableAt ℝ (graphPotential A u v) x := by + have hd(w:E→ℝ)(hw:DifferentiableAt ℝ w x): + DifferentiableAt ℝ (fun y:E=>ParametricIntegral.heightPrimitive A (y,w y)) x:= + DifferentiableAt.comp (f:=fun y:E=>(y,w y)) (g:=ParametricIntegral.heightPrimitive A) x + (ParametricIntegral.heightPrimitive_differentiable hA (x,w x)) (differentiableAt_id.prodMk hw) + exact ((hd v hv).sub (hd u hu)).const_smul 2 + +def splitGraphPotential (A B:E×ℝ→E) (u w v:E→ℝ) (x:E):E:= + graphPotential A u w x+graphPotential B w v x + +/-- The moving seam contribution is derived from the two actual graph +primitives. The sign is exactly the extended calibration flux jump. -/ +theorem split_graph_bound {A B:E×ℝ→E} (hA:ContDiff ℝ 1 A) (hB:ContDiff ℝ 1 B) + {u w v:E→ℝ} {x:E} (hu:DifferentiableAt ℝ u x) (hw:DifferentiableAt ℝ w x) + (hv:DifferentiableAt ℝ v x) (huw:u x≤w x) (hwv:w x≤v x) + (hbulkA:∀s∈Icc (u x) (w x),divergence (fun y:E=>A (y,s)) x+ + inner ℝ (A (x,s)) (deriv (fun t:ℝ=>A (x,t)) s)≤0) + (hbulkB:∀s∈Icc (w x) (v x),divergence (fun y:E=>B (y,s)) x+ + inner ℝ (B (x,s)) (deriv (fun t:ℝ=>B (x,t)) s)≤0) + (hjump:‖B (x,w x)‖^2-‖A (x,w x)‖^2- + 2*inner ℝ (B (x,w x)-A (x,w x)) (gradient w x)≤0) : + divergence (splitGraphPotential A B u w v) x≤‖gradient v x‖^2+ + ‖A (x,u x)‖^2-2*inner ℝ (A (x,u x)) (gradient u x) := by + have hiA:=integrated_bulk hA x huw hbulkA + have hiB:=integrated_bulk hB x hwv hbulkB + have hs:0≤‖gradient v x-B (x,v x)‖^2:=sq_nonneg _ + rw [norm_sub_sq_real] at hs + have he:inner ℝ (gradient v x) (B (x,v x))=inner ℝ (B (x,v x)) (gradient v x):=real_inner_comm _ _ + rw [he] at hs + have hj:=hjump + rw [inner_sub_left] at hj + change divergence (fun y=>graphPotential A u w y+graphPotential B w v y) x ≤ _ + rw [divergence_add + (graphPotential_differentiableAt hA hu hw) (graphPotential_differentiableAt hB hw hv), + graph_potential_identity hA hu hw,graph_potential_identity hB hw hv] + linarith +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/PositiveFoliation.lean b/lean/OAI/Analysis/BernoulliCone/PositiveFoliation.lean new file mode 100644 index 0000000000000000000000000000000000000000..338fbc5b2acccefa9cc095fd0ee95725d42a5d17 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/PositiveFoliation.lean @@ -0,0 +1,68 @@ +import OAI.Analysis.BernoulliCone.UpperFamily + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology +namespace Bernoulli.Foliation + +lemma strict_increase_above_zero {f:ℝ→ℝ} {a b:ℝ} (hab:at*f (t⁻¹ • x)) + (f (l⁻¹ • x)-inner ℝ (l⁻¹ • x) (gradient f (l⁻¹ • x))) l := by + have hd:=hf.hasFDerivAt.comp_hasDerivAt l (((hasDerivAt_id l).inv hl).smul_const x) + convert! (hasDerivAt_id l).mul hd using 1 + simp only [Function.comp_apply, Pi.inv_apply, id_eq,one_mul,ContinuousLinearMap.map_smul,smul_eq_mul] + rw [←inner_gradient_left,real_inner_smul_left,real_inner_comm x (gradient f (l⁻¹ • x))] + field_simp + ring +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/PositiveQuotient.lean b/lean/OAI/Analysis/BernoulliCone/PositiveQuotient.lean new file mode 100644 index 0000000000000000000000000000000000000000..601c7ae501a6a747afcf6a57a1e1825383098965 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/PositiveQuotient.lean @@ -0,0 +1,86 @@ +import OAI.Analysis.BernoulliCone.HalfspaceQuotient + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Halfspace +variable {d : ℕ} +/-- The square perspective on the nonnegative cone, with its zero value at +zero denominator. Used on actual admissible Lipschitz variations. -/ +def positiveSquareRatio (v u : Space d → ℝ) (x : Space d) : ℝ := + if 0] (U x),(upperParameter x t)^2] (U x),tκ*Zsigned y):=hn.mono fun y hy=>U_eq_signed_of_pos hy + obtain ⟨hx0,ha⟩:=radiusSq_pos_data (U_pos_radiusSq hx) + rw [gradient,he.fderiv_eq] + exact gradient_const_mul κ ((signed_contDiffAt (n:=1) hx0 ha).differentiableAt (by norm_num)) +lemma normalized_radiusSq_ne_one {x:Space 7} {l:ℝ} (hl:01:=by + rw [inv_pow,←div_eq_inv_mul] + change 1upperFlux (x,t)) (𝓝[>] (U x)) (𝓝 (gradient U x)) := by + have he:(fun t:ℝ=>upperFlux (x,t)) =ᶠ[𝓝[>] (U x)] + (fun t=>κ • gradient Zsigned x+((t-κ*Zsigned x)/KSup x) • gradient KSup x) := by + filter_upwards [upperParameter_eventually_outer hx,self_mem_nhdsWithin] with t hq ht + exact upperFlux_outer_affine ht hq + have hc:ContinuousAt (fun t:ℝ=>κ • gradient Zsigned x+ + ((t-κ*Zsigned x)/KSup x) • gradient KSup x) (U x):=by fun_prop + apply Tendsto.congr' he.symm + simpa only [U_eq_signed_of_pos hx,sub_self,zero_div,zero_smul,add_zero,gradient_U_eq_signed hx] using + hc.tendsto.mono_left nhdsWithin_le_nhds +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/PrimitiveBound.lean b/lean/OAI/Analysis/BernoulliCone/PrimitiveBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad465035d5b7268d86ad5feb47cd9083653af582 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/PrimitiveBound.lean @@ -0,0 +1,179 @@ +import OAI.Analysis.BernoulliCone.ClampedGraphBound + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison +open Foliation + +lemma cap_extension_eventually_eq {K:Set (Space 7×ℝ)} {B:Space 7×ℝ→Space 7} + (hB:∀p∈K,seamHeight p.1≤p.2 → B p=upperFlux p) + {p:Space 7×ℝ} (hp:p∈interior K) (hq:0hAe hz + rw [bulkExpression_congr (he.trans (exteriorFlux_eventually_eq hu hq hs))] + exact upperFlux_bulk_off_seam hu hq (ne_of_gt hs) + +lemma cap_extension_bulk {K:Set (Space 7×ℝ)} {B:Space 7×ℝ→Space 7} + (hBe:∀p∈K,seamHeight p.1≤p.2 → B p=upperFlux p) + {p:Space 7×ℝ} (hp:p∈interior K) (hu:U p.1clampedHeight_le (huv y) + have hpoint (t:ℝ) (ht:t∈Icc (u x) (v x)):(x,t)∈interior K:=hKi ⟨rfl,ht⟩ + by_cases hlt:u xgraphPotential A u w y+graphPotential B w v y) x≤0 + change DifferentiableAt ℝ w x at hdw + rw [divergence_add (graphPotential_differentiableAt hA hdu hdw) (graphPotential_differentiableAt hB hdw hdv), + graph_divergence_zero_contact hA hdu hdw huw hux,graph_divergence_zero_contact hB hdw hdv hwv hwx] + norm_num +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/PrimitiveLocal.lean b/lean/OAI/Analysis/BernoulliCone/PrimitiveLocal.lean new file mode 100644 index 0000000000000000000000000000000000000000..f9719032289673392770aa509b210fa46c81caf2 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/PrimitiveLocal.lean @@ -0,0 +1,97 @@ +import OAI.Analysis.BernoulliCone.VerticalGraphLocalization + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison +open Foliation + +lemma above_U_isOpen : IsOpen {p:Space 7×ℝ|U p.1 + Cylindrical.radiusSq axis ((upperParameter z.1 z.2)⁻¹ • z.1)) p:= + (Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.continuousAt.comp + (((upperParameter_continuousAt hp.1).inv₀ (upperParameter_spec hp.1).1.ne').smul continuous_fst.continuousAt) + exact inter_mem (above_U_isOpen.mem_nhds hp.1) (hq.eventually (gt_mem_nhds hp.2)) + +lemma upperFlux_primitive_axis_lipschitz {u v:Space 7→ℝ} + (hu:LocallyLipschitz u) (hv:LocallyLipschitz v) (huv:∀y,u y≤v y) + (huU:∀y,U y(upperFlux_contDiffAt hp.1 hp.2.ne).of_le (by simp) |>.contDiffWithinAt) + _ upperFlux_intervalIntegrable + intro p hp + have hpx:p.1=x:=hp.1 + change U p.1(seamHeight_contDiffAt hy).of_le (by simp) |>.contDiffWithinAt) + exact ⟨σ,hσ,by simpa using hσe⟩ + +lemma upperFlux_compact_tube {x:Space 7} {a b:ℝ} (hua:U x(hKD hp).1,fun p hp=>(hKD hp).2⟩ + +lemma upperFlux_primitive_offaxis_lipschitz {u v:Space 7→ℝ} + (hu:LocallyLipschitz u) (hv:LocallyLipschitz v) (huv:∀y,u y≤v y) + (huU:∀y,U y rawKernel x*positiveLinear e x + have hc : Continuous F := contDiff_rawKernel.continuous.mul (positiveLinear_lipschitz e).continuous + have hs : HasCompactSupport F := rawKernel_compact.mul_right + have hnonneg : ∀ x, 0 ≤ F x := fun x => mul_nonneg (rawKernel_nonneg x) (le_max_right _ _) + have hn : 0 < ‖e‖ := norm_pos_iff.mpr he + let x := (2*‖e‖)⁻¹ • e + have hxNorm : ‖x‖=(1:ℝ)/2 := by + dsimp [x] + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr (by positivity))] + field_simp + have hxpos : 0 < inner ℝ e x := by + dsimp [x] + rw [real_inner_smul_right,real_inner_self_eq_norm_sq] + positivity + have hxF : F x ≠ 0 := by + exact (mul_pos (kernelProfile_pos (by rw [hxNorm]; norm_num)) + (lt_max_of_lt_left hxpos)).ne' + have hpos : 0 < ∫ y, F y := hc.integral_pos_of_hasCompactSupport_nonneg_nonzero hs hnonneg hxF + have hF : (∫ y in ball (0:Space d) 2, F y) = ∫ y, F y := by + apply setIntegral_eq_integral_of_forall_compl_eq_zero + intro y hy + have h1 : y ∉ closedBall (0:Space d) 1 := fun hh => hy (closedBall_subset_ball (by norm_num) hh) + simp [F,rawKernel_zero h1] + have hid : (∫ y in ball (0:Space d) 2, firstTerm potential e y) = -(∫ y, F y) := by + simp_rw [firstTerm_potential] + rw [show (fun y : Space d => -rawKernel y*positiveLinear e y)=(fun y => -F y) from by funext y; simp [F]] + rw [integral_neg,hF] + rw [hid] + exact neg_ne_zero.mpr hpos.ne' +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/RankOneDeterminant.lean b/lean/OAI/Analysis/BernoulliCone/RankOneDeterminant.lean new file mode 100644 index 0000000000000000000000000000000000000000..eedbe7d39a671a59b73d4cacb081828fe573cca9 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/RankOneDeterminant.lean @@ -0,0 +1,40 @@ +import OAI.Analysis.BernoulliCone.StationarityDensity + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + +lemma rankOneMap_det (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) : + (rankOneMap a e t).det = 1+t*a e := by + classical + let b := Module.finBasis ℝ E + let u := fun i => t * b.repr e i + let v := fun j => a (b j) + have hm : LinearMap.toMatrix b b (rankOneMap a e t).toLinearMap = + 1 + Matrix.replicateCol Unit u * Matrix.replicateRow Unit v := by + ext i j + simp only [LinearMap.toMatrix_apply] + change b.repr (rankOneMap a e t (b j)) i = _ + rw [rankOneMap_apply] + simp [u,v,Matrix.mul_apply,Matrix.one_apply,smul_eq_mul,Finsupp.single_apply] + split_ifs <;> simp_all <;> ring + rw [ContinuousLinearMap.det,← LinearMap.det_toMatrix b,hm, + Matrix.det_one_add_replicateCol_mul_replicateRow] + congr 1 + change (∑ i, a (b i) * (t * b.repr e i)) = t*a e + calc + _ = t * (∑ i, b.repr e i * a (b i)) := by rw [Finset.mul_sum]; congr 1; ext i; ring + _ = t*a (∑ i, b.repr e i • b i) := by simp only [map_sum,map_smul,smul_eq_mul] + _ = _ := by rw [b.sum_repr] +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/RankOnePerturbation.lean b/lean/OAI/Analysis/BernoulliCone/RankOnePerturbation.lean new file mode 100644 index 0000000000000000000000000000000000000000..541b8169097cc03606c6403571208d24df74d254 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/RankOnePerturbation.lean @@ -0,0 +1,63 @@ +import OAI.Analysis.BernoulliCone.SmallPerturbation + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def rankOneMap (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) : E →L[ℝ] E := + ContinuousLinearMap.id ℝ E + t • a.smulRight e + +def rankOneInverse (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) : E →L[ℝ] E := + ContinuousLinearMap.id ℝ E - (t/(1+t*a e)) • a.smulRight e + +@[simp] lemma rankOneMap_apply (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (x : E) : + rankOneMap a e t x = x+(t*a x) • e := by + simp [rankOneMap,smul_smul] +@[simp] lemma rankOneInverse_apply (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (x : E) : + rankOneInverse a e t x = x-((t/(1+t*a e))*a x) • e := by + simp [rankOneInverse,smul_smul] + +lemma rankOne_left_inverse (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) : + Function.LeftInverse (rankOneInverse a e t) (rankOneMap a e t) := by + intro x + rw [rankOneInverse_apply,rankOneMap_apply] + simp only [map_add,map_smul,smul_eq_mul] + have hh : t/(1+t*a e)*(a x+t*a x*a e) = t*a x := by field_simp + rw [hh,add_sub_cancel_right] + +lemma rankOne_right_inverse (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) : + Function.RightInverse (rankOneInverse a e t) (rankOneMap a e t) := by + intro x + rw [rankOneMap_apply,rankOneInverse_apply] + simp only [map_sub,map_smul,smul_eq_mul] + have hh : t*(a x-(t/(1+t*a e)*a x)*a e) = t/(1+t*a e)*a x := by field_simp; ring + rw [hh,sub_add_cancel] + +def rankOneEquiv (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) : E ≃L[ℝ] E := + ContinuousLinearEquiv.equivOfInverse (rankOneMap a e t) (rankOneInverse a e t) + (rankOne_left_inverse a e t h) (rankOne_right_inverse a e t h) + +@[simp] lemma rankOneEquiv_coe (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) : + (rankOneEquiv a e t h : E →L[ℝ] E) = rankOneMap a e t := rfl +@[simp] lemma rankOneEquiv_symm_coe (a : E →L[ℝ] ℝ) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) : + ((rankOneEquiv a e t h).symm : E →L[ℝ] E) = rankOneInverse a e t := rfl + +lemma dual_rankOneInverse (a b : E →L[ℝ] ℝ) (e : E) (t : ℝ) : + b.comp (rankOneInverse a e t) = b - (t*b e/(1+t*a e)) • a := by + ext x + simp only [ContinuousLinearMap.comp_apply,rankOneInverse_apply,map_sub,map_smul, + smul_eq_mul,sub_apply,smul_apply] + ring +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ScalarImplicit.lean b/lean/OAI/Analysis/BernoulliCone/ScalarImplicit.lean new file mode 100644 index 0000000000000000000000000000000000000000..409070d21c1efb11a7005e8f7ef7930e5db68a5a --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ScalarImplicit.lean @@ -0,0 +1,67 @@ +import OAI.Analysis.BernoulliCone.UpperParameter + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff +namespace Bernoulli.Foliation +variable {E : Type uE} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] +lemma real_linear_invertible {L:ℝ→L[ℝ] ℝ} (hL:L 1≠0) :L.IsInvertible := by + have he:∀s:ℝ,L s=s*L 1:=fun s=>by simpa using L.map_smul s (1:ℝ) + let R:ℝ→L[ℝ] ℝ:=(L 1)⁻¹ • ContinuousLinearMap.id ℝ ℝ + apply ContinuousLinearMap.IsInvertible.of_inverse (g:=R) + · apply ContinuousLinearMap.ext + intro s + simp only [ContinuousLinearMap.comp_apply,R,smul_apply, + ContinuousLinearMap.id_apply,smul_eq_mul] + rw [he] + field_simp + · apply ContinuousLinearMap.ext + intro s + simp only [ContinuousLinearMap.comp_apply,R,smul_apply, + ContinuousLinearMap.id_apply,smul_eq_mul] + rw [he] + field_simp + rw [he] + ring +lemma scalar_implicit {F:E×ℝ→ℝ} {x:E} {l ρ:ℝ} + (hF:ContDiffAt ℝ ∞ F (x,l)) (hd:HasDerivAt (fun s:ℝ=>F (x,s)) ρ l) (hρ:ρ≠0) : + ∃ψ:E→ℝ, ContDiffAt ℝ ∞ ψ x ∧ ψ x=l ∧ + ∀ᶠ y in 𝓝 x,F (y,ψ y)=F (x,l) := by + have hc:HasDerivAt (fun s:ℝ=>F (x,s)) ((fderiv ℝ F (x,l)) (0,1)) l := by + exact (hF.differentiableAt (by simp)).hasFDerivAt.comp_hasDerivAt l + ((hasDerivAt_const l x).prodMk (hasDerivAt_id l)) + have hl:(fderiv ℝ F (x,l) ∘L ContinuousLinearMap.inr ℝ E ℝ) 1=ρ := by + simpa using hc.unique hd + have hi:(fderiv ℝ F (x,l) ∘L ContinuousLinearMap.inr ℝ E ℝ).IsInvertible:= + real_linear_invertible (by rw [hl]; exact hρ) + exact ⟨hF.implicitFunction (by simp) hi,hF.contDiffAt_implicitFunction (by simp) hi, + hF.implicitFunction_apply_self (by simp) hi,hF.eventually_apply_implicitFunction (by simp) hi⟩ +/-- The local uniqueness clause of the scalar implicit-function theorem is +needed for a smooth extension up to one side of a genuine seam. -/ +lemma scalar_implicit_unique {F:E×ℝ→ℝ} {x:E} {l ρ:ℝ} + (hF:ContDiffAt ℝ ∞ F (x,l)) (hd:HasDerivAt (fun s:ℝ=>F (x,s)) ρ l) (hρ:ρ≠0) : + ∃ψ:E→ℝ, ContDiffAt ℝ ∞ ψ x ∧ ψ x=l ∧ + (∀ᶠ y in 𝓝 x,F (y,ψ y)=F (x,l)) ∧ + ∀ᶠ z in 𝓝 (x,l), F z=F (x,l) ↔ ψ z.1=z.2 := by + have hc:HasDerivAt (fun s:ℝ=>F (x,s)) ((fderiv ℝ F (x,l)) (0,1)) l := + (hF.differentiableAt (by simp)).hasFDerivAt.comp_hasDerivAt l + ((hasDerivAt_const l x).prodMk (hasDerivAt_id l)) + have hl:(fderiv ℝ F (x,l) ∘L ContinuousLinearMap.inr ℝ E ℝ) 1=ρ := by + simpa using hc.unique hd + have hi:(fderiv ℝ F (x,l) ∘L ContinuousLinearMap.inr ℝ E ℝ).IsInvertible:= + real_linear_invertible (by rw [hl]; exact hρ) + exact ⟨hF.implicitFunction (by simp) hi,hF.contDiffAt_implicitFunction (by simp) hi, + hF.implicitFunction_apply_self (by simp) hi, + hF.eventually_apply_implicitFunction (by simp) hi, + hF.eventually_apply_eq_iff_implicitFunction (by simp) hi⟩ +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ScalarLaplacian.lean b/lean/OAI/Analysis/BernoulliCone/ScalarLaplacian.lean new file mode 100644 index 0000000000000000000000000000000000000000..b7ae5ba31741aa169f34b10cc96fc19c9a6c7294 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ScalarLaplacian.lean @@ -0,0 +1,113 @@ +import OAI.Analysis.BernoulliCone.LowerSupport + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter Finset +open scoped Topology ContDiff Laplacian +namespace Bernoulli.ScalarLaplacian +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma deriv2_mul {f g : ℝ → ℝ} {t:ℝ} + (hf:ContDiffAt ℝ 2 f t) (hg:ContDiffAt ℝ 2 g t) : + deriv (deriv (fun s=>f s*g s)) t = + deriv (deriv f) t*g t+2*deriv f t*deriv g t+f t*deriv (deriv g) t := by + have hf' := (hf.derivWithin (m:=1) (by norm_num)).differentiableAt (by norm_num) + have hg' := (hg.derivWithin (m:=1) (by norm_num)).differentiableAt (by norm_num) + have he : deriv (fun s=>f s*g s) =ᶠ[𝓝 t] fun s=>deriv f s*g s+f s*deriv g s := by + filter_upwards [hf.eventually (by norm_num),hg.eventually (by norm_num)] with s hs ht + exact deriv_mul (hs.differentiableAt (by norm_num)) (ht.differentiableAt (by norm_num)) + rw [he.deriv_eq] + have hh := (hf'.hasDerivAt.mul (hg.differentiableAt (by norm_num)).hasDerivAt).add + ((hf.differentiableAt (by norm_num)).hasDerivAt.mul hg'.hasDerivAt) + change deriv (deriv f*g+f*deriv g) t = _ + rw [hh.deriv] + ring + +lemma line_deriv {f:E→ℝ} {x:E} (hf:DifferentiableAt ℝ f x) (v:E) : + deriv (fun t:ℝ=>f (x+t • v)) 0 = inner ℝ (gradient f x) v := by + have hl : HasDerivAt (fun t:ℝ=>x+t • v) v 0 := by + simpa using ((hasDerivAt_id (0:ℝ)).smul_const v).const_add x + have hfx : HasFDerivAt f (fderiv ℝ f x) (x+(0:ℝ) • v) := by simpa using hf.hasFDerivAt + simpa only [Function.comp_def,inner_gradient_left] using (hfx.comp_hasDerivAt 0 hl).deriv + +lemma gradient_mul {f g:E→ℝ} {x:E} (hf:DifferentiableAt ℝ f x) + (hg:DifferentiableAt ℝ g x) : + gradient (fun y=>f y*g y) x = g x • gradient f x + f x • gradient g x := by + apply ext_inner_right ℝ + intro v + rw [inner_add_left,real_inner_smul_left,real_inner_smul_left,inner_gradient_left, + inner_gradient_left,inner_gradient_left] + change (fderiv ℝ (f*g) x) v = _ + rw [(hf.hasFDerivAt.mul hg.hasFDerivAt).fderiv] + simp only [add_apply,smul_apply,smul_eq_mul] + ring + +lemma gradient_comp {φ:ℝ→ℝ} {f:E→ℝ} {x:E} (hφ:DifferentiableAt ℝ φ (f x)) + (hf:DifferentiableAt ℝ f x) : + gradient (fun y=>φ (f y)) x = deriv φ (f x) • gradient f x := by + apply ext_inner_right ℝ + intro v + change inner ℝ (gradient (φ ∘ f) x) v = _ + rw [inner_gradient_left,fderiv_comp x hφ hf,ContinuousLinearMap.comp_apply, + fderiv_eq_deriv_mul,real_inner_smul_left,inner_gradient_left] + +lemma laplacian_sum_line {f:E→ℝ} {x:E} (hf:ContDiffAt ℝ 2 f x) : + Δ f x = ∑ i, deriv (deriv (fun t:ℝ=>f (x+t • stdOrthonormalBasis ℝ E i))) 0 := by + rw [InnerProductSpace.laplacian_eq_iteratedFDeriv_stdOrthonormalBasis] + simp_rw [iteratedFDeriv_two_apply] + simp only [Fin.isValue,Matrix.cons_val_zero,Matrix.cons_val_one] + simp_rw [Axisymmetric.line_second_derivative hf] + +lemma laplacian_mul {f g:E→ℝ} {x:E} (hf:ContDiffAt ℝ 2 f x) + (hg:ContDiffAt ℝ 2 g x) : + Δ (fun y=>f y*g y) x = g x*Δ f x+2*inner ℝ (gradient f x) (gradient g x)+f x*Δ g x := by + let b := stdOrthonormalBasis ℝ E + have hfL (v:E) : ContDiffAt ℝ 2 (fun t:ℝ=>f (x+t • v)) 0 := by + have hh : ContDiffAt ℝ 2 (fun t:ℝ=>x+t • v) 0 := contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const) + exact (show ContDiffAt ℝ 2 f (x+(0:ℝ) • v) by simpa using hf).comp 0 hh + have hgL (v:E) : ContDiffAt ℝ 2 (fun t:ℝ=>g (x+t • v)) 0 := by + have hh : ContDiffAt ℝ 2 (fun t:ℝ=>x+t • v) 0 := contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const) + exact (show ContDiffAt ℝ 2 g (x+(0:ℝ) • v) by simpa using hg).comp 0 hh + rw [laplacian_sum_line (hf.mul hg),laplacian_sum_line hf,laplacian_sum_line hg] + simp_rw [deriv2_mul (hfL _) (hgL _),zero_smul,add_zero, + line_deriv (hf.differentiableAt (by norm_num)),line_deriv (hg.differentiableAt (by norm_num))] + simp_rw [Finset.sum_add_distrib,←Finset.sum_mul,←Finset.mul_sum,mul_assoc] + have hc : (∑ i,inner ℝ (gradient f x) (b i)*inner ℝ (gradient g x) (b i))= + inner ℝ (gradient f x) (gradient g x) := by + convert b.sum_inner_mul_inner (gradient f x) (gradient g x) using 1 + apply Finset.sum_congr rfl + intro i hi + rw [real_inner_comm (gradient g x) (b i)] + dsimp only [b] at hc + rw [←Finset.mul_sum,hc] + ring + +lemma laplacian_comp {φ:ℝ→ℝ} {f:E→ℝ} {x:E} (hφ:ContDiffAt ℝ 2 φ (f x)) + (hf:ContDiffAt ℝ 2 f x) : + Δ (fun y=>φ (f y)) x = deriv (deriv φ) (f x)*‖gradient f x‖^2 + deriv φ (f x)*Δ f x := by + let b := stdOrthonormalBasis ℝ E + have he (v:E) : deriv (deriv (fun t:ℝ=>φ (f (x+t • v)))) 0 = + deriv (deriv φ) (f x)*(inner ℝ (gradient f x) v)^2+ + deriv φ (f x)*deriv (deriv (fun t:ℝ=>f (x+t • v))) 0 := by + have hfL : ContDiffAt ℝ 2 (fun t:ℝ=>f (x+t • v)) 0 := by + have hh : ContDiffAt ℝ 2 (fun t:ℝ=>x+t • v) 0 := contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const) + exact (show ContDiffAt ℝ 2 f (x+(0:ℝ) • v) by simpa using hf).comp 0 hh + have hh := iteratedDeriv_comp_two (show ContDiffAt ℝ 2 φ (f (x+(0:ℝ) • v)) by simpa using hφ) hfL + simpa only [iteratedDeriv_succ,iteratedDeriv_zero,Function.comp_def,zero_smul,add_zero, + line_deriv (hf.differentiableAt (by norm_num))] using hh + change Δ (φ ∘ f) x = _ + rw [laplacian_sum_line (hφ.comp x hf),laplacian_sum_line hf] + simp only [Function.comp_apply] + simp_rw [he,Finset.sum_add_distrib,←Finset.mul_sum] + rw [b.sum_sq_inner_left] +end Bernoulli.ScalarLaplacian + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SeamCalibration.lean b/lean/OAI/Analysis/BernoulliCone/SeamCalibration.lean new file mode 100644 index 0000000000000000000000000000000000000000..433d102b71859800fce6a6dd1c7fe823053abe54 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SeamCalibration.lean @@ -0,0 +1,113 @@ +import OAI.Analysis.BernoulliCone.FoliationSeam + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison +open Axisymmetric +lemma polarGradient_span (x:Space 7) (a b:ℝ) : + ∃c d:ℝ,polarGradient axis x a b=c • axis+d • x := by + refine ⟨b,(a-b*(inner ℝ x axis/‖x‖))*‖x‖⁻¹,?_⟩ + unfold polarGradient radial + module +lemma outerGradient_span {x:Space 7} (hq:0Zsigned x+capAmplitude*KSup x) x=a • axis+b • x + rw [gradient_add' hdz (hdk.const_mul capAmplitude),gradient_const_mul _ hdk,hz, + KSup_gradient hx ha,hab,hcd] + refine ⟨a+capAmplitude*(‖x‖^(-2:ℝ)/‖x‖)*c,b+capAmplitude*(‖x‖^(-2:ℝ)/‖x‖)*d,?_⟩ + module +lemma cylindrical_projection {x G:Space 7} (hq:Cylindrical.radiusSq axis x=1) + (hG:∃a b:ℝ,G=a • axis+b • x) : + G=inner ℝ G axis • axis+inner ℝ G (Cylindrical.transverse axis x) • Cylindrical.transverse axis x := by + obtain ⟨a,b,hab⟩:=hG + have hn:inner ℝ (Cylindrical.transverse axis x) axis=0:=Cylindrical.transverse_inner axis x axis_norm + have hn':inner ℝ axis (Cylindrical.transverse axis x)=0:=by rw [real_inner_comm,hn] + have hnn:inner ℝ (Cylindrical.transverse axis x) (Cylindrical.transverse axis x)=1:=by + rw [real_inner_self_eq_norm_sq,Cylindrical.transverse_sq axis x axis_norm,hq] + have hg:G=(a+b*Cylindrical.axis axis x) • axis+b • Cylindrical.transverse axis x:=by + rw [hab,Cylindrical.transverse] + module + rw [hg] + simp only [inner_add_left,real_inner_smul_left,hn,hn',hnn,mul_zero,mul_one,zero_add,add_zero, + real_inner_self_eq_norm_sq,axis_norm,one_pow] + +lemma smoothCap_gradient_at_seam {x:Space 7} (hq:Cylindrical.radiusSq axis x=1) : + gradient smoothCap x=capHP (Cylindrical.axis axis x) • axis+ + (capEta*capH (Cylindrical.axis axis x)- + capP*Cylindrical.axis axis x*capHP (Cylindrical.axis axis x)) • Cylindrical.transverse axis x := by + rw [gradient_smoothCap (le_of_eq hq)] + simp only [hq,CapAlgebra.V_one,CapAlgebra.Y_one,CapAlgebra.D_one,CapAlgebra.Y1_one, + div_one,one_pow,inv_one,one_mul] + module +lemma outer_gradient_at_seam {x:Space 7} (hq:Cylindrical.radiusSq axis x=1) : + gradient outerSigned x=capHP (Cylindrical.axis axis x) • axis+ + (capH (Cylindrical.axis axis x)-Cylindrical.axis axis x*capHP (Cylindrical.axis axis x)- + 3*capAmplitude*(1+2*(Cylindrical.axis axis x)^2)) • Cylindrical.transverse axis x := by + rw [cylindrical_projection hq (outerGradient_span (by rw [hq]; norm_num)), + outerSigned_axis_at_seam hq,outerSigned_transverse_at_seam hq] +/-- Tangential matching gives the gradient of the one-homogeneous seam height. -/ +def seamGradient (x:Space 7) : Space 7 := + capHP (Cylindrical.axis axis x) • axis+ + (capH (Cylindrical.axis axis x)-Cylindrical.axis axis x*capHP (Cylindrical.axis axis x)) • + Cylindrical.transverse axis x +lemma seamGradient_matching {x G:Space 7} (hq:Cylindrical.radiusSq axis x=1) + {b:ℝ} (hg:G=capHP (Cylindrical.axis axis x) • axis+b • Cylindrical.transverse axis x) : + seamGradient x=G+(capH (Cylindrical.axis axis x)-inner ℝ x G) • Cylindrical.transverse axis x := by + have hn:inner ℝ x (Cylindrical.transverse axis x)=1:=by + rw [Cylindrical.transverse,inner_sub_right,real_inner_smul_right,real_inner_self_eq_norm_sq] + change ‖x‖^2-Cylindrical.axis axis x*Cylindrical.axis axis x=1 + simpa only [Cylindrical.radiusSq,pow_two] using hq + rw [hg] + simp only [inner_add_right,real_inner_smul_right,hn,mul_one] + change seamGradient x=_ + unfold seamGradient Cylindrical.axis + module + +/-- The actual cap/exterior calibration has the required nonpositive seam flux. +This verifies the jump, rather than inserting a comparison premise. -/ +theorem upperCalibration_seam {x:Space 7} (hq:Cylindrical.radiusSq axis x=1) + (hp:0(Real.sqrt q)⁻¹) capH x +lemma seamHeight_formula (x:Space 7): + seamHeight x=κ*Real.sqrt (Cylindrical.radiusSq axis x)* + capH (Cylindrical.axis axis x/Real.sqrt (Cylindrical.radiusSq axis x)) := by + simp only [seamHeight,Cylindrical.lift,div_eq_mul_inv,mul_assoc] +lemma seamHeight_contDiffAt {x:Space 7} (hq:0(Real.sqrt q)⁻¹) capH) x := + Cylindrical.contDiffAt_lift hs (hs.inv (Real.sqrt_pos.mpr hq).ne') capH_contDiff.contDiffAt + exact contDiffAt_const.mul hL +lemma transverse_smul (a:ℝ) (x:Space 7): + Cylindrical.transverse axis (a • x)=a • Cylindrical.transverse axis x := by + rw [Cylindrical.transverse,Cylindrical.transverse,Cylindrical.axis_smul] + module +lemma gradient_seamHeight {x:Space 7} (hq:0(Real.sqrt q)⁻¹) (-(1/(2*r))/r^2) q:=hs.inv hr.ne' + have hh:=hasDerivAt_capH (z*r⁻¹) + have hl:=Cylindrical.gradient_lift (e:=axis) hs.differentiableAt hi.differentiableAt hh.differentiableAt + change gradient (fun y=>κ*Cylindrical.lift axis Real.sqrt (fun q:ℝ=>(Real.sqrt q)⁻¹) capH y) x=_ + have hL:DifferentiableAt ℝ (Cylindrical.lift axis Real.sqrt (fun q:ℝ=>(Real.sqrt q)⁻¹) capH) x := + (Cylindrical.contDiffAt_lift (Real.contDiffAt_sqrt hq.ne' : ContDiffAt ℝ 1 Real.sqrt q) + ((Real.contDiffAt_sqrt hq.ne').inv hr.ne') (capH_contDiff.of_le (by simp)).contDiffAt).differentiableAt (by norm_num) + rw [gradient_const_mul κ hL,hl] + congr 1 + rw [hs.deriv,hi.deriv,hh.deriv] + simp only [seamGradient,Cylindrical.axis_smul,transverse_smul] + change (2*(1/(2*r))*capH (z*r⁻¹)) • Cylindrical.transverse axis x+ + (r*capHP (z*r⁻¹)) • (r⁻¹ • axis+(2*z*(-(1/(2*r))/r^2)) • Cylindrical.transverse axis x)= + capHP (r⁻¹*z) • axis+(capH (r⁻¹*z)-r⁻¹*z*capHP (r⁻¹*z)) • (r⁻¹ • Cylindrical.transverse axis x) + rw [mul_comm z r⁻¹] + simp only [smul_add,smul_smul] + have he1:r*capHP (r⁻¹*z)*r⁻¹=capHP (r⁻¹*z):=by field_simp + have he2:2*(1/(2*r))*capH (r⁻¹*z)+r*capHP (r⁻¹*z)*(2*z*(-(1/(2*r))/r^2))= + (capH (r⁻¹*z)-r⁻¹*z*capHP (r⁻¹*z))*r⁻¹:=by field_simp; ring + rw [he1] + calc + _=capHP (r⁻¹*z) • axis+ + (2*(1/(2*r))*capH (r⁻¹*z)+r*capHP (r⁻¹*z)*(2*z*(-(1/(2*r))/r^2))) • Cylindrical.transverse axis x := by module + _=_:=by rw [he2] + +lemma normalized_radius_seam {x:Space 7} (hq:0 (t*φ x) • e) := by + apply LipschitzWith.of_dist_le_mul + intro x y + have hh := hφ.dist_le_mul x y + simp only [dist_eq_norm] at hh ⊢ + rw [← sub_smul,← mul_sub,norm_smul,norm_mul] + exact (by simpa only [NNReal.coe_mul,coe_nnnorm,mul_assoc,mul_left_comm,mul_comm] using + mul_le_mul_of_nonneg_left hh (mul_nonneg (norm_nonneg t) (norm_nonneg e))) + +lemma hasFDerivAt_deform {φ : E → ℝ} {a : E →L[ℝ] ℝ} {x : E} + (hφ : HasFDerivAt φ a x) (e : E) (t : ℝ) : + HasFDerivAt (deform φ e t) (rankOneMap a e t) x := by + have h := (hasFDerivAt_id x).add ((hφ.const_smul t).smul_const e) + convert h using 1 + · rfl + · ext y + simp [rankOneMap,smul_smul] + +lemma inverse_hasFDerivAt_deform {φ : E → ℝ} {a : E →L[ℝ] ℝ} {x : E} + (hφ : HasFDerivAt φ a x) (e : E) (t : ℝ) (h : 1+t*a e ≠ 0) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) : + HasFDerivAt g.symm (rankOneInverse a e t) (g x) := by + have hf : HasFDerivAt g (rankOneMap a e t) x := by + convert hasFDerivAt_deform hφ e t using 1 + exact funext hg + have hs := HasFDerivAt.of_local_left_inverse (g.symm.continuous.continuousAt (x:=g x)) + (f':=rankOneEquiv a e t h) (by simpa using hf) + (Eventually.of_forall g.apply_symm_apply) + simpa using hs + +omit [NormedSpace ℝ E] in +lemma image_eq_of_fixed_compl (g : E ≃ₜ E) (s : Set E) + (hg : ∀ x ∉ s, g x=x) : g '' s=s := by + ext x + constructor + · rintro ⟨y,hy,rfl⟩ + by_contra hx + have h := hg (g y) hx + have hh := g.injective h + rw [hh] at hx + exact hx hy + · intro hx + refine ⟨g.symm x,?_,g.apply_symm_apply x⟩ + by_contra hy + have h := hg (g.symm x) hy + rw [g.apply_symm_apply] at h + exact hy (h ▸ hx) + +omit [NormedSpace ℝ E] in +lemma inv_fixed_of_fixed (g : E ≃ₜ E) {x : E} (hx : g x=x) : g.symm x=x := by + apply g.injective + simpa using hx.symm + +lemma pullback_diff_support {φ u : E → ℝ} (e : E) (t : ℝ) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) : + tsupport (fun x => u (g.symm x)-u x) ⊆ tsupport φ := by + apply closure_minimal _ isClosed_closure + intro x hx + apply subset_tsupport + intro hφ + have hfixed : g x=x := by rw [hg]; simp [deform,hφ] + have hh := inv_fixed_of_fixed g hfixed + exact hx (by simp [hh]) +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SmallPerturbation.lean b/lean/OAI/Analysis/BernoulliCone/SmallPerturbation.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ab80700cce9e1b7068bfcabec6b66a1a3af1b7e --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SmallPerturbation.lean @@ -0,0 +1,90 @@ +import OAI.Analysis.BernoulliCone.HarmonicWeakLaplacian + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology NNReal +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [CompleteSpace E] + +omit [CompleteSpace E] in +lemma perturbation_lower {K : ℝ≥0} {f : E → E} (hf : LipschitzWith K f) + (x y : E) : (1-(K:ℝ))*‖x-y‖ ≤ ‖(x+f x)-(y+f y)‖ := by + have hh := norm_sub_le ((x+f x)-(y+f y)) (f x-f y) + have hi : ((x+f x)-(y+f y))-(f x-f y) = x-y := by abel + rw [hi] at hh + have h := hf.dist_le_mul x y + rw [dist_eq_norm,dist_eq_norm] at h + nlinarith + +lemma perturbation_bijective {K : ℝ≥0} {f : E → E} (hf : LipschitzWith K f) + (hK : K < 1) : Function.Bijective (fun x => x+f x) := by + have hK' : (K:ℝ) < 1 := hK + constructor + · intro x y h + have hh := perturbation_lower hf x y + change x+f x = y+f y at h + rw [h,sub_self,norm_zero] at hh + have hn : ‖x-y‖ = 0 := by nlinarith [norm_nonneg (x-y)] + exact sub_eq_zero.mp (norm_eq_zero.mp hn) + · intro z + have hc : ContractingWith K (fun x => z-f x) := by + refine ⟨hK,LipschitzWith.of_dist_le_mul ?_⟩ + intro x y + simpa only [dist_sub_left] using hf.dist_le_mul x y + let x := ContractingWith.fixedPoint (fun x => z-f x) hc + have hh : z-f x=x := hc.fixedPoint_isFixedPt + use x + exact (eq_sub_iff_add_eq.mp hh.symm) + +/-- A small globally Lipschitz perturbation of the identity is an actual +bi-Lipschitz homeomorphism, obtained by the contraction theorem. -/ +def perturbationHomeomorph {K : ℝ≥0} {f : E → E} (hf : LipschitzWith K f) + (hK : K < 1) : E ≃ₜ E := by + let e := Equiv.ofBijective (fun x => x+f x) (perturbation_bijective hf hK) + have hK' : 0 < 1-(K:ℝ) := sub_pos.mpr hK + have hinv : LipschitzWith ⟨(1-(K:ℝ))⁻¹,(inv_pos.mpr hK').le⟩ e.symm := by + apply LipschitzWith.of_dist_le_mul + intro x y + have hh := perturbation_lower hf (e.symm x) (e.symm y) + change (1-(K:ℝ))*‖e.symm x-e.symm y‖ ≤ ‖e (e.symm x)-e (e.symm y)‖ at hh + rw [e.apply_symm_apply,e.apply_symm_apply] at hh + simp only [dist_eq_norm] + change ‖e.symm x-e.symm y‖ ≤ (1-(K:ℝ))⁻¹*‖x-y‖ + rw [inv_mul_eq_div] + exact (le_div_iff₀ hK').mpr (by simpa only [mul_comm] using hh) + exact ⟨e,continuous_id.add hf.continuous,hinv.continuous⟩ + +@[simp] lemma perturbationHomeomorph_apply {K : ℝ≥0} {f : E → E} (hf : LipschitzWith K f) + (hK : K < 1) (x : E) : perturbationHomeomorph hf hK x = x+f x := rfl + +lemma perturbationHomeomorph_symm_lipschitz {K : ℝ≥0} {f : E → E} + (hf : LipschitzWith K f) (hK : K < 1) : + LipschitzWith ⟨(1-(K:ℝ))⁻¹,(inv_pos.mpr (sub_pos.mpr hK : 0 < 1-(K:ℝ))).le⟩ + (perturbationHomeomorph hf hK).symm := by + apply LipschitzWith.of_dist_le_mul + intro x y + let e := perturbationHomeomorph hf hK + have hh := perturbation_lower hf (e.symm x) (e.symm y) + change (1-(K:ℝ))*‖e.symm x-e.symm y‖ ≤ ‖e (e.symm x)-e (e.symm y)‖ at hh + rw [e.apply_symm_apply,e.apply_symm_apply] at hh + simp only [dist_eq_norm] + change ‖e.symm x-e.symm y‖ ≤ (1-(K:ℝ))⁻¹*‖x-y‖ + rw [inv_mul_eq_div] + exact (le_div_iff₀ (sub_pos.mpr hK : 0 < 1-(K:ℝ))).mpr (by simpa only [mul_comm] using hh) + +lemma perturbationHomeomorph_symm_fixed {K : ℝ≥0} {f : E → E} + (hf : LipschitzWith K f) (hK : K < 1) {x : E} (hx : f x=0) : + (perturbationHomeomorph hf hK).symm x=x := by + apply (perturbationHomeomorph hf hK).injective + simp [hx] +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SmoothIntervalPrimitive.lean b/lean/OAI/Analysis/BernoulliCone/SmoothIntervalPrimitive.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b1202d24b5fe15eedca47d933a7ac8e034fb9f4 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SmoothIntervalPrimitive.lean @@ -0,0 +1,44 @@ +import OAI.Analysis.BernoulliCone.PiecewiseFoliationGraph + +namespace OAI + +universe uE uG + +section +noncomputable section +open MeasureTheory Set Filter +open scoped Topology ContDiff +namespace Bernoulli.ParametricIntegral +variable {E : Type uE} {G : Type uG} [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + [NormedAddCommGroup G] [NormedSpace ℝ G] [CompleteSpace G] + +omit [CompleteSpace G] in +lemma fixed_contDiff_one [CompleteSpace G] {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) : + ContDiff ℝ 1 (fun x:E=>∫t in (0:ℝ)..1,F (x,t)) := by + let D:E×ℝ→E→L[ℝ] G:=fun p=>fderiv ℝ F p ∘L ContinuousLinearMap.inl ℝ E ℝ + have hD:Continuous D:=(hF.continuous_fderiv (by norm_num)).clm_comp continuous_const + have hc:Continuous (fun x:E=>∫t in Icc (0:ℝ) 1,D (x,t)):= + continuous_parametric_integral_of_continuous hD isCompact_Icc + have he: (fun x:E=>∫t in Icc (0:ℝ) 1,D (x,t))= + (fun x:E=>∫t in (0:ℝ)..1,D (x,t)) := by + ext x + rw [intervalIntegral.integral_of_le (by norm_num : (0:ℝ)≤1),integral_Icc_eq_integral_Ioc] + rw [he] at hc + exact contDiff_one_iff_hasFDerivAt.mpr ⟨_,hc,fun x=>fixed_hasFDerivAt hF x 0 1⟩ + +lemma heightPrimitive_contDiff_one {F:E×ℝ→G} (hF:ContDiff ℝ 1 F) : + ContDiff ℝ 1 (heightPrimitive F) := by + let B:(E×ℝ)×ℝ→G:=fun z=>z.1.2 • F (z.1.1,z.2*z.1.2) + have hB:ContDiff ℝ 1 B:=by + have hm:ContDiff ℝ 1 (fun z:(E×ℝ)×ℝ=>(z.1.1,z.2*z.1.2)):=by fun_prop + exact (contDiff_fst.snd).smul (hF.comp hm) + have he:heightPrimitive F=(fun y:E×ℝ=>∫s in (0:ℝ)..1,B (y,s)):= + funext (heightPrimitive_rescale F) + rw [he] + exact fixed_contDiff_one hB +end Bernoulli.ParametricIntegral + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SmoothLocalizedExtension.lean b/lean/OAI/Analysis/BernoulliCone/SmoothLocalizedExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..f35086e6a566b08ac34d4b4e9ca0beaf90f11a52 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SmoothLocalizedExtension.lean @@ -0,0 +1,54 @@ +import OAI.Analysis.BernoulliCone.ClosedGermExtension + +namespace OAI + +universe uE uG + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Manifold +namespace Bernoulli.LocalExtension +variable {E : Type uE} {G : Type uG} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup G] [NormedSpace ℝ G] +lemma exists_cutoff {K D:Set E} (hK:IsCompact K) (hD:IsOpen D) (hKD:K⊆D) : + ∃φ:E→ℝ,ContDiff ℝ ∞ φ ∧ HasCompactSupport φ ∧ tsupport φ⊆D ∧ + (∀ᶠ x in 𝓝ˢ K,φ x=1) := by + obtain ⟨δ,hδ,hδD⟩:=hK.exists_thickening_subset_open hD hKD + have hki:K⊆interior (Metric.cthickening (δ/2) K):= + (Metric.self_subset_thickening (half_pos hδ) _).trans + (Metric.thickening_subset_interior_cthickening _ _) + obtain ⟨φ,hφ1,hφ0,hφb⟩:=exists_contMDiffMap_one_nhds_of_subset_interior + (𝓘(ℝ,E)) (n:=⊤) hK.isClosed hki + refine ⟨φ,φ.contMDiff.contDiff,HasCompactSupport.intro hK.cthickening hφ0,?_,hφ1⟩ + have hs:tsupport (φ:E→ℝ)⊆Metric.cthickening (δ/2) K:=by + apply closure_minimal _ Metric.isClosed_cthickening + intro x hx + by_contra hn + exact hx (hφ0 x hn) + exact hs.trans ((Metric.cthickening_subset_thickening' hδ (by linarith) _).trans hδD) + +/-- A compact part of a genuinely smooth open domain admits a global smooth +representative. This permits use of global calculus only after verifying the +actual local hypotheses. -/ +lemma exists_contDiff_extension {n:ℕ∞} {F:E→G} {K D:Set E} + (hK:IsCompact K) (hD:IsOpen D) (hKD:K⊆D) (hF:ContDiffOn ℝ n F D) : + ∃B:E→G,ContDiff ℝ n B ∧ B =ᶠ[𝓝ˢ K] F := by + obtain ⟨φ,hφ,hφc,hφD,hφ1⟩:=exists_cutoff hK hD hKD + refine ⟨fun x=>φ x • F x,?_,?_⟩ + · rw [contDiff_iff_contDiffAt] + intro x + by_cases hx:x∈D + · exact (hφ.of_le (m:=n) (by exact_mod_cast (le_top : n≤⊤))).contDiffAt.smul (hF.contDiffAt (hD.mem_nhds hx)) + · have hxt:x∉tsupport φ:=fun h=>hx (hφD h) + apply (contDiffAt_const (c:=(0:G))).congr_of_eventuallyEq + filter_upwards [notMem_tsupport_iff_eventuallyEq.1 hxt] with y hy + simp [hy] + · filter_upwards [hφ1] with x hx + simp [hx] +end Bernoulli.LocalExtension + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SobolevCalculus.lean b/lean/OAI/Analysis/BernoulliCone/SobolevCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..c484ab4b3a7bc29b563bef210a52b96503e8566c --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SobolevCalculus.lean @@ -0,0 +1,2035 @@ +import OAI.Analysis.BernoulliCone.Model + +namespace OAI + +universe uα uE uF uK uι + +section + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff + +namespace Bernoulli +open scoped _root_.Bernoulli + +namespace Test + +variable {d : ℕ} {D : Set (Space d)} {φ : Space d → ℝ} + +theorem continuous_gradient (hφ : Test D φ) : Continuous (gradient φ) := by + exact (InnerProductSpace.toDual ℝ (Space d)).symm.continuous.comp + (hφ.1.continuous_fderiv (by simp)) + +theorem compact_gradient (hφ : Test D φ) : HasCompactSupport (gradient φ) := by + exact (hφ.2.1.fderiv ℝ).comp_left (map_zero (InnerProductSpace.toDual ℝ (Space d)).symm) + +theorem memLp (hφ : Test D φ) : MemLp φ 2 (volume.restrict D) := by + exact MemLp.mono_measure Measure.restrict_le_self + (hφ.1.continuous.memLp_of_hasCompactSupport hφ.2.1) + +theorem memLp_gradient (hφ : Test D φ) : + MemLp (gradient φ) 2 (volume.restrict D) := by + exact MemLp.mono_measure Measure.restrict_le_self + (hφ.continuous_gradient.memLp_of_hasCompactSupport hφ.compact_gradient) + +theorem eq_zero_outside (hφ : Test D φ) {x : Space d} (hx : x ∉ D) : φ x = 0 := by + by_contra h + exact hx (hφ.2.2 (subset_tsupport φ (by exact h))) + +theorem weakGradient (hφ : Test D φ) : WeakGradient D φ (gradient φ) := by + intro ψ hψ h + have hcφ : Continuous (fun x => (fderiv ℝ φ x) h) := (hφ.1.continuous_fderiv (by simp)).clm_apply continuous_const + have hcψ : Continuous (fun x => (fderiv ℝ ψ x) h) := (hψ.1.continuous_fderiv (by simp)).clm_apply continuous_const + simp_rw [inner_gradient_left] + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφ.eq_zero_outside hx, zero_mul])] + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hψ.eq_zero_outside hx, mul_zero])] + apply integral_mul_fderiv_eq_neg_fderiv_mul_of_integrable + · exact (hcφ.mul hψ.1.continuous).integrable_of_hasCompactSupport + hψ.2.1.mul_left + · exact (hφ.1.continuous.mul hcψ).integrable_of_hasCompactSupport + hφ.2.1.mul_right + · exact (hφ.1.continuous.mul hψ.1.continuous).integrable_of_hasCompactSupport + hψ.2.1.mul_left + · exact fun x _ => hφ.1.differentiable (by simp) x + · exact fun x _ => hψ.1.differentiable (by simp) x + +theorem h1 (hφ : Test D φ) : H1 D φ (gradient φ) := + ⟨hφ.memLp, hφ.memLp_gradient, hφ.weakGradient⟩ + +theorem h10 (hφ : Test D φ) : H10 D φ (gradient φ) := by + refine ⟨hφ.h1, fun ε hε => ⟨φ, hφ, ?_, ?_⟩⟩ + · simpa using (ENNReal.ofReal_pos.mpr hε) + · simpa using (ENNReal.ofReal_pos.mpr hε) + +end Test + +section SobolevLinear +variable {d : ℕ} {D : Set (Space d)} +variable {u v : Space d → ℝ} {G V : Space d → Space d} + +lemma memLp_inner_const (hG : MemLp G 2 (volume.restrict D)) (h : Space d) : + MemLp (fun x => inner ℝ (G x) h) 2 (volume.restrict D) := by + apply hG.of_le_mul (c := ‖h‖) (hG.aestronglyMeasurable.inner aestronglyMeasurable_const) + exact Filter.Eventually.of_forall (fun x => by + simpa [mul_comm] using (norm_inner_le_norm (𝕜 := ℝ) (G x) h)) + +lemma Test.memLp_directional {φ : Space d → ℝ} (hφ : Test D φ) (h : Space d) : + MemLp (fun x => (fderiv ℝ φ x) h) 2 (volume.restrict D) := by + simpa only [inner_gradient_left] using memLp_inner_const hφ.memLp_gradient h + +lemma integrable_deriv_product (hu : MemLp u 2 (volume.restrict D)) + {φ : Space d → ℝ} (hφ : Test D φ) (h : Space d) : + Integrable (fun x => u x * (fderiv ℝ φ x) h) (volume.restrict D) := by + exact hu.integrable_mul (hφ.memLp_directional h) + +lemma integrable_inner_test (hG : MemLp G 2 (volume.restrict D)) + {φ : Space d → ℝ} (hφ : Test D φ) (h : Space d) : + Integrable (fun x => inner ℝ (G x) h * φ x) (volume.restrict D) := by + exact (memLp_inner_const hG h).integrable_mul hφ.memLp + +lemma H1.add (hu : H1 D u G) (hv : H1 D v V) : + H1 D (fun x => u x + v x) (fun x => G x + V x) := by + refine ⟨hu.1.add hv.1, hu.2.1.add hv.2.1, ?_⟩ + intro φ hφ h + simp_rw [add_mul, inner_add_left] + rw [integral_add (integrable_deriv_product hu.1 hφ h) + (integrable_deriv_product hv.1 hφ h)] + simp_rw [add_mul] + rw [integral_add (integrable_inner_test hu.2.1 hφ h) + (integrable_inner_test hv.2.1 hφ h), hu.2.2 φ hφ h, hv.2.2 φ hφ h] + ring + +lemma H1.const_smul (hu : H1 D u G) (t : ℝ) : + H1 D (fun x => t * u x) (fun x => t • G x) := by + refine ⟨hu.1.const_mul t, hu.2.1.const_smul t, ?_⟩ + intro φ hφ h + simp_rw [real_inner_smul_left, mul_assoc] + rw [integral_const_mul, integral_const_mul, hu.2.2 φ hφ h] + ring + +end SobolevLinear + +section Variations +variable {d : ℕ} {D : Set (Space d)} + +lemma Test.const_mul {φ : Space d → ℝ} (hφ : Test D φ) (t : ℝ) : + Test D (fun x => t * φ x) := by + exact ⟨contDiff_const.mul hφ.1, hφ.2.1.mul_left, + tsupport_mul_subset_right.trans hφ.2.2⟩ + +lemma Test.gradient_const_mul {φ : Space d → ℝ} (hφ : Test D φ) (t : ℝ) : + gradient (fun x => t * φ x) = fun x => t • gradient φ x := by + funext x + apply ext_inner_right ℝ + intro y + rw [inner_gradient_left, real_inner_smul_left, inner_gradient_left, + fderiv_const_mul (hφ.1.differentiable (by simp) x)] + rfl + +lemma Test.h10_const_mul {φ : Space d → ℝ} (hφ : Test D φ) (t : ℝ) : + H10 D (fun x => t * φ x) (fun x => t • gradient φ x) := by + rw [← hφ.gradient_const_mul t] + exact (hφ.const_mul t).h10 + +lemma integrable_phase {μ : Measure (Space d)} [IsFiniteMeasure μ] + {u : Space d → ℝ} (hu : AEStronglyMeasurable u μ) : + Integrable (fun x => if 0 < u x then (1 : ℝ) else 0) μ := by + have hm : Measurable (fun t : ℝ => if 0 < t then (1 : ℝ) else 0) := + Measurable.ite measurableSet_Ioi measurable_const measurable_const + apply (integrable_const (1 : ℝ)).mono' + (hm.comp_aemeasurable hu.aemeasurable).aestronglyMeasurable + exact Filter.Eventually.of_forall (fun x => by + change ‖(if 0 < u x then (1 : ℝ) else 0)‖ ≤ 1 + split_ifs <;> norm_num) + +lemma integrable_inner_of_memLp {μ : Measure (Space d)} + {G V : Space d → Space d} (hG : MemLp G 2 μ) (hV : MemLp V 2 μ) : + Integrable (fun x => inner ℝ (G x) (V x)) μ := by + apply (hG.norm.integrable_mul hV.norm).mono' + (hG.aestronglyMeasurable.inner hV.aestronglyMeasurable) + exact Filter.Eventually.of_forall (fun x => norm_inner_le_norm (G x) (V x)) + +lemma energy_affine [IsFiniteMeasure (volume.restrict D)] + {u φ : Space d → ℝ} {G V : Space d → Space d} + (hu : MemLp u 2 (volume.restrict D)) + (hG : MemLp G 2 (volume.restrict D)) + (hV : MemLp V 2 (volume.restrict D)) (t : ℝ) + (hphase : ∀ᵐ x ∂volume.restrict D, (0 < u x + t * φ x) ↔ 0 < u x) : + energy D (fun x => u x + t * φ x) (fun x => G x + t • V x) = + energy D u G + 2 * t * (∫ x in D, inner ℝ (G x) (V x)) + + t ^ 2 * (∫ x in D, ‖V x‖ ^ 2) := by + have hG2 : Integrable (fun x => ‖G x‖ ^ 2) (volume.restrict D) := + hG.integrable_norm_pow (by norm_num) + have hV2 : Integrable (fun x => ‖V x‖ ^ 2) (volume.restrict D) := + hV.integrable_norm_pow (by norm_num) + have hGV := integrable_inner_of_memLp hG hV + have hI := integrable_phase hu.aestronglyMeasurable + have hid : ∀ᵐ x ∂volume.restrict D, + ‖G x + t • V x‖ ^ 2 + (if 0 < u x + t * φ x then (1 : ℝ) else 0) = + ((‖G x‖ ^ 2 + (if 0 < u x then (1 : ℝ) else 0)) + + (2 * t) * inner ℝ (G x) (V x)) + t ^ 2 * ‖V x‖ ^ 2 := by + filter_upwards [hphase] with x hx + rw [norm_add_sq_real, real_inner_smul_right, norm_smul, mul_pow, Real.norm_eq_abs, + sq_abs, if_congr hx rfl rfl] + ring + unfold energy + rw [integral_congr_ae hid] + have hsum := integral_add ((hG2.add hI).add (hGV.const_mul (2 * t))) + (hV2.const_mul (t ^ 2)) + have hsum' := integral_add (hG2.add hI) (hGV.const_mul (2 * t)) + simp only [Pi.add_apply] at hsum hsum' + rw [hsum, hsum', integral_const_mul, integral_const_mul] + +lemma linear_coefficient_eq_zero (A B : ℝ) {ε : ℝ} (hε : 0 < ε) + (h : ∀ t : ℝ, |t| < ε → 0 ≤ 2 * t * A + t ^ 2 * B) : A = 0 := by + have hm : IsLocalMin (fun t : ℝ => 2 * t * A + t ^ 2 * B) 0 := by + apply Metric.eventually_nhds_iff.mpr + refine ⟨ε, hε, fun t ht => ?_⟩ + simpa using h t (by simpa [Real.dist_eq] using ht) + have hd : HasDerivAt (fun t : ℝ => 2 * t * A + t ^ 2 * B) (2 * A) 0 := by + convert (((hasDerivAt_id (0 : ℝ)).const_mul 2).mul_const A).add + (((hasDerivAt_id (0 : ℝ)).pow 2).mul_const B) using 1 + · rfl + · norm_num + have := hm.hasDerivAt_eq_zero hd + linarith + +/-- The first variation for compact perturbations whose support stays uniformly +inside the positive phase. This is derived from full Sobolev comparison. -/ +lemma firstVariation_of_comparison [IsFiniteMeasure (volume.restrict D)] + {u φ : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) (hu0 : ∀ᵐ x ∂volume.restrict D, 0 ≤ u x) + (hmin : ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 D v V → (∀ᵐ x ∂volume.restrict D, 0 ≤ v x) → + H10 D (fun x => v x - u x) (fun x => V x - G x) → + energy D u G ≤ energy D v V) + (hφ : Test D φ) {δ : ℝ} (hδ : 0 < δ) + (hpos : ∀ᵐ x ∂volume.restrict D, x ∈ tsupport φ → δ ≤ u x) : + (∫ x in D, inner ℝ (G x) (gradient φ x)) = 0 := by + obtain ⟨C, hC⟩ := (hφ.1.continuous.norm.bddAbove_range_of_hasCompactSupport + hφ.2.1.norm) + have hCB : ∀ x, |φ x| ≤ |C| + 1 := fun x => by + have hx := hC (mem_range_self x) + change ‖φ x‖ ≤ C at hx + rw [Real.norm_eq_abs] at hx + linarith [le_abs_self C] + have hCpos : 0 < |C| + 1 := by positivity + apply linear_coefficient_eq_zero _ _ (div_pos hδ hCpos) + intro t ht + have hsmall : |t| * (|C| + 1) < δ := (lt_div_iff₀ hCpos).mp ht + have hcontrol : ∀ᵐ x ∂volume.restrict D, + 0 ≤ u x + t * φ x ∧ ((0 < u x + t * φ x) ↔ 0 < u x) := by + filter_upwards [hu0, hpos] with x hx hp + by_cases hz : φ x = 0 + · simp [hz, hx] + · have hux : δ ≤ u x := hp (subset_tsupport φ hz) + have hb : |t * φ x| < δ := by + rw [abs_mul] + exact lt_of_le_of_lt (mul_le_mul_of_nonneg_left (hCB x) (abs_nonneg t)) hsmall + have ha : 0 < u x + t * φ x := by + have := neg_abs_le (t * φ x) + linarith + exact ⟨ha.le, iff_of_true ha (lt_of_lt_of_le hδ hux)⟩ + have hcomp := hmin (fun x => u x + t * φ x) + (fun x => G x + t • gradient φ x) + (hu.add (hφ.h1.const_smul t)) (hcontrol.mono fun _ hx => hx.1) + (by simpa only [add_sub_cancel_left] using hφ.h10_const_mul t) + rw [energy_affine hu.1 hu.2.1 hφ.memLp_gradient t + (hcontrol.mono fun _ hx => hx.2)] at hcomp + linarith + +lemma LocalMinimizer.firstVariation {u : Space d → ℝ} (hu : LocalMinimizer D u) : + ∃ G : Space d → Space d, H1Loc D u G ∧ + ∀ (c : Space d) (r : ℝ), 0 < r → Metric.closedBall c r ⊆ D → + ∀ φ : Space d → ℝ, Test (Metric.ball c r) φ → + ∀ δ : ℝ, 0 < δ → + (∀ᵐ x ∂volume.restrict (Metric.ball c r), x ∈ tsupport φ → δ ≤ u x) → + (∫ x in Metric.ball c r, inner ℝ (G x) (gradient φ x)) = 0 := by + obtain ⟨hD, G, hG, hnonneg, hmin⟩ := hu + refine ⟨G, hG, fun c r hr hB φ hφ δ hδ hp => ?_⟩ + let : IsFiniteMeasure (volume.restrict (Metric.ball c r)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + apply firstVariation_of_comparison (hG c r hr hB) _ (hmin c r hr hB) hφ hδ hp + exact ae_restrict_of_ae_restrict_of_subset + (Metric.ball_subset_closedBall.trans hB) hnonneg + +/-- Once a continuous representative is obtained, every test compactly +supported in its positive phase is an admissible two-sided variation. -/ +lemma LocalMinimizer.weakHarmonic_of_continuous {u : Space d → ℝ} + (hu : LocalMinimizer D u) (hc : ContinuousOn u D) : + ∃ G : Space d → Space d, H1Loc D u G ∧ + ∀ (c : Space d) (r : ℝ), 0 < r → Metric.closedBall c r ⊆ D → + ∀ φ : Space d → ℝ, Test (Metric.ball c r ∩ {x | 0 < u x}) φ → + (∫ x in Metric.ball c r, inner ℝ (G x) (gradient φ x)) = 0 := by + obtain ⟨G, hG, hvar⟩ := hu.firstVariation + refine ⟨G, hG, fun c r hr hB φ hφ => ?_⟩ + have hsub : tsupport φ ⊆ D := + fun x hx => hB (Metric.ball_subset_closedBall (hφ.2.2 hx).1) + have hδ : ∃ δ : ℝ, 0 < δ ∧ ∀ x ∈ tsupport φ, δ ≤ u x := by + by_cases hn : (tsupport φ).Nonempty + · obtain ⟨x, hx, hmin⟩ := hφ.2.1.exists_isMinOn hn (hc.mono hsub) + exact ⟨u x, (hφ.2.2 hx).2, hmin⟩ + · exact ⟨1, zero_lt_one, fun x hx => (hn ⟨x, hx⟩).elim⟩ + obtain ⟨δ, hd, hδ⟩ := hδ + exact hvar c r hr hB φ ⟨hφ.1, hφ.2.1, fun x hx => (hφ.2.2 hx).1⟩ δ hd + (Filter.Eventually.of_forall hδ) + +lemma OneHomogeneous.everywhere {u : Space d → ℝ} + (hu : OneHomogeneous u) (hc : Continuous u) (r : ℝ) (hr : 0 < r) : + ∀ x, u (r • x) = r * u x := by + have h1 : Continuous (fun x => u (r • x)) := hc.comp (continuous_id.const_smul r) + have h2 : Continuous (fun x => r * u x) := continuous_const.mul hc + have hh : (fun x => u (r • x)) = fun x => r * u x := + (h1.ae_eq_iff_eq volume h2).mp (hu r hr) + exact congrFun hh + +end Variations + +section GradientUniqueness +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} + {G V : Space d → Space d} + +/-- The explicit gradient witnesses in the Sobolev definition are unique a.e. +This uses Mathlib's fundamental lemma for compact smooth test functions. -/ +lemma H1.gradient_unique (hD : IsOpen D) (hG : H1 D u G) (hV : H1 D u V) : + G =ᵐ[volume.restrict D] V := by + have hdir : ∀ h : Space d, ∀ᵐ x ∂volume, + x ∈ D → inner ℝ (G x - V x) h = 0 := by + intro h + apply hD.ae_eq_zero_of_integral_contDiff_smul_eq_zero + · apply locallyIntegrableOn_of_locallyIntegrable_restrict + exact (memLp_inner_const (hG.2.1.sub hV.2.1) h).locallyIntegrable (by norm_num) + · intro φ hφc hφs hφD + have hφ : Test D φ := ⟨hφc, hφs, hφD⟩ + rw [← setIntegral_eq_integral_of_forall_compl_eq_zero + (s := D) (fun x hx => by rw [hφ.eq_zero_outside hx, zero_smul])] + simp only [smul_eq_mul, inner_sub_left, mul_sub] + have hGi : Integrable (fun x => φ x * inner ℝ (G x) h) (volume.restrict D) := by + simpa only [mul_comm] using integrable_inner_test hG.2.1 hφ h + have hVi : Integrable (fun x => φ x * inner ℝ (V x) h) (volume.restrict D) := by + simpa only [mul_comm] using integrable_inner_test hV.2.1 hφ h + rw [integral_sub hGi hVi] + have h1 := hG.2.2 φ hφ h + have h2 := hV.2.2 φ hφ h + simp only [mul_comm (φ _)] + linarith + apply (ae_restrict_iff' hD.measurableSet).mpr + have hcoord : ∀ i : Fin d, ∀ᵐ x ∂volume, x ∈ D → G x i = V x i := by + intro i + filter_upwards [hdir (EuclideanSpace.single i 1)] with x hx hxD + have hi := hx hxD + simpa [EuclideanSpace.inner_single_right, sub_eq_zero] using hi + filter_upwards [ae_all_iff.mpr hcoord] with x hx hxD + apply PiLp.ext; intro i + exact hx i hxD + +end GradientUniqueness + +section SobolevClosure +variable {d : ℕ} {D : Set (Space d)} + +lemma integral_inner_bound {α : Type uα} {E : Type uE} [MeasurableSpace α] + [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + {μ : Measure α} {f g : α → E} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : + |∫ x, inner ℝ (f x) (g x) ∂μ| ≤ + (eLpNorm f 2 μ).toReal * (eLpNorm g 2 μ).toReal := by + have he : (∫ x, inner ℝ (f x) (g x) ∂μ) = + inner ℝ (hf.toLp f) (hg.toLp g) := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [hf.coeFn_toLp, hg.coeFn_toLp] with x hx hy + rw [hx, hy] + rw [he, ← Lp.norm_toLp f hf, ← Lp.norm_toLp g hg] + exact abs_real_inner_le_norm _ _ + +lemma Test.memLp_smul_const {φ : Space d → ℝ} (hφ : Test D φ) (h : Space d) : + MemLp (fun x => φ x • h) 2 (volume.restrict D) := by + refine hφ.memLp.of_le_mul (c := ‖h‖) + (hφ.memLp.aestronglyMeasurable.smul aestronglyMeasurable_const) ?_ + exact ae_of_all _ (fun x => by simp [norm_smul, mul_comm]) + +/-- Weak H¹ is closed for the actual L² norm on both components. This is +used to zero-extend arbitrary H¹₀ competitors, not just smooth competitors. -/ +lemma eq_zero_of_abs_lt {z : ℝ} (h : ∀ ε : ℝ, 0 < ε → |z| < ε) : z = 0 := by + by_contra hz + exact lt_irrefl _ (h |z| (abs_pos.mpr hz)) + +lemma weakGradient_of_approx {u : Space d → ℝ} {G : Space d → Space d} + (hu : MemLp u 2 (volume.restrict D)) (hG : MemLp G 2 (volume.restrict D)) + (hap : ∀ ε : ℝ, 0 < ε → ∃ v V, H1 D v V ∧ + eLpNorm (fun x => u x-v x) 2 (volume.restrict D) < ENNReal.ofReal ε ∧ + eLpNorm (fun x => G x-V x) 2 (volume.restrict D) < ENNReal.ofReal ε) : + WeakGradient D u G := by + intro φ hφ h + let μ := volume.restrict D + let ψ := fun x => (fderiv ℝ φ x) h + let Ψ := fun x => φ x • h + have hψ : MemLp ψ 2 μ := hφ.memLp_directional h + have hΨ : MemLp Ψ 2 μ := hφ.memLp_smul_const h + let C := (eLpNorm ψ 2 μ).toReal + (eLpNorm Ψ 2 μ).toReal + 1 + have hC : 0 < C := by dsimp [C]; positivity + have hz : (∫ x in D, u x * ψ x) + (∫ x in D, inner ℝ (G x) h * φ x) = 0 := by + apply eq_zero_of_abs_lt + intro ε hε + let δ := ε / C + have hδ : 0 < δ := div_pos hε hC + obtain ⟨v, V, hv, heu, heG⟩ := hap δ hδ + have heuto : (eLpNorm (fun x => u x-v x) 2 μ).toReal < δ := by + exact (ENNReal.toReal_lt_toReal (hu.sub hv.1).eLpNorm_ne_top ENNReal.ofReal_ne_top).mpr + heu |>.trans_eq (ENNReal.toReal_ofReal hδ.le) + have heGto : (eLpNorm (fun x => G x-V x) 2 μ).toReal < δ := by + exact (ENNReal.toReal_lt_toReal (hG.sub hv.2.1).eLpNorm_ne_top ENNReal.ofReal_ne_top).mpr + heG |>.trans_eq (ENNReal.toReal_ofReal hδ.le) + have h1 := integral_inner_bound (hu.sub hv.1) hψ + have h2 := integral_inner_bound (hG.sub hv.2.1) hΨ + simp only [Real.inner_apply] at h1 + simp only [Ψ, inner_smul_right, mul_comm (φ _)] at h2 + have heq : (∫ x in D, u x * ψ x) + (∫ x in D, inner ℝ (G x) h * φ x) = + (∫ x in D, (u x-v x)*ψ x) + + (∫ x in D, inner ℝ (G x-V x) h * φ x) := by + simp only [sub_mul, inner_sub_left] + rw [integral_sub (f := fun x => u x * ψ x) (g := fun x => v x * ψ x) + (hu.integrable_mul hψ) (hv.1.integrable_mul hψ), + integral_sub (integrable_inner_test hG hφ h) (integrable_inner_test hv.2.1 hφ h)] + have ht := hv.2.2 φ hφ h + change (∫ x in D, v x * ψ x) = _ at ht + linarith + rw [heq] + calc + _ ≤ |∫ x in D, (u x-v x)*ψ x| + |∫ x in D, inner ℝ (G x-V x) h * φ x| := abs_add_le _ _ + _ ≤ (eLpNorm (fun x => u x-v x) 2 μ).toReal * (eLpNorm ψ 2 μ).toReal + + (eLpNorm (fun x => G x-V x) 2 μ).toReal * (eLpNorm Ψ 2 μ).toReal := add_le_add h1 h2 + _ ≤ δ * (eLpNorm ψ 2 μ).toReal + δ * (eLpNorm Ψ 2 μ).toReal := by + gcongr + _ < ε := by + have hem : δ*C = ε := div_mul_cancel₀ ε hC.ne' + dsimp [C] at hem + nlinarith + linarith + +end SobolevClosure + +section Localization +variable {d : ℕ} {D E : Set (Space d)} +variable {u v : Space d → ℝ} {G V : Space d → Space d} + +lemma WeakGradient.congr (hu : WeakGradient D u G) + (huv : u =ᵐ[volume.restrict D] v) (hGV : G =ᵐ[volume.restrict D] V) : + WeakGradient D v V := by + intro φ hφ h + have hleft : (∫ x in D, v x * (fderiv ℝ φ x) h) = + ∫ x in D, u x * (fderiv ℝ φ x) h := by + apply integral_congr_ae + filter_upwards [huv] with x hx + rw [hx] + have hright : (∫ x in D, inner ℝ (V x) h * φ x) = + ∫ x in D, inner ℝ (G x) h * φ x := by + apply integral_congr_ae + filter_upwards [hGV] with x hx + rw [hx] + rw [hleft, hright, hu φ hφ h] + +lemma H1.congr (hu : H1 D u G) + (huv : u =ᵐ[volume.restrict D] v) (hGV : G =ᵐ[volume.restrict D] V) : + H1 D v V := + ⟨hu.1.ae_eq huv, hu.2.1.ae_eq hGV, hu.2.2.congr huv hGV⟩ + +lemma H10.congr (hu : H10 D u G) + (huv : u =ᵐ[volume.restrict D] v) (hGV : G =ᵐ[volume.restrict D] V) : + H10 D v V := by + refine ⟨hu.1.congr huv hGV, ?_⟩ + intro ε hε + obtain ⟨φ, hφ, he, heG⟩ := hu.2 ε hε + refine ⟨φ, hφ, ?_, ?_⟩ + · have heq : (fun x => u x - φ x) =ᵐ[volume.restrict D] (fun x => v x - φ x) := + huv.fun_comp (fun z => z) |>.sub (Filter.EventuallyEq.refl _ φ) + rwa [← eLpNorm_congr_ae heq] + · have heq : (fun x => G x - gradient φ x) =ᵐ[volume.restrict D] + (fun x => V x - gradient φ x) := hGV.sub (Filter.EventuallyEq.refl _ (gradient φ)) + rwa [← eLpNorm_congr_ae heq] + +lemma Test.fderiv_eq_zero_outside {φ : Space d → ℝ} (hφ : Test D φ) + {x : Space d} (hx : x ∉ D) : fderiv ℝ φ x = 0 := + fderiv_of_notMem_tsupport ℝ (fun h => hx (hφ.2.2 h)) + +lemma Test.mono {φ : Space d → ℝ} (hφ : Test D φ) (hDE : D ⊆ E) : Test E φ := + ⟨hφ.1, hφ.2.1, hφ.2.2.trans hDE⟩ + +lemma H1.mono (hu : H1 E u G) (hDE : D ⊆ E) : H1 D u G := by + refine ⟨hu.1.mono_measure (Measure.restrict_mono hDE le_rfl), + hu.2.1.mono_measure (Measure.restrict_mono hDE le_rfl), ?_⟩ + intro φ hφ h + have hh := hu.2.2 φ (hφ.mono hDE) h + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [(hφ.mono hDE).fderiv_eq_zero_outside hx]; simp), + setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [(hφ.mono hDE).eq_zero_outside hx, mul_zero])] at hh + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφ.fderiv_eq_zero_outside hx]; simp), + setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφ.eq_zero_outside hx, mul_zero])] + exact hh + +lemma Test.mul {φ ψ : Space d → ℝ} (hφ : Test D φ) (hψ : Test D ψ) : + Test D (fun x => φ x * ψ x) := + ⟨hφ.1.mul hψ.1, hφ.2.1.mul_right, (tsupport_mul_subset_left (f := φ) (g := ψ)).trans hφ.2.2⟩ + +lemma Test.memLp_top {φ : Space d → ℝ} (hφ : Test D φ) : + MemLp φ ∞ (volume.restrict D) := + (hφ.1.continuous.memLp_of_hasCompactSupport hφ.2.1).mono_measure Measure.restrict_le_self + +lemma Test.memLp_gradient_top {φ : Space d → ℝ} (hφ : Test D φ) : + MemLp (gradient φ) ∞ (volume.restrict D) := + (hφ.continuous_gradient.memLp_of_hasCompactSupport hφ.compact_gradient).mono_measure + Measure.restrict_le_self + +lemma Test.gradient_mul {φ ψ : Space d → ℝ} (hφ : Test D φ) (hψ : Test D ψ) + (x : Space d) : gradient (fun y => φ y * ψ y) x = + φ x • gradient ψ x + ψ x • gradient φ x := by + apply (InnerProductSpace.toDual ℝ (Space d)).injective + ext h + change inner ℝ (gradient (fun y => φ y * ψ y) x) h = + inner ℝ (φ x • gradient ψ x + ψ x • gradient φ x) h + simp only [inner_add_left, real_inner_smul_left, inner_gradient_left] + have hh := ((hφ.1.differentiable (by simp)).differentiableAt (x := x)).hasFDerivAt.mul + ((hψ.1.differentiable (by simp)).differentiableAt (x := x)).hasFDerivAt + have hh' := hh.fderiv + change fderiv ℝ (fun y => φ y * ψ y) x = _ at hh' + rw [hh'] + simp only [add_apply, smul_apply, smul_eq_mul] + +lemma H1.mul_test (hu : H1 D u G) {φ : Space d → ℝ} (hφ : Test D φ) : + H1 D (fun x => φ x * u x) + (fun x => φ x • G x + u x • gradient φ x) := by + have hum : MemLp (fun x => φ x * u x) 2 (volume.restrict D) := + hφ.memLp_top.fun_mul hu.1 + have hGm : MemLp (fun x => φ x • G x) 2 (volume.restrict D) := + hφ.memLp_top.smul hu.2.1 + have hgm : MemLp (fun x => u x • gradient φ x) 2 (volume.restrict D) := + hu.1.smul hφ.memLp_gradient_top + refine ⟨hum, hGm.add hgm, ?_⟩ + intro ψ hψ h + have hi := integrable_deriv_product hum hψ h + have hij := integrable_inner_test hgm hψ h + simp only [real_inner_smul_left, inner_gradient_left] at hij + have hik := integrable_inner_test hGm hψ h + simp only [real_inner_smul_left] at hik + have hderiv (x : Space d) : + u x * (fderiv ℝ (fun y => φ y * ψ y) x) h = + (φ x * u x) * (fderiv ℝ ψ x) h + (u x * (fderiv ℝ φ x) h) * ψ x := by + rw [← inner_gradient_left, hφ.gradient_mul hψ, + inner_add_left, real_inner_smul_left, real_inner_smul_left, + inner_gradient_left, inner_gradient_left] + ring + have hweak := hu.2.2 _ (hφ.mul hψ) h + simp_rw [hderiv] at hweak + rw [integral_add hi hij] at hweak + have hright (x : Space d) : inner ℝ (G x) h * (φ x * ψ x) = + (φ x * inner ℝ (G x) h) * ψ x := by ring + simp_rw [hright] at hweak + simp only [inner_add_left, real_inner_smul_left, inner_gradient_left, add_mul] + rw [integral_add hik hij] + linarith + +lemma energy_congr (huv : u =ᵐ[volume.restrict D] v) + (hGV : G =ᵐ[volume.restrict D] V) : energy D u G = energy D v V := by + apply integral_congr_ae + filter_upwards [huv, hGV] with x hx hGx + rw [hx, hGx] + +lemma LocalMinimizer.congr (hu : LocalMinimizer D u) + (huv : u =ᵐ[volume.restrict D] v) : LocalMinimizer D v := by + obtain ⟨hD, G, hG, hnonneg, hmin⟩ := hu + have heq (c : Space d) (r : ℝ) (hsub : Metric.closedBall c r ⊆ D) : + u =ᵐ[volume.restrict (Metric.ball c r)] v := + huv.filter_mono (ae_mono (Measure.restrict_mono + (Metric.ball_subset_closedBall.trans hsub) le_rfl)) + refine ⟨hD, G, ?_, ?_, ?_⟩ + · intro c r hr hsub + exact (hG c r hr hsub).congr (heq c r hsub) (Filter.EventuallyEq.refl _ _) + · filter_upwards [hnonneg, huv] with x hx he + rwa [← he] + · intro c r hr hsub q Q hq hqn hzero + have hz : H10 (Metric.ball c r) (fun x => q x - u x) (fun x => Q x - G x) := + hzero.congr ((Filter.EventuallyEq.refl _ q).sub (heq c r hsub).symm) + (Filter.EventuallyEq.refl _ _) + have hm := hmin c r hr hsub q Q hq hqn hz + rwa [energy_congr (heq c r hsub) (Filter.EventuallyEq.refl _ _)] at hm + +lemma LocalMinimizer.mono (hu : LocalMinimizer E u) (hD : IsOpen D) (hDE : D ⊆ E) : + LocalMinimizer D u := by + obtain ⟨_, G, hG, hnonneg, hmin⟩ := hu + refine ⟨hD, G, ?_, ?_, ?_⟩ + · intro c r hr hsub + exact hG c r hr (hsub.trans hDE) + · exact hnonneg.filter_mono (ae_mono (Measure.restrict_mono hDE le_rfl)) + · intro c r hr hsub + exact hmin c r hr (hsub.trans hDE) + +lemma Test.gradient_eq_zero_outside {φ : Space d → ℝ} (hφ : Test D φ) + {x : Space d} (hx : x ∉ D) : gradient φ x = 0 := by + simp [gradient, hφ.fderiv_eq_zero_outside hx] + +/-- Zero extension preserves the exact Sobolev norm of a zero-trace +approximation; neither a smooth representative nor a boundary trace theorem +is assumed. -/ +lemma H10.zero_extension (hu : H10 D u G) (hD : MeasurableSet D) (hDE : D ⊆ E) : + H10 E (D.indicator u) (D.indicator G) := by + have hres : (volume.restrict E).restrict D = volume.restrict D := + Measure.restrict_restrict_of_subset hDE + have hU : MemLp (D.indicator u) 2 (volume.restrict E) := by + apply (memLp_indicator_iff_restrict hD).mpr + rw [hres] + exact hu.1.1 + have hW : MemLp (D.indicator G) 2 (volume.restrict E) := by + apply (memLp_indicator_iff_restrict hD).mpr + rw [hres] + exact hu.1.2.1 + have hap (ε : ℝ) (hε : 0 < ε) : ∃ φ : Space d → ℝ, Test E φ ∧ + eLpNorm (fun x => D.indicator u x - φ x) 2 (volume.restrict E) < ENNReal.ofReal ε ∧ + eLpNorm (fun x => D.indicator G x - gradient φ x) 2 (volume.restrict E) < ENNReal.ofReal ε := by + obtain ⟨φ, hφ, hUφ, hGφ⟩ := hu.2 ε hε + refine ⟨φ, hφ.mono hDE, ?_, ?_⟩ + · have heq : (fun x => D.indicator u x - φ x) = D.indicator (fun x => u x - φ x) := by + funext x + by_cases hx : x ∈ D + · simp [hx] + · simp [hx, hφ.eq_zero_outside hx] + rw [heq, eLpNorm_indicator_eq_eLpNorm_restrict hD, hres] + exact hUφ + · have heq : (fun x => D.indicator G x - gradient φ x) = + D.indicator (fun x => G x - gradient φ x) := by + funext x + by_cases hx : x ∈ D + · simp [hx] + · simp [hx, hφ.gradient_eq_zero_outside hx] + rw [heq, eLpNorm_indicator_eq_eLpNorm_restrict hD, hres] + exact hGφ + refine ⟨⟨hU, hW, weakGradient_of_approx hU hW ?_⟩, hap⟩ + intro ε hε + obtain ⟨φ, hφ, hUφ, hGφ⟩ := hap ε hε + exact ⟨φ, gradient φ, hφ.h1, hUφ, hGφ⟩ + +lemma eLpNorm_sub_lt_of_two {α : Type uα} {F : Type uF} [MeasurableSpace α] + [NormedAddCommGroup F] {μ : Measure α} {f g h : α → F} + (_hf : MemLp f 2 μ) (_hg : MemLp g 2 μ) (_hh : MemLp h 2 μ) + {ε : ℝ} (hε : 0 < ε) + (hfg : eLpNorm (fun x => f x - g x) 2 μ < ENNReal.ofReal (ε / 2)) + (hgh : eLpNorm (fun x => g x - h x) 2 μ < ENNReal.ofReal (ε / 2)) : + eLpNorm (fun x => f x - h x) 2 μ < ENNReal.ofReal ε := by + have heq : (fun x => f x - h x) = + (fun x => f x - g x) + (fun x => g x - h x) := by + funext x + simp + rw [heq] + calc + _ ≤ eLpNorm (fun x => f x - g x) 2 μ + + eLpNorm (fun x => g x - h x) 2 μ := + eLpNorm_add_le (by norm_num) + _ < ENNReal.ofReal (ε / 2) + ENNReal.ofReal (ε / 2) := ENNReal.add_lt_add hfg hgh + _ = ENNReal.ofReal ε := by + rw [← ENNReal.ofReal_add (by positivity) (by positivity)] + congr 1 + ring + +lemma H10.of_approx (hu : MemLp u 2 (volume.restrict D)) + (hG : MemLp G 2 (volume.restrict D)) + (hap : ∀ ε : ℝ, 0 < ε → ∃ v V, H10 D v V ∧ + eLpNorm (fun x => u x - v x) 2 (volume.restrict D) < ENNReal.ofReal ε ∧ + eLpNorm (fun x => G x - V x) 2 (volume.restrict D) < ENNReal.ofReal ε) : + H10 D u G := by + refine ⟨⟨hu, hG, weakGradient_of_approx hu hG ?_⟩, ?_⟩ + · intro ε hε + obtain ⟨v, V, hv, hvu, hVG⟩ := hap ε hε + exact ⟨v, V, hv.1, hvu, hVG⟩ + · intro ε hε + obtain ⟨v, V, hv, hvu, hVG⟩ := hap (ε / 2) (by positivity) + obtain ⟨φ, hφ, hvφ, hVφ⟩ := hv.2 (ε / 2) (by positivity) + exact ⟨φ, hφ, eLpNorm_sub_lt_of_two hu hv.1.1 hφ.memLp hε hvu hvφ, + eLpNorm_sub_lt_of_two hG hv.1.2.1 hφ.memLp_gradient hε hVG hVφ⟩ + +lemma energy_split [IsFiniteMeasure (volume.restrict E)] + (hu : MemLp u 2 (volume.restrict E)) (hG : MemLp G 2 (volume.restrict E)) + (hD : MeasurableSet D) (hDE : D ⊆ E) : + energy E u G = energy D u G + energy (E \ D) u G := by + have hi : Integrable (fun x => ‖G x‖ ^ 2 + if 0 < u x then (1 : ℝ) else 0) + (volume.restrict E) := + (hG.integrable_norm_pow (by norm_num)).add (integrable_phase hu.aestronglyMeasurable) + have heq : Dᶜ ∩ E = E \ D := by ext x; simp [and_comm] + unfold energy + rw [← integral_add_compl hD hi, + Measure.restrict_restrict_of_subset hDE, Measure.restrict_restrict hD.compl, heq] + +lemma GlobalMinimizer.compare_bounded (hu : GlobalMinimizer u) : + ∃ G : Space d → Space d, H1Loc univ u G ∧ + ∀ D : Set (Space d), MeasurableSet D → Bornology.IsBounded D → + ∀ (v : Space d → ℝ) (V : Space d → Space d), + H1 D v V → (∀ᵐ x ∂volume.restrict D, 0 ≤ v x) → + H10 D (fun x => v x - u x) (fun x => V x - G x) → + energy D u G ≤ energy D v V := by + obtain ⟨_, G, hG, hnonneg, hmin⟩ := hu + refine ⟨G, hG, ?_⟩ + intro D hD hDb v V hv hvn hz + obtain ⟨r, hr, hDr⟩ := hDb.subset_ball_lt 0 (0 : Space d) + let B := Metric.ball (0 : Space d) r + let : IsFiniteMeasure (volume.restrict B) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + have huB : H1 B u G := hG 0 r hr (subset_univ _) + have hzu : H10 B (D.indicator (fun x => v x - u x)) + (D.indicator (fun x => V x - G x)) := hz.zero_extension hD hDr + let U : Space d → ℝ := fun x => u x + D.indicator (fun y => v y - u y) x + let W : Space d → Space d := fun x => G x + D.indicator (fun y => V y - G y) x + have hUW : H1 B U W := huB.add hzu.1 + have hres : (volume.restrict B).restrict D = volume.restrict D := + Measure.restrict_restrict_of_subset hDr + have hUn : ∀ᵐ x ∂volume.restrict B, 0 ≤ U x := by + have hun : ∀ᵐ x ∂volume.restrict B, 0 ≤ u x := by + rw [Measure.restrict_univ] at hnonneg + exact hnonneg.filter_mono (ae_mono Measure.restrict_le_self) + have hvn' : ∀ᵐ x ∂(volume.restrict B).restrict D, 0 ≤ v x := by + rwa [hres] + have hvimp : ∀ᵐ x ∂volume.restrict B, x ∈ D → 0 ≤ v x := + (ae_restrict_iff' hD).mp hvn' + filter_upwards [hun, hvimp] with x hux hvx + by_cases hx : x ∈ D + · simpa [U, hx] using hvx hx + · simpa [U, hx] using hux + have hzero : H10 B (fun x => U x - u x) (fun x => W x - G x) := + hzu.congr (ae_of_all _ (fun x => by simp [U])) + (ae_of_all _ (fun x => by simp [W])) + have hm := hmin 0 r hr (subset_univ _) U W hUW hUn hzero + change energy B u G ≤ energy B U W at hm + have hUinside : U =ᵐ[volume.restrict D] v := by + filter_upwards [ae_restrict_mem hD] with x hx + simp [U, hx] + have hWinside : W =ᵐ[volume.restrict D] V := by + filter_upwards [ae_restrict_mem hD] with x hx + simp [W, hx] + have hUoutside : U =ᵐ[volume.restrict (B \ D)] u := by + filter_upwards [ae_restrict_mem (Metric.isOpen_ball.measurableSet.diff hD)] with x hx + simp [U, hx.2] + have hWoutside : W =ᵐ[volume.restrict (B \ D)] G := by + filter_upwards [ae_restrict_mem (Metric.isOpen_ball.measurableSet.diff hD)] with x hx + simp [W, hx.2] + rw [energy_split huB.1 huB.2.1 hD hDr, energy_split hUW.1 hUW.2.1 hD hDr, + energy_congr hUinside hWinside, energy_congr hUoutside hWoutside] at hm + linarith + +lemma eLpNorm_two_eq_eLpNorm' {α : Type uα} {F : Type uF} [MeasurableSpace α] + [NormedAddCommGroup F] {μ : Measure α} {f : α → F} + (hf : AEStronglyMeasurable f μ) : eLpNorm f 2 μ = eLpNorm' f 2 μ := by + simpa using eLpNorm_eq_eLpNorm' (p := 2) (by norm_num) (by norm_num) hf + +lemma eLpNorm_lt_of_bound {α : Type uα} {F : Type uF} {K : Type uK} [MeasurableSpace α] + [NormedAddCommGroup F] [NormedAddCommGroup K] {μ : Measure α} + {f : α → F} {g : α → K} {C ε : ℝ} (hC : 0 < C) + (hb : ∀ᵐ x ∂μ, ‖f x‖ ≤ C * ‖g x‖) + (hg : eLpNorm' g 2 μ < ENNReal.ofReal (ε / C)) : + eLpNorm' f 2 μ < ENNReal.ofReal ε := by + have hbound := eLpNorm'_le_nnreal_smul_eLpNorm'_of_ae_le_mul + (f := f) (g := g) (c := ⟨C, hC.le⟩) (p := 2) + (by filter_upwards [hb] with x hx; exact_mod_cast hx) (by norm_num) + calc + _ ≤ ENNReal.ofReal C * eLpNorm' g 2 μ := by + rw [ENNReal.ofReal_eq_coe_nnreal hC.le] + exact hbound + _ < ENNReal.ofReal C * ENNReal.ofReal (ε / C) := + ENNReal.mul_lt_mul_right (ENNReal.ofReal_pos.mpr hC).ne' ENNReal.ofReal_ne_top hg + _ = ENNReal.ofReal ε := by + rw [← ENNReal.ofReal_mul hC.le, mul_div_cancel₀ _ hC.ne'] + +lemma eLpNorm_lt_of_bound_of_aestronglyMeasurable + {α : Type uα} {F : Type uF} {K : Type uK} [MeasurableSpace α] + [NormedAddCommGroup F] [NormedAddCommGroup K] {μ : Measure α} + {f : α → F} {g : α → K} {C ε : ℝ} (hC : 0 < C) + (hf : AEStronglyMeasurable f μ) + (hb : ∀ᵐ x ∂μ, ‖f x‖ ≤ C * ‖g x‖) + (hg : eLpNorm g 2 μ < ENNReal.ofReal (ε / C)) : + eLpNorm f 2 μ < ENNReal.ofReal ε := by + have hg_meas := aestronglyMeasurable_of_eLpNorm_ne_top (ne_top_of_lt hg) + rw [eLpNorm_two_eq_eLpNorm' hf] + rw [eLpNorm_two_eq_eLpNorm' hg_meas] at hg + exact eLpNorm_lt_of_bound hC hb hg + +/-- Multiplying an arbitrary zero-trace Sobolev function by a smooth cutoff +preserves zero trace, with the genuine weak product-rule gradient. -/ +lemma H10.mul_test (hu : H10 D u G) {φ : Space d → ℝ} (hφ : Test D φ) : + H10 D (fun x => φ x * u x) + (fun x => φ x • G x + u x • gradient φ x) := by + obtain ⟨C₀, hC₀⟩ := hφ.1.continuous.norm.bddAbove_range_of_hasCompactSupport hφ.2.1.norm + obtain ⟨C₁, hC₁⟩ := hφ.continuous_gradient.norm.bddAbove_range_of_hasCompactSupport + hφ.compact_gradient.norm + let C := max (max C₀ C₁) 1 + have hC : 0 < C := lt_of_lt_of_le zero_lt_one (le_max_right _ _) + have hbφ (x : Space d) : ‖φ x‖ ≤ C := + (hC₀ (mem_range_self x)).trans ((le_max_left _ _).trans (le_max_left _ _)) + have hbg (x : Space d) : ‖gradient φ x‖ ≤ C := + (hC₁ (mem_range_self x)).trans ((le_max_right _ _).trans (le_max_left _ _)) + refine ⟨hu.1.mul_test hφ, ?_⟩ + intro ε hε + obtain ⟨ψ, hψ, hψu, hψG⟩ := hu.2 ((ε / 2) / C) (by positivity) + have huφ : eLpNorm (fun x => φ x * (u x - ψ x)) 2 (volume.restrict D) < + ENNReal.ofReal (ε / 2) := + eLpNorm_lt_of_bound_of_aestronglyMeasurable hC + (hφ.memLp.aestronglyMeasurable.mul (hu.1.1.sub hψ.memLp).aestronglyMeasurable) + (ae_of_all _ fun x => by rw [norm_mul]; exact mul_le_mul_of_nonneg_right (hbφ x) (norm_nonneg _)) hψu + have hGφ : eLpNorm (fun x => φ x • (G x - gradient ψ x)) 2 (volume.restrict D) < + ENNReal.ofReal (ε / 2) := + eLpNorm_lt_of_bound_of_aestronglyMeasurable hC + (hφ.memLp.aestronglyMeasurable.smul (hu.1.2.1.sub hψ.memLp_gradient).aestronglyMeasurable) + (ae_of_all _ fun x => by rw [norm_smul]; exact mul_le_mul_of_nonneg_right (hbφ x) (norm_nonneg _)) hψG + have hug : eLpNorm (fun x => (u x - ψ x) • gradient φ x) 2 (volume.restrict D) < + ENNReal.ofReal (ε / 2) := + eLpNorm_lt_of_bound_of_aestronglyMeasurable hC + ((hu.1.1.sub hψ.memLp).aestronglyMeasurable.smul hφ.memLp_gradient.aestronglyMeasurable) + (ae_of_all _ fun x => by + rw [norm_smul, mul_comm] + exact mul_le_mul_of_nonneg_right (hbg x) (norm_nonneg _)) hψu + refine ⟨fun x => φ x * ψ x, hφ.mul hψ, ?_, ?_⟩ + · simpa only [mul_sub] using huφ.trans_le (ENNReal.ofReal_le_ofReal (by linarith : ε / 2 ≤ ε)) + · have heq : (fun x => φ x • G x + u x • gradient φ x - + gradient (fun y => φ y * ψ y) x) = + (fun x => φ x • (G x - gradient ψ x)) + + (fun x => (u x - ψ x) • gradient φ x) := by + funext x + rw [hφ.gradient_mul hψ] + simp only [Pi.add_apply, smul_sub, sub_smul] + abel + rw [heq] + calc + _ ≤ eLpNorm (fun x => φ x • (G x - gradient ψ x)) 2 (volume.restrict D) + + eLpNorm (fun x => (u x - ψ x) • gradient φ x) 2 (volume.restrict D) := + eLpNorm_add_le (by norm_num) + _ < ENNReal.ofReal (ε / 2) + ENNReal.ofReal (ε / 2) := ENNReal.add_lt_add hGφ hug + _ = ENNReal.ofReal ε := by + rw [← ENNReal.ofReal_add (by positivity) (by positivity)] + congr 1 + ring + +end Localization +end Bernoulli + +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology Convolution + +namespace Bernoulli.Mollification +open scoped _root_.Bernoulli + +variable {d : ℕ} +abbrev Space (d : ℕ) := EuclideanSpace ℝ (Fin d) +variable {F : Type uF} [NormedAddCommGroup F] + +/-- Translation on the actual Lebesgue L² space. -/ +def translate (f : Lp F 2 (volume : Measure (Space d))) (y : Space d) : + Lp F 2 (volume : Measure (Space d)) := + Lp.compMeasurePreserving (fun x => x - y) (measurePreserving_sub_right volume y) f + +lemma continuous_translate (f : Lp F 2 (volume : Measure (Space d))) : + Continuous (translate f) := by + let shifts : Space d → C(Space d, Space d) := + fun y => ⟨fun x => x - y, continuous_id.sub continuous_const⟩ + have hc : Continuous shifts := ContinuousMap.continuous_of_continuous_uncurry _ + (continuous_snd.sub continuous_fst) + exact continuous_const.compMeasurePreservingLp hc + (fun y => measurePreserving_sub_right volume y) (by norm_num) + +lemma coeFn_translate (f : Lp F 2 (volume : Measure (Space d))) (y : Space d) : + translate f y =ᵐ[volume] fun x => f (x - y) := + Lp.coeFn_compMeasurePreserving f (measurePreserving_sub_right volume y) + +@[simp] lemma translate_zero (f : Lp F 2 (volume : Measure (Space d))) : + translate f 0 = f := by + apply Lp.ext + simpa using coeFn_translate f 0 + +@[simp] lemma norm_translate (f : Lp F 2 (volume : Measure (Space d))) (y : Space d) : + ‖translate f y‖ = ‖f‖ := by + exact Lp.norm_compMeasurePreserving f (measurePreserving_sub_right volume y) + +lemma translate_toLp {f : Space d → F} (hf : MemLp f 2 volume) (y : Space d) : + translate (hf.toLp f) y = (hf.comp_measurePreserving + (measurePreserving_sub_right volume y)).toLp (fun x => f (x - y)) := by + apply Lp.ext + exact (coeFn_translate (hf.toLp f) y).trans + (((measurePreserving_sub_right volume y).quasiMeasurePreserving.ae_eq_comp hf.coeFn_toLp).trans + (hf.comp_measurePreserving (measurePreserving_sub_right volume y)).coeFn_toLp.symm) + +lemma eLpNorm_translate_tendsto {f : Space d → F} (hf : MemLp f 2 volume) : + Tendsto (fun y : Space d => eLpNorm (fun x => f (x - y) - f x) 2 volume) + (𝓝 0) (𝓝 0) := by + have hn := (((continuous_translate (hf.toLp f)).sub + (continuous_const (y := hf.toLp f))).continuousAt (x := (0 : Space d))).enorm + have heq (y : Space d) : ‖translate (hf.toLp f) y - hf.toLp f‖ₑ = + eLpNorm (fun x => f (x - y) - f x) 2 volume := by + rw [translate_toLp hf, ← MemLp.toLp_sub, Lp.enorm_toLp] + rfl + simpa [ContinuousAt, Pi.sub_apply, heq] using hn + +section Inner +variable [InnerProductSpace ℝ F] [CompleteSpace F] + +omit [CompleteSpace F] in +lemma integrable_inner_of_memLp {α : Type uα} [MeasurableSpace α] {μ : Measure α} + {f g : α → F} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : + Integrable (fun x => inner ℝ (f x) (g x)) μ := by + exact (hf.norm.integrable_mul hg.norm).mono' + (hf.aestronglyMeasurable.inner hg.aestronglyMeasurable) + (ae_of_all _ fun x => norm_inner_le_norm (f x) (g x)) + +lemma integral_inner_bound {α : Type uα} {K : Type uK} [MeasurableSpace α] + [NormedAddCommGroup K] [InnerProductSpace ℝ K] [CompleteSpace K] + {μ : Measure α} {f g : α → K} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : + |∫ x, inner ℝ (f x) (g x) ∂μ| ≤ + (eLpNorm f 2 μ).toReal * (eLpNorm g 2 μ).toReal := by + have he : (∫ x, inner ℝ (f x) (g x) ∂μ) = + inner ℝ (hf.toLp f) (hg.toLp g) := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [hf.coeFn_toLp, hg.coeFn_toLp] with x hx hy + rw [hx, hy] + rw [he, ← Lp.norm_toLp f hf, ← Lp.norm_toLp g hg] + exact abs_real_inner_le_norm _ _ + +omit [CompleteSpace F] in +lemma integral_norm_inner_bound {α : Type uα} [MeasurableSpace α] {μ : Measure α} + {f g : α → F} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : + (∫ x, ‖inner ℝ (f x) (g x)‖ ∂μ) ≤ + (eLpNorm f 2 μ).toReal * (eLpNorm g 2 μ).toReal := by + calc + _ ≤ ∫ x, ‖f x‖ * ‖g x‖ ∂μ := + integral_mono (integrable_inner_of_memLp hf hg).norm (hf.norm.integrable_mul hg.norm) + (fun x => norm_inner_le_norm (f x) (g x)) + _ ≤ |∫ x, ‖f x‖ * ‖g x‖ ∂μ| := le_abs_self _ + _ ≤ _ := by + simpa only [Real.inner_apply, eLpNorm_norm _ hf.aestronglyMeasurable, + eLpNorm_norm _ hg.aestronglyMeasurable] using integral_inner_bound hf.norm hg.norm + +omit [CompleteSpace F] in +/-- The Fubini integrability needed to compare a pointwise convolution with +its Bochner integral in L². The testing function is arbitrary L². -/ +lemma integrable_convolution_inner {κ : Space d → ℝ} {f g : Space d → F} + (hκ : Integrable κ volume) (hf : MemLp f 2 volume) (hg : MemLp g 2 volume) : + Integrable (fun p : Space d × Space d => + inner ℝ (κ p.2 • f (p.1 - p.2)) (g p.1)) (volume.prod volume) := by + have hmeas : AEStronglyMeasurable (fun p : Space d × Space d => + inner ℝ (κ p.2 • f (p.1 - p.2)) (g p.1)) (volume.prod volume) := + (hκ.aestronglyMeasurable.convolution_integrand (ContinuousLinearMap.lsmul ℝ ℝ) + hf.aestronglyMeasurable).inner + (hg.aestronglyMeasurable.comp_quasiMeasurePreserving Measure.quasiMeasurePreserving_fst) + rw [integrable_prod_iff' hmeas] + have hft (y : Space d) : MemLp (fun x => f (x - y)) 2 volume := + hf.comp_measurePreserving (measurePreserving_sub_right volume y) + refine ⟨ae_of_all _ fun y => ?_, ?_⟩ + · simpa only [real_inner_smul_left] using + (integrable_inner_of_memLp (hft y) hg).const_mul (κ y) + · have hm : AEStronglyMeasurable (fun y : Space d => + ∫ x : Space d, ‖inner ℝ (κ y • f (x - y)) (g x)‖) volume := + hmeas.prod_swap.norm.integral_prod_right' + apply Integrable.mono' (hκ.norm.mul_const + ((eLpNorm f 2 volume).toReal * (eLpNorm g 2 volume).toReal)) hm + apply ae_of_all + intro y + rw [Real.norm_of_nonneg (integral_nonneg fun x => norm_nonneg _)] + simp_rw [real_inner_smul_left, norm_mul, integral_const_mul] + apply mul_le_mul_of_nonneg_left _ (norm_nonneg _) + have hi := integral_norm_inner_bound (hft y) hg + have heq : eLpNorm (fun x => f (x - y)) 2 volume = eLpNorm f 2 volume := + eLpNorm_comp_measurePreserving hf.aestronglyMeasurable (measurePreserving_sub_right volume y) + rwa [heq] at hi + +omit [CompleteSpace F] in +lemma memLp_convolution {κ : Space d → ℝ} {f : Space d → F} + (hκ : Continuous κ) (hcκ : HasCompactSupport κ) + (hf : MemLp f 2 volume) (hcf : HasCompactSupport f) : + MemLp (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) 2 volume := + (hcκ.continuous_convolution_left (ContinuousLinearMap.lsmul ℝ ℝ) hκ + (hf.locallyIntegrable (by norm_num))).memLp_of_hasCompactSupport + (hcκ.convolution (ContinuousLinearMap.lsmul ℝ ℝ) hcf) + +/-- A pointwise mollification is the same element of L² as the Bochner +average of translates. This proof includes the Fubini and representative bridge. -/ +lemma convolution_toLp_eq_integral_translate {κ : Space d → ℝ} {f : Space d → F} + (hκ : Continuous κ) (hcκ : HasCompactSupport κ) + (hf : MemLp f 2 volume) (hcf : HasCompactSupport f) : + (memLp_convolution hκ hcκ hf hcf).toLp + (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) = + ∫ y, κ y • translate (hf.toLp f) y := by + have hiκ : Integrable κ volume := hκ.integrable_of_hasCompactSupport hcκ + have hLpInt : Integrable (fun y => κ y • translate (hf.toLp f) y) volume := + (hκ.smul (continuous_translate (hf.toLp f))).integrable_of_hasCompactSupport hcκ.smul_right + have hce := hcκ.convolutionExists_left (ContinuousLinearMap.lsmul ℝ ℝ) hκ + (hf.locallyIntegrable (by norm_num)) + apply ext_inner_left ℝ + intro g + rw [← integral_inner hLpInt g] + have htrans (y : Space d) : inner ℝ g (translate (hf.toLp f) y) = + ∫ x, inner ℝ (g x) (f (x - y)) := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [coeFn_translate (hf.toLp f) y, + (measurePreserving_sub_right volume y).quasiMeasurePreserving.ae_eq_comp hf.coeFn_toLp] + with x hx hy + rw [hx] + exact congrArg (inner ℝ (g x)) hy + have hFubini : Integrable (fun p : Space d × Space d => + inner ℝ (g p.1) (κ p.2 • f (p.1 - p.2))) (volume.prod volume) := by + simpa only [real_inner_comm] using integrable_convolution_inner hiκ hf (Lp.memLp g) + calc + _ = ∫ x, inner ℝ (g x) ((κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) x) := by + rw [L2.inner_def] + apply integral_congr_ae + filter_upwards [(memLp_convolution hκ hcκ hf hcf).coeFn_toLp] with x hx + rw [hx] + _ = ∫ x, ∫ y, inner ℝ (g x) (κ y • f (x - y)) := by + apply integral_congr_ae + exact ae_of_all _ fun x => (integral_inner (hce x) (g x)).symm + _ = ∫ y, ∫ x, inner ℝ (g x) (κ y • f (x - y)) := + integral_integral_swap hFubini + _ = ∫ y, inner ℝ g (κ y • translate (hf.toLp f) y) := by + apply integral_congr_ae + apply ae_of_all + intro y + simp_rw [real_inner_smul_right, integral_const_mul, htrans] + +/-- L² convergence of compactly supported mollifications. It applies at +once to the function and its weak gradient, once the weak derivative identity +has been proved. -/ +lemma convolution_toLp_tendsto {ι : Type uι} {l : Filter ι} + {φ : ι → ContDiffBump (0 : Space d)} {f : Space d → F} + (hφ : Tendsto (fun i => (φ i).rOut) l (𝓝 0)) + (hf : MemLp f 2 volume) (hcf : HasCompactSupport f) : + Tendsto (fun i => (memLp_convolution (φ i).continuous_normed + (φ i).hasCompactSupport_normed hf hcf).toLp + ((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f)) l + (𝓝 (hf.toLp f)) := by + have hc : Continuous (fun y : Space d => translate (hf.toLp f) (-y)) := + (continuous_translate (hf.toLp f)).comp continuous_neg + have ht := ContDiffBump.convolution_tendsto_right_of_continuous (μ := volume) hφ hc 0 + have heq (i : ι) : + (((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] + (fun y => translate (hf.toLp f) (-y))) 0) = + (memLp_convolution (φ i).continuous_normed (φ i).hasCompactSupport_normed hf hcf).toLp + ((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) := by + rw [convolution_toLp_eq_integral_translate (φ i).continuous_normed + (φ i).hasCompactSupport_normed hf hcf] + simp only [convolution_def, ContinuousLinearMap.lsmul_apply, zero_sub, neg_neg] + simpa only [heq, neg_zero, translate_zero] using ht + +lemma eLpNorm_convolution_sub_tendsto {ι : Type uι} {l : Filter ι} + {φ : ι → ContDiffBump (0 : Space d)} {f : Space d → F} + (hφ : Tendsto (fun i => (φ i).rOut) l (𝓝 0)) + (hf : MemLp f 2 volume) (hcf : HasCompactSupport f) : + Tendsto (fun i => eLpNorm + (fun x => ((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) x - f x) + 2 volume) l (𝓝 0) := by + have ht := ((convolution_toLp_tendsto hφ hf hcf).sub + (tendsto_const_nhds (x := hf.toLp f))).enorm + have heq (i : ι) : + ‖(memLp_convolution (φ i).continuous_normed (φ i).hasCompactSupport_normed hf hcf).toLp + ((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) - hf.toLp f‖ₑ = + eLpNorm + (fun x => ((φ i).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] f) x - f x) + 2 volume := by + rw [← MemLp.toLp_sub, Lp.enorm_toLp] + rfl + simpa only [heq, sub_self, enorm_zero] using ht + +end Inner + +end Bernoulli.Mollification + +namespace Bernoulli.SobolevDensity +open scoped _root_.Bernoulli +open scoped Convolution +variable {d : ℕ} + +lemma test_reflected {κ : Space d → ℝ} (hκ : Test univ κ) (x : Space d) : + Test univ (fun y => κ (x - y)) := by + refine ⟨hκ.1.comp (contDiff_const.sub contDiff_id), ?_, subset_univ _⟩ + exact hκ.2.1.comp_homeomorph (Homeomorph.subLeft x) + +lemma fderiv_reflected {κ : Space d → ℝ} (hκ : ContDiff ℝ ∞ κ) + (x y h : Space d) : + fderiv ℝ (fun z => κ (x - z)) y h = -(fderiv ℝ κ (x - y) h) := by + have hd := (hκ.differentiable (by simp) (x - y)).hasFDerivAt.comp y + ((hasFDerivAt_id y).const_sub x) + change HasFDerivAt (fun z => κ (x - z)) _ y at hd + rw [hd.fderiv] + simp + +lemma gradient_convolution {κ u : Space d → ℝ} {G : Space d → Space d} + (hκ : Test univ κ) (hu : H1 univ u G) (x : Space d) : + gradient (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u) x = + (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] G) x := by + have hfu : MemLp u 2 volume := by simpa using hu.1 + have hfG : MemLp G 2 volume := by simpa using hu.2.1 + have hlocu : LocallyIntegrable u volume := hfu.locallyIntegrable (by norm_num) + have hlocG : LocallyIntegrable G volume := hfG.locallyIntegrable (by norm_num) + have hκ₁ : ContDiff ℝ 1 κ := hκ.1.of_le (by simp) + have hder := hκ.2.1.hasFDerivAt_convolution_right + (ContinuousLinearMap.lsmul ℝ ℝ).flip hlocu hκ₁ x + have heq : u ⋆[(ContinuousLinearMap.lsmul ℝ ℝ).flip, volume] κ = + κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u := convolution_flip _ + rw [heq] at hder + apply ext_inner_right ℝ + intro h + rw [inner_gradient_left, hder.fderiv, + convolution_precompR_apply _ hlocu (hκ.2.1.fderiv ℝ) + (hκ.1.continuous_fderiv (by simp))] + have hw := hu.2.2 _ (test_reflected hκ x) h + simp only [Measure.restrict_univ, fderiv_reflected hκ.1, mul_neg, + integral_neg] at hw + have hw' := neg_injective hw + rw [convolution_lsmul_swap, real_inner_comm] + have hi := hκ.2.1.convolutionExists_right + (ContinuousLinearMap.lsmul ℝ ℝ).flip hlocG hκ.1.continuous x + have hi' : Integrable (fun y => κ (x - y) • G y) volume := hi + rw [← integral_inner hi'] + simp only [convolution_def, ContinuousLinearMap.flip_apply, + ContinuousLinearMap.lsmul_apply, smul_eq_mul] + calc + _ = ∫ y, u y * fderiv ℝ κ (x - y) h := by + apply integral_congr_ae + exact ae_of_all _ fun y => mul_comm _ _ + _ = ∫ y, inner ℝ (G y) h * κ (x - y) := hw' + _ = _ := by + apply integral_congr_ae + exact ae_of_all _ fun y => by + dsimp only + rw [real_inner_smul_right, real_inner_comm] + ring + +open scoped Pointwise + +lemma tsupport_convolution_subset {κ : Space d → ℝ} {u : Space d → ℝ} + (hκ : HasCompactSupport κ) (hu : HasCompactSupport u) : + tsupport (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u) ⊆ tsupport κ + tsupport u := by + apply closure_minimal + · exact (support_convolution_subset _).trans + (Set.add_subset_add (subset_tsupport κ) (subset_tsupport u)) + · exact (hκ.isCompact.add hu.isCompact).isClosed + +lemma tsupport_mollification_subset {u : Space d → ℝ} (hu : HasCompactSupport u) + (φ : ContDiffBump (0 : Space d)) {δ : ℝ} (hδ : φ.rOut < δ) : + tsupport (φ.normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u) ⊆ + Metric.thickening δ (tsupport u) := by + intro x hx + obtain ⟨a, ha, b, hb, rfl⟩ := tsupport_convolution_subset φ.hasCompactSupport_normed hu hx + rw [φ.tsupport_normed_eq, mem_closedBall_zero_iff] at ha + apply Metric.mem_thickening_iff.mpr + refine ⟨b, hb, ?_⟩ + simpa [dist_eq_norm] using ha.trans_lt hδ + +/-- A fixed sequence of positive-radius smooth normalized mollifiers. -/ +def bumps (d : ℕ) (n : ℕ) : ContDiffBump (0 : Space d) where + rIn := 1 / (2 * ((n : ℝ) + 1)) + rOut := 1 / ((n : ℝ) + 1) + rIn_pos := by positivity + rIn_lt_rOut := by + have hn : 0 < (n : ℝ) + 1 := by positivity + apply one_div_lt_one_div_of_lt hn + nlinarith + +lemma bumps_tendsto (d : ℕ) : Tendsto (fun n => (bumps d n).rOut) atTop (𝓝 0) := + tendsto_one_div_add_atTop_nhds_zero_nat + +/-- Simultaneous weak-H¹ mollification, including support inside the open +set. The gradient convergence is proved, not demanded of the approximants. -/ +lemma h10_of_compact_support {D : Set (Space d)} (hD : IsOpen D) + {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 univ u G) (hcu : HasCompactSupport u) (hcG : HasCompactSupport G) + (hsu : tsupport u ⊆ D) : H10 D u G := by + have huD : H1 D u G := hu.mono (subset_univ D) + refine ⟨huD, fun ε hε => ?_⟩ + obtain ⟨δ, hδ, hδD⟩ := hcu.isCompact.exists_thickening_subset_open hD hsu + have hfu : MemLp u 2 volume := by simpa using hu.1 + have hfG : MemLp G 2 volume := by simpa using hu.2.1 + have hε' : (0 : ℝ≥0∞) < ENNReal.ofReal ε := ENNReal.ofReal_pos.mpr hε + have htu := Mollification.eLpNorm_convolution_sub_tendsto (bumps_tendsto d) hfu hcu + have htG := Mollification.eLpNorm_convolution_sub_tendsto (bumps_tendsto d) hfG hcG + have hst : ∀ᶠ n : ℕ in atTop, + (bumps d n).rOut < δ ∧ + eLpNorm (fun x => ((bumps d n).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u) x - u x) + 2 volume < ENNReal.ofReal ε ∧ + eLpNorm (fun x => ((bumps d n).normed volume ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] G) x - G x) + 2 volume < ENNReal.ofReal ε := by + exact ((bumps_tendsto d).eventually_lt_const hδ).and + ((htu.eventually_lt_const hε').and (htG.eventually_lt_const hε')) + obtain ⟨n, hnδ, hnu, hnG⟩ := hst.exists + let κ := (bumps d n).normed volume + have hκ : Test univ κ := + ⟨(bumps d n).contDiff_normed, (bumps d n).hasCompactSupport_normed, subset_univ _⟩ + have hφ : Test D (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u) := by + refine ⟨hκ.2.1.contDiff_convolution_left _ hκ.1 (hfu.locallyIntegrable (by norm_num)), + hκ.2.1.convolution _ hcu, ?_⟩ + exact (tsupport_mollification_subset hcu (bumps d n) hnδ).trans hδD + refine ⟨_, hφ, ?_, ?_⟩ + · apply lt_of_le_of_lt (eLpNorm_mono_measure _ Measure.restrict_le_self) + change eLpNorm (u - (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] u)) 2 volume < _ + rw [eLpNorm_sub_comm] + exact hnu + · simp_rw [gradient_convolution hκ hu] + apply lt_of_le_of_lt (eLpNorm_mono_measure _ Measure.restrict_le_self) + change eLpNorm (G - (κ ⋆[ContinuousLinearMap.lsmul ℝ ℝ, volume] G)) 2 volume < _ + rw [eLpNorm_sub_comm] + exact hnG + +end Bernoulli.SobolevDensity + +namespace Bernoulli.SobolevDensity +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} + +lemma memLp_global_of_zero_outside {F : Type uF} [NormedAddCommGroup F] + {f : Space d → F} (hD : MeasurableSet D) (hf : MemLp f 2 (volume.restrict D)) + (hz : ∀ x ∉ D, f x = 0) : MemLp f 2 volume := by + have heq : D.indicator f = f := by + funext x + by_cases hx : x ∈ D + · simp [hx] + · simp [hx, hz x hx] + rw [← heq] + exact (memLp_indicator_iff_restrict hD).mpr hf + +/-- A compactly supported smooth cutoff of a local weak H¹ function is a +whole-space weak H¹ function, with the actual product-rule gradient. -/ +lemma h1_mul_test_global {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) (hD : MeasurableSet D) + {φ : Space d → ℝ} (hφ : Test D φ) : + H1 univ (fun x => φ x * u x) + (fun x => φ x • G x + u x • gradient φ x) := by + have hφU := hφ.mono (subset_univ D) + have hzφ (x : Space d) (hx : x ∉ D) : φ x = 0 := hφ.eq_zero_outside hx + have hzg (x : Space d) (hx : x ∉ D) : gradient φ x = 0 := hφ.gradient_eq_zero_outside hx + have hum : MemLp (fun x => φ x * u x) 2 volume := + memLp_global_of_zero_outside hD (hφ.memLp_top.fun_mul hu.1) + (fun x hx => by rw [hzφ x hx, zero_mul]) + have hGm : MemLp (fun x => φ x • G x) 2 volume := + memLp_global_of_zero_outside hD (hφ.memLp_top.smul hu.2.1) + (fun x hx => by rw [hzφ x hx, zero_smul]) + have hgm : MemLp (fun x => u x • gradient φ x) 2 volume := + memLp_global_of_zero_outside hD (hu.1.smul hφ.memLp_gradient_top) + (fun x hx => by rw [hzg x hx, smul_zero]) + refine ⟨by simpa using hum, by rw [Measure.restrict_univ]; exact hGm.add hgm, ?_⟩ + intro ψ hψ h + have hφψ : Test D (fun x => φ x * ψ x) := + ⟨hφ.1.mul hψ.1, hφ.2.1.mul_right, + (tsupport_mul_subset_left (f := φ) (g := ψ)).trans hφ.2.2⟩ + have hi := integrable_deriv_product (D := univ) (by simpa using hum) hψ h + have hij := integrable_inner_test (D := univ) (by simpa using hgm) hψ h + have hik := integrable_inner_test (D := univ) (by simpa using hGm) hψ h + simp only [Measure.restrict_univ, real_inner_smul_left, inner_gradient_left] at hi hij hik + have hderiv (x : Space d) : + u x * (fderiv ℝ (fun y => φ y * ψ y) x) h = + (φ x * u x) * (fderiv ℝ ψ x) h + (u x * (fderiv ℝ φ x) h) * ψ x := by + rw [← inner_gradient_left, hφU.gradient_mul hψ, + inner_add_left, real_inner_smul_left, real_inner_smul_left, + inner_gradient_left, inner_gradient_left] + ring + have hweak := hu.2.2 _ hφψ h + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφψ.fderiv_eq_zero_outside hx]; simp), + setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφψ.eq_zero_outside hx, mul_zero])] at hweak + simp_rw [hderiv] at hweak + rw [integral_add hi hij] at hweak + have hright (x : Space d) : inner ℝ (G x) h * (φ x * ψ x) = + (φ x * inner ℝ (G x) h) * ψ x := by ring + simp_rw [hright] at hweak + simp only [Measure.restrict_univ, inner_add_left, real_inner_smul_left, + inner_gradient_left, add_mul] + rw [integral_add hik hij] + linarith + +lemma h10_mul_test {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) (hD : IsOpen D) {φ : Space d → ℝ} (hφ : Test D φ) : + H10 D (fun x => φ x * u x) + (fun x => φ x • G x + u x • gradient φ x) := by + have hcu : HasCompactSupport (fun x => φ x * u x) := hφ.2.1.mul_right + have hφs : Test (tsupport φ) φ := ⟨hφ.1, hφ.2.1, subset_rfl⟩ + have hcG : HasCompactSupport (fun x => φ x • G x + u x • gradient φ x) := by + apply HasCompactSupport.intro hφ.2.1.isCompact + intro x hx + rw [hφs.eq_zero_outside hx, hφs.gradient_eq_zero_outside hx] + simp + have hsu : tsupport (fun x => φ x * u x) ⊆ D := + (tsupport_mul_subset_left (f := φ) (g := u)).trans hφ.2.2 + exact h10_of_compact_support hD (h1_mul_test_global hu hD.measurableSet hφ) hcu hcG hsu + +end Bernoulli.SobolevDensity + +namespace Bernoulli +open scoped _root_.Bernoulli +namespace LipschitzSobolev +variable {d : ℕ} {u : Space d → ℝ} {K : NNReal} + +lemma measurable_gradient : Measurable (gradient u) := by + exact (InnerProductSpace.toDual ℝ (Space d)).symm.continuous.measurable.comp + (measurable_fderiv ℝ u) + +lemma norm_gradient_le (hu : LipschitzWith K u) (x : Space d) : + ‖gradient u x‖ ≤ K := by + simpa only [gradient, LinearIsometryEquiv.norm_map] using + norm_fderiv_le_of_lipschitz ℝ (x₀ := x) hu + +lemma weakGradient (hu : LipschitzWith K u) (D : Set (Space d)) : + WeakGradient D u (gradient u) := by + intro φ hφ h + have hφdiff := hφ.1.differentiable (by simp) + obtain ⟨C, hφlip⟩ := hφ.1.lipschitzWith_of_hasCompactSupport hφ.2.1 (by simp) + have heq := hu.integral_lineDeriv_mul_eq (μ := volume) hφlip hφ.2.1 h + have hleft : (fun x => lineDeriv ℝ u x h * φ x) =ᵐ[volume] + (fun x => inner ℝ (gradient u x) h * φ x) := by + filter_upwards [hu.ae_differentiableAt] with x hx + rw [hx.lineDeriv_eq_fderiv, inner_gradient_left] + have hright : (fun x => lineDeriv ℝ φ x (-h) * u x) = + (fun x => -(u x * (fderiv ℝ φ x) h)) := by + funext x + rw [(hφdiff x).lineDeriv_eq_fderiv, map_neg] + ring + rw [integral_congr_ae hleft, hright, integral_neg] at heq + rw [setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + have hne : x ∉ tsupport φ := fun hx' => hx (hφ.2.2 hx') + rw [fderiv_of_notMem_tsupport ℝ hne, zero_apply, mul_zero]), + setIntegral_eq_integral_of_forall_compl_eq_zero (fun x hx => by + rw [hφ.eq_zero_outside hx, mul_zero])] + linarith + +lemma h1_ball (hu : LipschitzWith K u) (c : Space d) (r : ℝ) : + H1 (Metric.ball c r) u (gradient u) := by + let : IsFiniteMeasure (volume.restrict (Metric.ball c r)) := + isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + refine ⟨?_, ?_, weakGradient hu _⟩ + · apply MemLp.of_bound hu.continuous.aestronglyMeasurable (‖u c‖ + K * max r 0) + filter_upwards [ae_restrict_mem measurableSet_ball] with x hx + calc ‖u x‖ ≤ ‖u c‖ + ‖u x - u c‖ := norm_le_insert' _ _ + _ ≤ ‖u c‖ + K * dist x c := by + gcongr + simpa only [dist_eq_norm] using hu.norm_sub_le x c + _ ≤ ‖u c‖ + K * max r 0 := by + gcongr + exact (Metric.mem_ball.mp hx).le.trans (le_max_left _ _) + · exact MemLp.of_bound measurable_gradient.aestronglyMeasurable K + (Filter.Eventually.of_forall (norm_gradient_le hu)) + +lemma compact_gradient (hc : HasCompactSupport u) : HasCompactSupport (gradient u) := by + exact (hc.fderiv ℝ).comp_left (map_zero (InnerProductSpace.toDual ℝ (Space d)).symm) + +lemma h1_compact (hu : LipschitzWith K u) (hc : HasCompactSupport u) : + H1 univ u (gradient u) := by + refine ⟨by simpa using hu.continuous.memLp_of_hasCompactSupport (p := 2) hc, ?_, + weakGradient hu _⟩ + rw [Measure.restrict_univ] + have hzero (x : Space d) (hx : x ∉ tsupport u) : gradient u x = 0 := by + rw [gradient, fderiv_of_notMem_tsupport ℝ hx, map_zero] + let : IsFiniteMeasure (volume.restrict (tsupport u)) := + isFiniteMeasure_restrict.mpr hc.isCompact.measure_lt_top.ne + have hmem : MemLp (gradient u) 2 (volume.restrict (tsupport u)) := + MemLp.of_bound measurable_gradient.aestronglyMeasurable K + (Filter.Eventually.of_forall (norm_gradient_le hu)) + have heq : (tsupport u).indicator (gradient u) = gradient u := by + funext x + by_cases hx : x ∈ tsupport u + · simp [hx] + · simp [hx, hzero x hx] + rw [← heq] + exact (memLp_indicator_iff_restrict (isClosed_tsupport u).measurableSet).mpr hmem + +end LipschitzSobolev +end Bernoulli + +namespace Bernoulli +open scoped _root_.Bernoulli + +lemma H1.sub {d : ℕ} {D : Set (Space d)} {u v : Space d → ℝ} + {G V : Space d → Space d} (hu : H1 D u G) (hv : H1 D v V) : + H1 D (fun x => u x - v x) (fun x => G x - V x) := by + simpa only [neg_one_mul, neg_one_smul, sub_eq_add_neg] using hu.add (hv.const_smul (-1)) + +lemma LipschitzSobolev.h10 {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} + {K : NNReal} (hu : LipschitzWith K u) (hc : HasCompactSupport u) + (hD : IsOpen D) (hs : tsupport u ⊆ D) : H10 D u (gradient u) := + SobolevDensity.h10_of_compact_support hD (LipschitzSobolev.h1_compact hu hc) hc + (LipschitzSobolev.compact_gradient hc) hs + +/-- Genuine Sobolev comparison, specialized only AFTER two explicit functions + have been shown Lipschitz and their difference compactly supported. -/ +lemma GlobalMinimizer.compare_lipschitz {d : ℕ} {u v : Space d → ℝ} {K L : NNReal} + (hm : GlobalMinimizer u) (hu : LipschitzWith K u) (hv : LipschitzWith L v) + (c : Space d) {r : ℝ} (hr : 0 < r) + (hn : ∀ᵐ x ∂volume.restrict (Metric.ball c r), 0 ≤ v x) + (hc : HasCompactSupport (fun x => v x - u x)) + (hs : tsupport (fun x => v x - u x) ⊆ Metric.ball c r) : + energy (Metric.ball c r) u (gradient u) ≤ energy (Metric.ball c r) v (gradient v) := by + obtain ⟨_, G, hG, _, hmin⟩ := hm + have huG := hG c r hr (subset_univ _) + have hu' := LipschitzSobolev.h1_ball hu c r + have hv' := LipschitzSobolev.h1_ball hv c r + have hw := LipschitzSobolev.h10 (hv.sub hu) hc Metric.isOpen_ball hs + have hweak := hv'.sub huG + have hgrad := hw.1.gradient_unique Metric.isOpen_ball hweak + have hh := hmin c r hr (subset_univ _) v (gradient v) hv' hn + (hw.congr (Filter.EventuallyEq.refl _ _) hgrad) + rwa [energy_congr (Filter.EventuallyEq.refl _ _) (huG.gradient_unique Metric.isOpen_ball hu')] at hh + +end Bernoulli + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + +/-- The closure definition itself provides smooth approximants converging + simultaneously in both L² seminorms. -/ +lemma H10_sequence (hu : H10 D u G) : + ∃ f : ℕ → Space d → ℝ, (∀ n, Test D (f n)) ∧ + Tendsto (fun n => eLpNorm (f n - u) 2 (volume.restrict D)) atTop (𝓝 0) ∧ + Tendsto (fun n => eLpNorm (gradient (f n) - G) 2 (volume.restrict D)) atTop (𝓝 0) := by + choose f hf hfu hfG using fun n : ℕ => hu.2 (1 / ((n : ℝ) + 1)) (by positivity) + refine ⟨f, hf, ?_, ?_⟩ + · have ht := ENNReal.continuous_ofReal.continuousAt.tendsto.comp + tendsto_one_div_add_atTop_nhds_zero_nat + simp only [ENNReal.ofReal_zero] at ht + apply tendsto_of_tendsto_of_tendsto_of_le_of_le tendsto_const_nhds ht (fun _ => zero_le) + intro n + dsimp only [Function.comp_apply] + rw [eLpNorm_sub_comm] + exact (hfu n).le + · have ht := ENNReal.continuous_ofReal.continuousAt.tendsto.comp + tendsto_one_div_add_atTop_nhds_zero_nat + simp only [ENNReal.ofReal_zero] at ht + apply tendsto_of_tendsto_of_tendsto_of_le_of_le tendsto_const_nhds ht (fun _ => zero_le) + intro n + dsimp only [Function.comp_apply] + rw [eLpNorm_sub_comm] + exact (hfG n).le + +lemma gradient_comp {F : ℝ → ℝ} {f : Space d → ℝ} {x : Space d} + (hF : DifferentiableAt ℝ F (f x)) (hf : DifferentiableAt ℝ f x) : + gradient (F ∘ f) x = deriv F (f x) • gradient f x := by + apply ext_inner_right ℝ + intro h + rw [inner_gradient_left, fderiv_comp x hF hf, ContinuousLinearMap.comp_apply, + fderiv_eq_deriv_mul, real_inner_smul_left, inner_gradient_left] + +lemma test_comp_h1 {F : ℝ → ℝ} {K : NNReal} {f : Space d → ℝ} + (hF : ContDiff ℝ 1 F) (hlip : LipschitzWith K F) (hz : F 0 = 0) + (hf : Test univ f) : H1 univ (F ∘ f) (fun x => deriv F (f x) • gradient f x) := by + obtain ⟨L, hL⟩ := hf.1.lipschitzWith_of_hasCompactSupport hf.2.1 (by simp) + have hm := LipschitzSobolev.h1_compact (hlip.comp hL) (hf.2.1.comp_left hz) + have heq : gradient (F ∘ f) = fun x => deriv F (f x) • gradient f x := by + funext x + exact gradient_comp (hF.differentiable (by simp) _) (hf.1.differentiable (by simp) _) + rwa [heq] at hm + +section Dominated +variable {α : Type uα} {E : Type uE} [MeasurableSpace α] {μ : Measure α} + [NormedAddCommGroup E] + +/-- L² dominated convergence, expressed in the same seminorms as `H10`. -/ +lemma tendsto_eLpNorm_zero_of_dominated {f : ℕ → α → E} {b : α → ℝ} + (hf : ∀ n, AEStronglyMeasurable (f n) μ) (hb : MemLp b 2 μ) + (hbound : ∀ n, ∀ᵐ x ∂μ, ‖f n x‖ ≤ ‖b x‖) + (hlim : ∀ᵐ x ∂μ, Tendsto (fun n => f n x) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (f n) 2 μ) atTop (𝓝 0) := by + have hm (n : ℕ) : MemLp (f n) 2 μ := hb.mono (hf n) (hbound n) + have hi : Tendsto (fun n => ∫ x, ‖f n x‖ ^ 2 ∂μ) atTop (𝓝 0) := by + have ht := tendsto_integral_of_dominated_convergence (f := fun _ => (0 : ℝ)) + (fun x => ‖b x‖ ^ 2) + (fun n => (hf n).norm.pow 2) (hb.integrable_norm_pow (by norm_num)) ?_ ?_ + · simpa using ht + · intro n + filter_upwards [hbound n] with x hx + simpa only [Pi.pow_apply, Real.norm_eq_abs, abs_sq] using pow_le_pow_left₀ (norm_nonneg _) hx 2 + · filter_upwards [hlim] with x hx + simpa using hx.norm.pow 2 + have heq (n : ℕ) : eLpNorm (f n) 2 μ = + ENNReal.ofReal ((∫ x, ‖f n x‖ ^ 2 ∂μ) ^ (1 / 2 : ℝ)) := by + simpa using (hm n).eLpNorm_eq_integral_rpow_norm (by norm_num) (by norm_num) + simp_rw [heq] + have ht := ENNReal.continuous_ofReal.continuousAt.tendsto.comp + (hi.rpow_const (Or.inr (by norm_num : 0 ≤ (1 / 2 : ℝ)))) + convert! ht using 1 + simp + +end Dominated +end Bernoulli.SobolevCalculus + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + +lemma test_comp_h10 (hD : IsOpen D) {F : ℝ → ℝ} {K : NNReal} {f : Space d → ℝ} + (hF : ContDiff ℝ 1 F) (hlip : LipschitzWith K F) (hz : F 0 = 0) + (hf : Test D f) : H10 D (F ∘ f) (fun x => deriv F (f x) • gradient f x) := by + obtain ⟨L, hL⟩ := hf.1.lipschitzWith_of_hasCompactSupport hf.2.1 (by simp) + have hm := LipschitzSobolev.h10 (hlip.comp hL) (hf.2.1.comp_left hz) hD + ((tsupport_comp_subset hz f).trans hf.2.2) + have heq : gradient (F ∘ f) = fun x => deriv F (f x) • gradient f x := by + funext x + exact gradient_comp (hF.differentiable (by simp) _) (hf.1.differentiable (by simp) _) + rwa [heq] at hm + +lemma h10_of_strong {f : ℕ → Space d → ℝ} {V : ℕ → Space d → Space d} + (hu : MemLp u 2 (volume.restrict D)) (hG : MemLp G 2 (volume.restrict D)) + (hf : ∀ n, H10 D (f n) (V n)) + (hfu : Tendsto (fun n => eLpNorm (f n - u) 2 (volume.restrict D)) atTop (𝓝 0)) + (hfG : Tendsto (fun n => eLpNorm (V n - G) 2 (volume.restrict D)) atTop (𝓝 0)) : + H10 D u G := by + apply H10.of_approx hu hG + intro ε hε + have hp : (0 : ℝ≥0∞) < ENNReal.ofReal ε := ENNReal.ofReal_pos.mpr hε + obtain ⟨n, hn, hn'⟩ := ((hfu.eventually_lt_const hp).and (hfG.eventually_lt_const hp)).exists + refine ⟨f n, V n, hf n, ?_, ?_⟩ + · change eLpNorm (u - f n) 2 (volume.restrict D) < ENNReal.ofReal ε + rwa [eLpNorm_sub_comm] + · change eLpNorm (G - V n) 2 (volume.restrict D) < ENNReal.ofReal ε + rwa [eLpNorm_sub_comm] + +section Nemytskii +variable {α : Type uα} {E : Type uE} [MeasurableSpace α] {μ : Measure α} + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma lipschitz_tendsto_eLpNorm {f : ℕ → α → ℝ} {u : α → ℝ} + {F : ℝ → ℝ} {K : NNReal} (hF : LipschitzWith K F) + (hu : Tendsto (fun n => eLpNorm' (f n - u) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm' (F ∘ f n - F ∘ u) 2 μ) atTop (𝓝 0) := by + have ht := ENNReal.Tendsto.const_mul (a := (K : ℝ≥0∞)) hu (Or.inr ENNReal.coe_ne_top) + simp only [mul_zero] at ht + apply tendsto_of_tendsto_of_tendsto_of_le_of_le tendsto_const_nhds ht (fun _ => zero_le) + intro n + have hbound := eLpNorm'_le_nnreal_smul_eLpNorm'_of_ae_le_mul + (μ := μ) (f := F ∘ f n - F ∘ u) (g := f n - u) (c := K) (p := 2) + (Filter.Eventually.of_forall fun x => by exact_mod_cast hF.norm_sub_le (f n x) (u x)) + (by norm_num) + exact hbound + +lemma lipschitz_tendsto_eLpNorm_of_aestronglyMeasurable {f : ℕ → α → ℝ} {u : α → ℝ} + {F : ℝ → ℝ} {K : NNReal} (hF : LipschitzWith K F) + (hf : ∀ n, AEStronglyMeasurable (f n) μ) (hu_meas : AEStronglyMeasurable u μ) + (hu : Tendsto (fun n => eLpNorm (f n - u) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (F ∘ f n - F ∘ u) 2 μ) atTop (𝓝 0) := by + have hu_raw : Tendsto (fun n => eLpNorm' (f n - u) 2 μ) atTop (𝓝 0) := + hu.congr' (Eventually.of_forall fun n => eLpNorm_two_eq_eLpNorm' ((hf n).sub hu_meas)) + apply (lipschitz_tendsto_eLpNorm hF hu_raw).congr' + exact Eventually.of_forall fun n => (eLpNorm_two_eq_eLpNorm' + ((hF.continuous.comp_aestronglyMeasurable (hf n)).sub + (hF.continuous.comp_aestronglyMeasurable hu_meas))).symm + +lemma bounded_smul_tendsto {a : ℕ → α → ℝ} {b : α → ℝ} {G : α → E} {C : ℝ} + (ha : ∀ n, AEStronglyMeasurable (a n) μ) (hb : AEStronglyMeasurable b μ) + (hG : MemLp G 2 μ) (hC : 0 ≤ C) + (hab : ∀ n, ∀ᵐ x ∂μ, ‖a n x‖ ≤ C) (hbb : ∀ᵐ x ∂μ, ‖b x‖ ≤ C) + (ht : ∀ᵐ x ∂μ, Tendsto (fun n => a n x) atTop (𝓝 (b x))) : + Tendsto (fun n => eLpNorm (fun x => (a n x-b x) • G x) 2 μ) atTop (𝓝 0) := by + apply tendsto_eLpNorm_zero_of_dominated (f := fun n x => (a n x - b x) • G x) + (fun n => ((ha n).sub hb).smul hG.aestronglyMeasurable) + (hG.norm.const_smul (2*C)) + · intro n + filter_upwards [hab n, hbb] with x hx hy + simp only [Pi.smul_apply, smul_eq_mul, norm_smul, Real.norm_eq_abs, + abs_mul, abs_of_nonneg (norm_nonneg _), abs_of_nonneg (by positivity : 0 ≤ 2*C)] + have hab' : ‖a n x - b x‖ ≤ 2*C := (norm_sub_le _ _).trans (by linarith) + exact mul_le_mul_of_nonneg_right hab' (norm_nonneg _) + · filter_upwards [ht] with x hx + simpa using (hx.sub_const (b x)).smul + (tendsto_const_nhds : Tendsto (fun _ : ℕ => G x) atTop (𝓝 (G x))) + +end Nemytskii +end Bernoulli.SobolevCalculus + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +section Nemytskii +variable {α : Type uα} {E : Type uE} [MeasurableSpace α] {μ : Measure α} + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma bounded_smul_strong {a : ℕ → α → ℝ} {b : α → ℝ} + {V : ℕ → α → E} {G : α → E} {C : ℝ} + (ha : ∀ n, AEStronglyMeasurable (a n) μ) (hb : AEStronglyMeasurable b μ) + (hV : ∀ n, MemLp (V n) 2 μ) (hG : MemLp G 2 μ) (hC : 0 ≤ C) + (hab : ∀ n, ∀ᵐ x ∂μ, ‖a n x‖ ≤ C) (hbb : ∀ᵐ x ∂μ, ‖b x‖ ≤ C) + (ht : ∀ᵐ x ∂μ, Tendsto (fun n => a n x) atTop (𝓝 (b x))) + (hVG : Tendsto (fun n => eLpNorm (V n - G) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (fun x => a n x • V n x - b x • G x) 2 μ) + atTop (𝓝 0) := by + have hres := bounded_smul_tendsto ha hb hG hC hab hbb ht + have hfst := ENNReal.Tendsto.const_mul (a := ENNReal.ofReal C) hVG (Or.inr ENNReal.ofReal_ne_top) + simp only [mul_zero] at hfst + have hsum := hfst.add hres + simp only [add_zero] at hsum + apply tendsto_of_tendsto_of_tendsto_of_le_of_le tendsto_const_nhds hsum (fun _ => zero_le) + intro n + have heq : (fun x => a n x • V n x - b x • G x) = + (fun x => a n x • (V n x-G x)) + (fun x => (a n x-b x) • G x) := by + funext x + simp only [Pi.add_apply, smul_sub, sub_smul] + abel + dsimp only + rw [heq] + apply (eLpNorm_add_le (by norm_num : (1 : ℝ≥0∞) ≤ 2)).trans + apply add_le_add _ le_rfl + refine eLpNorm_le_mul_eLpNorm_of_ae_le_mul + (f := fun x => a n x • (V n x - G x)) (g := fun x => V n x - G x) + ((ha n).smul ((hV n).sub hG).aestronglyMeasurable) ?_ 2 + filter_upwards [hab n] with x hx + rw [norm_smul] + exact mul_le_mul_of_nonneg_right hx (norm_nonneg (V n x - G x)) + +end Nemytskii +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + +lemma h10_comp_C1 (hD : IsOpen D) (hu : H10 D u G) + {F : ℝ → ℝ} {K : NNReal} (hF : ContDiff ℝ 1 F) + (hlip : LipschitzWith K F) (hz : F 0 = 0) : + H10 D (F ∘ u) (fun x => deriv F (u x) • G x) := by + obtain ⟨f, hf, hfu, hfG⟩ := H10_sequence hu + obtain ⟨ns, hns, hpoint⟩ := (tendstoInMeasure_of_tendsto_eLpNorm + (by norm_num : (2 : ℝ≥0∞) ≠ 0) hfu).exists_seq_tendsto_ae + have hdc := hF.continuous_deriv (by simp) + have hdermem : MemLp (fun x => deriv F (u x)) ∞ (volume.restrict D) := + memLp_top_of_bound (hdc.comp_aestronglyMeasurable hu.1.1.aestronglyMeasurable) K + (Filter.Eventually.of_forall fun _ => norm_deriv_le_of_lipschitz hlip) + apply h10_of_strong (hlip.comp_memLp hz hu.1.1) (hdermem.smul hu.1.2.1) + (fun n => test_comp_h10 hD hF hlip hz (hf (ns n))) + · exact lipschitz_tendsto_eLpNorm_of_aestronglyMeasurable hlip + (fun n => (hf (ns n)).memLp.aestronglyMeasurable) hu.1.1.aestronglyMeasurable + (hfu.comp hns.tendsto_atTop) + · apply bounded_smul_strong + (fun n => hdc.comp_aestronglyMeasurable (hf (ns n)).memLp.aestronglyMeasurable) + (hdc.comp_aestronglyMeasurable hu.1.1.aestronglyMeasurable) + (fun n => (hf (ns n)).memLp_gradient) hu.1.2.1 K.coe_nonneg + (fun _ => Filter.Eventually.of_forall fun _ => norm_deriv_le_of_lipschitz hlip) + (Filter.Eventually.of_forall fun _ => norm_deriv_le_of_lipschitz hlip) + ?_ (hfG.comp hns.tendsto_atTop) + filter_upwards [hpoint] with x hx + exact hdc.continuousAt.tendsto.comp hx + +end Bernoulli.SobolevCalculus + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli + +def cutSlope (n : ℕ) (t : ℝ) : ℝ := min (max (((n : ℝ)+1)*t) 0) 1 + +def cutPrimitive (n : ℕ) (t : ℝ) : ℝ := ∫ s in (0 : ℝ)..t, cutSlope n s + +lemma cutSlope_continuous (n : ℕ) : Continuous (cutSlope n) := by + unfold cutSlope + fun_prop + +lemma cutSlope_nonneg (n : ℕ) (t : ℝ) : 0 ≤ cutSlope n t := + le_min (le_max_right _ _) (by norm_num) + +lemma cutSlope_le_one (n : ℕ) (t : ℝ) : cutSlope n t ≤ 1 := min_le_right _ _ + +lemma cutSlope_norm_le (n : ℕ) (t : ℝ) : ‖cutSlope n t‖ ≤ 1 := by + rw [Real.norm_eq_abs, abs_of_nonneg (cutSlope_nonneg n t)] + exact cutSlope_le_one n t + +lemma cutPrimitive_deriv (n : ℕ) (t : ℝ) : + HasDerivAt (cutPrimitive n) (cutSlope n t) t := by + exact intervalIntegral.integral_hasDerivAt_right + ((cutSlope_continuous n).intervalIntegrable _ _) + (cutSlope_continuous n).aestronglyMeasurable.stronglyMeasurableAtFilter + (cutSlope_continuous n).continuousAt + +lemma cutPrimitive_contDiff (n : ℕ) : ContDiff ℝ 1 (cutPrimitive n) := by + rw [contDiff_one_iff_deriv] + refine ⟨fun t => (cutPrimitive_deriv n t).differentiableAt, ?_⟩ + have heq : deriv (cutPrimitive n) = cutSlope n := funext fun t => + (cutPrimitive_deriv n t).deriv + rw [heq] + exact cutSlope_continuous n + +lemma cutPrimitive_lipschitz (n : ℕ) : LipschitzWith 1 (cutPrimitive n) := by + apply lipschitzWith_of_nnnorm_deriv_le (fun t => (cutPrimitive_deriv n t).differentiableAt) + intro t + rw [(cutPrimitive_deriv n t).deriv, ← NNReal.coe_le_coe] + exact cutSlope_norm_le n t + +@[simp] lemma cutPrimitive_zero (n : ℕ) : cutPrimitive n 0 = 0 := by + simp [cutPrimitive] + +lemma cutSlope_tendsto (t : ℝ) : + Tendsto (fun n => cutSlope n t) atTop (𝓝 (if 0 < t then 1 else 0)) := by + by_cases ht : 0 < t + · simp only [ite_eq_left ht] + have hg : Tendsto (fun n : ℕ => ((n : ℝ)+1)*t) atTop atTop := + (tendsto_atTop_mono (fun n : ℕ => (show (n : ℝ) ≤ (n : ℝ)+1 by linarith)) + tendsto_natCast_atTop_atTop).atTop_mul_const ht + apply tendsto_const_nhds.congr' + filter_upwards [hg.eventually_ge_atTop 1] with n hn + dsimp only [cutSlope] + exact (min_eq_right (hn.trans (le_max_left _ _))).symm + · simp only [ite_eq_right ht] + have hf (n : ℕ) : cutSlope n t = 0 := by + have hm : ((n : ℝ)+1)*t ≤ 0 := + mul_nonpos_of_nonneg_of_nonpos (by positivity) (le_of_not_gt ht) + simp [cutSlope, max_eq_right hm] + simp_rw [hf] + exact tendsto_const_nhds + +lemma integral_step (t : ℝ) : + (∫ s in (0 : ℝ)..t, if 0 < s then (1 : ℝ) else 0) = max t 0 := by + rcases le_or_gt 0 t with ht | ht + · rw [max_eq_left ht] + calc + _ = ∫ _s in (0 : ℝ)..t, (1 : ℝ) := by + apply intervalIntegral.integral_congr_ae + exact Filter.Eventually.of_forall fun s hs => by + simp only [uIoc_of_le ht, mem_Ioc] at hs + simp [hs.1] + _ = t := by simp + · rw [max_eq_right ht.le, intervalIntegral.integral_symm] + have hz : (∫ s in t..(0 : ℝ), if 0 < s then (1 : ℝ) else 0) = 0 := by + apply intervalIntegral.integral_zero_ae + exact Filter.Eventually.of_forall fun s hs => by + simp only [uIoc_of_le ht.le, mem_Ioc] at hs + simp [not_lt.mpr hs.2] + simp [hz] + +lemma cutPrimitive_tendsto (t : ℝ) : + Tendsto (fun n => cutPrimitive n t) atTop (𝓝 (max t 0)) := by + rw [← integral_step t] + apply intervalIntegral.tendsto_integral_filter_of_dominated_convergence (fun _ => (1 : ℝ)) + · exact Filter.Eventually.of_forall fun n => (cutSlope_continuous n).aestronglyMeasurable + · exact Filter.Eventually.of_forall fun n => Filter.Eventually.of_forall fun s _ => cutSlope_norm_le n s + · exact intervalIntegrable_const + · exact Filter.Eventually.of_forall fun s _ => cutSlope_tendsto s + +end Bernoulli.SobolevCalculus + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + +lemma norm_positivePart (t : ℝ) : ‖max t 0‖ ≤ ‖t‖ := by + rw [Real.norm_eq_abs, abs_of_nonneg (le_max_right _ _), Real.norm_eq_abs] + exact max_le (le_abs_self _) (abs_nonneg _) + +lemma step_memLp_top (hu : AEStronglyMeasurable u (volume.restrict D)) : + MemLp (fun x => if 0 < u x then (1 : ℝ) else 0) ∞ (volume.restrict D) := by + have hs : Measurable (fun t : ℝ => if 0 < t then (1 : ℝ) else 0) := by + exact Measurable.ite (measurableSet_lt measurable_const measurable_id) + measurable_const measurable_const + apply memLp_top_of_bound (hs.comp_aemeasurable hu.aemeasurable).aestronglyMeasurable 1 + exact Filter.Eventually.of_forall fun x => by + dsimp only [Function.comp_apply] + split_ifs <;> norm_num + +lemma h10_positivePart (hD : IsOpen D) (hu : H10 D u G) : + H10 D (fun x => max (u x) 0) + (fun x => (if 0 < u x then (1 : ℝ) else 0) • G x) := by + have hum : MemLp (fun x => max (u x) 0) 2 (volume.restrict D) := by + apply hu.1.1.mono ((continuous_id.max continuous_const).comp_aestronglyMeasurable hu.1.1.aestronglyMeasurable) + exact Filter.Eventually.of_forall fun x => norm_positivePart (u x) + have hg : MemLp (fun x => (if 0 < u x then (1 : ℝ) else 0) • G x) + 2 (volume.restrict D) := (step_memLp_top hu.1.1.aestronglyMeasurable).smul hu.1.2.1 + have hcomp (n : ℕ) : H10 D (cutPrimitive n ∘ u) (fun x => cutSlope n (u x) • G x) := by + have hh := h10_comp_C1 hD hu (cutPrimitive_contDiff n) (cutPrimitive_lipschitz n) + (cutPrimitive_zero n) + have heq : deriv (cutPrimitive n) = cutSlope n := + funext fun t => (cutPrimitive_deriv n t).deriv + rwa [heq] at hh + apply h10_of_strong hum hg hcomp + · apply tendsto_eLpNorm_zero_of_dominated + (f := fun n x => cutPrimitive n (u x) - max (u x) 0) + (fun n => ((cutPrimitive_lipschitz n).continuous.comp_aestronglyMeasurable + hu.1.1.aestronglyMeasurable).sub hum.aestronglyMeasurable) + (hu.1.1.norm.const_smul (2 : ℝ)) + · intro n + exact Filter.Eventually.of_forall fun x => by + have hn : ‖cutPrimitive n (u x)‖ ≤ ‖u x‖ := by + simpa using (cutPrimitive_lipschitz n).norm_sub_le (u x) 0 + calc + ‖cutPrimitive n (u x)-max (u x) 0‖ ≤ ‖cutPrimitive n (u x)‖ + ‖max (u x) 0‖ := norm_sub_le _ _ + _ ≤ 2*‖u x‖ := by linarith [norm_positivePart (u x)] + _ = ‖((2 : ℝ) • fun y => ‖u y‖) x‖ := by simp + · exact Filter.Eventually.of_forall fun x => by + simpa using (cutPrimitive_tendsto (u x)).sub_const (max (u x) 0) + · have ht := bounded_smul_tendsto + (fun n => (cutSlope_continuous n).comp_aestronglyMeasurable hu.1.1.aestronglyMeasurable) + (step_memLp_top hu.1.1.aestronglyMeasurable).aestronglyMeasurable + hu.1.2.1 (by norm_num : (0 : ℝ) ≤ 1) + (fun n => Filter.Eventually.of_forall fun x => cutSlope_norm_le n (u x)) + (Filter.Eventually.of_forall fun x => by split_ifs <;> norm_num) + (Filter.Eventually.of_forall fun x => cutSlope_tendsto (u x)) + simp only [sub_smul] at ht + convert! ht using 1 + +end Bernoulli.SobolevCalculus + +open scoped Manifold +namespace Bernoulli +open scoped _root_.Bernoulli +lemma exists_cutoff {d : ℕ} {K D : Set (Space d)} (hK : IsCompact K) + (hD : IsOpen D) (hKD : K ⊆ D) : + ∃ φ : Space d → ℝ, ContDiff ℝ ∞ φ ∧ HasCompactSupport φ ∧ tsupport φ ⊆ D ∧ + (∀ᶠ x in 𝓝ˢ K, φ x = 1) ∧ (∀ x, 0 ≤ φ x ∧ φ x ≤ 1) := by + obtain ⟨δ, hδ, hδD⟩ := hK.exists_thickening_subset_open hD hKD + have hki : K ⊆ interior (Metric.cthickening (δ/2) K) := by + exact (Metric.self_subset_thickening (half_pos hδ) _).trans + (Metric.thickening_subset_interior_cthickening _ _) + obtain ⟨φ, hφ1, hφ0, hφb⟩ := exists_contMDiffMap_one_nhds_of_subset_interior + (𝓘(ℝ, Space d)) (n := ⊤) hK.isClosed hki + refine ⟨φ, φ.contMDiff.contDiff, HasCompactSupport.intro (hK.cthickening) hφ0, ?_, hφ1, hφb⟩ + have hs : tsupport (φ : Space d → ℝ) ⊆ Metric.cthickening (δ/2) K := by + apply closure_minimal _ Metric.isClosed_cthickening + intro x hx + by_contra hn + exact hx (hφ0 x hn) + exact hs.trans ((Metric.cthickening_subset_thickening' hδ (by linarith) _).trans hδD) +end Bernoulli + +namespace Bernoulli +open scoped _root_.Bernoulli +lemma H1.neg {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + (hu : H1 D u G) : H1 D (fun x => -u x) (fun x => -G x) := by + simpa using hu.const_smul (-1) +end Bernoulli + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +variable {d : ℕ} {D : Set (Space d)} {u : Space d → ℝ} {G : Space d → Space d} + +lemma h1_positivePart (hD : IsOpen D) (hu : H1 D u G) : + H1 D (fun x => max (u x) 0) + (fun x => (if 0 < u x then (1 : ℝ) else 0) • G x) := by + have hum : MemLp (fun x => max (u x) 0) 2 (volume.restrict D) := by + apply hu.1.mono ((continuous_id.max continuous_const).comp_aestronglyMeasurable + hu.1.aestronglyMeasurable) + exact Filter.Eventually.of_forall fun x => norm_positivePart (u x) + refine ⟨hum, (step_memLp_top hu.1.aestronglyMeasurable).smul hu.2.1, ?_⟩ + intro φ hφ h + obtain ⟨χ, hχd, hχc, hχs, hχ1, _⟩ := exists_cutoff hφ.2.1.isCompact hD hφ.2.2 + have hχ : Test D χ := ⟨hχd, hχc, hχs⟩ + have hh := h10_positivePart hD (SobolevDensity.h10_mul_test hu hD hχ) + have hc1 (x) (hx : x ∈ tsupport φ) : χ x = 1 := hχ1.self_of_nhdsSet x hx + have hcG (x) (hx : x ∈ tsupport φ) : gradient χ x = 0 := by + have heq : χ =ᶠ[𝓝 x] fun _ => 1 := hχ1.filter_mono (nhds_le_nhdsSet hx) + rw [heq.gradient_eq] + exact gradient_const x 1 + have hφK : Test (tsupport φ) φ := ⟨hφ.1, hφ.2.1, subset_rfl⟩ + calc + _ = ∫ x in D, max (χ x*u x) 0 * (fderiv ℝ φ x) h := by + apply integral_congr_ae + exact Filter.Eventually.of_forall fun x => by + dsimp only + by_cases hx : x ∈ tsupport φ + · rw [hc1 x hx, one_mul] + · rw [hφK.fderiv_eq_zero_outside hx] + simp + _ = -(∫ x in D, inner ℝ ((if 0 < χ x*u x then (1 : ℝ) else 0) • + (χ x • G x + u x • gradient χ x)) h * φ x) := hh.1.2.2 φ hφ h + _ = _ := by + congr 1 + apply integral_congr_ae + exact Filter.Eventually.of_forall fun x => by + dsimp only + by_cases hx : x ∈ tsupport φ + · rw [hc1 x hx, hcG x hx] + simp + · rw [hφK.eq_zero_outside hx] + simp + +/-- A compactly supported H¹ function in the open set has zero trace. No +support or regularity condition is imposed on its given weak gradient. -/ +lemma h10_of_local_compact_support (hD : IsOpen D) (hu : H1 D u G) + (hc : HasCompactSupport u) (hs : tsupport u ⊆ D) : H10 D u G := by + obtain ⟨χ, hχd, hχc, hχs, hχ1, _⟩ := exists_cutoff hc.isCompact hD hs + have heq : (fun x => χ x*u x) = u := by + funext x + by_cases hx : x ∈ tsupport u + · rw [hχ1.self_of_nhdsSet x hx, one_mul] + · rw [image_eq_zero_of_notMem_tsupport hx, mul_zero] + have hh := SobolevDensity.h10_mul_test hu hD ⟨hχd, hχc, hχs⟩ + rw [heq] at hh + have hgrad := H1.gradient_unique hD hh.1 hu + exact hh.congr (Filter.EventuallyEq.refl _ _) hgrad + +/-- Stampacchia's zero-level-set property, obtained from the two truncations +and distributional uniqueness. -/ +lemma gradient_zero_on_zero_set (hD : IsOpen D) (hu : H1 D u G) : + ∀ᵐ x ∂volume.restrict D, u x = 0 → G x = 0 := by + have hp := h1_positivePart hD hu + have hn := h1_positivePart hD hu.neg + have hh := hp.sub hn + have heq : (fun x => max (u x) 0 - max (-u x) 0) = u := by + funext x + exact max_zero_sub_max_neg_zero_eq_self (u x) + change H1 D (fun x => max (u x) 0 - max (-u x) 0) _ at hh + rw [heq] at hh + have hg := H1.gradient_unique hD hu hh + filter_upwards [hg] with x hx hzero + simpa [hzero] using hx + +end Bernoulli.SobolevCalculus + +namespace Bernoulli.SobolevCalculus +open scoped _root_.Bernoulli +section Products +variable {α : Type uα} {E : Type uE} [MeasurableSpace α] {μ : Measure α} + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma bounded_smul_strong_of_fixed {a : ℕ → α → ℝ} {b : α → ℝ} + {V : ℕ → α → E} {G : α → E} {C : ℝ} + (ha : ∀ n, AEStronglyMeasurable (a n) μ) (_hb : AEStronglyMeasurable b μ) + (hV : ∀ n, MemLp (V n) 2 μ) (hG : MemLp G 2 μ) + (hab : ∀ n, ∀ᵐ x ∂μ, ‖a n x‖ ≤ C) + (hres : Tendsto (fun n => eLpNorm (fun x => (a n x-b x) • G x) 2 μ) atTop (𝓝 0)) + (hVG : Tendsto (fun n => eLpNorm (V n - G) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (fun x => a n x • V n x - b x • G x) 2 μ) + atTop (𝓝 0) := by + have hfst := ENNReal.Tendsto.const_mul (a := ENNReal.ofReal C) hVG (Or.inr ENNReal.ofReal_ne_top) + simp only [mul_zero] at hfst + have hsum := hfst.add hres + simp only [add_zero] at hsum + apply tendsto_of_tendsto_of_tendsto_of_le_of_le tendsto_const_nhds hsum (fun _ => zero_le) + intro n + have heq : (fun x => a n x • V n x - b x • G x) = + (fun x => a n x • (V n x-G x)) + (fun x => (a n x-b x) • G x) := by + funext x + simp only [Pi.add_apply, smul_sub, sub_smul] + abel + dsimp only + rw [heq] + apply (eLpNorm_add_le (by norm_num : (1 : ℝ≥0∞) ≤ 2)).trans + apply add_le_add _ le_rfl + refine eLpNorm_le_mul_eLpNorm_of_ae_le_mul + (f := fun x => a n x • (V n x - G x)) (g := fun x => V n x - G x) + ((ha n).smul ((hV n).sub hG).aestronglyMeasurable) ?_ 2 + filter_upwards [hab n] with x hx + rw [norm_smul] + exact mul_le_mul_of_nonneg_right hx (norm_nonneg (V n x - G x)) + +end Products +variable {d : ℕ} {D : Set (Space d)} {u v : Space d → ℝ} {G V : Space d → Space d} + +lemma positivePart_gradient_strong_of_ae (hD : IsOpen D) (hu : H1 D u G) + {f : ℕ → Space d → ℝ} {F : ℕ → Space d → Space d} + (hf : ∀ n, H1 D (f n) (F n)) + (hpoint : ∀ᵐ x ∂volume.restrict D, Tendsto (fun n => f n x) atTop (𝓝 (u x))) + (hFG : Tendsto (fun n => eLpNorm (F n - G) 2 (volume.restrict D)) atTop (𝓝 0)) : + Tendsto (fun n => eLpNorm (fun x => + (if 0 < f n x then (1 : ℝ) else 0) • F n x - + (if 0 < u x then (1 : ℝ) else 0) • G x) 2 (volume.restrict D)) atTop (𝓝 0) := by + have hfp (n : ℕ) := step_memLp_top (hf n).1.aestronglyMeasurable + have hup := step_memLp_top hu.1.aestronglyMeasurable + apply bounded_smul_strong_of_fixed + (fun n => (hfp n).aestronglyMeasurable) hup.aestronglyMeasurable + (fun n => (hf n).2.1) hu.2.1 + (C := 1) (fun _ => Filter.Eventually.of_forall fun _ => by split_ifs <;> norm_num) ?_ hFG + apply tendsto_eLpNorm_zero_of_dominated + (f := fun n x => ((if 0 < f n x then (1 : ℝ) else 0) - + (if 0 < u x then (1 : ℝ) else 0)) • G x) + (fun n => ((hfp n).aestronglyMeasurable.sub hup.aestronglyMeasurable).smul + hu.2.1.aestronglyMeasurable) (hu.2.1.norm.const_smul (2 : ℝ)) + · intro n + exact Filter.Eventually.of_forall fun x => by + have hb : ‖(if 0 < f n x then (1 : ℝ) else 0) - + (if 0 < u x then (1 : ℝ) else 0)‖ ≤ 2 := by split_ifs <;> norm_num + simpa only [norm_smul, Pi.smul_apply, smul_eq_mul, Real.norm_eq_abs, abs_mul, + abs_of_nonneg (norm_nonneg _), abs_of_pos (by norm_num : (0 : ℝ) < 2)] using + mul_le_mul_of_nonneg_right hb (norm_nonneg (G x)) + · filter_upwards [hpoint, gradient_zero_on_zero_set hD hu] with x hx hz + by_cases hzero : u x = 0 + · simp only [hz hzero, smul_zero] + exact tendsto_const_nhds + · by_cases hpos : 0 < u x + · apply tendsto_const_nhds.congr' + filter_upwards [hx.eventually_const_lt hpos] with n hn + simp [hpos, hn] + · have hneg : u x < 0 := lt_of_le_of_ne (le_of_not_gt hpos) hzero + apply tendsto_const_nhds.congr' + filter_upwards [hx.eventually_lt_const hneg] with n hn + simp [hpos, not_lt.mpr hn.le] + +lemma lipschitzWith_positivePart : LipschitzWith 1 (fun t : ℝ => max t 0) := by + exact LipschitzWith.id.max_const 0 + +lemma h10_positivePart_add_test (hD : IsOpen D) (hu : H1 D u G) + (hn : ∀ x, 0 ≤ u x) {φ : Space d → ℝ} (hφ : Test D φ) : + H10 D (fun x => max (u x + φ x) 0 - u x) + (fun x => (if 0 < u x + φ x then (1 : ℝ) else 0) • + (G x + gradient φ x) - G x) := by + have hh := (h1_positivePart hD (hu.add hφ.h1)).sub hu + have hs : tsupport (fun x => max (u x + φ x) 0 - u x) ⊆ tsupport φ := by + apply closure_minimal _ (isClosed_tsupport φ) + intro x hx + by_contra hnφ + have hz := image_eq_zero_of_notMem_tsupport hnφ + exact hx (by simp [hz, max_eq_left (hn x)]) + exact h10_of_local_compact_support hD hh + (hφ.2.1.isCompact.of_isClosed_subset (isClosed_tsupport _) hs) (hs.trans hφ.2.2) + +lemma h10_positivePart_trace_pointwise (hD : IsOpen D) + (hu : H1 D u G) (hn : ∀ x, 0 ≤ u x) (hv : H1 D v V) + (hvu : H10 D (fun x => v x - u x) (fun x => V x - G x)) : + H10 D (fun x => max (v x) 0 - u x) + (fun x => (if 0 < v x then (1 : ℝ) else 0) • V x - G x) := by + obtain ⟨φ, hφ, hφu, hφG⟩ := H10_sequence hvu + let f : ℕ → Space d → ℝ := fun n x => u x + φ n x + let F : ℕ → Space d → Space d := fun n x => G x + gradient (φ n) x + have hf (n : ℕ) : H1 D (f n) (F n) := hu.add (hφ n).h1 + have hfv : Tendsto (fun n => eLpNorm (f n - v) 2 (volume.restrict D)) atTop (𝓝 0) := by + convert! hφu using 1 + funext n + congr 1 + funext x + dsimp [f] + ring + have hFV : Tendsto (fun n => eLpNorm (F n - V) 2 (volume.restrict D)) atTop (𝓝 0) := by + convert! hφG using 1 + funext n + congr 1 + funext x + dsimp [F] + abel + obtain ⟨ns, hns, hpoint⟩ := (tendstoInMeasure_of_tendsto_eLpNorm + (by norm_num : (2 : ℝ≥0∞) ≠ 0) hfv).exists_seq_tendsto_ae + have htarget := (h1_positivePart hD hv).sub hu + apply h10_of_strong htarget.1 htarget.2.1 + (fun n => h10_positivePart_add_test hD hu hn (hφ (ns n))) + · have ht := lipschitz_tendsto_eLpNorm_of_aestronglyMeasurable lipschitzWith_positivePart + (fun n => (hf (ns n)).1.aestronglyMeasurable) hv.1.aestronglyMeasurable + (hfv.comp hns.tendsto_atTop) + convert! ht using 1 + funext n + congr 1 + funext x + dsimp [f] + ring + · have ht := positivePart_gradient_strong_of_ae hD hv (fun n => hf (ns n)) + hpoint (hFV.comp hns.tendsto_atTop) + convert! ht using 1 + funext n + congr 1 + funext x + dsimp [f, F] + abel + +lemma h10_positivePart_trace (hD : IsOpen D) (hu : H1 D u G) + (hn : ∀ᵐ x ∂volume.restrict D, 0 ≤ u x) (hv : H1 D v V) + (hvu : H10 D (fun x => v x - u x) (fun x => V x - G x)) : + H10 D (fun x => max (v x) 0 - u x) + (fun x => (if 0 < v x then (1 : ℝ) else 0) • V x - G x) := by + have heq : u =ᵐ[volume.restrict D] (fun x => max (u x) 0) := by + filter_upwards [hn] with x hx + exact (max_eq_left hx).symm + have hh := h10_positivePart_trace_pointwise hD + (hu.congr heq (Filter.EventuallyEq.refl _ _)) (fun x => le_max_right (u x) 0) hv + (hvu.congr ((Filter.EventuallyEq.refl _ v).sub heq) (Filter.EventuallyEq.refl _ _)) + exact hh.congr ((Filter.EventuallyEq.refl _ (fun x => max (v x) 0)).sub heq.symm) + (Filter.EventuallyEq.refl _ _) + +end Bernoulli.SobolevCalculus + +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/SobolevIdeals.lean b/lean/OAI/Analysis/BernoulliCone/SobolevIdeals.lean new file mode 100644 index 0000000000000000000000000000000000000000..669caf3603f756e15e5afe7ee11c215614a4bc42 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/SobolevIdeals.lean @@ -0,0 +1,226 @@ +import OAI.Analysis.BernoulliCone.GroundState + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter +open scoped ENNReal Topology ContDiff +namespace Bernoulli.SobolevCalculus + +lemma cutPrimitive_eq_zero_of_nonpos (n : ℕ) {t : ℝ} (ht : t ≤ 0) : + cutPrimitive n t = 0 := by + unfold cutPrimitive + rw [intervalIntegral.integral_symm] + have hz : (∫ s in t..(0:ℝ), cutSlope n s) = 0 := by + apply intervalIntegral.integral_zero_ae + exact ae_of_all _ fun s hs => by + have hs0 : s ≤ 0 := (mem_Ioc.mp (uIoc_of_le ht ▸ hs)).2 + have hh : ((n:ℝ)+1)*s ≤ 0 := mul_nonpos_of_nonneg_of_nonpos (by positivity) hs0 + simp [cutSlope,max_eq_right hh] + simp [hz] + +def innerCut (n : ℕ) (t : ℝ) : ℝ := cutPrimitive n (t - 1/((n:ℝ)+1)) +def innerSlope (n : ℕ) (t : ℝ) : ℝ := cutSlope n (t - 1/((n:ℝ)+1)) + +lemma innerCut_zero (n : ℕ) : innerCut n 0 = 0 := by + apply cutPrimitive_eq_zero_of_nonpos + simp only [zero_sub] + exact neg_nonpos.mpr (by positivity) +lemma innerCut_deriv (n : ℕ) (t : ℝ) : HasDerivAt (innerCut n) (innerSlope n t) t := by + convert! (cutPrimitive_deriv n (t-1/((n:ℝ)+1))).comp t ((hasDerivAt_id t).sub_const (1/((n:ℝ)+1))) using 1 + dsimp [innerSlope] + ring +lemma innerCut_contDiff (n : ℕ) : ContDiff ℝ 1 (innerCut n) := + (cutPrimitive_contDiff n).comp (contDiff_id.sub contDiff_const) +lemma innerCut_lipschitz (n : ℕ) : LipschitzWith 1 (innerCut n) := by + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [innerCut,Real.dist_eq,sub_sub_sub_cancel_right,NNReal.coe_one,one_mul] using (cutPrimitive_lipschitz n).dist_le_mul (x-1/((n:ℝ)+1)) (y-1/((n:ℝ)+1)) +lemma innerSlope_continuous (n : ℕ) : Continuous (innerSlope n) := + (cutSlope_continuous n).comp (continuous_id.sub continuous_const) +lemma innerSlope_norm_le (n : ℕ) (t : ℝ) : ‖innerSlope n t‖ ≤ 1 := cutSlope_norm_le _ _ +lemma innerCut_vanish (n : ℕ) {t : ℝ} (ht : t ≤ 1/((n:ℝ)+1)) : innerCut n t = 0 := + cutPrimitive_eq_zero_of_nonpos n (sub_nonpos.mpr ht) + +lemma innerCut_tendsto (t : ℝ) : Tendsto (fun n => innerCut n t) atTop (𝓝 (max t 0)) := by + have he : Tendsto (fun n : ℕ => 1/((n:ℝ)+1)) atTop (𝓝 (0:ℝ)) := + tendsto_one_div_add_atTop_nhds_zero_nat + have hd : Tendsto (fun n => innerCut n t - cutPrimitive n t) atTop (𝓝 (0:ℝ)) := by + apply squeeze_zero_norm _ he + intro n + have hh := (cutPrimitive_lipschitz n).norm_sub_le (t-1/((n:ℝ)+1)) t + simpa only [innerCut,NNReal.coe_one,one_mul,sub_sub_cancel_left,norm_neg,Real.norm_of_nonneg (by positivity : 0≤1/((n:ℝ)+1))] using hh + simpa only [sub_add_cancel,zero_add] using hd.add (cutPrimitive_tendsto t) + +lemma innerSlope_tendsto (t : ℝ) : + Tendsto (fun n => innerSlope n t) atTop (𝓝 (if 0 ((n:ℝ)+1)*t-1) atTop atTop := + Filter.tendsto_atTop_add_const_right _ (-1) ((tendsto_atTop_mono (fun n : ℕ => (show (n:ℝ)≤(n:ℝ)+1 by linarith)) + tendsto_natCast_atTop_atTop).atTop_mul_const ht) + apply tendsto_const_nhds.congr' + filter_upwards [hg.eventually_ge_atTop 1] with n hn + have he : ((n:ℝ)+1)*(t-1/((n:ℝ)+1))=((n:ℝ)+1)*t-1 := by + field_simp + dsimp only [innerSlope,cutSlope] + rw [he,max_eq_left (by linarith),min_eq_right hn] + · simp only [ite_eq_right ht] + have hz (n : ℕ) : innerSlope n t=0 := by + have hm : ((n:ℝ)+1)*(t-1/((n:ℝ)+1))≤0 := + mul_nonpos_of_nonneg_of_nonpos (by positivity) (by linarith [show 0≤1/((n:ℝ)+1) by positivity]) + dsimp only [innerSlope,cutSlope] + rw [max_eq_right hm] + norm_num + simp only [hz] + exact tendsto_const_nhds + +lemma h10_innerCut {d : ℕ} {D : Set (Space d)} {w : Space d → ℝ} {G : Space d → Space d} + (hD : IsOpen D) (hw : H10 D w G) (n : ℕ) : + H10 D (innerCut n ∘ w) (fun x => innerSlope n (w x) • G x) := by + have hh := h10_comp_C1 hD hw (innerCut_contDiff n) (innerCut_lipschitz n) (innerCut_zero n) + have he : deriv (innerCut n)=innerSlope n := funext fun t => (innerCut_deriv n t).deriv + rwa [he] at hh + +theorem h10_positive_domain {d : ℕ} {D : Set (Space d)} + {w U : Space d → ℝ} {G : Space d → Space d} + (hD : IsOpen D) (hDc : IsCompact (closure D)) (hw : H10 D w G) + (hU : Continuous U) (hwn : ∀x, 0≤w x) (hbound : ∀x, w x≤U x) + (hw0 : ∀x, x∉D → w x=0) : + H10 {x | 0 simp [hx,hw0 x] + rwa [he] at hh + have hwp := hwg.1.mono (subset_univ P) + have hcut (n : ℕ) : H10 P (innerCut n ∘ w) (fun x=>innerSlope n (w x) • D.indicator G x) := by + have hh := (h10_innerCut isOpen_univ hwg n).1.mono (subset_univ P) + have hs : tsupport (innerCut n ∘ w) ⊆ closure D ∩ {x | 1/((n:ℝ)+1)≤U x} := by + apply closure_minimal _ (isClosed_closure.inter (isClosed_le continuous_const hU)) + intro x hx + have hx' : innerCut n (w x)≠0 := hx + have hlt : 1/((n:ℝ)+1)hx' (innerCut_vanish n hn)) + refine ⟨subset_closure ?_,(hlt.le.trans (hbound x))⟩ + by_contra hn + rw [hw0 x hn] at hlt + have : 0<1/((n:ℝ)+1) := by positivity + linarith + apply h10_of_local_compact_support hP hh + · exact (hDc.inter_right (isClosed_le continuous_const hU)).of_isClosed_subset (isClosed_tsupport _) hs + · intro x hx + exact lt_of_lt_of_le (by positivity : 0<1/((n:ℝ)+1)) (hs hx).2 + apply h10_of_strong hwp.1 hwp.2.1 hcut + · apply tendsto_eLpNorm_zero_of_dominated + (fun n=>((innerCut_lipschitz n).continuous.comp_aestronglyMeasurable hwp.1.aestronglyMeasurable).sub hwp.1.aestronglyMeasurable) + (hwp.1.norm.const_smul (2:ℝ)) + · intro n + exact ae_of_all _ fun x=>by + have hn : ‖innerCut n (w x)‖≤‖w x‖ := by + simpa [innerCut_zero] using (innerCut_lipschitz n).norm_sub_le (w x) 0 + calc ‖innerCut n (w x)-w x‖ ≤ ‖innerCut n (w x)‖+‖w x‖ := norm_sub_le _ _ + _ ≤ ‖((2:ℝ) • fun y=>‖w y‖) x‖ := by + simp only [Pi.smul_apply,smul_eq_mul,norm_mul,Real.norm_of_nonneg (by norm_num : (0:ℝ)≤2),norm_norm] + linarith + · exact ae_of_all _ fun x=>by + simpa only [Pi.sub_apply,Function.comp_apply,max_eq_left (hwn x),sub_self] using (innerCut_tendsto (w x)).sub_const (w x) + · have hz := gradient_zero_on_zero_set isOpen_univ hwg.1 + simp only [Measure.restrict_univ] at hz + apply tendsto_eLpNorm_zero_of_dominated + (fun n=>(((innerSlope_continuous n).comp_aestronglyMeasurable hwp.1.aestronglyMeasurable).smul hwp.2.1.aestronglyMeasurable).sub hwp.2.1.aestronglyMeasurable) + (hwp.2.1.norm.const_smul (2:ℝ)) + · intro n + exact ae_of_all _ fun x=>by + calc ‖innerSlope n (w x) • D.indicator G x-D.indicator G x‖ ≤ + ‖innerSlope n (w x) • D.indicator G x‖+‖D.indicator G x‖ := norm_sub_le _ _ + _ ≤ ‖((2:ℝ) • fun y=>‖D.indicator G y‖) x‖ := by + rw [norm_smul] + have hh:=mul_le_mul_of_nonneg_right (innerSlope_norm_le n (w x)) (norm_nonneg (D.indicator G x)) + simp only [Pi.smul_apply,smul_eq_mul,norm_mul,Real.norm_of_nonneg (by norm_num : (0:ℝ)≤2),norm_norm] + linarith + · filter_upwards [ae_restrict_of_ae hz] with x hx + by_cases hp : 0D.indicator G x) atTop (𝓝 (D.indicator G x))) + simpa only [Pi.sub_apply,Pi.smul_apply',ite_eq_left hp,one_smul,sub_self] using ht.sub_const (D.indicator G x) + · have hwz : w x=0 := le_antisymm (not_lt.mp hp) (hwn x) + simp only [Pi.sub_apply,Pi.smul_apply',hx hwz,smul_zero,sub_self] + exact tendsto_const_nhds + +theorem h10_positive_domain_inter {d : ℕ} {D : Set (Space d)} + {S : Set (Space d)} (hS : IsOpen S) (hDS : closure D ⊆ S) + {w U : Space d → ℝ} {G : Space d → Space d} + (hD : IsOpen D) (hDc : IsCompact (closure D)) (hw : H10 D w G) + (hU : Continuous U) (hwn : ∀x, 0≤w x) (hbound : ∀x, w x≤U x) + (hw0 : ∀x, x∉D → w x=0) : + H10 ({x | 0 simp [hx,hw0 x] + rwa [he] at hh + have hwp := hwg.1.mono (subset_univ P) + have hcut (n : ℕ) : H10 P (innerCut n ∘ w) (fun x=>innerSlope n (w x) • D.indicator G x) := by + have hh := (h10_innerCut isOpen_univ hwg n).1.mono (subset_univ P) + have hs : tsupport (innerCut n ∘ w) ⊆ closure D ∩ {x | 1/((n:ℝ)+1)≤U x} := by + apply closure_minimal _ (isClosed_closure.inter (isClosed_le continuous_const hU)) + intro x hx + have hx' : innerCut n (w x)≠0 := hx + have hlt : 1/((n:ℝ)+1)hx' (innerCut_vanish n hn)) + refine ⟨subset_closure ?_,(hlt.le.trans (hbound x))⟩ + by_contra hn + rw [hw0 x hn] at hlt + have : 0<1/((n:ℝ)+1) := by positivity + linarith + apply h10_of_local_compact_support hP hh + · exact (hDc.inter_right (isClosed_le continuous_const hU)).of_isClosed_subset (isClosed_tsupport _) hs + · intro x hx + exact ⟨lt_of_lt_of_le (by positivity : 0<1/((n:ℝ)+1)) (hs hx).2, hDS (hs hx).1⟩ + apply h10_of_strong hwp.1 hwp.2.1 hcut + · apply tendsto_eLpNorm_zero_of_dominated + (fun n=>((innerCut_lipschitz n).continuous.comp_aestronglyMeasurable hwp.1.aestronglyMeasurable).sub hwp.1.aestronglyMeasurable) + (hwp.1.norm.const_smul (2:ℝ)) + · intro n + exact ae_of_all _ fun x=>by + have hn : ‖innerCut n (w x)‖≤‖w x‖ := by + simpa [innerCut_zero] using (innerCut_lipschitz n).norm_sub_le (w x) 0 + calc ‖innerCut n (w x)-w x‖ ≤ ‖innerCut n (w x)‖+‖w x‖ := norm_sub_le _ _ + _ ≤ ‖((2:ℝ) • fun y=>‖w y‖) x‖ := by + simp only [Pi.smul_apply,smul_eq_mul,norm_mul,Real.norm_of_nonneg (by norm_num : (0:ℝ)≤2),norm_norm] + linarith + · exact ae_of_all _ fun x=>by + simpa only [Pi.sub_apply,Function.comp_apply,max_eq_left (hwn x),sub_self] using (innerCut_tendsto (w x)).sub_const (w x) + · have hz := gradient_zero_on_zero_set isOpen_univ hwg.1 + simp only [Measure.restrict_univ] at hz + apply tendsto_eLpNorm_zero_of_dominated + (fun n=>(((innerSlope_continuous n).comp_aestronglyMeasurable hwp.1.aestronglyMeasurable).smul hwp.2.1.aestronglyMeasurable).sub hwp.2.1.aestronglyMeasurable) + (hwp.2.1.norm.const_smul (2:ℝ)) + · intro n + exact ae_of_all _ fun x=>by + calc ‖innerSlope n (w x) • D.indicator G x-D.indicator G x‖ ≤ + ‖innerSlope n (w x) • D.indicator G x‖+‖D.indicator G x‖ := norm_sub_le _ _ + _ ≤ ‖((2:ℝ) • fun y=>‖D.indicator G y‖) x‖ := by + rw [norm_smul] + have hh:=mul_le_mul_of_nonneg_right (innerSlope_norm_le n (w x)) (norm_nonneg (D.indicator G x)) + simp only [Pi.smul_apply,smul_eq_mul,norm_mul,Real.norm_of_nonneg (by norm_num : (0:ℝ)≤2),norm_norm] + linarith + · filter_upwards [ae_restrict_of_ae hz] with x hx + by_cases hp : 0D.indicator G x) atTop (𝓝 (D.indicator G x))) + simpa only [Pi.sub_apply,Pi.smul_apply',ite_eq_left hp,one_smul,sub_self] using ht.sub_const (D.indicator G x) + · have hwz : w x=0 := le_antisymm (not_lt.mp hp) (hwn x) + simp only [Pi.sub_apply,Pi.smul_apply',hx hwz,smul_zero,sub_self] + exact tendsto_const_nhds + +end Bernoulli.SobolevCalculus + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/StationarityDensity.lean b/lean/OAI/Analysis/BernoulliCone/StationarityDensity.lean new file mode 100644 index 0000000000000000000000000000000000000000..6a13d3abc7bc3d218f48d4c0362c0995e07376fe --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/StationarityDensity.lean @@ -0,0 +1,85 @@ +import OAI.Analysis.BernoulliCone.HalfspaceDensity + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology NNReal +namespace Bernoulli.Shape +variable {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +def stressTerm (u φ : E → ℝ) (e : E) (x : E) : ℝ := + density u x * fderiv ℝ φ x e - + 2 * (fderiv ℝ u x e) * (fderiv ℝ u x (gradient φ x)) + +lemma pullback_gradient {u φ : E → ℝ} {x : E} + (hu : DifferentiableAt ℝ u x) (hφ : DifferentiableAt ℝ φ x) + (e : E) (t : ℝ) (h : 1+t*fderiv ℝ φ x e ≠ 0) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) : + gradient (fun y => u (g.symm y)) (g x) = + gradient u x - (t*(fderiv ℝ u x e)/(1+t*fderiv ℝ φ x e)) • gradient φ x := by + have hi := inverse_hasFDerivAt_deform hφ.hasFDerivAt e t h g hg + have ho : HasFDerivAt u (fderiv ℝ u x) (g.symm (g x)) := by + simpa using hu.hasFDerivAt + have hf := ho.comp (g x) hi + apply ext_inner_right ℝ + intro y + rw [inner_gradient_left] + change fderiv ℝ (u ∘ g.symm) (g x) y = _ + rw [hf.fderiv,dual_rankOneInverse] + simp only [sub_apply,smul_apply,smul_eq_mul,inner_sub_left, + real_inner_smul_left,inner_gradient_left] + +omit [CompleteSpace E] in +lemma general_density_algebra (q e z : E) (t c : ℝ) (h : 1+t*inner ℝ z e ≠ 0) : + (1+t*inner ℝ z e) * (‖q-(t*inner ℝ q e/(1+t*inner ℝ z e)) • z‖^2+c) - + (‖q‖^2+c) = + t*((‖q‖^2+c)*inner ℝ z e - 2*inner ℝ q e*inner ℝ q z) + + t^2*(inner ℝ q e)^2*‖z‖^2/(1+t*inner ℝ z e) := by + rw [norm_sub_sq_real,real_inner_smul_right,norm_smul,mul_pow,Real.norm_eq_abs,sq_abs] + field_simp + ring + +lemma stress_density_bound {u φ : E → ℝ} {L C : ℝ≥0} {x : E} + (hu : DifferentiableAt ℝ u x) (huLip : LipschitzWith L u) + (hφ : DifferentiableAt ℝ φ x) (hφLip : LipschitzWith C φ) + (e : E) (t : ℝ) (h : (1:ℝ)/2 ≤ 1+t*fderiv ℝ φ x e) + (g : E ≃ₜ E) (hg : ∀ y, g y=deform φ e t y) : + (1+t*fderiv ℝ φ x e)*density (fun y => u (g.symm y)) (g x) ≤ + density u x+t*stressTerm u φ e x+t^2*(2*(L:ℝ)^2*‖e‖^2*(C:ℝ)^2) := by + have hp : 0 < 1+t*fderiv ℝ φ x e := lt_of_lt_of_le (by norm_num) h + have hne := hp.ne' + have hq := gradient_norm_le_lipschitz huLip hu + have hz := gradient_norm_le_lipschitz hφLip hφ + have hq2 : ‖gradient u x‖^2 ≤ (L:ℝ)^2 := by nlinarith [norm_nonneg (gradient u x)] + have hz2 : ‖gradient φ x‖^2 ≤ (C:ℝ)^2 := by nlinarith [norm_nonneg (gradient φ x)] + have hqe : (fderiv ℝ u x e)^2 ≤ (L:ℝ)^2*‖e‖^2 := by + have hh := real_inner_mul_inner_self_le (gradient u x) e + rw [inner_gradient_left,real_inner_self_eq_norm_sq,real_inner_self_eq_norm_sq,← pow_two] at hh + exact hh.trans (mul_le_mul_of_nonneg_right hq2 (sq_nonneg _)) + have hnum : 0 ≤ t^2*((L:ℝ)^2*‖e‖^2*(C:ℝ)^2) := by positivity + have hbound : t^2*(fderiv ℝ u x e)^2*‖gradient φ x‖^2 ≤ + t^2*((L:ℝ)^2*‖e‖^2*(C:ℝ)^2) := by + have hh := mul_le_mul hqe hz2 (sq_nonneg _) (by positivity : 0 ≤ (L:ℝ)^2*‖e‖^2) + simpa only [mul_assoc] using mul_le_mul_of_nonneg_left hh (sq_nonneg t) + have hr : t^2*(fderiv ℝ u x e)^2*‖gradient φ x‖^2/(1+t*fderiv ℝ φ x e) ≤ + t^2*(2*(L:ℝ)^2*‖e‖^2*(C:ℝ)^2) := by + apply (div_le_iff₀ hp).mpr + have hh : t^2*((L:ℝ)^2*‖e‖^2*(C:ℝ)^2) ≤ + (2*(t^2*((L:ℝ)^2*‖e‖^2*(C:ℝ)^2)))*(1+t*fderiv ℝ φ x e) := by nlinarith + exact hbound.trans (by nlinarith only [hh]) + have hc := general_density_algebra (gradient u x) e (gradient φ x) t + (if 0 < u x then 1 else 0) (by simpa only [inner_gradient_left] using hne) + simp only [inner_gradient_left] at hc + rw [density,pullback_gradient hu hφ e t hne g hg,g.symm_apply_apply] + unfold stressTerm density + linarith +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/StationarityEnergy.lean b/lean/OAI/Analysis/BernoulliCone/StationarityEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec27f77af8c3229cdd058378cd54ecd5be610824 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/StationarityEnergy.lean @@ -0,0 +1,74 @@ +import OAI.Analysis.BernoulliCone.HalfspaceUnitSlope + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal ContDiff +namespace Bernoulli.Shape +variable {d : ℕ} + +lemma general_energy_pullback_upper {u φ : Space d → ℝ} {L C : ℝ≥0} + (huLip : LipschitzWith L u) + (hφ : ContDiff ℝ ∞ φ) (hLip : LipschitzWith C φ) + (e : Space d) (t : ℝ) + (hdet : ∀ x, (1:ℝ)/2 ≤ 1+t*fderiv ℝ φ x e) + (g : Space d ≃ₜ Space d) (hg : ∀ y, g y=deform φ e t y) + (a : Space d) (R : ℝ) (hfix : ∀ x ∉ ball a R, φ x=0) : + energy (ball a R) (fun y => u (g.symm y)) + (gradient (fun y => u (g.symm y))) ≤ + energy (ball a R) (u) (gradient (u)) + + t*(∫ x in ball a R, stressTerm u φ e x) + + t^2*(2*(L:ℝ)^2*‖e‖^2*C^2)*(volume (ball a R)).toReal := by + let : IsFiniteMeasure (volume.restrict (ball a R)) := + isFiniteMeasure_restrict.mpr (measure_ball_lt_top.ne) + let v := fun y => u (g.symm y) + have him : g '' ball a R=ball a R := image_eq_of_fixed_compl g _ (by + intro x hx + rw [hg] + simp [deform,hfix x hx]) + have hchange := integral_image_eq_integral_abs_det_fderiv_smul (s:=ball a R) volume measurableSet_ball + (f:=g) (f':=fun x => rankOneMap (fderiv ℝ φ x) e t) + (fun x _ => (show HasFDerivAt g (rankOneMap (fderiv ℝ φ x) e t) x from by + rw [show (g : Space d → Space d)=deform φ e t from funext hg] + exact hasFDerivAt_deform ((hφ.differentiable (by simp)) x).hasFDerivAt e t).hasFDerivWithinAt) (g.injective.injOn) (density v) + rw [him] at hchange + have hdetpos (x : Space d) : 0 ≤ 1+t*fderiv ℝ φ x e := le_trans (by norm_num) (hdet x) + simp_rw [rankOneMap_det,abs_of_nonneg (hdetpos _),smul_eq_mul] at hchange + change energy (ball a R) v (gradient v) = _ at hchange + rw [hchange] + have hi : Integrable (fun x => density (u) x+t*stressTerm u φ e x+ + t^2*(2*(L:ℝ)^2*‖e‖^2*C^2)) (volume.restrict (ball a R)) := by + convert ((density_integrable_ball huLip a R).add + ((stressTerm_integrable_ball huLip hLip e a R).const_mul (t))).add + (integrable_const (t^2*(2*(L:ℝ)^2*‖e‖^2*C^2))) using 1; rfl + have hm := integral_mono_of_nonneg + (μ:=volume.restrict (ball a R)) + (f:=fun x => (1+t*fderiv ℝ φ x e)*density v (g x)) + (g:=fun x => density (u) x+t*stressTerm u φ e x+ + t^2*(2*(L:ℝ)^2*‖e‖^2*C^2)) + (Eventually.of_forall (fun x => mul_nonneg (hdetpos x) (density_nonneg v (g x)))) hi + (by + filter_upwards [ae_restrict_of_ae huLip.ae_differentiableAt] with x hx + exact stress_density_bound hx huLip ((hφ.differentiable (by simp)) x) hLip e t (hdet x) g hg) + have hiE := density_integrable_ball huLip a R + have hiF := (stressTerm_integrable_ball huLip hLip e a R).const_mul (t) + have hsum : (∫ x in ball a R, density (u) x+t*stressTerm u φ e x+ + t^2*(2*(L:ℝ)^2*‖e‖^2*C^2)) = + energy (ball a R) (u) (gradient (u)) + + t*(∫ x in ball a R, stressTerm u φ e x) + + t^2*(2*(L:ℝ)^2*‖e‖^2*C^2)*(volume (ball a R)).toReal := by + have hadd := integral_add (hiE.add hiF) (integrable_const (t^2*(2*(L:ℝ)^2*‖e‖^2*C^2))) + have hadd2 := integral_add hiE hiF + simp only [Pi.add_apply] at hadd + rw [hadd2,integral_const_mul,integral_const] at hadd + convert hadd using 1; first | rfl | (simp only [Measure.restrict_apply_univ,Measure.real,smul_eq_mul]; dsimp [energy,density]; ring) + rw [hsum] at hm + exact hm +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/StationarityIntegrability.lean b/lean/OAI/Analysis/BernoulliCone/StationarityIntegrability.lean new file mode 100644 index 0000000000000000000000000000000000000000..13309f1e8c22665abb2d86316aca70c50698f9db --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/StationarityIntegrability.lean @@ -0,0 +1,72 @@ +import OAI.Analysis.BernoulliCone.HalfspaceEnergy + +namespace OAI + +section +noncomputable section +open MeasureTheory Set Filter Metric +open scoped Topology NNReal ENNReal +namespace Bernoulli.Shape +variable {d : ℕ} + +lemma derivative_norm_le {u : Space d → ℝ} {L : ℝ≥0} + (hu : LipschitzWith L u) (x y : Space d) : ‖fderiv ℝ u x y‖ ≤ L*‖y‖ := + (fderiv ℝ u x).le_opNorm y |>.trans + (mul_le_mul_of_nonneg_right (norm_fderiv_le_of_lipschitz ℝ hu) (norm_nonneg y)) + +lemma density_le {u : Space d → ℝ} {L : ℝ≥0} (hu : LipschitzWith L u) (x : Space d) : + density u x ≤ (L:ℝ)^2+1 := by + have hn := LipschitzSobolev.norm_gradient_le hu x + unfold density + split_ifs <;> nlinarith [norm_nonneg (gradient u x)] + +lemma density_measurable {u : Space d → ℝ} {L : ℝ≥0} (hu : LipschitzWith L u) : + Measurable (density u) := by + have hp : Measurable (fun x : Space d => if 0 < u x then (1:ℝ) else 0) := + measurable_const.ite (isOpen_lt continuous_const hu.continuous).measurableSet measurable_const + exact (LipschitzSobolev.measurable_gradient.norm.pow_const 2).add hp + +lemma stressTerm_measurable {u : Space d → ℝ} {L : ℝ≥0} (hu : LipschitzWith L u) + (φ : Space d → ℝ) (e : Space d) : Measurable (stressTerm u φ e) := by + have hφ : Measurable (fun x : Space d => fderiv ℝ φ x e) := measurable_fderiv_apply_const ℝ φ e + have hue : Measurable (fun x : Space d => fderiv ℝ u x e) := measurable_fderiv_apply_const ℝ u e + have hub : Measurable (fun x : Space d => fderiv ℝ u x (gradient φ x)) := by + simp_rw [← inner_gradient_left] + exact LipschitzSobolev.measurable_gradient.inner LipschitzSobolev.measurable_gradient + exact ((density_measurable hu).mul hφ).sub ((measurable_const.mul hue).mul hub) + +lemma stressTerm_norm_le {u φ : Space d → ℝ} {L C : ℝ≥0} + (hu : LipschitzWith L u) (hφ : LipschitzWith C φ) (e x : Space d) : + ‖stressTerm u φ e x‖ ≤ ((L:ℝ)^2+1)*C*‖e‖ + 2*(L:ℝ)^2*‖e‖*C := by + have hud := derivative_norm_le hu x e + have hφd := derivative_norm_le hφ x e + have hub : ‖fderiv ℝ u x (gradient φ x)‖ ≤ (L:ℝ)*C := + (derivative_norm_le hu x _).trans + (mul_le_mul_of_nonneg_left (LipschitzSobolev.norm_gradient_le hφ x) L.coe_nonneg) + have hden : ‖density u x‖ ≤ (L:ℝ)^2+1 := by + rw [Real.norm_eq_abs,abs_of_nonneg (density_nonneg u x)] + exact density_le hu x + have h1 := mul_le_mul hden hφd (norm_nonneg _) (by positivity : 0 ≤ (L:ℝ)^2+1) + have h2 := mul_le_mul (mul_le_mul_of_nonneg_left hud (show (0:ℝ) ≤ 2 by norm_num)) hub + (norm_nonneg _) (by positivity : 0 ≤ 2*((L:ℝ)*‖e‖)) + unfold stressTerm + calc + _ ≤ ‖density u x * fderiv ℝ φ x e‖ + ‖2*fderiv ℝ u x e*fderiv ℝ u x (gradient φ x)‖ := norm_sub_le _ _ + _ ≤ ((L:ℝ)^2+1)*(C*‖e‖)+(2*((L:ℝ)*‖e‖))*((L:ℝ)*C) := by + simp only [norm_mul,Real.norm_ofNat] + exact add_le_add h1 h2 + _ = _ := by ring + +lemma stressTerm_integrable_ball {u φ : Space d → ℝ} {L C : ℝ≥0} + (hu : LipschitzWith L u) (hφ : LipschitzWith C φ) (e a : Space d) (R : ℝ) : + IntegrableOn (stressTerm u φ e) (ball a R) := by + let : IsFiniteMeasure (volume.restrict (ball a R)) := isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + apply (integrable_const (((L:ℝ)^2+1)*C*‖e‖ + 2*(L:ℝ)^2*‖e‖*C)).mono' + (stressTerm_measurable hu φ e).aestronglyMeasurable + exact Eventually.of_forall (stressTerm_norm_le hu hφ e) +end Bernoulli.Shape + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/StrictSlope.lean b/lean/OAI/Analysis/BernoulliCone/StrictSlope.lean new file mode 100644 index 0000000000000000000000000000000000000000..1124f4797d50ce5947177fc5c2f5fd828f53089d --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/StrictSlope.lean @@ -0,0 +1,92 @@ +import OAI.Analysis.BernoulliCone.OuterGeometry + +namespace OAI + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison +lemma GSup_neg_deriv {t:ℝ} (hl:t7≤t) (hr:t≤27/50) : deriv GSup t<0 := by + have ht0:0≤t:=t7_pos.le.trans hl + have ht1:t<1:=by linarith + have hI:t∈Ioo (-1:ℝ) 1:=⟨by linarith,ht1⟩ + have hf0:f t≤0 := by + have hh:=f_strictAnti.antitoneOn ⟨t7_pos.le,t7_lt_one⟩ ⟨ht0,ht1⟩ hl + simpa only [f_t7] using hh + have hf:-1/8≤f t := upper_endpoint_bounds.1.trans + (f_strictAnti.antitoneOn ⟨ht0,ht1⟩ (by norm_num) hr) + have hp:fp t≤-4 := (fp_strictAnti.antitoneOn (by norm_num) ⟨ht0,ht1⟩ + (by linarith [t7_bounds.1])).trans upper_endpoint_bounds.2 + obtain ⟨hq0,hq4,hqL⟩:=qSup_small ht0 hr + have hm:=mul_le_mul_of_nonneg_left hq4 (show 0≤-f t by linarith) + have hB:fp t-4*f t*qSup t≤0 := by nlinarith + have hc : 5*t-(1-t^2)*qSup t<0 := by + have hu : t^2≤729/2500 := by nlinarith + have hd : 1-t^2≠0 := by nlinarith + have he : (1-t^2)*qSup t-5*t=t*(1-3*t^2)/(1+t^2) := by + unfold qSup + field_simp [hd,show 1+t^2≠0 by positivity] + ring + have hpos : 0 eLpNorm (f n - g) 2 μ) atTop (𝓝 0)) : + Tendsto (fun n => ∫ x, ‖f n x‖ ^ 2 ∂μ) atTop (𝓝 (∫ x, ‖g x‖ ^ 2 ∂μ)) := by + have ht : Tendsto (fun n => (hf n).toLp (f n)) atTop (𝓝 (hg.toLp g)) := by + apply tendsto_iff_enorm_sub_tendsto_zero.mpr + simpa only [← MemLp.toLp_sub, Lp.enorm_toLp] using hc + have hi (n : ℕ) := integral_norm_sq_eq (hf n) + simp_rw [hi, integral_norm_sq_eq hg] + exact ht.norm.pow 2 + +end L2 + +def ramp (ε t:ℝ) : ℝ := min (max (t/ε) 0) 1 +lemma ramp_continuous (ε:ℝ) : Continuous (ramp ε) := by + unfold ramp + fun_prop +lemma ramp_nonneg (ε t:ℝ) : 0≤ramp ε t := le_min (le_max_right _ _) zero_le_one +lemma ramp_le_one (ε t:ℝ) : ramp ε t≤1 := min_le_right _ _ +lemma ramp_norm_le (ε t:ℝ) : ‖ramp ε t‖≤1 := by + rw [Real.norm_eq_abs,abs_of_nonneg (ramp_nonneg _ _)] + exact ramp_le_one _ _ +def envelope (ε u w:ℝ) : ℝ := if 0 norm_num + · have hu0:u=0:=le_antisymm (not_lt.mp hup) hu + subst u + rw [envelope,ite_eq_right (lt_irrefl _)] + by_cases hw:ε norm_num + · have he:w-ε≤0:=sub_nonpos.mpr (not_lt.mp hw) + simp only [max_eq_right he,add_zero,lt_self_iff_false,ite_false] + exact ramp_nonneg _ _ +lemma envelope_le_phase {ε u w:ℝ} (_hε:0<ε) (hu:0≤u) (hw:0≤w) : + envelope ε u w≤(if 0envelope ε (u x) (w x)) μ := by + have hm:Measurable (fun p:ℝ×ℝ=>envelope ε p.1 p.2) := + Measurable.ite (measurableSet_lt measurable_const measurable_fst) measurable_const + ((ramp_continuous ε).measurable.comp measurable_snd) + exact (hm.comp_aemeasurable (hu.aemeasurable.prodMk hw.aemeasurable)).aestronglyMeasurable +lemma envelope_integrable {u w:α→ℝ} (hu:AEStronglyMeasurable u μ) + (hw:AEStronglyMeasurable w μ) (ε:ℝ) : + Integrable (fun x=>envelope ε (u x) (w x)) μ := + (integrable_const (1:ℝ)).mono' (envelope_measurable hu hw ε) + (Eventually.of_forall fun _=>envelope_norm_le _ _ _) +lemma envelope_integral_tendsto {u w:α→ℝ} {f:ℕ→α→ℝ} + (hu:AEStronglyMeasurable u μ) (hf:∀n,AEStronglyMeasurable (f n) μ) + (hp:∀ᵐ x ∂μ,Tendsto (fun n=>f n x) atTop (𝓝 (w x))) (ε:ℝ) : + Tendsto (fun n=>∫x,envelope ε (u x) (f n x) ∂μ) atTop + (𝓝 (∫x,envelope ε (u x) (w x) ∂μ)) := by + apply tendsto_integral_of_dominated_convergence (fun _=>1) + · exact fun n=>envelope_measurable hu (hf n) ε + · exact integrable_const _ + · exact fun _=>Eventually.of_forall fun _=>envelope_norm_le _ _ _ + · filter_upwards [hp] with x hx + by_cases hu':0a) (fun _=>0) := by + simpa only [gradient_fun_const',Pi.zero_apply] using (LipschitzSobolev.h1_ball (LipschitzWith.const a) c r) +lemma h1_sub_const_ball {c:Space d} {r:ℝ} {u:Space d→ℝ} {G:Space d→Space d} + (hu:H1 (Metric.ball c r) u G) (a:ℝ) : + H1 (Metric.ball c r) (fun x=>u x-a) G := by + simpa only [sub_zero] using hu.sub (h1_const_ball c r a) +/-- Strong H1-density gives the exact upper comparison after fixed positive +threshold truncation. The discontinuous phase term is controlled by a continuous +ramp, not by an unjustified continuity assertion for positivity sets. -/ +lemma fixed_threshold_limit {c:Space d} {r:ℝ} {u w:Space d→ℝ} + {G W:Space d→Space d} (hu:H1 (Metric.ball c r) u G) + (hw:H10 (Metric.ball c r) w W) + (hun:∀ᵐ x ∂volume.restrict (Metric.ball c r),0≤u x) + (hwn:∀ᵐ x ∂volume.restrict (Metric.ball c r),0≤w x) + {ε:ℝ} (hε:0<ε) + (hcomp:∀φ:Space d→ℝ,Test (Metric.ball c r) φ → + energy (Metric.ball c r) u G≤energy (Metric.ball c r) + (fun x=>u x+max (φ x-ε) 0) + (fun x=>G x+(if 0<φ x-ε then (1:ℝ) else 0) • gradient φ x)) : + energy (Metric.ball c r) u G≤ + (∫x in Metric.ball c r,‖G x+(if 0G x+(if 0G x+(if 0max (f (ns n) x-ε) 0) + (fun x=>(if 0u x+max (w x-ε) 0) V := + hu.add (SobolevCalculus.h1_positivePart Metric.isOpen_ball (h1_sub_const_ball hw.1 ε)) + have hF(n:ℕ):H1 B (fun x=>u x+max (f (ns n) x-ε) 0) (F n):=hu.add (hs n) + have hstrong:Tendsto (fun n=>eLpNorm (F n-V) 2 (volume.restrict B)) atTop (𝓝 0) := by + have hp:∀ᵐ x ∂volume.restrict B,Tendsto (fun n=>f (ns n) x-ε) atTop (𝓝 (w x-ε)):=by + filter_upwards [hpoint] with x hx + exact hx.sub_const ε + have hh:=SobolevCalculus.positivePart_gradient_strong_of_ae Metric.isOpen_ball + (h1_sub_const_ball hw.1 ε) (fun n=>h1_sub_const_ball (hf (ns n)).h1 ε) hp + (hfW.comp hns.tendsto_atTop) + convert hh using 1 + funext n + congr 1 + funext x + dsimp [F,V] + abel + have hlim:=tendsto_integral_norm_sq (fun n=>(hF n).2.1) hV.2.1 hstrong + have henv:=envelope_integral_tendsto hu.1.aestronglyMeasurable + (fun n=>(hf (ns n)).h1.1.aestronglyMeasurable) hpoint ε + have hbound(n:ℕ):energy B u G≤(∫x in B,‖F n x‖^2)+ + (∫x in B,envelope ε (u x) (f (ns n) x)) := by + apply (hcomp _ (hf (ns n))).trans + rw [energy,integral_add ((hF n).2.1.integrable_norm_pow (by norm_num)) + (integrable_phase (hF n).1.aestronglyMeasurable)] + apply add_le_add le_rfl + apply integral_mono_ae (integrable_phase (hF n).1.aestronglyMeasurable) + (envelope_integrable hu.1.aestronglyMeasurable (hf (ns n)).h1.1.aestronglyMeasurable ε) + filter_upwards [hun] with x hx + exact phase_threshold_le hε hx + have hh:=ge_of_tendsto (hlim.add henv) (Eventually.of_forall hbound) + apply hh.trans + apply add_le_add le_rfl + apply integral_mono_ae (envelope_integrable hu.1.aestronglyMeasurable hw.1.1.aestronglyMeasurable ε) + (integrable_phase (hu.add hw.1).1.aestronglyMeasurable) + filter_upwards [hun,hwn] with x hx hwx + exact envelope_le_phase hε hx hwx +/-- The faithful arbitrary-Sobolev upper-variation bridge. The sole comparison +input here is the concrete thresholded compact-test inequality; all density and +phase-limit steps are proved, without regularity assumptions on the competitor. -/ +theorem upper_variation_of_threshold_tests {c:Space d} {r:ℝ} {u w:Space d→ℝ} + {G W:Space d→Space d} (hu:H1 (Metric.ball c r) u G) + (hw:H10 (Metric.ball c r) w W) + (hun:∀ᵐ x ∂volume.restrict (Metric.ball c r),0≤u x) + (hwn:∀ᵐ x ∂volume.restrict (Metric.ball c r),0≤w x) + (hcomp:∀ε:ℝ,0<ε → ∀φ:Space d→ℝ,Test (Metric.ball c r) φ → + energy (Metric.ball c r) u G≤energy (Metric.ball c r) + (fun x=>u x+max (φ x-ε) 0) + (fun x=>G x+(if 0<φ x-ε then (1:ℝ) else 0) • gradient φ x)) : + energy (Metric.ball c r) u G≤energy (Metric.ball c r) + (fun x=>u x+w x) (fun x=>G x+W x) := by + let B:=Metric.ball c r + let : IsFiniteMeasure (volume.restrict B) := isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + let ε:ℕ→ℝ:=fun n=>1/((n:ℝ)+1) + have hε(n:ℕ):0<ε n:=by dsimp [ε]; positivity + have hεlim:Tendsto ε atTop (𝓝 0):=tendsto_one_div_add_atTop_nhds_zero_nat + let F:ℕ→Space d→Space d:=fun n x=>G x+(if 0G x+(if 0u x+max (w x-ε n) 0) (F n):= + hu.add (SobolevCalculus.h1_positivePart Metric.isOpen_ball (h1_sub_const_ball hw.1 (ε n))) + have hV:H1 B (fun x=>u x+max (w x) 0) V:= + hu.add (SobolevCalculus.h1_positivePart Metric.isOpen_ball hw.1) + have hstrong:Tendsto (fun n=>eLpNorm (F n-V) 2 (volume.restrict B)) atTop (𝓝 0) := by + have hp:∀ᵐ x ∂volume.restrict B,Tendsto (fun n=>w x-ε n) atTop (𝓝 (w x)):= + Eventually.of_forall fun x=>by simpa only [sub_zero] using tendsto_const_nhds.sub hεlim + have hWW:Tendsto (fun _n:ℕ=>eLpNorm (W-W) 2 (volume.restrict B)) atTop (𝓝 0):=by + simp only [sub_self,eLpNorm_zero] + exact tendsto_const_nhds + have hh:=SobolevCalculus.positivePart_gradient_strong_of_ae Metric.isOpen_ball + hw.1 (fun n=>h1_sub_const_ball hw.1 (ε n)) hp hWW + convert hh using 1 + funext n + congr 1 + funext x + dsimp [F,V] + abel + have hVe:V =ᵐ[volume.restrict B] (fun x=>G x+W x):=by + filter_upwards [hwn,SobolevCalculus.gradient_zero_on_zero_set Metric.isOpen_ball hw.1] with x hx h0 + by_cases hp:0by + change ‖V x‖^2=‖G x+W x‖^2 + rw [hx]) + have hlim:=tendsto_integral_norm_sq (fun n=>(hF n).2.1) hV.2.1 hstrong + rw [hnorm] at hlim + have hb(n:ℕ):energy B u G≤(∫x in B,‖F n x‖^2)+ + (∫x in B,if 0u x+w x) (fun x=>G x+W x) + change energy B u G ≤ ∫x in B, ‖G x+W x‖^2 + if 0y 0) ht + simpa [Cylindrical.transverse,axis] using hh + +lemma radiusSq_pos_ae : ∀ᵐ x:Space 7 ∂volume,0f e) hh + simpa [a] using h + exact he (inner_self_eq_zero.mp hx) + have hker:volume (LinearMap.ker a.toLinearMap : Set (Space 7))=0:=by + apply Measure.addHaar_submodule + rw [Ne,LinearMap.ker_eq_top] + intro hh + exact ha (ContinuousLinearMap.coe_injective hh) + have hne:∀ᵐ x:Space 7 ∂volume,x 0≠0:=by + rw [ae_iff] + change volume {x:Space 7 | inner ℝ e x=0}=0 at hker + simpa [e,not_not,EuclideanSpace.inner_single_left] using hker + filter_upwards [hne] with x hx + exact lt_of_le_of_ne (Cylindrical.radiusSq_nonneg axis x axis_norm) + (fun h=>hx (radiusSq_zero_coordinate h.symm)) + +lemma boundary_signed_slope {x:Space 7} (hq:0] 0,(upperParameter x t)^2] 0,tupperFlux (x,t)) (𝓝[>] 0) (𝓝 (κ • gradient Zsigned x)) := by + have hU:U x=0:=by rw [U_eq_signed_pospart hq,hz,max_self,mul_zero] + have he:(fun t:ℝ=>upperFlux (x,t)) =ᶠ[𝓝[>] 0] + (fun t=>κ • gradient Zsigned x+(t/KSup x) • gradient KSup x):=by + filter_upwards [boundary_outer_eventually hq hz,self_mem_nhdsWithin] with t ht ht0 + rw [upperFlux_outer_affine (by rwa [hU]) ht,hz,mul_zero,sub_zero] + apply Tendsto.congr' he.symm + have hc:ContinuousAt (fun t:ℝ=>κ • gradient Zsigned x+(t/KSup x) • gradient KSup x) 0:=by fun_prop + simpa only [zero_div,zero_smul,add_zero] using hc.tendsto.mono_left nhdsWithin_le_nhds + +/-- Full zero-phase upper trace bound, including the conical boundary. Only +the null axis is excluded; no assertion about the boundary's measure is used. -/ +theorem upperFlux_zero_trace_bound {x:Space 7} (hq:0] 0,‖upperFlux (x,t)‖^2<1+η := by + have hz:Zsigned x≤0:=by + rw [U_eq_signed_pospart hq] at hU + have hh:max (Zsigned x) 0=0:=(mul_eq_zero.mp hU).resolve_left κ_pos.ne' + exact (le_max_left _ _).trans hh.le + rcases hz.eq_or_lt with he|hl + · have ht:=((upperFlux_boundary_trace hq he).norm.pow 2) + rw [boundary_signed_slope hq he] at ht + exact ht.eventually (gt_mem_nhds (by linarith : (1:ℝ)<1+η)) + · exact (upperFlux_eventually_subunit hq hl).mono fun _ h=>by linarith +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperCalibration.lean b/lean/OAI/Analysis/BernoulliCone/UpperCalibration.lean new file mode 100644 index 0000000000000000000000000000000000000000..d22ba5580eeb4ce537973bcdc403996683863338 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperCalibration.lean @@ -0,0 +1,115 @@ +import OAI.Analysis.BernoulliCone.LaplacianDilation + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff Laplacian +namespace Bernoulli.DeSilvaJerison +lemma upperSigned_laplacian_nonpos {x:Space 7} + (hp:0l⁻¹ • y) x:= + (contDiffAt_id (𝕜:=ℝ) (n:=2) (x:=x)).const_smul l⁻¹ + have hg:ContDiffAt ℝ 2 (fun y:Space 7=>upperSigned (l⁻¹ • y)) x:= + ContDiffAt.comp (f:=fun y:Space 7=>l⁻¹ • y) x hf hi + have he:(upperFamily l) =ᶠ[𝓝 x] (fun y=>κ*l*upperSigned (l⁻¹ • y)) := by + filter_upwards [hg.continuousAt.eventually (lt_mem_nhds hpos)] with y hy + exact congrArg (κ*l* ·) (max_eq_left hy.le) + rw [(laplacian_congr_nhds he).self_of_nhds] + have hh:Δ (fun y:Space 7=>κ*l*upperSigned (l⁻¹ • y)) x= + κ*l*Δ (fun y:Space 7=>upperSigned (l⁻¹ • y)) x:=laplacian_smul (κ*l) hg + rw [hh,ScalarLaplacian.laplacian_comp_smul l⁻¹ hf] + exact mul_nonpos_of_nonneg_of_nonpos (mul_nonneg κ_pos.le hl.le) + (mul_nonpos_of_nonneg_of_nonpos (sq_nonneg _) (upperSigned_laplacian_nonpos hpos hq)) + +lemma upperFamily_contDiffAt_swap {x:Space 7} {l:ℝ} (hl:0upperFamily z.2 z.1) (x,l) := by + have hh:ContDiffAt ℝ ∞ (fun z:ℝ×Space 7=>upperFamily z.1 z.2) (l,x):= + upperFamily_joint_contDiffAt (p:=(l,x)) hl hp hq + have hi:ContDiffAt ℝ ∞ (fun z:Space 7×ℝ=>(z.2,z.1)) (x,l):= + contDiffAt_snd.prodMk contDiffAt_fst + exact ContDiffAt.comp (f:=fun z:Space 7×ℝ=>(z.2,z.1)) (x,l) hh hi + +/-- The actual upper foliation's spatial gradient at a point above the cone. -/ +def upperCalibration (p:Space 7×ℝ) : Space 7 := + Foliation.spatialGradient (fun z:Space 7×ℝ=>upperFamily z.2 z.1) + (p.1,upperParameter p.1 p.2) + +lemma upperCalibration_contDiffAt {p:Space 7×ℝ} (hp:U p.1upperFamily z.2 z.1) + (p.1,upperParameter p.1 p.2):=by + exact upperFamily_contDiffAt_swap hl (by rw [he]; exact (U_nonneg _).trans_lt hp) hq + exact (Foliation.spatialGradient_contDiffAt hF).comp p + (contDiffAt_fst.prodMk (upperParameter_contDiffAt hp hq)) + +theorem upperCalibration_bulk {p:Space 7×ℝ} (hp:U p.1upperCalibration (x,p.2)) p.1+ + inner ℝ (upperCalibration p) (deriv (fun t=>upperCalibration (p.1,t)) p.2)≤0 := by + let F:Space 7×ℝ→ℝ:=fun z=>upperFamily z.2 z.1 + let L:Space 7×ℝ→ℝ:=fun z=>upperParameter z.1 z.2 + have hl:0(p.1,t)) (0,1) (L p):=by + simpa using (hasDerivAt_const (L p) p.1).prodMk (hasDerivAt_id (L p)) + have hh:HasDerivAt (fun t:ℝ=>upperFamily t p.1) (fderiv ℝ F (p.1,L p) (0,1)) (L p):=by + exact (hF.differentiableAt (by simp)).hasFDerivAt.comp_hasDerivAt (L p) his + exact (hh.unique hd).symm ▸ hρ.ne' + have hid:=Foliation.foliation_divergence hF hL he hρ' + change Foliation.divergence (fun x=>upperCalibration (x,p.2)) p.1+ + inner ℝ (upperCalibration p) (deriv (fun t=>upperCalibration (p.1,t)) p.2)= + Δ (upperFamily (L p)) p.1 at hid + rw [hid] + exact upperFamily_laplacian_nonpos hl hpos hq +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperComparison.lean b/lean/OAI/Analysis/BernoulliCone/UpperComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ef6a9119b4963147df6163dae44c99f483f8c6a --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperComparison.lean @@ -0,0 +1,61 @@ +import OAI.Analysis.BernoulliCone.ThresholdRecovery + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison + +lemma threshold_lipschitz {φ:Space 7→ℝ} {D:Set (Space 7)} (hφ:Test D φ) (δ:ℝ) : + ∃K:ℝ≥0,LipschitzWith K (fun x=>max (φ x-δ) 0) := by + obtain ⟨K,hK⟩:=hφ.1.lipschitzWith_of_hasCompactSupport hφ.2.1 (by simp) + have hD:LipschitzWith K (fun x=>φ x-δ):=by + apply LipschitzWith.of_dist_le_mul + intro x y + simpa only [dist_sub_right] using hK.dist_le_mul x y + exact ⟨K,hD.max_const 0⟩ +lemma threshold_support {φ:Space 7→ℝ} {δ:ℝ} (hδ:0≤δ): + tsupport (fun x=>U x+max (φ x-δ) 0-U x)⊆tsupport φ := by + apply closure_minimal _ (isClosed_tsupport _) + intro x hx + by_contra hn + have hφ:φ x=0:=image_eq_zero_of_notMem_tsupport hn + have hh:max (φ x-δ) 0=0:=by rw [hφ,max_eq_right (by linarith)] + exact hx (by dsimp; rw [hh]; ring) + +/-- The actual upper foliation comparison, transferred through H1-zero trace +closure to every admissible upper Sobolev competitor on every ball. -/ +theorem U_upper_comparison (c:Space 7) (r:ℝ) (hr:0v x-U x) (fun x=>V x-gradient U x)) : + energy (Metric.ball c r) U (gradient U)≤energy (Metric.ball c r) v V := by + have hu:=U_h1loc c r hr (subset_univ _) + have hh:=ThresholdRecovery.upper_variation_of_threshold_tests hu ⟨hv.sub hu, htrace.2⟩ + (Eventually.of_forall U_nonneg) (hUv.mono fun x hx=>sub_nonneg.mpr hx) + have hcomp:∀δ:ℝ,0<δ → ∀φ:Space 7→ℝ,Test (Metric.ball c r) φ → + energy (Metric.ball c r) U (gradient U)≤energy (Metric.ball c r) + (fun x=>U x+max (φ x-δ) 0) + (fun x=>gradient U x+(if 0<φ x-δ then (1:ℝ) else 0) • gradient φ x):=by + intro δ hδ φ hφ + obtain ⟨K,hK⟩:=exists_lipschitz_U + obtain ⟨L,hL⟩:=threshold_lipschitz hφ δ + have hvL:=hK.add hL + have hsub:=threshold_support (φ:=φ) hδ.le + have hc:HasCompactSupport (fun x=>U x+max (φ x-δ) 0-U x):= + hφ.2.1.of_isClosed_subset (isClosed_tsupport _) hsub + have he:=U_upper_lipschitz_comparison hvL (fun x=>by have hh:=le_max_right (φ x-δ) 0; linarith) hc (hsub.trans hφ.2.2) + have hH:H1 (Metric.ball c r) (fun x=>U x+max (φ x-δ) 0) + (fun x=>gradient U x+(if 0<φ x-δ then (1:ℝ) else 0) • gradient φ x):= + hu.add (SobolevCalculus.h1_positivePart Metric.isOpen_ball (ThresholdRecovery.h1_sub_const_ball hφ.h1 δ)) + rwa [energy_congr (EventuallyEq.refl _ _) ((LipschitzSobolev.h1_ball hvL c r).gradient_unique Metric.isOpen_ball hH)] at he + simpa only [add_sub_cancel] using hh hcomp +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperFamily.lean b/lean/OAI/Analysis/BernoulliCone/UpperFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..7a63b2dca70bdd7126d203b960eeaee5b57f24f4 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperFamily.lean @@ -0,0 +1,154 @@ +import OAI.Analysis.BernoulliCone.UpperSeam + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.Cylindrical +lemma axis_smul {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (e x:E) (t:ℝ) : axis e (t • x)=t*axis e x := by simp [axis,real_inner_smul_left] +lemma radiusSq_smul {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (e x:E) (t:ℝ) : radiusSq e (t • x)=t^2*radiusSq e x := by + simp only [radiusSq,axis_smul,norm_smul,Real.norm_eq_abs,mul_pow,sq_abs] + ring +end Bernoulli.Cylindrical +namespace Bernoulli.DeSilvaJerison +lemma angle_smul (x:Space 7) {t:ℝ} (ht:0le_of_lt (not_le.mp hy)) (isClosed_le continuous_const hc)) hx + have hqp:0l⁻¹ • x):=continuous_id.const_smul l⁻¹ + have hg:Continuous (fun x:Space 7=>max (upperSigned (l⁻¹ • x)) 0):= + (upperSigned_continuous.comp hc).max continuous_const + exact continuous_const.mul hg +lemma upperFamily_joint_continuous : ContinuousOn (fun z:ℝ×Space 7=>upperFamily z.1 z.2) {z|0t⁻¹ • x) l=l⁻¹ • x:=rfl + have hps:0κ*(t*smoothCap (t⁻¹ • x))) v l:= + (Foliation.hasDerivAt_dilate x hl.ne' (hc.differentiableAt (by norm_num))).const_mul κ + apply hd.hasDerivWithinAt.congr_of_eventuallyEq + · filter_upwards [self_mem_nhdsWithin] with t ht + have htpos:0κ*(t*outerSigned (t⁻¹ • x))) v l:= + (Foliation.hasDerivAt_dilate x hl.ne' + ((outerSigned_contDiffAt (n:=1) hx0 ha).differentiableAt (by norm_num))).const_mul κ + have hcont:ContinuousAt (fun t:ℝ=>Cylindrical.radiusSq axis (t⁻¹ • x)) l:= + (Cylindrical.radiusSq_contDiff axis (n:=1)).continuous.continuousAt.comp + ((continuousAt_id.inv₀ hl.ne').smul continuousAt_const) + apply hd.hasDerivWithinAt.congr_of_eventuallyEq + · filter_upwards [(hcont.eventually (lt_mem_nhds hq1)).filter_mono nhdsWithin_le_nhds] with t ht + rw [upperTrace,upperSigned_outer ht.le] + ring + · rw [upperTrace,upperSigned_outer hq1.le] + ring +lemma upperFamily_monotone (x:Space 7) : MonotoneOn (fun l=>upperFamily l x) (Ioi 0) := by + intro a ha b hb hab + change upperFamily a x ≤ upperFamily b x + rw [upperFamily_eq_max ha.le,upperFamily_eq_max hb.le] + exact Foliation.monotone_positive_part hab + ((upperTrace_continuous x).mono (fun t ht=>ha.trans_le ht.1)) + (fun t ht hp=>upperTrace_right_derivative x (ha.trans_le ht.1) hp) +lemma upperFamily_strict {x:Space 7} {a b:ℝ} (ha:0ha.trans_le ht.1)) hpa + (fun t ht hpt=>upperTrace_right_derivative x (ha.trans_le ht.1) hpt) + rw [max_eq_left hpa.le,max_eq_left (hpa.trans hh).le] + exact hh +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperLeaves.lean b/lean/OAI/Analysis/BernoulliCone/UpperLeaves.lean new file mode 100644 index 0000000000000000000000000000000000000000..c9d0ebef989814ec2909a277a1fd742ae765eb86 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperLeaves.lean @@ -0,0 +1,102 @@ +import OAI.Analysis.BernoulliCone.UpperLimits + +namespace OAI + +section +noncomputable section +open Set Filter +open scoped Topology +namespace Bernoulli.DeSilvaJerison + +lemma upperSigned_pos_zero :0upperFamily l x) (Ioi 0) := by + intro l hl + unfold upperFamily + exact ((continuousAt_const.mul continuousAt_id).mul + ((upperSigned_continuous.continuousAt.comp + ((continuousAt_id.inv₀ (ne_of_gt hl)).smul continuousAt_const)).max continuousAt_const)).continuousWithinAt +lemma upperFamily_tendsto_atTop (x:Space 7) : + Tendsto (fun l:ℝ=>upperFamily l x) atTop atTop := by + have hi:Tendsto (fun l:ℝ=>l⁻¹ • x) atTop (𝓝 0) := by + simpa only [zero_smul] using (tendsto_inv_atTop_zero: Tendsto (fun l:ℝ=>l⁻¹) atTop (𝓝 0)).smul (tendsto_const_nhds (x:=x)) + have hs:Tendsto (fun l:ℝ=>max (upperSigned (l⁻¹ • x)) 0) atTop (𝓝 (upperSigned 0)) := by + simpa only [Function.comp_apply,max_eq_left upperSigned_pos_zero.le] using + (upperSigned_continuous.tendsto 0 |>.comp hi).max (tendsto_const_nhds (x:=(0:ℝ))) + exact (tendsto_id.const_mul_atTop κ_pos).atTop_mul_pos upperSigned_pos_zero hs +lemma U_le_upperFamily (x:Space 7) {l:ℝ} (hl:0] 0,s] 0,0ha.trans_le hy.1)) ⟨hat.le,hbt.le⟩ + change upperFamily l x=t at hle + have hl:0upperFamily l x) (𝓝[>] 0) (𝓝 (U x)) := by + have hc:ContinuousAt (fun l:ℝ=>κ*max (Zsigned x+capAmplitude*l^3*KSup x) 0) 0:=by fun_prop + have he:(fun l:ℝ=>upperFamily l x)=ᶠ[𝓝[>] 0] + (fun l:ℝ=>κ*max (Zsigned x+capAmplitude*l^3*KSup x) 0) := by + have hsq:∀ᶠ l:ℝ in 𝓝[>] 0,l^2upperFamily l x) (𝓝[>] 0) (𝓝 (U x)) := by + rcases (Cylindrical.radiusSq_nonneg axis x axis_norm).eq_or_lt with hq|hq + · rw [U_zero_of_radiusSq_zero hq.symm] + apply squeeze_zero' (by filter_upwards [self_mem_nhdsWithin] with l hl; exact upperFamily_nonneg hl.le x) + (by filter_upwards [self_mem_nhdsWithin] with l hl; exact upperFamily_axis_bound hq.symm hl.le) + have hc:ContinuousAt (fun l:ℝ=>κ*l*smoothCap 0) 0:=by fun_prop + simpa only [mul_zero,zero_mul] using hc.tendsto.mono_left nhdsWithin_le_nhds + · exact upperFamily_tendsto_zero_off_axis hq +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperLipschitzComparison.lean b/lean/OAI/Analysis/BernoulliCone/UpperLipschitzComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..133cb9237c894bcb68b8118381ff3ac394040d0f --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperLipschitzComparison.lean @@ -0,0 +1,108 @@ +import OAI.Analysis.BernoulliCone.IntegralUpperLimit + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace MeasureTheory +open scoped Topology ContDiff NNReal +namespace Bernoulli.DeSilvaJerison +open Foliation + +def energyDifference (v:Space 7→ℝ) (x:Space 7):ℝ:= + (‖gradient v x‖^2+if 0U x+ε n) atTop (𝓝[>] U x):=by + rw [tendsto_nhdsWithin_iff] + exact ⟨by simpa using tendsto_const_nhds.add hεt, + Eventually.of_forall (fun n=>by change U xU x+ε n) atTop (𝓝 (U x))).eventually (gt_mem_nhds hl) + rcases (U_nonneg x).eq_or_lt with he0|hp + · have hu0:U x=0:=he0.symm + have hg:gradient U x=0:=by + have hh:=gradient_eq_of_order_contact (differentiableAt_const (c:=(0:ℝ))) hdu U_nonneg he0 + simpa only [gradient_fun_const] using hh.symm + have hεw:Tendsto ε atTop (𝓝[>] (0:ℝ)):=by + rw [tendsto_nhdsWithin_iff] + exact ⟨hεt,Eventually.of_forall hε⟩ + have hn:=hεw.eventually (upperFlux_zero_trace_bound hq hu0 hη) + filter_upwards [hn,hlt] with n hn hlt + rw [comparisonR,ite_eq_left hlt] + simp only [energyDifference,hu0,hg,norm_zero,zero_pow (by norm_num:2≠0), + ite_eq_left hvp,lt_self_iff_false,ite_false,zero_add,inner_zero_right,mul_zero,sub_zero] + linarith + · have hA:Tendsto (fun n=>upperFlux (x,U x+ε n)) atTop (𝓝 (gradient U x)):= + (upperFlux_tendsto_positive_trace hp).comp hheight + have ht:Tendsto (fun n=>‖gradient v x‖^2+‖upperFlux (x,U x+ε n)‖^2- + 2*inner ℝ (upperFlux (x,U x+ε n)) (gradient U x)) atTop + (𝓝 (energyDifference v x)):=by + have hvc:Tendsto (fun _n:ℕ=>‖gradient v x‖^2) atTop (𝓝 (‖gradient v x‖^2)):=tendsto_const_nhds + have hgc:Tendsto (fun _n:ℕ=>gradient U x) atTop (𝓝 (gradient U x)):=tendsto_const_nhds + have hh:=(hvc.add (hA.norm.pow 2)).sub ((hA.inner hgc).const_mul 2) + convert hh using 1 + simp only [energyDifference,ite_eq_left hp,ite_eq_left hvp,real_inner_self_eq_norm_sq] + ring_nf + have hn:=ht.eventually (gt_mem_nhds (by linarith : energyDifference v xv y-U y)) + {c:Space 7} {r:ℝ} (hS:tsupport (fun y=>v y-U y)⊆Metric.ball c r) : + energy (Metric.ball c r) U (gradient U)≤energy (Metric.ball c r) v (gradient v) := by + let B:=Metric.ball c r + let μ:=volume.restrict B + let :IsFiniteMeasure μ:=isFiniteMeasure_restrict.mpr measure_ball_lt_top.ne + obtain ⟨K,hK⟩:=exists_lipschitz_U + obtain ⟨C,hC,hA⟩:=upperFlux_uniform_bound + let ε:ℕ→ℝ:=fun n=>1/((n:ℝ)+1) + have hε(n:ℕ):0<ε n:=by dsimp [ε]; positivity + have hεt:Tendsto ε atTop (𝓝 0):=tendsto_one_div_add_atTop_nhds_zero_nat + have huH:=LipschitzSobolev.h1_ball hK c r + have hvH:=LipschitzSobolev.h1_ball hv c r + have huI:Integrable (fun x=>‖gradient U x‖^2+if 0‖gradient v x‖^2+if 0Eventually.of_forall (comparisonR_bound hK hv hC.le hA (ε n))) + (fun n=>comparisonR_integral_nonneg hv (hε n) hc hS) hlim + change 0≤∫x,energyDifference v x ∂μ at hi + rw [show energyDifference v=(fun x=>(‖gradient v x‖^2+if 0upperParameter z.1 z.2) p := by + have hdom:∀ᶠ z:Space 7×ℝ in 𝓝 p,U z.1upperParameter z.1 z.2) + {z|U z.1(upperParameter_continuousAt hp).continuousWithinAt +end Bernoulli.DeSilvaJerison + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/UpperSeam.lean b/lean/OAI/Analysis/BernoulliCone/UpperSeam.lean new file mode 100644 index 0000000000000000000000000000000000000000..630c1432b054db75b3112286f455cdcd8a3bb998 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/UpperSeam.lean @@ -0,0 +1,115 @@ +import OAI.Analysis.BernoulliCone.StrictSlope + +namespace OAI + +universe uE + +section +noncomputable section +open Set Filter +open scoped Topology ContDiff Laplacian +namespace Bernoulli.Cylindrical +lemma axis_add_axis {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (e x:E) (he:‖e‖=1) (t:ℝ) : axis e (x+t • e)=axis e x+t := by + simp [axis,inner_add_left,real_inner_smul_left,he] +lemma radiusSq_add_axis {E : Type uE} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (e x:E) (he:‖e‖=1) (t:ℝ) : radiusSq e (x+t • e)=radiusSq e x := by + simp only [radiusSq,axis_add_axis e x he,norm_add_sq_real,norm_smul, + Real.norm_eq_abs,sq_abs,he,mul_one,real_inner_smul_right] + unfold axis + ring +end Bernoulli.Cylindrical +namespace Bernoulli.DeSilvaJerison +lemma cap_boundary_slope_lt : capC^2*(capHP (3/4))^2outerSigned (x+t • axis))=fun t=>capH (Cylindrical.axis axis x+t) := by + funext t + rw [outerSigned_at_seam (by rw [Cylindrical.radiusSq_add_axis axis x axis_norm,hq]), + Cylindrical.axis_add_axis axis x axis_norm] + rw [he] + have hh:HasDerivAt (fun t:ℝ=>capH (Cylindrical.axis axis x+t)) (capHP (Cylindrical.axis axis x)) 0 := by + convert! (hasDerivAt_capH (Cylindrical.axis axis x+0)).comp 0 ((hasDerivAt_id 0).const_add (Cylindrical.axis axis x)) using 1 + simp + exact hh.deriv + +lemma outerSigned_transverse_at_seam {x:Space 7} (hq:Cylindrical.radiusSq axis x=1) : + inner ℝ (gradient outerSigned x) (Cylindrical.transverse axis x)= + capH (Cylindrical.axis axis x)-Cylindrical.axis axis x*capHP (Cylindrical.axis axis x)- + 3*capAmplitude*(1+2*(Cylindrical.axis axis x)^2) := by + have hqp:0upperFamily z.1 z.2) p := by + have hpos:0z.1⁻¹ • z.2) p:= + (contDiffAt_fst.inv hl.ne').smul contDiffAt_snd + have hs0 : ContDiffAt ℝ ∞ upperSigned (p.1⁻¹ • p.2) := + upperSigned_contDiffAt hq + have hs:ContDiffAt ℝ ∞ (fun z:ℝ×Space 7=>upperSigned (z.1⁻¹ • z.2)) p := by + exact ContDiffAt.comp (f:=fun z:ℝ×Space 7=>z.1⁻¹ • z.2) (g:=upperSigned) p hs0 hi + apply ((contDiffAt_const.mul contDiffAt_fst).mul hs).congr_of_eventuallyEq + filter_upwards [hs.continuousAt.eventually (lt_mem_nhds hpos)] with z hz + exact congrArg (κ*z.1* ·) (max_eq_left hz.le) +lemma upperFamily_scale_derivative {x:Space 7} {l:ℝ} (hl:0upperFamily s x) ρ l := by + let ρ:=κ*(upperSigned (l⁻¹ • x)-inner ℝ (l⁻¹ • x) (gradient upperSigned (l⁻¹ • x))) + have hd:HasDerivAt (upperTrace x) ρ l := by + have hh:HasDerivAt (fun s:ℝ=>κ*(s*upperSigned (s⁻¹ • x))) ρ l:= + (Foliation.hasDerivAt_dilate x hl.ne' + ((upperSigned_contDiffAt hq).differentiableAt (by simp))).const_mul κ + change HasDerivAt (fun s=>κ*s*upperSigned (s⁻¹ • x)) ρ l + simpa only [mul_assoc] using hh + have hpt:0upperParameter z.1 z.2) p := by + let l:=upperParameter p.1 p.2 + have hl:0upperFamily z.2 z.1.1-z.1.2 + have hpl:0upperFamily z.1 z.2) (l,p.1) := + upperFamily_joint_contDiffAt (p:=(l,p.1)) hl hpl hq + have hF:ContDiffAt ℝ ∞ F (p,l) := by + have hh:ContDiffAt ℝ ∞ (fun z:(Space 7×ℝ)×ℝ=>(z.2,z.1.1)) (p,l):=by fun_prop + exact (hUF.comp (p,l) hh).sub + (contDiffAt_fst.snd) + obtain ⟨ρ,hρ,hd⟩:=upperFamily_scale_derivative hl hpl hq + have hdF:HasDerivAt (fun s:ℝ=>F (p,s)) ρ l:=by simpa only [F] using hd.sub_const p.2 + obtain ⟨ψ,hψ,hψ0,hψeq⟩:=Foliation.scalar_implicit hF hdF hρ.ne' + have hF0:F (p,l)=0:=by dsimp [F]; rw [he,sub_self] + apply hψ.congr_of_eventuallyEq + have hψpos:∀ᶠ z in 𝓝 p,0<ψ z:=hψ.continuousAt.eventually (lt_mem_nhds (by rwa [hψ0])) + have hdom:∀ᶠ z:Space 7×ℝ in 𝓝 p,U z.1.trans_eq (mul_comm _ _) + · have he:UpperAlgebra.fhi (t^2)/(8*(1-t^2)^2)= + (8-25*t^2+15*(t^2)^2)/(8*(1-t^2)^2)-15/8*t^2*B 6 (t^2) := by + unfold UpperAlgebra.fhi B + norm_num [Finset.sum_range_succ] + field_simp [ne_of_gt hd] + ring + rw [←he] at hU + simpa only [mul_comm] using (le_div_iff₀ (by positivity)).mp hU + +lemma quadratic_bound {A B C L H X R:ℝ} (hA:0≤A) (hXL:L≤X) (hXH:X≤H) + (hL:A*L^2+B*L+C≤R) (hH:A*H^2+B*H+C≤R) : + A*X^2+B*X+C≤R := by + by_cases he:L=H + · have hx:X=L:=by linarith + simpa only [hx] using hL + have hLH:0 linarith [hA.1,hA.2] +lemma capAmplitude_pos : 0(hasDerivAt_capHP s).differentiableAt) + intro s + rw [(hasDerivAt_capHP s).deriv] + have hh:1≤(capRadius s)^3:=one_le_pow₀ (capRadius_one_le s) + linarith [capAmplitude_le] + +lemma capHP_nonpos {s:ℝ} (hs:0≤ s) :capHP s≤0 := by + have hh:=capHP_antitone hs + simpa only [capHP_zero] using hh + +lemma capHP_le_linear {s:ℝ} (hs:0≤ s) : capHP s≤(-5+4*capAmplitude)*s := by + let g:ℝ→ℝ:=fun t=>capHP t-(-5+4*capAmplitude)*t + have hD (t:ℝ) :HasDerivAt g (-5*(capRadius t)^3+5) t := by + convert! (hasDerivAt_capHP t).sub ((hasDerivAt_id t).const_mul (-5+4*capAmplitude)) using 1 + ring + have hM:Antitone g := by + apply antitone_of_deriv_nonpos (fun t=>(hD t).differentiableAt) + intro t + rw [(hD t).deriv] + have hh:1≤(capRadius t)^3:=one_le_pow₀ (capRadius_one_le t) + linarith + have hh:=hM hs + dsimp [g] at hh + rw [capHP_zero] at hh + linarith + +lemma capH_antitone : AntitoneOn capH (Set.Ici 0) := by + apply antitoneOn_of_deriv_nonpos (convex_Ici (0:ℝ)) + · exact fun s _=>(hasDerivAt_capH s).continuousAt.continuousWithinAt + · exact fun s _=>(hasDerivAt_capH s).differentiableAt.differentiableWithinAt + · intro s hs + rw [(hasDerivAt_capH s).deriv] + exact capHP_nonpos (interior_subset hs) + +lemma capH_nonneg {s:ℝ} (hs:|s|≤3/4) :0≤capH s := by + have hh:=capH_antitone (show (|s|:ℝ)∈Set.Ici 0 from abs_nonneg s) (by norm_num : (3/4:ℝ)∈Set.Ici 0) hs + rw [capH_end] at hh + rcases le_total 0 s with hp|hn + · simpa only [abs_of_nonneg hp] using hh + · simpa only [abs_of_nonpos hn,capH_even] using hh + +lemma capHPP_nonpos (s:ℝ) :-5*(capRadius s)^3+4*capAmplitude≤0 := by + have hh:1≤(capRadius s)^3:=one_le_pow₀ (capRadius_one_le s) + linarith [capAmplitude_le] + +lemma capAngle_bounds {s:ℝ} (hs:0≤ s) (hs1:s≤3/4) : 0≤capAngle s ∧ capAngle s≤3/5 := by + have hr:=capRadius_pos s + constructor + · exact div_nonneg hs hr.le + · rw [capAngle,div_le_iff₀ hr] + have hs2:s^2≤9/16:=by nlinarith + nlinarith [capRadius_sq s] + +lemma cap_flo_bound {t:ℝ} (ht:0≤t) (ht1:t≤3/5) : CapSign.flo (t^2)≤8*(1-t^2)^2*f t := by + have hd:0<1-t^2:=by nlinarith + have hl:=f_series_lower 6 ht (by linarith : t<1) + have hi:CapSign.flo (t^2)/(8*(1-t^2)^2)= + (8-25*t^2+15*(t^2)^2)/(8*(1-t^2)^2)-15/8*t^2*(B 6 (t^2)+(t^2)^6/(1-t^2)) := by + unfold CapSign.flo B + norm_num [Finset.sum_range_succ] + field_simp [hd.ne'] + ring + rw [←hi] at hl + exact (div_le_iff₀ (by positivity)).mp hl |>.trans_eq (mul_comm _ _) + +lemma cap_K_identity (s:ℝ) : + (-5*(capRadius s)^3+4*capAmplitude-(673/250)*s*capHP s+(431/200)*capH s)/(capRadius s)^5= + (431/200-673/250)*(1-(capAngle s)^2)^2*f (capAngle s)+673/250-5*(1-(capAngle s)^2)+ + capAmplitude/(capRadius s)^3*(4*(1-(capAngle s)^2)-4*(673/250)*(capAngle s)^2+431/200*(1+(capAngle s)^2)) := by + rw [capHP,capH,capAngle_d,cap_f_relation] + unfold capAngle + field_simp [(capRadius_pos s).ne'] + have he:s^2=(capRadius s)^2-1:=by linarith [capRadius_sq s] + have he3:s^3=s*((capRadius s)^2-1):=by linear_combination s*he + ring_nf + rw [he,he3] + ring + +theorem cap_K_nonpos {s:ℝ} (hs:|s|≤3/4) : + -5*(capRadius s)^3+4*capAmplitude-(673/250)*s*capHP s+(431/200)*capH s≤0 := by + suffices hp:∀t:ℝ, 0≤t → t≤3/4 → + -5*(capRadius t)^3+4*capAmplitude-(673/250)*t*capHP t+(431/200)*capH t≤0 by + rcases le_total 0 s with hpos|hneg + · exact hp s hpos (by rw [abs_of_nonneg hpos] at hs; exact hs) + · have hh:=hp (-s) (by linarith) (by rw [abs_of_nonpos hneg] at hs; exact hs) + simpa only [capRadius,neg_sq,capHP_odd,capH_even,mul_neg,neg_mul,neg_neg] using hh + intro s hs hs1 + obtain ⟨ht,ht1⟩:=capAngle_bounds hs hs1 + have hu:0≤(capAngle s)^2:=sq_nonneg _ + have hu1:(capAngle s)^2≤9/25:=by nlinarith + have hd:0≤1-(capAngle s)^2:=by linarith + have hB:0≤4*(1-(capAngle s)^2)-4*(673/250)*(capAngle s)^2+431/200*(1+(capAngle s)^2):=by linarith + have hF:=cap_flo_bound ht ht1 + have hF':(431/200-673/250)*(1-(capAngle s)^2)^2*f (capAngle s)≤ + (431/200-673/250)*CapSign.flo ((capAngle s)^2)/8 := by nlinarith + have hr:=capRadius_pos s + have hr1:=capRadius_one_le s + have hRa:capAmplitude/(capRadius s)^3≤29/100*(1-(capAngle s)^2) := by + rw [capAngle_d] + field_simp [hr.ne'] + nlinarith [capAmplitude_le] + have hAB:=mul_le_mul_of_nonneg_right hRa hB + have hp:=CapSign.polyK_nonpos hu hu1 + unfold CapSign.polyK at hp + have hh:(-5*(capRadius s)^3+4*capAmplitude-(673/250)*s*capHP s+(431/200)*capH s)/(capRadius s)^5≤0 := by + rw [cap_K_identity] + linarith + simpa only [zero_mul] using (div_le_iff₀ (pow_pos hr 5)).mp hh + +end Bernoulli.DeSilvaJerison + +namespace Bernoulli.DeSilvaJerison + +def capEta : ℝ := capP - (9/16)*capP*(capP-3/25)/(1+(9/16)*capP^2) +def capW (s : ℝ) : ℝ := (1-capEta)*capH s+(capP-1)*s*capHP s-3*capAmplitude*(1+2*s^2) +def capWP (s : ℝ) : ℝ := (capP-capEta)*capHP s+(capP-1)*s*(-5*(capRadius s)^3+4*capAmplitude)-12*capAmplitude*s +def capWPP (s : ℝ) : ℝ := (2*capP-capEta-1)*(-5*(capRadius s)^3+4*capAmplitude)+(capP-1)*(-15*s^2*capRadius s)-12*capAmplitude + +lemma capP_bounds : 3884/10000≤capP ∧ capP≤3886/10000 := by + have hh:=capB_bounds + unfold capB at hh + constructor <;> linarith [hh.1,hh.2] +lemma capEta_bounds : 1/3≤capEta ∧ capEta≤capP := by + have hp:=capP_bounds + have hq:0<1+(9/16)*capP^2:=by positivity + have hpp:0≤capP*(capP-3/25):=mul_nonneg (by linarith [hp.1]) (by linarith [hp.1]) + have hprod:capP*(capP-3/25)≤(3886/10000)*(2686/10000):=by + exact mul_le_mul hp.2 (by linarith [hp.2]) (by linarith [hp.1]) (by norm_num) + have hsq:(3884/10000:ℝ)^2≤capP^2:=by nlinarith [hp.1] + unfold capEta + constructor + · have hdelta : (9/16)*capP*(capP-3/25)/(1+(9/16)*capP^2)≤capP-1/3 := by + apply (div_le_iff₀ hq).mpr + have hh:=mul_le_mul_of_nonneg_left hsq (show (0:ℝ)≤9/16 from by norm_num) + have ha:0≤capP-1/3:=by linarith [hp.1] + have hb:((3884/10000:ℝ)-1/3)*(1+(9/16)*(3884/10000:ℝ)^2)≤(capP-1/3)*(1+(9/16)*capP^2):= + mul_le_mul (by linarith [hp.1]) (by linarith) (by positivity) ha + nlinarith + linarith + · exact sub_le_self _ (div_nonneg (by nlinarith) hq.le) + +lemma capW_even (s : ℝ) : capW (-s)=capW s := by + simp only [capW,capH_even,capHP_odd,neg_sq,mul_neg,neg_mul,neg_neg] +lemma capW_zero_nonpos : capW 0≤0 := by + rw [capW,capH_zero,capHP_zero] + norm_num + have hprod:=mul_le_mul_of_nonneg_right capEta_bounds.1 capAmplitude_pos.le + nlinarith [capAmplitude_bounds.1,capEta_bounds.1] +lemma capW_end : capW (3/4)=0 := by + rw [capW,capH_end,capHP_end] + simp only [mul_zero,zero_add] + have hd:3125/1024-capAmplitude/8≠0:=ne_of_gt (by linarith [capAmplitude_le]) + have hp : capP*(3125/1024-capAmplitude/8)=3125/1024-13/2*capAmplitude := by + rw [capP,div_mul_cancel₀ _ hd] + nlinarith + +lemma hasDerivAt_capW (s : ℝ) : HasDerivAt capW (capWP s) s := by + have hh:=(((hasDerivAt_capH s).const_mul (1-capEta)).add + (((hasDerivAt_id s).const_mul (capP-1)).mul (hasDerivAt_capHP s))).sub + (((hasDerivAt_const s (1:ℝ)).add (((hasDerivAt_id s).pow 2).const_mul 2)).const_mul (3*capAmplitude)) + convert! hh using 1 + simp only [capWP,id_eq,Nat.cast_ofNat] + ring +lemma hasDerivAt_capWP (s : ℝ) : HasDerivAt capWP (capWPP s) s := by + have hR:=hasDerivAt_capRadius s + have hH:HasDerivAt (fun t=>-5*(capRadius t)^3+4*capAmplitude) (-15*s*capRadius s) s := by + convert! ((hR.pow 3).const_mul (-5)).add_const (4*capAmplitude) using 1 + norm_num only [Nat.reduceSub,Nat.cast_ofNat] + field_simp [(capRadius_pos s).ne'] + ring + have hh:=(((hasDerivAt_capHP s).const_mul (capP-capEta)).add + (((hasDerivAt_id s).const_mul (capP-1)).mul hH)).sub ((hasDerivAt_id s).const_mul (12*capAmplitude)) + convert! hh using 1 + simp only [capWPP,id_eq] + ring + +lemma capRadius_cube_bound (s : ℝ) : (capRadius s)^3-1≤(3/2)*(capRadius s)*s^2 := by + have hr:=capRadius_pos s + have hh:=mul_nonneg (sq_nonneg (capRadius s-1)) (by linarith : 0≤capRadius s+2) + nlinarith [capRadius_sq s, mul_nonneg (sq_nonneg (capRadius s-1)) hr.le] + +lemma capW_radial_convex {s : ℝ} (hs : 0≤ s) : 0≤ s*capWPP s-capWP s := by + have he:s*capWPP s-capWP s=(capP-capEta)*(s*(-5*(capRadius s)^3+4*capAmplitude)-capHP s)+ + 15*(1-capP)*s^3*capRadius s := by unfold capWPP capWP; ring + rw [he] + have hc:0≤capP-capEta:=sub_nonneg.mpr capEta_bounds.2 + have hb:=mul_le_mul_of_nonneg_left (capHP_le_linear hs) hc + have hR:=mul_le_mul_of_nonneg_left (capRadius_cube_bound s) (show 0≤5*(capP-capEta)*s by positivity) + have hex:0≤(15*(1-capP)-(15/2)*(capP-capEta))*s^3*capRadius s := by + have hh:0≤15*(1-capP)-(15/2)*(capP-capEta):=by linarith [capP_bounds.2,capEta_bounds.1] + exact mul_nonneg (mul_nonneg hh (pow_nonneg hs 3)) (capRadius_pos s).le + nlinarith + +def capZ (q : ℝ) : ℝ := capW (Real.sqrt q) +def capZP (q : ℝ) : ℝ := capWP (Real.sqrt q)/(2*Real.sqrt q) +lemma hasDerivAt_capZ {q : ℝ} (hq : 0(hasDerivAt_capW s).continuousAt)).comp Real.continuous_sqrt + have hp {q : ℝ} (hq : 0(p.1,(1-p.2)*u p.1+p.2*v p.1)) (x,t):=by + exact continuous_fst.continuousAt.prodMk + (((continuousAt_const.sub continuous_snd.continuousAt).mul (hu.comp continuous_fst.continuousAt)).add + (continuous_snd.continuousAt.mul (hv.comp continuous_fst.continuousAt))) + have hp:(x,(1-t)*u x+t*v x)∈({x}×ˢ Icc (u x) (v x)):=by + refine ⟨rfl,?_,?_⟩ + · nlinarith [mul_nonneg ht.1 (sub_nonneg.mpr huv)] + · nlinarith [mul_nonneg (sub_nonneg.mpr ht.2) (sub_nonneg.mpr huv)] + exact hc.eventually ((nhds_le_nhdsSet hp) hV) + filter_upwards [hh] with y hy hyuv s hs + obtain ⟨t,ht,rfl⟩:=real_interval_combination hyuv hs + exact hy t ht + +omit [InnerProductSpace ℝ E] [FiniteDimensional ℝ E] in +lemma locallyLipschitz_germ [InnerProductSpace ℝ E] [FiniteDimensional ℝ E] + {F Q:E→E} {x:E} (hQ:LocallyLipschitz Q) (he:F =ᶠ[𝓝 x] Q) : + ∃K:ℝ≥0,∃V∈𝓝 x,LipschitzOnWith K F V := by + obtain ⟨K,V,hV,hL⟩:=hQ x + refine ⟨K,V∩{y|F y=Q y},inter_mem hV he,?_⟩ + intro y hy z hz + rw [hy.2,hz.2] + exact hL hy.1 hz.1 + +/-- Primitive of the actual field between two graphs; no assigned derivative. -/ +def verticalPotential (F:E×ℝ→E) (u v:E→ℝ) (x:E):E:=(2:ℝ) • (∫s in u x..v x,F (x,s)) + +lemma verticalPotential_smooth_germ {F:E×ℝ→E} {u v:E→ℝ} + (hu:LocallyLipschitz u) (hv:LocallyLipschitz v) (huv:∀y,u y≤v y) {x:E} + {D:Set (E×ℝ)} (hD:IsOpen D) (hFD:ContDiffOn ℝ 1 F D) + (hK:({x}×ˢ Icc (u x) (v x))⊆D) + (_hFi:∀y a b,IntervalIntegrable (fun t:ℝ=>F (y,t)) volume a b) : + ∃K:ℝ≥0,∃V∈𝓝 x,LipschitzOnWith K (verticalPotential F u v) V := by + obtain ⟨A,hA,hAe⟩:=LocalExtension.exists_contDiff_extension + (isCompact_singleton.prod isCompact_Icc) hD hK hFD + have hn:=eventually_vertical_segment hu.continuous.continuousAt hv.continuous.continuousAt + (huv x) hAe + apply locallyLipschitz_germ (graphPotential_locallyLipschitz hA hu hv) + filter_upwards [hn] with y hy + rw [graphPotential_eq_integral hA.continuous] + unfold verticalPotential + congr 1 + apply intervalIntegral.integral_congr_Ioo_of_le (huv y) + intro s hs + exact (hy (huv y) s ⟨hs.1.le,hs.2.le⟩).symm +end Bernoulli.Foliation + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BernoulliCone/ZeroTrace.lean b/lean/OAI/Analysis/BernoulliCone/ZeroTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..b74ee09c26bb4561f0f2592002cfa64c5dbd08c5 --- /dev/null +++ b/lean/OAI/Analysis/BernoulliCone/ZeroTrace.lean @@ -0,0 +1,124 @@ +import OAI.Analysis.BernoulliCone.CompactZeroFiber + +namespace OAI + +section +noncomputable section +open Set Filter InnerProductSpace +open scoped Topology ContDiff +namespace Bernoulli.DeSilvaJerison +lemma exists_zero_upper_leaf {x:Space 7} (hq:0Zsigned x+capAmplitude*l^3*KSup x) 0:=by fun_prop + have hp:Zsigned x+capAmplitude*(0:ℝ)^3*KSup x<0:=by simpa using hz + have hn:∀ᶠ l:ℝ in 𝓝[>] 0,Zsigned x+capAmplitude*l^3*KSup x<0:= + (hc.eventually (gt_mem_nhds hp)).filter_mono nhdsWithin_le_nhds + have hqn:∀ᶠ l:ℝ in 𝓝[>] 0,l^2] 0,0‖κ • W (s⁻¹ • x)‖^2) l := by + have hc:ContinuousAt (fun s:ℝ=>s⁻¹ • x) l:= + (continuousAt_id.inv₀ hl.ne').smul continuousAt_const + have hg:ContinuousAt (fun s:ℝ=>W (s⁻¹ • x)) l:= + ContinuousAt.comp (f:=fun s:ℝ=>s⁻¹ • x) (g:=W) hW hc + exact (hg.const_smul κ).norm.pow 2 +lemma normalized_radiusSq_ge_one {x:Space 7} {l:ℝ} (hl:0] 0,‖upperFlux (x,t)‖^2<1 := by + have hU:U x=0:=by rw [U_eq_signed_pospart hq,max_eq_right hz.le,mul_zero] + obtain ⟨a,b,ha,hab,hpar⟩:=upperParameter_compact_near_zero hq hz + let Kc:Set ℝ:=Icc a b ∩ {l|Cylindrical.radiusSq axis x≤l^2} + let Ko:Set ℝ:=Icc a b ∩ {l|l^2≤Cylindrical.radiusSq axis x} + have hKc:IsCompact Kc:=isCompact_Icc.inter_right (isClosed_le continuous_const (continuous_id.pow 2)) + have hKo:IsCompact Ko:=isCompact_Icc.inter_right (isClosed_le (continuous_id.pow 2) continuous_const) + have hlc (l:ℝ)(hl:l∈Kc):0upperTrace_continuousAt x (hlc l hl) + · intro l hl + exact scaled_gradient_norm_sq_continuousAt x (hlc l hl) + (gradient_smoothCap_continuousAt (hqc l hl)) + · intro l hl he + exact (upper_free_boundary_slopes (hs0 l (hlc l hl) he)).1 (hqc l hl) + have ho:∀ᶠ t:ℝ in 𝓝 0,∀l∈Ko,upperTrace x l=t → ‖κ • gradient outerSigned (l⁻¹ • x)‖^2<1:=by + apply Foliation.eventually_near_zero_fiber hKo + · exact fun l hl=>upperTrace_continuousAt x (hlo l hl) + · intro l hl + exact scaled_gradient_norm_sq_continuousAt x (hlo l hl) + (gradient_outerSigned_continuousAt (hqo l hl)) + · intro l hl he + exact (upper_free_boundary_slopes (hs0 l (hlo l hl) he)).2 (hqo l hl) + have htn:∀ᶠ t:ℝ in 𝓝[>] 0,t<1:=(gt_mem_nhds (by norm_num : (0:ℝ)<1)).filter_mono nhdsWithin_le_nhds + filter_upwards [hc.filter_mono nhdsWithin_le_nhds,ho.filter_mono nhdsWithin_le_nhds,htn,self_mem_nhdsWithin] with t hct hot ht1 ht0 + have ht:U x B (v+s • a,q)) 0 0) : + fderiv ℝ B (v,q) (a,0) = 0 := by + have hp : HasDerivAt (fun s : ℝ => (v+s • a,q)) (a,0) 0 := by + convert! (((hasDerivAt_const (0:ℝ) v).add ((hasDerivAt_id (0:ℝ)).smul_const a)).prodMk + (hasDerivAt_const (0:ℝ) q)) using 1; simp + have hb : HasFDerivAt B (fderiv ℝ B (v,q)) (v+(0:ℝ) • a,q) := by simpa using hB.hasFDerivAt + have h := hb.comp_hasDerivAt 0 hp + exact h.unique hline + +lemma fderiv_snd_eq_of_partial {B : E×F → ℝ} {v : E} {q : F} {D : F →L[ℝ] ℝ} + (hB : DifferentiableAt ℝ B (v,q)) + (hpart : HasFDerivAt (fun y : F => B (v,y)) D q) (u : F) : + fderiv ℝ B (v,q) (0,u) = D u := by + have hp := (hasFDerivAt_const v q).prodMk (hasFDerivAt_id (𝕜 := ℝ) q) + have h := hB.hasFDerivAt.comp q hp + have heq := h.unique hpart + exact congrArg (fun A : F →L[ℝ] ℝ => A u) heq + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/CompactParameterJets.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/CompactParameterJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..428c026efdd149e8a24ad75506bcaa332d7252f2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/CompactParameterJets.lean @@ -0,0 +1,163 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ManifoldLipschitz +import OAI.Analysis.BiholderTransport.Coordinates.ChartCostJets + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {Q E : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma compact_parameter_second_jet {K : Set Q} (hK : IsCompact K) + {F : (ℝ×Q) → E → ℝ} {t : ℝ} + (hF : ∀ q∈K, ContDiffAt ℝ ∞ (Function.uncurry F) ((t,q),0)) : + ∃ B>0, ∀ᶠ s in 𝓝 t, ∀ q∈K, + ContDiffAt ℝ 2 (F (s,q)) 0 ∧ ‖fderiv ℝ (fderiv ℝ (F (s,q))) 0‖≤B := by + let H := fun z : ℝ×Q => fderiv ℝ (fderiv ℝ (F z)) 0 + have hH : ∀ q∈K, ContinuousAt H (t,q) := by + intro q hq + exact (ContDiffAt.partial_snd_fderiv_two (hF q hq)).continuousAt.comp + (x := (t,q)) (f := fun z : ℝ×Q => (z,(0:E))) + (continuousAt_id.prodMk continuousAt_const) + obtain ⟨B,hB,HB⟩ := compact_eventually_fiberwise_bound hK + (f := fun _ : Q => ()) continuous_const (g := fun _ : ℝ => ()) + (continuousAt_const (x := t)) (h := H) (fun q hq _ => hH q hq) + have HS : ∀ᶠ s in 𝓝 t, ∀ q∈K, ()=() → ContDiffAt ℝ 2 (F (s,q)) 0 := by + apply compact_eventually_fiberwise hK (f := fun _ : Q => ()) continuous_const + (g := fun _ : ℝ => ()) (continuousAt_const (x := t)) + intro q hq _ + have He := ((hF q hq).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + have hc : ContinuousAt (fun z : ℝ×Q => (z,(0:E))) (t,q) := + continuousAt_id.prodMk continuousAt_const + filter_upwards [hc.tendsto.eventually He] with z hz + exact hz.comp (0:E) (contDiffAt_const.prodMk contDiffAt_id) + refine ⟨B,hB,?_⟩ + filter_upwards [HB,HS] with s hb hs + exact fun q hq => ⟨hs q hq rfl,hb q hq rfl⟩ + +end + +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def shortLegCost (x : M) (t : ℝ) (p h : TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost (riemannianExp x (t • (p+h))) (riemannianExp x p) + +def movingShortLegCost (a : M) (z : ℝ × (Model n × Model n)) (h : Model n) : ℝ := + cost (movingNormal a (z.2.1,z.1 • (z.2.2+h))) (movingNormal a z.2) + +lemma movingShortLegCost_contDiffAt {a : M} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContDiffAt ℝ ∞ (Function.uncurry (movingShortLegCost a)) ((1,(b,p)),0) := by + let Z := (ℝ × (Model n × Model n)) × Model n + have hA : ContMDiffAt 𝓘(ℝ,Z) 𝓘(ℝ,Model n) ∞ + (fun q : Z => movingNormal a (q.1.2.1,q.1.1 • (q.1.2.2+q.2))) ((1,(b,p)),0) := by + refine (show ContMDiffAt 𝓘(ℝ,Model n × Model n) 𝓘(ℝ,Model n) ∞ + (movingNormal a) (b,(1:ℝ) • (p+0)) from by simpa using movingNormal_contMDiffAt hb).comp + (f := fun q : Z => (q.1.2.1,q.1.1 • (q.1.2.2+q.2))) ((1,(b,p)),0) ?_ + exact (contDiffAt_fst.snd.fst.prodMk + (contDiffAt_fst.fst.smul (contDiffAt_fst.snd.snd.add contDiffAt_snd))).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Z) 𝓘(ℝ,Model n) ∞ + (fun q : Z => movingNormal a q.1.2) ((1,(b,p)),0) := + (movingNormal_contMDiffAt (q := (b,p)) hb).comp ((1,(b,p)),0) + contDiffAt_fst.snd.contMDiffAt + have hC : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M × M => cost q.1 q.2) + (movingNormal a (b,(1:ℝ) • (p+0)),movingNormal a (b,p)) := by + simpa only [add_zero,one_smul,riemannianExp_zero] using + cost_contMDiffAt_of_injectivityDomain + (⟨movingNormal a (b,p),0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + (zero_mem_injectivityDomain (movingNormal a (b,p))) + exact (hC.comp ((1,(b,p)),0) (hA.prodMk hB)).contDiffAt + +lemma shortLeg_second_bound_near_base (R : ℝ) (a : M) : + ∃ C : ℝ≥0, ∃ K∈𝓝 a, ∀ᶠ t in 𝓝 (1:ℝ), ∀ x∈K, + ∀ p : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖≤R → + ContDiffAt ℝ 2 (shortLegCost x t p) 0 ∧ + ∀ k : TangentSpace 𝓘(ℝ,Model n) x, + ‖fderiv ℝ (fderiv ℝ (shortLegCost x t p)) 0 k k‖≤C*‖k‖^2 := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hBpos,hB⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + obtain ⟨K,hKn,hKs,hKc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) hB) + let χ := extChartAt 𝓘(ℝ,Model n) a + let P := (χ '' K) ×ˢ closedBall (0 : Model n) (B*R) + have hPc : IsCompact P := + (hKc.image_of_continuousOn ((continuousOn_extChartAt a).mono + (fun x hx => (hKs hx).1))).prod (isCompact_closedBall _ _) + obtain ⟨D,hDpos,HD⟩ := compact_parameter_second_jet hPc + (F := movingShortLegCost a) (t := 1) (fun q hq => movingShortLegCost_contDiffAt (by + obtain ⟨x,hx,hxq⟩ := hq.1 + rw [←hxq] + exact χ.map_source (hKs hx).1)) + refine ⟨⟨D*B^2,mul_nonneg hDpos.le (sq_nonneg B)⟩,K,hKn,?_⟩ + filter_upwards [HD] with t ht + intro x hx p hp + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x + have hpP : (χ x,A p)∈P := by + refine ⟨mem_image_of_mem χ hx,?_⟩ + rw [mem_closedBall,dist_zero_right] + exact (A.le_opNorm p).trans (mul_le_mul (hKs hx).2.le hp (norm_nonneg _) hBpos.le) + have he : shortLegCost x t p = (fun h => movingShortLegCost a (t,(χ x,A p)) (A h)) := by + funext h + dsimp only [shortLegCost,movingShortLegCost] + rw [←map_add,←map_smul,movingNormal_trivialization_exp (hKs hx).1, + movingNormal_trivialization_exp (hKs hx).1] + rw [he] + have HD' := ht (χ x,A p) hpP + refine ⟨(show ContDiffAt ℝ 2 (movingShortLegCost a (t,(χ x,A p))) (A 0) from by + simpa only [map_zero] using HD'.1).comp 0 A.contDiff.contDiffAt,?_⟩ + intro k + rw [second_fderiv_comp_linear_zero HD'.1 A k] + let H := fderiv ℝ (fderiv ℝ (movingShortLegCost a (t,(χ x,A p)))) 0 + have hAk : ‖A k‖≤B*‖k‖ := + (A.le_opNorm k).trans (mul_le_mul_of_nonneg_right (hKs hx).2.le (norm_nonneg _)) + calc + ‖H (A k) (A k)‖≤‖H (A k)‖*‖A k‖ := (H (A k)).le_opNorm _ + _≤(‖H‖*‖A k‖)*‖A k‖ := mul_le_mul_of_nonneg_right (H.le_opNorm _) (norm_nonneg _) + _≤(D*‖A k‖)*‖A k‖ := by gcongr; exact HD'.2 + _≤(D*(B*‖k‖))*(B*‖k‖) := by gcongr + _=(D*B^2)*‖k‖^2 := by ring + +lemma exists_uniform_shortLeg_second_bound (R : ℝ) : + ∃ C : ℝ≥0, ∀ᶠ t in 𝓝 (1:ℝ), ∀ x : M, + ∀ p : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖≤R → + ContDiffAt ℝ 2 (shortLegCost x t p) 0 ∧ + ∀ k : TangentSpace 𝓘(ℝ,Model n) x, + ‖fderiv ℝ (fderiv ℝ (shortLegCost x t p)) 0 k k‖≤C*‖k‖^2 := by + classical + choose C K hKn hK using shortLeg_second_bound_near_base (n := n) (M := M) R + obtain ⟨s,hs⟩ := finite_cover_nhds hKn + refine ⟨s.sup C,?_⟩ + have HT := (eventually_all_finset s).mpr (fun a _ => hK a) + filter_upwards [HT] with t ht + intro x p hp + have hx : x∈ ⋃ a∈s,K a := by rw [hs]; trivial + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp hx + have H := ht a ha x hxa p hp + refine ⟨H.1,fun k => (H.2 k).trans ?_⟩ + exact mul_le_mul_of_nonneg_right (by exact_mod_cast Finset.le_sup (f := C) ha) (sq_nonneg _) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/CompactSmoothGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/CompactSmoothGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..17d76c61cc34a86220538286a5ffb49547caffd2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/CompactSmoothGrowth.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.UniformFiniteGrowth +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Calculus.TaylorBound + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {P E : Type*} [TopologicalSpace P] [CompactSpace P] + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + {ι : Type*} [Fintype ι] [Nonempty ι] + +lemma compact_finite_smooth_transverse_growth + (f : P → ι → E → ℝ) (w : P → ι → ℝ) + (hw : ∀ a i, 0 ≤ w a i) (hsum : ∀ a, ∑ i, w a i = 1) + (hwc : ∀ i, Continuous (fun a => w a i)) + (hf : ∀ a i, ∀ᶠ q : E × P in 𝓝 (0,a), ContDiffAt ℝ 2 (f q.2 i) q.1) + (hf0 : ∀ a i, f a i 0 = 0) + (hLc : ∀ i, Continuous (fun a => fderiv ℝ (f a i) 0)) + (hBc : ∀ i, Continuous (fun a => fderiv ℝ (fderiv ℝ (f a i)) 0)) + (hD : ∀ a i, ContinuousAt (fun q : E × P => + fderiv ℝ (fderiv ℝ (f q.2 i)) q.1) (0,a)) + (hmean : ∀ a v, ∑ i, w a i * fderiv ℝ (f a i) 0 v = 0) + (hpos : ∀ a v, ‖v‖ = 1 → (∀ i, fderiv ℝ (f a i) 0 v ≤ 0) → + 0 < ∑ i, w a i * fderiv ℝ (fderiv ℝ (f a i)) 0 v v) : + ∃ b > 0, ∀ᶠ h : E in 𝓝 0, ∀ a : P, ∃ i, b * ‖h‖^2 ≤ f a i h := by + let L := fun a i => fderiv ℝ (f a i) 0 + let B := fun a i => (1/2 : ℝ) • fderiv ℝ (fderiv ℝ (f a i)) 0 + have hB : ∀ i, Continuous (fun a => B a i) := + fun i => (continuous_const : Continuous (fun _ : P => (1/2 : ℝ))).smul (hBc i) + have hpos' : ∀ a v, ‖v‖ = 1 → (∀ i, L a i v ≤ 0) → + 0 < ∑ i, w a i * B a i v v := by + intro a v hv hl + have he : (∑ i, w a i * B a i v v) = (1/2:ℝ) * + ∑ i, w a i * fderiv ℝ (fderiv ℝ (f a i)) 0 v v := by + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + simp only [B,_root_.smul_apply,smul_eq_mul] + ring + rw [he] + exact mul_pos (by norm_num) (hpos a v hv hl) + obtain ⟨b,hb,H⟩ := uniform_finite_transverse_quadratic_growth w L B hw hsum hmean + hwc hLc hB hpos' + have HT : ∀ᶠ h : E in 𝓝 0, ∀ i, ∀ a : P, + |f a i h - L a i h - B a i h h| ≤ (b/2) * ‖h‖^2 := by + apply Filter.eventually_all.mpr + intro i + have hi := compact_parametric_second_order_remainder (fun a => f a i) + (fun a => hf a i) (fun a => hD a i) (half_pos hb) + filter_upwards [hi] with h hh + intro a + simpa only [hf0,sub_zero,L,B,_root_.smul_apply,smul_eq_mul,one_div,div_eq_mul_inv, + one_mul,mul_comm] using hh a + refine ⟨b/2,half_pos hb,?_⟩ + filter_upwards [H,HT] with h hh ht + intro a + obtain ⟨i,hi⟩ := hh a + have he := (abs_le.mp (ht i a)).1 + exact ⟨i,by nlinarith⟩ + +end + +open Set Filter +open scoped Topology ContDiff + +lemma compact_smooth_data_transverse_growth + {P Q E : Type*} [TopologicalSpace P] [CompactSpace P] + [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + {ι : Type*} [Fintype ι] [Nonempty ι] + (F : Q → ι → E → ℝ) (d : P → Q) (hd : Continuous d) (w : P → ι → ℝ) + (hw : ∀ a i, 0 ≤ w a i) (hsum : ∀ a, ∑ i, w a i = 1) + (hwc : ∀ i, Continuous (fun a => w a i)) + (hf : ∀ a i, ContDiffAt ℝ ∞ (fun q : Q × E => F q.1 i q.2) (d a,0)) + (hf0 : ∀ a i, F (d a) i 0 = 0) + (hmean : ∀ a v, ∑ i, w a i * fderiv ℝ (F (d a) i) 0 v = 0) + (hpos : ∀ a v, ‖v‖ = 1 → (∀ i, fderiv ℝ (F (d a) i) 0 v ≤ 0) → + 0 < ∑ i, w a i * fderiv ℝ (fderiv ℝ (F (d a) i)) 0 v v) : + ∃ b > 0, ∀ᶠ h : E in 𝓝 0, ∀ a : P, ∃ i, b * ‖h‖^2 ≤ F (d a) i h := by + have hc : Continuous (fun q : E × P => (d q.2,q.1)) := + (hd.comp continuous_snd).prodMk continuous_fst + have hF : ∀ a i, ∀ᶠ q : E × P in 𝓝 (0,a), ContDiffAt ℝ 2 (F (d q.2) i) q.1 := by + intro a i + have H := ((hf a i).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + filter_upwards [hc.continuousAt.tendsto.eventually H] with q hq + exact hq.comp q.1 (contDiffAt_const.prodMk contDiffAt_id) + have hD : ∀ a i, ContinuousAt (fun q : E × P => + fderiv ℝ (fderiv ℝ (F (d q.2) i)) q.1) (0,a) := by + intro a i + exact (ContDiffAt.partial_snd_fderiv_two (f := fun q => F q i) (hf a i)).continuousAt.comp + (x := (0,a)) (f := fun q : E × P => (d q.2,q.1)) hc.continuousAt + apply compact_finite_smooth_transverse_growth (fun a => F (d a)) w hw hsum hwc hF hf0 + · intro i + apply continuous_iff_continuousAt.mpr + intro a + exact (ContDiffAt.partial_snd_fderiv (f := fun q => F q i) (hf a i)).continuousAt.comp + (x := a) (f := fun a => (d a,(0:E))) (hd.continuousAt.prodMk continuousAt_const) + · intro i + apply continuous_iff_continuousAt.mpr + intro a + exact (hD a i).comp (x := a) (f := fun a => ((0:E),a)) + (continuousAt_const.prodMk continuousAt_id) + · exact hD + · exact hmean + · exact hpos + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/DerivativeNegLowerCrossing.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/DerivativeNegLowerCrossing.lean new file mode 100644 index 0000000000000000000000000000000000000000..401c41322507507ae55ff0d0263b471c11a837d8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/DerivativeNegLowerCrossing.lean @@ -0,0 +1,29 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma derivative_neg_of_lower_crossing {f : ℝ → ℝ} {d a c : ℝ} + (hd : HasDerivAt f d 1) (ha : a < 1) (hc : 0 < c) + (hf : ∀ᶠ t in 𝓝 (1:ℝ), a < t → t < 1 → c*(1-t) ≤ f t-f 1) : 0 < -d := by + have Hsl : Tendsto (slope f 1) (𝓝[<] (1:ℝ)) (𝓝 d) := + hd.tendsto_slope.mono_left (nhdsLT_le_nhdsNE 1) + have Hle : ∀ᶠ t in 𝓝[<] (1:ℝ), slope f 1 t ≤ -c := by + filter_upwards [hf.filter_mono nhdsWithin_le_nhds, + (eventually_gt_nhds ha).filter_mono nhdsWithin_le_nhds,self_mem_nhdsWithin] with t ht hat ht1 + have H := ht hat ht1 + rw [slope_def_field] + exact (div_le_iff_of_neg (sub_neg.mpr ht1)).mpr (by nlinarith only [H]) + have H := le_of_tendsto Hsl Hle + linarith only [H,hc] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ExactScalarBounds.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ExactScalarBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..5a71e2ab040aa67b5660c16f958388034b69a51f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ExactScalarBounds.lean @@ -0,0 +1,141 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OuterVelocityFactorNonneg +import OAI.Analysis.BiholderTransport.CostGeometry.ExactTemplateCurvature +import OAI.Analysis.BiholderTransport.Calculus.ModifiedScalarDerivatives + +namespace OAI + +noncomputable section +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma modifiedScalar_slope_bounds {B:ℝ → ℝ} (hB:ContDiff ℝ ∞ B) + {C D b:ℝ} (hC:0 ≤ C) (hD:0 < D) (hb:0 ≤ b) (hbd:b/D*C ≤ 1/2) + (hder:∀s,|deriv B s|≤C) (a s:ℝ) : + (1:ℝ)/2 ≤ deriv (fun x=>modifiedScalar a D B (b,x)) s ∧ + deriv (fun x=>modifiedScalar a D B (b,x)) s ≤ 3/2 := by + rw [modifiedScalar_deriv hB] + have H:=abs_le.mp (hder ((s-a)/D)) + have p:=mul_le_mul_of_nonneg_left H.1 (div_nonneg hb hD.le) + have q:=mul_le_mul H.2 le_rfl (div_nonneg hb hD.le) hC + constructor <;> nlinarith only [p,q,hbd] + +lemma modifiedScalar_strictMono {B:ℝ → ℝ} (hB:ContDiff ℝ ∞ B) + {C D b:ℝ} (hC:0 ≤ C) (hD:0 < D) (hb:0 ≤ b) (hbd:b/D*C ≤ 1/2) + (hder:∀s,|deriv B s|≤C) (a:ℝ) : + StrictMono (fun x=>modifiedScalar a D B (b,x)) := by + apply strictMono_of_deriv_pos + intro s + exact lt_of_lt_of_le (by norm_num) (modifiedScalar_slope_bounds hB hC hD hb hbd hder a s).1 + +lemma exact_center_slope_curvature {a D b s:ℝ} (hD:0 < D) (hb:0 < b) + (hsmall:b/D*centerGamma ≤ 1) (hs:0 < centerTemplate ((s-a)/D)) : + let l:=deriv (fun x=>modifiedScalar a D centerTemplate (b,x)) s + let k:=iteratedDeriv 2 (fun x=>modifiedScalar a D centerTemplate (b,x)) s + (1:ℝ)/2 ≤ l ∧ l<1 ∧ k<0 ∧ + -k/l^2 ≤ 2*centerGamma^2*b/D^2 ∧ + -k/l^2 ≤ 4*centerGamma*(1-l)/D := by + dsimp only + rw [modifiedScalar_deriv centerTemplate_smooth,modifiedScalar_second centerTemplate_smooth] + let u:=deriv centerTemplate ((s-a)/D) + let v:=iteratedDeriv 2 centerTemplate ((s-a)/D) + have hu:=centerTemplate_deriv_neg ((s-a)/D) + obtain ⟨hv,hv1,hv2⟩:=centerTemplate_curvature hs + have hu2:=(centerTemplate_deriv_bound ((s-a)/D)).2 + have hp:0 < b/D:=div_pos hb hD + have hp2:0 < b/D^2:=div_pos hb (sq_pos_of_pos hD) + have hl:(1:ℝ)/2 ≤ 1+b/D*u:=by + have H:=mul_le_mul_of_nonneg_left hu2 hp.le + dsimp only [u] + nlinarith only [H,hsmall] + have hl2:1/4 ≤ (1+b/D*u)^2:=by nlinarith only [hl,sq_nonneg (1+b/D*u-1/2)] + have hl0:0 < (1+b/D*u)^2:=lt_of_lt_of_le (by norm_num) hl2 + have hk0:0 ≤ -(b/D^2*v):=by dsimp [v]; exact neg_nonneg.mpr (mul_neg_of_pos_of_neg hp2 hv).le + refine ⟨hl,?_,mul_neg_of_pos_of_neg hp2 hv,?_,?_⟩ + · have H:=mul_neg_of_pos_of_neg hp hu + dsimp only [u] at hl ⊢ + linarith only [H] + · apply (div_le_iff₀ hl0).mpr + have H:=mul_le_mul_of_nonneg_left hv2 hp2.le + have Q:=mul_le_mul_of_nonneg_left hl2 (show 0 ≤ 2*centerGamma^2*b/D^2 by positivity) + have he : 2*centerGamma^2*b/D^2*(1/4)=b/D^2*(centerGamma^2/2) := by ring + rw [he] at Q + dsimp only [u] at Q ⊢ + linarith only [H,Q] + · apply (div_le_iff₀ hl0).mpr + have H:=mul_le_mul_of_nonneg_left hv1 hp2.le + have Q:=mul_le_mul_of_nonneg_left hl2 + (show 0 ≤ 4*centerGamma*(1-(1+b/D*u))/D by + have ht:0 ≤ 1-(1+b/D*u):=by + have H:=mul_neg_of_pos_of_neg hp hu + dsimp only [u] + linarith only [H] + exact div_nonneg (mul_nonneg (mul_nonneg (by norm_num) centerGamma_pos.le) ht) hD.le) + have he:4*centerGamma*(1-(1+b/D*u))/D*(1/4)=b/D^2*(centerGamma*(-u)):=by + field_simp + ring + rw [he] at Q + dsimp only [u] at Q ⊢ + linarith only [H,Q] + +lemma exact_outer_slope_curvature {M K eta a D b s C:ℝ} + (hM:2 ≤ M) (hK:1 ≤ K) (heta:0 < eta) (hD:0 < D) (hb:0 < b) + (hC:0 ≤ C) (hder:∀t,|deriv (outerTemplate M K eta) t|≤C) (hsmall:b/D*C ≤ 1/2) + (hs:-2*eta ≤ (s-a)/D) (hs':(s-a)/D ≤ 1-eta) + (hcap:outerTemplate M K eta ((s-a)/D) ≤ M) : + let l:=deriv (fun x=>modifiedScalar a D (outerTemplate M K eta) (b,x)) s + let k:=iteratedDeriv 2 (fun x=>modifiedScalar a D (outerTemplate M K eta) (b,x)) s + 1 < l ∧ l ≤ 2 ∧ k < 0 ∧ K*b/(4*D^2) ≤ -k/l^2 := by + dsimp only + have hupper:=(modifiedScalar_slope_bounds (outerTemplate_smooth M K eta) hC hD hb.le hsmall hder a s).2 + rw [modifiedScalar_deriv (outerTemplate_smooth M K eta)] at hupper ⊢ + rw [modifiedScalar_second (outerTemplate_smooth M K eta)] + obtain ⟨hd,hdd⟩:=exact_outer_curvature hK hM heta hs hs' hcap + let l:=1+b/D*deriv (outerTemplate M K eta) ((s-a)/D) + have hlo:1(e (b,v)).2 + let g:=fun w:F=>(e.symm (b,w)).2 + (fun v=>g (f v)) =ᶠ[𝓝 p] id ∧ (fun w=>f (g w)) =ᶠ[𝓝 (f p)] id := by + dsimp only + have hf0:e (b,p)=(b,(e (b,p)).2) := Prod.ext (he _) rfl + constructor + · have H:∀ᶠ v in 𝓝 p,(b,v)∈e.source := + (continuous_const.prodMk continuous_id).continuousAt.preimage_mem_nhds (e.open_source.mem_nhds hq) + filter_upwards [H] with v hv + have Hinv:=e.left_inv hv + have Hpair:e (b,v)=(b,(e (b,v)).2) := Prod.ext (he _) rfl + calc + _ = (e.symm (e (b,v))).2 := congrArg (fun q=>(e.symm q).2) Hpair.symm + _ = v := congrArg Prod.snd Hinv + · have ht:(b,(e (b,p)).2)∈e.target := hf0 ▸ e.map_source hq + have H:∀ᶠ w in 𝓝 ((e (b,p)).2),(b,w)∈e.target := + (continuous_const.prodMk continuous_id).continuousAt.preimage_mem_nhds (e.open_target.mem_nhds ht) + filter_upwards [H] with w hw + have Hinv:=e.right_inv hw + have Hfirst:(e.symm (b,w)).1=b := by + rw [←he (e.symm (b,w)),Hinv] + have Hpair:e.symm (b,w)=(b,(e.symm (b,w)).2) := Prod.ext Hfirst rfl + calc + _ = (e (e.symm (b,w))).2 := congrArg (fun q=>(e q).2) Hpair.symm + _ = w := congrArg Prod.snd Hinv + +lemma fiber_jet_bound + (e:OpenPartialHomeomorph (E×F) (E×F)) (he:∀q,(e q).1=q.1) + {b:E} {p:F} (hq:(b,p)∈e.source) + (hf:DifferentiableAt ℝ e (b,p)) (hg:DifferentiableAt ℝ e.symm (e (b,p))) + {v:F → ℝ} {B:F →L[ℝ] F →L[ℝ] ℝ} + (hjet:HasLowerSecondTaylor (fun d=>v ((e (b,p+d)).2)) 0 B) + (hB:∀d,0 ≤ B d d) {C:ℝ} (hC:0 ≤ C) + (hbound:∀ H:F →L[ℝ] F →L[ℝ] ℝ,(∀d,0 ≤ H d d) → + HasLowerSecondTaylor (fun w=>v ((e (b,p)).2+w)) 0 H → ∀d,H d d ≤ C*‖d‖^2) : + ∀d,B d d ≤ C*‖fderiv ℝ e (b,p)‖^2*‖d‖^2 := by + let f:=fun v:F=>(e (b,v)).2 + let g:=fun w:F=>(e.symm (b,w)).2 + let T:=fderiv ℝ e (b,p) + let A:F →L[ℝ] F := (ContinuousLinearMap.snd ℝ E F).comp + (T.comp (ContinuousLinearMap.inr ℝ E F)) + have hsection:HasFDerivAt (fun v:F=>(b,v)) (ContinuousLinearMap.inr ℝ E F) p := by + have hi:ContinuousLinearMap.inr ℝ E F=(0: F →L[ℝ] E).prod (ContinuousLinearMap.id ℝ F) := by + ext d <;> rfl + rw [hi] + exact (hasFDerivAt_const b p).prodMk (hasFDerivAt_id p) + have hAf:HasFDerivAt f A p := (hf.hasFDerivAt.comp p hsection).snd + have hG:DifferentiableAt ℝ g (f p) := by + have heq:(b,f p)=e (b,p) := by + apply Prod.ext + · exact (he (b,p)).symm + · rfl + have hg':DifferentiableAt ℝ e.symm (b,f p) := heq.symm ▸ hg + exact (hg'.comp _ ((differentiableAt_const b).prodMk differentiableAt_id)).snd + obtain ⟨hgf,hfg⟩:=fiber_local_inverse e he hq + have H:=lower_jet_diffeomorphism_bound hAf hG.hasFDerivAt hgf hfg hjet hB hC hbound + have hnorm:‖A‖ ≤ ‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro d + change ‖(T (0,d)).2‖ ≤ ‖T‖*‖d‖ + calc + _ ≤ ‖T (0,d)‖ := norm_snd_le _ + _ ≤ ‖T‖*‖(0,d)‖ := T.le_opNorm _ + _ = ‖T‖*‖d‖ := by simp + intro d + exact (H d).trans (by gcongr) + +lemma exists_uniform_fiber_jet_transfer + (e:OpenPartialHomeomorph (E×F) (E×F)) (he:∀q,(e q).1=q.1) + (hf:ContDiffOn ℝ ∞ e e.source) (hg:ContDiffOn ℝ ∞ e.symm e.target) + {q:E×F} (hq:q∈e.source) : + ∃ U:Set (E×F),U∈𝓝 q ∧ U⊆e.source ∧ ∃ K≥0, + ∀z∈U,∀v:F → ℝ,∀B:F →L[ℝ] F →L[ℝ] ℝ, + HasLowerSecondTaylor (fun d=>v ((e (z.1,z.2+d)).2)) 0 B → + (∀d,0 ≤ B d d) → ∀C:ℝ,0 ≤ C → + (∀ H:F →L[ℝ] F →L[ℝ] ℝ,(∀d,0 ≤ H d d) → + HasLowerSecondTaylor (fun w=>v ((e z).2+w)) 0 H → ∀d,H d d ≤ C*‖d‖^2) → + ∀d,B d d ≤ C*K*‖d‖^2 := by + let R:=‖fderiv ℝ e q‖+1 + let U:=e.source ∩ {z|‖fderiv ℝ e z‖0, ∀ᶠ h : E in 𝓝 0, ∃ i, b*‖h‖^2≤f i h := by + let L := fun i => fderiv ℝ (f i) 0 + let B := fun i => (1/2:ℝ) • fderiv ℝ (fderiv ℝ (f i)) 0 + have hBpos : ∀ v : E, v≠0 → (∀ i, L i v=0) → 0<∑ i, w i*B i v v := by + intro v hv hl + have heq : (∑ i, w i*B i v v)=(1/2:ℝ)*(∑ i, w i*fderiv ℝ (fderiv ℝ (f i)) 0 v v) := by + simp only [B,smul_apply,smul_eq_mul,Finset.mul_sum] + congr 1 + ext i + ring + rw [heq] + exact mul_pos (by norm_num) (hpos v hv hl) + obtain ⟨b,hb,hgrowth⟩ := finite_transverse_quadratic_growth L B w hw hsum hmean hBpos + have hrem : ∀ᶠ h : E in 𝓝 0, ∀ i, + |f i h-L i h-B i h h|≤(b/2)*‖h‖^2 := by + rw [Filter.eventually_all] + intro i + have H := (contDiffAt_second_order_remainder (hf i)).bound (half_pos hb) + simpa only [hf0,L,B,smul_apply,smul_eq_mul,div_eq_mul_inv,one_mul,mul_comm, + sub_zero,Real.norm_eq_abs,norm_pow,Real.norm_of_nonneg (norm_nonneg _)] using H + refine ⟨b/2,half_pos hb,?_⟩ + filter_upwards [hgrowth,hrem] with h hh hr + obtain ⟨i,hi⟩ := hh + exact ⟨i,by linarith [(abs_le.mp (hr i)).1]⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/FiniteTaylor.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/FiniteTaylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..39a156f587e1d897639f50f67c7c6a593895ec61 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/FiniteTaylor.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LowerTaylor +import OAI.Analysis.BiholderTransport.LinearAlgebra.SplitEndpointJets +import OAI.Analysis.BiholderTransport.LinearAlgebra.PrefixActionJets + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma HasSecondTaylor.const_mul' {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) (c:ℝ) : + HasSecondTaylor (fun h => c*f h) (c • l) (c • B) := by + unfold HasSecondTaylor at * + have he : (fun h => c*f h-c*f 0-(c • l) h-(c • B) h h/2) = + (fun h => c*(f h-f 0-l h-B h h/2)) := by + funext h; simp only [smul_apply,smul_eq_mul]; ring + rw [he] + exact hf.const_mul_left c + +lemma HasSecondTaylor.sum {ι : Type*} (s : Finset ι) {f : ι → E → ℝ} + {l : ι → E →L[ℝ] ℝ} {B : ι → E →L[ℝ] E →L[ℝ] ℝ} + (hf : ∀ i∈s, HasSecondTaylor (f i) (l i) (B i)) : + HasSecondTaylor (fun h => ∑ i∈s, f i h) (∑ i∈s, l i) (∑ i∈s, B i) := by + classical + induction s using Finset.induction_on with + | empty => + simp only [Finset.sum_empty] + simp only [HasSecondTaylor,sub_self,zero_apply,zero_div] + exact Asymptotics.isLittleO_zero _ _ + | @insert i s hi IH => + simp only [Finset.sum_insert hi] + exact (hf i (Finset.mem_insert_self _ _)).add + (IH (fun j hj => hf j (Finset.mem_insert_of_mem hj))) + +lemma HasLowerSecondTaylor.mono_diagonal {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B C : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasLowerSecondTaylor f l B) + (hBC : ∀ h:E, C h h≤B h h) : HasLowerSecondTaylor f l C := by + intro ε hε + filter_upwards [hf ε hε] with h hh + have H := hBC h + linarith + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def prefixDefect (x : M) (t : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) + (h : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + prefixAction x t (h.1,p+h.2)-t*(‖p+h.2‖^2/2) + +def splitDefect (x : M) (s : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) + (h : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + splitEndpointCost x s (h.1,p+h.2)-‖p+h.2‖^2/2 + +lemma prefixDefect_taylor {x : M} {t : ℝ} (ht : t≠0) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : t • p∈injectivityDomain x) : + ∃ B : (TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] + (TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ, + HasSecondTaylor (prefixDefect x t p) + ((-innerSL ℝ p).comp (ContinuousLinearMap.fst ℝ _ _)) B ∧ + ∀ a d : TangentSpace 𝓘(ℝ,Model n) x, + B (a,d) (a,d)=hessianValue x (t • p) a/t-2*inner ℝ a d := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let P : V×V →L[ℝ] V := ContinuousLinearMap.snd ℝ V V + let H : V×V →L[ℝ] V×V →L[ℝ] ℝ := fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) + let D : V×V →L[ℝ] V×V →L[ℝ] ℝ := H-t • pullBilinear (innerSL ℝ) P + have hC := (prefixAction_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have HN : HasSecondTaylor (fun h:V×V => t*(‖p+P h‖^2/2)) + (t • ((innerSL ℝ p).comp P)) (t • pullBilinear (innerSL ℝ) P) := + ((norm_square_hasSecondTaylor p).comp_linear P).const_mul' t + have HT := (hasSecondTaylor_shift hC).sub HN + have hlin : fderiv ℝ (prefixAction x t) (0,p)-t • ((innerSL ℝ p).comp P)= + (-innerSL ℝ p).comp (ContinuousLinearMap.fst ℝ V V) := by + apply ContinuousLinearMap.ext + rintro ⟨a,d⟩ + change fderiv ℝ (prefixAction x t) (0,p) (a,d)-t*inner ℝ p d = -inner ℝ p a + rw [show (a,d)=((a,0):V×V)+(0,d) by simp,map_add, + prefixAction_source_gradient ht hp,prefixAction_endpoint_gradient hp] + ring + rw [hlin] at HT + refine ⟨D,?_,?_⟩ + · convert! HT using 1 + funext h + rcases h with ⟨a,d⟩ + simp only [prefixDefect,Prod.mk_add_mk,zero_add,P,ContinuousLinearMap.coe_snd'] + · intro a d + change fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) (a,d) (a,d)-t*inner ℝ d d=_ + rw [prefixAction_hessian_diag ht hp,real_inner_self_eq_norm_sq] + ring + +lemma splitDefect_taylor {x : M} {s : ℝ} (hs : 0 f h-f 0-l h-B h h/2) =o[𝓝 0] (fun h : E => ‖h‖^2) + +lemma HasSecondTaylor.eventually {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) {ε : ℝ} (hε : 0<ε) : + ∀ᶠ h in 𝓝 (0:E), |f h-f 0-l h-B h h/2|≤ε*‖h‖^2 := by + simpa only [Real.norm_eq_abs,abs_pow,abs_norm] using hf.def hε + +lemma hasSecondTaylor_of_contDiffAt {f : E → ℝ} (hf : ContDiffAt ℝ 2 f 0) : + HasSecondTaylor f (fderiv ℝ f 0) (fderiv ℝ (fderiv ℝ f) 0) := by + apply Asymptotics.IsLittleO.of_bound + intro ε hε + have hn := hf.eventually (by norm_num) + have hD := ((hf.fderiv_right (m := 1) (by norm_num)).fderiv_right + (m := 0) (by norm_num)).continuousAt + have he : ∀ᶠ z : E in 𝓝 0, + ‖fderiv ℝ (fderiv ℝ f) z-fderiv ℝ (fderiv ℝ f) 0‖<ε := by + exact Metric.tendsto_nhds.mp hD ε hε |>.mono (fun _ h => by simpa only [dist_eq_norm] using h) + obtain ⟨r,hr,hball⟩ := Metric.eventually_nhds_iff.mp (hn.and he) + filter_upwards [Metric.ball_mem_nhds (0:E) hr] with h hh + have H := second_order_remainder_bound_on_ball hr hε.le + (fun z hz => (hball hz).1) (fun z hz => (hball hz).2.le) hh + simpa only [Real.norm_eq_abs,abs_pow,abs_norm] using H + +lemma bilinear_isBigO_norm_mul {α : Type*} (L : Filter α) + (B : E →L[ℝ] F →L[ℝ] G) (u : α → E) (v : α → F) : + (fun x => B (u x) (v x)) =O[L] (fun x => ‖u x‖*‖v x‖) := by + apply Asymptotics.IsBigO.of_bound ‖B‖ + exact Filter.Eventually.of_forall (fun x => by + simpa only [Real.norm_eq_abs,abs_of_nonneg (mul_nonneg (norm_nonneg _) (norm_nonneg _)), + mul_assoc] using B.le_opNorm₂ (u x) (v x)) + +lemma bilinear_remainder_of_hasFDerivAt {a : E → F} {A : E →L[ℝ] F} + (ha : HasFDerivAt a A 0) (ha0 : a 0=0) (B : F →L[ℝ] F →L[ℝ] ℝ) : + (fun h => B (a h) (a h)-B (A h) (A h)) =o[𝓝 0] (fun h : E => ‖h‖^2) := by + have hR : (fun h => a h-A h) =o[𝓝 0] (fun h : E => h) := by + simpa only [zero_add,ha0,sub_zero] using hasFDerivAt_iff_isLittleO_nhds_zero.mp ha + have hO : a =O[𝓝 0] (fun h : E => h) := by + simpa only [ha0,sub_zero] using ha.isBigO_sub + have hA : (fun h : E => A h) =O[𝓝 0] (fun h => h) := A.isBigO_id _ + have h1 := (bilinear_isBigO_norm_mul (𝓝 (0:E)) B (fun h => a h-A h) a).trans_isLittleO + (hR.norm_left.norm_right.mul_isBigO hO.norm_left.norm_right) + have h2 := (bilinear_isBigO_norm_mul (𝓝 (0:E)) B (fun h => A h) (fun h => a h-A h)).trans_isLittleO + (hA.norm_left.norm_right.mul_isLittleO hR.norm_left.norm_right) + have he : (fun h => B (a h) (a h)-B (A h) (A h)) = + (fun h => B (a h-A h) (a h)+B (A h) (a h-A h)) := by + funext h + simp only [map_sub,_root_.sub_apply] + ring + rw [he] + simpa only [pow_two] using h1.add h2 + +lemma HasSecondTaylor.comp_stationary {f : F → ℝ} + {B : F →L[ℝ] F →L[ℝ] ℝ} (hf : HasSecondTaylor f 0 B) + {a : E → F} {A : E →L[ℝ] F} (ha : HasFDerivAt a A 0) (ha0 : a 0=0) : + HasSecondTaylor (fun h => f (a h)) 0 + (((ContinuousLinearMap.compL ℝ E F ℝ).flip A).comp (B.comp A)) := by + have hO : (fun h : E => ‖a h‖) =O[𝓝 0] (fun h => ‖h‖) := by + simpa only [ha0,sub_zero] using ha.isBigO_sub.norm_left.norm_right + have ht : Tendsto a (𝓝 0) (𝓝 0) := ha0 ▸ ha.continuousAt + have h1 := (hf.comp_tendsto ht).trans_isBigO (hO.pow 2) + have h2 : (fun h => (B (a h) (a h)-B (A h) (A h))/2) =o[𝓝 0] + (fun h : E => ‖h‖^2) := by + simpa only [div_eq_mul_inv,mul_comm] using + (bilinear_remainder_of_hasFDerivAt ha ha0 B).const_mul_left (2:ℝ)⁻¹ + unfold HasSecondTaylor + have he : (fun h => f (a h)-f (a 0)-(0 : E →L[ℝ] ℝ) h- + (((ContinuousLinearMap.compL ℝ E F ℝ).flip A).comp (B.comp A)) h h/2) = + (fun h => (f (a h)-f 0-(0 : F →L[ℝ] ℝ) (a h)-B (a h) (a h)/2)+ + (B (a h) (a h)-B (A h) (A h))/2) := by + funext h + simp only [ha0,_root_.zero_apply,sub_zero,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.compL_apply,ContinuousLinearMap.flip_apply] + ring + rw [he] + exact h1.add h2 + +lemma HasSecondTaylor.sub {f g : E → ℝ} {l k : E →L[ℝ] ℝ} + {B C : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) + (hg : HasSecondTaylor g k C) : HasSecondTaylor (fun h => f h-g h) (l-k) (B-C) := by + unfold HasSecondTaylor at * + have he : (fun h => (f h-g h)-(f 0-g 0)-(l-k) h-(B-C) h h/2) = + (fun h => (f h-f 0-l h-B h h/2)-(g h-g 0-k h-C h h/2)) := by + funext h + simp only [_root_.sub_apply] + ring + rw [he] + exact Asymptotics.IsLittleO.sub hf hg + +lemma HasSecondTaylor.add {f g : E → ℝ} {l k : E →L[ℝ] ℝ} + {B C : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) + (hg : HasSecondTaylor g k C) : HasSecondTaylor (fun h => f h+g h) (l+k) (B+C) := by + unfold HasSecondTaylor at * + have he : (fun h => (f h+g h)-(f 0+g 0)-(l+k) h-(B+C) h h/2) = + (fun h => (f h-f 0-l h-B h h/2)+(g h-g 0-k h-C h h/2)) := by + funext h + simp only [_root_.add_apply] + ring + rw [he] + exact Asymptotics.IsLittleO.add hf hg + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/Gradient.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/Gradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..ccc2f4a7b1ab5d41d25ad51528f7e0a2321258ed --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/Gradient.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +lemma twist_hasFDerivWithinAt + {B : E×E → ℝ} {q g : E → E} {p : E} {S A : E →L[ℝ] E} {s : Set E} + (hB : ContDiffAt ℝ 2 B (0,p)) + (hxx : ∀ u v : E, fderiv ℝ (fderiv ℝ B) (0,p) (u,0) (v,0)=inner ℝ (S u) v) + (hqx : ∀ u v : E, fderiv ℝ (fderiv ℝ B) (0,p) (0,u) (v,0)= -inner ℝ u v) + (hq0 : q 0=p) (hqc : ContinuousAt q 0) (hg : HasFDerivWithinAt g A s 0) + (hcontact : ∀ᶠ x in 𝓝[s] 0, (fderiv ℝ B (x,q x)).comp + (ContinuousLinearMap.inl ℝ E E)= -(innerSL ℝ (g x))) + (hcontact0 : (fderiv ℝ B (0,p)).comp + (ContinuousLinearMap.inl ℝ E E)= -(innerSL ℝ (g 0))) : + HasFDerivWithinAt q (S+A) s 0 := by + let J : (E →L[ℝ] ℝ) →L[ℝ] E := + (InnerProductSpace.toDual ℝ E).symm.toContinuousLinearEquiv.toContinuousLinearMap + let D : E×E → (E →L[ℝ] ℝ) := fun z => + (fderiv ℝ B z).comp (ContinuousLinearMap.inl ℝ E E) + let H : E×E → E×E := fun z => (z.1,-J (D z)) + let L : E×E →L[ℝ] E×E := + (ContinuousLinearMap.fst ℝ E E).prod + (ContinuousLinearMap.snd ℝ E E-S.comp (ContinuousLinearMap.fst ℝ E E)) + let R : E×E →L[ℝ] E×E := + (ContinuousLinearMap.fst ℝ E E).prod + (ContinuousLinearMap.snd ℝ E E+S.comp (ContinuousLinearMap.fst ℝ E E)) + have hRL : Function.LeftInverse R L := by + intro z + change (z.1,z.2-S z.1+S z.1)=z + simp + have hLR : Function.RightInverse R L := by + intro z + change (z.1,z.2+S z.1-S z.1)=z + simp + let e : (E×E) ≃L[ℝ] (E×E) := ContinuousLinearEquiv.equivOfInverse L R hRL hLR + have hDc : ContDiffAt ℝ 1 D (0,p) := + (hB.fderiv_right (m := 1) (by norm_num)).clm_comp contDiffAt_const + have hHc : ContDiffAt ℝ 1 H (0,p) := contDiffAt_fst.prodMk + (J.contDiff.contDiffAt.comp (0,p) hDc).neg + have hDd := ((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.clm_comp + (hasFDerivAt_const (ContinuousLinearMap.inl ℝ E E) (0,p)) + have hHd := (hasFDerivAt_fst (p := (0,p))).prodMk + (((J.hasFDerivAt).comp (0,p) hDd).neg) + have hHD : HasFDerivAt H (e : (E×E) →L[ℝ] (E×E)) (0,p) := by + apply hHd.congr_fderiv + apply ContinuousLinearMap.ext + intro z + apply Prod.ext + · rfl + · apply (InnerProductSpace.toDual ℝ E).injective + change (InnerProductSpace.toDual ℝ E) (-J _) = _ + rw [map_neg,show ∀ ξ : E →L[ℝ] ℝ, (InnerProductSpace.toDual ℝ E) (J ξ)=ξ from + fun ξ => (InnerProductSpace.toDual ℝ E).apply_symm_apply ξ] + ext v + change -((fderiv ℝ B (0,p)) (0,0)+fderiv ℝ (fderiv ℝ B) (0,p) z (v,0)) = + inner ℝ (z.2-S z.1) v + rw [show ((0:E),(0:E))=(0:E×E) by rfl,map_zero,zero_add] + rw [show z=(z.1,0)+(0,z.2) by ext <;> simp,map_add,add_apply,hxx,hqx] + simp only [inner_sub_left,Prod.fst_add,Prod.snd_add,add_zero,zero_add] + ring + have hstrict := hHc.hasStrictFDerivAt' hHD (by norm_num) + have J_inner (a : E) : J (innerSL ℝ a)=a := by + apply (InnerProductSpace.toDual ℝ E).injective + rw [show (InnerProductSpace.toDual ℝ E) (J (innerSL ℝ a))=innerSL ℝ a from + (InnerProductSpace.toDual ℝ E).apply_symm_apply _] + rfl + have hH0 : H (0,p)=(0,g 0) := by + change (0,-J ((fderiv ℝ B (0,p)).comp (ContinuousLinearMap.inl ℝ E E)))=(0,g 0) + rw [hcontact0,map_neg,J_inner,neg_neg] + let inv := hstrict.localInverse H e (0,p) + have hi : HasFDerivAt inv (e.symm : (E×E) →L[ℝ] (E×E)) (0,g 0) := by + rw [←hH0] + exact hstrict.to_localInverse.hasFDerivAt + have hcomp := hi.comp_hasFDerivWithinAt 0 ((hasFDerivAt_id (𝕜 := ℝ) (0:E)).hasFDerivWithinAt.prodMk hg) + have hfinal := (hasFDerivAt_snd (p := inv (0,g 0))).comp_hasFDerivWithinAt 0 hcomp + have heq : ∀ᶠ x in 𝓝[s] 0, q x=(inv (x,g x)).2 := by + have hnear := (continuousAt_id.prodMk hqc).tendsto.eventually + (by rw [hq0]; exact hstrict.eventually_left_inverse) + filter_upwards [hcontact,mem_nhdsWithin_of_mem_nhds hnear] with x hx hxi + have Hx : H (x,q x)=(x,g x) := by + change (x,-J ((fderiv ℝ B (x,q x)).comp (ContinuousLinearMap.inl ℝ E E)))=(x,g x) + rw [hx,map_neg,J_inner,neg_neg] + change inv (H (x,q x))=(x,q x) at hxi + rw [Hx] at hxi + exact (congrArg Prod.snd hxi).symm + have heq0 : q 0=(inv (0,g 0)).2 := by + change q 0=(hstrict.localInverse H e (0,p) (0,g 0)).2 + rw [←hH0,hstrict.localInverse_apply_image,hq0] + apply (hfinal.congr_of_eventuallyEq heq heq0).congr_fderiv + ext h + change A h+S h=S h+A h + exact add_comm _ _ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/HopfGradient.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/HopfGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..b01aaca9935e5fb61ca2a3b32a784b8212d6f94c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/HopfGradient.lean @@ -0,0 +1,159 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.HopfSupports + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] in +lemma cost_divided_triangle_two_times (x y z : M) {s t : ℝ} (hs : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma mdifferentiableAt_of_chart_differentiable {f : M → ℝ} {x : M} + (hd : DifferentiableAt ℝ (fun y => f ((extChartAt 𝓘(ℝ,Model n) x).symm y)) + (extChartAt 𝓘(ℝ,Model n) x x)) : + MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x := by + have H := hd.hasFDerivAt.hasMFDerivAt.comp x + (mdifferentiableAt_extChartAt (I := 𝓘(ℝ,Model n)) + (show x∈(chartAt (Model n) x).source from mem_chart_source _ _)).hasMFDerivAt + apply (H.congr_of_eventuallyEq ?_).mdifferentiableAt + filter_upwards [extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) x] with y hy + simp only [Function.comp_apply,(extChartAt 𝓘(ℝ,Model n) x).left_inv hy] + +lemma WeakMTW.mdifferentiable_hopfLax (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 u x+cost x a/(t-ε)+cost a y/ε + have hG : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) G z.1 (innerSL ℝ z.2) := by + have H := (hasMFDerivAt_const (I := 𝓘(ℝ,Model n)) (I' := 𝓘(ℝ,ℝ)) + (u x+cost x a/(t-ε)) z.1).add (hshort.const_smul ε⁻¹) + have heD : 0+ε⁻¹ • innerSL ℝ (ε • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2) = + innerSL ℝ z.2 := by + ext v + simp only [zero_add,_root_.smul_apply,smul_eq_mul,innerSL_apply_apply, + real_inner_smul_left] + dsimp [z,w] + field_simp + replace H := H.congr_mfderiv heD + have heG : G = ((fun _ => u x+cost x a/(t-ε)) + + ε⁻¹ • fun y => dist (sprayFlow (t-ε) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 y^2/2) := by + funext y + dsimp [G,cost,a,w] + ring + rw [heG] + exact H + have hmin : dist x z.1=t*‖p‖ := by + dsimp [z,w] + rw [←riemannianExp_smul,minimizingVectors_smul hp ht.le ht1,norm_smul, + Real.norm_eq_abs,abs_of_pos ht] + have hleft : dist x a=(t-ε)*‖p‖ := + sprayFlow_minimizing_prefix w (sub_pos.mpr hεt).le (by linarith) hmin + have hright : dist a z.1=ε*‖p‖ := by + have H := sprayFlow_minimizing_subinterval w (sub_pos.mpr hεt).le (by linarith) hmin + simpa only [sub_sub_cancel] using H + have hcontact : hopfLax t u z.1=G z.1 := by + rw [heq] + dsimp [G,cost] + rw [hmin,hleft,hright] + field_simp + ring + have hle : ∀ y, hopfLax t u y≤G y := by + intro y + have H := cost_divided_triangle_two_times x a y (sub_pos.mpr hεt) hε + rw [sub_add_cancel] at H + exact (hopfLax_le hu t y x).trans (by dsimp [G]; linarith) + exact hd.hasMFDerivAt.congr_mfderiv + ((upper_contact_mfderiv hd hG.mdifferentiableAt (Filter.Eventually.of_forall hle) hcontact).trans hG.mfderiv) + +def riemannianGradient (f : M → ℝ) (x : M) : TangentSpace 𝓘(ℝ,Model n) x := by + letI : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + exact (InnerProductSpace.toDual ℝ (TangentSpace 𝓘(ℝ,Model n) x)).symm + (mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x) + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma riemannianGradient_eq_of_derivative {f : M → ℝ} {x : M} + {v : TangentSpace 𝓘(ℝ,Model n) x} + (h : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x (innerSL ℝ v)) : + riemannianGradient (n := n) f x=v := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + rw [riemannianGradient,h.mfderiv] + exact (InnerProductSpace.toDual ℝ (TangentSpace 𝓘(ℝ,Model n) x)).symm_apply_apply v + +lemma WeakMTW.hopfLax_backward_flow (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_chart_hopf_gradient_bound (c:M) : + ∃K≥0,∀ᶠ z in 𝓝 (extChartAt 𝓘(ℝ,Model n) c c),∀t:ℝ,1/2 ≤ t → + ∀u:M → ℝ,Continuous u → + ‖fderiv ℝ (fun w=>hopfLax t u ((extChartAt 𝓘(ℝ,Model n) c).symm w)) z‖ ≤ K := by + let : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨L,r,hr,hT,hL⟩ := exists_lipschitzOn_inverse_chart (E := Model n) c + let D:ℝ≥0:=Real.toNNReal (Metric.diam (univ:Set M)) + have hD:∀x y:M,dist x y ≤ D := by + intro x y + rw [Real.coe_toNNReal _ Metric.diam_nonneg] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + refine ⟨2*(D:ℝ)*L,by positivity,?_⟩ + filter_upwards [ball_mem_nhds (extChartAt 𝓘(ℝ,Model n) c c) hr] with z hz + intro t ht u hu + have ht0:0 < t := by linarith + have hn:=norm_fderiv_le_of_lipschitzOn ℝ (isOpen_ball.mem_nhds hz) + ((hopfLax_lipschitz hu hD ht0).comp_lipschitzOnWith hL) + have hdiv:(D:ℝ)/t ≤ 2*D := (div_le_iff₀ ht0).mpr (by nlinarith [D.coe_nonneg]) + calc + _ ≤ ↑((D/Real.toNNReal t)*L:ℝ≥0) := hn + _ = (D:ℝ)/t*L := by rw [NNReal.coe_mul,NNReal.coe_div,Real.coe_toNNReal _ ht0.le] + _ ≤ _ := mul_le_mul_of_nonneg_right hdiv L.coe_nonneg + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ImplicitNeighborhood.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ImplicitNeighborhood.lean new file mode 100644 index 0000000000000000000000000000000000000000..55f87bd35bdd2f3743a442c27df5ec5a04acbebf --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ImplicitNeighborhood.lean @@ -0,0 +1,95 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {X Y : Type*} [NormedAddCommGroup X] [NormedSpace ℝ X] [CompleteSpace X] + [NormedAddCommGroup Y] [NormedSpace ℝ Y] [CompleteSpace Y] + +lemma endomorphism_isInvertible_iff_isUnit (L : Y →L[ℝ] Y) : L.IsInvertible ↔ IsUnit L := by + constructor + · rintro ⟨e,rfl⟩ + exact ContinuousLinearMap.isUnit_iff_bijective.mpr e.bijective + · intro h + have hb := ContinuousLinearMap.isUnit_iff_bijective.mp h + exact ⟨ContinuousLinearEquiv.ofBijective L (LinearMap.ker_eq_bot.mpr hb.1) + (LinearMap.range_eq_top.mpr hb.2),rfl⟩ + +lemma isOpen_invertible_endomorphism : IsOpen {L : Y →L[ℝ] Y | L.IsInvertible} := by + simpa only [endomorphism_isInvertible_iff_isUnit] using + (Units.isOpen : IsOpen {L : Y →L[ℝ] Y | IsUnit L}) + +lemma exists_smooth_implicit_neighborhood (F : X × Y → Y) (hF : ContDiff ℝ ∞ F) + (a : X) (b : Y) (hi : (fderiv ℝ F (a,b) ∘L inr ℝ X Y).IsInvertible) : + ∃ U : X → Y, ∃ S : Set X, IsOpen S ∧ a ∈ S ∧ ContDiffOn ℝ ∞ U S ∧ U a = b ∧ + ∀ x ∈ S, F (x,U x) = F (a,b) := by + let U := hF.contDiffAt.implicitFunction (by simp) hi + have hU : ContDiffAt ℝ ∞ U a := hF.contDiffAt.contDiffAt_implicitFunction (by simp) hi + have hb : U a = b := hF.contDiffAt.implicitFunction_apply_self (by simp) hi + have hc : ∀ᶠ x in 𝓝 a, ContDiffAt ℝ 1 U x := + (hU.of_le (by simp : (1:ℕ∞ω) ≤ (∞:ℕ∞ω))).eventually (by simp) + have hid : Continuous (fun p : X × Y => fderiv ℝ F p ∘L inr ℝ X Y) := + (hF.continuous_fderiv (by simp)).clm_comp continuous_const + have hin : ∀ᶠ p in 𝓝 (a,b), (fderiv ℝ F p ∘L inr ℝ X Y).IsInvertible := + hid.continuousAt (isOpen_invertible_endomorphism.mem_nhds hi) + have hgraph : ContinuousAt (fun x => (x,U x)) a := continuousAt_id.prodMk hU.continuousAt + have hgi : ∀ᶠ x in 𝓝 a, (fderiv ℝ F (x,U x) ∘L inr ℝ X Y).IsInvertible := + hgraph (by simpa only [hb] using! hin) + have heq : ∀ᶠ x in 𝓝 a, F (x,U x) = F (a,b) := + hF.contDiffAt.eventually_apply_implicitFunction (by simp) hi + obtain ⟨V,hVsub,hV,hbase⟩ := mem_nhds_iff.mp + (hF.contDiffAt.eventually_apply_eq_iff_implicitFunction (by simp) hi) + have hgin : ∀ᶠ x in 𝓝 a, (x,U x) ∈ V := + hgraph (by simpa only [hb] using! hV.mem_nhds hbase) + obtain ⟨S,hSsub,hS,ha⟩ := mem_nhds_iff.mp (hc.and (hgi.and (heq.and hgin))) + refine ⟨U,S,hS,ha,?_,hb,fun x hx => (hSsub hx).2.2.1⟩ + intro x hx + have hh := hSsub hx + let W := hF.contDiffAt.implicitFunction (by simp) hh.2.1 + have hW : ContDiffAt ℝ ∞ W x := hF.contDiffAt.contDiffAt_implicitFunction (by simp) hh.2.1 + have hwx : W x = U x := hF.contDiffAt.implicitFunction_apply_self (by simp) hh.2.1 + have hWgraph : ContinuousAt (fun z => (z,W z)) x := continuousAt_id.prodMk hW.continuousAt + have hWV : ∀ᶠ z in 𝓝 x, (z,W z) ∈ V := hWgraph (by simpa only [hwx] using hV.mem_nhds hh.2.2.2) + have hev : U =ᶠ[𝓝 x] W := by + filter_upwards [hWV,hF.contDiffAt.eventually_apply_implicitFunction (by simp) hh.2.1] with z hz hz' + apply (hVsub hz).mp + exact hz'.trans hh.2.2.1 + exact (hW.congr_of_eventuallyEq hev).contDiffWithinAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/JetPullback.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/JetPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ea309b09abe0b73ad544c7b1615f241ac87c19a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/JetPullback.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.FullSet + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_fderiv_comp_affine {f : F → ℝ} (L : E →L[ℝ] F) (b : F) (x : E) + (hf : ContDiffAt ℝ 2 f (b+L x)) (v w : E) : + fderiv ℝ (fderiv ℝ (fun h => f (b+L h))) x v w = + fderiv ℝ (fderiv ℝ f) (b+L x) (L v) (L w) := by + have hL : ∀ y:E, HasFDerivAt (fun h : E => b+L h) L y := + fun y => (L.hasFDerivAt (x := y)).const_add b + have hd := ((hf.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun h : E => b+L h) x (hL x) + have H := hd.clm_comp (hasFDerivAt_const L x) + have heq : (fun h => fderiv ℝ f (b+L h) |>.comp L) =ᶠ[𝓝 x] + (fderiv ℝ (fun h => f (b+L h))) := by + have hn := (hL x).continuousAt.eventually (hf.eventually (by norm_num)) + filter_upwards [hn] with h hh + exact ((hh.differentiableAt (by norm_num)).hasFDerivAt.comp + (f := fun h : E => b+L h) h (hL h)).fderiv.symm + have he := congrArg (fun B : E →L[ℝ] E →L[ℝ] ℝ => B v w) + (H.congr_of_eventuallyEq heq.symm).fderiv + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.flip_apply,map_zero,ContinuousLinearMap.comp_zero, + zero_add,add_apply,zero_apply] using he + +lemma hasSecondTaylor_shift {f : E → ℝ} {x : E} (hf : ContDiffAt ℝ 2 f x) : + HasSecondTaylor (fun h => f (x+h)) (fderiv ℝ f x) + (fderiv ℝ (fderiv ℝ f) x) := by + have hc : ContDiffAt ℝ 2 (fun h => f (x+h)) 0 := by + exact (show ContDiffAt ℝ 2 f (x+(0:E)) by simpa using hf).comp 0 + (contDiffAt_const.add contDiffAt_id) + have H := hasSecondTaylor_of_contDiffAt hc + have hD : fderiv ℝ (fun h => f (x+h)) 0=fderiv ℝ f x := by + have hd := (hf.differentiableAt (by norm_num)).hasFDerivAt + have hl := (hasFDerivAt_id (𝕜 := ℝ) (0:E)).const_add x + simpa only [add_zero,ContinuousLinearMap.comp_id,Function.comp_def] using + ((show HasFDerivAt f (fderiv ℝ f x) (x+(0:E)) by simpa using hd).comp + (f := fun h : E => x+h) 0 hl).fderiv + have hDD : fderiv ℝ (fderiv ℝ (fun h => f (x+h))) 0= + fderiv ℝ (fderiv ℝ f) x := by + ext v w + simpa only [ContinuousLinearMap.id_apply,add_zero] using + second_fderiv_comp_affine (ContinuousLinearMap.id ℝ E) x 0 + (by simpa using hf) v w + rwa [hD,hDD] at H + +end + +open Set Filter +open scoped Topology ContDiff + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma half_norm_sq_hasFDerivAt (p : E) : + HasFDerivAt (fun v : E => ‖v‖^2/2) (innerSL ℝ p) p := by + have H := ((hasFDerivAt_id (𝕜 := ℝ) p).norm_sq).const_smul (1/2:ℝ) + convert! H using 1 + · ext v; simp only [Pi.smul_apply,smul_eq_mul,id_eq]; ring + · ext a + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply, + smul_apply,smul_eq_mul,innerSL_apply_apply,id_eq] + ring + +lemma half_norm_sq_fderiv : + fderiv ℝ (fun v : E => ‖v‖^2/2) = innerSL ℝ := by + funext p + exact (half_norm_sq_hasFDerivAt p).fderiv + +lemma half_norm_sq_second_fderiv (p a d : E) : + fderiv ℝ (fderiv ℝ (fun v : E => ‖v‖^2/2)) p a d=inner ℝ a d := by + rw [half_norm_sq_fderiv] + rw [(innerSL ℝ).hasFDerivAt.fderiv] + rfl + +lemma half_norm_sq_contDiff : ContDiff ℝ ∞ (fun v : E => ‖v‖^2/2) := by + simpa only [one_div,Pi.smul_apply,smul_eq_mul,div_eq_mul_inv,mul_comm,one_mul] using + ((contDiff_norm_sq (𝕜 := ℝ) (E := E) (n := ∞)).const_smul (1/2:ℝ)) + +lemma norm_square_hasSecondTaylor (p : E) : + HasSecondTaylor (fun h : E => ‖p+h‖^2/2) (innerSL ℝ p) (innerSL ℝ) := by + have hc : ContDiffAt ℝ 2 (fun v : E => ‖v‖^2/2) p := + ((half_norm_sq_contDiff (E := E)).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + have H := hasSecondTaylor_shift hc + simpa only [half_norm_sq_fderiv,(innerSL ℝ).hasFDerivAt.fderiv] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/JetTranslation.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/JetTranslation.lean new file mode 100644 index 0000000000000000000000000000000000000000..b711a4dbf951418dada2c0707100650e74c63f19 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/JetTranslation.lean @@ -0,0 +1,42 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma fderiv_translate_at_zero {f:E → F} {x:E} (hf:DifferentiableAt ℝ f x) (c:F) : + fderiv ℝ (fun h=>f (x+h)-c) 0=fderiv ℝ f x := by + rw [fderiv_sub_const] + have H:=(show HasFDerivAt f (fderiv ℝ f x) (x+id 0) from by simpa only [id_eq,add_zero] using hf.hasFDerivAt).comp 0 ((hasFDerivAt_id (0:E)).const_add x) + simpa only [Function.comp_def,add_zero,ContinuousLinearMap.comp_id] using H.fderiv + +lemma second_fderiv_translate_at_zero {f:E → F} {x:E} (hf:ContDiffAt ℝ 2 f x) (c:F) : + fderiv ℝ (fderiv ℝ (fun h=>f (x+h)-c)) 0=fderiv ℝ (fderiv ℝ f) x := by + have ht:Tendsto (fun h:E=>x+h) (𝓝 0) (𝓝 x):=by + have hc : ContinuousAt (fun h:E=>x+h) 0 := continuousAt_const.add continuousAt_id + have H:=hc.tendsto + rw [add_zero] at H + exact H + have hd:∀ᶠ y in 𝓝 x,DifferentiableAt ℝ f y:= + (hf.eventually (by norm_num)).mono (fun _ h=>h.differentiableAt (by norm_num)) + have he:fderiv ℝ (fun h=>f (x+h)-c)=ᶠ[𝓝 (0:E)] (fun h=>fderiv ℝ f (x+h)):=by + filter_upwards [ht.eventually hd] with h hh + rw [fderiv_sub_const] + have H:=hh.hasFDerivAt.comp h ((hasFDerivAt_id h).const_add x) + simpa only [Function.comp_def,ContinuousLinearMap.comp_id] using H.fderiv + rw [he.fderiv_eq] + have hfd:DifferentiableAt ℝ (fderiv ℝ f) x:= + (hf.fderiv_right (m:=1) (by norm_num)).differentiableAt (by norm_num) + have H:=(show HasFDerivAt (fderiv ℝ f) (fderiv ℝ (fderiv ℝ f) x) (x+id 0) from by simpa only [id_eq,add_zero] using hfd.hasFDerivAt).comp 0 ((hasFDerivAt_id (0:E)).const_add x) + simpa only [Function.comp_def,add_zero,ContinuousLinearMap.comp_id] using H.fderiv +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostGradient.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..18b4c30036e30cd41def5858825ebd58faa52139 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostGradient.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayScaling +import OAI.Analysis.BiholderTransport.Calculus.LocalMetricGradient +import OAI.Analysis.BiholderTransport.Coordinates.IntrinsicGradient + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_local_cost_gradient (a : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ b ∈ Metric.ball a δ, ∀ y ∈ Metric.ball a δ, + ∃ q : TangentBundle 𝓘(ℝ,E) M, + q.1 = y ∧ ‖q.2‖ = dist b y ∧ (sprayFlow (-1) q).1 = b ∧ + HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun x => dist b x ^ 2 / 2) q.1 (innerSL ℝ q.2) := by + obtain ⟨δ,τ,hδ,hτ,hsrc,H⟩ := exists_local_metric_gradient (E := E) a + refine ⟨δ,hδ,?_⟩ + intro b hb y hy + obtain ⟨z,hzb,hzy,hn,hD⟩ := H b hb y hy + have hzs : (sprayFlow τ z).1 ∈ (extChartAt 𝓘(ℝ,E) a).source := hzy ▸ hsrc hy + have hDc : HasFDerivAt (fun w : E => dist b ((extChartAt 𝓘(ℝ,E) a).symm w)^2 / 2) + (τ • riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a (sprayFlow τ z).1) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) (sprayFlow τ z)).2)) + (extChartAt 𝓘(ℝ,E) a (sprayFlow τ z).1) := by rwa [hzy] + have hD' := hasMFDerivAt_of_coordinate_gradient (sprayFlow τ z) hzs + (fun x => dist b x^2/2) τ hDc + refine ⟨tangentScale τ (sprayFlow τ z),hzy,?_,?_,?_⟩ + · change ‖τ • (sprayFlow τ z).2‖ = _ + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hτ,sprayFlow_speed] + exact hn.symm + · rw [sprayFlow_scale,show τ * (-1) = -τ by ring,←sprayFlow_add,neg_add_cancel,sprayFlow_zero] + exact hzb + · exact hD'.congr_mfderiv (map_smul (innerSL ℝ) τ (sprayFlow τ z).2).symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostSmooth.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostSmooth.lean new file mode 100644 index 0000000000000000000000000000000000000000..46f8efa7a2020488aa887976fa68879a27e2f44a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalCostSmooth.lean @@ -0,0 +1,137 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.JointNormalChart + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_local_cost_smooth (a : M) : + ∃ δ : ℝ, 0<δ ∧ ContMDiffOn (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => dist z.1 z.2^2/2) (Metric.ball a δ ×ˢ Metric.ball a δ) := by + obtain ⟨δ,_,τ,hδ,_,_,_,Φ,e,_,_,_,he,_,_,hei,hsrc,_,htarget,hdist⟩ := + exists_uniform_metric_normal_coordinates (E := E) a + let c := extChartAt 𝓘(ℝ,E) a + let g := riemannianCoordinateMetric (E := E) a + let V : M×M → E := fun z => (e.symm (c z.1,c z.2)).2 + let f : M×M → ℝ := fun z => (τ^2/2)*g (c z.1) (V z) (V z) + have heq : ∀ z ∈ Metric.ball a δ ×ˢ Metric.ball a δ, dist z.1 z.2^2/2 = f z := by + rintro ⟨b,y⟩ ⟨hb,hy⟩ + have ht := htarget b hb y hy + have hs := e.map_target ht + have hi := e.right_inv ht + have hfst : (e.symm (c b,c y)).1=c b := by + have hh := congrArg Prod.fst hi + rw [he] at hh + exact hh + have hpair : e.symm (c b,c y)=(c b,V (b,y)) := Prod.ext hfst rfl + rw [hpair] at hs hi + have hval : (Φ (τ,(c b,V (b,y)))).1=c y := by + have hh := congrArg Prod.snd hi + rw [he] at hh + exact hh + have hd := hdist b hb y hy (V (b,y)) hs hval + have hnonneg : 0 ≤ g (c b) (V (b,y)) (V (b,y)) := by + by_cases hv : V (b,y)=0 + · simp [hv] + · exact (riemannianCoordinateMetric_positive (c.map_source (hsrc hb)) hv).le + change dist b y^2/2 = (τ^2/2)*g (c b) (V (b,y)) (V (b,y)) + rw [hd,mul_pow,Real.sq_sqrt hnonneg] + ring + refine ⟨δ,hδ,?_⟩ + rintro z hz + have hc₁ : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E) ∞ (fun z : M×M => c z.1) z := + (contMDiffAt_extChartAt' (I := 𝓘(ℝ,E)) (by simpa only [extChartAt_source] using hsrc hz.1)).comp z contMDiffAt_fst + have hc₂ : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E) ∞ (fun z : M×M => c z.2) z := + (contMDiffAt_extChartAt' (I := 𝓘(ℝ,E)) (by simpa only [extChartAt_source] using hsrc hz.2)).comp z contMDiffAt_snd + have heSnd : ContDiffAt ℝ ∞ (fun w : E×E => (e.symm w).2) (c z.1,c z.2) := + (hei.contDiffAt (e.open_target.mem_nhds (htarget z.1 hz.1 z.2 hz.2))).snd + have heSndM : ContMDiffAt 𝓘(ℝ,E×E) 𝓘(ℝ,E) ∞ + (fun w : E×E => (e.symm w).2) (c z.1,c z.2) := heSnd.contMDiffAt + have hV : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E) ∞ V z := + heSndM.comp (f := fun z : M×M => (c z.1,c z.2)) z (hc₁.prodMk_space hc₂) + have hg : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E →L[ℝ] E →L[ℝ] ℝ) ∞ + (fun z : M×M => g (c z.1)) z := + ((contDiffOn_riemannianCoordinateMetric a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds (c.map_source (hsrc hz.1)))).contMDiffAt.comp z hc₁ + have hf : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,ℝ) ∞ f z := + contMDiffAt_const.mul ((hg.clm_apply hV).clm_apply hV) + exact ((hf.congr_of_eventuallyEq (Filter.eventuallyEq_of_mem + ((Metric.isOpen_ball.prod Metric.isOpen_ball).mem_nhds hz) heq)).contMDiffWithinAt) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/LocalMetricGradient.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalMetricGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..d186e2e17c246112a5e458002356e7e2f564a8dd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/LocalMetricGradient.lean @@ -0,0 +1,204 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayProjection +import OAI.Analysis.BiholderTransport.Coordinates.JointNormalChart +import OAI.Analysis.BiholderTransport.Coordinates.NormalGradient + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_local_metric_gradient (a : M) : + ∃ δ τ : ℝ, 0 < δ ∧ 0 < τ ∧ + Metric.ball a δ ⊆ (extChartAt 𝓘(ℝ,E) a).source ∧ + ∀ b ∈ Metric.ball a δ, ∀ y ∈ Metric.ball a δ, + ∃ z : TangentBundle 𝓘(ℝ,E) M, + z.1 = b ∧ (sprayFlow τ z).1 = y ∧ dist b y = τ * ‖z.2‖ ∧ + HasFDerivAt (fun w : E => dist b ((extChartAt 𝓘(ℝ,E) a).symm w)^2 / 2) + (τ • riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a y) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) (sprayFlow τ z)).2)) + (extChartAt 𝓘(ℝ,E) a y) := by + obtain ⟨δ,r,τ,hδ,hr,hτ,hτr,Φ,e,hΦ,hΦ0,hode,he,hesub,hed,hei,hsrc,hdiag,htarget,hdist⟩ := + exists_uniform_metric_normal_coordinates (E := E) a + refine ⟨δ,τ,hδ,hτ,hsrc,?_⟩ + intro b hb y hy + let c := extChartAt 𝓘(ℝ,E) a + let A : TangentBundle 𝓘(ℝ,E) M := ⟨a,0⟩ + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) A + let g := riemannianCoordinateMetric (E := E) a + have hp : ∀ z : E × E, (e z).1 = z.1 := by intro z; rw [he] + let f := fiberwiseHomeomorph e hp (c b) + let v := f.symm (c y) + have hyt : c y ∈ f.target := htarget b hb y hy + have hvs : v ∈ f.source := f.map_target hyt + have hcb : dist (c b) (c a) < r := + (max_lt_iff.mp (show max (dist (c b) (c a)) (dist (0:E) 0) < r from hesub (hdiag b hb))).1 + have hball : ∀ w ∈ Metric.ball (0:E) r, (c b,w) ∈ Metric.ball (c a,0) r := by + intro w hw + exact max_lt hcb hw + have hv : v ∈ Metric.ball (0:E) r := + (max_lt_iff.mp (show max (dist (c b) (c a)) (dist v 0) < r from hesub hvs)).2 + let Ψ : ℝ × E → E := fun z => (Φ (z.1,(c b,z.2))).1 + let W : ℝ × E → E := fun z => (Φ (z.1,(c b,z.2))).2 + have hΦc := hΦ.comp (contDiffOn_fst.prodMk (contDiffOn_const.prodMk contDiffOn_snd)) + (show MapsTo (fun z : ℝ × E => (z.1,(c b,z.2))) + (Ioo (-r) r ×ˢ Metric.ball 0 r) (Ioo (-r) r ×ˢ Metric.ball (c a,0) r) from + fun z hz => ⟨hz.1,hball z.2 hz.2⟩) + have hf : (f : E → E) = fun w => Ψ (τ,w) := by + funext w + change (e (c b,w)).2 = _ + rw [he] + have ht : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨by linarith,hr⟩ + have hΨv : Ψ (τ,v) = c y := (congrFun hf v).symm.trans (f.right_inv hyt) + have hG : ∀ w : E, g (c y) (W (τ,v)) (fderiv ℝ f v w) = τ*g (c b) v w := by + intro w + rw [hf,←hΨv] + exact coordinate_endpoint_gauss (Ψ := Ψ) (W := W) (x := c b) (g := g) + (isOpen_extChartAt_target a) + (contDiffOn_riemannianCoordinateMetric a) + (fun _ hx => riemannianCoordinateMetric_isInvertible hx) + (fun x _ u v => riemannianCoordinateMetric_symm a x u v) + (show ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r) from hΦc.fst) + (show ContDiffOn ℝ ∞ W (Ioo (-r) r ×ˢ Metric.ball 0 r) from hΦc.snd) + (fun t ht w hw => (hode t ht (c b,w) (hball w hw)).1) + (fun t ht w hw => ⟨((hode t ht (c b,w) (hball w hw)).2).fst, + ((hode t ht (c b,w) (hball w hw)).2).snd⟩) h0 + (fun w hw => congrArg Prod.fst (hΦ0 (c b,w) (hball w hw))) + (fun w hw => congrArg Prod.snd (hΦ0 (c b,w) (hball w hw))) ht hv w + have hfd := ((fiberwiseHomeomorph_contDiffOn hp (c b) hed).contDiffAt + (f.open_source.mem_nhds hvs)).differentiableAt (by simp) + have hfi := ((fiberwiseHomeomorph_symm_contDiffOn hp (c b) hei).contDiffAt + (f.open_target.mem_nhds hyt)).differentiableAt (by simp) + have hD := normal_action_hasFDerivAt f hyt hfd hfi (g (c b)) (g (c y)) + (riemannianCoordinateMetric_symm a (c b)) (W (τ,v)) τ hG + have hnear : ∀ᶠ w : E in 𝓝 (c y), w ∈ c.target ∧ c.symm w ∈ Metric.ball a δ := by + have hcy : c y ∈ c.target := c.map_source (hsrc hy) + have hynear := ((continuousOn_extChartAt_symm a).continuousAt ((isOpen_extChartAt_target a).mem_nhds hcy)).preimage_mem_nhds + (by rw [c.left_inv (hsrc hy)]; exact Metric.isOpen_ball.mem_nhds hy) + filter_upwards [(isOpen_extChartAt_target a).mem_nhds hcy, hynear] with w hw hwy + exact ⟨hw,hwy⟩ + have hdistEq : (fun w : E => dist b (c.symm w)^2/2) =ᶠ[𝓝 (c y)] + (fun w => (τ^2/2)*g (c b) (f.symm w) (f.symm w)) := by + filter_upwards [hnear] with w hw + have hwt : w ∈ f.target := by + change (c b,w) ∈ e.target + have hh : (c b,c (c.symm w)) ∈ e.target := htarget b hb (c.symm w) hw.2 + simpa only [c.right_inv hw.1] using hh + have hh := hdist b hb (c.symm w) hw.2 (f.symm w) (f.map_target hwt) + (show (Φ (τ,(c b,f.symm w))).1 = c (c.symm w) by + rw [c.right_inv hw.1] + exact (congrFun hf _).symm.trans (f.right_inv hwt)) + have hn : 0 ≤ g (c b) (f.symm w) (f.symm w) := by + by_cases hh : f.symm w = 0 + · simp only [hh,map_zero,le_refl] + · exact (riemannianCoordinateMetric_positive (c.map_source (hsrc hb)) hh).le + rw [hh,mul_pow,Real.sq_sqrt hn] + ring + let z := χ.symm (c b,v) + have hzt : (c b,v) ∈ χ.target := (tangent_chart_target_iff A _).mpr (c.map_source (hsrc hb)) + have hzchart : χ z = (c b,v) := χ.right_inv hzt + have hzsrc : z ∈ χ.source := χ.map_target hzt + have hzb : z.1 = b := by + have hh := congrArg Prod.fst hzchart + rw [tangent_chart_apply] at hh + exact c.injOn ((tangent_chart_source_iff A z).mp hzsrc) (hsrc hb) hh + have hflow := sprayFlow_eq_coordinate_curve A hr + (fun t ht' => (hode t ht' (c b,v) (hball v hv)).1) + (fun t ht' => (hode t ht' (c b,v) (hball v hv)).2) + (show χ.symm (Φ (0,(c b,v))) = z by rw [hΦ0 (c b,v) (hball v hv)]) ht + have hflowchart : χ (sprayFlow τ z) = Φ (τ,(c b,v)) := by + rw [hflow,χ.right_inv ((tangent_chart_target_iff A _).mpr (hode τ ht (c b,v) (hball v hv)).1)] + have hflowsrc : sprayFlow τ z ∈ χ.source := by + rw [hflow] + exact χ.map_target ((tangent_chart_target_iff A _).mpr (hode τ ht (c b,v) (hball v hv)).1) + have hfy : (sprayFlow τ z).1 = y := by + apply c.injOn ((tangent_chart_source_iff A _).mp hflowsrc) (hsrc hy) + exact (congrArg Prod.fst (tangent_chart_apply A (sprayFlow τ z))).symm.trans + ((congrArg Prod.fst hflowchart).trans hΨv) + refine ⟨z,hzb,hfy,?_,?_⟩ + · have hh := hdist b hb y hy v hvs hΨv + have hn := coordinate_spray_energy A z ((tangent_chart_source_iff A z).mp hzsrc) + rw [hzchart] at hn + rw [hh,hn,Real.sqrt_sq (norm_nonneg _)] + · have hh := hD.congr_of_eventuallyEq hdistEq + rw [show (χ (sprayFlow τ z)).2 = W (τ,v) from congrArg Prod.snd hflowchart] + exact hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/LowerTaylorComposition.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/LowerTaylorComposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..09e70d75fdaf6975c056c2e712132f5e4427f6cf --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/LowerTaylorComposition.lean @@ -0,0 +1,43 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LowerTaylor + +namespace OAI + +noncomputable section +open Set Filter Asymptotics +open scoped Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma HasLowerSecondTaylor.comp_stationary {f : F → ℝ} + {B : F →L[ℝ] F →L[ℝ] ℝ} (hf : HasLowerSecondTaylor f 0 B) + {a : E → F} {A : E →L[ℝ] F} (ha : HasFDerivAt a A 0) (ha0 : a 0=0) : + HasLowerSecondTaylor (fun h => f (a h)) 0 (pullBilinear B A) := by + have hO : a =O[𝓝 0] (fun h : E => h) := by + simpa only [ha0,sub_zero] using ha.isBigO_sub + obtain ⟨C,hC,HC⟩ := hO.exists_pos + have ht : Tendsto a (𝓝 0) (𝓝 0) := ha0 ▸ ha.continuousAt + intro ε hε + have hδ : 0 < ε/(2*C^2) := div_pos hε (by positivity) + have hB := (bilinear_remainder_of_hasFDerivAt ha ha0 B).def hε + filter_upwards [ht.eventually (hf _ hδ),HC.bound,hB] with h hh haB hb + simp only [zero_apply,add_zero] at hh ⊢ + rw [ha0,pullBilinear_apply] + have hb' : |B (a h) (a h)-B (A h) (A h)| ≤ ε*‖h‖^2 := by + simpa only [Real.norm_eq_abs,abs_pow,abs_norm] using hb + have hsq : ‖a h‖^2 ≤ C^2*‖h‖^2 := by + nlinarith only [sq_nonneg (C*‖h‖-‖a h‖),haB,norm_nonneg (a h), + mul_nonneg hC.le (norm_nonneg h)] + have hsq' := mul_le_mul_of_nonneg_left hsq (le_of_lt hδ) + have he : ε/(2*C^2)*(C^2*‖h‖^2)=(ε/2)*‖h‖^2 := by + field_simp [hC.ne'] + rw [he] at hsq' + linarith only [hh,(abs_le.mp hb').1,hsq'] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/MaximumScalarJets.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/MaximumScalarJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..dbc1fb040152070064bf0ea224efe8ee27d91e4c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/MaximumScalarJets.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamily +import OAI.Analysis.BiholderTransport.Regularity.MaximumGoodCenters +import OAI.Analysis.BiholderTransport.Convexity.JensenUndoShort +import OAI.Analysis.BiholderTransport.Convexity.JensenPhaseGradient + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance maximumScalarDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumScalarDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumScalarBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance maximumScalarBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma MaximumDiagonal.scalar_jets + {u v:M → ℝ} (hu:Continuous u) {Lv:ℝ≥0} (hv:LipschitzWith Lv v) + (hdual:IsCostDualPair u v) {α D bminus bplus A₀ B₀:ℝ} {Bc Bo:ℝ → ℝ} + {ho:Continuous Bo} (hBc:ContDiff ℝ ∞ Bc) + (hmono:∀b∈Icc bminus bplus,Monotone (fun s=>modifiedScalar α D Bc (b,s))) + (hrange:∀y,v y∈Icc A₀ B₀) + (hslope:∀b∈Icc bminus bplus,∀y:M, + 0modifiedScalar α D Bc (b,s)) (v y) ∧ + deriv (fun s=>modifiedScalar α D Bc (b,s)) (v y)<1) + {hmtw:WeakMTW (n:=n) (M:=M)} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} {a c:M} {N:Set (Model n)} + {J:MaximumJensenFamily hmtw hv.continuous ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + {Q:M → Prop} {r:ℝ} (hr:0v ((extChartAt 𝓘(ℝ,Model n) c).symm (z+h))) p A) + (hx:Tendsto (fun k=>J.sampleCenter k (S.ν k)) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hz:Tendsto (fun k=>(J.sample k).z (J.sampleIndex k (S.ν k))) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + {g:Model n →L[ℝ] ℝ} {H:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hg:Tendsto (fun k=>fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 g)) + (hH:Tendsto (fun k=>fderiv ℝ (fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 H)) : + ∃p:ℕ → Model n,∃A:ℕ → Model n →L[ℝ] Model n, + (∀ᶠ k in atTop,Q ((J.sample k).Y ((J.sample k).z (J.sampleIndex k (S.ν k)))) ∧ + (∀d e,inner ℝ (A k d) e=inner ℝ d (A k e)) ∧ + HasQuadraticExpansion (fun h=>modifiedScalar α D Bc (F.b k, + v ((extChartAt 𝓘(ℝ,Model n) c).symm (J.sampleCenter k (S.ν k)+h)))) (p k) (A k)) ∧ + Tendsto (fun k=>innerSL ℝ (p k)) atTop (𝓝 g) ∧ + Tendsto (fun k=>(innerSL ℝ).comp (A k)) atTop (𝓝 H) := by + let χ:=extChartAt 𝓘(ℝ,Model n) c + let i:=fun k=>J.sampleIndex k (S.ν k) + let φ:=fun k s=>modifiedScalar α D Bc (F.b k,s) + have hφ (k:ℕ):ContDiff ℝ ∞ (φ k):= + (modifiedScalar_contDiff hBc α D).comp (contDiff_const.prodMk contDiff_id) + have hsl (k:ℕ) (y:M):0 ‖fderiv ℝ (fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k)))‖) atTop (𝓝 ‖H‖) := hH.norm + have HG:∀ᶠ k in atTop,∀d, + fderiv ℝ (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (i k)) d d≤(‖H‖+1)*‖d‖^2:=by + filter_upwards [hHn.eventually (gt_mem_nhds (show ‖H‖<‖H‖+1 by linarith))] with k hk + intro d + exact (le_abs_self _).trans ((bilinear_quadratic_norm_bound _ d).trans + (mul_le_mul_of_nonneg_right hk.le (sq_nonneg _))) + have Hgood:=S.good_centers hBc.continuous hx hz HG + have HE:∀ᶠ k in atTop,Q ((J.sample k).Y ((J.sample k).z (i k))) ∧ + ∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>v (χ.symm (J.sampleCenter k (S.ν k)+h))) p A:=by + filter_upwards [Hgood,hx.eventually (ball_mem_nhds _ hr)] with k hk hb + have HH:=hgood _ hb hk + have hY:χ.symm (J.sampleCenter k (S.ν k))=(J.sample k).Y ((J.sample k).z (i k)):= + χ.left_inv ((J.sample k).samples (i k)).1 + rw [hY] at HH + exact HH + obtain ⟨K,hK,R,hR,hRT,Hsem⟩:=uniform_family_chart_semiconvex (n:=n) + (modifiedScalar_contDiff hBc α D) isCompact_Icc hmono A₀ B₀ c + have HB:∀y,cTransform u y∈Icc A₀ B₀:=by rwa [←hdual.2] + have HS:∀ᶠ k in atTop,∃r>0,∃K:ℝ, + ConvexOn ℝ (ball (J.sampleCenter k (S.ν k)) r) + (fun q=>φ k (v (χ.symm q))+K/2*‖q‖^2):=by + filter_upwards [hx.eventually (ball_mem_nhds _ (half_pos hR))] with k hk + have hs:=Hsem (F.b k) (Ioo_subset_Icc_self (F.parameter k)) u hu HB + rw [←hdual.2] at hs + refine ⟨R/2,half_pos hR,K,hs.subset ?_ (convex_ball _ _)⟩ + intro z hz' + change dist z (χ c)(F.prefixTime k).1) (fun k=>(F.prefixTime k).2) J.sample i F.time hz hg hH + (HE.mono (fun k hk=>hk.2)) HS + have hgrad:∀ᶠ k in atTop,(coordinatePhaseFlow c (1-F.t k,(J.sample k).z (i k), + fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (F.t k) c) ((J.sample k).z (i k)))).2= + innerSL ℝ (p k):=by + filter_upwards [HS,HPA] with k Hs Hp + obtain ⟨r,hr,K,Hs⟩:=Hs + exact hmtw.jensen_phase_gradient hu hv hdual (hφ k) (hsl k) + (F.prefixTime k).1 (F.prefixTime k).2 (J.sample k) (i k) + (S.chart k) hr Hp.1 Hp.2 Hs + exact ⟨p,A,(HE.and HPA).mono (fun k hk=>⟨hk.1.1,hk.2⟩), + phase_gradient_tendsto F.time hz hg hgrad,HA⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/MixedContinuity.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/MixedContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..63207496123d4bb479323dd0c40acf70fc6e1c78 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/MixedContinuity.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ChartCostJets + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MixedContinuity +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [CompleteSpace E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] [CompleteSpace F] + +local instance genericMixedProdNormedGroup : NormedAddCommGroup (F×E) := Prod.normedAddCommGroup +local instance genericMixedProdNormedSpace : NormedSpace ℝ (F×E) := Prod.normedSpace +local instance genericMixedDualNormedGroup : NormedAddCommGroup ((F×E) →L[ℝ] ℝ) := inferInstance +local instance genericMixedDualNormedSpace : NormedSpace ℝ ((F×E) →L[ℝ] ℝ) := inferInstance +end MixedContinuity + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteTrivialization (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance mixedTrivProductNormedGroup (x y : M) : + NormedAddCommGroup (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := + Prod.normedAddCommGroup +local instance mixedTrivProductNormedSpace (x y : M) : + NormedSpace ℝ (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := Prod.normedSpace +local instance mixedTrivDualNormedGroup (x y : M) : + NormedAddCommGroup ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := inferInstance +local instance mixedTrivDualNormedSpace (x y : M) : + NormedSpace ℝ ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := inferInstance +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +lemma compact_parameter_second_jet_on_graph {Q E : Type*} + [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + {K : Set Q} (hK : IsCompact K) {v : Q → E} (hv : Continuous v) + {F : (ℝ×Q) → E → ℝ} {t : ℝ} + (hF : ∀ q∈K, ContDiffAt ℝ ∞ (Function.uncurry F) ((t,q),v q)) : + ∃ B>0, ∀ᶠ s in 𝓝 t, ∀ q∈K, + ContDiffAt ℝ 2 (F (s,q)) (v q) ∧ + ‖fderiv ℝ (fderiv ℝ (F (s,q))) (v q)‖≤B := by + let H := fun z : ℝ×Q => fderiv ℝ (fderiv ℝ (F z)) (v z.2) + have hc : Continuous (fun z : ℝ×Q => (z,v z.2)) := continuous_id.prodMk (hv.comp continuous_snd) + have hH : ∀ q∈K, ContinuousAt H (t,q) := by + intro q hq + exact (ContDiffAt.partial_snd_fderiv_two (hF q hq)).continuousAt.comp + (x := (t,q)) (f := fun z : ℝ×Q => (z,v z.2)) hc.continuousAt + obtain ⟨B,hB,HB⟩ := compact_eventually_fiberwise_bound hK + (f := fun _ : Q => ()) continuous_const (g := fun _ : ℝ => ()) + (continuousAt_const (x := t)) (h := H) (fun q hq _ => hH q hq) + have HS : ∀ᶠ s in 𝓝 t, ∀ q∈K, ()=() → ContDiffAt ℝ 2 (F (s,q)) (v q) := by + apply compact_eventually_fiberwise hK (f := fun _ : Q => ()) continuous_const + (g := fun _ : ℝ => ()) (continuousAt_const (x := t)) + intro q hq _ + have He := ((hF q hq).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + filter_upwards [(hc.continuousAt (x := (t,q))).tendsto.eventually He] with z hz + exact hz.comp (v z.2) (contDiffAt_const.prodMk contDiffAt_id) + refine ⟨B,hB,?_⟩ + filter_upwards [HB,HS] with s hb hs + exact fun q hq => ⟨hs q hq rfl,hb q hq rfl⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ModifiedScalarDerivatives.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ModifiedScalarDerivatives.lean new file mode 100644 index 0000000000000000000000000000000000000000..b8dc0088389cf3053db8c47129d217d2cc72241c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ModifiedScalarDerivatives.lean @@ -0,0 +1,35 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamily + +namespace OAI + +noncomputable section +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma modifiedScalar_deriv {B:ℝ → ℝ} (hB:ContDiff ℝ ∞ B) (a D b s:ℝ) : + deriv (fun x=>modifiedScalar a D B (b,x)) s=1+b/D*deriv B ((s-a)/D) := by + have H:= (hasDerivAt_id s).add (((hB.differentiable (by simp) ((s-a)/D)).hasDerivAt.comp s + (((hasDerivAt_id s).sub_const a).div_const D)).const_mul b) + convert! H.deriv using 1 + ring + +lemma modifiedScalar_second {B:ℝ → ℝ} (hB:ContDiff ℝ ∞ B) (a D b s:ℝ) : + iteratedDeriv 2 (fun x=>modifiedScalar a D B (b,x)) s=b/D^2*iteratedDeriv 2 B ((s-a)/D) := by + have hb:ContDiff ℝ ∞ (deriv B):=(contDiff_infty_iff_deriv.mp hB).2 + have H:= (hasDerivAt_const s (1:ℝ)).add (((hb.differentiable (by simp) ((s-a)/D)).hasDerivAt.comp s + (((hasDerivAt_id s).sub_const a).div_const D)).const_mul (b/D)) + have heq:deriv (fun x=>modifiedScalar a D B (b,x))=(fun x=>1+b/D*deriv B ((x-a)/D)) := + funext (modifiedScalar_deriv hB a D b) + simp only [iteratedDeriv_succ,iteratedDeriv_zero] + rw [heq] + convert! H.deriv using 1 + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/OuterDerivativeBound.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/OuterDerivativeBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..6001e8c016cedfb0931df5d69bdaa1225d17a270 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/OuterDerivativeBound.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OuterTemplatePrimitive + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma exists_outerTemplate_deriv_bound {M0 K eta:ℝ} (heta:0 < eta) (heta1:eta ≤ 1/128) : + ∃C:ℝ,0 ≤ C ∧ ∀s,|deriv (outerTemplate M0 K eta) s| ≤ C := by + have hc:Continuous (deriv (outerTemplate M0 K eta)) := + (outerTemplate_smooth M0 K eta).continuous_deriv (by simp) + obtain ⟨C,hC⟩:= (isCompact_Icc : IsCompact (Icc (-1) (2:ℝ))).exists_bound_of_continuousOn hc.continuousOn + refine ⟨max C 0,le_max_right _ _,?_⟩ + intro s + by_cases hs:s∈Icc (-1) (2:ℝ) + · exact (hC s hs).trans (le_max_left _ _) + have hd:deriv (outerTemplate M0 K eta) s=0 := by + have hh:s < -1 ∨ 2 < s := by simpa only [mem_Icc,not_and_or,not_le] using hs + rcases hh with h | h + · have he:outerTemplate M0 K eta =ᶠ[𝓝 s] outerPrimitive M0 K eta := by + filter_upwards [eventually_lt_nhds (show s<1-eta by linarith only [h,heta1])] with t ht + exact outerTemplate_eq_primitive heta ht.le + rw [he.deriv_eq,(hasDerivAt_outerPrimitive M0 K eta s).deriv] + exact outerVelocity_zero_left heta (by linarith only [h,heta1]) + · have he:outerTemplate M0 K eta =ᶠ[𝓝 s] (fun _=>0) := by + filter_upwards [eventually_gt_nhds (show 1 f (q,s)) (directionalDerivative f (1,0) (t,s)) t := by + exact hf.hasFDerivAt.comp_hasDerivAt t ((hasDerivAt_id t).prodMk (hasDerivAt_const t s)) + +lemma hasDerivAt_slice_right {f : ℝ × ℝ → F} {t s : ℝ} + (hf : DifferentiableAt ℝ f (t,s)) : + HasDerivAt (fun q => f (t,q)) (directionalDerivative f (0,1) (t,s)) s := by + exact hf.hasFDerivAt.comp_hasDerivAt s ((hasDerivAt_const s t).prodMk (hasDerivAt_id s)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/PartialDerivatives.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/PartialDerivatives.lean new file mode 100644 index 0000000000000000000000000000000000000000..779af0a2ee741d45873eb10c651803854e57a6b6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/PartialDerivatives.lean @@ -0,0 +1,31 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {Q E F : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma ContDiffAt.partial_snd_fderiv {f : Q → E → F} {q:Q} {h:E} + (hf : ContDiffAt ℝ ∞ (Function.uncurry f) (q,h)) : + ContDiffAt ℝ ∞ (fun z : Q × E => fderiv ℝ (f z.1) z.2) (q,h) := by + have H : ContDiffAt ℝ ∞ (Function.uncurry (fun z : Q × E => f z.1)) ((q,h),h) := by + exact hf.comp ((q,h),h) (contDiffAt_fst.fst.prodMk contDiffAt_snd) + exact H.fderiv contDiffAt_snd (by simp) + +lemma ContDiffAt.partial_snd_fderiv_two {f : Q → E → F} {q:Q} {h:E} + (hf : ContDiffAt ℝ ∞ (Function.uncurry f) (q,h)) : + ContDiffAt ℝ ∞ (fun z : Q × E => fderiv ℝ (fderiv ℝ (f z.1)) z.2) (q,h) := by + apply ContDiffAt.partial_snd_fderiv (f := fun q => fderiv ℝ (f q)) + exact ContDiffAt.partial_snd_fderiv hf + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/PathCalculus.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/PathCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..1d56bcc5eb1b17685e4f3545401b4293b849a478 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/PathCalculus.lean @@ -0,0 +1,136 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +universe u w +variable {K : Type w} {E F : Type u} [TopologicalSpace K] [CompactSpace K] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +local instance pathCalculusNormedAddCommGroupContinuousLinearMap : + NormedAddCommGroup (E →L[ℝ] F) := ContinuousLinearMap.toNormedAddCommGroup +local instance pathCalculusNormedSpaceContinuousLinearMap : + NormedSpace ℝ (E →L[ℝ] F) := ContinuousLinearMap.toNormedSpace +local instance pathCalculusNormedAddCommGroupContinuousMap : + NormedAddCommGroup C(K,E →L[ℝ] F) := ContinuousMap.instNormedAddCommGroup + +def pathLinearApply (A : C(K,E →L[ℝ] F)) : C(K,E) →L[ℝ] C(K,F) := by + let L : C(K,E) →ₗ[ℝ] C(K,F) := + { toFun := fun u => ⟨fun t => A t (u t),A.continuous.clm_apply u.continuous⟩ + map_add' := by intro u v; ext t; exact map_add (A t) (u t) (v t) + map_smul' := by intro c u; ext t; exact map_smul (A t) c (u t) } + exact L.mkContinuous ‖A‖ (by + intro u + change ‖(⟨fun t => A t (u t),A.continuous.clm_apply u.continuous⟩ : C(K,F))‖ ≤ ‖A‖ * ‖u‖ + apply (ContinuousMap.norm_le _ (mul_nonneg (norm_nonneg A) (norm_nonneg u))).mpr + intro t + exact (A t).le_opNorm (u t) |>.trans + (mul_le_mul (A.norm_coe_le_norm t) (u.norm_coe_le_norm t) + (norm_nonneg _) (norm_nonneg _))) + +@[simp] lemma pathLinearApply_apply (A : C(K,E →L[ℝ] F)) (u : C(K,E)) (t : K) : + pathLinearApply A u t = A t (u t) := rfl + +lemma norm_pathLinearApply_le (A : C(K,E →L[ℝ] F)) : ‖pathLinearApply A‖ ≤ ‖A‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg A) + intro u + apply (ContinuousMap.norm_le _ (mul_nonneg (norm_nonneg A) (norm_nonneg u))).mpr + intro t + exact (A t).le_opNorm (u t) |>.trans + (mul_le_mul (A.norm_coe_le_norm t) (u.norm_coe_le_norm t) + (norm_nonneg _) (norm_nonneg _)) + +def pathLinearApplyL : C(K,E →L[ℝ] F) →L[ℝ] C(K,E) →L[ℝ] C(K,F) := by + let L : C(K,E →L[ℝ] F) →ₗ[ℝ] C(K,E) →L[ℝ] C(K,F) := + { toFun := fun (A : C(K,E →L[ℝ] F)) => pathLinearApply A + map_add' := by intro A B; ext u t; rfl + map_smul' := by intro c A; ext u t; rfl } + refine LinearMap.mkContinuous (𝕜 := ℝ) (𝕜₂ := ℝ) + (E := C(K,E →L[ℝ] F)) (F := C(K,E) →L[ℝ] C(K,F)) L 1 ?_ + intro A + change ‖pathLinearApply A‖ ≤ 1 * ‖A‖ + simpa only [one_mul] using norm_pathLinearApply_le A + +lemma hasFDerivAt_path_comp (f : C(E,F)) (f' : C(E,E →L[ℝ] F)) + (hder : ∀ x, HasFDerivAt f (f' x) x) (u : C(K,E)) : + HasFDerivAt (fun v : C(K,E) => f.comp v) (pathLinearApply (f'.comp u)) u := by + rw [hasFDerivAt_iff_isLittleO_nhds_zero,Asymptotics.isLittleO_iff] + intro ε hε + have hc : IsCompact (range u) := isCompact_range u.continuous + have huni := hc.uniformContinuousAt_of_continuousAt f' + (fun _ _ => f'.continuous.continuousAt) + (r := {z : (E →L[ℝ] F) × (E →L[ℝ] F) | dist z.1 z.2 < ε}) + (Metric.mem_uniformity_dist.mpr ⟨ε,hε,fun {_ _} h => h⟩) + obtain ⟨δ,hδ,hclose⟩ := Metric.mem_uniformity_dist.mp huni + filter_upwards [Metric.ball_mem_nhds (0:C(K,E)) hδ] with v hv + have hvnorm : ‖v‖ < δ := by simpa using hv + apply (ContinuousMap.norm_le _ (mul_nonneg hε.le (norm_nonneg v))).mpr + intro t + have hbound : ∀ z ∈ Metric.ball (u t) δ, ‖f' z - f' (u t)‖ ≤ ε := by + intro z hz + have hh := hclose (by simpa only [Metric.mem_ball,dist_comm] using hz) (mem_range_self t) + change dist (f' (u t)) (f' z) < ε at hh + exact le_of_lt (by simpa only [dist_eq_norm, norm_sub_rev] using hh) + have hb : u t + v t ∈ Metric.ball (u t) δ := by + rw [Metric.mem_ball,dist_eq_norm,add_sub_cancel_left] + exact (v.norm_coe_le_norm t).trans_lt hvnorm + have hm := Convex.norm_image_sub_le_of_norm_hasFDerivWithin_le' + (fun z (_ : z ∈ Metric.ball (u t) δ) => (hder z).hasFDerivWithinAt) + hbound (convex_ball (u t) δ) (Metric.mem_ball_self hδ) hb + have heq : ((f.comp (u+v) - f.comp u - pathLinearApply (f'.comp u) v) t) = + f (u t + v t) - f (u t) - f' (u t) ((u t + v t) - u t) := by + simp only [ContinuousMap.sub_apply,ContinuousMap.comp_apply,ContinuousMap.add_apply, + pathLinearApply_apply,add_sub_cancel_left] + rw [heq] + exact hm.trans (by simpa only [add_sub_cancel_left] using + mul_le_mul_of_nonneg_left (v.norm_coe_le_norm t) hε.le) + +lemma contDiff_path_comp_nat (m : ℕ) (f : C(E,F)) (hf : ContDiff ℝ m f) : + ContDiff ℝ m (fun v : C(K,E) => f.comp v) := by + induction m generalizing F with + | zero => exact contDiff_zero.mpr f.continuous_postcomp + | succ m ih => + obtain ⟨f',hf',hder⟩ := contDiff_succ_iff_hasFDerivAt.mp hf + let F' : C(E,E →L[ℝ] F) := ⟨f',hf'.continuous⟩ + apply contDiff_succ_iff_hasFDerivAt.mpr + refine ⟨fun v => pathLinearApply (F'.comp v),?_,?_⟩ + · exact (pathLinearApplyL (K := K) (E := E) (F := F)).contDiff.comp + (ih F' hf') + · intro u; exact hasFDerivAt_path_comp f F' hder u + +lemma contDiff_path_comp (f : C(E,F)) (hf : ContDiff ℝ ∞ f) : + ContDiff ℝ ∞ (fun v : C(K,E) => f.comp v) := + contDiff_infty.mpr fun m => contDiff_path_comp_nat m f (contDiff_infty.mp hf m) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseGraphDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseGraphDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..fcf3783e536c3d34bd5ea25b4369f187a4005162 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseGraphDerivative.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ProximalSelectorDerivative +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition +import OAI.Analysis.BiholderTransport.Convexity.ProximalProducer + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +lemma semiconvex_phase_graph_derivative + {f:E → ℝ} {Y:E → E} {P:E → E →L[ℝ] ℝ} + {Φ:(E×(E →L[ℝ] ℝ)) → E×(E →L[ℝ] ℝ)} + {x p:E} {A R:E →L[ℝ] E} {H:E →L[ℝ] E →L[ℝ] ℝ} + {D:(E×(E →L[ℝ] ℝ)) →L[ℝ] E×(E →L[ℝ] ℝ)} + (hA:∀v w,inner ℝ (A v) w=inner ℝ v (A w)) + (hexp:HasQuadraticExpansion (fun h=>f (Y x+h)) p A) + {r:ℝ} (hr:0(InnerProductSpace.toDual ℝ E).symm (Φ (z,P z)).2 + have hξ:ξ x=p:=semiconvex_subgradient_eq_at_expansion hA hexp hr K hsub.self_of_nhds + have hd:=semiconvex_subgradient_along_selector hA hexp hr K hY hξ hsub + have hs:HasFDerivAt (fun z=>(Φ (z,P z)).2) (((innerSL ℝ).comp A).comp R) x := by + have hh:HasFDerivAt (fun z=>(innerSL ℝ) (ξ z)) ((innerSL ℝ).comp (A.comp R)) x := + (innerSL ℝ).hasFDerivAt.comp x hd + have he:(fun z=>(Φ (z,P z)).2)=(fun z=>(innerSL ℝ) (ξ z)) := by + funext z + exact ((InnerProductSpace.toDual ℝ E).apply_symm_apply (Φ (z,P z)).2).symm + rw [he] + simpa only [ContinuousLinearMap.comp_assoc] using hh + have hb:HasFDerivAt (fun z=>(Φ (z,P z)).1) R x := hY.congr_of_eventuallyEq hbase + have hboth:=hb.prodMk hs + have hchain:=hΦ.comp x ((hasFDerivAt_id x).prodMk hP) + exact hchain.unique hboth + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseJet.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..93afd0f84260c9130331d8573fc5b86068e5b1fa --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/PhaseJet.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.CotangentFlow + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section PhaseJetAlgebra +variable {E:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] +variable {P:Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma limit_from_comp_near_id {Aj Hj:ℕ → E →L[ℝ] P} {Rj:ℕ → E →L[ℝ] E} + {H:E →L[ℝ] P} (hR:Tendsto Rj atTop (𝓝 1)) + (hH:Tendsto Hj atTop (𝓝 H)) + (he:∀ᶠ j in atTop,(Aj j).comp (Rj j)=Hj j) : Tendsto Aj atTop (𝓝 H) := by + have hi:Tendsto (fun j=>Ring.inverse (Rj j)) atTop (𝓝 (1:E →L[ℝ] E)) := by + simpa only [Function.comp_def, Units.val_one, Ring.inverse_one] using (NormedRing.inverse_continuousAt (1:(E →L[ℝ] E)ˣ)).tendsto.comp hR + have hu:∀ᶠ j in atTop,IsUnit (Rj j) := hR.eventually (Units.isOpen.mem_nhds isUnit_one) + have hl:= (ContinuousLinearMap.compL ℝ E E P).continuous₂.tendsto (H,1) |>.comp (hH.prodMk_nhds hi) + change Tendsto (fun j=>(Hj j).comp (Ring.inverse (Rj j))) atTop (𝓝 H) at hl + apply hl.congr' + filter_upwards [he,hu] with j hej huj + ext v + have hh:=congrArg (fun T:E →L[ℝ] P=>T (Ring.inverse (Rj j) v)) hej + have hr:Rj j (Ring.inverse (Rj j) v)=v := + congrArg (fun T:E →L[ℝ] E=>T v) (Ring.mul_inverse_cancel (Rj j) huj) + simpa only [ContinuousLinearMap.comp_apply,hr] using hh.symm + +lemma phase_graph_derivative_limit + {Dj:ℕ → (E×P) →L[ℝ] (E×P)} {Hj Aj:ℕ → E →L[ℝ] P} + {Rj:ℕ → E →L[ℝ] E} {H:E →L[ℝ] P} + (hD:Tendsto Dj atTop (𝓝 (ContinuousLinearMap.id ℝ (E×P)))) + (hH:Tendsto Hj atTop (𝓝 H)) + (he:∀ᶠ j in atTop,(Dj j).comp ((ContinuousLinearMap.id ℝ E).prod (Hj j))= + (Rj j).prod ((Aj j).comp (Rj j))) : + Tendsto Rj atTop (𝓝 1) ∧ Tendsto Aj atTop (𝓝 H) := by + have hpair:Tendsto (fun j=>(ContinuousLinearMap.id ℝ E).prod (Hj j)) atTop + (𝓝 ((ContinuousLinearMap.id ℝ E).prod H)) := (ContinuousLinearMap.prodₗᵢ ℝ).continuous.tendsto _ |>.comp (tendsto_const_nhds.prodMk_nhds hH) + have hd:= (ContinuousLinearMap.compL ℝ E (E×P) (E×P)).continuous₂.tendsto _ |>.comp (hD.prodMk_nhds hpair) + change Tendsto (fun j=>(Dj j).comp ((ContinuousLinearMap.id ℝ E).prod (Hj j))) atTop + (𝓝 ((ContinuousLinearMap.id ℝ (E×P)).comp ((ContinuousLinearMap.id ℝ E).prod H))) at hd + rw [ContinuousLinearMap.id_comp] at hd + have hd':Tendsto (fun j=>(Rj j).prod ((Aj j).comp (Rj j))) atTop + (𝓝 ((ContinuousLinearMap.id ℝ E).prod H)) := hd.congr' he + have hR:= (ContinuousLinearMap.compL ℝ E (E×P) E (ContinuousLinearMap.fst ℝ E P)).continuous.tendsto _ |>.comp hd' + have hA:= (ContinuousLinearMap.compL ℝ E (E×P) P (ContinuousLinearMap.snd ℝ E P)).continuous.tendsto _ |>.comp hd' + change Tendsto (fun j=>(ContinuousLinearMap.fst ℝ E P).comp ((Rj j).prod ((Aj j).comp (Rj j)))) atTop + (𝓝 ((ContinuousLinearMap.fst ℝ E P).comp ((ContinuousLinearMap.id ℝ E).prod H))) at hR + simp only [ContinuousLinearMap.fst_comp_prod] at hR + change Tendsto (fun j=>(ContinuousLinearMap.snd ℝ E P).comp ((Rj j).prod ((Aj j).comp (Rj j)))) atTop + (𝓝 ((ContinuousLinearMap.snd ℝ E P).comp ((ContinuousLinearMap.id ℝ E).prod H))) at hA + simp only [ContinuousLinearMap.snd_comp_prod] at hA + exact ⟨hR,limit_from_comp_near_id hR hA (Eventually.of_forall (fun _=>rfl))⟩ +end PhaseJetAlgebra + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinate_phase_jet_limit {a:M} {q:Phase n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + {τj:ℕ → ℝ} {qj:ℕ → Phase n} {Hj Aj:ℕ → Model n →L[ℝ] Model n →L[ℝ] ℝ} + {Rj:ℕ → Model n →L[ℝ] Model n} {H:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (ht:Tendsto τj atTop (𝓝 0)) (hqj:Tendsto qj atTop (𝓝 q)) + (hH:Tendsto Hj atTop (𝓝 H)) + (he:∀ᶠ j in atTop, + (fderiv ℝ (fun v=>coordinatePhaseFlow a (τj j,v)) (qj j)).comp + ((ContinuousLinearMap.id ℝ (Model n)).prod (Hj j))= + (Rj j).prod ((Aj j).comp (Rj j))) : + Tendsto Rj atTop (𝓝 1) ∧ Tendsto Aj atTop (𝓝 H) := by + have hd := (coordinatePhaseFlow_derivative_limit hq).comp (ht.prodMk_nhds hqj) + exact phase_graph_derivative_limit hd hH he +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/PoleJetAlgebra.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/PoleJetAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..6b461832ceaed37b2eb2f41023ab8c7b3ee09a18 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/PoleJetAlgebra.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.JetPullback +import OAI.Analysis.BiholderTransport.Calculus.TaylorPositivity + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma HasSecondTaylor.const_mul {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) (c:ℝ) : + HasSecondTaylor (fun h => c*f h) (c • l) (c • B) := by + unfold HasSecondTaylor at * + have he : (fun h => c*f h-c*f 0-(c • l) h-(c • B) h h/2) = + (fun h => c*(f h-f 0-l h-B h h/2)) := by + funext h; simp only [smul_apply,smul_eq_mul]; ring + rw [he] + exact hf.const_mul_left c + +lemma pole_nonneg_of_envelope_taylor {f : E → ℝ} {p : E} {t : ℝ} + {R : E →L[ℝ] E} + (hf : HasSecondTaylor (fun h => f (p+h)) (t • innerSL ℝ p) + (t • innerSL ℝ-(innerSL ℝ).comp R)) + (hupper : ∀ᶠ q in 𝓝 p, f q≤f p+t*(‖q‖^2/2-‖p‖^2/2)) + (d:E) : 0 ≤ inner ℝ (R d) d := by + have H := ((norm_square_hasSecondTaylor p).const_mul t).sub hf + have He : t • innerSL ℝ p-t • innerSL ℝ p = (0 : E →L[ℝ] ℝ) := sub_self _ + have HB : t • innerSL ℝ-(t • innerSL ℝ-(innerSL ℝ).comp R)=(innerSL ℝ).comp R := + sub_sub_cancel _ _ + rw [He,HB] at H + have hm : IsLocalMin (fun h => t*(‖p+h‖^2/2)-f (p+h)) 0 := by + have ht : Tendsto (fun h:E => p+h) (𝓝 0) (𝓝 p) := by + simpa only [ContinuousAt,add_zero] using + (show ContinuousAt (fun h:E => p+h) 0 from by fun_prop) + filter_upwards [ht.eventually hupper] with h hh + simp only [add_zero] + linarith + exact H.nonneg_of_localMin hm d + +lemma pole_kernel_of_active_support {B : E×E → ℝ} {D f : E → ℝ} + {a : E → E} {p pj : E} {t : ℝ} {R : E →L[ℝ] E} + (ha : HasFDerivAt a R p) (ha0 : a p=0) + (hf : HasFDerivAt f (t • innerSL ℝ p) p) + (hB : DifferentiableAt ℝ B (0,p)) + (hBa : ∀ u v:E, fderiv ℝ B (0,p) (u,v) = -inner ℝ p u+t*inner ℝ p v) + (hD : HasFDerivAt D (-innerSL ℝ pj) 0) + (hm : IsLocalMin (fun q => f q-B (a q,q)+D (a q)) p) + (hsym : ∀ u v:E, inner ℝ (R u) v=inner ℝ u (R v)) : R (pj-p)=0 := by + have hB' : HasFDerivAt B (fderiv ℝ B (0,p)) (a p,p) := by + rw [ha0]; exact hB.hasFDerivAt + have hD' : HasFDerivAt D (-innerSL ℝ pj) (a p) := by rwa [ha0] + have hder := (hf.sub (hB'.comp (f := fun q => (a q,q)) p + (ha.prodMk (hasFDerivAt_id (𝕜 := ℝ) p)))).add (hD'.comp p ha) + have H := hm.hasFDerivAt_eq_zero hder + apply (inner_self_eq_zero (𝕜 := ℝ)).mp + have he := congrArg (fun l : E →L[ℝ] ℝ => l (R (pj-p))) H + simp only [add_apply,sub_apply,smul_apply,neg_apply,zero_apply, + smul_eq_mul,ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,innerSL_apply_apply] at he + rw [hBa] at he + have horth : inner ℝ (pj-p) (R (R (pj-p)))=0 := by + rw [inner_sub_left] + linarith + rw [←hsym] at horth + exact horth + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/RiemannianContinuous.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/RiemannianContinuous.lean new file mode 100644 index 0000000000000000000000000000000000000000..64fd4d683028b02e425de46351bb80e083c0de43 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/RiemannianContinuous.lean @@ -0,0 +1,87 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport +variable {EB : Type*} [NormedAddCommGroup EB] [NormedSpace ℝ EB] + {HB : Type*} [TopologicalSpace HB] {IB : ModelWithCorners ℝ EB HB} + {B : Type*} [TopologicalSpace B] [ChartedSpace HB B] + {F : Type*} [NormedAddCommGroup F] [NormedSpace ℝ F] + {E : B → Type*} [TopologicalSpace (TotalSpace F E)] [∀ x, NormedAddCommGroup (E x)] + [∀ x, InnerProductSpace ℝ (E x)] [FiberBundle F E] [VectorBundle ℝ F E] + [h : IsContMDiffRiemannianBundle IB ∞ F E] + +include h in +lemma continuousRiemannianBundle_of_smooth : IsContinuousRiemannianBundle F E := by + obtain ⟨g,hg,hge⟩ := IsContMDiffRiemannianBundle.exists_contMDiff (IB := IB) (n := ∞) (F := F) (E := E) + exact ⟨g,hg.continuous,hge⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SampleJetData.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SampleJetData.lean new file mode 100644 index 0000000000000000000000000000000000000000..40036fc7e13d3982a94dcd9981c4adde60cab5c6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SampleJetData.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.UniformFixedCrossing +import OAI.Analysis.BiholderTransport.Calculus.SamplePoleDerivative +import OAI.Analysis.BiholderTransport.Regularity.NonnegativeTransfer + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma exists_actual_uniform_regular_split_after {t:ℝ} (ht : 0⟨contracted_minimizer_mem_injectivityDomain hp + (ht.trans hst) hs1,hs x p (minimizing_norm_le_diam hp)⟩⟩ + +lemma WeakMTW.actual_sample_pole_matrix (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 extChartAt 𝓘(ℝ,Model n) c + (hopfPole (n := n) t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) a).symm w))) + (extChartAt 𝓘(ℝ,Model n) a (riemannianExp x (t • p)))) : + let V := TangentSpace 𝓘(ℝ,Model n) x + let I : V →L[ℝ] V →L[ℝ] ℝ := innerSL ℝ + let L : V →L[ℝ] V →L[ℝ] ℝ := t • I - fderiv ℝ (fderiv ℝ + (fun q:V=>hopfLax t (cTransform v) (riemannianExp x (t • q)))) p + DifferentiableAt ℝ (fderiv ℝ + (fun q:V=>hopfLax t (cTransform v) (riemannianExp x (t • q)))) p ∧ + (∀ d:V,0≤L d d) ∧ (∀ d e:V,L d e=L e d) ∧ + (∀ q∈activeLogs v x,∀ d:V,L (q-p) d=0) ∧ + (∀ (ι:Type) [Fintype ι] (pj:ι → V) (w:ι → ℝ), + (∀ j,0≤w j) → (∑ j,w j=1) → (∑ j,w j • pj j=p) → + (∀ j,pj j∈activeLogs v x) → ∀ i,0v (riemannianExp x (pj i+d))+‖pj i+d‖^2/2) + 0 (w i • L)) := by + dsimp only + let V := TangentSpace 𝓘(ℝ,Model n) x + let : NormedAddCommGroup (V →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (V →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (V →L[ℝ] V →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let q : subgradientGraph (n := n) (cTransform v) := ⟨⟨x,p⟩,hp⟩ + have hpole : hopfPole (n := n) t (cTransform v) (riemannianExp x (t • p))=x := by + exact congrArg Bundle.TotalSpace.proj (hmtw.hopfLax_backward_flow hv ht ht1 q) + obtain ⟨e,R,he,he0,herep⟩ := hmtw.exists_actual_normal_pole_derivative hv ht ht1 hz hx hpole hD + have hpre := hmtw.active_hull_precut hv ht ht1 x p + (normalSubdifferential_subset_active_hull hv x hp) + have hdual : IsCostDualPair (cTransform v) (cTransform (cTransform v)) := + ⟨(cTransform_triple hv).symm,rfl⟩ + have HD' := hmtw.actualPole_second_derivative (continuous_cTransform hv) + (continuous_cTransform (continuous_cTransform hv)) hdual ht ht1 hpre he he0 herep + have HD := HD'.fderiv + rw [HD,sub_sub_cancel] + have H := hmtw.actualPole_taylor (continuous_cTransform hv) + (continuous_cTransform (continuous_cTransform hv)) hdual ht ht1 hpre he he0 herep + obtain ⟨s,hts,hs1,hs⟩ := exists_actual_uniform_regular_split_after (n := n) (M := M) ht ht1 + refine ⟨HD'.differentiableAt,H.2.1,?_,?_,?_⟩ + · intro d f + change inner ℝ (R d) f=inner ℝ (R f) d + exact (H.2.2 d f).trans (real_inner_comm (R f) d) + · intro r hr d + have hk := hmtw.actualPole_kernel (continuous_cTransform hv) + (continuous_cTransform (continuous_cTransform hv)) hdual ht ht1 (ht.trans hts) hs1 + hpre hr.1 (active_contact_biconjugate hv hr.2).2 (hs x r hr.1).1 (hs x r hr.1).2 + he he0 herep + simp only [ContinuousLinearMap.comp_apply,hk,map_zero,zero_apply] + · intro ι _ pj w hw hw1 hbar ha i hi + exact hmtw.modified_active_lower_jet_nonneg hv ht hts hs1 pj w hw hw1 i hi + (fun j=>(ha j).1) (fun j=>(ha j).2) (fun j=>(hs x (pj j) (ha j).1).1) + (fun j=>(hs x (pj j) (ha j).1).2) (hbar ▸ he) (hbar ▸ he0) (hbar ▸ herep) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SamplePoleDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SamplePoleDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..3a2a34a42171d396d05c016449070c8905353643 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SamplePoleDerivative.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiberLog +import OAI.Analysis.BiholderTransport.Regularity.GraphInverse + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.continuous_hopfPole (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0hmtw.graphHomeomorph_inverse_pole hv ht ht1 z) + +lemma WeakMTW.exists_actual_normal_pole_derivative + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0 extChartAt 𝓘(ℝ,Model n) c + (hopfPole (n := n) t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) a).symm w))) + (extChartAt 𝓘(ℝ,Model n) a (riemannianExp x (t • p)))) : + ∃ e : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) x, + ∃ R : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x, + HasFDerivAt e R p ∧ e p=0 ∧ + ∀ᶠ q in 𝓝 p,riemannianExp x (e q)= + hopfPole (n := n) t (cTransform v) (riemannianExp x (t • q)) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let χ := extChartAt 𝓘(ℝ,Model n) a + let ψ := extChartAt 𝓘(ℝ,Model n) c + let P := hopfPole (n := n) t (cTransform v) + let F : Model n → Model n := fun w=>ψ (P (χ.symm w)) + let z := riemannianExp x (t • p) + let Z : V → Model n := fun q=>χ (riemannianExp x (t • q)) + let S : V →L[ℝ] V := t • ContinuousLinearMap.id ℝ V + have hc : ContMDiffAt 𝓘(ℝ,V) 𝓘(ℝ,Model n) ∞ + (fun q:V=>riemannianExp x (t • q)) p := + (contMDiff_riemannianExp_fiber x (t • p)).comp p S.contDiff.contMDiff.contMDiffAt + have hZ : ContDiffAt ℝ ∞ Z p := + ((contMDiffAt_extChartAt' (I := 𝓘(ℝ,Model n)) (by + simpa only [extChartAt_source] using hz)).comp p hc).contDiffAt + have hFz : F (Z p)=ψ x := by + dsimp [F,Z]; rw [χ.left_inv hz]; exact congrArg ψ hpole + obtain ⟨L,hL,hL0,hLi,hLin⟩ := exists_smooth_chart_fiber_log + (zero_mem_injectivityDomain (n := n) x) (by simpa only [riemannianExp_zero] using hx) + simp only [riemannianExp_zero] at hL hL0 hLi hLin + let e : V → V := fun q=>L (F (Z q)) + have hDZ : DifferentiableAt ℝ (fun q=>F (Z q)) p := + (show DifferentiableAt ℝ F (Z p) from hD).comp (f := Z) p (hZ.differentiableAt (by simp)) + have hDe : DifferentiableAt ℝ e p := + (show DifferentiableAt ℝ L (F (Z p)) from hFz ▸ hL.differentiableAt (by simp)).comp p hDZ + refine ⟨e,fderiv ℝ e p,hDe.hasFDerivAt,?_,?_⟩ + · dsimp [e]; rw [hFz]; exact hL0 + have hexp : ContinuousAt (fun q:V=>riemannianExp x (t • q)) p := hc.continuousAt + have hP : ContinuousAt (fun q:V=>P (riemannianExp x (t • q))) p := + (hmtw.continuous_hopfPole hv ht ht1).continuousAt.comp hexp + have hcZ : ∀ᶠ q in 𝓝 p,riemannianExp x (t • q)∈χ.source := + hexp.eventually ((isOpen_extChartAt_source a).mem_nhds hz) + have hcP : ∀ᶠ q in 𝓝 p,P (riemannianExp x (t • q))∈ψ.source := + hP.eventually (show ψ.source∈𝓝 (P (riemannianExp x (t • p))) from by + change ψ.source∈𝓝 (hopfPole (n := n) t (cTransform v) (riemannianExp x (t • p))) + rw [hpole]; exact (isOpen_extChartAt_source c).mem_nhds hx) + have hlog : ∀ᶠ q in 𝓝 p,riemannianExp x (L (F (Z q)))=ψ.symm (F (Z q)) := + hDZ.continuousAt.eventually (hFz ▸ hLi) + filter_upwards [hcZ,hcP,hlog] with q hq hpq hlq + change riemannianExp x (L (F (Z q)))=P (riemannianExp x (t • q)) + rw [hlq] + dsimp [F,Z] + rw [χ.left_inv hq,ψ.left_inv hpq] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamily.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..413fccbd6c87ba6225dafed2f4a9a19c401bc9a7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamily.lean @@ -0,0 +1,38 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport + +def modifiedScalar (α D : ℝ) (B : ℝ → ℝ) (p : ℝ×ℝ) : ℝ := + p.2+p.1*B ((p.2-α)/D) + +lemma modifiedScalar_contDiff {B : ℝ → ℝ} (hB : ContDiff ℝ ∞ B) (α D : ℝ) : + ContDiff ℝ ∞ (modifiedScalar α D B) := + contDiff_snd.add (contDiff_fst.mul (hB.comp ((contDiff_snd.sub contDiff_const).div_const D))) + +lemma scalar_family_hasDeriv {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) (p:ℝ×ℝ) : + HasDerivAt (fun s=>Φ (p.1,s)) (fderiv ℝ Φ p (0,1)) p.2 := by + have H := (hΦ.differentiable (by simp) p).hasFDerivAt.comp_hasDerivAt p.2 + ((hasDerivAt_const p.2 p.1).prodMk (hasDerivAt_id p.2)) + exact H + +lemma continuous_scalar_family_deriv {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) : + Continuous (fun p:ℝ×ℝ=>deriv (fun s=>Φ (p.1,s)) p.2) := by + have heq (p:ℝ×ℝ) := (scalar_family_hasDeriv hΦ p).deriv + simp_rw [heq] + exact (contDiff_infty_iff_fderiv.mp hΦ).2.continuous.clm_apply continuous_const + +lemma scalar_family_derivable {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) (p:ℝ×ℝ) : + HasDerivAt (fun s=>Φ (p.1,s)) (deriv (fun s=>Φ (p.1,s)) p.2) p.2 := + (scalar_family_hasDeriv hΦ p).differentiableAt.hasDerivAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamilyBounds.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamilyBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..04346385d6ef9e4d344d6a3cc2fae414fef72e55 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarFamilyBounds.lean @@ -0,0 +1,43 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ExactScalarBounds + +namespace OAI + + +noncomputable section +open Set Filter +open scoped ContDiff Topology NNReal + +namespace WeakMTWTransport + +lemma modifiedScalar_lipschitz {B:ℝ → ℝ} (hB:ContDiff ℝ ∞ B) + {C D b:ℝ} (hC:0 ≤ C) (hD:0 < D) (hb:0 ≤ b) (hbd:b/D*C ≤ 1/2) + (hder:∀s,|deriv B s|≤C) (a:ℝ) : + LipschitzWith 2 (fun s=>modifiedScalar a D B (b,s)) := by + apply lipschitzWith_of_nnnorm_deriv_le + · exact fun s=>(scalar_family_derivable (modifiedScalar_contDiff hB a D) (b,s)).differentiableAt + · intro s + apply (NNReal.coe_le_coe).mp + rw [coe_nnnorm,Real.norm_eq_abs] + obtain ⟨hl,hu⟩:=modifiedScalar_slope_bounds hB hC hD hb hbd hder a s + rw [abs_of_nonneg (by linarith only [hl])] + norm_num only [NNReal.coe_ofNat] + linarith only [hu] + +lemma exact_center_deriv_abs (s:ℝ) : |deriv centerTemplate s| ≤ centerGamma/2 := by + rw [abs_of_neg (centerTemplate_deriv_neg s)] + exact (centerTemplate_deriv_bound s).2 + +lemma exact_center_slope_small {a D b s eps:ℝ} (hD:0 < D) (hb:0 ≤ b) + (hsmall:b/D*centerGamma/2 < eps) : + |deriv (fun x=>modifiedScalar a D centerTemplate (b,x)) s-1| < eps := by + rw [modifiedScalar_deriv centerTemplate_smooth,add_sub_cancel_left,abs_mul, + abs_of_nonneg (div_nonneg hb hD.le)] + have H:=mul_le_mul_of_nonneg_left (exact_center_deriv_abs ((s-a)/D)) (div_nonneg hb hD.le) + exact H.trans_lt (by simpa only [mul_div_assoc] using hsmall) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarInverseJet.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarInverseJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..83439744f7265181a2353d5cc53842e42f1d5d09 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarInverseJet.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondFderivScalarComp + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma exists_scalar_inverse_jet {φ : ℝ → ℝ} {v l : ℝ} + (hφ : ContDiffAt ℝ 2 φ v) (hd : HasDerivAt φ l v) (hl : l≠0) : + ∃ i : ℝ → ℝ, ContDiffAt ℝ 2 i (φ v) ∧ i (φ v)=v ∧ + HasDerivAt i l⁻¹ (φ v) ∧ + (∀ᶠ w in 𝓝 (φ v),φ (i w)=w) ∧ + iteratedDeriv 2 i (φ v)= -iteratedDeriv 2 φ v/l^3 := by + let i := hφ.localInverse (hd.hasFDerivAt_equiv hl) (by norm_num) + have hi : ContDiffAt ℝ 2 i (φ v) := hφ.to_localInverse (hd.hasFDerivAt_equiv hl) (by norm_num) + have hiv : i (φ v)=v := hφ.localInverse_apply_image (hd.hasFDerivAt_equiv hl) (by norm_num) + have hr : ∀ᶠ w in 𝓝 (φ v),φ (i w)=w := + (hφ.hasStrictFDerivAt' (hd.hasFDerivAt_equiv hl) (by norm_num)).eventually_right_inverse + have hiD : HasDerivAt i l⁻¹ (φ v) := (show HasDerivAt φ l (i (φ v)) from hiv.symm ▸ hd).of_local_left_inverse hi.continuousAt hl (by + simpa only [hiv] using hr) + refine ⟨i,hi,hiv,hiD,hr,?_⟩ + have hsecond := iteratedDeriv_comp_two (show ContDiffAt ℝ 2 φ (i (φ v)) from hiv.symm ▸ hφ) hi + have hid : iteratedDeriv 2 (φ ∘ i) (φ v)=0 := by + have H : (φ ∘ i)=ᶠ[𝓝 (φ v)] (fun w : ℝ => w) := hr + have H2 := H.deriv.deriv_eq + simpa only [iteratedDeriv_succ,iteratedDeriv_zero,deriv_id'',deriv_const] using H2 + rw [hid,hiv,hd.deriv,hiD.deriv] at hsecond + apply (eq_div_iff (pow_ne_zero 3 hl)).mpr + field_simp at hsecond + nlinarith only [hsecond] + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma scalar_inverse_lower_test {φ : ℝ → ℝ} (hmono : StrictMono φ) + {v F : E → ℝ} {x : E} (hφ : ContDiffAt ℝ 2 φ (v x)) + {l : ℝ} (hd : HasDerivAt φ l (v x)) (hl : l≠0) + (hF : ContDiffAt ℝ 2 F x) (hval : F x=φ (v x)) + (hlo : ∀ᶠ y in 𝓝 x,F y≤φ (v y)) : + ∃ f : E → ℝ, ContDiffAt ℝ 2 f x ∧ f x=v x ∧ + (∀ᶠ y in 𝓝 x,f y≤v y) ∧ + fderiv ℝ f x=l⁻¹ • fderiv ℝ F x ∧ + ∀ ξ : E, fderiv ℝ (fderiv ℝ f) x ξ ξ= + l⁻¹*fderiv ℝ (fderiv ℝ F) x ξ ξ- + (iteratedDeriv 2 φ (v x)/l^3)*(fderiv ℝ F x ξ)^2 := by + obtain ⟨i,hi,hiv,hiD,hir,hi2⟩ := exists_scalar_inverse_jet hφ hd hl + let f := i ∘ F + have hiF : ContDiffAt ℝ 2 i (F x) := hval.symm ▸ hi + have hiDF : HasDerivAt i l⁻¹ (F x) := hval.symm ▸ hiD + refine ⟨f,hiF.comp x hF,by dsimp [f]; rw [hval,hiv],?_,?_,?_⟩ + · have hr' := hF.continuousAt.eventually (show ∀ᶠ a in 𝓝 (F x),φ (i a)=a by rwa [hval]) + filter_upwards [hlo,hr'] with y hy hry + apply hmono.le_iff_le.mp + simpa only [f,Function.comp_apply,hry] using hy + · exact (hiDF.comp_hasFDerivAt x (hF.differentiableAt (by norm_num)).hasFDerivAt).fderiv + · intro ξ + rw [show f=(fun y => i (F y)) from rfl,second_fderiv_scalar_comp hF hiF ξ, + hval,hi2,hiD.deriv] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetFormula.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetFormula.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec329ecf75ec5aa9c5535faee4fbb0eec74b2391 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetFormula.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondFderivScalarComp +import OAI.Analysis.BiholderTransport.Coordinates.ScalarExpansion + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] +omit [CompleteSpace E] in +lemma quadraticTaylor_hasFDerivAt (f0:ℝ) (p:E) {A:E →L[ℝ] E} + (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) (x:E) : + HasFDerivAt (quadraticTaylor f0 p A) (innerSL ℝ (p+A x)) x := by + have H:=((hasFDerivAt_const f0 x).add ((innerSL ℝ p).hasFDerivAt)).add + ((A.hasFDerivAt.inner ℝ (hasFDerivAt_id x)).const_smul (1/2:ℝ)) + convert! H using 1 + · funext d + simp only [quadraticTaylor, Pi.add_apply, Pi.smul_apply, innerSL_apply_apply, smul_eq_mul, id_eq] + ring + · ext d + simp only [add_apply,smul_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply,innerSL_apply_apply, + fderivInnerCLM_apply,inner_add_left,zero_add,smul_eq_mul, id_eq] + rw [hA d x,real_inner_comm d (A x)] + ring + +omit [CompleteSpace E] in +lemma quadraticTaylor_second_fderiv (f0:ℝ) (p:E) {A:E →L[ℝ] E} + (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) (x:E) : + fderiv ℝ (fderiv ℝ (quadraticTaylor f0 p A)) x=(innerSL ℝ).comp A := by + have he:fderiv ℝ (quadraticTaylor f0 p A)=(fun x=>innerSL ℝ (p+A x)):= by + funext x + exact (quadraticTaylor_hasFDerivAt f0 p hA x).fderiv + rw [he] + have H:=((innerSL ℝ).hasFDerivAt).comp x ((hasFDerivAt_const p x).add A.hasFDerivAt) + simpa only [zero_add,Function.comp_def,Pi.add_apply] using H.fderiv + +lemma quadratic_expansion_scalar_formula [FiniteDimensional ℝ E] {f:E → ℝ} {p:E} {A:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) + {φ:ℝ → ℝ} (hφ:ContDiffAt ℝ 2 φ (f 0)) : + ∃q:E,∃B:E →L[ℝ] E,(∀d e,inner ℝ (B d) e=inner ℝ d (B e)) ∧ + HasQuadraticExpansion (fun h=>φ (f h)) q B ∧ + ∀d,inner ℝ (B d) d=iteratedDeriv 2 φ (f 0)*(inner ℝ p d)^2+ + deriv φ (f 0)*inner ℝ (A d) d := by + let P:=quadraticTaylor (f 0) p A + have hP:ContDiff ℝ 2 P := by + dsimp only [P,quadraticTaylor] + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + have hp0:P 0=f 0 := by simp only [P,quadraticTaylor,map_zero,inner_zero_right,zero_div,add_zero] + have hQ:ContDiffAt ℝ 2 (fun h=>φ (P h)) 0 := (hp0.symm ▸ hφ).comp 0 hP.contDiffAt + have H:=quadratic_expansion_scalar_proxy hf hφ + refine ⟨(InnerProductSpace.toDual ℝ E).symm (fderiv ℝ (fun h=>φ (P h)) 0), + bilinearOperator (fderiv ℝ (fderiv ℝ (fun h=>φ (P h))) 0),?_,?_,?_⟩ + · intro d e + rw [bilinearOperator_inner] + calc + _ = fderiv ℝ (fderiv ℝ (fun h=>φ (P h))) 0 e d := + (hQ.isSymmSndFDerivAt (by norm_num)).eq d e + _ = _ := by rw [real_inner_comm,bilinearOperator_inner] + · intro epsilon hepsilon + obtain ⟨radius,hradius,hball⟩ := Metric.eventually_nhds_iff.mp (H.eventually hepsilon) + refine ⟨radius,hradius,?_⟩ + intro vector hvector + have hbound := hball (by simpa only [Metric.mem_ball,dist_zero_right] using hvector) + simpa only [P,quadraticTaylor,bilinearOperator_inner,InnerProductSpace.toDual_symm_apply, + sub_add_eq_sub_sub] using hbound + · intro d + rw [bilinearOperator_inner,second_fderiv_scalar_comp hP.contDiffAt (hp0.symm ▸ hφ),hp0] + rw [show fderiv ℝ P 0=innerSL ℝ p from by + simpa only [map_zero,add_zero] using (quadraticTaylor_hasFDerivAt (f 0) p hA 0).fderiv] + rw [quadraticTaylor_second_fderiv (f 0) p hA] + rfl +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetNeighborhood.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetNeighborhood.lean new file mode 100644 index 0000000000000000000000000000000000000000..8427bae0943e1a7cee872282f41e466af40b75f8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarJetNeighborhood.lean @@ -0,0 +1,35 @@ +import Mathlib + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma scalar_jet_neighborhood {E:Type*} [TopologicalSpace E] + {f:E → ℝ} {x:E} (hf:ContinuousAt f x) + {A B:ℝ×ℝ → ℝ} (hA:Continuous A) (hB:Continuous B) {β:ℝ} + {U:Set (E×ℝ)} (hU:U∈𝓝 (x,A (β,f x))) + (hcurve:B (β,f x) < 0) : + ∃V:Set (E×ℝ),V∈𝓝 (x,β) ∧ ∀q∈V, + (q.1,A (q.2,f q.1))∈U ∧ + B (q.2,f q.1) < 0 := by + let Q:=fun q:E×ℝ=>(q.2,f q.1) + have hQ:ContinuousAt Q (x,β) := continuousAt_snd.prodMk (hf.comp continuousAt_fst) + let J:=fun q:E×ℝ=>(q.1,A (q.2,f q.1)) + have hJ:ContinuousAt J (x,β) := continuousAt_fst.prodMk + (hA.continuousAt.comp hQ) + have hJU:J ⁻¹' U∈𝓝 (x,β) := hJ.preimage_mem_nhds hU + have hK:ContinuousAt (fun q:E×ℝ=>B (q.2,f q.1)) (x,β) := + hB.continuousAt.comp hQ + exact ⟨{q|J q∈U ∧ B (q.2,f q.1) < 0}, + inter_mem hJU (hK.eventually (gt_mem_nhds hcurve)),fun q hq=>hq⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarSecond.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarSecond.lean new file mode 100644 index 0000000000000000000000000000000000000000..ef117a3d17ac5c534e62df720ad108b8a6911b9b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ScalarSecond.lean @@ -0,0 +1,32 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamily + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma contDiff_scalar_family_deriv {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) : + ContDiff ℝ ∞ (fun p:ℝ×ℝ=>deriv (fun s=>Φ (p.1,s)) p.2) := by + have heq (p:ℝ×ℝ) := (scalar_family_hasDeriv hΦ p).deriv + simp_rw [heq] + exact (contDiff_infty_iff_fderiv.mp hΦ).2.clm_apply contDiff_const + +lemma continuous_scalar_family_second {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) : + Continuous (fun p:ℝ×ℝ=>iteratedDeriv 2 (fun s=>Φ (p.1,s)) p.2) := by + have H:=continuous_scalar_family_deriv (contDiff_scalar_family_deriv hΦ) + simpa only [iteratedDeriv_succ,iteratedDeriv_zero] using H + +lemma scalar_family_contDiff {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) (b:ℝ) : + ContDiff ℝ ∞ (fun s=>Φ (b,s)) := + hΦ.comp (contDiff_const.prodMk contDiff_id) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeLinearSandwich.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeLinearSandwich.lean new file mode 100644 index 0000000000000000000000000000000000000000..2940816b469d2b1ce8863daa2a76a9df9b5d4867 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeLinearSandwich.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F G H : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + [NormedAddCommGroup G] [NormedSpace ℝ G] + [NormedAddCommGroup H] [NormedSpace ℝ H] + +lemma second_derivative_linear_sandwich {f : F → G} {a : E} + (L : E →L[ℝ] F) (K : G →L[ℝ] H) (hf : ContDiffAt ℝ 2 f (L a)) (u v : E) : + fderiv ℝ (fderiv ℝ (fun x => K (f (L x)))) a u v = + K (fderiv ℝ (fderiv ℝ f) (L a) (L u) (L v)) := by + have heq : fderiv ℝ (fun x => K (f (L x))) =ᶠ[𝓝 a] + fun x => K.comp ((fderiv ℝ f (L x)).comp L) := by + filter_upwards [L.continuous.continuousAt.eventually (hf.eventually (by norm_num))] with x hx + exact (K.hasFDerivAt.comp x ((hx.differentiableAt (by norm_num)).hasFDerivAt.comp x + L.hasFDerivAt)).fderiv + have hdd := (hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hD := (hasFDerivAt_const K a).clm_comp + ((hdd.hasFDerivAt.comp a L.hasFDerivAt).clm_comp (hasFDerivAt_const L a)) + have h := congrArg (fun A : E →L[ℝ] E →L[ℝ] H => A u v) + ((hD.congr_of_eventuallyEq heq).fderiv) + simpa only [comp_apply,compL_apply,flip_apply,add_apply,zero_apply,map_zero,zero_add,add_zero] using h + +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [InnerProductSpace ℝ F] + +lemma second_derivative_half_norm_sq {g : E → F} {a v : E} + (hg : ContDiffAt ℝ 2 g a) : + fderiv ℝ (fderiv ℝ (fun x => ‖g x‖^2/2)) a v v = + ‖fderiv ℝ g a v‖^2 + inner ℝ (g a) (fderiv ℝ (fderiv ℝ g) a v v) := by + let G : E → E →L[ℝ] ℝ := fun x => (innerSL ℝ (g x)).comp (fderiv ℝ g x) + have hdg := hg.differentiableAt (by norm_num) + have hddg := (hg.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hG := ((innerSL ℝ).hasFDerivAt.comp a hdg.hasFDerivAt).clm_comp hddg.hasFDerivAt + have heq : fderiv ℝ (fun x => ‖g x‖^2/2) =ᶠ[𝓝 a] G := by + filter_upwards [hg.eventually (by norm_num : (2:ℕ∞ω)≠∞)] with x hx + have hd0 := ((hx.differentiableAt (by norm_num)).hasFDerivAt.norm_sq).const_smul (1/2:ℝ) + have hd := hd0.fderiv + have hfun : (fun z => ‖g z‖^2/2)=(fun z => (1/2:ℝ) • ‖g z‖^2) := by + funext z; simp only [smul_eq_mul]; ring + rw [hfun] + change fderiv ℝ ((1/2:ℝ) • fun z => ‖g z‖^2) x=G x + rw [hd] + ext w + simp only [G,comp_apply,smul_apply,innerSL_apply_apply,smul_eq_mul] + ring + have hD := (hG.congr_of_eventuallyEq heq).fderiv + rw [hD] + simp only [comp_apply,compL_apply,add_apply,flip_apply] + change inner ℝ (g a) (fderiv ℝ (fderiv ℝ g) a v v)+inner ℝ (fderiv ℝ g a v) (fderiv ℝ g a v)=_ + rw [real_inner_self_eq_norm_sq,add_comm] + +lemma third_derivative_swap_outer {f : E → ℝ} {a u v w : E} + (hf : ContDiffAt ℝ 3 f a) : + fderiv ℝ (fderiv ℝ (fderiv ℝ f)) a u v w = + fderiv ℝ (fderiv ℝ (fderiv ℝ f)) a v u w := by + exact congrArg (fun L : E →L[ℝ] ℝ => L w) + ((hf.fderiv_right (m := 2) (by norm_num)).isSymmSndFDerivAt (by norm_num) |>.eq u v) + +lemma third_derivative_swap_inner {f : E → ℝ} {a u v w : E} + (hf : ContDiffAt ℝ 3 f a) : + fderiv ℝ (fderiv ℝ (fderiv ℝ f)) a u v w = + fderiv ℝ (fderiv ℝ (fderiv ℝ f)) a u w v := by + let H := fderiv ℝ (fderiv ℝ f) + have hH := ((hf.fderiv_right (m := 2) (by norm_num)).fderiv_right + (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hvw := (hH.hasFDerivAt.clm_apply (hasFDerivAt_const v a)).clm_apply + (hasFDerivAt_const w a) + have hwv := (hH.hasFDerivAt.clm_apply (hasFDerivAt_const w a)).clm_apply + (hasFDerivAt_const v a) + have heq : (fun x => H x v w)=ᶠ[𝓝 a] (fun x => H x w v) := by + filter_upwards [hf.eventually (by norm_num : (3:ℕ∞ω)≠∞)] with x hx + exact hx.isSymmSndFDerivAt (by norm_num) |>.eq v w + have hh := congrArg (fun L : E →L[ℝ] ℝ => L u) + ((hvw.congr_of_eventuallyEq heq.symm).unique hwv) + simpa only [comp_apply,flip_apply,add_apply,zero_apply,map_zero,zero_add,add_zero] using hh + +lemma eikonal_third_derivative {B : E×F → ℝ} {g : E → F} {a v : E} + (hB : ContDiffAt ℝ 3 B (a,0)) (hg : ContDiffAt ℝ 2 g a) + (heik : (fun x => B (x,0)) =ᶠ[𝓝 a] (fun x => ‖g x‖^2/2)) + (hgrad : ∀ᶠ x in 𝓝 a, ∀ w : F, + fderiv ℝ B (x,0) (0,w)=inner ℝ (g x) w) : + fderiv ℝ (fderiv ℝ B) (a,0) (v,0) (v,0) = + ‖fderiv ℝ g a v‖^2+ + fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (a,0) (0,g a) (v,0) (v,0) := by + let L := ContinuousLinearMap.inl ℝ E F + have hL : L a=(a,0) := rfl + have hsource := second_derivative_linear_sandwich L (ContinuousLinearMap.id ℝ ℝ) + (show ContDiffAt ℝ 2 B (L a) from hB.of_le (by norm_num)) v v + have hnorm := congrArg (fun D : E →L[ℝ] E →L[ℝ] ℝ => D v v) + (heik.fderiv (𝕜 := ℝ)).fderiv_eq + have hs : fderiv ℝ (fderiv ℝ B) (a,0) (v,0) (v,0)= + ‖fderiv ℝ g a v‖^2+inner ℝ (g a) (fderiv ℝ (fderiv ℝ g) a v v) := by + have hsource' : fderiv ℝ (fderiv ℝ (fun x => B (x,0))) a v v = + fderiv ℝ (fderiv ℝ B) (a,0) (v,0) (v,0) := hsource + rw [←hsource'] + exact hnorm.trans (second_derivative_half_norm_sq hg) + have hpartial : (fun x => fderiv ℝ B (x,0) (0,g a)) =ᶠ[𝓝 a] + fun x => inner ℝ (g a) (g x) := by + filter_upwards [hgrad] with x hx + rw [hx,real_inner_comm] + have hp2 := congrArg (fun D : E →L[ℝ] E →L[ℝ] ℝ => D v v) + (hpartial.fderiv (𝕜 := ℝ)).fderiv_eq + have hleft := second_derivative_linear_sandwich L + (ContinuousLinearMap.apply ℝ ℝ ((0:E),g a)) + (show ContDiffAt ℝ 2 (fderiv ℝ B) (L a) from hB.fderiv_right (by norm_num)) v v + have hright := second_derivative_linear_sandwich (ContinuousLinearMap.id ℝ E) + (innerSL ℝ (g a)) hg v v + have htr : inner ℝ (g a) (fderiv ℝ (fderiv ℝ g) a v v)= + fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (a,0) (v,0) (v,0) (0,g a) := by + exact hright.symm.trans (hp2.symm.trans hleft) + rw [hs,htr] + congr 1 + rw [third_derivative_swap_inner hB,third_derivative_swap_outer hB] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeSlice.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeSlice.lean new file mode 100644 index 0000000000000000000000000000000000000000..a1d4ae6664bd813f8c8f9f3c05793a0afbe41f48 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeSlice.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeLinearSandwich + +namespace OAI + +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_derivative_source_slice {B : E×F → ℝ} {a : E} {b : F} + (hB : ContDiffAt ℝ 2 B (a,b)) (v w : E) : + fderiv ℝ (fderiv ℝ (fun x => B (x,b))) a v w = + fderiv ℝ (fderiv ℝ B) (a,b) (v,0) (w,0) := by + let L : E →L[ℝ] E×F := inl ℝ E F + let C : E×F → ℝ := fun z => B (z+(0,b)) + have hC : ContDiffAt ℝ 2 C (L a) := by + have hB' : ContDiffAt ℝ 2 B (L a+(0,b)) := by + simpa only [L,inl_apply,Prod.mk_add_mk,add_zero,zero_add] using hB + exact hB'.comp (L a) (contDiffAt_id.add contDiffAt_const) + have h := second_derivative_linear_sandwich L (ContinuousLinearMap.id ℝ ℝ) hC v w + have heq : fderiv ℝ C =ᶠ[𝓝 (a,0)] fun z => fderiv ℝ B (z+(0,b)) := by + filter_upwards [((continuousAt_id.add_const (0,b)).eventually + (show ∀ᶠ z in 𝓝 ((a,0)+(0,b)), ContDiffAt ℝ 2 B z from by + simpa only [Prod.mk_add_mk,add_zero,zero_add] using hB.eventually (by norm_num)))] with z hz + exact ((hz.differentiableAt (by norm_num)).hasFDerivAt.comp z + ((hasFDerivAt_id z).add_const (0,b))).fderiv + have hD := ((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)).hasFDerivAt + have hD' : HasFDerivAt (fderiv ℝ B) (fderiv ℝ (fderiv ℝ B) (a,b)) ((a,0)+(0,b)) := by + simpa using hD + have hDc := hD'.comp (a,0) ((hasFDerivAt_id (a,(0:F))).add_const (0,b)) + have hDD := (hDc.congr_of_eventuallyEq heq).fderiv + have hh : fderiv ℝ (fderiv ℝ C) (a,0)=fderiv ℝ (fderiv ℝ B) (a,b) := by + simpa only [comp_id] using hDD + have hh' : fderiv ℝ (fderiv ℝ (fun x => B (x,b))) a v w = + fderiv ℝ (fderiv ℝ C) (a,0) (v,0) (w,0) := by + simpa only [id_apply,C,L,inl_apply,Prod.mk_add_mk,add_zero,zero_add] using h + exact hh'.trans (congrArg (fun K : E×F →L[ℝ] E×F →L[ℝ] ℝ => K (v,0) (w,0)) hh) + +lemma hasDerivAt_source_hessian_line {B : E×F → ℝ} {a v : E} {b w : F} {t : ℝ} + (hB : ContDiffAt ℝ 3 B (a,b)) : + HasDerivAt (fun s : ℝ => fderiv ℝ (fderiv ℝ + (fun x => B (x,b+(s-t) • w))) a v v) + (fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (a,b) (0,w) (v,0) (v,0)) t := by + let q : ℝ → E×F := fun s => (a,b+(s-t) • w) + have hq : HasDerivAt q (0,w) t := by + simpa only [q,one_smul,id_eq] using (hasDerivAt_const t a).prodMk + (((hasDerivAt_id t).sub_const t).smul_const w |>.const_add b) + have hqt : q t=(a,b) := by simp [q] + have hH := ((hB.fderiv_right (m := 2) (by norm_num)).fderiv_right + (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hH' : HasFDerivAt (fderiv ℝ (fderiv ℝ B)) + (fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (a,b)) (q t) := hqt.symm ▸ hH.hasFDerivAt + have hD := hH'.comp_hasDerivAt (f := q) (l := fderiv ℝ (fderiv ℝ B)) t hq + have hD' := (hD.clm_apply (hasDerivAt_const t (v,(0:F)))).clm_apply + (hasDerivAt_const t (v,(0:F))) + have heq : (fun s : ℝ => fderiv ℝ (fderiv ℝ + (fun x => B (x,b+(s-t) • w))) a v v) =ᶠ[𝓝 t] + fun s => fderiv ℝ (fderiv ℝ B) (q s) (v,0) (v,0) := by + filter_upwards [hq.continuousAt.eventually + (show ∀ᶠ z in 𝓝 (q t), ContDiffAt ℝ 3 B z from by + rw [hqt]; exact hB.eventually (by norm_num))] with s hs + exact second_derivative_source_slice (hs.of_le (by norm_num)) v v + apply HasDerivAt.congr_of_eventuallyEq _ heq + simpa only [Function.comp_apply,zero_add,add_zero,map_zero] using hD' + +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] +lemma second_derivative_target_slice {B : E×F → ℝ} {a : E} {b : F} + (hB : ContDiffAt ℝ 2 B (a,b)) (v w : F) : + fderiv ℝ (fderiv ℝ (fun y => B (a,y))) b v w = + fderiv ℝ (fderiv ℝ B) (a,b) (0,v) (0,w) := by + let L : F →L[ℝ] E×F := inr ℝ E F + let C : E×F → ℝ := fun z => B (z+(a,0)) + have hC : ContDiffAt ℝ 2 C (L b) := by + have hB' : ContDiffAt ℝ 2 B (L b+(a,0)) := by + simpa only [L,inr_apply,Prod.mk_add_mk,add_zero,zero_add] using hB + exact hB'.comp (L b) (contDiffAt_id.add contDiffAt_const) + have h := second_derivative_linear_sandwich L (ContinuousLinearMap.id ℝ ℝ) hC v w + have heq : fderiv ℝ C =ᶠ[𝓝 (0,b)] fun z => fderiv ℝ B (z+(a,0)) := by + filter_upwards [((continuousAt_id.add_const (a,0)).eventually + (show ∀ᶠ z in 𝓝 ((0,b)+(a,0)), ContDiffAt ℝ 2 B z from by + simpa only [Prod.mk_add_mk,add_zero,zero_add] using hB.eventually (by norm_num)))] with z hz + exact ((hz.differentiableAt (by norm_num)).hasFDerivAt.comp z + ((hasFDerivAt_id z).add_const (a,0))).fderiv + have hD := ((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)).hasFDerivAt + have hD' : HasFDerivAt (fderiv ℝ B) (fderiv ℝ (fderiv ℝ B) (a,b)) ((0,b)+(a,0)) := by + simpa using hD + have hDc := hD'.comp ((0:E),b) ((hasFDerivAt_id ((0:E),b)).add_const (a,0)) + have hDD := (hDc.congr_of_eventuallyEq heq).fderiv + have hh : fderiv ℝ (fderiv ℝ C) (0,b)=fderiv ℝ (fderiv ℝ B) (a,b) := by + simpa only [comp_id] using hDD + have hh' : fderiv ℝ (fderiv ℝ (fun y => B (a,y))) b v w = + fderiv ℝ (fderiv ℝ C) (0,b) (0,v) (0,w) := by + simpa only [id_apply,C,L,inr_apply,Prod.mk_add_mk,add_zero,zero_add] using h + exact hh'.trans (congrArg (fun K : E×F →L[ℝ] E×F →L[ℝ] ℝ => K (0,v) (0,w)) hh) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeTaylor.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeTaylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..0281dbc0ebdaff982ec25ea974df83acb1521b71 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondDerivativeTaylor.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.FullSet + +namespace OAI + +noncomputable section +open Set Filter Asymptotics +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma hasSecondTaylor_of_second_derivative {f : E → ℝ} {f' : E → E →L[ℝ] ℝ} + {x : E} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : ∀ᶠ y in 𝓝 x, HasFDerivAt f (f' y) y) + (hD : HasFDerivAt f' B x) : + HasSecondTaylor (fun h => f (x+h)) (f' x) B := by + have hs : ∀ v w, B v w=B w v := second_derivative_symmetric_of_eventually hf hD + apply Asymptotics.IsLittleO.of_bound + intro ε hε + have hrem := (hasFDerivAt_iff_isLittleO_nhds_zero.mp hD).def hε + have hnear : ∀ᶠ h : E in 𝓝 0, HasFDerivAt f (f' (x+h)) (x+h) := by + exact (show ContinuousAt (fun h : E => x+h) 0 from continuousAt_const.add continuousAt_id).eventually + (by simpa only [add_zero] using hf) + obtain ⟨r,hr,hball⟩ := Metric.eventually_nhds_iff.mp (hnear.and hrem) + let R : E → ℝ := fun h => f (x+h)-f x-f' x h-B h h/2 + have hR0 : R 0=0 := by simp [R] + have hdR : ∀ z ∈ Metric.ball (0:E) r, + HasFDerivAt R (f' (x+z)-f' x-B z) z := by + intro z hz + have hshift : HasFDerivAt (fun h : E => x+h) (ContinuousLinearMap.id ℝ E) z := + (hasFDerivAt_id z).const_add x + have hbase := (hball hz).1.comp (f := fun h : E => x+h) z hshift + have hquad : HasFDerivAt (fun v : E => B v v/2) (B z) z := by + have H := (B.hasFDerivAt_of_bilinear (hasFDerivAt_id z) (hasFDerivAt_id z)).const_smul (1/2:ℝ) + have he : (fun v : E => B v v/2)=((1/2:ℝ) • fun v : E => B v v) := by + ext v; simp only [Pi.smul_apply,smul_eq_mul]; ring + rw [he] + apply H.congr_fderiv + ext v + simp only [smul_apply,add_apply,ContinuousLinearMap.precompR_apply, + ContinuousLinearMap.precompL_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply,smul_eq_mul,id_eq] + rw [hs v z] + ring + convert! ((hbase.sub_const (f x)).sub (f' x).hasFDerivAt).sub hquad using 1 + filter_upwards [Metric.ball_mem_nhds (0:E) hr] with h hh + have hsub : Metric.closedBall (0:E) ‖h‖ ⊆ Metric.ball (0:E) r := by + intro z hz + simp only [Metric.mem_closedBall,Metric.mem_ball,dist_zero_right] at hz hh ⊢ + exact lt_of_le_of_lt hz hh + have H := (convex_closedBall (0:E) ‖h‖).norm_image_sub_le_of_norm_hasFDerivWithin_le + (fun z hz => (hdR z (hsub hz)).hasFDerivWithinAt) + (show ∀ z ∈ Metric.closedBall (0:E) ‖h‖, ‖f' (x+z)-f' x-B z‖≤ε*‖h‖ from by + intro z hz + exact (hball (hsub hz)).2.trans + (mul_le_mul_of_nonneg_left (by simpa only [Metric.mem_closedBall,dist_zero_right] using hz) hε.le)) + (Metric.mem_closedBall_self (norm_nonneg h)) + (show h ∈ Metric.closedBall (0:E) ‖h‖ by simp) + simpa only [hR0,sub_zero,R,add_zero,pow_two,Real.norm_eq_abs,abs_pow, + abs_norm,abs_mul,mul_assoc] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SecondFderivScalarComp.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondFderivScalarComp.lean new file mode 100644 index 0000000000000000000000000000000000000000..0a40c0d968cd9405f3c5de645d7525226eeadcd9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondFderivScalarComp.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSmooth + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma second_fderiv_scalar_comp {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} {φ : ℝ → ℝ} {x : E} (hf : ContDiffAt ℝ 2 f x) + (hφ : ContDiffAt ℝ 2 φ (f x)) (ξ : E) : + fderiv ℝ (fderiv ℝ (fun h => φ (f h))) x ξ ξ = + iteratedDeriv 2 φ (f x)*(fderiv ℝ f x ξ)^2+ + deriv φ (f x)*fderiv ℝ (fderiv ℝ f) x ξ ξ := by + let g := fun t : ℝ => f (x+t • ξ) + have hg : ContDiffAt ℝ 2 g 0 := by + change ContDiffAt ℝ 2 (f ∘ fun t : ℝ => x+t • ξ) 0 + exact (show ContDiffAt ℝ 2 f (x+(0:ℝ) • ξ) from by simpa using hf).comp (0:ℝ) + (contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const)) + have hg0 : g 0=f x := by simp [g] + have hline : HasDerivAt (fun t : ℝ => x+t • ξ) ξ 0 := by + convert! (hasDerivAt_const (0:ℝ) x).add ((hasDerivAt_id (0:ℝ)).smul_const ξ) using 1 + simp + have hd : deriv g 0=fderiv ℝ f x ξ := by + simpa only [Function.comp_def,g,zero_smul,add_zero] using + ((show HasFDerivAt f (fderiv ℝ f x) (x+(0:ℝ) • ξ) from by + simpa only [zero_smul,add_zero] using (hf.differentiableAt (by norm_num)).hasFDerivAt).comp_hasDerivAt (0:ℝ) hline).deriv + have H := iteratedDeriv_comp_two (show ContDiffAt ℝ 2 φ (g 0) from hg0.symm ▸ hφ) hg + rw [hg0,hd,show iteratedDeriv 2 g 0=fderiv ℝ (fderiv ℝ f) x ξ ξ from + iteratedDeriv_two_affine_line hf ξ] at H + change fderiv ℝ (fderiv ℝ (φ ∘ f)) x ξ ξ = _ + rw [←iteratedDeriv_two_affine_line (hφ.comp x hf) ξ] + exact H + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SecondTaylorComposition.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondTaylorComposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..27cf26c120163b12e2bdf6a2690b9c6059112dfc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SecondTaylorComposition.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeJetTest +import OAI.Analysis.BiholderTransport.Calculus.ScalarJetFormula +import OAI.Analysis.BiholderTransport.Calculus.TaylorPositivity + +namespace OAI + +noncomputable section +open Set Filter Asymptotics +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [NormedAddCommGroup F] [InnerProductSpace ℝ F] + +lemma HasSecondTaylor.diagonal_unique {f:E → ℝ} {l:E →L[ℝ] ℝ} + {B C:E →L[ℝ] E →L[ℝ] ℝ} (hB:HasSecondTaylor f l B) (hC:HasSecondTaylor f l C) (d:E) : + B d d=C d d := by + have h1:HasSecondTaylor (fun h=>f h-f h) 0 (B-C):=by simpa only [sub_self] using hB.sub hC + have h2:HasSecondTaylor (fun h=>f h-f h) 0 (C-B):=by simpa only [sub_self] using hC.sub hB + have hm:IsLocalMin (fun h=>f h-f h) 0:=by + exact Eventually.of_forall (fun h=>by simp) + have H1:=h1.nonneg_of_localMin hm d + have H2:=h2.nonneg_of_localMin hm d + simp only [sub_apply] at H1 H2 + linarith + +lemma HasSecondTaylor.congr_of_eventuallyEq {f g:E → ℝ} {l:E →L[ℝ] ℝ} + {B:E →L[ℝ] E →L[ℝ] ℝ} (hf:HasSecondTaylor f l B) (he:g=ᶠ[𝓝 0] f) : + HasSecondTaylor g l B := by + have h0:=he.self_of_nhds + apply hf.congr' _ (Eventually.of_forall (fun _=>rfl)) + filter_upwards [he] with h hh + rw [hh,h0] + +lemma HasQuadraticExpansion.hasSecondTaylor' {f:E → ℝ} {p:E} {A:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) : + HasSecondTaylor f (innerSL ℝ p) ((innerSL ℝ).comp A) := by + have H:=quadratic_expansion_polynomial_remainder hf + unfold HasSecondTaylor + convert H using 1 + funext h + simp only [quadraticTaylor,ContinuousLinearMap.comp_apply,innerSL_apply_apply] + ring + +lemma quadratic_expansion_comp_proxy {f:F → ℝ} {p:F} {A:F →L[ℝ] F} + (hf:HasQuadraticExpansion f p A) {g:E → F} (hg:ContDiffAt ℝ 2 g 0) (hg0:g 0=0) : + let P:=quadraticTaylor (f 0) p A + HasSecondTaylor (fun h=>f (g h)) (fderiv ℝ (fun h=>P (g h)) 0) + (fderiv ℝ (fderiv ℝ (fun h=>P (g h))) 0) := by + let P:=quadraticTaylor (f 0) p A + have hP:ContDiff ℝ 2 P:=by + dsimp only [P,quadraticTaylor] + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + have hQ:ContDiffAt ℝ 2 (fun h=>P (g h)) 0:=hP.contDiffAt.comp 0 hg + apply (hasSecondTaylor_of_contDiffAt hQ).of_littleO_difference + · simp only [hg0,P,quadraticTaylor,map_zero,inner_zero_right,zero_div,add_zero] + · have hgd:HasFDerivAt g (fderiv ℝ g 0) 0:=(hg.differentiableAt (by norm_num)).hasFDerivAt + have ht:Tendsto g (𝓝 0) (𝓝 0):=hg0 ▸ hg.continuousAt.tendsto + have hO:(fun h:E=>‖g h‖)=O[𝓝 0] (fun h=>‖h‖):=by + simpa only [hg0,sub_zero] using hgd.isBigO_sub.norm_left.norm_right + exact ((quadratic_expansion_polynomial_remainder hf).comp_tendsto ht).trans_isBigO (hO.pow 2) + +lemma quadratic_proxy_pullback {f0:ℝ} {p:F} {A:F →L[ℝ] F} + (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) + {g:E → F} (hg:ContDiffAt ℝ 2 g 0) (hg0:g 0=0) : + fderiv ℝ (fderiv ℝ (fun h=>quadraticTaylor f0 p A (g h))) 0= + secondJetPullback (innerSL ℝ p) ((innerSL ℝ).comp A) + (fderiv ℝ g 0) (fderiv ℝ (fderiv ℝ g) 0) := by + have hP:ContDiff ℝ 2 (quadraticTaylor f0 p A):=by + change ContDiff ℝ 2 (fun h:F=>f0+inner ℝ p h+inner ℝ (A h) h/2) + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + ext d e + rw [second_fderiv_comp_at (Eventually.of_forall (fun _=>hP.differentiable (by norm_num) _)) + (((hP.contDiffAt.fderiv_right (m:=1) (by norm_num)).differentiableAt (by norm_num))) hg] + rw [hg0,quadraticTaylor_second_fderiv f0 p hA] + rw [show fderiv ℝ (quadraticTaylor f0 p A) 0=innerSL ℝ p from by + simpa only [map_zero,add_zero] using (quadraticTaylor_hasFDerivAt f0 p hA 0).fderiv] + rfl +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ShortGradientLimit.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortGradientLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd173f591f6c0d3ab072454a57e9423c75d215c7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortGradientLimit.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ParametricLowerSequence + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +lemma parametric_short_gradient_tendsto {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} (L : ℝ≥0) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) + {pj : ℕ → P} {xj : ℕ → Model n} {tj : ℕ → ℝ} {f : ℕ → M → ℝ} + (hp : Tendsto pj atTop (𝓝 p)) (hxx : Tendsto xj atTop (𝓝 x)) + (ht : Tendsto tj atTop (𝓝 0)) (htpos : ∀ᶠ i in atTop,0hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm w)) + (parametricShortForward a ψ ((pj i,tj i),xj i))) : + Tendsto (fun i=>fderiv ℝ + (fun w=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm w)) + (parametricShortForward a ψ ((pj i,tj i),xj i))) atTop + (𝓝 (fderiv ℝ (fun w=>ψ (p,w)) x)) := by + obtain ⟨U,hU,hD,_⟩ := exists_parametric_short_lower_sequence L hx hψ hp hxx ht htpos hlip hbelow htouch + apply hD.congr' + filter_upwards [hU,hd] with i hi hdi + let z := parametricShortForward a ψ ((pj i,tj i),xj i) + let F := fun w=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm w) + have hm : IsLocalMin (fun w=>F w-U i w) z := by + filter_upwards [hi.2.2] with w hw + change F z-U i z≤F w-U i w + rw [hi.2.1] + linarith only [hw] + have he := hm.fderiv_eq_zero + rw [fderiv_fun_sub hdi (hi.1.differentiableAt (by norm_num))] at he + exact (sub_eq_zero.mp he).symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ShortPoleIdentities.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortPoleIdentities.lean new file mode 100644 index 0000000000000000000000000000000000000000..2857e7ad4dc8ddcd203eb7c65f40dfd94ecefa5e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortPoleIdentities.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ShortForward + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] [CompleteSpace P] in +lemma short_family_first_jet_limit {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} {B : (P×ℝ)×Model n → Model n} {U : (P×ℝ)×Model n → ℝ} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hU : ContDiffAt ℝ ∞ U ((p,0),x)) + (hZB : ∀ᶠ q in 𝓝 ((p,0),x),B (q.1,parametricShortForward a ψ q)=q.2) + (hUE : ∀ q,U q=ψ (q.1.1,B q)+q.1.2*parametricShortEnergy a ψ (q.1.1,B q)) : + Tendsto (fun q : (P×ℝ)×Model n => fderiv ℝ (fun w => U (q.1,w)) q.2) + (𝓝 ((p,0),x)) (𝓝 (fderiv ℝ (fun w => ψ (p,w)) x)) := by + have hi : ContinuousAt (fun w : Model n => ((p,(0:ℝ)),w)) x := + continuousAt_const.prodMk continuousAt_id + have hz := hi.eventually hZB + have heq : (fun w => U ((p,0),w))=ᶠ[𝓝 x] (fun w => ψ (p,w)) := by + filter_upwards [hz,(isOpen_extChartAt_target a).mem_nhds hx] with w hw hwc + change B ((p,0),shortForward a (fun v => ψ (p,v)) (0,w))=w at hw + rw [shortForward_zero hwc] at hw + rw [hUE,hw] + simp only [zero_mul,add_zero] + have H := (ContDiffAt.partial_snd_fderiv (f := fun q w => U (q,w)) hU).continuousAt.tendsto + rw [heq.fderiv_eq] at H + exact H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/ShortSmoothFamily.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortSmoothFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..30d23607b0845816c4dc2d157703259b8edc685d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/ShortSmoothFamily.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives + +namespace OAI + + + +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {P E : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +lemma smooth_family_local_inverse {Z : P×E → E} {p : P} {x : E} + (hZ : ContDiffAt ℝ ∞ Z (p,x)) + (hDx : HasFDerivAt (fun y => Z (p,y)) (ContinuousLinearMap.id ℝ E) x) : + ∃ B : P×E → E, ContDiffAt ℝ ∞ B (p,Z (p,x)) ∧ B (p,Z (p,x))=x ∧ + (∀ᶠ q in 𝓝 (p,Z (p,x)),Z (q.1,B q)=q.2) ∧ + (∀ᶠ q in 𝓝 (p,x), B (q.1,Z q)=q.2) ∧ + (∀ᶠ q : (P×E)×E in 𝓝 ((p,Z (p,x)),x), + Z (q.1.1,q.2)=q.1.2 ↔ B q.1=q.2) := by + let F : (P×E)×E → E := fun q => Z (q.1.1,q.2)-q.1.2 + have hF : ContDiffAt ℝ ∞ F ((p,Z (p,x)),x) := + (hZ.comp (f := fun q : (P×E)×E => (q.1.1,q.2)) ((p,Z (p,x)),x) + (contDiffAt_fst.fst.prodMk contDiffAt_snd)).sub contDiffAt_fst.snd + have hFy : HasFDerivAt (fun y => F ((p,Z (p,x)),y)) (ContinuousLinearMap.id ℝ E) x := + hDx.sub_const (Z (p,x)) + have hpart : fderiv ℝ F ((p,Z (p,x)),x) ∘L inr ℝ (P×E) E=ContinuousLinearMap.id ℝ E := by + have H := (hF.differentiableAt (by simp)).hasFDerivAt.comp + (f := fun y => ((p,Z (p,x)),y)) x + ((hasFDerivAt_const (p,Z (p,x)) x).prodMk (hasFDerivAt_id x)) + exact H.unique hFy + have hi : (fderiv ℝ F ((p,Z (p,x)),x) ∘L inr ℝ (P×E) E).IsInvertible := by + rw [hpart] + exact ⟨ContinuousLinearEquiv.refl ℝ E,rfl⟩ + let B := hF.implicitFunction (by simp) hi + have hB : ContDiffAt ℝ ∞ B (p,Z (p,x)) := hF.contDiffAt_implicitFunction (by simp) hi + have hBx : B (p,Z (p,x))=x := hF.implicitFunction_apply_self (by simp) hi + have hiff : ∀ᶠ q : (P×E)×E in 𝓝 ((p,Z (p,x)),x), + Z (q.1.1,q.2)=q.1.2 ↔ B q.1=q.2 := by + filter_upwards [hF.eventually_apply_eq_iff_implicitFunction (by simp) hi] with q hq + simpa only [F,sub_self,sub_eq_zero] using hq + refine ⟨B,hB,hBx,?_,?_,hiff⟩ + · filter_upwards [hF.eventually_apply_implicitFunction (by simp) hi] with q hq + simpa only [F,sub_self,sub_eq_zero] using hq + · have hc : ContinuousAt (fun q : P×E => ((q.1,Z q),q.2)) (p,x) := + (continuousAt_fst.prodMk hZ.continuousAt).prodMk continuousAt_snd + filter_upwards [hc.eventually hiff] with q hq + exact hq.mp rfl + +lemma parametric_smooth_short_action {Z : (P×ℝ)×E → E} {ψ K : P×E → ℝ} + {p : P} {x : E} (hZ : ContDiffAt ℝ ∞ Z ((p,0),x)) + (hZ0 : ∀ᶠ y in 𝓝 x,Z ((p,0),y)=y) + (hψ : ContDiffAt ℝ ∞ ψ (p,x)) (hK : ContDiffAt ℝ ∞ K (p,x)) : + ∃ (B : (P×ℝ)×E → E) (U : (P×ℝ)×E → ℝ), + ContDiffAt ℝ ∞ B ((p,0),x) ∧ ContDiffAt ℝ ∞ U ((p,0),x) ∧ B ((p,0),x)=x ∧ + (∀ᶠ q in 𝓝 ((p,0),x),Z (q.1,B q)=q.2) ∧ + (∀ᶠ q in 𝓝 ((p,0),x),B (q.1,Z q)=q.2) ∧ + (∀ q,U q=ψ (q.1.1,B q)+q.1.2*K (q.1.1,B q)) ∧ + Tendsto (fun q : (P×ℝ)×E => fderiv ℝ (fderiv ℝ (fun y => U (q.1,y))) q.2) + (𝓝 ((p,0),x)) (𝓝 (fderiv ℝ (fderiv ℝ (fun y => ψ (p,y))) x)) := by + have hDx : HasFDerivAt (fun y => Z ((p,0),y)) (ContinuousLinearMap.id ℝ E) x := + (hasFDerivAt_id (𝕜 := ℝ) x).congr_of_eventuallyEq hZ0 + obtain ⟨B,hB,hBx,hBZ,hZB,hiff⟩ := smooth_family_local_inverse hZ hDx + have hx0 := hZ0.self_of_nhds + rw [hx0] at hB hBx hBZ hiff + let U : (P×ℝ)×E → ℝ := fun q => ψ (q.1.1,B q)+q.1.2*K (q.1.1,B q) + have hbq : ContDiffAt ℝ ∞ (fun q : (P×ℝ)×E => (q.1.1,B q)) ((p,0),x) := + contDiffAt_fst.fst.prodMk hB + have hU : ContDiffAt ℝ ∞ U ((p,0),x) := by + have hpψ : ContDiffAt ℝ ∞ ψ (p,B ((p,0),x)) := by rwa [hBx] + have hpK : ContDiffAt ℝ ∞ K (p,B ((p,0),x)) := by rwa [hBx] + exact (hpψ.comp (f := fun q : (P×ℝ)×E => (q.1.1,B q)) ((p,0),x) hbq).add + (contDiffAt_fst.snd.mul (hpK.comp (f := fun q : (P×ℝ)×E => (q.1.1,B q)) ((p,0),x) hbq)) + have hU0 : (fun y => U ((p,0),y))=ᶠ[𝓝 x] (fun y => ψ (p,y)) := by + have hc : ContinuousAt (fun y : E => ((p,(0:ℝ)),y)) x := + continuousAt_const.prodMk continuousAt_id + filter_upwards [hc.eventually hZB,hZ0] with y hy hz + rw [hz] at hy + simp only [U,hy,zero_mul,add_zero] + refine ⟨B,U,hB,hU,hBx,hBZ,hZB,fun _ => rfl,?_⟩ + have H := (ContDiffAt.partial_snd_fderiv_two (f := fun q y => U (q,y)) hU).continuousAt.tendsto + rwa [hU0.fderiv.fderiv_eq] at H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SliceDerivatives.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SliceDerivatives.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a52c320a5ab0e302be9a5d5b553e75679cc7dfc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SliceDerivatives.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitAction +import OAI.Analysis.BiholderTransport.Coordinates.BranchInverse +import OAI.Analysis.BiholderTransport.Calculus.JetPullback +import OAI.Analysis.BiholderTransport.Coordinates.FiberLog + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {E F G : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + [NormedAddCommGroup G] [NormedSpace ℝ G] + +lemma fderiv_snd_slice {f : F×E → G} {a : F} {b : E} + (hf : DifferentiableAt ℝ f (a,b)) (k : E) : + fderiv ℝ (fun v : E => f (a,v)) b k=fderiv ℝ f (a,b) (0,k) := by + have H := hf.hasFDerivAt.comp (f := fun v : E => (a,v)) b + ((hasFDerivAt_const a b).prodMk (hasFDerivAt_id (𝕜 := ℝ) b)) + have HH := congrArg (fun L : E →L[ℝ] G => L k) H.fderiv + simpa only [Function.comp_def, ContinuousLinearMap.comp_apply, ContinuousLinearMap.prod_apply, + zero_apply, ContinuousLinearMap.id_apply] using HH + +lemma second_fderiv_snd_slice {f : F×E → ℝ} {a : F} {b : E} + (hf : ContDiffAt ℝ 2 f (a,b)) (v w : E) : + fderiv ℝ (fderiv ℝ (fun t : E => f (a,t))) b v w= + fderiv ℝ (fderiv ℝ f) (a,b) (0,v) (0,w) := by + let I : E →L[ℝ] F×E := (0:E →L[ℝ] F).prod (ContinuousLinearMap.id ℝ E) + have H := second_fderiv_comp_affine I (a,0) b (by simpa [I] using hf) v w + simpa [I] using H + +lemma second_fderiv_map_fst {B : F×G → ℝ} {e : E → F} {x : E} {y : G} + (hB : ContDiffAt ℝ 2 B (e x,y)) (he : ContDiffAt ℝ 2 e x) (d : E) (k : G) : + fderiv ℝ (fderiv ℝ (fun q : E×G => B (e q.1,q.2))) (x,y) (d,0) (0,k)= + fderiv ℝ (fderiv ℝ B) (e x,y) (fderiv ℝ e x d,0) (0,k) := by + let A := fun q : E×G => B (e q.1,q.2) + have hA : ContDiffAt ℝ 2 A (x,y) := + hB.comp (x,y) ((he.comp (x,y) contDiffAt_fst).prodMk contDiffAt_snd) + have hdA := (((hA.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun a : E => (a,y)) x + ((hasFDerivAt_id (𝕜 := ℝ) x).prodMk (hasFDerivAt_const y x))).clm_apply + (hasFDerivAt_const ((0:E),k) x) + have hdB := (((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun a : E => (e a,y)) x + ((he.differentiableAt (by norm_num)).hasFDerivAt.prodMk (hasFDerivAt_const y x))).clm_apply + (hasFDerivAt_const ((0:F),k) x) + have hnA : ∀ᶠ a in 𝓝 x, ContDiffAt ℝ 2 A (a,y) := + (continuousAt_id.prodMk continuousAt_const).eventually (hA.eventually (by norm_num)) + have hnB : ∀ᶠ a in 𝓝 x, ContDiffAt ℝ 2 B (e a,y) := + (he.continuousAt.prodMk continuousAt_const).eventually (hB.eventually (by norm_num)) + have heq : (fun a : E => fderiv ℝ A (a,y) (0,k)) =ᶠ[𝓝 x] + (fun a => fderiv ℝ B (e a,y) (0,k)) := by + filter_upwards [hnA,hnB] with a ha hb + rw [←fderiv_snd_slice (ha.differentiableAt (by norm_num)) k, + ←fderiv_snd_slice (hb.differentiableAt (by norm_num)) k] + have H := congrArg (fun L : E →L[ℝ] ℝ => L d) + ((hdA.congr_of_eventuallyEq heq.symm).unique hdB) + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,ContinuousLinearMap.flip_apply,map_zero,zero_apply, + add_apply,add_zero,zero_add] using H + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_joining_selector {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : p∈injectivityDomain x) (ht : 0 < t) (ht1 : t < 1) : + ∃ b : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) x, + ContDiffAt ℝ ∞ b 0 ∧ b 0=p ∧ + (∀ᶠ a in 𝓝 0, normalCost x p a=splitNormalAction x t p (a,b a)) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + let y := riemannianExp x p + obtain ⟨P,hP,hP0,_,hPinv⟩ := exists_smooth_exp_branch z + (riemannianExp_interior_nonconjugate hp) + let Q : V → TangentBundle 𝓘(ℝ,Model n) M := fun a => P (riemannianExp x a,y) + have hQ0 : Q 0=z := by dsimp [Q]; rw [riemannianExp_zero]; exact hP0 + have hmap : ContMDiffAt 𝓘(ℝ,V) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun a : V => (riemannianExp x a,y)) 0 := + (contMDiff_riemannianExp_fiber x 0).prodMk contMDiffAt_const + have hQ : ContMDiffAt 𝓘(ℝ,V) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Q 0 := by + exact (show ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P (riemannianExp x (0:V),y) from by + simpa only [riemannianExp_zero] using hP).comp 0 hmap + let Z : V → M := fun a => (sprayFlow t (Q a)).1 + have hZ : ContMDiffAt 𝓘(ℝ,V) 𝓘(ℝ,Model n) ∞ Z 0 := + (Bundle.contMDiff_proj (fun w : M => TangentSpace 𝓘(ℝ,Model n) w)).contMDiffAt.comp 0 + (contMDiff_sprayFlow.contMDiffAt.comp 0 (contMDiffAt_const.prodMk hQ)) + have hZ0 : Z 0=riemannianExp x (t • p) := by + dsimp only [Z]; rw [hQ0]; exact (riemannianExp_smul x p t).symm + have hpre := contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors x hp) ht ht1 + obtain ⟨L,hL,hL0,hLinv⟩ := exists_smooth_fiber_log hpre + let b : V → V := fun a => t⁻¹ • L (Z a) + have hb : ContDiffAt ℝ ∞ b 0 := + ((contDiffAt_const (c := t⁻¹)).smul ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ L (Z 0) from + hZ0 ▸ hL).comp 0 hZ).contDiffAt) + have hb0 : b 0=p := by simp only [b,hZ0,hL0,smul_smul,inv_mul_cancel₀ ht.ne',one_smul] + refine ⟨b,hb,hb0,?_⟩ + have hQmin : ∀ᶠ a in 𝓝 (0:V), (Q a).2∈injectivityDomain (Q a).1 := + hQ.continuousAt.eventually (show {r : TangentBundle 𝓘(ℝ,Model n) M | + r.2∈injectivityDomain r.1}∈𝓝 (Q 0) from by + rw [hQ0]; exact isOpen_total_injectivityDomain.mem_nhds hp) + have hQi : ∀ᶠ a in 𝓝 (0:V), (Q a).1=riemannianExp x a ∧ + riemannianExp (Q a).1 (Q a).2=y := by + have H := hmap.continuousAt.eventually (show ∀ᶠ w in 𝓝 (riemannianExp x (0:V),y), + (P w).1=w.1 ∧ riemannianExp (P w).1 (P w).2=w.2 from by + simpa only [riemannianExp_zero] using hPinv) + exact H + have hZi : ∀ᶠ a in 𝓝 (0:V), riemannianExp x (t • b a)=Z a := by + have H := hZ.continuousAt.eventually (show ∀ᶠ w in 𝓝 (Z 0), riemannianExp x (L w)=w from + hZ0 ▸ hLinv) + simpa only [b,smul_smul,mul_inv_cancel₀ ht.ne',one_smul] using H + filter_upwards [hQmin,hQi,hZi] with a ha hi hz + have H := splitNormalAction_contact (injectivityDomain_subset_minimizingVectors _ ha) ht ht1 + simp only [splitNormalAction,normalCost,riemannianExp_zero] at H + rw [riemannianExp_smul] at H + change cost (Q a).1 (Z a)/t+cost (Z a) (riemannianExp (Q a).1 (Q a).2)/(1-t)= + cost (Q a).1 (riemannianExp (Q a).1 (Q a).2) at H + rw [hi.2,hi.1] at H + change cost (riemannianExp x a) y = + cost (riemannianExp x a) (riemannianExp x (t • b a))/t+ + cost (riemannianExp x (t • b a)) y/(1-t) + rw [hz] + exact H.symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothDistance.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothDistance.lean new file mode 100644 index 0000000000000000000000000000000000000000..6471ffcd43c86dc9067ccf3a58fd69a742938a25 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothDistance.lean @@ -0,0 +1,144 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Coordinates + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +local instance smoothDistanceNormedSpace : NormedSpace ℝ E := + InnerProductSpace.toNormedSpace +local instance smoothDistanceNormedAddCommGroupEndomorphism : + NormedAddCommGroup (E →L[ℝ] E) := ContinuousLinearMap.toNormedAddCommGroup +local instance smoothDistanceNormedSpaceEndomorphism : + NormedSpace ℝ (E →L[ℝ] E) := ContinuousLinearMap.toNormedSpace +local instance smoothDistanceNormedAddCommGroupDual : + NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance smoothDistanceNormedSpaceDual : + NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance smoothDistanceNormedAddCommGroupBilinear : + NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance smoothDistanceNormedSpaceBilinear : + NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + +lemma derivative_pullback_metric + {g h : E → E →L[ℝ] E →L[ℝ] ℝ} {φ : E → E} {x : E} + (hg : DifferentiableAt ℝ g x) (hh : DifferentiableAt ℝ h (φ x)) + (hφ : DifferentiableAt ℝ φ x) (hDφ : DifferentiableAt ℝ (fderiv ℝ φ) x) + (hmetric : ∀ᶠ y in 𝓝 x, ∀ u v, g y u v = h (φ y) (fderiv ℝ φ y u) (fderiv ℝ φ y v)) + (w u v : E) : + fderiv ℝ g x w u v = + fderiv ℝ h (φ x) (fderiv ℝ φ x w) (fderiv ℝ φ x u) (fderiv ℝ φ x v) + + h (φ x) (fderiv ℝ (fderiv ℝ φ) x w u) (fderiv ℝ φ x v) + + h (φ x) (fderiv ℝ φ x u) (fderiv ℝ (fderiv ℝ φ) x w v) := by + have hleft := (hg.hasFDerivAt.clm_apply (hasFDerivAt_const u x)).clm_apply + (hasFDerivAt_const v x) + have hright := ((hh.hasFDerivAt.comp x hφ.hasFDerivAt).clm_apply + (hDφ.hasFDerivAt.clm_apply (hasFDerivAt_const u x))).clm_apply + (hDφ.hasFDerivAt.clm_apply (hasFDerivAt_const v x)) + have heq : (fun y => g y u v) =ᶠ[𝓝 x] + (fun y => h (φ y) (fderiv ℝ φ y u) (fderiv ℝ φ y v)) := by + filter_upwards [hmetric] with y hy; exact hy u v + have he := congrArg (fun L : E →L[ℝ] ℝ => L w) + ((hleft.congr_of_eventuallyEq heq.symm).unique hright) + simpa [add_assoc,add_comm,add_left_comm] using he + +lemma christoffel_pushforward_pairing + {g h : E → E →L[ℝ] E →L[ℝ] ℝ} {φ : E → E} {x : E} + (hg : DifferentiableAt ℝ g x) (hh : DifferentiableAt ℝ h (φ x)) + (hφ : ContDiffAt ℝ ∞ φ x) + (hmetric : ∀ᶠ y in 𝓝 x, ∀ u v, g y u v = h (φ y) (fderiv ℝ φ y u) (fderiv ℝ φ y v)) + (hgi : (g x).IsInvertible) (hhi : (h (φ x)).IsInvertible) + (hhs : ∀ u v, h (φ x) u v = h (φ x) v u) (u v w : E) : + h (φ x) (fderiv ℝ φ x (coordinateChristoffel g x u v)) (fderiv ℝ φ x w) = + h (φ x) (fderiv ℝ (fderiv ℝ φ) x u v + + coordinateChristoffel h (φ x) (fderiv ℝ φ x u) (fderiv ℝ φ x v)) + (fderiv ℝ φ x w) := by + have hpd := hφ.differentiableAt (by simp) + have hD := (hφ.fderiv_right (m := ∞) (by simp)).differentiableAt (by simp) + have hp := derivative_pullback_metric hg hh hpd hD hmetric + have hm := hmetric.self_of_nhds + have hb : ∀ u v, fderiv ℝ (fderiv ℝ φ) x u v = fderiv ℝ (fderiv ℝ φ) x v u := by + intro u v + exact (hφ.isSymmSndFDerivAt (by simp)).eq u v + have h1 := coordinateChristoffel_metric g x u v w hgi + have h2 := coordinateChristoffel_metric h (φ x) (fderiv ℝ φ x u) + (fderiv ℝ φ x v) (fderiv ℝ φ x w) hhi + rw [hm,hp u v w,hp v u w,hp w u v] at h1 + rw [hb v u,hb w u,hb w v] at h1 + rw [hhs (fderiv ℝ φ x v) _,hhs (fderiv ℝ φ x u) _] at h1 + simp only [map_add,add_apply] + linarith + +lemma christoffel_pushforward + {g h : E → E →L[ℝ] E →L[ℝ] ℝ} {φ : E → E} {x : E} + (hg : DifferentiableAt ℝ g x) (hh : DifferentiableAt ℝ h (φ x)) + (hφ : ContDiffAt ℝ ∞ φ x) (hφs : Function.Surjective (fderiv ℝ φ x)) + (hmetric : ∀ᶠ y in 𝓝 x, ∀ u v, g y u v = h (φ y) (fderiv ℝ φ y u) (fderiv ℝ φ y v)) + (hgi : (g x).IsInvertible) (hhi : (h (φ x)).IsInvertible) + (hhs : ∀ u v, h (φ x) u v = h (φ x) v u) (u v : E) : + fderiv ℝ φ x (coordinateChristoffel g x u v) = + fderiv ℝ (fderiv ℝ φ) x u v + + coordinateChristoffel h (φ x) (fderiv ℝ φ x u) (fderiv ℝ φ x v) := by + have heq : h (φ x) (fderiv ℝ φ x (coordinateChristoffel g x u v)) = + h (φ x) (fderiv ℝ (fderiv ℝ φ) x u v + + coordinateChristoffel h (φ x) (fderiv ℝ φ x u) (fderiv ℝ φ x v)) := by + ext w + obtain ⟨z,rfl⟩ := hφs w + exact christoffel_pushforward_pairing hg hh hφ hmetric hgi hhi hhs u v z + rcases hhi with ⟨A,hA⟩ + apply A.injective + change A.toContinuousLinearMap _ = A.toContinuousLinearMap _ + rw [hA] + exact heq +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothExtensionNear.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothExtensionNear.lean new file mode 100644 index 0000000000000000000000000000000000000000..33e8327708ca8378f74bd8d0d15153970956645c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/SmoothExtensionNear.lean @@ -0,0 +1,74 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +namespace WeakMTWTransport + +lemma exists_smooth_extension_near {E F : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] [HasContDiffBump E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {f : E → F} {S : Set E} (hS : IsOpen S) (hf : ContDiffOn ℝ ∞ f S) + {a : E} (ha : a ∈ S) : + ∃ g : E → F, ContDiff ℝ ∞ g ∧ g =ᶠ[𝓝 a] f := by + obtain ⟨r,hr,hrS⟩ := Metric.mem_nhds_iff.mp (hS.mem_nhds ha) + let b : ContDiffBump a := ⟨r/4,r/2,by positivity,by linarith⟩ + let g : E → F := fun x => b x • f x + have hbS : tsupport b ⊆ S := by + rw [b.tsupport_eq] + intro x hx + apply hrS + change dist x a < r + have h : dist x a ≤ r/2 := hx + linarith + refine ⟨g,?_,?_⟩ + · rw [contDiff_iff_contDiffAt] + intro x + by_cases hx : x ∈ tsupport b + · exact b.contDiff.contDiffAt.smul (hf.contDiffAt (hS.mem_nhds (hbS hx))) + · have heq : g =ᶠ[𝓝 x] 0 := by + filter_upwards [notMem_tsupport_iff_eventuallyEq.mp hx] with y hy + change b y • f y = 0 + simp only [hy,Pi.zero_apply,zero_smul] + exact contDiffAt_const.congr_of_eventuallyEq heq + · filter_upwards [b.eventuallyEq_one] with x hx + change b x • f x = f x + simpa only [Pi.one_apply,one_smul] using congrArg (fun z : ℝ => z • f x) hx + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorAlgebra.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorAlgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..1f41ac8cc118fccb96d9fd68038bb266182f3c2f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorAlgebra.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Pole + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +def SecondTaylorRemainder (f : E → ℝ) (D : E →L[ℝ] ℝ) + (K : E →L[ℝ] E →L[ℝ] ℝ) : Prop := + (fun h => f h-f 0-D h-K h h/2) =o[𝓝 0] (fun h : E => ‖h‖^2) + +lemma SecondTaylorRemainder.sub {f g : E → ℝ} {D D' : E →L[ℝ] ℝ} + {K K' : E →L[ℝ] E →L[ℝ] ℝ} (hf : SecondTaylorRemainder f D K) + (hg : SecondTaylorRemainder g D' K') : + SecondTaylorRemainder (fun h => f h-g h) (D-D') (K-K') := by + unfold SecondTaylorRemainder at * + convert! hf.sub hg using 1 + funext h + simp only [sub_apply] + ring + +lemma SecondTaylorRemainder.const_mul {f : E → ℝ} {D : E →L[ℝ] ℝ} + {K : E →L[ℝ] E →L[ℝ] ℝ} (hf : SecondTaylorRemainder f D K) (c : ℝ) : + SecondTaylorRemainder (fun h => c*f h) (c • D) (c • K) := by + unfold SecondTaylorRemainder at * + convert! hf.const_mul_left c using 1 + funext h + simp only [smul_apply,smul_eq_mul] + ring + +lemma SecondTaylorRemainder.sum {ι : Type*} (s : Finset ι) + {f : ι → E → ℝ} {D : ι → E →L[ℝ] ℝ} {K : ι → E →L[ℝ] E →L[ℝ] ℝ} + (hf : ∀ i ∈ s, SecondTaylorRemainder (f i) (D i) (K i)) : + SecondTaylorRemainder (fun h => ∑ i ∈ s, f i h) (∑ i ∈ s, D i) (∑ i ∈ s, K i) := by + unfold SecondTaylorRemainder at * + have H := Asymptotics.IsLittleO.sum hf + convert! H using 1 + funext h + simp only [Finset.sum_apply,sum_apply,Finset.sum_sub_distrib,Finset.sum_div] + +lemma SecondTaylorRemainder.comp_linear {f : F → ℝ} {D : F →L[ℝ] ℝ} + {K : F →L[ℝ] F →L[ℝ] ℝ} (hf : SecondTaylorRemainder f D K) (T : E →L[ℝ] F) : + SecondTaylorRemainder (fun h => f (T h)) (D.comp T) (K.bilinearComp T T) := by + have H := second_order_substitution_exact_linear hf (map_zero T) (T.hasFDerivAt (x := 0)) + simpa only [SecondTaylorRemainder,map_zero,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.bilinearComp_apply] using H + + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorBound.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..ede57ca4bf67689af2933bb2e220f9d18f82fa8d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorBound.lean @@ -0,0 +1,123 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +section TaylorBound +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma second_order_remainder_bound_on_ball {f : E → ℝ} {r ε : ℝ} + (hr : 0 < r) (hε : 0 ≤ ε) + (hf : ∀ z ∈ Metric.ball (0:E) r, ContDiffAt ℝ 2 f z) + (hB : ∀ z ∈ Metric.ball (0:E) r, + ‖fderiv ℝ (fderiv ℝ f) z - fderiv ℝ (fderiv ℝ f) 0‖ ≤ ε) + {h : E} (hh : h ∈ Metric.ball (0:E) r) : + |f h - f 0 - fderiv ℝ f 0 h - fderiv ℝ (fderiv ℝ f) 0 h h / 2| ≤ ε * ‖h‖^2 := by + let D := fderiv ℝ f 0 + let B := fderiv ℝ (fderiv ℝ f) 0 + let R : E → ℝ := fun z => f z - f 0 - D z - B z z / 2 + let R' : E → E →L[ℝ] ℝ := fun z => fderiv ℝ f z - D - B z + have h0 : (0:E) ∈ Metric.ball (0:E) r := Metric.mem_ball_self hr + have hs : ∀ v w, B v w = B w v := + fun v w => ((hf 0 h0).isSymmSndFDerivAt (by norm_num)).eq v w + have hdR' : ∀ z ∈ Metric.ball (0:E) r, + HasFDerivAt R' (fderiv ℝ (fderiv ℝ f) z - B) z := by + intro z hz + exact ((((hf z hz).fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.sub_const D).sub B.hasFDerivAt + have hR' : ∀ z ∈ Metric.ball (0:E) r, ‖R' z‖ ≤ ε * ‖z‖ := by + intro z hz + have H := (convex_ball (0:E) r).norm_image_sub_le_of_norm_hasFDerivWithin_le + (fun z hz => (hdR' z hz).hasFDerivWithinAt) hB h0 hz + simpa only [R',D,B,map_zero,sub_self,sub_zero] using H + have hdR : ∀ z ∈ Metric.ball (0:E) r, HasFDerivAt R (R' z) z := by + intro z hz + have hquad : HasFDerivAt (fun v : E => B v v / 2) (B z) z := by + have H := (B.hasFDerivAt_of_bilinear (hasFDerivAt_id z) (hasFDerivAt_id z)).const_smul (1/2:ℝ) + have he : (fun v : E => B v v / 2) = ((1/2:ℝ) • fun v : E => B v v) := by + ext v + simp only [Pi.smul_apply,smul_eq_mul] + ring + rw [he] + apply H.congr_fderiv + ext v + simp only [_root_.smul_apply,_root_.add_apply,ContinuousLinearMap.precompR_apply, + ContinuousLinearMap.precompL_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply,smul_eq_mul,id_eq] + rw [hs v z] + ring + exact (((hf z hz).differentiableAt (by norm_num)).hasFDerivAt.sub_const (f 0) + |>.sub D.hasFDerivAt |>.sub hquad) + have hsub : Metric.closedBall (0:E) ‖h‖ ⊆ Metric.ball (0:E) r := by + intro z hz + simp only [Metric.mem_closedBall,Metric.mem_ball,dist_zero_right] at hz hh ⊢ + exact lt_of_le_of_lt hz hh + have H := (convex_closedBall (0:E) ‖h‖).norm_image_sub_le_of_norm_hasFDerivWithin_le + (fun z hz => (hdR z (hsub hz)).hasFDerivWithinAt) + (show ∀ z ∈ Metric.closedBall (0:E) ‖h‖, ‖R' z‖ ≤ ε * ‖h‖ from by + intro z hz + apply (hR' z (hsub hz)).trans + exact mul_le_mul_of_nonneg_left (by simpa only [Metric.mem_closedBall,dist_zero_right] using hz) hε) + (Metric.mem_closedBall_self (norm_nonneg h)) + (show h ∈ Metric.closedBall (0:E) ‖h‖ by simp) + simpa only [R,D,B,map_zero,_root_.zero_apply,zero_div,sub_self,sub_zero,Real.norm_eq_abs, + pow_two,mul_assoc] using H + +end TaylorBound + +variable {E P : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [TopologicalSpace P] [CompactSpace P] + +lemma compact_parametric_second_order_remainder + (f : P → E → ℝ) + (hf : ∀ a : P, ∀ᶠ q : E × P in 𝓝 (0,a), ContDiffAt ℝ 2 (f q.2) q.1) + (hD : ∀ a : P, ContinuousAt (fun q : E × P => fderiv ℝ (fderiv ℝ (f q.2)) q.1) (0,a)) + {ε : ℝ} (hε : 0 < ε) : + ∀ᶠ h : E in 𝓝 0, ∀ a : P, + |f a h - f a 0 - fderiv ℝ (f a) 0 h - + fderiv ℝ (fderiv ℝ (f a)) 0 h h / 2| ≤ ε * ‖h‖^2 := by + have hloc : ∀ a ∈ (univ : Set P), ∀ᶠ q : E × P in 𝓝 (0,a), + ContDiffAt ℝ 2 (f q.2) q.1 ∧ + ‖fderiv ℝ (fderiv ℝ (f q.2)) q.1 - fderiv ℝ (fderiv ℝ (f q.2)) 0‖ ≤ ε := by + intro a _ + have hc0 : ContinuousAt (fun q : E × P => ((0:E),q.2)) ((0:E),a) := + continuousAt_const.prodMk continuousAt_snd + have hcB0 : ContinuousAt (fun q : E × P => + fderiv ℝ (fderiv ℝ (f q.2)) 0) (0,a) := + by + simpa only [Function.comp_def] using (hD a).comp (x := ((0:E),a)) (f := fun q : E × P => ((0:E),q.2)) hc0 + have hc : ContinuousAt (fun q : E × P => + ‖fderiv ℝ (fderiv ℝ (f q.2)) q.1 - fderiv ℝ (fderiv ℝ (f q.2)) 0‖) (0,a) := + by + have hh : ContinuousAt (fun q : E × P => + fderiv ℝ (fderiv ℝ (f q.2)) q.1 - fderiv ℝ (fderiv ℝ (f q.2)) (0:E)) ((0:E),a) := + (hD a).sub hcB0 + exact @ContinuousAt.norm (E × P) (E →L[ℝ] E →L[ℝ] ℝ) _ _ _ _ hh + have he : ∀ᶠ q : E × P in 𝓝 (0,a), + ‖fderiv ℝ (fderiv ℝ (f q.2)) q.1 - fderiv ℝ (fderiv ℝ (f q.2)) 0‖ < ε := + hc.eventually_lt continuousAt_const (by simpa only [sub_self, ContinuousLinearMap.opNorm_zero] using hε) + exact (hf a).and (he.mono (fun _ h => h.le)) + have he : ∀ᶠ h : E in 𝓝 0, ∀ a ∈ (univ : Set P), + ContDiffAt ℝ 2 (f a) h ∧ + ‖fderiv ℝ (fderiv ℝ (f a)) h - fderiv ℝ (fderiv ℝ (f a)) 0‖ ≤ ε := + isCompact_univ.eventually_forall_of_forall_eventually hloc + obtain ⟨r,hr,hball⟩ := Metric.eventually_nhds_iff.mp he + filter_upwards [Metric.ball_mem_nhds (0:E) hr] with h hh + intro a + apply second_order_remainder_bound_on_ball hr hε.le + · intro z hz + exact (hball (y := z) hz a (mem_univ a)).1 + · intro z hz + exact (hball (y := z) hz a (mem_univ a)).2 + · exact hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorPositivity.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorPositivity.lean new file mode 100644 index 0000000000000000000000000000000000000000..fca97bca2088b5ae7d11a801a305020017dbd2ce --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/TaylorPositivity.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.FullSet + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma HasSecondTaylor.nonneg_of_localMin {f : E → ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f 0 B) + (hm : IsLocalMin f 0) (v:E) : 0≤B v v := by + by_contra hn + have hB : B v v<0 := lt_of_not_ge hn + have hv : v≠0 := by + intro he; subst v; simp at hB + have hnv : 0<‖v‖^2 := sq_pos_of_pos (norm_pos_iff.mpr hv) + let ε := -(B v v)/(4*‖v‖^2) + have hε : 0<ε := div_pos (neg_pos.mpr hB) (by positivity) + have hεeq : ε*‖v‖^2 = -(B v v)/4 := by + dsimp [ε]; field_simp + obtain ⟨r,hr,H⟩ := Metric.eventually_nhds_iff.mp ((hf.eventually hε).and hm) + let δ := r/(2*(‖v‖+1)) + have hδ : 0<δ := div_pos hr (by positivity) + have hδeq : δ*(2*(‖v‖+1))=r := div_mul_cancel₀ _ (by positivity) + have hmem : δ • v∈Metric.ball (0:E) r := by + rw [Metric.mem_ball,dist_zero_right,norm_smul,Real.norm_eq_abs,abs_of_pos hδ] + nlinarith [norm_nonneg v] + obtain ⟨ht,hm'⟩ := H hmem + have hbil : B (δ • v) (δ • v)=δ^2*B v v := by + simp only [map_smul,smul_apply,smul_eq_mul]; ring + have hnorm : ‖δ • v‖^2=δ^2*‖v‖^2 := by + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hδ,mul_pow] + rw [hbil,hnorm] at ht + simp only [zero_apply,sub_zero] at ht + have hupper := (abs_le.mp ht).2 + have hmul : ε*(δ^2*‖v‖^2)=δ^2*(-(B v v)/4) := by + calc + _=δ^2*(ε*‖v‖^2) := by ring + _=_ := by rw [hεeq] + rw [hmul] at hupper + have hneg := mul_neg_of_pos_of_neg (sq_pos_of_pos hδ) hB + change f 0≤f (δ • v) at hm' + nlinarith +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterGradient.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..04f1c7e7a30f6cb167ede837a10b1919039057b9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterGradient.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveDifferentiability +import OAI.Analysis.BiholderTransport.Coordinates.Taylor +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.Contact.LocalCEMS +import OAI.Analysis.BiholderTransport.Contact.CenterSupportFamily + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma reverse_minimizer_eq {a c:M} + {r:TangentSpace 𝓘(ℝ,Model n) c} {q:TangentSpace 𝓘(ℝ,Model n) a} + (hr:r∈injectivityDomain c) (hq:q∈minimizingVectors a) + (ha:riemannianExp c r=a) (hc:riemannianExp a q=c) : + reverseRay (⟨c,r⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩ := by + let z:TangentBundle 𝓘(ℝ,Model n) M:=⟨c,r⟩ + have hb:(reverseRay z).1=a:=(reverseRay_base z).trans ha + have hR:=reverseRay_regular (z:=z) hr + have hE:=reverseRay_endpoint z + generalize hw:reverseRay z=w + rw [hw] at hb hR hE + rcases w with ⟨b,p⟩ + change b=a at hb + subst b + have he:=riemannianExp_interior_unique hR hq (hE.trans hc.symm) + exact congrArg (fun v:TangentSpace 𝓘(ℝ,Model n) a=>(⟨a,v⟩:TangentBundle 𝓘(ℝ,Model n) M)) he + +lemma NormalAlexandrovContact.active_eq {u:M → ℝ} (hu:Continuous u) {y:M} + {p r:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) (hr:r∈activeLogs u y) : r=p := by + have H:=activeLog_derivative_eq hu hr hA.2.2.2.hasFDerivAt + apply ext_inner_right ℝ + intro d + exact (congrArg (fun L:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ=>L d) H).symm + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma TrueCenterRow.active {c:M} {u v:M → ℝ} (hdual:IsCostDualPair u v) + {φ:ℝ → ℝ} {x:Model n} {z:M} {τ l:ℝ} (R:TrueCenterRow c u v φ x z τ l) : + chartFiberInverse c x R.r∈activeLogs u ((extChartAt 𝓘(ℝ,Model n) c).symm x) := by + refine ⟨R.minimizing,?_⟩ + have H:=R.contact + rw [movingNormal_eq R.chart] at H + simpa only [contactGap,hdual.2,chartFiberInverse] using H + +lemma quadratic_scalar_gradient {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {f:E → ℝ} {p s:E} {A S:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) {φ:ℝ → ℝ} {l:ℝ} + (hφ:HasDerivAt φ l (f 0)) + (hS:HasQuadraticExpansion (fun h=>φ (f h)) s S) : s=l • p := by + have H:=hS.hasFDerivAt.unique (hφ.comp_hasFDerivAt 0 hf.hasFDerivAt) + apply ext_inner_right ℝ + intro d + have HH:=congrArg (fun L:E →L[ℝ] ℝ=>L d) H + simpa only [innerSL_apply_apply,smul_apply,smul_eq_mul, + real_inner_smul_left] using HH + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterJet.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..6360fd7781277b01eaa83744fc12375ac870b449 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/TrueCenterJet.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ChartCenterGain + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TrueCenterJet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance trueCenterJetFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +structure TrueCenterJet (u:M → ℝ) (a c:M) (φ:ℝ → ℝ) (l:ℝ) where + y : M + b : Model n + q : Model n + chart : b∈(extChartAt 𝓘(ℝ,Model n) a).target + regular : chartFiberInverse a b q∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b) + endpoint : movingPrefix a 1 b q=y + endChart : y∈(extChartAt 𝓘(ℝ,Model n) c).source + p : TangentSpace 𝓘(ℝ,Model n) y + A : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y + original : NormalAlexandrovContact (n:=n) u y p A + positive : ∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d + pole : riemannianExp y (l • p)=(extChartAt 𝓘(ℝ,Model n) a).symm b + smooth : ContDiffAt ℝ 2 φ (cTransform u y) + slope : deriv φ (cTransform u y)=l + s : Model n + S : Model n →L[ℝ] Model n + symmetric : ∀d e,inner ℝ (S d) e=inner ℝ d (S e) + expansion : HasQuadraticExpansion (fun h=>φ (cTransform u ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c y+h)))) s S + +def TrueCenterJet.fullRay {u:M → ℝ} {a c:M} {φ:ℝ → ℝ} {l:ℝ} + (J:TrueCenterJet (n:=n) u a c φ l) : TangentBundle 𝓘(ℝ,Model n) M:=⟨J.y,J.p⟩ +def TrueCenterJet.shortRay {u:M → ℝ} {a c:M} {φ:ℝ → ℝ} {l:ℝ} + (J:TrueCenterJet (n:=n) u a c φ l) : TangentBundle 𝓘(ℝ,Model n) M:= + ⟨(extChartAt 𝓘(ℝ,Model n) a).symm J.b,chartFiberInverse a J.b J.q⟩ +def TrueCenterJet.matrix {u:M → ℝ} {a c:M} {φ:ℝ → ℝ} {l:ℝ} + (J:TrueCenterJet (n:=n) u a c φ l) : Model n →L[ℝ] Model n →L[ℝ] ℝ:= + chartJetMatrix a c J.b J.q (innerSL ℝ J.s) ((innerSL ℝ).comp J.S) +def TrueCenterJet.curvature {u:M → ℝ} {a c:M} {φ:ℝ → ℝ} {l:ℝ} + (J:TrueCenterJet (n:=n) u a c φ l) : ℝ:=iteratedDeriv 2 φ (cTransform u J.y) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma exists_true_center_jet_gain : ∃δ>0,∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀l∈U,0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def trueCenterJetOfOriginal {u:M → ℝ} {a c y:M} {φ:ℝ → ℝ} {l:ℝ} + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) + (hp:∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d) + (hl:0φ (cTransform u ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c y+h)))) s S) : + TrueCenterJet (n:=n) u a c φ l := by + let z:=reverseRay (⟨y,l • p⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hrec:=graph_coordinate_reconstruction hz + have hreg:z.2∈injectivityDomain z.1:= + reverseRay_regular (contracted_minimizer_mem_injectivityDomain (injectivityDomain_subset_minimizingVectors _ hA.2.1) hl hl1) + refine { + y := y + b := graphBaseCoordinate a z + q := graphVelocityCoordinate a z + chart := (extChartAt 𝓘(ℝ,Model n) a).map_source hz + regular := ?_ + endpoint := ?_ + endChart := hy + p := p + A := A + original := hA + positive := hp + pole := ?_ + smooth := hφ + slope := hφd + s := s + S := S + symmetric := hS + expansion := hSe } + · exact (congrArg (fun w:TangentBundle 𝓘(ℝ,Model n) M=>w.2∈injectivityDomain w.1) hrec).mpr hreg + · rw [movingPrefix_graph_coordinates hz,one_smul] + exact reverseRay_endpoint _ + · exact (reverseRay_base (⟨y,l • p⟩:TangentBundle 𝓘(ℝ,Model n) M)).symm.trans + ((extChartAt 𝓘(ℝ,Model n) a).left_inv hz).symm +end TrueCenterJetBuild +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Calculus/UniformCostTaylor.lean b/lean/OAI/Analysis/BiholderTransport/Calculus/UniformCostTaylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..fcfe07a7c9ee53cccbd2dcc44739fec07c9b933b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Calculus/UniformCostTaylor.lean @@ -0,0 +1,141 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ManifoldLipschitz +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters +import OAI.Analysis.BiholderTransport.Regularity.RayAnchor +import OAI.Analysis.BiholderTransport.Regularity.CompactUniformSecondRemainder + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma half_cost_taylor_near_base (a : M) : + ∃ C>0, ∃ d>0, ∃ K∈𝓝 a, ∀ x∈K, ∀ p v : TangentSpace 𝓘(ℝ,Model n) x, + p∈minimizingVectors x → ‖v‖ TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hB,hbound⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + obtain ⟨K,hKn,hKs,hKc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) hbound) + let χ := extChartAt 𝓘(ℝ,Model n) a + let e := trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + let P := minimizingChartParameters (n := n) a K + let F : (Model n×Model n) → Model n → ℝ := + fun q z => movingNormalCost a q.1 ((1/2:ℝ) • q.2) z + have hF : ∀ q∈P, ContDiffAt ℝ ∞ (Function.uncurry F) (q,0) := by + intro q hq + have H := mem_minimizingChartParameters (fun x hx => (hKs hx).1) hq + have hp := contracted_minimizer_mem_injectivityDomain H.2.2 + (by norm_num : (0:ℝ)<1/2) (by norm_num : (1/2:ℝ)<1) + have hp' : e.symmL ℝ (χ.symm q.1) ((1/2:ℝ) • q.2)∈injectivityDomain (χ.symm q.1) := + by simpa only [map_smul] using hp + exact (movingNormalCost_contDiffAt H.1 hp').comp (q,(0 : Model n)) + ((contDiffAt_fst.fst.prodMk ((contDiffAt_const (c := (1/2:ℝ))).smul contDiffAt_fst.snd)).prodMk contDiffAt_snd) + obtain ⟨L,hL,d,hd,H⟩ := compact_uniform_second_remainder + (isCompact_minimizingChartParameters hKc (fun x hx => (hKs hx).1)) hF + refine ⟨L*B^2,by positivity,d/B,by positivity,K,hKn,?_⟩ + intro x hx p v hp hv + let A := e.continuousLinearMapAt ℝ x + have hpP : (χ x,A p)∈P := + trivialization_mem_minimizingChartParameters (fun x hx => (hKs hx).1) hx hp + have hAv : ‖A v‖≤B*‖v‖ := + (A.le_opNorm v).trans (mul_le_mul_of_nonneg_right (hKs hx).2.le (norm_nonneg _)) + have he : normalCost x ((1/2:ℝ) • p) = fun z => F (χ x,A p) (A z) := by + funext z + dsimp only [normalCost,F,movingNormalCost] + rw [←map_smul,movingNormal_trivialization_exp (hKs hx).1, + movingNormal_trivialization_exp (hKs hx).1] + have hD : DifferentiableAt ℝ (F (χ x,A p)) 0 := + ((hF _ hpP).comp 0 (contDiffAt_const.prodMk contDiffAt_id)).differentiableAt (by simp) + have hder : fderiv ℝ (F (χ x,A p)) 0 (A v) = -inner ℝ ((1/2:ℝ) • p) v := by + have hd0 : HasFDerivAt (F (χ x,A p)) (fderiv ℝ (F (χ x,A p)) 0) (A 0) := by + simpa only [map_zero] using hD.hasFDerivAt + have HD := hd0.comp 0 A.hasFDerivAt + dsimp only [Function.comp_def] at HD + rw [←he] at HD + have HR := congrArg (fun L : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => L v) HD.fderiv.symm + rw [normalCost_fderiv_zero (contracted_minimizer_mem_injectivityDomain hp + (by norm_num : (0:ℝ)<1/2) (by norm_num : (1/2:ℝ)<1))] at HR + exact HR + have havd : ‖A v‖0, ∃ d>0, ∀ x : M, ∀ p v : TangentSpace 𝓘(ℝ,Model n) x, + p∈minimizingVectors x → ‖v‖ hd a) + · intro x p v hp hv + have hx : x∈ ⋃ a∈s,K a := by rw [hs]; trivial + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp hx + exact (H a x hxa p v hp (hv.trans_le (Finset.inf'_le d ha))).trans + (mul_le_mul_of_nonneg_right (Finset.le_sup' C ha) (sq_nonneg _)) + +lemma exists_uniform_cost_upper_taylor [Nonempty M] : + ∃ C>0, ∃ d>0, ∀ x : M, ∀ p v : TangentSpace 𝓘(ℝ,Model n) x, + p∈minimizingVectors x → ‖v‖ b (h.1,w i • h.2)- + ∑ j,w j*c j (h.1,if j=i then h.2 else 0)) 0 D ∧ + ∀ a d:E, D (a,d) (a,d)=q a-∑ j,w j*r j a := by + let J : E×E →L[ℝ] E×E := (ContinuousLinearMap.fst ℝ E E).prod + (w i • ContinuousLinearMap.snd ℝ E E) + let K : ι → E×E →L[ℝ] E×E := fun j => (ContinuousLinearMap.fst ℝ E E).prod + (if j=i then ContinuousLinearMap.snd ℝ E E else 0) + have HTc : ∀ j, HasSecondTaylor (fun h => w j * c j (K j h)) + (w j • (((-innerSL ℝ (p j)).comp (ContinuousLinearMap.fst ℝ E E)).comp (K j))) + (w j • pullBilinear (C j) (K j)) := fun j => + ((hc j).comp_linear (K j)).const_mul' (w j) + have HCsum := HasSecondTaylor.sum (f := fun j h => w j*c j (K j h)) + (l := fun j => w j • (((-innerSL ℝ (p j)).comp (ContinuousLinearMap.fst ℝ E E)).comp (K j))) + (B := fun j => w j • pullBilinear (C j) (K j)) Finset.univ (fun j _ => HTc j) + have HT := (hb.comp_linear J).sub HCsum + have hl : (((-innerSL ℝ (∑ j,w j • p j)).comp + (ContinuousLinearMap.fst ℝ E E)).comp J)- + (∑ j,w j • (((-innerSL ℝ (p j)).comp + (ContinuousLinearMap.fst ℝ E E)).comp (K j)))=0 := by + apply ContinuousLinearMap.ext + rintro ⟨a,d⟩ + simp only [sub_apply,ContinuousLinearMap.comp_apply,J,K, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.coe_fst', + sum_apply,smul_apply,smul_eq_mul,neg_apply, + innerSL_apply_apply,zero_apply,sum_inner,real_inner_smul_left, + mul_neg,Finset.sum_neg_distrib,sub_self] + rw [hl] at HT + refine ⟨pullBilinear B J-∑ j,w j • pullBilinear (C j) (K j),?_,?_⟩ + · convert! HT using 1 + funext h + congr 1 + apply Finset.sum_congr rfl + intro j _ + by_cases hj : j=i <;> simp [K,hj] + · intro a d + simp only [sub_apply,sum_apply,smul_apply,smul_eq_mul, + pullBilinear_apply,J,K,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.coe_fst',ContinuousLinearMap.coe_snd'] + rw [hB,real_inner_smul_right] + have HC : ∀ j, C j (a,(if j=i then ContinuousLinearMap.snd ℝ E E else 0) (a,d)) + (a,(if j=i then ContinuousLinearMap.snd ℝ E E else 0) (a,d))= + r j a-(if j=i then 2*inner ℝ a d else 0) := by + intro j + by_cases hj : j=i <;> simp only [hj,ite_true,ite_false, + ContinuousLinearMap.coe_snd',zero_apply,hC,inner_zero_right,mul_zero] + simp_rw [HC,mul_sub] + rw [Finset.sum_sub_distrib] + simp only [mul_ite,mul_zero,Finset.sum_ite_eq',Finset.mem_univ,ite_true] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/AEContacts.lean b/lean/OAI/Analysis/BiholderTransport/Contact/AEContacts.lean new file mode 100644 index 0000000000000000000000000000000000000000..04f88d2c2d18322f30c4f496108044e51ef3a4d7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/AEContacts.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull +import OAI.Analysis.BiholderTransport.Regularity.AERademacher + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section AEContacts +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [MeasurableSpace M] [BorelSpace M] in +lemma active_log_derivative {v : M → ℝ} (hv : Continuous v) {x : M} + (hDiff : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈activeLogs (n := n) v x) : + HasFDerivAt (fun h => cTransform v (riemannianExp x h)) (innerSL ℝ p) 0 := by + have hID := contracted_minimizer_mem_injectivityDomain hp.1 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let f := fun h : TangentSpace 𝓘(ℝ,Model n) x => + (-2:ℝ)*(normalCost x ((1/2:ℝ) • p) h-normalCost x ((1/2:ℝ) • p) 0) + have hD : HasFDerivAt f (innerSL ℝ p) 0 := by + apply (((normalCost_hasFDerivAt_zero hID).sub_const + (normalCost x ((1/2:ℝ) • p) 0)).const_smul (-2:ℝ)).congr_fderiv + ext h + simp only [smul_apply,innerSL_apply_apply,inner_neg_left,real_inner_smul_left,smul_eq_mul] + ring + have hU : DifferentiableAt ℝ (fun h : TangentSpace 𝓘(ℝ,Model n) x => cTransform v (riemannianExp x h)) 0 := by + have hf : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) + (riemannianExp (n := n) x 0) := by simpa only [riemannianExp_zero] using hDiff + exact (hf.comp 0 ((contMDiff_riemannianExp_fiber x).contMDiffAt.mdifferentiableAt + (by simp))).differentiableAt + have hMin : IsLocalMin (fun h => cTransform v (riemannianExp x h)-f h) 0 := by + apply Filter.Eventually.of_forall + intro h + have hs := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (riemannianExp x h) + have he : f h = -(cost (riemannianExp x h) (riemannianExp x ((1/2:ℝ) • p)) - + cost x (riemannianExp x ((1/2:ℝ) • p))) / (1/2:ℝ) := by + dsimp [f,normalCost] + rw [riemannianExp_zero] + ring + change cTransform v (riemannianExp x 0)-f 0≤ + cTransform v (riemannianExp x h)-f h + simp only [riemannianExp_zero,show f 0=0 by simp [f],sub_zero,he] + linarith only [hs] + have he := sub_eq_zero.mp (hMin.hasFDerivAt_eq_zero (hU.hasFDerivAt.sub hD)) + rw [←he] + exact hU.hasFDerivAt + +omit [MeasurableSpace M] [BorelSpace M] in +lemma contact_unique_of_mdifferentiable {v : M → ℝ} (hv : Continuous v) {x : M} + (hDiff : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {y z : M} (hy : contactGap (cTransform v) v x y=0) + (hz : contactGap (cTransform v) v x z=0) : y=z := by + obtain ⟨p,hp,hep⟩ := exists_minimizing_vector (n := n) x y + obtain ⟨q,hq,heq⟩ := exists_minimizing_vector (n := n) x z + have hpA : p∈activeLogs (n := n) v x := ⟨hp,by simpa only [hep] using hy⟩ + have hqA : q∈activeLogs (n := n) v x := ⟨hq,by simpa only [heq] using hz⟩ + have H := (active_log_derivative hv hDiff hpA).unique (active_log_derivative hv hDiff hqA) + have hpq : p=q := by + apply ext_inner_right ℝ + intro h + exact congrArg (fun D : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => D h) H + rw [←hep,←heq,hpq] + +variable [Nonempty M] +lemma cTransform_ae_unique_contact {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ x ∂metricVolume (M := M) n, ∃! y, contactGap (cTransform v) v x y=0 := by + filter_upwards [cTransform_ae_mdifferentiableAt hv] with x hx + obtain ⟨y,hy⟩ := cTransform_gap_zero hv x + exact ⟨y,hy,fun z hz => contact_unique_of_mdifferentiable hv hx hz hy⟩ + +end AEContacts +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ActiveContinuationLocal.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ActiveContinuationLocal.lean new file mode 100644 index 0000000000000000000000000000000000000000..ba83a647b47b3a2d4d97472205c933425b91483a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ActiveContinuationLocal.lean @@ -0,0 +1,270 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalSubdifferential +import OAI.Analysis.BiholderTransport.Coordinates.MetricLocalGrowth +import OAI.Analysis.BiholderTransport.Regularity.LocalMinStrictGrowth + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma smooth_lower_support_mem_normalSubdifferential {u : M → ℝ} {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {g : TangentSpace 𝓘(ℝ,Model n) x → ℝ} + (hg : HasFDerivAt g (innerSL ℝ p) 0) + (hs : ∀ᶠ h in 𝓝 0, g h-g 0≤u (riemannianExp x h)-u x) : + p ∈ normalSubdifferential (n := n) u x := by + intro ε hε + filter_upwards [hasFDerivAt_affine_lower_support hg ε hε,hs] with h hh hk + exact hh.trans hk + +lemma local_min_divided_cost_subgradient {u : M → ℝ} {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} (ht : t≠0) + (hID : t • p ∈ injectivityDomain x) + (hmin : IsLocalMin (fun z => u z+cost z (riemannianExp x (t • p))/t) x) : + p ∈ normalSubdifferential (n := n) u x := by + let g := fun h : TangentSpace 𝓘(ℝ,Model n) x => (-t⁻¹)*normalCost x (t • p) h + have hg : HasFDerivAt g (innerSL ℝ p) 0 := by + apply ((normalCost_hasFDerivAt_zero hID).const_smul (-t⁻¹)).congr_fderiv + ext h + simp only [smul_apply,innerSL_apply_apply,inner_neg_left,real_inner_smul_left,smul_eq_mul] + field_simp + apply smooth_lower_support_mem_normalSubdifferential hg + have hm : ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + u x+cost x (riemannianExp x (t • p))/t≤ + u (riemannianExp x h)+cost (riemannianExp x h) (riemannianExp x (t • p))/t := by + have hc := (continuous_riemannianExp (n := n) x).continuousAt (x := 0) |>.tendsto + rw [riemannianExp_zero] at hc + exact hc.eventually hmin + filter_upwards [hm] with h hh + dsimp only [g,normalCost] + rw [riemannianExp_zero] + simp only [div_eq_mul_inv] at hh + nlinarith + +lemma WeakMTW.active_hull_nearby_local_min (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {t : ℝ} (ht : 0 cTransform v w+cost w y/t) z := by + let : Nonempty M := ⟨x⟩ + apply exists_local_min_of_strict_growth + · exact ((continuous_cTransform hv).comp continuous_fst).add + (((continuous_fst.dist continuous_snd).pow 2).div_const 2 |>.div_const t) + · exact hmtw.active_hull_strict_local_min hv hp ht ht1 hID + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ActiveLocalGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ActiveLocalGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc8e462c2b76a6cfbe944e003e2880a9a3864c9c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ActiveLocalGrowth.lean @@ -0,0 +1,243 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions +import OAI.Analysis.BiholderTransport.Coordinates.FiniteActiveGrowth + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma active_split_lower_support {v : M → ℝ} (hv : Continuous v) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ minimizingVectors x) + (hactive : contactGap (cTransform v) v x (riemannianExp x p)=0) + {s : ℝ} (hs : 00, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + b*‖h‖^2 ≤ + cTransform v (riemannianExp x h)-cTransform v x+ + (cost (riemannianExp x h) (riemannianExp x (t • (∑ j, w j • p j)))- + cost x (riemannianExp x (t • (∑ j, w j • p j))))/t := by + obtain ⟨s,hts,hs1⟩ := exists_between ht1 + obtain ⟨b,hb,H⟩ := hmtw.finite_active_cost_growth p w hw hsum hmin ht hts hs1 hID + refine ⟨b,hb,?_⟩ + filter_upwards [H] with h hh + obtain ⟨i,hi⟩ := hh + have hsup := active_split_lower_support hv (hmin i) (hactive i) (ht.trans hts) hs1 + (riemannianExp x h) + simp only [normalCost,riemannianExp_zero] at hi + rw [neg_div] at hsup + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ActualEnvelopeJets.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ActualEnvelopeJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d78a35e94b1928b3c28bc99652a4ea8240ddf68 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ActualEnvelopeJets.lean @@ -0,0 +1,46 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CoordinateScalarSupport + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +def jointScalarSupport (a : M) (Φ : P×ℝ → ℝ) + (q : (P×((ℝ×ℝ)×(Model n×Model n)))×Model n) : ℝ := + Φ (q.1.1,coordinateScalarSupport a id (q.1.2,q.2)) + +omit [Nonempty M] [CompleteSpace P] in +lemma jointScalarSupport_contDiffAt {a : M} {b p : Model n} {v s : ℝ} + {param : P} {Φ : P×ℝ → ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hs : s≠0) + (hp : s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hΦ : ContDiffAt ℝ ∞ Φ (param,v)) : + ContDiffAt ℝ ∞ (jointScalarSupport a Φ) ((param,((v,s),(b,p))),b) := by + have hF := (coordinateScalarSupport_contDiffAt hb hs hp contDiffAt_id).comp + ((param,((v,s),(b,p))),b) (contDiffAt_fst.snd.prodMk contDiffAt_snd) + have hpair := contDiffAt_fst.fst.prodMk hF + exact (show ContDiffAt ℝ ∞ Φ + (param,coordinateScalarSupport a id (((v,s),(b,p)),b)) from by + simpa only [coordinateScalarSupport_self,id_eq] using hΦ).comp + (f := fun q : (P×((ℝ×ℝ)×(Model n×Model n)))×Model n => + (q.1.1,coordinateScalarSupport a id (q.1.2,q.2))) _ hpair +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ActualPoleJet.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ActualPoleJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..32b8a503474a098abdea91581190ed3523d6a363 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ActualPoleJet.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeTaylor +import OAI.Analysis.BiholderTransport.CostGeometry.ActualPole +import OAI.Analysis.BiholderTransport.Calculus.PoleJetAlgebra + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.actualPole_fixed_support (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 + hopfLax t u (riemannianExp x (t • q))) (t • innerSL ℝ p) p := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let f : V → ℝ := fun q => hopfLax t u (riemannianExp x (t • q)) + have hd := hmtw.prefix_hopfLax_differentiable hu hv hdual ht ht1 x p + have hsup := (hmtw.actualPole_fixed_support hu hv hdual ht ht1 hp hpole).2 + have hg : HasFDerivAt (fun q : V => f p+t*(‖q‖^2/2-‖p‖^2/2)) + (t • innerSL ℝ p) p := by + convert! (((half_norm_sq_hasFDerivAt p).sub_const (‖p‖^2/2)).const_smul t).const_add (f p) using 1 + have he := upper_contact_fderiv hd hg.differentiableAt hsup (by simp only [sub_self,mul_zero,add_zero]; rfl) + exact hd.hasFDerivAt.congr_fderiv (he.trans hg.fderiv) + +lemma WeakMTW.actualPole_taylor (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 hopfLax t u (riemannianExp x (t • (p+h)))) + (t • innerSL ℝ p) (t • (innerSL ℝ (E := TangentSpace 𝓘(ℝ,Model n) x))-(innerSL ℝ).comp R) ∧ + (∀ d:TangentSpace 𝓘(ℝ,Model n) x, 0 ≤ inner ℝ (R d) d) ∧ + (∀ d e:TangentSpace 𝓘(ℝ,Model n) x, inner ℝ (R d) e=inner ℝ d (R e)) := by + have hpole : hopfPole (n := n) t u (riemannianExp x (t • p))=x := by + have H := harep.self_of_nhds + rw [ha0,riemannianExp_zero] at H + exact H.symm + have hD := hmtw.actualPole_second_derivative hu hv hdual ht ht1 hp ha ha0 harep + have hnear : ∀ᶠ q in 𝓝 p, HasFDerivAt + (fun w : TangentSpace 𝓘(ℝ,Model n) x => hopfLax t u (riemannianExp x (t • w))) + (fderiv ℝ (fun w : TangentSpace 𝓘(ℝ,Model n) x => hopfLax t u (riemannianExp x (t • w))) q) q := + Filter.Eventually.of_forall (fun q => + (hmtw.prefix_hopfLax_differentiable hu hv hdual ht ht1 x q).hasFDerivAt) + have HT := hasSecondTaylor_of_second_derivative hnear hD + rw [(hmtw.actualPole_first_derivative hu hv hdual ht ht1 hp hpole).fderiv] at HT + refine ⟨HT,pole_nonneg_of_envelope_taylor HT + (hmtw.actualPole_fixed_support hu hv hdual ht ht1 hp hpole).2,?_⟩ + intro d e + have H := second_derivative_symmetric_of_eventually hnear hD d e + change t*inner ℝ d e-inner ℝ (R d) e=t*inner ℝ e d-inner ℝ (R e) d at H + rw [real_inner_comm e d,real_inner_comm d (R e)] at H + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/BranchContact.lean b/lean/OAI/Analysis/BiholderTransport/Contact/BranchContact.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c62d12b80b140071d99b6925ba5d03004b22072 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/BranchContact.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.InjectivityOpen +import OAI.Analysis.BiholderTransport.Regularity.InteriorCompactUniqueFiber +import OAI.Analysis.BiholderTransport.Coordinates.BranchInverse + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Pointwise + +namespace WeakMTWTransport +section FirstNonconjugate +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma mem_injectivityDomain_of_unique_nonconjugate {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hu : ∀ q∈minimizingVectors x, riemannianExp x q=riemannianExp x p → q=p) + (hreg : Function.Injective (fderiv ℝ (fun q => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x q)) p)) : + p∈injectivityDomain x := by + obtain ⟨P,_,_,hleft,_⟩ := exists_smooth_exp_branch + (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hreg + have hmap := (FiberBundle.continuous_totalSpaceMk (Model n) + (fun a : M => TangentSpace 𝓘(ℝ,Model n) a) x).continuousAt.eventually hleft + obtain ⟨U,hUsub,hU,hpU⟩ := mem_nhds_iff.mp hmap + apply interior_minimizingVectors_subset x + apply interior_of_compact_unique_fiber (isCompact_minimizingVectors x) + (continuous_riemannianExp x) (exists_minimizing_vector (n := n) x) hu + refine ⟨U,hU,hpU,?_⟩ + intro q hq r hr he + have hq' := hUsub hq + have hr' := hUsub hr + change P (x,riemannianExp x q)=⟨x,q⟩ at hq' + change P (x,riemannianExp x r)=⟨x,r⟩ at hr' + exact TotalSpace.mk_injective x (hq'.symm.trans ((congrArg (fun y => P (x,y)) he).trans hr')) + +end FirstNonconjugate +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupport.lean b/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..6b3860b96b59ac53e3dd94b4ffc97b76683901d5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupport.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ActiveLocalGrowth +import OAI.Analysis.BiholderTransport.Calculus.SecondFderivScalarComp + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def scalarCostSupport (φ : ℝ → ℝ) (v0 : ℝ) (x : M) + (p : TangentSpace 𝓘(ℝ,Model n) x) (s : ℝ) (y : M) : ℝ := + φ (v0+cost x (riemannianExp x (s • p))/s-cost y (riemannianExp x (s • p))/s) + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma scalarCostSupport_self (φ : ℝ → ℝ) (v0 : ℝ) (x : M) + (p : TangentSpace 𝓘(ℝ,Model n) x) (s : ℝ) : + scalarCostSupport φ v0 x p s x=φ v0 := by simp [scalarCostSupport] + +lemma scalarCostSupport_lower {u v : M → ℝ} (hu : Continuous u) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hφ : Monotone φ) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + (hc : contactGap v u x (riemannianExp x p)=0) {s : ℝ} (hs : 0 + scalarCostSupport φ v0 x p s (riemannianExp x h)) 0 ∧ + HasFDerivAt (fun h : TangentSpace 𝓘(ℝ,Model n) x => + scalarCostSupport φ v0 x p s (riemannianExp x h)) (innerSL ℝ (l • p)) 0 ∧ + ∀ ξ : TangentSpace 𝓘(ℝ,Model n) x, + fderiv ℝ (fderiv ℝ (fun h => scalarCostSupport φ v0 x p s (riemannianExp x h))) 0 ξ ξ = + -(l/s)*hessianValue x (s • p) ξ+iteratedDeriv 2 φ v0*(inner ℝ p ξ)^2 := by + let C := normalCost x (s • p) + let f := fun h : TangentSpace 𝓘(ℝ,Model n) x => v0+C 0/s+(-s⁻¹)*C h + have hf0 : f 0=v0 := by dsimp [f]; ring + have hC : ContDiffAt ℝ 2 C 0 := + (normalCost_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hf : ContDiffAt ℝ 2 f 0 := contDiffAt_const.add (contDiffAt_const.mul hC) + have hD : HasFDerivAt f (innerSL ℝ p) 0 := by + apply (((normalCost_hasFDerivAt_zero hp).const_mul (-s⁻¹)).const_add (v0+C 0/s)).congr_fderiv + ext h + simp only [_root_.smul_apply,smul_eq_mul,innerSL_apply_apply,inner_neg_left,real_inner_smul_left] + field_simp + have he (h : TangentSpace 𝓘(ℝ,Model n) x) : + scalarCostSupport φ v0 x p s (riemannianExp x h)=φ (f h) := by + dsimp [scalarCostSupport,f,C,normalCost] + rw [riemannianExp_zero] + congr 1 + ring + have heq : (fun h => scalarCostSupport φ v0 x p s (riemannianExp x h))=fun h => φ (f h) := funext he + rw [heq] + have hφf : ContDiffAt ℝ 2 φ (f 0) := hf0.symm ▸ hφ + refine ⟨hφf.comp 0 hf,?_,?_⟩ + · have H := (hφf.differentiableAt (by norm_num)).hasDerivAt.comp_hasFDerivAt 0 hD + rw [hf0,hl] at H + apply H.congr_fderiv + ext h + simp only [_root_.smul_apply,smul_eq_mul,innerSL_apply_apply,real_inner_smul_left] + · intro ξ + rw [second_fderiv_scalar_comp hf hφf ξ,hf0,hl,hD.fderiv] + have H : fderiv ℝ (fderiv ℝ f) 0 ξ ξ=(-s⁻¹)*hessianValue x (s • p) ξ := by + have hd : fderiv ℝ f=fun h => (-s⁻¹) • fderiv ℝ C h := by + funext h + dsimp only [f] + rw [fderiv_const_add] + exact congrFun (fderiv_const_smul_field (𝕜 := ℝ) (f := C) (-s⁻¹)) h + rw [hd] + change fderiv ℝ ((-s⁻¹) • fderiv ℝ C) 0 ξ ξ = _ + rw [fderiv_const_smul_field (𝕜 := ℝ) (f := fderiv ℝ C) (-s⁻¹)] + rw [hessianValue_eq_normalHessian hp] + rfl + rw [H] + simp only [innerSL_apply_apply] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupportFamily.lean b/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupportFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..40a4e1a1b644646098ad73a6b21de2f9244a4d6b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/CenterSupportFamily.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ActualEnvelopeJets +import OAI.Analysis.BiholderTransport.Regularity.ActualCenterRay +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingCoordinateLimit + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure TrueCenterRow (c : M) (u v : M → ℝ) (φ : ℝ → ℝ) + (x : Model n) (z : M) (τ l : ℝ) where + r : Model n + chart : x∈(extChartAt 𝓘(ℝ,Model n) c).target + minimizing : chartFiberInverse c x r∈minimizingVectors ((extChartAt 𝓘(ℝ,Model n) c).symm x) + contact : contactGap v u ((extChartAt 𝓘(ℝ,Model n) c).symm x) (movingNormal c (x,r))=0 + modifiedRegular : l • chartFiberInverse c x r∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) c).symm x) + ray : riemannianExp ((extChartAt 𝓘(ℝ,Model n) c).symm x) ((τ*l) • chartFiberInverse c x r)=z + below : ∀ w,coordinateScalarSupport c φ + (((v ((extChartAt 𝓘(ℝ,Model n) c).symm x),(1+l)/2),(x,r)),w)≤ + φ (v ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + touching : coordinateScalarSupport c φ + (((v ((extChartAt 𝓘(ℝ,Model n) c).symm x),(1+l)/2),(x,r)),x)= + φ (v ((extChartAt 𝓘(ℝ,Model n) c).symm x)) + forward : shortForward c (fun w=>coordinateScalarSupport c φ + (((v ((extChartAt 𝓘(ℝ,Model n) c).symm x),(1+l)/2),(x,r)),w)) (τ,x)= + extChartAt 𝓘(ℝ,Model n) c z + +lemma WeakMTW.actual_center_row (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) {Lv : ℝ≥0} (hv : LipschitzWith Lv v) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hφc : Continuous φ) (hmono : Monotone φ) + {c : M} {x : Model n} (hx : x∈(extChartAt 𝓘(ℝ,Model n) c).target) + {z : M} {l τ : ℝ} (hφ : HasDerivAt φ l (v ((extChartAt 𝓘(ℝ,Model n) c).symm x))) + (hl : 0φ (v y)) z=φ (v ((extChartAt 𝓘(ℝ,Model n) c).symm x))+ + cost ((extChartAt 𝓘(ℝ,Model n) c).symm x) z/τ) : + Nonempty (TrueCenterRow c u v φ x z τ l) := by + obtain ⟨p,hm,hc,hr,he,hb,ht,hf⟩ := hmtw.exists_center_coordinate_support hu hv hdual hφc hmono hx hφ hl hl1 hτ hτ1 hval + exact ⟨⟨p,hx,hm,hc,hr,he,hb,ht,hf⟩⟩ + +abbrev centerRowParameter (c : M) (v : M → ℝ) (γ l : ℝ) (x r : Model n) := + (γ,((v ((extChartAt 𝓘(ℝ,Model n) c).symm x),(1+l)/2),(x,r))) + +omit [CompactSpace M] [Nonempty M] + [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma center_row_parameter_tendsto {c : M} {v : M → ℝ} (hv : Continuous v) + {γj lj : ℕ → ℝ} {xj rj : ℕ → Model n} {γ l : ℝ} {r : Model n} + (hγ : Tendsto γj atTop (𝓝 γ)) (hl : Tendsto lj atTop (𝓝 l)) + (hx : Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hr : Tendsto rj atTop (𝓝 r)) : + Tendsto (fun i=>centerRowParameter c v (γj i) (lj i) (xj i) (rj i)) atTop + (𝓝 (γ,((v c,(1+l)/2),(extChartAt 𝓘(ℝ,Model n) c c,r)))) := by + have hb := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hy := (continuousAt_extChartAt_symm'' hb).tendsto.comp hx + rw [(extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c)] at hy + exact hγ.prodMk_nhds (((hv.tendsto c).comp hy).prodMk_nhds + ((tendsto_const_nhds.add hl).div_const 2) |>.prodMk_nhds (hx.prodMk_nhds hr)) + +omit [Nonempty M] in +lemma center_support_family_subseq {c : M} {u v : M → ℝ} {Φ : ℝ×ℝ → ℝ} + {γj lj τj : ℕ → ℝ} {xj : ℕ → Model n} {zj : ℕ → M} + (R : ∀ i,TrueCenterRow c u v (fun s=>Φ (γj i,s)) (xj i) (zj i) (τj i) (lj i)) + (hx : Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) : + ∃ σ : ℕ → ℕ, StrictMono σ ∧ ∃ r : Model n, + (show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c ∧ + Tendsto (fun i=>(R (σ i)).r) atTop (𝓝 r) := + minimizing_coordinates_tail_subseq hx (fun i=>(R i).chart) (fun i=>(R i).minimizing) + +omit [Nonempty M] in +lemma center_limit_support_smooth {c : M} {r : Model n} {γ l : ℝ} {v : M → ℝ} + {Φ : ℝ×ℝ → ℝ} (hΦ : ContDiffAt ℝ ∞ Φ (γ,v c)) + (hr : (show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c) + (hl : 0 t * u (a • x+b • y)) hab + nlinarith only [H₁,H₂,he,habu] + +lemma convexOn_of_quadratic_lower_support {u : E → ℝ} {S : Set E} {K : ℝ} + (hS : Convex ℝ S) + (h : ∀ x∈S, ∃ l : E →L[ℝ] ℝ, ∀ y∈S, u x+l (y-x)-K*‖y-x‖^2 ≤ u y) : + ConvexOn ℝ S (fun z => u z+K*‖z‖^2) := by + apply convexOn_of_linear_lower_support hS + intro x hx + obtain ⟨l,hl⟩ := h x hx + refine ⟨l+(2*K) • innerSL ℝ x,?_⟩ + intro y hy + have H := hl y hy + have hn : ‖y‖^2-‖x‖^2-2*inner ℝ x (y-x)=‖y-x‖^2 := by + simp only [← real_inner_self_eq_norm_sq,inner_sub_left,inner_sub_right,real_inner_comm y x] + ring + simp only [add_apply,smul_apply,innerSL_apply_apply,smul_eq_mul] + have hnK := congrArg (fun t : ℝ => K*t) hn + nlinarith only [H,hnK] + +end +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma c2_quadratic_remainder_on_convex {f : E → ℝ} {S : Set E} {K : ℝ} + (hK : 0≤K) (hS : Convex ℝ S) (hf : ∀ z∈S, ContDiffAt ℝ 2 f z) + (hbound : ∀ z∈S, ‖fderiv ℝ (fderiv ℝ f) z‖≤K) {x y : E} (hx : x∈S) (hy : y∈S) : + ‖f y-f x-fderiv ℝ f x (y-x)‖ ≤ K*‖y-x‖^2 := by + have hd (z) (hz : z∈S) : DifferentiableAt ℝ (fderiv ℝ f) z := + ((hf z hz).fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hseg : segment ℝ x y ⊆ S := hS.segment_subset hx hy + have hball : segment ℝ x y ⊆ Metric.closedBall x ‖y-x‖ := + (convex_closedBall x ‖y-x‖).segment_subset (by simp only [Metric.mem_closedBall,dist_self]; positivity) + (by simp only [Metric.mem_closedBall,dist_eq_norm,le_refl]) + have hdif (z) (hz : z∈segment ℝ x y) : ‖fderiv ℝ f z-fderiv ℝ f x‖≤K*‖y-x‖ := by + calc + _ ≤ K*‖z-x‖ := hS.norm_image_sub_le_of_norm_fderiv_le hd hbound hx (hseg hz) + _ ≤ K*‖y-x‖ := mul_le_mul_of_nonneg_left (by + simpa only [Metric.mem_closedBall,dist_eq_norm] using hball hz) hK + have H := (convex_segment x y).norm_image_sub_le_of_norm_fderiv_le' + (fun z hz => (hf z (hseg hz)).differentiableAt (by norm_num)) hdif + (left_mem_segment ℝ x y) (right_mem_segment ℝ x y) + simpa only [mul_assoc,← sq] using H + +end +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts.lean new file mode 100644 index 0000000000000000000000000000000000000000..05e4dfde22a33dc34624061a522666aa546fac31 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SmoothUpperTest +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateExpansion +import OAI.Analysis.BiholderTransport.Geodesics.GoodContact + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactCharts +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteContactCharts (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end ContactCharts +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter MeasureTheory Manifold Bundle Metric +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section RegularContact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteRegularContact (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [MeasurableSpace M] [BorelSpace M] in +lemma cTransform_normal_expansion_active {v : M → ℝ} (hv : Continuous v) {x : M} + (hD : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {p : TangentSpace 𝓘(ℝ,Model n) x} + {A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x} + (hexp : HasQuadraticExpansion (fun h => cTransform v (riemannianExp x h)) p A) : + p∈activeLogs (n := n) v x := by + obtain ⟨y,hy⟩ := cTransform_gap_zero hv x + obtain ⟨q,hq,heq⟩ := exists_minimizing_vector (n := n) x y + have hqa : q∈activeLogs (n := n) v x := ⟨hq,by simpa only [heq] using hy⟩ + have hDerivative : HasFDerivAt (fun offset => cTransform v (riemannianExp x offset)) + ((innerSL ℝ) p) 0 := by + obtain ⟨radius,hradius,hbound⟩ := hexp 1 zero_lt_one + let bound : ℝ := 1+‖A‖/2 + have hpositive : 0 D h) H + rwa [hpq] + +omit [MeasurableSpace M] [BorelSpace M] in +lemma contactSelection_continuousAt_of_mdifferentiable {v : M → ℝ} (hv : Continuous v) + {x : M} (hD : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) : + ContinuousAt (contactSelection hv) x := by + apply contact_selection_continuousAt (continuous_cTransform hv) hv (contactSelection_mem hv) + exact fun y hy => contact_unique_of_mdifferentiable hv hD hy (contactSelection_mem hv x) + +lemma minimizing_dualPair_regular_contact_set {lam cap : ℝ} (hlam : 0 cTransform v (riemannianExp x h)) p A) ∧ + (∀ B : Set M, MeasurableSet B → B⊆G → + ENNReal.ofReal (lam/cap)*metricVolume n B ≤ + metricVolume n (contactSelection v.continuous '' B) ∧ + metricVolume n (contactSelection v.continuous '' B) ≤ + ENNReal.ofReal (cap/lam)*metricVolume n B) := by + obtain ⟨G,hGm,hGae,hGi,hGD,hGmass⟩ := + minimizing_dualPair_good_contact_set hlam hcap h0 h1 huv hmin + obtain ⟨H,hHm,hHae,hH⟩ := exists_measurable_full_subset + ((cTransform_ae_normal_quadraticExpansion (n := n) v.continuous).and + (cTransform_ae_active_before_cut (n := n) v.continuous)) + refine ⟨G∩H,hGm.inter hHm,hGae.and hHae,hGi.mono inter_subset_left, + fun x hx => hGD x hx.1,fun x hx => + contactSelection_continuousAt_of_mdifferentiable v.continuous (hGD x hx.1),?_,?_⟩ + · intro x hx + obtain ⟨p,A,hAs,hA⟩ := (hH x hx.2).1 + have hp := cTransform_normal_expansion_active v.continuous (hGD x hx.1) hA + exact ⟨p,A,hp,(hH x hx.2).2 p hp,hAs,hA⟩ + · intro B hBm hBG + exact hGmass B hBm (hBG.trans inter_subset_left) + +end RegularContact +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts2.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts2.lean new file mode 100644 index 0000000000000000000000000000000000000000..4528343f09235e03d3ca5d97d28e1a7eae733914 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactCharts2.lean @@ -0,0 +1,131 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactCharts +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [MeasurableSpace M] [BorelSpace M] in +lemma contact_selection_chart_differential_full {v : M → ℝ} (hv : Continuous v) + {T : M → M} (hT : ∀ z, contactGap (cTransform v) v z (T z)=0) + {G : Set M} (hG : ∀ z∈G, MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) z) + {x : M} (hxG : x∈G) {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈activeLogs (n := n) v x) (hpI : p∈injectivityDomain x) + {A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x} + (hA : ∀ u w, inner ℝ (A u) w=inner ℝ u (A w)) + (hexp : HasQuadraticExpansion (fun h => cTransform v (riemannianExp x h)) p A) + (a b : M) (hGs : G⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hTxs : T x∈(extChartAt 𝓘(ℝ,Model n) b).source) : + ∃ R : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x, + ∃ S : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] Model n, + HasFDerivWithinAt + ((extChartAt 𝓘(ℝ,Model n) b) ∘ T ∘ (extChartAt 𝓘(ℝ,Model n) a).symm) + (S.comp ((normalHessianOperator x p+A).comp R)) + ((extChartAt 𝓘(ℝ,Model n) a) '' G) ((extChartAt 𝓘(ℝ,Model n) a) x) ∧ + S=fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) b) ∘ riemannianExp (n := n) x) p ∧ + (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) 0).comp R= + ContinuousLinearMap.id ℝ (Model n) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let d := extChartAt 𝓘(ℝ,Model n) a + let e := extChartAt 𝓘(ℝ,Model n) b + have hx : x∈d.source := hGs hxG + have hDx := hG x hxG + have hTx : T x=riemannianExp x p := contact_unique_of_mdifferentiable hv hDx (hT x) hp.2 + obtain ⟨r,hr,q,hq0,hqc,hqright,hq⟩ := + contact_selection_normal_differential hv hp hpI hDx hA hexp hT + obtain ⟨κ,hκ0,hκ,hκright⟩ := exists_normal_local_inverse_at (zero_mem_injectivityDomain (n := n) x) + simp only [riemannianExp_zero] at hκ0 hκ hκright + let η : Model n → V := κ ∘ d.symm + let ξ : V → Model n := e ∘ riemannianExp x + have hη0 : η (d x)=0 := by simp only [η,Function.comp_apply,d.left_inv hx,hκ0] + have hdi : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d.symm (d x) := + (contMDiffOn_extChartAt_symm a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds (d.map_source hx)) + have hη : ContDiffAt ℝ ∞ η (d x) := by + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp (d x) _ hdi + simpa only [d.left_inv hx] using hκ + have hξ : ContDiffAt ℝ ∞ ξ p := by + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp p _ (contMDiff_riemannianExp_fiber x p) + apply contMDiffAt_extChartAt' + simpa only [←hTx,extChartAt_source] using hTxs + have hηt : Tendsto η (𝓝 (d x)) (𝓝 (0:V)) := by + simpa only [ContinuousAt,hη0] using hη.continuousAt + have hdiT : Tendsto d.symm (𝓝 (d x)) (𝓝 x) := by + simpa only [ContinuousAt,d.left_inv hx] using hdi.continuousAt + have hηright : ∀ᶠ z in 𝓝 (d x), riemannianExp x (η z)=d.symm z := hdiT.eventually hκright + let s : Set V := {h | h∈Metric.ball 0 r ∧ + DifferentiableAt ℝ (fun z => cTransform v (riemannianExp x z)) h} + have hηs : ∀ᶠ z in 𝓝[d '' G] (d x), η z∈s := by + filter_upwards [self_mem_nhdsWithin,mem_nhdsWithin_of_mem_nhds hηright, + mem_nhdsWithin_of_mem_nhds (hηt.eventually (Metric.ball_mem_nhds 0 hr))] with z hz he hzball + refine ⟨hzball,?_⟩ + obtain ⟨w,hw,rfl⟩ := hz + have hew : riemannianExp x (η (d w))=w := by simpa only [d.left_inv (hGs hw)] using he + have H := (show MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) + (riemannianExp x (η (d w))) from hew.symm ▸ hG w hw).comp (η (d w)) + ((contMDiff_riemannianExp_fiber x _).mdifferentiableAt (by simp)) + exact H.differentiableAt + have hηwt : Tendsto η (𝓝[d '' G] (d x)) (𝓝[s] (η (d x))) := by + rw [hη0] + exact tendsto_nhdsWithin_iff.mpr ⟨hηt.mono_left nhdsWithin_le_nhds,hηs⟩ + let R := fderiv ℝ η (d x) + let S := fderiv ℝ ξ p + have hWq : HasFDerivWithinAt q (normalHessianOperator x p+A) s (η (d x)) := by + simpa only [hη0] using hq + have hqη := hWq.comp_of_tendsto (d x) + (hη.differentiableAt (by simp)).hasFDerivAt.hasFDerivWithinAt hηwt + have hξd : HasFDerivAt ξ S ((q ∘ η) (d x)) := by + simpa only [Function.comp_apply,hη0,hq0] using + (hξ.differentiableAt (by simp)).hasFDerivAt + refine ⟨R,S,?_,rfl,?_⟩ + · apply (hξd.comp_hasFDerivWithinAt (d x) hqη).congr_of_eventuallyEq + · apply Filter.Eventually.filter_mono nhdsWithin_le_nhds + filter_upwards [hηright,hηt.eventually hqright] with z hz hqz + simp only [Function.comp_apply,ξ] + rw [hqz,hz] + · change e (T (d.symm (d x)))=ξ (q (η (d x))) + simp only [ξ,Function.comp_apply,hη0,hq0,d.left_inv hx,hTx] + · let χ : V → Model n := d ∘ riemannianExp (n := n) x + have hχ : ContDiffAt ℝ ∞ χ 0 := by + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp 0 _ (contMDiff_riemannianExp_fiber x 0) + apply contMDiffAt_extChartAt' + simpa only [riemannianExp_zero,d,extChartAt_source] using hx + have hχd : HasFDerivAt χ (fderiv ℝ χ 0) (η (d x)) := by + simpa only [hη0] using (hχ.differentiableAt (by simp)).hasFDerivAt + have hprod := hχd.comp (d x) (hη.differentiableAt (by simp)).hasFDerivAt + have hEq : (χ ∘ η)=ᶠ[𝓝 (d x)] id := by + filter_upwards [hηright,(isOpen_extChartAt_target a).mem_nhds (d.map_source hx)] with z hz hzt + change d (riemannianExp x (η z))=z + rw [hz,d.right_inv hzt] + exact (hprod.congr_of_eventuallyEq hEq.symm).unique (hasFDerivAt_id (d x)) + +end ContactCharts +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..85055a1414770e3d1c244b90948d6c0ee8ee8aba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactDerivative.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactDerivative +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinateContact (a b : M) (q : Model n × (Model n →L[ℝ] ℝ)) : Model n := + extChartAt 𝓘(ℝ,Model n) b (coordinateBackward a (-1,q.1,q.2)) + +omit [Nonempty M] in +lemma coordinateContact_contDiffAt {a b : M} {q : Model n × (Model n →L[ℝ] ℝ)} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hb : coordinateBackward a (-1,q.1,q.2)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + ContDiffAt ℝ ∞ (coordinateContact (n := n) a b) q := by + have hi : ContDiffAt ℝ ∞ (fun z : Model n × (Model n →L[ℝ] ℝ) => ((-1:ℝ),z)) q := + contDiffAt_const.prodMk contDiffAt_id + have hq' := (coordinateBackward_contMDiffAt (q := (-1,q.1,q.2)) hq).comp q + hi.contMDiffAt + have hb' : coordinateBackward a (-1,q.1,q.2)∈(chartAt (Model n) b).source := by + simpa only [extChartAt_source] using hb + exact ((contMDiffAt_extChartAt' hb').comp q hq').contDiffAt +end ContactDerivative +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactImage.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactImage.lean new file mode 100644 index 0000000000000000000000000000000000000000..cca77432314b4349dc3d85ac18a255bdec0e8e6e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactImage.lean @@ -0,0 +1,30 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Metric Manifold Bundle +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport + +section ContactImage +variable {M : Type*} [MetricSpace M] + +lemma contactGap_swap (u v : M → ℝ) (x y : M) : + contactGap u v x y=contactGap v u y x := by + simp only [contactGap,cost,dist_comm y x] + ring + +variable [MeasurableSpace M] +end ContactImage + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactJetCalculus.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactJetCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..78754edbef15deee56000dfb1e7281810af6ff41 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactJetCalculus.lean @@ -0,0 +1,38 @@ +import Mathlib + +namespace OAI + +section +noncomputable section +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F G:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] [NormedAddCommGroup G] [NormedSpace ℝ G] +lemma fderiv_contact_jet {g:E × F → G} {f:E → F} {x:E} + (hg:DifferentiableAt ℝ g (x,f x)) (hf:DifferentiableAt ℝ f x) : + fderiv ℝ (fun y=>g (y,f y)) x=(fderiv ℝ g (x,f x)).comp + ((ContinuousLinearMap.id ℝ E).prod (fderiv ℝ f x)) := by + exact (hg.hasFDerivAt.comp x ((hasFDerivAt_id x).prodMk hf.hasFDerivAt)).fderiv +lemma fderiv_contact_c2 {g:E × (E →L[ℝ] ℝ) → G} {φ:E → ℝ} {x:E} + (hg:ContDiffAt ℝ ∞ g (x,fderiv ℝ φ x)) (hφ:ContDiffAt ℝ 2 φ x) : + fderiv ℝ (fun y=>g (y,fderiv ℝ φ y)) x=(fderiv ℝ g (x,fderiv ℝ φ x)).comp + ((ContinuousLinearMap.id ℝ E).prod (fderiv ℝ (fderiv ℝ φ) x)) := by + exact fderiv_contact_jet (hg.differentiableAt (by simp)) + ((hφ.fderiv_right (m:=1) (by norm_num)).differentiableAt (by norm_num)) +lemma continuous_contact_jet_det (J:E × F →L[ℝ] E) (H Q:E →L[ℝ] F) : + Continuous (fun δ:ℝ=>|(J.comp ((ContinuousLinearMap.id ℝ E).prod (H-δ • Q))).det|) := by + have hH:Continuous (fun δ:ℝ=>H-δ • Q):=continuous_const.sub (continuous_id.smul continuous_const) + have hP:Continuous (fun δ:ℝ=>(ContinuousLinearMap.id ℝ E).prod (H-δ • Q)):= + (ContinuousLinearMap.prodL ℝ).continuous.comp (continuous_const.prodMk hH) + exact (ContinuousLinearMap.continuous_det.comp (continuous_const.clm_comp hP)).abs +lemma continuous_linearized_det (J:F →L[ℝ] E) (H Q:E →L[ℝ] F) : + Continuous (fun δ:ℝ=>|(J.comp (H-δ • Q)).det|) := by + have hH:Continuous (fun δ:ℝ=>H-δ • Q):=continuous_const.sub (continuous_id.smul continuous_const) + exact (ContinuousLinearMap.continuous_det.comp (continuous_const.clm_comp hH)).abs +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactPSD.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactPSD.lean new file mode 100644 index 0000000000000000000000000000000000000000..91115e7e99a3b3ff914a78c92efd1f2dcadfcf56 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactPSD.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Inner +import OAI.Analysis.BiholderTransport.Coordinates.Add +import OAI.Analysis.BiholderTransport.Coordinates.Stationary +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactPSD +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma normalCost_quadraticExpansion {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : + HasQuadraticExpansion (normalCost x p) (-p) (normalHessianOperator x p) := by + rw [hasQuadraticExpansion_iff_isLittleO] + have H := contDiffAt_second_order_remainder ((normalCost_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + convert H using 1 + funext h + rw [(normalCost_hasFDerivAt_zero hp).fderiv] + simp only [quadraticTaylor,innerSL_apply_apply,inner_normalHessianOperator,normalHessian] + ring + +omit [MeasurableSpace M] [BorelSpace M] in +lemma normal_contact_hessian_posSemidef + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈activeLogs (n := n) v x) (hpI : p∈injectivityDomain x) + {A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x} + (hexp : HasQuadraticExpansion (fun h => cTransform v (riemannianExp x h)) p A) + (e : TangentSpace 𝓘(ℝ,Model n) x) : + 0 ≤ inner ℝ ((normalHessianOperator x p+A) e) e := by + have H := (normalCost_quadraticExpansion hpI).add hexp + rw [neg_add_cancel] at H + apply H.nonneg_of_localMin _ e + apply Filter.Eventually.of_forall + intro h + have hgap := cTransform_gap_nonneg hv (riemannianExp x h) (riemannianExp x p) + have heq := hp.2 + simp only [contactGap,normalCost,riemannianExp_zero] at heq ⊢ hgap + linarith + +end ContactPSD +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactRelationChart.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactRelationChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..b48af2e056a1b2869a58d0503dbecb4990d2a35c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactRelationChart.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GlobalSupport +import OAI.Analysis.BiholderTransport.Duality.RiemannianTransport +import OAI.Analysis.BiholderTransport.Volume.EuclideanVolumeFactorNe + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Bundle +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section ContactRelationChart +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +def chartContactRelation (a b : M) (u v : M → ℝ) (T : Set M) + (z q : Model n) : Prop := + q∈(extChartAt 𝓘(ℝ,Model n) b).target ∧ + (extChartAt 𝓘(ℝ,Model n) b).symm q∈T ∧ + contactGap u v ((extChartAt 𝓘(ℝ,Model n) a).symm z) + ((extChartAt 𝓘(ℝ,Model n) b).symm q)=0 + +lemma chartContactRelation_volume_upper {lam cap : ℝ} {rho0 rho1 : M → ℝ} + (hlam : 0 < lam) + (hrho0 : AdmissibleDensity (metricVolume n) lam cap rho0) + (hrho1 : AdmissibleDensity (metricVolume n) lam cap rho1) + {u v : M →ᵇ ℝ} (hdual : IsCostDualPair u v) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (u,v) ≤ + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (a,b)) + {a b : M} {A : Set (Model n)} {T : Set M} (hA : MeasurableSet A) + (ha : A⊆(extChartAt 𝓘(ℝ,Model n) a).target) {Da Cb : ℝ≥0} + (hDa : LipschitzOnWith Da (extChartAt 𝓘(ℝ,Model n) a).symm A) + (hCb : LipschitzOnWith Cb (extChartAt 𝓘(ℝ,Model n) b) T) : + ENNReal.ofReal lam*metricVolume n {q | ∃ z∈A, chartContactRelation a b u v T z q} ≤ + ENNReal.ofReal cap*((Cb:ℝ≥0∞)*(Da:ℝ≥0∞))^n*metricVolume n A := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let ψ := extChartAt 𝓘(ℝ,Model n) b + let X := χ.symm '' A + let Y := contactImage u v X + have hXm : MeasurableSet X := hA.image_of_continuousOn_injOn + ((continuousOn_extChartAt_symm a).mono ha) (χ.symm.injOn.mono ha) + have hmass := (dual_minimizer_contactImage_mass hlam hrho0 hrho1 hdual hmin hXm).2.2.2 + have hsub : {q | ∃ z∈A, chartContactRelation a b u v T z q}⊆ψ '' (Y∩T) := by + rintro q ⟨z,hz,hq,hqT,hgap⟩ + refine ⟨ψ.symm q,⟨?_,hqT⟩,ψ.right_inv hq⟩ + exact ⟨χ.symm z,⟨z,hz,rfl⟩,hgap⟩ + have h1 := lipschitzOn_metricVolume_image_le (hCb.mono inter_subset_right : + LipschitzOnWith Cb ψ (Y∩T)) n + have h2 := lipschitzOn_metricVolume_image_le hDa n + calc + _ ≤ ENNReal.ofReal lam*metricVolume n (ψ '' (Y∩T)) := + mul_le_mul_right (measure_mono hsub) _ + _ ≤ ENNReal.ofReal lam*((Cb:ℝ≥0∞)^n*metricVolume n (Y∩T)) := + mul_le_mul_right h1 _ + _ ≤ ENNReal.ofReal lam*((Cb:ℝ≥0∞)^n*metricVolume n Y) := + mul_le_mul_right (mul_le_mul_right (measure_mono inter_subset_left) _) _ + _ = (Cb:ℝ≥0∞)^n*(ENNReal.ofReal lam*metricVolume n Y) := by ac_rfl + _ ≤ (Cb:ℝ≥0∞)^n*(ENNReal.ofReal cap*metricVolume n X) := + mul_le_mul_right hmass _ + _ ≤ (Cb:ℝ≥0∞)^n*(ENNReal.ofReal cap*((Da:ℝ≥0∞)^n*metricVolume n A)) := + mul_le_mul_right (mul_le_mul_right h2 _) _ + _ = _ := by rw [mul_pow]; ac_rfl + +end ContactRelationChart +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section AllLocalContact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.local_contact_global (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {x y : M} + (hmin : IsLocalMin (fun z => u z+cost z y) x) : contactGap u v x y=0 := by + obtain ⟨p,hp,rfl⟩ := exists_minimizing_vector (n := n) x y + have ht : (0:ℝ)<1/2 := by norm_num + have ht1 : (1:ℝ)/2<1 := by norm_num + have hID := contracted_minimizer_mem_injectivityDomain hp ht ht1 + have hcon := splitNormalAction_contact hp ht ht1 + simp only [splitNormalAction,normalCost,riemannianExp_zero] at hcon + have hsub : p∈normalSubdifferential u x := by + apply local_min_divided_cost_subgradient (t := 1/2) (by norm_num) hID + filter_upwards [hmin] with z hz + have H := squared_dist_divided_action_le z + (riemannianExp x ((1/2:ℝ) • p)) (riemannianExp x p) ht ht1 + have H' : cost z (riemannianExp x p)≤ + cost z (riemannianExp x ((1/2:ℝ) • p))/(1/2)+ + cost (riemannianExp x ((1/2:ℝ) • p)) (riemannianExp x p)/(1-1/2) := by + convert H using 1 <;> simp only [cost,div_div] + linarith only [hz,H',hcon] + rw [hdual.1] at hsub + have H := (hmtw.global_support hv hsub).2 + rw [←hdual.1] at H + have hupp : v (riemannianExp x p)≤-cost (riemannianExp x p) x-u x := by + rw [hdual.2,cTransform_le_iff hu] + intro a + have h := H a + rw [cost_symm a,cost_symm x] at h + linarith only [h] + have hgap := dualPair_gap_nonneg hv hdual x (riemannianExp x p) + dsimp only [contactGap] at hgap ⊢ + rw [cost_symm (riemannianExp x p)] at hupp + linarith only [hgap,hupp] + +lemma WeakMTW.chart_local_contact_global (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {a : M} {z : Model n} {y : M} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hmin : IsLocalMin (fun w => u ((extChartAt 𝓘(ℝ,Model n) a).symm w)+ + cost ((extChartAt 𝓘(ℝ,Model n) a).symm w) y) z) : + contactGap u v ((extChartAt 𝓘(ℝ,Model n) a).symm z) y=0 := by + let χ := extChartAt 𝓘(ℝ,Model n) a + have hx : χ.symm z∈χ.source := χ.map_target hz + have hc : ContinuousAt χ (χ.symm z) := + (continuousOn_extChartAt a (χ.symm z) hx).continuousAt + ((isOpen_extChartAt_source a).mem_nhds hx) + have hm : ∀ᶠ x in 𝓝 (χ.symm z), u (χ.symm z)+cost (χ.symm z) y≤u x+cost x y := by + have H : ∀ᶠ x in 𝓝 (χ.symm z), + u (χ.symm z)+cost (χ.symm z) y≤u (χ.symm (χ x))+cost (χ.symm (χ x)) y := by + have HH := hc.eventually (χ.right_inv hz ▸ hmin) + simpa only [show extChartAt 𝓘(ℝ,Model n) a=χ from rfl,χ.right_inv hz] using HH + filter_upwards [H,(isOpen_extChartAt_source a).mem_nhds hx] with x hx1 hx2 + simpa only [χ.left_inv hx2] using hx1 + exact hmtw.local_contact_global hu hv hdual hm + +end AllLocalContact +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactSelection.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactSelection.lean new file mode 100644 index 0000000000000000000000000000000000000000..0abc3aa5656de78a8ce8e512d5882ef144637712 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactSelection.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section ContactSelection +variable {M : Type*} [MetricSpace M] [CompactSpace M] + +lemma contact_selection_continuousAt {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + {T : M → M} (hT : ∀ z, contactGap u v z (T z)=0) {x : M} + (hx : ∀ y, contactGap u v x y=0 → y=T x) : ContinuousAt T x := by + rw [Metric.continuousAt_iff] + intro ε hε + let A := {z : M×M | contactGap u v z.1 z.2=0 ∧ z.2∉ball (T x) ε} + have hg : Continuous (fun z : M×M => contactGap u v z.1 z.2) := + ((hu.comp continuous_fst).add + (((continuous_fst.dist continuous_snd).pow 2).div_const 2)).add + (hv.comp continuous_snd) + have hA : IsClosed A := (isClosed_eq hg continuous_const).inter + (isOpen_ball.preimage continuous_snd).isClosed_compl + have hB : IsClosed (Prod.fst '' A) := isClosedMap_fst_of_compactSpace A hA + have hxB : x∉Prod.fst '' A := by + rintro ⟨⟨z,y⟩,⟨hzy,hy⟩,rfl⟩ + exact hy ((hx y hzy) ▸ mem_ball_self hε) + obtain ⟨δ,hδ,hball⟩ := Metric.mem_nhds_iff.mp (hB.isOpen_compl.mem_nhds hxB) + refine ⟨δ,hδ,fun {z} hz => ?_⟩ + by_contra hbad + exact hball hz ⟨(z,T z),⟨hT z,hbad⟩,rfl⟩ + +variable [Nonempty M] +def contactSelection {v : M → ℝ} (hv : Continuous v) (x : M) : M := + (cTransform_gap_zero hv x).choose + +lemma contactSelection_mem {v : M → ℝ} (hv : Continuous v) (x : M) : + contactGap (cTransform v) v x (contactSelection hv x)=0 := + (cTransform_gap_zero hv x).choose_spec + +end ContactSelection + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ContactStationarity.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ContactStationarity.lean new file mode 100644 index 0000000000000000000000000000000000000000..9942de438cf2bf31029fd4c13395957eb2ffc633 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ContactStationarity.lean @@ -0,0 +1,136 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SmoothTestPDE + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactStationarity +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + +def chartCostCovector (a b : M) (q : Model n×Model n) : Model n →L[ℝ] ℝ := + fderiv ℝ (chartCost a ((extChartAt 𝓘(ℝ,Model n) b).symm q.2)) q.1 + +lemma chartCostCovector_contDiffAt {a b : M} {q : Model n×Model n} + (ha : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hb : q.2∈(extChartAt 𝓘(ℝ,Model n) b).target) + (hc : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1,(extChartAt 𝓘(ℝ,Model n) b).symm q.2)) : + ContDiffAt ℝ ∞ (chartCostCovector a b) q := by + let F : Model n → Model n → ℝ := fun y x => + chartCost a ((extChartAt 𝓘(ℝ,Model n) b).symm y) x + have hiA := (contMDiffOn_extChartAt_symm (n := ∞) a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds ha) + have hiB := (contMDiffOn_extChartAt_symm (n := ∞) b).contMDiffAt + ((isOpen_extChartAt_target b).mem_nhds hb) + have hF : ContDiffAt ℝ ∞ (Function.uncurry F) q.swap := + (hc.comp q.swap ((hiA.comp q.swap contDiffAt_snd.contMDiffAt).prodMk + (hiB.comp q.swap contDiffAt_fst.contMDiffAt))).contDiffAt + exact (ContDiffAt.partial_snd_fderiv hF).comp q (contDiffAt_snd.prodMk contDiffAt_fst) + +variable [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma contact_stationarity_eventually {a b : M} {q : Model n×(Model n →L[ℝ] ℝ)} + (ha : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : chartGradientVector a q.1 q.2∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1)) + (hb : coordinateBackward a (-1,q.1,q.2)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + ∀ᶠ q' in 𝓝 q, chartCostCovector a b (q'.1,coordinateContact a b q')= -q'.2 := by + have hY : ContinuousAt (fun q : Model n×(Model n →L[ℝ] ℝ) => coordinateBackward a (-1,q.1,q.2)) q := + (coordinateBackward_contMDiffAt (q := (-1,q.1,q.2)) ha).continuousAt.comp + (x := q) (continuousAt_const.prodMk continuousAt_id) + have hT := hY.preimage_mem_nhds ((isOpen_extChartAt_source b).mem_nhds hb) + have hA := continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_target a).mem_nhds ha) + filter_upwards [hT,hA,chartGradientVector_regular_near ha hp] with q' hb' ha' hp' + dsimp only [chartCostCovector,coordinateContact] + rw [(extChartAt 𝓘(ℝ,Model n) b).left_inv hb'] + exact (chartCost_gradient_at_contact ha' hp').fderiv + +lemma chartTestContact_relative_hessian {a : M} {z : Model n} {φ : Model n → ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hp : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) : + let b := coordinateBackward a (-1,z,fderiv ℝ φ z) + let y := extChartAt 𝓘(ℝ,Model n) b b + let D := fderiv ℝ (chartCostCovector a b) (z,y) + fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a b)) z = + -((D.comp (ContinuousLinearMap.inr ℝ (Model n) (Model n))).comp + (fderiv ℝ (chartTestContact a b φ) z)) := by + dsimp only + let b := coordinateBackward a (-1,z,fderiv ℝ φ z) + let y := extChartAt 𝓘(ℝ,Model n) b b + let G := chartCostCovector (n := n) a b + let T := chartTestContact a b φ + have hTy : T z=y := rfl + have hy : y∈(extChartAt 𝓘(ℝ,Model n) b).target := + (extChartAt 𝓘(ℝ,Model n) b).map_source (mem_extChartAt_source b) + have hyb : (extChartAt 𝓘(ℝ,Model n) b).symm y=b := + (extChartAt 𝓘(ℝ,Model n) b).left_inv (mem_extChartAt_source b) + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z (fderiv ℝ φ z)⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) ((extChartAt 𝓘(ℝ,Model n) a).symm z, + (extChartAt 𝓘(ℝ,Model n) b).symm y) := by + rw [hyb,show b=riemannianExp _ (chartGradientVector a z (fderiv ℝ φ z)) from + coordinateBackward_eq_exp_chartGradient hz _] + exact hc + have hG : DifferentiableAt ℝ G (z,y) := + (chartCostCovector_contDiffAt hz hy hc').differentiableAt (by simp) + have hT : DifferentiableAt ℝ T z := + (chartTestContact_contDiffAt hz hφ (mem_extChartAt_source b)).differentiableAt (by simp) + have hgraph : HasFDerivAt (fun w => (w,T w)) + ((ContinuousLinearMap.id ℝ (Model n)).prod (fderiv ℝ T z)) z := + (hasFDerivAt_id z).prodMk hT.hasFDerivAt + have hggraph := hG.hasFDerivAt.comp z hgraph + have he : (fun w => G (w,T w))=ᶠ[𝓝 z] (fun w => -fderiv ℝ φ w) := by + have hZ : ContinuousAt (fun w => (w,fderiv ℝ φ w)) z := + continuousAt_id.prodMk (hφ.fderiv_right (m := 1) (by norm_num)).continuousAt + exact hZ.eventually (contact_stationarity_eventually hz hp (mem_extChartAt_source b)) + have heD := (hggraph.congr_of_eventuallyEq he.symm).unique + (((hφ.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)).hasFDerivAt.neg) + have hbaseMap : HasFDerivAt (fun w : Model n => (w,y)) + ((ContinuousLinearMap.id ℝ (Model n)).prod 0) z := + (hasFDerivAt_id z).prodMk (hasFDerivAt_const y z) + have hbase := hG.hasFDerivAt.comp (f := fun w : Model n => (w,y)) z hbaseMap + have hbaseEq : (fun w => G (w,y))=fderiv ℝ (chartCost a b) := by + funext w + change fderiv ℝ (chartCost a ((extChartAt 𝓘(ℝ,Model n) b).symm y)) w = _ + rw [hyb] + change HasFDerivAt (fun w => G (w,y)) _ z at hbase + rw [hbaseEq] at hbase + have hbaseD := hbase.fderiv + ext ξ η + have heV := congrArg (fun A : Model n →L[ℝ] Model n →L[ℝ] ℝ => A ξ η) heD + have hbV := congrArg (fun A : Model n →L[ℝ] Model n →L[ℝ] ℝ => A ξ η) hbaseD + dsimp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,zero_apply, + neg_apply,Pi.neg_apply] at heV hbV + have hsplit : (ξ,fderiv ℝ T z ξ)=(ξ,(0:Model n))+(0,fderiv ℝ T z ξ) := by simp + rw [hsplit,map_add,add_apply] at heV + change fderiv ℝ (fderiv ℝ φ) z ξ η+fderiv ℝ (fderiv ℝ (chartCost a b)) z ξ η = + -fderiv ℝ G (z,y) (0,fderiv ℝ T z ξ) η + simp only [neg_apply,zero_apply] at heV hbV + linarith only [heV,hbV] + +end ContactStationarity +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateScalarSupport.lean b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateScalarSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..e931628363dccab041dbee1ca861a6fff632777a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateScalarSupport.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates3 +import OAI.Analysis.BiholderTransport.Contact.CenterSupport + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinateScalarSupport (a : M) (φ : ℝ → ℝ) + (q : ((ℝ×ℝ)×(Model n×Model n))×Model n) : ℝ := + φ (q.1.1.1+cost ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.2.1) + (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))/q.1.1.2- + cost ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) + (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))/q.1.1.2) + +section +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma coordinateScalarSupport_eq {a : M} {b : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (v s : ℝ) (p z : Model n) (φ : ℝ → ℝ) : + coordinateScalarSupport a φ (((v,s),(b,p)),z)= + scalarCostSupport φ v ((extChartAt 𝓘(ℝ,Model n) a).symm b) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) s + ((extChartAt 𝓘(ℝ,Model n) a).symm z) := by + simp only [coordinateScalarSupport,scalarCostSupport,movingNormal_eq hb,map_smul] + +lemma coordinateScalarSupport_self (a : M) (v s : ℝ) (b p : Model n) (φ : ℝ → ℝ) : + coordinateScalarSupport a φ (((v,s),(b,p)),b)=φ v := by + simp only [coordinateScalarSupport,add_sub_cancel_right] + +end + +lemma coordinateScalarSupport_contDiffAt {a : M} {b p : Model n} {v s : ℝ} {φ : ℝ → ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hs : s≠0) + (hp : s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hφ : ContDiffAt ℝ ∞ φ v) : + ContDiffAt ℝ ∞ (coordinateScalarSupport a φ) (((v,s),(b,p)),b) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let Q := ((ℝ×ℝ)×(Model n×Model n))×Model n + let q : Q := (((v,s),(b,p)),b) + have hi : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ χ.symm b := + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds hb) + have hA : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun q : Q => movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2)) q := + (movingNormal_contMDiffAt (q := (b,s • p)) hb).comp + (f := fun q : Q => (q.1.2.1,q.1.1.2 • q.1.2.2)) q + (contDiffAt_fst.snd.fst.prodMk (contDiffAt_fst.fst.snd.smul contDiffAt_fst.snd.snd)).contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨χ.symm b,s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ (χ.symm b) p⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + have he : movingNormal a (b,s • p)=riemannianExp (χ.symm b) + (s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ (χ.symm b) p) := by + rw [movingNormal_eq hb,map_smul] + rw [←he] at hc + have hC : ContDiffAt ℝ ∞ (fun q : Q => cost (χ.symm q.1.2.1) + (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))) q := + (hc.comp (f := fun q : Q => (χ.symm q.1.2.1, + movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))) q + ((hi.comp (f := fun q : Q => q.1.2.1) q + contDiffAt_fst.snd.fst.contMDiffAt).prodMk hA)).contDiffAt + have hD : ContDiffAt ℝ ∞ (fun q : Q => cost (χ.symm q.2) + (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))) q := + (hc.comp (f := fun q : Q => (χ.symm q.2, + movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))) q + ((hi.comp (f := fun q : Q => q.2) q contDiffAt_snd.contMDiffAt).prodMk hA)).contDiffAt + have hF := (contDiffAt_fst.fst.fst.add (hC.div contDiffAt_fst.fst.snd hs)).sub + (hD.div contDiffAt_fst.fst.snd hs) + have hv : q.1.1.1+cost (χ.symm q.1.2.1) (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))/q.1.1.2- + cost (χ.symm q.2) (movingNormal a (q.1.2.1,q.1.1.2 • q.1.2.2))/q.1.1.2=v := by + dsimp only [q]; ring + exact (show ContDiffAt ℝ ∞ φ _ from hv.symm ▸ hφ).comp q hF + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupport.lean b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..71b26a556613b696562022ea98b7cf38d3b03521 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupport.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.CostSmooth +import OAI.Analysis.BiholderTransport.Regularity.ContDiffParametricQuadratic + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +section CoordinateSupport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma smooth_coordinate_half_cost_quadratic {A : Type*} [TopologicalSpace A] + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {ψ : E → M} (hψ : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,Model n) ∞ ψ 0) + {Y : A → M} {a : A} (hY : ContinuousAt Y a) {x : M} (hx : ψ 0=x) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + (hya : Y a=riemannianExp x ((1/2:ℝ) • p)) : + ∃ δ>0, ∃ K>0, ∀ᶠ b in 𝓝 a, + ∀ z∈Metric.ball (0:E) δ, + ∃ l : E →L[ℝ] ℝ, + ∀ w∈Metric.ball (0:E) δ, + 2*(cost (ψ w) (Y b)-cost (ψ z) (Y b))- + l (w-z) ≤ K*‖w-z‖^2 := by + let y := riemannianExp x ((1/2:ℝ) • p) + let d := extChartAt 𝓘(ℝ,Model n) y + have hyS : y∈d.source := mem_extChartAt_source y + have hyT : d y∈d.target := d.map_source hyS + have hdy : d.symm (d y)=y := d.left_inv hyS + have hID := contracted_minimizer_mem_injectivityDomain hp + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let F := fun q : E×Model n => (2:ℝ)*cost (ψ q.1) (d.symm q.2) + have hA : ContMDiffAt 𝓘(ℝ,E×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : E×Model n => ψ q.1) (0,d y) := + hψ.comp (0,d y) contDiffAt_fst.contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,E×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : E×Model n => d.symm q.2) (0,d y) := + ((contMDiffWithinAt_extChartAt_symm_target y hyT).contMDiffAt + ((isOpen_extChartAt_target y).mem_nhds hyT)).comp (0,d y) contDiffAt_snd.contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain + (⟨x,(1/2:ℝ) • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hID + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (ψ (0:E),d.symm (d y)) := by + simpa only [hx,hdy] using hC + have hF0 := hC'.comp (0,d y) (hA.prodMk hB) + have hF : ContDiffAt ℝ ∞ F (0,d y) := by + simpa only [Function.comp_def] using contDiffAt_const.mul hF0.contDiffAt + obtain ⟨δ,hδ,K,hK,H⟩ := contDiffAt_parametric_quadratic_upper hF + have hc : ContinuousAt (fun b => d (Y b)) a := + (show ContinuousAt d (Y a) by rw [hya]; exact continuousAt_extChartAt y).comp hY + have hdY : ∀ᶠ b in 𝓝 a, d (Y b)∈Metric.ball (d y) δ := by + apply hc.preimage_mem_nhds + apply Metric.isOpen_ball.mem_nhds + simpa only [hya,Metric.mem_ball,y,dist_self] using hδ + have hsrc : ∀ᶠ b in 𝓝 a, Y b∈d.source := + hY.preimage_mem_nhds ((isOpen_extChartAt_source y).mem_nhds (hya.symm ▸ hyS)) + refine ⟨δ,hδ,K,hK,?_⟩ + filter_upwards [hdY,hsrc] with b hb hbs + intro z hz + refine ⟨(fderiv ℝ F (z,d (Y b))).comp (ContinuousLinearMap.inl ℝ E (Model n)),?_⟩ + intro w hw + have HH := H z hz w hw (d (Y b)) hb + dsimp only [F] at HH + rw [d.left_inv hbs] at HH + change 2*(cost (ψ w) (Y b)-cost (ψ z) (Y b))- + (fderiv ℝ F (z,d (Y b))) (w-z,0) ≤ K*‖w-z‖^2 + change 2*cost (ψ w) (Y b)-2*cost (ψ z) (Y b)- + (fderiv ℝ F (z,d (Y b))) (w-z,0) ≤ K*‖w-z‖^2 at HH + simpa only [mul_sub] using HH + +end CoordinateSupport +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupportGradient.lean b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupportGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..b4e124543affff42f77745c0aa4a33e085f8c552 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/CoordinateSupportGradient.lean @@ -0,0 +1,148 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ShortForward +import OAI.Analysis.BiholderTransport.Convexity.ParametricShortLowerEnvelope +import OAI.Analysis.BiholderTransport.Contact.CoordinateScalarSupport + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma coordinateScalarSupport_hasFDerivAt {a : M} {b p : Model n} + {v s l : ℝ} {φ : ℝ → ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hs : s≠0) + (hp : s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hφ : HasDerivAt φ l v) : + HasFDerivAt (fun w => coordinateScalarSupport a φ (((v,s),(b,p)),w)) + (l • riemannianCoordinateMetric a b p) b := by + let L := riemannianCoordinateMetric a b p + have hi := riemannianCoordinateMetric_isInvertible hb + have hgrad : chartGradientVector a b (s • L)= + s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p := by + simp only [chartGradientVector,map_smul,L,hi.inverse_apply_self] + have he : coordinateBackward a (-1,b,s • L)=movingNormal a (b,s • p) := by + simp only [coordinateBackward,neg_neg,one_smul,map_smul,L,hi.inverse_apply_self] + have hC := chartCost_gradient_at_contact hb (hgrad.symm ▸ hp) + rw [he] at hC + let c := chartCost (n := n) a (movingNormal a (b,s • p)) + let f := fun w => v+c b/s+(-s⁻¹)*c w + have hf : HasFDerivAt f L b := by + apply ((hC.const_mul (-s⁻¹)).const_add (v+c b/s)).congr_fderiv + ext d + simp only [_root_.smul_apply,smul_eq_mul,neg_apply] + field_simp + have hf0 : f b=v := by dsimp only [f]; ring + have h : HasDerivAt φ l (f b) := hf0.symm ▸ hφ + have H := h.comp_hasFDerivAt b hf + have heq : (fun w => coordinateScalarSupport a φ (((v,s),(b,p)),w))= + fun w => φ (f w) := by + funext w + dsimp only [coordinateScalarSupport,f,c,chartCost] + congr 1 + ring + rw [heq] + exact H + +omit [Nonempty M] in +lemma coordinateScalarSupport_shortForward {a : M} {b p : Model n} + {v s l t : ℝ} {φ : ℝ → ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hs : s≠0) + (hp : s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hφ : HasDerivAt φ l v) : + shortForward a (fun w => coordinateScalarSupport a φ (((v,s),(b,p)),w)) (t,b)= + extChartAt 𝓘(ℝ,Model n) a (movingNormal a (b,(t*l) • p)) := by + rw [shortForward,(coordinateScalarSupport_hasFDerivAt hb hs hp hφ).fderiv] + simp only [coordinateBackward,neg_neg,map_smul, + (riemannianCoordinateMetric_isInvertible hb).inverse_apply_self,smul_smul,one_mul] + +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.exists_actual_center_support (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) {L : ℝ≥0} (hv : LipschitzWith L v) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hmono : Monotone φ) + {a : M} {b : Model n} (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + {l τ : ℝ} (hφ : HasDerivAt φ l (v ((extChartAt 𝓘(ℝ,Model n) a).symm b))) + (hl : 0 φ (v y)+ + cost y (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) (τ • r))/τ) + ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + ∃ p : Model n, + let y := (extChartAt 𝓘(ℝ,Model n) a).symm b + let s := (1+l)/2 + let ψ := fun w => coordinateScalarSupport a φ ((((v y),s),(b,p)),w) + 0 (fderiv ℝ C (a q,q)).comp I + have hmap := ha.prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hC' : ContDiffAt ℝ 2 C (a p,p) := by rwa [ha0] + have hd := ((hC'.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun q => (a q,q)) p hmap + have hG := hd.clm_comp (hasFDerivAt_const I p) + have heq : fderiv ℝ f =ᶠ[𝓝 p] G := by + have hn := hmap.continuousAt.eventually (hC'.eventually (by norm_num)) + filter_upwards [hf,hsupport,hn] with q hq hs hreg + let g : E → ℝ := fun v => f q+C (a q,v)-C (a q,q) + have hD := (hreg.differentiableAt (by norm_num)).hasFDerivAt.comp + (f := fun v : E => (a q,v)) q + ((hasFDerivAt_const (a q) q).prodMk (hasFDerivAt_id q)) + have hg : HasFDerivAt g (G q) q := by + convert! (hD.const_add (f q)).sub_const (C (a q,q)) using 1 + rw [upper_contact_fderiv hq hg.differentiableAt hs (by dsimp [g]; ring)] + exact hg.fderiv + apply (hG.congr_of_eventuallyEq heq).congr_fderiv + ext d e + simp only [ha0,ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,ContinuousLinearMap.comp_zero, + zero_add,zero_apply,sub_apply,smul_apply,smul_eq_mul, + innerSL_apply_apply,I] + have he : (R d,d)=((R d,0):E×E)+(0,d) := by simp + rw [he,map_add,add_apply,haq,hqq] + change -inner ℝ (R d) e+t*inner ℝ d e = t*inner ℝ d e-inner ℝ (R d) e + ring +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/GlobalSupport.lean b/lean/OAI/Analysis/BiholderTransport/Contact/GlobalSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..df902bb7a23b77c24bb79b0f34ed4a15a443ffb0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/GlobalSupport.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.CompactDual +import OAI.Analysis.BiholderTransport.CostGeometry.ProjectionContinuation + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.global_support + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ normalSubdifferential (cTransform v) x) : + p ∈ minimizingVectors x ∧ ∀ a : M, + cTransform v x+cost x (riemannianExp x p) ≤ + cTransform v a+cost a (riemannianExp x p) := by + let z : subgradientGraph (n := n) (cTransform v) := ⟨⟨x,p⟩,hp⟩ + have H := graph_global_min_at_left_limit (continuous_cTransform hv) (by norm_num : (0:ℝ)<1) + (fun t ht => hmtw.injective_graphProjection hv ht.1 ht.2) z + simpa only [one_smul,div_one,graphProjection,z] using H + +lemma WeakMTW.active_hull_global_support + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) : + p ∈ minimizingVectors x ∧ ∀ a : M, + cTransform v x+cost x (riemannianExp x p) ≤ + cTransform v a+cost a (riemannianExp x p) := + hmtw.global_support hv (active_hull_subset_normalSubdifferential hv x hp) + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +def twoMountain (x y₀ y₁ z : M) : ℝ := + max (cost x y₀-cost z y₀) (cost x y₁-cost z y₁) + +omit [CompactSpace M] [Nonempty M] in +lemma continuous_twoMountain (x y₀ y₁ : M) : Continuous (twoMountain x y₀ y₁) := + (continuous_const.sub (continuous_cost_left y₀)).max (continuous_const.sub (continuous_cost_left y₁)) + +omit [CompactSpace M] [Nonempty M] in +lemma twoMountain_self (x y₀ y₁ : M) : twoMountain x y₀ y₁ x=0 := by simp [twoMountain] + +lemma cTransform_eq_of_lower_mountain {f : M → ℝ} (hf : Continuous f) + {x y : M} (hx : f x=0) (hm : ∀ z, cost x y-cost z y≤f z) : + cTransform f y = -cost x y := by + apply le_antisymm + · rw [cTransform_le_iff hf] + intro z + rw [cost_symm y z] + linarith [hm z] + · have hh := cTransform_gap_nonneg hf y x + rw [contactGap,cost_symm y x,hx] at hh + linarith + +lemma cTransform_twoMountain_left (x y₀ y₁ : M) : + cTransform (twoMountain x y₀ y₁) y₀ = -cost x y₀ := + cTransform_eq_of_lower_mountain (continuous_twoMountain x y₀ y₁) + (twoMountain_self x y₀ y₁) (fun _ => le_max_left _ _) + +lemma cTransform_twoMountain_right (x y₀ y₁ : M) : + cTransform (twoMountain x y₀ y₁) y₁ = -cost x y₁ := + cTransform_eq_of_lower_mountain (continuous_twoMountain x y₀ y₁) + (twoMountain_self x y₀ y₁) (fun _ => le_max_right _ _) + +lemma cTransform_cTransform_twoMountain (x y₀ y₁ : M) : + cTransform (cTransform (twoMountain x y₀ y₁))=twoMountain x y₀ y₁ := by + funext z + apply le_antisymm (cTransform_cTransform_le (continuous_twoMountain x y₀ y₁) z) + apply max_le + · have h := cTransform_gap_nonneg (continuous_cTransform (continuous_twoMountain x y₀ y₁)) z y₀ + rw [contactGap,cTransform_twoMountain_left] at h + linarith + · have h := cTransform_gap_nonneg (continuous_cTransform (continuous_twoMountain x y₀ y₁)) z y₁ + rw [contactGap,cTransform_twoMountain_right] at h + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/GraphCompact.lean b/lean/OAI/Analysis/BiholderTransport/Contact/GraphCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a204e2e35e147bd69a0c380aeb1a113ed41423a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/GraphCompact.lean @@ -0,0 +1,328 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GraphProjection + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma isClosed_subgradientGraph {v : M → ℝ} (hv : Continuous v) : + IsClosed (subgradientGraph (n := n) (cTransform v)) := by + classical + apply isOpen_compl_iff.mp + apply isOpen_iff_mem_nhds.mpr + rintro ⟨x,p⟩ hp + have hn : p∉convexHull ℝ (activeLogs (n := n) v x) := by + intro hh + exact hp (active_hull_subset_normalSubdifferential hv x hh) + have : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + obtain ⟨f,K,hK,hpK⟩ := geometric_hahn_banach_closed_point + (convex_convexHull ℝ (activeLogs (n := n) v x)) + (isCompact_convexHull_finiteDimensional (isCompact_activeLogs (n := n) hv x)).isClosed hn + let e := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) x + have hx : x∈e.baseSet := mem_baseSet_trivializationAt _ _ x + let g : Model n →L[ℝ] ℝ := f.comp (e.continuousLinearEquivAt ℝ x hx).symm.toContinuousLinearMap + let F := fun z : TangentBundle 𝓘(ℝ,Model n) M => g (e z).2 + have hF (z : TangentBundle 𝓘(ℝ,Model n) M) (hz : z.1∈e.baseSet) : ContinuousAt F z := + g.continuous.continuousAt.comp ((e.toOpenPartialHomeomorph.continuousAt + (e.mem_source.mpr hz)).snd) + have hFx (q : TangentSpace 𝓘(ℝ,Model n) x) : F ⟨x,q⟩=f q := by + dsimp only [F,g,ContinuousLinearMap.comp_apply] + rw [e.apply_eq_prod_continuousLinearEquivAt ℝ x hx q] + exact congrArg f ((e.continuousLinearEquivAt ℝ x hx).symm_apply_apply q) + have HF : ∀ᶠ y in 𝓝 x, ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2∈activeLogs (n := n) v z.1 → z.1=y → F z a.2) + (x,⟨x,q⟩) := continuousAt_snd + have hc : ContinuousAt (fun a : M × TangentBundle 𝓘(ℝ,Model n) M => F a.2) + (x,⟨x,q⟩) := ContinuousAt.comp + (f := fun a : M × TangentBundle 𝓘(ℝ,Model n) M => a.2) + (g := F) (x := (x,⟨x,q⟩)) (hF ⟨x,q⟩ hx) hsnd + exact hc.eventually_lt continuousAt_const hqK + have hproj : Continuous (fun z : TangentBundle 𝓘(ℝ,Model n) M => z.1) := + FiberBundle.continuous_proj _ _ + have HK : ∀ᶠ z : TangentBundle 𝓘(ℝ,Model n) M in 𝓝 ⟨x,p⟩, K TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + apply (isCompact_bundle_disk (F := Model n) + (E := fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (Metric.diam (univ : Set M))).of_isClosed_subset + (isClosed_subgradientGraph hv) + intro z hz + exact active_hull_norm_le_diam (normalSubdifferential_subset_active_hull hv z.1 hz) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/GraphProjection.lean b/lean/OAI/Analysis/BiholderTransport/Contact/GraphProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca84fb2bd4017f3f88d79ebd6bbf5d42f93afcf0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/GraphProjection.lean @@ -0,0 +1,342 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.GraphOpen + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def subgradientGraph (u : M → ℝ) : Set (TangentBundle 𝓘(ℝ,Model n) M) := + {z | z.2∈normalSubdifferential (n := n) u z.1} + +def graphProjection (u : M → ℝ) (t : ℝ) (z : subgradientGraph (n := n) u) : M := + riemannianExp z.1.1 (t • z.1.2) + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma continuous_graphProjection (u : M → ℝ) (t : ℝ) : + Continuous (graphProjection (n := n) u t) := + (contMDiff_riemannianExp (n := n) (M := M)).continuous.comp + ((contMDiff_tangentScale (E := Model n) (M := M)).continuous.comp + (continuous_const.prodMk continuous_subtype_val)) + +lemma WeakMTW.isOpenMap_graphProjection (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma global_min_divided_cost_subgradient {u : M → ℝ} {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma uniform_cTransform_chart_lower (a : M) : + ∃ B>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ v : M → ℝ, Continuous v → + ∀ x∈ball (extChartAt 𝓘(ℝ,Model n) a a) r, + ∃ L : Model n →L[ℝ] ℝ, + ∀ y∈ball (extChartAt 𝓘(ℝ,Model n) a a) r, + cTransform v ((extChartAt 𝓘(ℝ,Model n) a).symm x)+L (y-x)-B*‖y-x‖^2 ≤ + cTransform v ((extChartAt 𝓘(ℝ,Model n) a).symm y) := by + obtain ⟨B,hB,r,hr,hrT,hjet⟩ := uniform_half_cost_hessian (n := n) a + refine ⟨2*B,by positivity,r,hr,hrT,?_⟩ + intro v hv x hx + let χ := extChartAt 𝓘(ℝ,Model n) a + obtain ⟨p,hp⟩ := nonempty_activeLogs (n := n) hv (χ.symm x) + let f := chartCost (n := n) a (riemannianExp (χ.symm x) ((1/2:ℝ) • p)) + refine ⟨(-2:ℝ) • fderiv ℝ f x,?_⟩ + intro y hy + have hrem := first_order_remainder_le_of_hessian_bound (convex_ball _ _) hB.le + (fun w hw => (hjet x hx p hp.1 w hw).1) + (fun w hw => (hjet x hx p hp.1 w hw).2) hx hy + have hlow := active_split_lower_support hv hp.1 hp.2 + (by norm_num : (0:ℝ)<1/2) (by norm_num : (1/2:ℝ)<1) (χ.symm y) + change |f y-f x-fderiv ℝ f x (y-x)|≤B*‖y-x‖^2 at hrem + change -(f y-f x)/(1/2:ℝ)≤cTransform v (χ.symm y)-cTransform v (χ.symm x) at hlow + have hU := (abs_le.mp hrem).2 + simp only [_root_.smul_apply,smul_eq_mul] + norm_num at hlow + nlinarith + +lemma uniform_hopfLax_chart_upper (a : M) : + ∃ B>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ t : ℝ, 0 t*u x) (continuous_const.mul hu) x hx + refine ⟨(-t⁻¹) • L,?_⟩ + intro y hy + rw [hopfLax_eq_neg_transform hu ht,hopfLax_eq_neg_transform hu ht] + simp only [_root_.smul_apply,smul_eq_mul] + have H' := mul_le_mul_of_nonpos_left (hL y hy) (neg_nonpos.mpr (inv_nonneg.mpr ht.le)) + convert H' using 1 + all_goals first | rfl | (simp only [div_eq_mul_inv]; ring) + +lemma WeakMTW.uniform_hopfLax_C11 (hmtw : WeakMTW (n := n) (M := M)) (a : M) : + ∃ B>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ t : ℝ, 0 hopfLax t u ((extChartAt 𝓘(ℝ,Model n) a).symm z)) x) ∧ + LipschitzOnWith (Real.toNNReal (6*(B/t+B/(1-t)))) + (fderiv ℝ (fun z => hopfLax t u ((extChartAt 𝓘(ℝ,Model n) a).symm z))) + (ball (extChartAt 𝓘(ℝ,Model n) a a) (r/4)) := by + obtain ⟨B,hB,r,hr,hrT,H⟩ := uniform_hopfLax_chart_upper (n := n) a + refine ⟨B,hB,r,hr,hrT,?_⟩ + intro t ht ht1 u v hu hv hdual + let χ := extChartAt 𝓘(ℝ,Model n) a + let S := ball (χ a) r + let f := fun z => hopfLax t u (χ.symm z) + let C := B/t+B/(1-t) + have hC : 0≤C := by dsimp [C]; positivity + have hid := hmtw.dual_hopfLax_identity hu hv hdual ht ht1 + have hsup : ∀ x∈S, ∃ L U : Model n →L[ℝ] ℝ, ∀ y∈S, + f x+L (y-x)-C*‖y-x‖^2≤f y ∧ f y≤f x+U (y-x)+C*‖y-x‖^2 := by + intro x hx + obtain ⟨U,hU⟩ := H t ht u hu x hx + obtain ⟨V,hV⟩ := H (1-t) (sub_pos.mpr ht1) v hv x hx + refine ⟨-V,U,?_⟩ + intro y hy + have hUy := hU y hy + have hVy := hV y hy + have hf (z : Model n) : hopfLax (1-t) v (χ.symm z) = -f z := by + dsimp [f] + rw [hid] + simp only [neg_neg] + change f y≤f x+U (y-x)+(B/t)*‖y-x‖^2 at hUy + rw [hf y,hf x] at hVy + have htB : 0≤B/t := by positivity + have htB' : 0≤B/(1-t) := by positivity + simp only [_root_.neg_apply] + dsimp only [C] + constructor + · nlinarith [mul_nonneg htB (sq_nonneg ‖y-x‖)] + · nlinarith [mul_nonneg htB' (sq_nonneg ‖y-x‖)] + have hrem := quadratic_remainder_of_two_supports isOpen_ball hC hsup + refine ⟨fun x hx => (hrem x hx).1,?_⟩ + change LipschitzOnWith (Real.toNNReal (6*C)) (fderiv ℝ f) (ball (χ a) (r/4)) + have he : Real.toNNReal (6*C) = (⟨6*C, mul_nonneg (by norm_num : (0:ℝ)≤6) hC⟩ : ℝ≥0) := by + exact Real.toNNReal_of_nonneg (mul_nonneg (by norm_num : (0:ℝ)≤6) hC) + rw [he] + exact derivative_lipschitz_of_quadratic_remainder hr hC (fun x hx => (hrem x hx).2) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/Inner.lean b/lean/OAI/Analysis/BiholderTransport/Contact/Inner.lean new file mode 100644 index 0000000000000000000000000000000000000000..e6e149fd86d76a45c757981a897db0755739efca --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/Inner.lean @@ -0,0 +1,35 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Calculus + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma convexOn_of_quadratic_lower_supports {f : E → ℝ} {S : Set E} + (hS : Convex ℝ S) (B : ℝ) + (hs : ∀ x∈S, ∃ L : E →L[ℝ] ℝ, ∀ y∈S, + f x+L (y-x)-B*‖y-x‖^2≤f y) : + ConvexOn ℝ S (fun x => f x+B*‖x‖^2) := by + apply convexOn_of_affine_lower_supports hS + intro x hx + obtain ⟨L,hL⟩ := hs x hx + refine ⟨L+(2*B) • innerSL ℝ x,?_⟩ + intro y hy + have H := hL y hy + simp only [_root_.add_apply,_root_.smul_apply,innerSL_apply_apply,inner_sub_right, + smul_eq_mul,real_inner_self_eq_norm_sq] + rw [norm_sub_sq_real] at H + have hi : inner ℝ y x=inner ℝ x y := real_inner_comm _ _ + rw [hi] at H + nlinarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/IntrinsicCEMS.lean b/lean/OAI/Analysis/BiholderTransport/Contact/IntrinsicCEMS.lean new file mode 100644 index 0000000000000000000000000000000000000000..0cdf44af52f8648bf803924298a41cf388a2da94 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/IntrinsicCEMS.lean @@ -0,0 +1,130 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ContactCharts +import OAI.Analysis.BiholderTransport.Contact.LocalCEMS2 +import OAI.Analysis.BiholderTransport.Volume.UniformCharts + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Bundle Metric +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section IntrinsicCEMS +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma exists_uniform_intrinsic_contact_bounds {ell upper : ℝ} (hell : 0 hz.2.1 + have hTBV : T '' B⊆V := by + rintro _ ⟨z,hz,rfl⟩ + exact hWs hz.2.2 + have hBm : MeasurableSet B := hGm.inter (hUo.inter hWo).measurableSet + have hloc := local_contact_cems_full hv hBm (fun z hz => hGD z (hBG hz)) + (hGi.mono hBG) (fun z hz => hReg z (hBG hz)) a b + (hBU.trans hUs) (hTBV.trans hVs) hC hC (hda.mono hBU) + (hdai.mono (image_mono hBU)) (hdb.mono hTBV) (hdbi.mono (image_mono hTBV)) + (ENNReal.ofReal_pos.mpr hell) (fun A hAm hAB => hmass A hAm (hAB.trans hBG)) + have hloc' := (ae_restrict_iff' hBm).mp hloc + refine ⟨U∩W,hUo.inter hWo,⟨hxU,hxW⟩,?_⟩ + filter_upwards [hloc',hGae] with z hz hzG hzUW + obtain ⟨p,A,hp,hpd,R,S,hl,hu,heq⟩ := hz ⟨hzG,hzUW⟩ + have hlr := ENNReal.toReal_mono ENNReal.ofReal_ne_top hl + have hur := ENNReal.toReal_mono + (ENNReal.mul_ne_top (ENNReal.mul_ne_top + (ENNReal.pow_ne_top ENNReal.coe_ne_top) ENNReal.ofReal_ne_top) + (ENNReal.pow_ne_top ENNReal.coe_ne_top)) hu + simp only [ENNReal.toReal_div,ENNReal.toReal_mul,ENNReal.toReal_pow, + ENNReal.coe_toReal,ENNReal.toReal_ofReal hell.le,ENNReal.toReal_ofReal hupper.le, + ENNReal.toReal_ofReal (abs_nonneg _)] at hlr hur + have hbounds := scalar_intrinsic_jacobian_bounds (abs_nonneg _) + (mul_nonneg (expJacobian_nonneg z p) (abs_nonneg _)) hell0.le hc hd + (hja z hzUW.1) (hjb (T z) (hWs hzUW.2)) hlr hur heq + exact ⟨p,A,hp,hpd,hbounds⟩ + +lemma minimizing_dualPair_uniform_intrinsic_cems {lam cap : ℝ} (hlam : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def NormalAlexandrovContact (v : M → ℝ) (x : M) + (p : TangentSpace 𝓘(ℝ,Model n) x) + (A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) : Prop := + p∈activeLogs (n := n) v x ∧ p∈injectivityDomain x ∧ + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (riemannianExp x h)) p A +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/LocalCEMS2.lean b/lean/OAI/Analysis/BiholderTransport/Contact/LocalCEMS2.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f001bb3265fca6628f077344be194ec4981a815 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/LocalCEMS2.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ContactPSD +import OAI.Analysis.BiholderTransport.Coordinates.AePullbackLipschitzChart +import OAI.Analysis.BiholderTransport.Regularity.PosSemidefApplyInner +import OAI.Analysis.BiholderTransport.Contact.LocalCEMS +import OAI.Analysis.BiholderTransport.Contact.ContactCharts2 +import OAI.Analysis.BiholderTransport.Volume.IntrinsicJacobian + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section LocalCEMS +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma local_contact_cems_full {v : M → ℝ} (hv : Continuous v) + {G : Set M} (hGm : MeasurableSet G) + (hGD : ∀ x∈G, MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + (hGi : InjOn (contactSelection hv) G) + (hReg : ∀ x∈G, ∃ p A, NormalAlexandrovContact (n := n) v x p A) + (a b : M) (hGs : G⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hTs : contactSelection hv '' G⊆(extChartAt 𝓘(ℝ,Model n) b).source) + {C D H K : ℝ≥0} (hC : 0 + if hz : z∈d '' G then (hEx z hz).choose else 0 + have hF (z : Model n) (hz : z∈d '' G) : + HasFDerivWithinAt (e ∘ T ∘ d.symm) (F z) (d '' G) z := by + simpa only [F,dite_eq_left hz] using (hEx z hz).choose_spec.1 + have hJac := ae_chart_jacobian_bounds d e hGm hIm hGs hTs hGi + hC hK hd hdi he hei hmass hF + filter_upwards [hJac,ae_restrict_mem hGm] with x hx hxG + have hxI : d x∈d '' G := ⟨x,hxG,rfl⟩ + have hFspec := (hEx (d x) hxI).choose_spec.2 + obtain ⟨y,hy,hyx,p,A,hp,R,S,hEq,hS,hR⟩ := hFspec + have hyx' : y=x := d.injOn (hGs hy) (hGs hxG) hyx + subst y + have hEq' : F (d x)=S.comp ((normalHessianOperator x p+A).comp R) := by + simpa only [F,dite_eq_left hxI] using hEq + rw [hEq'] at hx + refine ⟨p,A,hp,?_,R,S,hx.1,hx.2,?_⟩ + · apply posDef_of_posSemidef_injective + · intro w z + simp only [add_apply,inner_add_left,inner_add_right, + inner_normalHessianOperator,hp.2.2.1] + rw [← real_inner_comm w (normalHessianOperator x p z),inner_normalHessianOperator, + normalHessian_symm hp.2.1 w z] + · exact normal_contact_hessian_posSemidef hv hp.1 hp.2.1 hp.2.2.2 + · apply injective_middle_of_det_comp_ne_zero (by rfl) R S + intro hh + have hpos : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +variable [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_locally_uniform_test_det_bound + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 0 < lam) (hcap : 0 ≤ cap) (a b : M) : + ∃ U : Set (Model n), IsOpen U ∧ extChartAt 𝓘(ℝ,Model n) a a∈U ∧ + ∃ V : Set M, IsOpen V ∧ b∈V ∧ + ∃ K≥0, ∀ z∈U, ∀ (x0:M) (uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ φ : Model n → ℝ, ContDiffAt ℝ 2 φ z → + coordinateBackward a (-1,z,fderiv ℝ φ z)∈V → + chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z) → + uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)=φ z → + (∃ ε>0,∀ᶠ w in 𝓝 z,ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) → + (∃ m>0,∀ d : Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d) → + |(fderiv ℝ (chartTestContact a b φ) z).det|≤K := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let ψ := extChartAt 𝓘(ℝ,Model n) b + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨Da,r₁,hr₁,hchart₁,hDa⟩ := exists_lipschitzOn_inverse_chart (E := Model n) a + obtain ⟨Cb,R,hR,hT,hCb⟩ := exists_lipschitzOn_chart (n := n) b + let U := Metric.ball (χ a) r₁ + let V := Metric.ball b R + let K := (cap/lam)*((Cb:ℝ)*(Da:ℝ))^n + refine ⟨U,Metric.isOpen_ball,Metric.mem_ball_self hr₁,V,Metric.isOpen_ball, + Metric.mem_ball_self hR,K,by dsimp [K]; positivity,?_⟩ + intro z hz x0 uv huv φ hφ hYz hpφ hval hgap hpos + have hzT : z∈χ.target := hchart₁ hz + obtain ⟨ε,hε,hgap⟩ := hgap + obtain ⟨m,hm,hpos⟩ := hpos + obtain ⟨r₂,hr₂,_,hmount⟩ := exists_test_mountains hzT hφ hpφ hm hpos + let Y := fun w : Model n => coordinateBackward a (-1,w,fderiv ℝ φ w) + have hY : ContinuousAt Y z := + (coordinateBackward_contMDiffAt (q := (-1,z,fderiv ℝ φ z)) hzT).continuousAt.comp + (x := z) (f := fun w : Model n => ((-1:ℝ),w,fderiv ℝ φ w)) + (continuousAt_const.prodMk (continuousAt_id.prodMk + (hφ.fderiv_right (m := 1) (by norm_num)).continuousAt)) + have hYn : ∀ᶠ w : Model n in 𝓝 z,Y w∈V := + hY.preimage_mem_nhds (Metric.isOpen_ball.mem_nhds hYz) + have hnear : ∀ᶠ w : Model n in 𝓝 z, + ε*dist w z^2≤uv.1 (χ.symm w)-φ w ∧ + w∈U ∧ w∈Metric.ball z r₂ ∧ ContinuousAt φ w ∧ Y w∈V := by + filter_upwards [hgap,Metric.isOpen_ball.mem_nhds hz,Metric.ball_mem_nhds z hr₂, + hφ.eventually (by norm_num),hYn] with w hw h₁ h₂ hφw hYw + exact ⟨hw,h₁,h₂,hφw.continuousAt,hYw⟩ + obtain ⟨r,hr,hrsub⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hnear + obtain ⟨rho0,rho1,hrho0,hrho1,hmin⟩ := huv.2 + apply hmtw.lower_test_chart_det_bound hlam hcap hrho0 hrho1 + (densityDualClass_isDual huv) hmin hr hε + (fun w hw => hchart₁ (hrsub hw).2.1) + (hDa.mono (fun w hw => (hrsub hw).2.1)) hCb + (fun w hw => (hrsub hw).2.2.2.1.continuousWithinAt) + hval (fun w hw => (hrsub hw).1) (S := chartTestContact a b φ) ?_ ?_ + ((chartTestContact_contDiffAt hzT hφ (hT hYz)).hasStrictFDerivAt (by norm_num)) + · intro w hw + have hy : Y w∈ψ.source := hT (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + refine ⟨ψ.map_source hy,?_⟩ + change ψ.symm (ψ (Y w))∈Metric.ball b R + rw [ψ.left_inv hy] + exact (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + · intro w hw q hq + have hy : Y w∈ψ.source := hT (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + change φ w+cost (χ.symm w) (ψ.symm (ψ (Y w)))≤φ q+cost (χ.symm q) (ψ.symm (ψ (Y w))) + rw [ψ.left_inv hy] + exact hmount w (Metric.ball_subset_closedBall (hrsub (Metric.ball_subset_closedBall hw)).2.2.1) + q (Metric.ball_subset_closedBall (hrsub hq).2.2.1) + +end LocalUniformTestPDE +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/LowerTestContact.lean b/lean/OAI/Analysis/BiholderTransport/Contact/LowerTestContact.lean new file mode 100644 index 0000000000000000000000000000000000000000..5ef70658ff72f3a49334d78de16c0c1da1c7129d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/LowerTestContact.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.LocalJacobianBarrier + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory +open scoped Topology ENNReal NNReal + +namespace WeakMTWTransport +section LowerTestContact +variable {X Y : Type*} [MetricSpace X] [ProperSpace X] + +lemma lower_test_sublevel_contacts {v φ : X → ℝ} {c : X → Y → ℝ} + {S : X → Y} {R : X → Y → Prop} {x : X} {r h : ℝ} (hr : 0 < r) + (hv : ContinuousOn v (Metric.closedBall x r)) + (hc : ∀ y, ContinuousOn (fun w => c w y) (Metric.closedBall x r)) + (hboundary : ∀ w, dist w x=r → h ≤ v w-φ w) + (hlocal : ∀ w∈Metric.ball x r, ∀ z∈Metric.ball x r, + IsLocalMin (fun w => v w+c w (S z)) w → R w (S z)) + (hmountain : ∀ z∈Metric.ball x r, v z-φ z < h → + ∀ w∈Metric.closedBall x r, φ z+c z (S z) ≤ φ w+c w (S z)) : + ∀ z∈Metric.ball x r, v z-φ z < h → + ∃ w∈Metric.ball x r, v w-φ w < h ∧ R w (S z) := by + intro z hz hzgap + have hzclosed : z∈Metric.closedBall x r := Metric.ball_subset_closedBall hz + obtain ⟨w,hw,hmin⟩ := (isCompact_closedBall x r).exists_isMinOn + (Metric.nonempty_closedBall.mpr hr.le) (hv.add (hc (S z))) + have hvalue : v w+c w (S z) ≤ v z+c z (S z) := hmin hzclosed + have hmount : φ z+c z (S z) ≤ φ w+c w (S z) := hmountain z hz hzgap w hw + have hwgap : v w-φ w < h := by linarith only [hvalue,hmount,hzgap] + have hwin : w∈Metric.ball x r := by + apply lt_of_le_of_ne (Metric.mem_closedBall.mp hw) + intro he + exact (not_le_of_gt hwgap) (hboundary w he) + refine ⟨w,hwin,hwgap,hlocal w hwin z hz ?_⟩ + exact hmin.isLocalMin (Metric.closedBall_mem_nhds_of_mem hwin) + +end LowerTestContact +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology ENNReal NNReal + +namespace WeakMTWTransport +section LowerTestViscosity +variable {E Y : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + +lemma lower_test_abs_det_le {v φ : E → ℝ} {c : E → E → ℝ} + {S : E → E} {R : E → E → Prop} {x : E} {r₀ ε C : ℝ} + {A : E →L[ℝ] E} (hr₀ : 0 < r₀) (hε : 0 < ε) (hC : 0 ≤ C) + (hv : ContinuousOn v (Metric.closedBall x r₀)) + (hφ : ContinuousOn φ (Metric.closedBall x r₀)) + (hc : ∀ y, ContinuousOn (fun w => c w y) (Metric.closedBall x r₀)) + (hx : v x=φ x) + (hgap : ∀ w∈Metric.closedBall x r₀, ε*dist w x^2 ≤ v w-φ w) + (hlocal : ∀ w∈Metric.ball x r₀, ∀ z∈Metric.ball x r₀, + IsLocalMin (fun w => v w+c w (S z)) w → R w (S z)) + (hmountain : ∀ z∈Metric.ball x r₀, ∀ w∈Metric.closedBall x r₀, + φ z+c z (S z) ≤ φ w+c w (S z)) + (hvol : ∀ s : Set E, MeasurableSet s → s⊆Metric.ball x r₀ → + μ {y | ∃ w∈s, R w y} ≤ ENNReal.ofReal C*μ s) + (hS : HasStrictFDerivAt S A x) : |A.det| ≤ C := by + apply abs_det_le_of_small_image_bounds μ hS hC + intro U hU + obtain ⟨r,hr,hrU⟩ := Metric.nhds_basis_closedBall.mem_iff.mp + (inter_mem hU (Metric.ball_mem_nhds x hr₀)) + have hrsub : Metric.closedBall x r ⊆ Metric.closedBall x r₀ := + fun w hw => Metric.ball_subset_closedBall (hrU hw).2 + have hrb : Metric.ball x r ⊆ Metric.ball x r₀ := + fun w hw => (hrU (Metric.ball_subset_closedBall hw)).2 + let h := ε*r^2/2 + have hh : 0 < h := by dsimp [h]; positivity + let Ω : Set E := Metric.ball x r ∩ {w | v w-φ w < h} + have hΩopen : IsOpen Ω := + ((hv.sub hφ).mono (fun w hw => hrsub (Metric.ball_subset_closedBall hw))).isOpen_inter_preimage + Metric.isOpen_ball isOpen_Iio + have hxΩ : x∈Ω := by + exact ⟨Metric.mem_ball_self hr,by change v x-φ x < h; simpa only [hx,sub_self] using hh⟩ + have hΩsub : Ω⊆Metric.ball x r₀ := fun w hw => hrb hw.1 + have hcontact : S '' Ω ⊆ {y | ∃ w∈Ω, R w y} := by + rintro y ⟨z,hz,rfl⟩ + obtain ⟨w,hw,hwh,hwR⟩ := lower_test_sublevel_contacts hr + (hv.mono hrsub) (fun y => (hc y).mono hrsub) (h := h) + (fun w he => by + have H := hgap w (hrsub (Metric.mem_closedBall.mpr he.le)) + rw [he] at H + have H' : ε*r^2/2 ≤ ε*r^2 := by nlinarith only [mul_nonneg hε.le (sq_nonneg r)] + exact H'.trans H) + (fun w hw z hz => hlocal w (hrb hw) z (hrb hz)) + (fun z hz _ w hw => hmountain z (hrb hz) w (hrsub hw)) z hz.1 hz.2 + exact ⟨w,⟨hw,hwh⟩,hwR⟩ + refine ⟨Ω,fun w hw => (hrU (Metric.ball_subset_closedBall hw.1)).1, + (hΩopen.measure_pos μ ⟨x,hxΩ⟩).ne',?_,?_⟩ + · exact ne_top_of_le_ne_top (isCompact_closedBall x r).measure_lt_top.ne + (measure_mono (fun w hw => Metric.ball_subset_closedBall hw.1)) + · exact (measure_mono hcontact).trans (hvol Ω hΩopen.measurableSet hΩsub) + +end LowerTestViscosity +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/MatchedSupports.lean b/lean/OAI/Analysis/BiholderTransport/Contact/MatchedSupports.lean new file mode 100644 index 0000000000000000000000000000000000000000..14757c7a867800862f07b14fc69aa6ec1ec63df5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/MatchedSupports.lean @@ -0,0 +1,143 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma linear_supports_match {f : E → ℝ} {x : E} {L U : E →L[ℝ] ℝ} {B : ℝ} + (hnear : ∀ᶠ y in 𝓝 x, + f x+L (y-x)-B*‖y-x‖^2≤f y ∧ f y≤f x+U (y-x)+B*‖y-x‖^2) : L=U := by + have hmin : IsLocalMin (fun h : E => (U-L) h+(2*B)*‖h‖^2) 0 := by + have hn := ((continuous_const.add continuous_id).tendsto (0:E)).eventually + (show ∀ᶠ y in 𝓝 (x+(0:E)), _ from by simpa only [add_zero] using hnear) + filter_upwards [hn] with h hh + change f x + L (x+h-x) - B*‖x+h-x‖^2 ≤ f (x+h) ∧ + f (x+h) ≤ f x + U (x+h-x) + B*‖x+h-x‖^2 at hh + simp only [add_sub_cancel_left] at hh + simpa only [add_sub_cancel_left] using + (show (U-L) 0+(2*B)*‖(0:E)‖^2≤(U-L) h+(2*B)*‖h‖^2 from by + simp only [map_zero,norm_zero,zero_pow (by omega : 2≠0),mul_zero,zero_add, + _root_.sub_apply] + linarith [hh.1,hh.2]) + have hd : HasFDerivAt (fun h : E => (U-L) h+(2*B)*‖h‖^2) (U-L) 0 := by + convert (U-L).hasFDerivAt.add ((hasStrictFDerivAt_norm_sq (0:E)).hasFDerivAt.const_mul (2*B)) using 1 + all_goals first | rfl | (ext h; simp) + exact (sub_eq_zero.mp (hmin.hasFDerivAt_eq_zero hd)).symm + +lemma hasFDerivAt_of_quadratic_remainder {f : E → ℝ} {x : E} {L : E →L[ℝ] ℝ} + {B : ℝ} (hB : 0≤B) + (hnear : ∀ᶠ y in 𝓝 x, |f y-f x-L (y-x)|≤B*‖y-x‖^2) : + HasFDerivAt f L x := by + rw [hasFDerivAt_iff_isLittleO_nhds_zero,Asymptotics.isLittleO_iff] + intro ε hε + have hn : ∀ᶠ h : E in 𝓝 0, |f (x+h)-f x-L h|≤B*‖h‖^2 := by + simpa only [add_zero,add_sub_cancel_left] using + ((show Tendsto (fun h : E => x+h) (𝓝 0) (𝓝 x) from by + convert (continuous_const.add continuous_id : Continuous (fun h : E => x+h)).tendsto 0 using 1 + all_goals first | rfl | simp).eventually hnear) + have hr : ∀ᶠ h : E in 𝓝 0, ‖h‖<ε/(B+1) := + (continuous_norm.tendsto (0:E)).eventually (by + simpa only [norm_zero] using eventually_lt_nhds (show (0:ℝ)<ε/(B+1) by positivity)) + filter_upwards [hn,hr] with h hh hr + rw [Real.norm_eq_abs] + apply hh.trans + have hmul : (B+1)*‖h‖<ε := by + have := (lt_div_iff₀ (show 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma neg_cost_ray_lipschitz (z : TangentBundle 𝓘(ℝ,Model n) M) (y : M) : + ∃ K, LipschitzWith K (fun t => -cost (sprayFlow t z).1 y) := by + let C : ℝ≥0 := ⟨Metric.diam (univ:Set M),Metric.diam_nonneg⟩ + have hC : ∀ x y : M,dist x y≤C := fun x y => + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + have H : LipschitzWith C (fun x : M => cost x y) := by + rw [lipschitzWith_iff_dist_le_mul] + intro x x' + simpa only [Real.dist_eq] using cost_lipschitz_of_distance_bound hC x x' y + exact ⟨C*‖z.2‖₊,(H.comp (lipschitz_spray_projection z)).neg⟩ + +def rayMountainDifference (z : TangentBundle 𝓘(ℝ,Model n) M) (y : M) + (a vy b B0 By : ℝ) (t : ℝ) : ℝ := + -cost (sprayFlow t z).1 y+(1-t)^2*‖z.2‖^2/2+(a-vy-b*(By-B0)) + +omit [Nonempty M] in +lemma rayMountainDifference_lipschitzOn (z : TangentBundle 𝓘(ℝ,Model n) M) (y : M) + (a vy b B0 By T : ℝ) : + ∃ K, LipschitzOnWith K (rayMountainDifference z y a vy b B0 By) (Icc 0 T) := by + obtain ⟨K,hK⟩ := neg_cost_ray_lipschitz z y + have hc : ContDiff ℝ 1 (fun t : ℝ => (1-t)^2*‖z.2‖^2/2) := by fun_prop + obtain ⟨L,hL⟩ := hc.contDiffOn.exists_lipschitzOnWith (by norm_num) (convex_Icc 0 T) isCompact_Icc + refine ⟨K+L,?_⟩ + have H := (hK.lipschitzOnWith.add hL).add (LipschitzWith.const (a-vy-b*(By-B0))).lipschitzOnWith + simp only [add_zero] at H + exact H + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma rayMountainDifference_hasDerivAt {z : TangentBundle 𝓘(ℝ,Model n) M} {y : M} + (a vy b B0 By : ℝ) {t d : ℝ} + (hd : HasDerivAt (fun s => -cost (sprayFlow s z).1 y) d t) : + HasDerivAt (rayMountainDifference z y a vy b B0 By) (d-(1-t)*‖z.2‖^2) t := by + have hc0 := ((((hasDerivAt_const t (1:ℝ)).sub (hasDerivAt_id t)).pow 2).mul_const (‖z.2‖^2)).div_const 2 + have hc : HasDerivAt (fun s : ℝ => (1-s)^2*‖z.2‖^2/2) (-(1-t)*‖z.2‖^2) t := by + convert hc0 using 1 <;> norm_num + ring + have H := (hd.add hc).add_const (a-vy-b*(By-B0)) + have he' : d+(-(1-t)*‖z.2‖^2)=d-(1-t)*‖z.2‖^2 := by ring + rw [he'] at H + exact H + +omit [Nonempty M] in +lemma middle_mountain_barrier {z : TangentBundle 𝓘(ℝ,Model n) M} {y : M} + {a vy b B0 By D T : ℝ} (hb : 0≤b) (hD : 0 -cost (sprayFlow s z).1 y) t := + hC.ae_differentiableAt + filter_upwards [hae] with t ht htI hval + have hd := ht.hasDerivAt + have H := spray_neg_cost_deriv_le hd + have hmul : b≤b*(By-B0) := by nlinarith only [mul_nonneg hb (sub_nonneg.mpr hB)] + have hgap : dist (sprayFlow t z).1 y^2≤(1-t)^2*‖z.2‖^2-D/8 := by + dsimp only [rayMountainDifference,cost] at hval + linarith only [hval,hs,hmul,hb] + have Hn := norm_deficit_advance dist_nonneg (norm_nonneg z.2) htI.1 (htI.2.trans hT1) + (show 0≤D/8 by positivity) hgap + rw [(rayMountainDifference_hasDerivAt a vy b B0 By hd).deriv] + linarith only [H,Hn,hD] + +end + +open Set MeasureTheory +open scoped Topology Interval ContDiff + +def templateEps : ℝ := (2:ℝ)^(-10:ℤ) + +def centerGamma : ℝ := 8*Real.log 2047 + +def centerTemplate (s : ℝ) : ℝ := + 1-2/(1+Real.exp (-centerGamma*(s-5/8))) + +lemma templateEps_eq : templateEps=1/1024 := by norm_num [templateEps] +lemma centerGamma_pos : 0 < centerGamma := by + unfold centerGamma + positivity + +lemma centerTemplate_smooth : ContDiff ℝ ∞ centerTemplate := by + unfold centerTemplate + have hden : ∀ s:ℝ,1+Real.exp (-centerGamma*(s-5/8))≠0 := + fun s => ne_of_gt (by positivity) + exact contDiff_const.sub (contDiff_const.div (contDiff_const.add + (Real.contDiff_exp.comp (contDiff_const.mul (contDiff_id.sub contDiff_const)))) hden) + +lemma centerTemplate_bounds (s : ℝ) : -1 < centerTemplate s ∧ centerTemplate s < 1 := by + have hp := Real.exp_pos (-centerGamma*(s-5/8)) + have hden : 0 < 1+Real.exp (-centerGamma*(s-5/8)) := by positivity + unfold centerTemplate + constructor + · have H : 2/(1+Real.exp (-centerGamma*(s-5/8))) < 2 := + (div_lt_iff₀ hden).mpr (by linarith) + linarith + · have H : 0 < 2/(1+Real.exp (-centerGamma*(s-5/8))) := by positivity + linarith + +lemma centerTemplate_left {s:ℝ} (hs : s ≤ 1/2) : + 1-templateEps ≤ centerTemplate s := by + have Hs : centerGamma/8 ≤ -centerGamma*(s-5/8) := by + nlinarith [centerGamma_pos] + have he : Real.exp (centerGamma/8)=2047 := by + rw [centerGamma] + convert Real.exp_log (by norm_num : (0:ℝ)<2047) using 1 + congr 1 + ring + have H := Real.exp_le_exp.mpr Hs + rw [he] at H + have hden : 0 < 1+Real.exp (-centerGamma*(s-5/8)) := by positivity + have HH : 2/(1+Real.exp (-centerGamma*(s-5/8))) ≤ (1:ℝ)/1024 := + (div_le_iff₀ hden).mpr (by linarith only [H]) + rw [templateEps_eq] + unfold centerTemplate + linarith only [HH] + +lemma centerTemplate_right {s:ℝ} (hs : 3/4 ≤ s) : centerTemplate s < 0 := by + have hs' : -centerGamma*(s-5/8) < 0 := by nlinarith [centerGamma_pos] + have he : Real.exp (-centerGamma*(s-5/8)) < 1 := Real.exp_lt_one_iff.mpr hs' + have hden : 0 < 1+Real.exp (-centerGamma*(s-5/8)) := by positivity + have HH : 1 < 2/(1+Real.exp (-centerGamma*(s-5/8))) := + (lt_div_iff₀ hden).mpr (by linarith only [he]) + unfold centerTemplate + linarith only [HH] + +lemma hasDerivAt_centerTemplate (s:ℝ) : + HasDerivAt centerTemplate + (-2*centerGamma*Real.exp (-centerGamma*(s-5/8))/ + (1+Real.exp (-centerGamma*(s-5/8)))^2) s := by + have he := (((hasDerivAt_id s).sub_const (5/8:ℝ)).const_mul (-centerGamma)).exp + have H := (hasDerivAt_const s (1:ℝ)).sub ((hasDerivAt_const s (2:ℝ)).div + ((hasDerivAt_const s (1:ℝ)).add he) (by + change 1+Real.exp (-centerGamma*(s-5/8))≠0 + exact ne_of_gt (by positivity))) + have H' : HasDerivAt centerTemplate + (0-(0*(1+Real.exp (-centerGamma*(s-5/8)))- + 2*(0+Real.exp (-centerGamma*(s-5/8))*(-centerGamma*1)))/ + (1+Real.exp (-centerGamma*(s-5/8)))^2) s := H + convert H' using 1 + ring + +lemma centerTemplate_deriv_neg (s:ℝ) : deriv centerTemplate s < 0 := by + rw [(hasDerivAt_centerTemplate s).deriv] + have hden : 0 < (1+Real.exp (-centerGamma*(s-5/8)))^2 := by positivity + apply div_neg_of_neg_of_pos _ hden + exact mul_neg_of_neg_of_pos (mul_neg_of_neg_of_pos (by norm_num) centerGamma_pos) + (Real.exp_pos _) + +def outerVelocity (M0 K eta s : ℝ) : ℝ := + let kappa := K+1 + let A := M0+3 + let L := 128*A*kappa + let h0 := 1/(128*kappa) + (L-kappa*s)*Real.smoothTransition ((s+3*eta)/eta)* + (1-Real.smoothTransition ((s-h0)/h0)) + +def outerPrimitive (M0 K eta s : ℝ) : ℝ := + 1+templateEps/2+∫ q in (0:ℝ)..s,outerVelocity M0 K eta q + +def outerTemplate (M0 K eta s : ℝ) : ℝ := + outerPrimitive M0 K eta s* + (1-Real.smoothTransition ((s-(1-eta))/eta)) + +lemma outerVelocity_smooth (M0 K eta : ℝ) : ContDiff ℝ ∞ (outerVelocity M0 K eta) := by + unfold outerVelocity + fun_prop + +lemma outerVelocity_zero_left {M0 K eta s:ℝ} (heta : 0 < eta) (hs : s ≤ -3*eta) : + outerVelocity M0 K eta s=0 := by + have H : (s+3*eta)/eta ≤ 0 := div_nonpos_of_nonpos_of_nonneg (by linarith) heta.le + simp only [outerVelocity,Real.smoothTransition.zero_of_nonpos H,mul_zero,zero_mul] + +lemma outerVelocity_zero_right {M0 K eta s:ℝ} (hK : 1 ≤ K) + (hs : 2*(1/(128*(K+1))) ≤ s) : outerVelocity M0 K eta s=0 := by + have hh : 0 < 1/(128*(K+1)) := by positivity + have H : 1 ≤ (s-1/(128*(K+1)))/(1/(128*(K+1))) := + (le_div_iff₀ hh).mpr (by linarith only [hs]) + simp only [outerVelocity,Real.smoothTransition.one_of_one_le H,sub_self,mul_zero] + +lemma outerVelocity_core {M0 K eta s:ℝ} (heta : 0 < eta) + (hs : -2*eta ≤ s) (hs' : s ≤ 1/(128*(K+1))) (hK : 1 ≤ K) : + outerVelocity M0 K eta s=128*(M0+3)*(K+1)-(K+1)*s := by + have hh : 0 < 1/(128*(K+1)) := by positivity + have Hl : 1 ≤ (s+3*eta)/eta := (le_div_iff₀ heta).mpr (by linarith only [hs]) + have Hr : (s-1/(128*(K+1)))/(1/(128*(K+1))) ≤ 0 := + div_nonpos_of_nonpos_of_nonneg (by linarith only [hs']) hh.le + simp only [outerVelocity,Real.smoothTransition.one_of_one_le Hl, + Real.smoothTransition.zero_of_nonpos Hr,sub_zero,mul_one] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ModifiedActiveLowerJet.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ModifiedActiveLowerJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9809874e24d1035074df9dc1a023142b5d5c57e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ModifiedActiveLowerJet.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.ActualLowerJet + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma active_contact_biconjugate {v : M → ℝ} (hv : Continuous v) {x y : M} + (hactive : contactGap (cTransform v) v x y=0) : + cTransform (cTransform v) y=v y ∧ + contactGap (cTransform v) (cTransform (cTransform v)) x y=0 := by + have hle := cTransform_cTransform_le hv y + have hlo := cTransform_gap_nonneg (continuous_cTransform hv) y x + rw [contactGap,cost_symm y x] at hlo + have hact := hactive + rw [contactGap] at hact + have he : cTransform (cTransform v) y=v y := by linarith only [hle,hlo,hact] + exact ⟨he,by simpa only [contactGap,he] using hactive⟩ + +lemma WeakMTW.modified_active_lower_jet (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) + {t s : ℝ} (ht : 0 + v (riemannianExp x (pj i+d))+‖pj i+d‖^2/2) 0 + (w i • ((innerSL ℝ).comp R)) := by + have hdual : IsCostDualPair (cTransform v) (cTransform (cTransform v)) := + ⟨(cTransform_triple hv).symm,rfl⟩ + have H := hmtw.actual_active_lower_jet (continuous_cTransform hv) + (continuous_cTransform (continuous_cTransform hv)) hdual ht hts hs1 pj w hw hsum i + hmin (fun j => (active_contact_biconjugate hv (hactive j)).2) hleft hright ha ha0 harep + apply H.mono + · simp only [add_zero,(active_contact_biconjugate hv (hactive i)).1] + · filter_upwards [] with d + have H := cTransform_cTransform_le hv (riemannianExp x (pj i+d)) + linarith only [H] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/MovingCostSupport.lean b/lean/OAI/Analysis/BiholderTransport/Contact/MovingCostSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..2248f9c2fa82c0236a135ba175dd7cdffee4fff5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/MovingCostSupport.lean @@ -0,0 +1,337 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveCompact +import OAI.Analysis.BiholderTransport.Regularity.ContDiffParametricSecant +import OAI.Analysis.BiholderTransport.Coordinates.CompactEventuallyFiberwise + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma moving_half_cost_secant {A : Type*} [TopologicalSpace A] + {Y : A → M} {a : A} (hY : ContinuousAt Y a) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ minimizingVectors x) + (hya : Y a=riemannianExp x ((1/2:ℝ) • p)) + (h : TangentSpace 𝓘(ℝ,Model n) x) {K : ℝ} (hK : inner ℝ p h (2:ℝ)*cost (riemannianExp x (q.2 • h)) (d.symm q.1) + have hA : ContMDiffAt 𝓘(ℝ,Model n×ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×ℝ => riemannianExp x (q.2 • h)) (d y,0) := + (contMDiff_riemannianExp_fiber (n := n) x _).comp (d y,0) + (contDiffAt_snd.smul contDiffAt_const).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Model n×ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×ℝ => d.symm q.1) (d y,0) := + ((contMDiffWithinAt_extChartAt_symm_target y hyT).contMDiffAt + ((isOpen_extChartAt_target y).mem_nhds hyT)).comp (d y,0) contDiffAt_fst.contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain + (⟨x,(1/2:ℝ) • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hID + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) + (riemannianExp x ((0:ℝ) • h),d.symm (d y)) := by + simpa only [zero_smul,riemannianExp_zero,hdy] using hC + have hF0 := hC'.comp (d y,0) (hA.prodMk hB) + have hF : ContDiffAt ℝ ∞ F (d y,0) := + contDiffAt_const.mul hF0.contDiffAt + have hD : HasDerivAt (fun r : ℝ => F (d y,r)) (-inner ℝ p h) 0 := by + have hN : HasFDerivAt (normalCost x ((1/2:ℝ) • p)) + (innerSL ℝ (-((1/2:ℝ) • p))) ((id (0:ℝ)) • h) := by + simpa only [id_eq,zero_smul] using normalCost_hasFDerivAt_zero hID + have H := (hN.comp_hasDerivAt 0 + ((hasDerivAt_id (0:ℝ)).smul_const h)).const_mul (2:ℝ) + apply H.congr_deriv (by + simp only [innerSL_apply_apply,inner_neg_left,real_inner_smul_left,one_smul] + ring) |>.congr_of_eventuallyEq + exact Filter.Eventually.of_forall (fun r => by dsimp [F,normalCost,y]; rw [hdy]) + have hDF := hF.differentiableAt (by simp) |>.hasFDerivAt + have hDs := hDF.comp_hasDerivAt 0 ((hasDerivAt_const (0:ℝ) (d y)).prodMk (hasDerivAt_id (0:ℝ))) + have heD : fderiv ℝ F (d y,0) (0,1) = -inner ℝ p h := hDs.unique hD + have H := contDiffAt_parametric_secant_lower + (hF.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 1)) + (K := -K) (by rw [heD]; linarith) + have hySa : Y a∈d.source := hya.symm ▸ hyS + have hcY : ContinuousAt (fun q : ℝ×A => Y q.2) (0,a) := hY.comp continuousAt_snd + have hc : ContinuousAt (fun q : ℝ×A => (d (Y q.2),q.1)) (0,a) := + ((show ContinuousAt d (Y a) by rw [hya]; exact continuousAt_extChartAt y).comp (f := fun q : ℝ×A => Y q.2) (x := (0,a)) + hcY).prodMk continuousAt_fst + have hc' : Tendsto (fun q : ℝ×A => (d (Y q.2),q.1)) (𝓝 (0,a)) (𝓝 (d y,0)) := by + simpa only [hya] using hc.tendsto + have hnear : ∀ᶠ q : ℝ×A in 𝓝 (0,a), Y q.2∈d.source := + hcY.preimage_mem_nhds ((isOpen_extChartAt_source y).mem_nhds hySa) + filter_upwards [hc'.eventually H,hnear] with q hq hsrc ht + have hh := hq ht + dsimp only [F] at hh + rw [d.left_inv hsrc,zero_smul,riemannianExp_zero] at hh + linarith + +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma active_directional_upper_support {v : M → ℝ} (hv : Continuous v) {x : M} + (h : TangentSpace 𝓘(ℝ,Model n) x) {K : ℝ} + (hK : ∀ p∈activeLogs (n := n) v x, inner ℝ p h riemannianExp z.1 ((1/2:ℝ) • z.2) + have hY : Continuous Y := (contMDiff_riemannianExp (n := n) (M := M)).continuous.comp + ((contMDiff_tangentScale (E := Model n) (M := M)).continuous.comp + (continuous_const.prodMk continuous_id)) + have hg : ContinuousAt (fun t : ℝ => riemannianExp x (t • h)) 0 := + (continuous_riemannianExp x).continuousAt.comp (continuousAt_id.smul continuousAt_const) + have H : ∀ᶠ t : ℝ in 𝓝 0, ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2∈activeLogs (n := n) v z.1 → z.1=riemannianExp x (t • h) → + (0≤t → -2*(cost (riemannianExp x (t • h)) (Y z)-cost x (Y z))≤K*t) := by + apply compact_eventually_fiberwise (isCompact_total_activeLogs hv) + (FiberBundle.continuous_proj _ _) hg + rintro ⟨a,p⟩ hp he + simp only [zero_smul,riemannianExp_zero] at he + subst a + exact moving_half_cost_secant hY.continuousAt hp.1 rfl h (hK p hp) + filter_upwards [H] with t ht ht0 + obtain ⟨p,hp⟩ := nonempty_activeLogs (n := n) hv (riemannianExp x (t • h)) + have hh := ht ⟨riemannianExp x (t • h),p⟩ hp rfl ht0 + have hs := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) x + dsimp only [Y] at hh + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/PhaseContact.lean b/lean/OAI/Analysis/BiholderTransport/Contact/PhaseContact.lean new file mode 100644 index 0000000000000000000000000000000000000000..23255aa258e8bcd9fa8bc3fcdb85a5c5aa4ddaad --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/PhaseContact.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.CotangentFlow +import OAI.Analysis.BiholderTransport.Convexity.ProximalProducer + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma coordinatePhaseFlow_of_minimizer {a x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + {u:M → ℝ} (hu:Continuous u) (hp:p∈minimizingVectors x) + {t:ℝ} (ht:0hopfLax t u ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (extChartAt 𝓘(ℝ,Model n) a (sprayFlow t (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).1)) = + phaseLower a (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M)) := by + let w:TangentBundle 𝓘(ℝ,Model n) M:=⟨x,p⟩ + let z:=sprayFlow t w + let χ:=extChartAt 𝓘(ℝ,Model n) a + let η:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hf:=hopfLax_derivative_of_minimizer hu hp ht ht1 he hd + have hf':HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (hopfLax t u) z.1 (innerSL ℝ ((1:ℝ) • z.2)) := by + simpa only [one_smul] using hf + have hh:=coordinate_gradient_of_hasMFDerivAt z hz (hopfLax t u) 1 hf' + simp only [one_smul] at hh + have hi:=riemannianCoordinateMetric_isInvertible (χ.map_source hz) + have hraise:phaseRaise a (χ z.1,fderiv ℝ (fun q=>hopfLax t u (χ.symm q)) (χ z.1))=η z := by + apply Prod.ext + · rfl + · change (riemannianCoordinateMetric a (χ z.1)).inverse _=(η z).2 + rw [hh.fderiv,hi.inverse_apply_self] + change phaseLower a (η (sprayFlow (-t) (η.symm (phaseRaise a + (χ z.1,fderiv ℝ (fun q=>hopfLax t u (χ.symm q)) (χ z.1))))))=phaseLower a (η w) + rw [hraise,η.left_inv ((tangent_chart_source_iff _ _).mpr hz)] + rw [←sprayFlow_add,neg_add_cancel,sprayFlow_zero] + +omit [Nonempty M] in +lemma divided_kernel_gradient {a x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + {t:ℝ} (ht:t≠0) (hp:t • p∈injectivityDomain x) + (hx:x∈(extChartAt 𝓘(ℝ,Model n) a).source) : + HasFDerivAt (fun y=>cost ((extChartAt 𝓘(ℝ,Model n) a).symm y) + (riemannianExp x (t • p))/t) + (-(phaseLower a (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M))).2) + (extChartAt 𝓘(ℝ,Model n) a x) := by + have hg:=cost_start_gradient_of_injectivityDomain hp + have hg':HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (fun y=>cost y (riemannianExp x (t • p))) x + (innerSL ℝ ((-t) • p)) := by simpa only [neg_smul] using hg + have hc:=coordinate_gradient_of_hasMFDerivAt (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M) + hx (fun y=>cost y (riemannianExp x (t • p))) (-t) hg' + simp only [div_eq_mul_inv] + apply (hc.mul_const t⁻¹).congr_fderiv + ext v + simp only [smul_apply, neg_apply,smul_eq_mul,phaseLower] + field_simp + rfl + +lemma phase_contact_semiconvex {a x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + {u:M → ℝ} (hu:Continuous u) (hp:p∈minimizingVectors x) + {t:ℝ} (ht:0u ((extChartAt 𝓘(ℝ,Model n) a).symm y)+K/2*‖y‖^2)) : + let Q:=coordinatePhaseFlow a (t, + extChartAt 𝓘(ℝ,Model n) a (sprayFlow t (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).1, + fderiv ℝ (fun z=>hopfLax t u ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (extChartAt 𝓘(ℝ,Model n) a (sprayFlow t (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).1)) + Q.1=extChartAt 𝓘(ℝ,Model n) a x ∧ + IsSemiconvexSubgradientOn (fun y=>u ((extChartAt 𝓘(ℝ,Model n) a).symm y)) s K Q.1 + ((InnerProductSpace.toDual ℝ (Model n)).symm Q.2) := by + dsimp only + rw [coordinatePhaseFlow_of_minimizer hu hp ht ht1.le he hz hd] + refine ⟨rfl,?_⟩ + have hk:=divided_kernel_gradient ht.ne' (contracted_minimizer_mem_injectivityDomain hp ht ht1) hx + have hmin:∀ᶠ y in 𝓝 (extChartAt 𝓘(ℝ,Model n) a x), + u ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a x))+ + cost ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a x)) + (riemannianExp x (t • p))/t ≤ + u ((extChartAt 𝓘(ℝ,Model n) a).symm y)+ + cost ((extChartAt 𝓘(ℝ,Model n) a).symm y) (riemannianExp x (t • p))/t := by + apply Eventually.of_forall + intro y + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv hx,riemannianExp_smul,←he] + exact hopfLax_le hu t _ _ + have HH:=kernel_minimum_semiconvex_subgradient hsem hxs hk hmin + simp only [neg_neg] at HH + convert HH using 1 + rfl + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/ProximalSelectorDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Contact/ProximalSelectorDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..f67599c5d150f384dd1d117065141592e2558233 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/ProximalSelectorDerivative.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SubgradientDifferential + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma semiconvex_subgradient_along_selector {f : E → ℝ} {Y ξ : E → E} + {x p : E} {A R : E →L[ℝ] E} + (hA : ∀ v w, inner ℝ (A v) w=inner ℝ v (A w)) + (hexp : HasQuadraticExpansion (fun h => f (Y x+h)) p A) + {r : ℝ} (hr : 0 < r) (K : ℝ) (hY : HasFDerivAt Y R x) + (hξ : ξ x=p) + (hg : ∀ᶠ z in 𝓝 x, + IsSemiconvexSubgradientOn f (Metric.ball (Y x) r) K (Y z) (ξ z)) : + HasFDerivAt ξ (A.comp R) x := by + obtain ⟨C,hC,hCb⟩ := hY.isBigO_sub.exists_pos + have hs : (fun z => ξ z-p-A (Y z-Y x)) =o[𝓝 x] (fun z => z-x) := by + rw [Asymptotics.isLittleO_iff] + intro eps heps + obtain ⟨d,hd,H⟩ := semiconvex_subgradient_uniform_differential hA hexp hr K + (eps/C) (div_pos heps hC) + have hn : ∀ᶠ z in 𝓝 x, ‖Y z-Y x‖ < d := by + simpa only [Metric.mem_ball,dist_eq_norm] using + hY.continuousAt.eventually (Metric.ball_mem_nhds (Y x) hd) + filter_upwards [hg,hCb.bound,hn] with z hz hbound hnear + have HH := H (Y z-Y x) (ξ z) hnear (by + intro w hw + have hw' : Y x+w∈Metric.ball (Y x) r := by + simpa only [Metric.mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using hw + have hh := hz (Y x+w) hw' + simpa only [add_sub_cancel,show w-(Y z-Y x)=Y x+w-Y z by abel] using hh) + calc + ‖ξ z-p-A (Y z-Y x)‖ ≤ (eps/C)*‖Y z-Y x‖ := HH + _ ≤ (eps/C)*(C*‖z-x‖) := mul_le_mul_of_nonneg_left hbound (div_nonneg heps.le hC.le) + _ = eps*‖z-x‖ := by field_simp + have ha := A.hasFDerivAt.comp x hY + rw [hasFDerivAt_iff_isLittleO] at ha ⊢ + convert hs.add ha using 1 + first + | rfl + | (ext z + simp only [Function.comp_def,ContinuousLinearMap.comp_apply,map_sub,hξ] + abel) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/SmoothSupportSemibound.lean b/lean/OAI/Analysis/BiholderTransport/Contact/SmoothSupportSemibound.lean new file mode 100644 index 0000000000000000000000000000000000000000..59241c8e0d1eec6353b076e141ee83edcf938b50 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/SmoothSupportSemibound.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.FullSet + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_fderiv_comp_with_acceleration {f : F → ℝ} {g : E → F} {x : E} + (hf : ContDiffAt ℝ 2 f (g x)) (hg : ContDiffAt ℝ 2 g x) (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => f (g a))) x v w = + fderiv ℝ (fderiv ℝ f) (g x) (fderiv ℝ g x v) (fderiv ℝ g x w)+ + fderiv ℝ f (g x) (fderiv ℝ (fderiv ℝ g) x v w) := by + have hgd := (hg.differentiableAt (by norm_num)).hasFDerivAt + have hd1 := ((hf.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := g) x hgd + have hd2 := ((hg.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt + have hd := hd1.clm_comp hd2 + have heq : (fun a => (fderiv ℝ f (g a)).comp (fderiv ℝ g a)) =ᶠ[𝓝 x] + fderiv ℝ (fun a => f (g a)) := by + filter_upwards [hgd.continuousAt.eventually (hf.eventually (by norm_num)), + hg.eventually (by norm_num)] with a hfa hga + exact ((hfa.differentiableAt (by norm_num)).hasFDerivAt.comp (f := g) a + (hga.differentiableAt (by norm_num)).hasFDerivAt).fderiv.symm + have H := congrArg (fun A : E →L[ℝ] E →L[ℝ] ℝ => A v w) + (hd.congr_of_eventuallyEq heq.symm).fderiv + simpa only [Function.comp_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.compL_apply,ContinuousLinearMap.flip_apply,add_apply,add_comm] using H + +lemma HasSecondTaylor.smooth_support_diag_le {f q : E → ℝ} + {l : E →L[ℝ] ℝ} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasSecondTaylor f l B) (hfd : HasFDerivAt f l 0) + (hq : ContDiffAt ℝ 2 q 0) (hval : q 0=f 0) + (hlo : q≤ᶠ[𝓝 0] f) (d:E) : + fderiv ℝ (fderiv ℝ q) 0 d d≤B d d := by + have hmin : IsLocalMin (fun x => f x-q x) 0 := by + filter_upwards [hlo] with x hx + change f 0-q 0≤f x-q x + rw [hval,sub_self] + linarith only [hx] + have hlin := hmin.hasFDerivAt_eq_zero + (hfd.sub (hq.differentiableAt (by norm_num)).hasFDerivAt) + have Hj := hf.sub (hasSecondTaylor_of_contDiffAt hq) + rw [hlin] at Hj + let remainder := B - fderiv ℝ (fderiv ℝ q) 0 + have hnonneg : 0 ≤ remainder d d := by + by_contra hnegative + have hnegative : remainder d d < 0 := lt_of_not_ge hnegative + have hdir : d ≠ 0 := by + intro hzero + subst d + simp at hnegative + have hnorm : 0 < ‖d‖ ^ 2 := sq_pos_of_pos (norm_pos_iff.mpr hdir) + let epsilon := -(remainder d d) / (4 * ‖d‖ ^ 2) + have hepsilon : 0 < epsilon := div_pos (neg_pos.mpr hnegative) (by positivity) + have hepsilon_mul : epsilon * ‖d‖ ^ 2 = -(remainder d d) / 4 := by + dsimp [epsilon] + field_simp + obtain ⟨radius, hradius, hball⟩ := + Metric.eventually_nhds_iff.mp ((Hj.eventually hepsilon).and hmin) + let delta := radius / (2 * (‖d‖ + 1)) + have hdelta : 0 < delta := div_pos hradius (by positivity) + have hdelta_mul : delta * (2 * (‖d‖ + 1)) = radius := + div_mul_cancel₀ _ (by positivity) + have hmem : delta • d ∈ Metric.ball (0 : E) radius := by + rw [Metric.mem_ball, dist_zero_right, norm_smul, Real.norm_eq_abs, abs_of_pos hdelta] + nlinarith [norm_nonneg d] + obtain ⟨htaylor, hminimum⟩ := hball hmem + change |f (delta • d) - q (delta • d) - (f 0 - q 0) - 0 - + remainder (delta • d) (delta • d) / 2| ≤ epsilon * ‖delta • d‖ ^ 2 at htaylor + have hbilinear : remainder (delta • d) (delta • d) = delta ^ 2 * remainder d d := by + simp only [map_smul, smul_apply, smul_eq_mul] + ring + have hscaled_norm : ‖delta • d‖ ^ 2 = delta ^ 2 * ‖d‖ ^ 2 := by + rw [norm_smul, Real.norm_eq_abs, abs_of_pos hdelta, mul_pow] + rw [hbilinear, hscaled_norm] at htaylor + have hupper := (abs_le.mp htaylor).2 + have hscaled_error : epsilon * (delta ^ 2 * ‖d‖ ^ 2) = + delta ^ 2 * (-(remainder d d) / 4) := by + calc + _ = delta ^ 2 * (epsilon * ‖d‖ ^ 2) := by ring + _ = _ := by rw [hepsilon_mul] + rw [hscaled_error] at hupper + have hstrict := mul_neg_of_pos_of_neg (sq_pos_of_pos hdelta) hnegative + change f 0 - q 0 ≤ f (delta • d) - q (delta • d) at hminimum + nlinarith + change 0 ≤ B d d - fderiv ℝ (fderiv ℝ q) 0 d d at hnonneg + linarith only [hnonneg] + +lemma HasSecondTaylor.smooth_support_diag_le_at {f q : E → ℝ} {x : E} + {l : E →L[ℝ] ℝ} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasSecondTaylor (fun h => f (x+h)) l B) (hfd : HasFDerivAt f l x) + (hq : ContDiffAt ℝ 2 q x) (hval : q x=f x) + (hlo : q≤ᶠ[𝓝 x] f) (d:E) : + fderiv ℝ (fderiv ℝ q) x d d≤B d d := by + have hc : ContinuousAt (fun h:E => x+h) 0 := continuousAt_const.add continuousAt_id + have hq' : ContDiffAt ℝ 2 (fun h:E => q (x+h)) 0 := by + exact (show ContDiffAt ℝ 2 q (x+0) by simpa only [add_zero] using hq).comp 0 + (contDiffAt_const.add contDiffAt_id) + have hd : HasFDerivAt (fun h:E => f (x+h)) l 0 := by + exact (hasFDerivAt_comp_add_left x).mpr (by simpa only [add_zero] using hfd) + have hv : q (x+0)=f (x+0) := by simpa only [add_zero] using hval + have hh : (fun h:E => q (x+h))≤ᶠ[𝓝 0] (fun h => f (x+h)) := by + have ht : Tendsto (fun h:E => x+h) (𝓝 0) (𝓝 x) := by + simpa only [add_zero] using hc.tendsto + exact ht.eventually hlo + have H := hf.smooth_support_diag_le hd hq' hv hh d + have he : fderiv ℝ (fun h:E => q (x+h))=(fun h => fderiv ℝ q (x+h)) := + funext (fun h => fderiv_comp_add_left x) + rw [he,fderiv_comp_add_left,add_zero] at H + exact H + +lemma bilinear_diag_sub_bound (B C : E →L[ℝ] E →L[ℝ] ℝ) (d:E) : + |B d d-C d d|≤‖B-C‖*‖d‖^2 := by + have H := (B-C).le_opNorm₂ d d + simpa only [sub_apply,Real.norm_eq_abs,pow_two,mul_assoc] using H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/SmoothTestPDE.lean b/lean/OAI/Analysis/BiholderTransport/Contact/SmoothTestPDE.lean new file mode 100644 index 0000000000000000000000000000000000000000..e3162152ac9f560304de5fe0ee9ff088f6bc33e7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/SmoothTestPDE.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.SectionOscillation +import OAI.Analysis.BiholderTransport.Contact.ContactDerivative +import OAI.Analysis.BiholderTransport.Geodesics.ChartLipschitz +import OAI.Analysis.BiholderTransport.Contact.TestMountains +import OAI.Analysis.BiholderTransport.Coordinates.ActualLowerTestBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section SmoothTestPDE +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def chartTestContact (a b : M) (φ : Model n → ℝ) (w : Model n) : Model n := + coordinateContact a b (w,fderiv ℝ φ w) + +lemma chartTestContact_contDiffAt {a b : M} {z : Model n} {φ : Model n → ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hb : coordinateBackward a (-1,z,fderiv ℝ φ z)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + ContDiffAt ℝ 1 (chartTestContact a b φ) z := by + have hA : ContDiffAt ℝ 1 (coordinateContact a b) (z,fderiv ℝ φ z) := + (coordinateContact_contDiffAt (a := a) (b := b) (q := (z,fderiv ℝ φ z)) hz hb).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 1) + have hB : ContDiffAt ℝ 1 (fun w : Model n => (w,fderiv ℝ φ w)) z := + contDiffAt_id.prodMk (hφ.fderiv_right (m := 1) (by norm_num)) + exact hA.comp (f := fun w : Model n => (w,fderiv ℝ φ w)) z hB + +variable [Nonempty M] [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_strict_test_det_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 0 < lam) (hcap : 0 ≤ cap) (a : M) (L : Model n →L[ℝ] ℝ) + (hp : chartGradientVector a (extChartAt 𝓘(ℝ,Model n) a a) L∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a a))) : + let z := extChartAt 𝓘(ℝ,Model n) a a + let b := coordinateBackward a (-1,z,L) + ∃ K≥0, ∀ (x0 : M) (uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ φ : Model n → ℝ, ContDiffAt ℝ 2 φ z → fderiv ℝ φ z=L → + uv.1 a=φ z → + (∃ ε>0, ∀ᶠ w : Model n in 𝓝 z, + ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) → + (∃ m>0, ∀ d : Model n, m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a b)) z d d) → + |(fderiv ℝ (chartTestContact a b φ) z).det|≤K := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let z := χ a + let b := coordinateBackward a (-1,z,L) + let ψ := extChartAt 𝓘(ℝ,Model n) b + have hz : z∈χ.target := χ.map_source (mem_extChartAt_source a) + have hza : χ.symm z=a := χ.left_inv (mem_extChartAt_source a) + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨Da,r₁,hr₁,hchart₁,hDa⟩ := exists_lipschitzOn_inverse_chart (E := Model n) a + obtain ⟨Cb,R,hR,hT,hCb⟩ := exists_lipschitzOn_chart (n := n) b + let K := (cap/lam)*((Cb:ℝ)*(Da:ℝ))^n + refine ⟨K,by dsimp [K]; positivity,?_⟩ + intro x0 uv huv φ hφ hL hval hgap hpos + obtain ⟨ε,hε,hgap⟩ := hgap + obtain ⟨m,hm,hpos⟩ := hpos + have hpφ : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain (χ.symm z) := by rwa [hL] + have hpos' : ∀ d : Model n, m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d := by + change fderiv ℝ φ z=L at hL + rw [hL] + exact hpos + obtain ⟨r₂,hr₂,_,hmount⟩ := exists_test_mountains hz hφ hpφ hm hpos' + let Y := fun w : Model n => coordinateBackward a (-1,w,fderiv ℝ φ w) + have hYz : Y z=b := by dsimp [Y,b]; rw [hL] + have hY : ContinuousAt Y z := + (coordinateBackward_contMDiffAt (q := (-1,z,fderiv ℝ φ z)) hz).continuousAt.comp + (x := z) (f := fun w : Model n => ((-1:ℝ),w,fderiv ℝ φ w)) + (continuousAt_const.prodMk (continuousAt_id.prodMk + (hφ.fderiv_right (m := 1) (by norm_num)).continuousAt)) + have hYn : ∀ᶠ w : Model n in 𝓝 z, Y w∈Metric.ball b R := + hY.preimage_mem_nhds (by rw [hYz]; exact Metric.ball_mem_nhds b hR) + have hnear : ∀ᶠ w : Model n in 𝓝 z, + ε*dist w z^2≤uv.1 (χ.symm w)-φ w ∧ + w∈Metric.ball z r₁ ∧ w∈Metric.ball z r₂ ∧ + ContinuousAt φ w ∧ Y w∈Metric.ball b R := + by + filter_upwards [hgap,Metric.ball_mem_nhds z hr₁,Metric.ball_mem_nhds z hr₂, + hφ.eventually (by norm_num),hYn] with w hw h₁ h₂ hφw hYw + exact ⟨hw,h₁,h₂,hφw.continuousAt,hYw⟩ + obtain ⟨r,hr,hrsub⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hnear + obtain ⟨rho0,rho1,hrho0,hrho1,hmin⟩ := huv.2 + apply hmtw.lower_test_chart_det_bound hlam hcap hrho0 hrho1 + (densityDualClass_isDual huv) hmin hr hε + (fun w hw => hchart₁ (hrsub hw).2.1) + (hDa.mono (fun w hw => (hrsub hw).2.1)) hCb + (fun w hw => (hrsub hw).2.2.2.1.continuousWithinAt) + (by change uv.1 (χ.symm z)=φ z; rw [hza]; exact hval) (fun w hw => (hrsub hw).1) + (S := chartTestContact a b φ) ?_ ?_ + ((chartTestContact_contDiffAt hz hφ (by change Y z∈ψ.source; rw [hYz]; exact mem_extChartAt_source b)).hasStrictFDerivAt (by norm_num)) + · intro w hw + have hy : Y w∈ψ.source := hT (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + refine ⟨ψ.map_source hy,?_⟩ + change ψ.symm (ψ (Y w))∈Metric.ball b R + rw [ψ.left_inv hy] + exact (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + · intro w hw q hq + have hy : Y w∈ψ.source := hT (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + change φ w+cost (χ.symm w) (ψ.symm (ψ (Y w)))≤φ q+cost (χ.symm q) (ψ.symm (ψ (Y w))) + rw [ψ.left_inv hy] + exact hmount w (Metric.ball_subset_closedBall (hrsub (Metric.ball_subset_closedBall hw)).2.2.1) + q (Metric.ball_subset_closedBall (hrsub hq).2.2.1) + +end SmoothTestPDE +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/Subgradient.lean b/lean/OAI/Analysis/BiholderTransport/Contact/Subgradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..c81d68b176879fade7ff44e67d30e70f62a1f142 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/Subgradient.lean @@ -0,0 +1,471 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +def IsSubgradientOn (f : E → ℝ) (s : Set E) (h zeta : E) : Prop := + ∀ y ∈ s, f h + inner ℝ zeta (y - h) ≤ f y + +def quadraticTaylor (f0 : ℝ) (p : E) (A : E →L[ℝ] E) (h : E) : ℝ := + f0 + inner ℝ p h + inner ℝ (A h) h / 2 + +def HasQuadraticExpansion (f : E → ℝ) (p : E) (A : E →L[ℝ] E) : Prop := + ∀ w : ℝ, 0 < w → ∃ delta : ℝ, 0 < delta ∧ + ∀ z : E, ‖z‖ < delta → + |f z - quadraticTaylor (f 0) p A z| ≤ w * ‖z‖ ^ 2 + +lemma convex_lipschitz_extension {f : E → ℝ} {s : Set E} {L : ℝ≥0} + (hc : ConvexOn ℝ s f) (hlip : LipschitzOnWith L f s) (hs : s.Nonempty) : + ∃ g : E → ℝ, LipschitzWith L g ∧ ConvexOn ℝ univ g ∧ EqOn f g s := by + have : Nonempty s := hs.to_subtype + let g := fun y : E => ⨅ x : s, f x + L * dist y x + have hB : ∀ y : E, BddBelow (range fun x : s => f x + L * dist y x) := by + intro y + obtain ⟨z,hz⟩ := hs + refine ⟨f z - L*dist y z, ?_⟩ + rintro w ⟨t,rfl⟩ + dsimp + rw [sub_le_iff_le_add,add_assoc,← mul_add,add_comm (dist y t)] + calc + f z ≤ f t + L * dist z t := hlip.le_add_mul hz t.2 + _ ≤ f t + L*(dist y z + dist y t) := by + gcongr + exact dist_triangle_left _ _ _ + have hEq : EqOn f g s := by + intro x hx + refine le_antisymm (le_ciInf fun y => hlip.le_add_mul hx y.2) ?_ + simpa only [add_zero,Subtype.coe_mk,mul_zero,dist_self] using ciInf_le (hB x) ⟨x,hx⟩ + have hgL : LipschitzWith L g := by + apply LipschitzWith.of_le_add_mul L + intro x y + rw [← sub_le_iff_le_add] + refine le_ciInf fun z => ?_ + rw [sub_le_iff_le_add] + calc + g x ≤ f z + L*dist x z := ciInf_le (hB x) _ + _ ≤ f z + L*dist y z + L*dist x y := by + rw [add_assoc,← mul_add,add_comm (dist y z)] + gcongr + exact dist_triangle _ _ _ + refine ⟨g,hgL,⟨convex_univ,?_⟩,hEq⟩ + intro x _ y _ a b ha hb hab + simp only [smul_eq_mul] + apply le_of_forall_pos_le_add + intro eps heps + obtain ⟨u,hu⟩ : ∃ u : s, f u + L*dist x u < g x + eps := + exists_lt_of_ciInf_lt (by dsimp [g]; linarith : g x < g x + eps) + obtain ⟨v,hv⟩ : ∃ v : s, f v + L*dist y v < g y + eps := + exists_lt_of_ciInf_lt (by dsimp [g]; linarith : g y < g y + eps) + have huv : a • (u:E) + b • (v:E) ∈ s := hc.1 u.2 v.2 ha hb hab + have hcf := hc.2 u.2 v.2 ha hb hab + have hdist : dist (a • x+b • y) (a • (u:E)+b • (v:E)) ≤ + a*dist x u + b*dist y v := by + rw [dist_eq_norm,dist_eq_norm,dist_eq_norm] + have heq : a • x+b • y-(a • (u:E)+b • (v:E)) = + a • (x-u) + b • (y-v) := by simp only [smul_sub]; abel + rw [heq] + calc + ‖a • (x-u)+b • (y-v)‖ ≤ ‖a • (x-u)‖+‖b • (y-v)‖ := norm_add_le _ _ + _ = a*‖x-u‖+b*‖y-v‖ := by rw [norm_smul_of_nonneg ha,norm_smul_of_nonneg hb] + calc + g (a • x+b • y) ≤ f (a • (u:E)+b • (v:E)) + + L*dist (a • x+b • y) (a • (u:E)+b • (v:E)) := + ciInf_le (hB _) ⟨_,huv⟩ + _ ≤ a*f u+b*f v + L*(a*dist x u+b*dist y v) := by + exact add_le_add hcf (mul_le_mul_of_nonneg_left hdist L.coe_nonneg) + _ = a*(f u+L*dist x u)+b*(f v+L*dist y v) := by ring + _ ≤ a*(g x+eps)+b*(g y+eps) := add_le_add + (mul_le_mul_of_nonneg_left hu.le ha) (mul_le_mul_of_nonneg_left hv.le hb) + _ = a*g x+b*g y+eps := by nlinarith [hab] + +open MeasureTheory + +lemma ae_of_locally_ae {X : Type*} [TopologicalSpace X] [SecondCountableTopology X] + [MeasurableSpace X] (μ : Measure X) {s : Set X} {P : X → Prop} + (hloc : ∀ x ∈ s, ∃ U : Set X, IsOpen U ∧ x ∈ U ∧ + (∀ᵐ z ∂μ, z ∈ U → P z)) : + ∀ᵐ z ∂μ, z ∈ s → P z := by + classical + choose U hUo hxU hUae using fun x : s => hloc x x.2 + have hcov : s ⊆ ⋃ x : s, U x := by + intro x hx + exact mem_iUnion.mpr ⟨⟨x,hx⟩,hxU ⟨x,hx⟩⟩ + obtain ⟨c,hc,hcover⟩ := (IsLindelof.of_coe (s := s)).elim_countable_subcover U hUo hcov + have hnull : μ (⋃ i ∈ c, {z | z ∈ U i ∧ ¬P z}) = 0 := by + apply (measure_biUnion_null_iff hc).mpr + intro i _ + simpa only [Classical.not_imp] using (ae_iff.mp (hUae i)) + apply ae_iff.mpr + apply measure_mono_null _ hnull + intro z hz + have hz' : z ∈ s ∧ ¬P z := by simpa only [mem_ofPred_eq,Classical.not_imp] using hz + obtain ⟨i,hi,hzi⟩ := mem_iUnion₂.mp (hcover hz'.1) + exact mem_iUnion₂.mpr ⟨i,hi,hzi,hz'.2⟩ + +namespace ConvexProximal + +def energy (f : E → ℝ) (y x : E) : ℝ := f x + ‖x-y‖^2/2 + +lemma norm_sq_add_real (a b : E) : + ‖a+b‖^2 = ‖a‖^2 + 2 * inner ℝ a b + ‖b‖^2 := by + simp only [← real_inner_self_eq_norm_sq, inner_add_left, inner_add_right] + rw [real_inner_comm b a] + ring + +lemma energy_increment (f : E → ℝ) (y x v : E) (t : ℝ) : + energy f y (x + t • (v-x)) - energy f y x = + f (x + t • (v-x)) - f x + + t * inner ℝ (x-y) (v-x) + t^2/2*‖v-x‖^2 := by + have heq : x + t • (v-x) - y = (x-y) + t • (v-x) := by abel + simp only [energy, heq, norm_sq_add_real, real_inner_smul_right, norm_smul, + mul_pow, Real.norm_eq_abs, sq_abs] + ring + +lemma subgradient_iff_minimizer {f : E → ℝ} (hf : ConvexOn ℝ univ f) (y x : E) : + IsSubgradientOn f univ x (y-x) ↔ ∀ v, energy f y x ≤ energy f y v := by + constructor + · intro hs v + have hh := hs v (mem_univ _) + have hi := energy_increment f y x v 1 + have heq : x + (1:ℝ) • (v-x) = v := by simp + rw [heq] at hi + have hí : inner ℝ (y-x) (v-x) = -inner ℝ (x-y) (v-x) := by + rw [← neg_sub x y, inner_neg_left] + rw [hí] at hh + nlinarith [sq_nonneg ‖v-x‖] + · intro hm v _ + have hb (t : ℝ) (ht : t ∈ Ioo 0 1) : + f x + inner ℝ (y-x) (v-x) ≤ f v + t/2*‖v-x‖^2 := by + have hc := hf.2 (mem_univ x) (mem_univ v) (by linarith [ht.2] : 0 ≤ 1-t) + ht.1.le (by ring : 1-t+t=1) + have heq : (1-t) • x + t • v = x + t • (v-x) := by + simp only [sub_smul, one_smul, smul_sub] + abel + rw [heq] at hc + have hi := energy_increment f y x v t + have hlo := hm (x + t • (v-x)) + have hinner : inner ℝ (y-x) (v-x) = -inner ℝ (x-y) (v-x) := by + rw [← neg_sub x y, inner_neg_left] + rw [hinner] + have hc' : f (x + t • (v-x)) ≤ (1-t)*f x + t*f v := by + simpa only [smul_eq_mul] using hc + apply (mul_le_mul_iff_left₀ ht.1).mp + nlinarith + have hcl : (0 : ℝ) ∈ closure (Ioo 0 1) := by + rw [closure_Ioo (by norm_num : (0:ℝ) ≠ 1)] + simp + have hc : Continuous (fun t : ℝ => f v + t/2*‖v-x‖^2) := by fun_prop + have hh := ContinuousWithinAt.closure_le hcl + (continuousWithinAt_const (b := f x + inner ℝ (y-x) (v-x))) hc.continuousWithinAt hb + simpa using hh + +lemma subgradient_strong_min {f : E → ℝ} {y x : E} + (hs : IsSubgradientOn f univ x (y-x)) (v : E) : + energy f y x + ‖v-x‖^2/2 ≤ energy f y v := by + have hh := hs v (mem_univ _) + have hi := energy_increment f y x v 1 + have heq : x + (1:ℝ) • (v-x) = v := by simp + rw [heq] at hi + have hí : inner ℝ (y-x) (v-x) = -inner ℝ (x-y) (v-x) := by + rw [← neg_sub x y, inner_neg_left] + rw [hí] at hh + nlinarith + +lemma subgradient_monotone {f : E → ℝ} {x z p q : E} + (hp : IsSubgradientOn f univ x p) (hq : IsSubgradientOn f univ z q) : + 0 ≤ inner ℝ (p-q) (x-z) := by + have h1 := hp z (mem_univ _) + have h2 := hq x (mem_univ _) + rw [← neg_sub x z, inner_neg_right] at h1 + simp only [inner_sub_left] + linarith + +lemma minimizer_unique {f : E → ℝ} (hf : ConvexOn ℝ univ f) {y x z : E} + (hx : ∀ v, energy f y x ≤ energy f y v) + (hz : ∀ v, energy f y z ≤ energy f y v) : x = z := by + have hs := (subgradient_iff_minimizer hf y x).mpr hx + have hb := subgradient_strong_min hs z + have hh := hz x + have hzero : ‖z-x‖ = 0 := by nlinarith [norm_nonneg (z-x)] + exact (sub_eq_zero.mp (norm_eq_zero.mp hzero)).symm + +variable [FiniteDimensional ℝ E] + +lemma exists_minimizer {f : E → ℝ} {L : ℝ≥0} (hf : LipschitzWith L f) (y : E) : + ∃ x, ∀ v, energy f y x ≤ energy f y v := by + let R : ℝ := 2*(L:ℝ)+1 + have hR : 0 ≤ R := by dsimp [R]; positivity + have hfc := hf.continuous + have hc : Continuous (energy f y) := by unfold energy; fun_prop + obtain ⟨x, hx, hmin⟩ := (isCompact_closedBall y R).exists_isMinOn + ⟨y, Metric.mem_closedBall_self hR⟩ hc.continuousOn + refine ⟨x, fun v => ?_⟩ + by_cases hv : v ∈ Metric.closedBall y R + · exact hmin hv + have hvR : R < ‖v-y‖ := by + simpa only [Metric.mem_closedBall, dist_eq_norm, not_le] using hv + have hh : f y - (L:ℝ)*‖v-y‖ ≤ f v := by + have hl := hf.dist_le_mul v y + rw [Real.dist_eq, dist_eq_norm] at hl + have hl' := (abs_le.mp hl).1 + linarith + have hpos : f y < energy f y v := by + dsimp [R] at hvR + unfold energy + nlinarith [show (0:ℝ) ≤ L from L.coe_nonneg] + have hxy : energy f y x ≤ energy f y y := hmin (Metric.mem_closedBall_self hR) + have ey : energy f y y = f y := by simp [energy] + rw [ey] at hxy + exact hxy.trans hpos.le + +def prox (f : E → ℝ) (L : ℝ≥0) (hf : LipschitzWith L f) (y : E) : E := + Classical.choose (exists_minimizer hf y) + +lemma prox_minimizes (f : E → ℝ) (L : ℝ≥0) (hf : LipschitzWith L f) (y v : E) : + energy f y (prox f L hf y) ≤ energy f y v := + Classical.choose_spec (exists_minimizer hf y) v + +lemma prox_subgradient {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hconv : ConvexOn ℝ univ f) (y : E) : + IsSubgradientOn f univ (prox f L hlip y) (y - prox f L hlip y) := + (subgradient_iff_minimizer hconv y _).mpr (prox_minimizes f L hlip y) + +lemma prox_of_subgradient {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hconv : ConvexOn ℝ univ f) {x p : E} (hp : IsSubgradientOn f univ x p) : + prox f L hlip (x+p) = x := by + apply minimizer_unique hconv (prox_minimizes f L hlip (x+p)) + apply (subgradient_iff_minimizer hconv (x+p) x).mp + simpa using hp + +lemma prox_firm {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hconv : ConvexOn ℝ univ f) (y z : E) : + ‖prox f L hlip y - prox f L hlip z‖^2 ≤ + inner ℝ (prox f L hlip y - prox f L hlip z) (y-z) := by + have hm := subgradient_monotone (prox_subgradient hlip hconv y) + (prox_subgradient hlip hconv z) + have heq : (y-prox f L hlip y) - (z-prox f L hlip z) = + (y-z) - (prox f L hlip y - prox f L hlip z) := by abel + rw [heq, inner_sub_left, real_inner_self_eq_norm_sq, real_inner_comm] at hm + linarith + +lemma prox_lipschitz {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hconv : ConvexOn ℝ univ f) : LipschitzWith 1 (prox f L hlip) := by + apply LipschitzWith.of_dist_le_mul + intro y z + have hf := prox_firm hlip hconv y z + have hi := real_inner_le_norm (prox f L hlip y - prox f L hlip z) (y-z) + have hnorm : ‖prox f L hlip y - prox f L hlip z‖ ≤ ‖y-z‖ := by + nlinarith [norm_nonneg (prox f L hlip y - prox f L hlip z), norm_nonneg (y-z)] + simpa only [NNReal.coe_one, one_mul, dist_eq_norm] using hnorm + +omit [FiniteDimensional ℝ E] in +lemma subgradient_norm_le {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + {x p : E} (hp : IsSubgradientOn f univ x p) : ‖p‖ ≤ L := by + have hs := hp (x+p) (mem_univ _) + have hl := hlip.dist_le_mul (x+p) x + simp only [add_sub_cancel_left, real_inner_self_eq_norm_sq] at hs + simp only [dist_eq_norm, add_sub_cancel_left] at hl + have hh := (abs_le.mp hl).2 + nlinarith [norm_nonneg p] + +lemma gradient_subgradient {f : E → ℝ} (hc : ConvexOn ℝ univ f) {x : E} + {f' : E →L[ℝ] ℝ} (hder : HasFDerivAt f f' x) : + IsSubgradientOn f univ x ((InnerProductSpace.toDual ℝ E).symm f') := by + intro v _ + rw [InnerProductSpace.toDual_symm_apply] + have hd : HasDerivAt (fun t : ℝ => f (x + t • (v-x))) (f' (v-x)) 0 := by + have hp : HasDerivAt (fun t : ℝ => x + t • (v-x)) (v-x) 0 := by + simpa using ((hasDerivAt_id (0 : ℝ)).smul_const (v-x)).const_add x + have hdf : HasFDerivAt f f' (x + (0:ℝ) • (v-x)) := by simpa using hder + exact hdf.comp_hasDerivAt 0 hp + have hb : ∀ᶠ t : ℝ in 𝓝[>] 0, + t⁻¹ * (f (x+t • (v-x)) - f x) ≤ f v - f x := by + filter_upwards [Ioo_mem_nhdsGT (by norm_num : (0:ℝ)<1)] with t ht + have hcv := hc.2 (mem_univ x) (mem_univ v) (by linarith [ht.2] : 0 ≤ 1-t) + ht.1.le (by ring : 1-t+t=1) + have heq : (1-t) • x + t • v = x + t • (v-x) := by + simp only [sub_smul, one_smul, smul_sub] + abel + rw [heq] at hcv + simp only [smul_eq_mul] at hcv + rw [inv_mul_eq_div, div_le_iff₀ ht.1] + nlinarith + have ht : Tendsto (fun t : ℝ => t⁻¹ * (f (x+t • (v-x)) - f x)) + (𝓝[>] 0) (𝓝 (f' (v-x))) := by + simpa only [zero_add, zero_smul, add_zero, smul_eq_mul] using hd.tendsto_slope_zero_right + have hh := le_of_tendsto ht hb + linarith + +lemma subgradient_eq_gradient {f : E → ℝ} {x p : E} {f' : E →L[ℝ] ℝ} + (hder : HasFDerivAt f f' x) (hp : IsSubgradientOn f univ x p) : + p = (InnerProductSpace.toDual ℝ E).symm f' := by + let g : E → ℝ := fun z => f z - inner ℝ p z + have hmin : IsLocalMin g x := by + apply Filter.Eventually.of_forall + intro z + have hh := hp z (mem_univ _) + dsimp [g] + simp only [inner_sub_right] at hh + linarith + have hdg : HasFDerivAt g (f' - innerSL ℝ p) x := + hder.sub (innerSL ℝ p).hasFDerivAt + have hz := hmin.hasFDerivAt_eq_zero hdg + have heq : f' = innerSL ℝ p := sub_eq_zero.mp hz + apply (InnerProductSpace.toDual ℝ E).injective + simp only [LinearIsometryEquiv.apply_symm_apply] + exact heq.symm + +omit [FiniteDimensional ℝ E] in +lemma isClosed_subgradient_projection {f : E → ℝ} (hf : Continuous f) + {K : Set E} (hK : IsCompact K) : + IsClosed {x | ∃ p ∈ K, IsSubgradientOn f univ x p} := by + have : CompactSpace K := isCompact_iff_compactSpace.mp hK + let C : Set (E × K) := {z | IsSubgradientOn f univ z.1 z.2.1} + have hC : IsClosed C := by + simp only [C, IsSubgradientOn, ofPred_forall] + exact isClosed_iInter fun _ => isClosed_iInter fun _ => + isClosed_le (by fun_prop) (by fun_prop) + have heq : {x | ∃ p ∈ K, IsSubgradientOn f univ x p} = Prod.fst '' C := by + ext x + constructor + · rintro ⟨p,hp,hpx⟩ + exact ⟨(x,⟨p,hp⟩),hpx,rfl⟩ + · rintro ⟨⟨z,p⟩,hz,rfl⟩ + exact ⟨p.1,p.2,hz⟩ + rw [heq] + exact isClosedMap_fst_of_compactSpace C hC + +lemma subgradient_continuity_at_singleton {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) {x p0 : E} + (huniq : ∀ p, IsSubgradientOn f univ x p → p = p0) : + ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ z p : E, ‖z-x‖ < delta → IsSubgradientOn f univ z p → ‖p-p0‖ < eps := by + intro eps heps + let K := Metric.closedBall (0:E) (L:ℝ) \ Metric.ball p0 eps + have hK : IsCompact K := (isCompact_closedBall _ _).diff Metric.isOpen_ball + have hclosed := isClosed_subgradient_projection hlip.continuous hK + have hx : x ∉ {z | ∃ p ∈ K, IsSubgradientOn f univ z p} := by + rintro ⟨p,hp,hpx⟩ + have heq := huniq p hpx + exact hp.2 (heq ▸ Metric.mem_ball_self heps) + obtain ⟨delta,hd,hball⟩ := Metric.mem_nhds_iff.mp (hclosed.isOpen_compl.mem_nhds hx) + refine ⟨delta,hd,?_⟩ + intro z p hz hp + by_contra hbad + have hpK : p ∈ K := by + constructor + · simpa only [Metric.mem_closedBall,dist_zero_right] using subgradient_norm_le hlip hp + · simpa only [Metric.mem_ball,dist_eq_norm] using hbad + exact (hball (by simpa only [Metric.mem_ball,dist_eq_norm] using hz)) ⟨p,hpK,hp⟩ + +lemma subgradient_continuity_of_differentiable {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) {x : E} {f' : E →L[ℝ] ℝ} (hder : HasFDerivAt f f' x) : + ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ z p : E, ‖z-x‖ < delta → IsSubgradientOn f univ z p → + ‖p-(InnerProductSpace.toDual ℝ E).symm f'‖ < eps := + subgradient_continuity_at_singleton hlip (fun _ hp => subgradient_eq_gradient hder hp) + +lemma uniform_subgradient_differential_of_regular_prox {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) (hc : ConvexOn ℝ univ f) + {x y : E} {f' : E →L[ℝ] ℝ} (hdf : HasFDerivAt f f' x) + (hy : prox f L hlip y = x) (B : E ≃L[ℝ] E) + (hdP : HasFDerivAt (prox f L hlip) (B : E →L[ℝ] E) y) : + ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ z p : E, ‖z-x‖ < delta → IsSubgradientOn f univ z p → + ‖p - (InnerProductSpace.toDual ℝ E).symm f' - + ((B.symm : E →L[ℝ] E) - ContinuousLinearMap.id ℝ E) (z-x)‖ ≤ + eps * ‖z-x‖ := by + let p0 := (InnerProductSpace.toDual ℝ E).symm f' + have hyp : y = x + p0 := by + have hs := prox_subgradient hlip hc y + rw [hy] at hs + have heq := subgradient_eq_gradient hdf hs + dsimp [p0] + rw [← heq] + abel + intro eps heps + let K : ℝ := ‖(B.symm : E →L[ℝ] E)‖ + 1 + have hK : 0 < K := by dsimp [K]; positivity + have hKbound : ‖(B.symm : E →L[ℝ] E)‖ ≤ K := by dsimp [K]; linarith + let eta : ℝ := min (1/(2*K)) (eps/(2*K^2)) + have heta : 0 < eta := by dsimp [eta]; positivity + have heta1 : K*eta ≤ 1/2 := by + have hh := min_le_left (1/(2*K)) (eps/(2*K^2)) + have hh' := (le_div_iff₀ (by positivity : 0 < 2*K)).mp hh + dsimp [eta] + nlinarith + have heta2 : 2*K^2*eta ≤ eps := by + have hh := min_le_right (1/(2*K)) (eps/(2*K^2)) + have hh' := (le_div_iff₀ (by positivity : 0 < 2*K^2)).mp hh + dsimp [eta] + nlinarith + obtain ⟨r,hr,hrem⟩ := Metric.mem_nhds_iff.mp (hdP.isLittleO.bound heta) + obtain ⟨d,hd,hcont⟩ := subgradient_continuity_of_differentiable hlip hdf (r/2) + (by positivity) + refine ⟨min d (r/2), by positivity, ?_⟩ + intro z p hz hp + have hpn : ‖p-p0‖ < r/2 := hcont z p (lt_of_lt_of_le hz (min_le_left _ _)) hp + let k : E := z+p-y + have hk : k = (z-x) + (p-p0) := by dsimp [k]; rw [hyp]; abel + have hkr : ‖z+p-y‖ < r := by + calc + ‖z+p-y‖ = ‖(z-x)+(p-p0)‖ := congrArg norm hk + _ ≤ ‖z-x‖ + ‖p-p0‖ := norm_add_le _ _ + _ < r := by have hz' := lt_of_lt_of_le hz (min_le_right _ _); linarith + have hPz : prox f L hlip (z+p) = z := prox_of_subgradient hlip hc hp + have hres : ‖(z-x) - B k‖ ≤ eta*‖k‖ := by + have hh := hrem (by simpa only [Metric.mem_ball,dist_eq_norm] using hkr) + simpa only [Set.mem_ofPred_eq, hy,hPz,k,ContinuousLinearEquiv.coe_coe] using hh + have hinv : k = B.symm (z-x) - B.symm ((z-x)-B k) := by + simp only [map_sub, B.symm_apply_apply] + abel + have hknorm : ‖k‖ ≤ 2*K*‖z-x‖ := by + have htri : ‖k‖ ≤ ‖B.symm (z-x)‖ + ‖B.symm ((z-x)-B k)‖ := by + conv_lhs => rw [hinv] + exact norm_sub_le _ _ + have h1 := (B.symm : E →L[ℝ] E).le_opNorm (z-x) + have h2 := (B.symm : E →L[ℝ] E).le_opNorm ((z-x)-B k) + have h1' : ‖B.symm (z-x)‖ ≤ K*‖z-x‖ := h1.trans + (mul_le_mul_of_nonneg_right hKbound (norm_nonneg _)) + have h2' : ‖B.symm ((z-x)-B k)‖ ≤ K*eta*‖k‖ := by + calc + ‖B.symm ((z-x)-B k)‖ ≤ K*‖(z-x)-B k‖ := h2.trans + (mul_le_mul_of_nonneg_right hKbound (norm_nonneg _)) + _ ≤ K*(eta*‖k‖) := mul_le_mul_of_nonneg_left hres hK.le + _ = K*eta*‖k‖ := by ring + have h3 := mul_le_mul_of_nonneg_right heta1 (norm_nonneg k) + nlinarith + have heq : p-p0-((B.symm : E →L[ℝ] E) - ContinuousLinearMap.id ℝ E) (z-x) = + - B.symm ((z-x)-B k) := by + simp only [sub_apply, ContinuousLinearMap.id_apply, + ContinuousLinearEquiv.coe_coe, map_sub, B.symm_apply_apply] + rw [hk] + abel + change ‖p-p0-((B.symm : E →L[ℝ] E) - ContinuousLinearMap.id ℝ E) (z-x)‖ ≤ _ + rw [heq,norm_neg] + calc + ‖B.symm ((z-x)-B k)‖ ≤ K*‖(z-x)-B k‖ := + ((B.symm : E →L[ℝ] E).le_opNorm _).trans + (mul_le_mul_of_nonneg_right hKbound (norm_nonneg _)) + _ ≤ K*(eta*‖k‖) := mul_le_mul_of_nonneg_left hres hK.le + _ ≤ K*(eta*(2*K*‖z-x‖)) := mul_le_mul_of_nonneg_left + (mul_le_mul_of_nonneg_left hknorm heta.le) hK.le + _ = (2*K^2*eta)*‖z-x‖ := by ring + _ ≤ eps*‖z-x‖ := mul_le_mul_of_nonneg_right heta2 (norm_nonneg _) + +end ConvexProximal +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientDifferential.lean b/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf0631b7439da827c318ebd3682633285d97b183 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientDifferential.lean @@ -0,0 +1,241 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma quadraticTaylor_increment (f0 : ℝ) (p : E) (A : E →L[ℝ] E) + (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) (h e : E) (t : ℝ) : + quadraticTaylor f0 p A (h + t • e) - quadraticTaylor f0 p A h = + t * inner ℝ (p + A h) e + t ^ 2 / 2 * inner ℝ (A e) e := by + have hs : inner ℝ (A e) h = inner ℝ (A h) e := (hA e h).trans (real_inner_comm _ _) + simp only [quadraticTaylor, map_add, map_smul, inner_add_left, inner_add_right, + real_inner_smul_left, real_inner_smul_right, hs] + ring + +lemma subgradient_directional_bound {f : E → ℝ} {f0 : ℝ} {p h zeta e : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) + {r alpha w : ℝ} (hr : 0 < r) (ha : 0 < alpha) (ha1 : alpha ≤ 1) + (hw : 0 ≤ w) (hh : ‖h‖ ≤ r) (he : ‖e‖ = 1) + (hrem : ∀ z : E, ‖z‖ ≤ 2*r → + |f z - quadraticTaylor f0 p A z| ≤ w * ‖z‖ ^ 2) + (hsub : IsSubgradientOn f (Metric.closedBall 0 (2*r)) h zeta) : + inner ℝ (zeta - p - A h) e ≤ ‖A‖ * alpha * r / 2 + 5*w*r/alpha := by + have hat : 0 < alpha*r := mul_pos ha hr + have hz : ‖h + (alpha*r) • e‖ ≤ 2*r := by + calc + ‖h + (alpha*r) • e‖ ≤ ‖h‖ + ‖(alpha*r) • e‖ := norm_add_le _ _ + _ = ‖h‖ + alpha*r := by rw [norm_smul_of_nonneg hat.le, he, mul_one] + _ ≤ 2*r := by nlinarith + have hxbound := hrem h (by linarith) + have hzbound := hrem (h + (alpha*r) • e) hz + have hsg := hsub (h + (alpha*r) • e) (by + simpa only [Metric.mem_closedBall, dist_zero_right] using hz) + have hnormsq : ‖h + (alpha*r) • e‖ ^ 2 ≤ 4*r^2 := by + nlinarith [norm_nonneg (h + (alpha*r) • e)] + have hhsq : ‖h‖ ^ 2 ≤ r^2 := by nlinarith [norm_nonneg h] + have hremdiff : (f (h + (alpha*r) • e) - quadraticTaylor f0 p A (h + (alpha*r) • e)) - + (f h - quadraticTaylor f0 p A h) ≤ 5*w*r^2 := by + have h1 := (abs_le.mp hzbound).2 + have h2 := (abs_le.mp hxbound).1 + have h3 := mul_le_mul_of_nonneg_left hnormsq hw + have h4 := mul_le_mul_of_nonneg_left hhsq hw + nlinarith + have hquad := quadraticTaylor_increment f0 p A hA h e (alpha*r) + have hAe : inner ℝ (A e) e ≤ ‖A‖ := by + calc + inner ℝ (A e) e ≤ ‖inner ℝ (A e) e‖ := le_abs_self _ + _ ≤ ‖A e‖ * ‖e‖ := norm_inner_le_norm _ _ + _ ≤ ‖A‖ := by simpa only [he, mul_one] using A.le_opNorm e + simp only [add_sub_cancel_left, real_inner_smul_right] at hsg + have hdir : alpha*r * inner ℝ (zeta - p - A h) e ≤ + (alpha*r)^2/2 * ‖A‖ + 5*w*r^2 := by + simp only [inner_sub_left, inner_add_left] at hquad ⊢ + have hm := mul_le_mul_of_nonneg_left hAe (by positivity : 0 ≤ (alpha*r)^2/2) + nlinarith + apply (mul_le_mul_iff_right₀ hat).mp + have hcancel : (5*w*r/alpha) * (alpha*r) = 5*w*r^2 := by field_simp + nlinarith + +lemma subgradient_norm_bound {f : E → ℝ} {f0 : ℝ} {p h zeta : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) + {r alpha w : ℝ} (hr : 0 < r) (ha : 0 < alpha) (ha1 : alpha ≤ 1) + (hw : 0 ≤ w) (hh : ‖h‖ ≤ r) + (hrem : ∀ z : E, ‖z‖ ≤ 2*r → + |f z - quadraticTaylor f0 p A z| ≤ w * ‖z‖ ^ 2) + (hsub : IsSubgradientOn f (Metric.closedBall 0 (2*r)) h zeta) : + ‖zeta - p - A h‖ ≤ ‖A‖ * alpha * r / 2 + 5*w*r/alpha := by + by_cases hzero : zeta - p - A h = 0 + · rw [hzero, norm_zero] + positivity + let v := zeta - p - A h + let e := ‖v‖⁻¹ • v + have he : ‖e‖ = 1 := norm_smul_inv_norm (𝕜 := ℝ) hzero + have hd := subgradient_directional_bound hA hr ha ha1 hw hh he hrem hsub + have hv : 0 < ‖v‖ := norm_pos_iff.mpr hzero + have hip : inner ℝ (zeta - p - A h) e = ‖zeta - p - A h‖ := by + change inner ℝ v (‖v‖⁻¹ • v) = ‖v‖ + rw [real_inner_smul_right, real_inner_self_eq_norm_sq] + field_simp + exact hip ▸ hd + +lemma subgradient_zero_of_quadraticExpansion {f : E → ℝ} {p zeta : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) + (hexp : HasQuadraticExpansion f p A) {R : ℝ} (hR : 0 < R) + (hsub : IsSubgradientOn f (Metric.ball 0 R) 0 zeta) : zeta = p := by + obtain ⟨delta, hdelta, hrem⟩ := hexp 1 zero_lt_one + let eps := min R delta / 4 + have heps : 0 < eps := by dsimp [eps]; positivity + have hbound (r : ℝ) (hr : r ∈ Ioo 0 eps) : + ‖zeta - p‖ ≤ ‖A‖ * 1 * r / 2 + 5*1*r/1 := by + have hrR : 2*r < R := by + have hh : 4*eps ≤ R := by dsimp [eps]; linarith [min_le_left R delta] + linarith [hr.2] + have hrdelta : 2*r < delta := by + have hh : 4*eps ≤ delta := by dsimp [eps]; linarith [min_le_right R delta] + linarith [hr.2] + have hh := subgradient_norm_bound (p := p) (h := 0) hA hr.1 zero_lt_one + le_rfl zero_le_one (by simpa using hr.1.le) + (fun z hz => hrem z (hz.trans_lt hrdelta)) + (fun z hz => hsub z (by + rw [Metric.mem_ball, dist_zero_right] + exact (show ‖z‖ ≤ 2 * r from by simpa only [Metric.mem_closedBall, dist_zero_right] using hz).trans_lt hrR)) + simpa only [map_zero, sub_zero] using hh + have hcl : (0 : ℝ) ∈ closure (Ioo 0 eps) := by + rw [closure_Ioo heps.ne] + exact ⟨le_rfl, heps.le⟩ + have hcont : Continuous (fun r : ℝ => ‖A‖ * 1 * r / 2 + 5*1*r/1) := by fun_prop + have hlim := ContinuousWithinAt.closure_le hcl + (continuousWithinAt_const (b := ‖zeta-p‖)) hcont.continuousWithinAt hbound + have hz : ‖zeta-p‖ = 0 := le_antisymm (by simpa using hlim) (norm_nonneg _) + exact sub_eq_zero.mp (norm_eq_zero.mp hz) + +lemma subgradient_uniform_differential {f : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) + (hexp : HasQuadraticExpansion f p A) {R : ℝ} (hR : 0 < R) : + ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ h zeta : E, ‖h‖ < delta → IsSubgradientOn f (Metric.ball 0 R) h zeta → + ‖zeta - p - A h‖ ≤ eps * ‖h‖ := by + intro eps heps + let alpha : ℝ := min 1 (eps / (‖A‖ + 1)) + have ha : 0 < alpha := by dsimp [alpha]; positivity + have ha1 : alpha ≤ 1 := min_le_left _ _ + have hAa : ‖A‖ * alpha ≤ eps := by + have hh := (le_div_iff₀ (by positivity : 0 < ‖A‖ + 1)).mp (min_le_right 1 (eps/(‖A‖+1))) + change alpha * (‖A‖+1) ≤ eps at hh + nlinarith + let w : ℝ := eps * alpha / 20 + have hw : 0 < w := by dsimp [w]; positivity + obtain ⟨d, hd, hrem⟩ := hexp w hw + let delta := min R d / 4 + have hdelta : 0 < delta := by dsimp [delta]; positivity + refine ⟨delta, hdelta, ?_⟩ + intro h zeta hh hsub + by_cases hz : h = 0 + · subst h + have hzet := subgradient_zero_of_quadraticExpansion hA hexp hR hsub + simp [hzet] + have hnorm : 0 < ‖h‖ := norm_pos_iff.mpr hz + have hhr : 2*‖h‖ < R := by + have ht : 4*delta ≤ R := by dsimp [delta]; linarith [min_le_left R d] + linarith + have hhd : 2*‖h‖ < d := by + have ht : 4*delta ≤ d := by dsimp [delta]; linarith [min_le_right R d] + linarith + have hb := subgradient_norm_bound hA hnorm ha ha1 hw.le le_rfl + (fun z hz => hrem z (hz.trans_lt hhd)) + (fun z hz => hsub z (by + rw [Metric.mem_ball, dist_zero_right] + exact (show ‖z‖ ≤ 2 * ‖h‖ from by simpa only [Metric.mem_closedBall, dist_zero_right] using hz).trans_lt hhr)) + apply hb.trans + have hwcalc : 5*w*‖h‖/alpha = eps*‖h‖/4 := by + dsimp [w] + field_simp + ring + rw [hwcalc] + have hm := mul_le_mul_of_nonneg_right hAa hnorm.le + nlinarith + +def IsSemiconvexSubgradientOn (f : E → ℝ) (s : Set E) (K : ℝ) + (h zeta : E) : Prop := + ∀ y ∈ s, f h + inner ℝ zeta (y - h) - K / 2 * ‖y - h‖ ^ 2 ≤ f y + +lemma semiconvex_subgradient_iff {f : E → ℝ} {s : Set E} {K : ℝ} {h zeta : E} : + IsSemiconvexSubgradientOn f s K h zeta ↔ + IsSubgradientOn (fun x => f x + K / 2 * ‖x‖ ^ 2) s h (zeta + K • h) := by + have heq (y : E) : + f h + K / 2 * ‖h‖ ^ 2 + inner ℝ (zeta + K • h) (y - h) - + (f y + K / 2 * ‖y‖ ^ 2) = + f h + inner ℝ zeta (y-h) - K/2*‖y-h‖^2 - f y := by + simp only [← real_inner_self_eq_norm_sq, inner_add_left, inner_sub_left, + inner_sub_right, real_inner_smul_left] + rw [real_inner_comm y h] + ring + constructor <;> intro hs y hy + · have hh := hs y hy + linarith [heq y] + · have hh := hs y hy + linarith [heq y] + +lemma quadraticExpansion_add_quadratic {f : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hexp : HasQuadraticExpansion f p A) (K : ℝ) : + HasQuadraticExpansion (fun x => f x + K / 2 * ‖x‖ ^ 2) p + (A + K • ContinuousLinearMap.id ℝ E) := by + intro w hw + obtain ⟨d, hd, hr⟩ := hexp w hw + refine ⟨d, hd, fun z hz => ?_⟩ + have heq : (f z + K/2*‖z‖ ^ 2) - + quadraticTaylor (f 0 + K/2*‖(0 : E)‖ ^ 2) p + (A + K • ContinuousLinearMap.id ℝ E) z = f z - quadraticTaylor (f 0) p A z := by + simp only [quadraticTaylor, norm_zero, zero_pow (by omega : 2 ≠ 0), mul_zero, + add_zero, add_apply, smul_apply, + ContinuousLinearMap.id_apply, inner_add_left, real_inner_smul_left, + real_inner_self_eq_norm_sq] + ring + rw [heq] + exact hr z hz + +lemma semiconvex_subgradient_uniform_differential {f : E → ℝ} {p : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y = inner ℝ x (A y)) + (hexp : HasQuadraticExpansion f p A) {R : ℝ} (hR : 0 < R) (K : ℝ) : + ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ h zeta : E, ‖h‖ < delta → + IsSemiconvexSubgradientOn f (Metric.ball 0 R) K h zeta → + ‖zeta - p - A h‖ ≤ eps * ‖h‖ := by + have hs : ∀ x y : E, + inner ℝ ((A + K • ContinuousLinearMap.id ℝ E) x) y = + inner ℝ x ((A + K • ContinuousLinearMap.id ℝ E) y) := by + intro x y + simp only [add_apply, smul_apply, + ContinuousLinearMap.id_apply, inner_add_left, inner_add_right, + real_inner_smul_left, real_inner_smul_right, hA] + intro eps heps + obtain ⟨delta, hdelta, hb⟩ := subgradient_uniform_differential hs + (quadraticExpansion_add_quadratic hexp K) hR eps heps + refine ⟨delta, hdelta, ?_⟩ + intro h zeta hh hsub + have hhbound := hb h (zeta + K • h) hh (semiconvex_subgradient_iff.mp hsub) + have heq : zeta + K • h - p - (A + K • ContinuousLinearMap.id ℝ E) h = + zeta - p - A h := by + simp only [add_apply, smul_apply, ContinuousLinearMap.id_apply] + abel + rwa [heq] at hhbound + + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientUpper.lean b/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..35b7e9cadc8d8196cf9e2df4deb08e81b36ea5ba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/SubgradientUpper.lean @@ -0,0 +1,287 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalSubdifferential +import OAI.Analysis.BiholderTransport.Contact.MovingCostSupport +import OAI.Analysis.BiholderTransport.Convexity.CompactConvexHullFinite + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +lemma normalSubdifferential_directional_le {u : M → ℝ} {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈normalSubdifferential u x) + (h : TangentSpace 𝓘(ℝ,Model n) x) {K : ℝ} + (hK : ∀ᶠ t : ℝ in 𝓝 0, 0≤t → u (riemannianExp x (t • h))-u x≤K*t) : + inner ℝ p h≤K := by + by_contra hn + have hdiff : 0 < inner ℝ p h-K := sub_pos.mpr (lt_of_not_ge hn) + let ε := (inner ℝ p h-K)/(2*(‖h‖+1)) + have hn1 : 0<‖h‖+1 := by positivity + have hε : 0<ε := div_pos hdiff (mul_pos (by norm_num) hn1) + have he : ε*(2*(‖h‖+1))=inner ℝ p h-K := div_mul_cancel₀ _ (ne_of_gt (mul_pos (by norm_num) hn1)) + have hc : Tendsto (fun t : ℝ => t • h) (𝓝 0) (𝓝 0) := by + have hc : ContinuousAt (fun t : ℝ => t • h) 0 := continuousAt_id.smul continuousAt_const + simpa only [zero_smul] using hc.tendsto + have H := (hc.eventually (hp ε hε)).and hK + obtain ⟨δ,hδ,Hδ⟩ := Metric.eventually_nhds_iff.mp H + have ht : 0<δ/2 := by positivity + have hh := Hδ (y := δ/2) (by simpa only [Real.dist_eq,sub_zero,abs_of_pos ht] using (show δ/2<δ by linarith)) + have hb := hh.1.trans (hh.2 ht.le) + rw [inner_smul_right,norm_smul,Real.norm_eq_abs,abs_of_pos ht] at hb + have hb' : (inner ℝ p h-ε*‖h‖)*(δ/2)≤K*(δ/2) := by nlinarith [hb] + have Hbad := (mul_le_mul_iff_left₀ ht).mp hb' + nlinarith [mul_pos hε hn1] + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma normalSubdifferential_subset_active_hull {v : M → ℝ} (hv : Continuous v) (x : M) : + normalSubdifferential (cTransform v) x ⊆ convexHull ℝ (activeLogs (n := n) v x) := by + have : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + have : CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x) := FiniteDimensional.complete ℝ _ + intro p hp + by_contra hn + obtain ⟨f,K,hK,hpK⟩ := geometric_hahn_banach_closed_point + (convex_convexHull ℝ (activeLogs (n := n) v x)) + (isCompact_convexHull_finiteDimensional (isCompact_activeLogs (n := n) hv x)).isClosed hn + let h := (InnerProductSpace.toDual ℝ (TangentSpace 𝓘(ℝ,Model n) x)).symm f + have he : ∀ q : TangentSpace 𝓘(ℝ,Model n) x, inner ℝ q h=f q := by + intro q + rw [real_inner_comm] + exact InnerProductSpace.toDual_symm_apply + have hh := active_directional_upper_support hv h + (fun q hq => by rw [he]; exact hK q (subset_convexHull ℝ _ hq)) + have H := normalSubdifferential_directional_le hp h hh + rw [he] at H + exact (not_lt_of_ge H hpK) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/TestMountains.lean b/lean/OAI/Analysis/BiholderTransport/Contact/TestMountains.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ad3c708e9b59b339c7b1ab6ad74d95cf06ad617 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/TestMountains.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LocalMountains +import OAI.Analysis.BiholderTransport.Coordinates.ChartGradientMap +import OAI.Analysis.BiholderTransport.Regularity.SecondFderivAdd + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TestMountains +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma exists_test_mountains {a : M} {z : Model n} {φ : Model n → ℝ} {m : ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hp : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) (hm : 0 < m) + (hpos : ∀ d : Model n, m*‖d‖^2 ≤ + fderiv ℝ (fderiv ℝ φ) z d d + + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d) : + ∃ r>0, Metric.closedBall z r⊆(extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ w∈Metric.closedBall z r, ∀ q∈Metric.closedBall z r, + φ w+chartCost a (coordinateBackward a (-1,w,fderiv ℝ φ w)) w ≤ + φ q+chartCost a (coordinateBackward a (-1,w,fderiv ℝ φ w)) q := by + let Y := fun w => coordinateBackward a (-1,w,fderiv ℝ φ w) + let F := fun y w => φ w+chartCost a y w + have hc : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) ((extChartAt 𝓘(ℝ,Model n) a).symm z,Y z) := by + rw [show Y z=riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm z) + (chartGradientVector a z (fderiv ℝ φ z)) from coordinateBackward_eq_exp_chartGradient hz _] + exact cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z (fderiv ℝ φ z)⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + obtain ⟨hC,hD⟩ := chartCost_jet_continuous hz hc + have hDn : ∀ᶠ q : Model n×M in 𝓝 (z,Y z), ContDiffAt ℝ 2 φ q.1 := + continuousAt_fst.eventually (hφ.eventually (by norm_num)) + have he : ∀ᶠ q : Model n×M in 𝓝 (z,Y z), + fderiv ℝ (fderiv ℝ (F q.2)) q.1 = + fderiv ℝ (fderiv ℝ φ) q.1+fderiv ℝ (fderiv ℝ (chartCost a q.2)) q.1 := by + filter_upwards [hDn,hD] with q hq hq' + exact second_fderiv_add_eq hq hq' + have hFC : ContinuousAt (fun q : Model n×M => fderiv ℝ (fderiv ℝ (F q.2)) q.1) (z,Y z) := by + apply ((((hφ.fderiv_right (m := 1) (by norm_num)).fderiv_right (m := 0) + (by norm_num)).continuousAt.comp continuousAt_fst).add hC).congr_of_eventuallyEq he + have hFD : ∀ᶠ q : Model n×M in 𝓝 (z,Y z), ContDiffAt ℝ 2 (F q.2) q.1 := by + filter_upwards [hDn,hD] with q hq hq' + exact hq.add hq' + obtain ⟨r₀,hr₀,V,hV,H⟩ := exists_local_mountains hm hFC hFD (by + intro d + rw [he.self_of_nhds] + exact hpos d) + have hj : ContinuousAt (fun w : Model n => (w,fderiv ℝ φ w)) z := + continuousAt_id.prodMk ((hφ.fderiv_right (m := 1) (by norm_num)).continuousAt) + have hY : ContinuousAt Y z := + (coordinateBackward_contMDiffAt (q := (-1,z,fderiv ℝ φ z)) hz).continuousAt.comp (x := z) (f := fun w : Model n => ((-1:ℝ),w,fderiv ℝ φ w)) + (continuousAt_const.prodMk hj) + have hchart : ∀ᶠ w : Model n in 𝓝 z, w∈(extChartAt 𝓘(ℝ,Model n) a).target := + (isOpen_extChartAt_target a).mem_nhds hz + have hnear : ∀ᶠ w : Model n in 𝓝 z, + w∈(extChartAt 𝓘(ℝ,Model n) a).target ∧ + chartGradientVector a w (fderiv ℝ φ w)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm w) ∧ + ContDiffAt ℝ 2 φ w ∧ Y w∈V ∧ w∈Metric.ball z r₀ := + by + filter_upwards [hchart,hj.eventually (chartGradientVector_regular_near hz hp), + hφ.eventually (by norm_num),hY.preimage_mem_nhds hV,Metric.ball_mem_nhds z hr₀] + with w hw hpw hφw hyw hrw + exact ⟨hw,hpw,hφw,hyw,hrw⟩ + obtain ⟨r,hr,hrsub⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hnear + refine ⟨r,hr,fun w hw => (hrsub hw).1,?_⟩ + intro w hw q hq + have hw' := hrsub hw + apply H (Y w) hw'.2.2.2.1 w (Metric.ball_subset_closedBall hw'.2.2.2.2) ?_ + q (Metric.ball_subset_closedBall (hrsub hq).2.2.2.2) + have HD := (hw'.2.2.1.differentiableAt (by norm_num)).hasFDerivAt.add + (chartCost_gradient_at_contact hw'.1 hw'.2.1) + change fderiv ℝ (φ + chartCost a (coordinateBackward a (-1,w,fderiv ℝ φ w))) w=0 + simpa only [add_neg_cancel] using HD.fderiv + +end TestMountains +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Contact/UpperContactIteratedDeriv.lean b/lean/OAI/Analysis/BiholderTransport/Contact/UpperContactIteratedDeriv.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc151732ee5e95e72fcda02ff5d2494e23b95094 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Contact/UpperContactIteratedDeriv.lean @@ -0,0 +1,132 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.LocalMinSecondDeriv + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma upper_contact_iteratedDeriv_two {f g : ℝ → ℝ} {x : ℝ} + (hf : ContDiffAt ℝ 2 f x) (hg : ContDiffAt ℝ 2 g x) + (hle : ∀ᶠ y in 𝓝 x, f y≤g y) (heq : f x=g x) : + iteratedDeriv 2 f x ≤ iteratedDeriv 2 g x := by + have hmin : IsLocalMin (g-f) x := by + filter_upwards [hle] with y hy + change g x-f x≤g y-f y + rw [heq,sub_self] + exact sub_nonneg.mpr hy + have H := localMin_second_deriv_nonneg hmin (hg.sub hf).continuousAt + have htwo : iteratedDeriv 2 (g-f) x=deriv (deriv (g-f)) x := by + rw [show (2:ℕ)=1+1 by rfl,iteratedDeriv_succ,iteratedDeriv_one] + rw [←htwo] at H + rw [iteratedDeriv_sub hg hf] at H + exact sub_nonneg.mp H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ActualCenterSemibound.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ActualCenterSemibound.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd8c241ea406371ca4376b3121bfab3cf0bbbdc8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ActualCenterSemibound.lean @@ -0,0 +1,148 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.ModelTangentJet +import OAI.Analysis.BiholderTransport.Contact.CenterSupportFamily +import OAI.Analysis.BiholderTransport.Regularity.CenterPoleLimit +import OAI.Analysis.BiholderTransport.Convexity.MovingCenterSemibound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section ActualCenterSemibound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure CenterSequenceData (a c : M) (u v : M → ℝ) (Φ : ℝ×ℝ → ℝ) + (γj lj τj tj : ℕ → ℝ) (xj bj qj : ℕ → Model n) (zj : ℕ → M) + (F : ℕ → Model n → ℝ) where + row : ∀ i,TrueCenterRow c u v (fun s=>Φ (γj i,s)) (xj i) (zj i) (τj i) (lj i) + endpoint : ∀ i,movingPrefix a (tj i) (bj i) (qj i)=zj i + derivative : ∀ᶠ i in atTop, + (∀ᶠ z in 𝓝 (extChartAt 𝓘(ℝ,Model n) c (zj i)),DifferentiableAt ℝ + (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm z))) + (extChartAt 𝓘(ℝ,Model n) c (zj i)) + gradient : Tendsto (fun i=>fderiv ℝ (F i) (extChartAt 𝓘(ℝ,Model n) c (zj i))+ + fderiv ℝ (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm z)) + (extChartAt 𝓘(ℝ,Model n) c (zj i))) atTop (𝓝 0) + backward : ∀ᶠ i in atTop,coordinateBackward c (tj i,extChartAt 𝓘(ℝ,Model n) c (zj i), + fderiv ℝ (F i) (extChartAt 𝓘(ℝ,Model n) c (zj i)))= + (extChartAt 𝓘(ℝ,Model n) a).symm (bj i) + +lemma exists_actual_center_sequential_gain : + ∃ c0>0,∀ᶠ l : ℝ in 𝓝 1, 0Φ (γ,s)) (v c)=l → + ∀ (γj lj τj tj : ℕ → ℝ) (xj bj qj : ℕ → Model n) (zj : ℕ → M) + (F : ℕ → Model n → ℝ), + ∀ D : CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F, + ∀ (r q : Model n), + (show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c → + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a → + riemannianExp a q=c → + Tendsto γj atTop (𝓝 γ) → Tendsto lj atTop (𝓝 l) → + Tendsto τj atTop (𝓝 0) → Tendsto tj atTop (𝓝 1) → + Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c)) → + Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)) → + Tendsto qj atTop (𝓝 q) → Tendsto (fun i=>(D.row i).r) atTop (𝓝 r) → + (∀ᶠ i in atTop,0<τj i) → ∀ L : ℝ≥0, + (∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) → + ∀ ε : ℝ,0<ε → + ∀ᶠ i in atTop,∀ d : Model n, + c0*(1-l)*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + (iteratedDeriv 2 (fun s=>Φ (γ,s)) (v c)/l^2)* + (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2-ε*‖d‖^2 ≤ + coordinateCenterMatrix a (tj i) (hopfLax (τj i) (fun y=>Φ (γj i,v y))) + (bj i) (qj i) d d := by + obtain ⟨c0,hc0,H⟩ := exists_uniform_coordinate_center_full_pullback (n := n) (M := M) + refine ⟨c0,hc0,?_⟩ + filter_upwards [H] with l hgain + intro hl hl1 a c u v Φ γ hv hΦ hder γj lj τj tj xj bj qj zj F D r q hr hq he + hγ hlm hτ ht hx hb hqq hrr hτpos L hLip ε hε + let p := (γ,((v c,(1+l)/2),(extChartAt 𝓘(ℝ,Model n) c c,r))) + let pj := fun i=>centerRowParameter c v (γj i) (lj i) (xj i) (D.row i).r + let ψ := jointScalarSupport (n := n) c Φ + have hp : Tendsto pj atTop (𝓝 p) := center_row_parameter_tendsto hv hγ hlm hx hrr + have hψ : ContDiffAt ℝ ∞ ψ (p,extChartAt 𝓘(ℝ,Model n) c c) := + center_limit_support_smooth hΦ hr hl hl1 + have hs : ((1+l)/2)≠0 := by linarith + have hr' := contracted_minimizer_mem_injectivityDomain hr (t := (1+l)/2) + (by linarith) (by linarith) + have hc := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hφinf : ContDiffAt ℝ ∞ (fun s=>Φ (γ,s)) (v c) := + hΦ.comp (v c) (contDiffAt_const.prodMk contDiffAt_id) + have hφ2 : ContDiffAt ℝ 2 (fun s=>Φ (γ,s)) (v c) := + hφinf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hφ : HasDerivAt (fun s=>Φ (γ,s)) l (v c) := by + rw [←hder] + exact (hφinf.differentiableAt (by simp)).hasDerivAt + have hforward (i : ℕ) : parametricShortForward c ψ ((pj i,τj i),xj i)= + extChartAt 𝓘(ℝ,Model n) c (zj i) := (D.row i).forward + have hbelow : ∀ᶠ i in atTop,∀ w,ψ (pj i,w)≤Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm w)) := + Eventually.of_forall (fun i=>(D.row i).below) + have htouch : ∀ᶠ i in atTop, + Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm (xj i)))=ψ (pj i,xj i) := + Eventually.of_forall (fun i=>(D.row i).touching.symm) + have ha : Tendsto (fun i=>(extChartAt 𝓘(ℝ,Model n) a).symm (bj i)) atTop (𝓝 a) := by + have hb0 := (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hy := (continuousAt_extChartAt_symm'' hb0).tendsto.comp hb + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] at hy + exact hy + have hd : ∀ᶠ i in atTop,DifferentiableAt ℝ + (fun w=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (parametricShortForward c ψ ((pj i,τj i),xj i)) := by + filter_upwards [D.derivative] with i hi + rw [hforward] + exact hi.1.self_of_nhds + have herr := D.gradient.congr' (Eventually.of_forall (fun i=>by rw [←hforward i])) + have hback : ∀ᶠ i in atTop,coordinateBackward c (tj i, + parametricShortForward c ψ ((pj i,τj i),xj i), + fderiv ℝ (F i) (parametricShortForward c ψ ((pj i,τj i),xj i)))= + (extChartAt 𝓘(ℝ,Model n) a).symm (bj i) := by + simpa only [hforward] using D.backward + have hstationary : a=riemannianExp c (l • r) := + parametric_short_center_pole_limit L hψ hs hr' hφ rfl hp hx ht hτ ha hτpos hLip + hbelow htouch hd herr hback + have hregular : (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a := + reverse_minimizer_regular (contracted_minimizer_mem_injectivityDomain hr hl hl1) + hq hstationary.symm he + have hsource : riemannianExp a q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + rw [he] + exact mem_extChartAt_source c + have hz : ∀ᶠ i in atTop,movingPrefixChart a c (tj i) (bj i) (qj i)= + parametricShortForward c ψ ((pj i,τj i),xj i) := Eventually.of_forall (fun i=>by + rw [hforward,movingPrefixChart,D.endpoint]) + have hjet : ∀ᶠ i in atTop, + (∀ᶠ z in 𝓝 (movingPrefixChart a c (tj i) (bj i) (qj i)),DifferentiableAt ℝ + (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm z))) + (movingPrefixChart a c (tj i) (bj i) (qj i)) := by + simpa only [movingPrefixChart,D.endpoint] using D.derivative + have Hlow := moving_center_sequential_semibound L hc hψ hregular + (congrArg (extChartAt 𝓘(ℝ,Model n) c) he) hsource hp hx hb hqq ht hτ hτpos hLip + hbelow htouch hz hjet hε + have HG := hgain hl hl1 a c r q hr hregular hstationary.symm he + (fun s=>Φ (γ,s)) (v c) hφ2 hder + filter_upwards [Hlow] with i hi + intro d + exact (sub_le_sub_right (HG d) _).trans (hi d) + +end ActualCenterSemibound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/AlexandrovDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/AlexandrovDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..12dff585798909783bdb42797ad82afdc9a9fae9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/AlexandrovDerivative.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SubgradientDifferential +import OAI.Analysis.BiholderTransport.Coordinates.Taylor + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +section AlexandrovDerivative +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma semiconvex_selection_hasFDerivWithinAt {f : E → ℝ} {p : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y=inner ℝ x (A y)) + (hexp : HasQuadraticExpansion f p A) {R : ℝ} (hR : 0 f (x+t • (v-x))) (f' (v-x)) 0 := by + have hp : HasDerivAt (fun t : ℝ => x+t • (v-x)) (v-x) 0 := by + simpa using ((hasDerivAt_id (0:ℝ)).smul_const (v-x)).const_add x + exact (show HasFDerivAt f f' (x+(0:ℝ) • (v-x)) from by simpa using hder).comp_hasDerivAt 0 hp + have hb : ∀ᶠ t : ℝ in 𝓝[>] 0, + t⁻¹*(f (x+t • (v-x))-f x)≤f v-f x := by + filter_upwards [Ioo_mem_nhdsGT (by norm_num : (0:ℝ)<1)] with t ht + have hcv := hc.2 hx hv (by linarith [ht.2] : 0≤1-t) ht.1.le (by ring : 1-t+t=1) + have heq : (1-t) • x+t • v=x+t • (v-x) := by + simp only [sub_smul,one_smul,smul_sub]; abel + rw [heq] at hcv + simp only [smul_eq_mul] at hcv + rw [inv_mul_eq_div,div_le_iff₀ ht.1] + nlinarith + have ht : Tendsto (fun t : ℝ => t⁻¹*(f (x+t • (v-x))-f x)) + (𝓝[>] 0) (𝓝 (f' (v-x))) := by + simpa only [zero_add,zero_smul,add_zero,smul_eq_mul] using hd.tendsto_slope_zero_right + have H := le_of_tendsto ht hb + linarith + +lemma gradient_semiconvex_subgradient_on {f : E → ℝ} {s : Set E} {K : ℝ} + (hc : ConvexOn ℝ s (fun z => f z+K/2*‖z‖^2)) {x : E} (hx : x∈s) + (hd : DifferentiableAt ℝ f x) : + IsSemiconvexSubgradientOn f s K x + ((InnerProductSpace.toDual ℝ E).symm (fderiv ℝ f x)) := by + rw [semiconvex_subgradient_iff] + have hq := ((hasStrictFDerivAt_norm_sq x).hasFDerivAt.const_mul (K/2)) + have h := gradient_subgradient_on hc hx (hd.hasFDerivAt.add hq) + convert h using 1 + apply (InnerProductSpace.toDual ℝ E).injective + simp only [map_add,map_smul,LinearIsometryEquiv.apply_symm_apply] + ext z + simp only [add_apply,smul_apply, + InnerProductSpace.toDual_apply_apply,innerSL_apply_apply,smul_eq_mul] + ring + +lemma semiconvex_gradient_hasFDerivWithinAt {f : E → ℝ} {p : E} + {A : E →L[ℝ] E} (hA : ∀ x y, inner ℝ (A x) y=inner ℝ x (A y)) + (hexp : HasQuadraticExpansion f p A) {R : ℝ} (hR : 0 f z+K/2*‖z‖^2)) : + HasFDerivWithinAt (fun z => (InnerProductSpace.toDual ℝ E).symm (fderiv ℝ f z)) A + {z | z∈Metric.ball 0 R ∧ DifferentiableAt ℝ f z} 0 := by + apply semiconvex_selection_hasFDerivWithinAt hA hexp hR K + · rw [hexp.hasFDerivAt.fderiv] + exact (InnerProductSpace.toDual ℝ E).symm_apply_apply p + · intro z hz + exact gradient_semiconvex_subgradient_on hc hz.1 hz.2 +end AlexandrovDerivative +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/BoundedConvexSecant.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/BoundedConvexSecant.lean new file mode 100644 index 0000000000000000000000000000000000000000..0826bd21bbaeb000d35441e7469460c759454c8e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/BoundedConvexSecant.lean @@ -0,0 +1,60 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma bounded_convex_secant {f : ℝ → ℝ} {a b C d x y : ℝ} + (hf : ConvexOn ℝ (Icc a b) f) (hC : 0 ≤ C) (hd : 0 + ∑ i, q.1.weights i • (q.2 i).1 + have hF : ∀ m, Continuous (F m) := by + intro m + dsimp [F] + apply continuous_finsetSum + intro i _ + exact ((Convexity.StdSimplex.continuous_weights_apply ℝ i).comp continuous_fst).smul + (continuous_subtype_val.comp ((continuous_apply i).comp continuous_snd)) + let C := fun m => range (F m) + have hC : ∀ m, IsCompact (C m) := fun m => isCompact_range (hF m) + have heq : convexHull ℝ S = ⋃ m≤Module.finrank ℝ E+1, C m := by + ext x + constructor + · intro hx + obtain ⟨ι,inst,z,w,hz,hi,hw,hsum,hx⟩ := eq_pos_convex_span_of_mem_convexHull hx + let : Fintype ι := inst + let e := Fintype.equivFin ι + have hcard : Fintype.card ι≤Module.finrank ℝ E+1 := + hi.card_le_finrank_succ.trans (Nat.add_le_add_right (Submodule.finrank_le _) 1) + refine mem_iUnion₂.mpr ⟨Fintype.card ι,hcard,?_⟩ + let v : Convexity.StdSimplex ℝ (Fin (Fintype.card ι)) := { + weights := Finsupp.equivFunOnFinite.symm (fun index => w (e.symm index)) + nonneg := fun index => (hw (e.symm index)).le + total := by simpa [Finsupp.sum_fintype, e.symm.sum_comp] using hsum } + let a : Fin (Fintype.card ι) → S := fun i => ⟨z (e.symm i),hz (mem_range_self _)⟩ + refine ⟨(v,a),?_⟩ + dsimp [F,v,a] + exact (e.symm.sum_comp (fun i => w i • z i)).trans hx + · intro hx + obtain ⟨m,_,q,rfl⟩ := mem_iUnion₂.mp hx + exact (convex_convexHull ℝ S).sum_mem (fun i _ => q.1.weights_nonneg i) + q.1.total_of_fintype + (fun i _ => subset_convexHull ℝ S (q.2 i).2) + rw [heq] + exact (finite_le_nat _).isCompact_biUnion (fun m _ => hC m) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexBarycentricSegment.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexBarycentricSegment.lean new file mode 100644 index 0000000000000000000000000000000000000000..928f6e3713a16faa69b08b3e591a5a5139d2f445 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexBarycentricSegment.lean @@ -0,0 +1,47 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma convex_barycentric_segment {E ι : Type*} [AddCommGroup E] [Module ℝ E] + [Fintype ι] {G : Set E} (hG : Convex ℝ G) (w : ι → ℝ) (v : ι → E) + (hw : ∀ i, 0 ≤ w i) (hs : ∑ i,w i=1) (hv : ∀ i,v i∈G) + (i : ι) {μ : ℝ} (hμ : 0 ≤ μ) (hi : μ ≤ w i) (t : ℝ) (ht : t∈Icc (-μ) 1) : + (∑ j,w j • v j)+t • (v i-∑ j,w j • v j)∈G := by + classical + let a : ι → ℝ := fun j => (1-t)*w j+if j=i then t else 0 + have ha (j : ι) (_hj : j∈Finset.univ) : 0 ≤ a j := by + dsimp only [a] + by_cases hj : j=i + · rw [ite_eq_left hj,hj] + by_cases h0 : 0 ≤ t + · exact add_nonneg (mul_nonneg (by linarith [ht.2]) (hw i)) h0 + · have ht0 : t<0 := lt_of_not_ge h0 + nlinarith [mul_nonneg (neg_nonneg.mpr ht0.le) (hμ.trans hi),ht.1] + · rw [ite_eq_right hj,add_zero] + exact mul_nonneg (by linarith [ht.2]) (hw j) + have has : ∑ j,a j=1 := by + simp only [a,Finset.sum_add_distrib,←Finset.mul_sum,hs,mul_one] + simp + have HH := hG.sum_mem (t := Finset.univ) ha has (fun j _ => hv j) + have he : (∑ j,a j • v j)=(∑ j,w j • v j)+t • (v i-∑ j,w j • v j) := by + simp only [a,add_smul,mul_smul,Finset.sum_add_distrib,←Finset.smul_sum, + ite_smul,zero_smul] + simp only [Finset.sum_ite_eq',Finset.mem_univ,ite_true] + module + rwa [he] at HH +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexNormSq.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexNormSq.lean new file mode 100644 index 0000000000000000000000000000000000000000..c573187558d9a7cfa4cca5d0c773a4ba9e68b1c0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ConvexNormSq.lean @@ -0,0 +1,31 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport + +lemma exists_convex_norm_sq {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {S : Set E} {p q : E} {N : ℝ} (hp : p∈S) (hq : q∈S) + (hpN : ‖p‖^2≤N) (hqN : N≤‖q‖^2) : + ∃ w∈convexHull ℝ S, ‖w‖^2=N := by + let f : ℝ → E := fun t => (1-t) • p+t • q + have hc : Continuous (fun t => ‖f t‖^2) := by dsimp [f]; fun_prop + have h0 : ‖f 0‖^2≤N := by simpa [f] using hpN + have h1 : N≤‖f 1‖^2 := by simpa [f] using hqN + obtain ⟨t,ht,he⟩ := intermediate_value_Icc (by norm_num : (0:ℝ)≤1) hc.continuousOn ⟨h0,h1⟩ + refine ⟨f t,?_,he⟩ + exact (convex_convexHull ℝ S) (subset_convexHull ℝ S hp) (subset_convexHull ℝ S hq) + (by linarith only [ht.2]) ht.1 (by ring) + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/CoordinateSemiconvex.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/CoordinateSemiconvex.lean new file mode 100644 index 0000000000000000000000000000000000000000..e137bbfb529bfa890d802b33d31b8f9abc582528 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/CoordinateSemiconvex.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull +import OAI.Analysis.BiholderTransport.Contact.CoordinateSupport + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +section CoordinateSemiconvex +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cTransform_uniform_smooth_coordinate_semiconvex + {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {ψ : E → M} (hψ : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,Model n) ∞ ψ 0) : + ∃ r>0, ∃ K>0, ∀ v : M → ℝ, Continuous v → + ConvexOn ℝ (Metric.ball (0:E) r) + (fun h => cTransform v (ψ h)+K*‖h‖^2) := by + let x := ψ 0 + let Y := fun z : TangentBundle 𝓘(ℝ,Model n) M => riemannianExp z.1 ((1/2:ℝ) • z.2) + have hY : Continuous Y := (contMDiff_riemannianExp (n := n) (M := M)).continuous.comp + ((contMDiff_tangentScale (E := Model n) (M := M)).continuous.comp + (continuous_const.prodMk continuous_id)) + let P := fun r K : ℝ => fun h : E => fun Z : TangentBundle 𝓘(ℝ,Model n) M => + Z.1=ψ h → ∀ z∈Metric.ball (0:E) r, ∃ l : E →L[ℝ] ℝ, + ∀ w∈Metric.ball (0:E) r, + 2*(cost (ψ w) (Y Z)-cost (ψ z) (Y Z))- + l (w-z) ≤ K*‖w-z‖^2 + have hmono : ∀ {r R b B : ℝ}, 0 (hl w (Metric.ball_subset_ball hrR hw)).trans + (mul_le_mul_of_nonneg_right hbB (sq_nonneg _))⟩ + have hlocal : ∀ Z : TangentBundle 𝓘(ℝ,Model n) M, + Z.2∈minimizingVectors Z.1 → + ∃ r>0, ∃ b>0, ∀ᶠ q : E×TangentBundle 𝓘(ℝ,Model n) M in 𝓝 (0,Z), + P r b q.1 q.2 := by + rintro ⟨a,p⟩ hp + by_cases ha : a=x + · subst a + obtain ⟨r,hr,b,hb,H⟩ := smooth_coordinate_half_cost_quadratic hψ (hY.continuousAt (x := (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M))) rfl hp rfl + refine ⟨r,hr,b,hb,?_⟩ + filter_upwards [continuousAt_snd.tendsto.eventually H] with q hq + exact fun _ => hq + · have hbase : Continuous (fun q : E×TangentBundle 𝓘(ℝ,Model n) M => q.2.1) := + (FiberBundle.continuous_proj _ _).comp continuous_snd + have hexp : ContinuousAt (fun q : E×TangentBundle 𝓘(ℝ,Model n) M => ψ q.1) (0,⟨a,p⟩) := + ContinuousAt.comp (x := ((0:E),(⟨a,p⟩ : TangentBundle 𝓘(ℝ,Model n) M))) (f := Prod.fst) hψ.continuousAt continuousAt_fst + have H : ∀ᶠ q : E×TangentBundle 𝓘(ℝ,Model n) M in 𝓝 (0,⟨a,p⟩), + q.2.1≠ψ q.1 := + (hbase.continuousAt.prodMk hexp).preimage_mem_nhds + (isClosed_diagonal.isOpen_compl.mem_nhds (by simpa only [mem_compl_iff,mem_diagonal_iff] using ha)) + exact ⟨1,by norm_num,1,by norm_num,H.mono (fun _ h he => (h he).elim)⟩ + obtain ⟨r,hr,K,hK,H⟩ := compact_eventually_uniform_radius_bound + (isCompact_total_minimizingVectors (n := n) (M := M)) hmono hlocal + obtain ⟨δ,hδ,Hδ⟩ := Metric.mem_nhds_iff.mp H + refine ⟨min r δ,lt_min hr hδ,K,hK,?_⟩ + intro v hv + apply convexOn_of_quadratic_lower_support (convex_ball _ _) + intro z hz + obtain ⟨p,hp⟩ := nonempty_activeLogs (n := n) hv (ψ z) + have HZ := Hδ (Metric.ball_subset_ball (min_le_right r δ) hz) + ⟨ψ z,p⟩ hp.1 rfl + obtain ⟨l,hl⟩ := HZ z (Metric.ball_subset_ball (min_le_left r δ) hz) + refine ⟨-l,?_⟩ + intro w hw + have HH := hl w (Metric.ball_subset_ball (min_le_left r δ) hw) + have hs := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (ψ w) + simp only [neg_apply] + dsimp only [Y] at HH + linarith + +end CoordinateSemiconvex +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/EndpointLowerJet.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/EndpointLowerJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..91b87bc958765320a85053eba2db9a928cc85ec0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/EndpointLowerJet.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TwoSidedFiberLog +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section EndpointLowerJet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_normal_endpoint_log_of_nonconjugate {z y : M} + {q : TangentSpace 𝓘(ℝ,Model n) z} (hend : riemannianExp z q=y) + (hq : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z q) (riemannianExp z v)) q)) : + ∃ e : TangentSpace 𝓘(ℝ,Model n) y → TangentSpace 𝓘(ℝ,Model n) z, + ContDiffAt ℝ ∞ e 0 ∧ e 0=q ∧ + (∀ᶠ w in 𝓝 0, riemannianExp z (e w)=riemannianExp y w) ∧ + Function.Injective (fderiv ℝ e 0) := by + let V := TangentSpace 𝓘(ℝ,Model n) z + let W := TangentSpace 𝓘(ℝ,Model n) y + obtain ⟨log,hlog,hlogq,hlogi,_⟩ := exists_smooth_two_sided_fiber_log_of_nonconjugate hq + rw [hend] at hlog hlogq hlogi + let e : W → V := fun w => log (riemannianExp y w) + have he : ContDiffAt ℝ ∞ e 0 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ log (riemannianExp y 0) from + by simpa only [riemannianExp_zero] using hlog).comp 0 + (contMDiff_riemannianExp_fiber y 0)).contDiffAt + have he0 : e 0=q := by dsimp [e]; rw [riemannianExp_zero,hlogq] + have hei : ∀ᶠ w in 𝓝 (0:W), riemannianExp z (e w)=riemannianExp y w := + (show ContinuousAt (riemannianExp y) (0:W) from (continuous_riemannianExp y).continuousAt).eventually + (by simpa only [riemannianExp_zero] using hlogi) + let χ := extChartAt 𝓘(ℝ,Model n) y + let F : V → Model n := fun v => χ (riemannianExp z v) + let G : W → Model n := fun w => χ (riemannianExp y w) + have hF : ContDiffAt ℝ ∞ F q := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ χ (riemannianExp z q) from + by rw [hend]; exact contMDiffAt_extChartAt).comp q + (contMDiff_riemannianExp_fiber z q)).contDiffAt + have hEq : (fun w => F (e w)) =ᶠ[𝓝 (0:W)] G := hei.mono (fun _ hw => congrArg χ hw) + have hD := hEq.fderiv_eq (𝕜 := ℝ) + rw [fderiv_fun_comp 0 (by simpa only [he0] using hF.differentiableAt (by simp)) + (he.differentiableAt (by simp)),he0] at hD + have hG : Function.Injective (fderiv ℝ G 0) := by + simpa only [G,χ,riemannianExp_zero] using + riemannianExp_interior_nonconjugate (zero_mem_injectivityDomain (n := n) y) + refine ⟨e,he,he0,hei,?_⟩ + have hcomp : Function.Injective ((fderiv ℝ F q).comp (fderiv ℝ e 0)) := by + rw [hD] + exact hG + exact Function.Injective.of_comp (f := fderiv ℝ F q) (g := fderiv ℝ e 0) hcomp + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma norm_reverseRay (z : TangentBundle 𝓘(ℝ,Model n) M) : + ‖(reverseRay z).2‖=‖z.2‖ := by + change ‖(-1:ℝ) • (sprayFlow 1 z).2‖=‖z.2‖ + rw [neg_one_smul,norm_neg,sprayFlow_speed] + +lemma exists_reverse_branch_with_forward_action + (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + ∃ G : M×M → ℝ, + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + ((reverseRay z).1,riemannianExp (reverseRay z).1 (reverseRay z).2) ∧ + (∀ᶠ r in 𝓝 z,G (riemannianExp r.1 r.2,r.1)=‖r.2‖^2/2) ∧ + ∀ᶠ r in 𝓝 (reverseRay z),r.2∈injectivityDomain r.1 → + (fun q : M×M => cost q.1 q.2) =ᶠ[𝓝 (r.1,riemannianExp r.1 r.2)] G := by + obtain ⟨G,hG,ha,hagree⟩ := exists_smooth_cost_branch_with_action + (reverseRay z) (reverseRay_nonconjugate z hz) + refine ⟨G,hG,?_,hagree⟩ + filter_upwards [continuous_reverseRay.continuousAt.eventually ha] with r hr + rw [norm_reverseRay,reverseRay_endpoint,reverseRay_base] at hr + exact hr + +end EndpointLowerJet +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/EnvelopeData.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/EnvelopeData.lean new file mode 100644 index 0000000000000000000000000000000000000000..f7df324005756b21c83caac23196c8e22aec867b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/EnvelopeData.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates3 + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +abbrev EnvelopeData (E ι : Type*) := (E × (ι → E)) × ((ι → ℝ) × ℝ) + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {ι : Type*} [Fintype ι] + +def scaledNormalEnvelope (a : M) (s : ℝ) (q : EnvelopeData (Model n) ι) (i : ι) + (h : Model n) : ℝ := + (movingNormalCost a q.1.1 (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) h - + movingNormalCost a q.1.1 (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) 0) - + (q.2.2 / s) * (movingNormalCost a q.1.1 (s • q.1.2 i) h - + movingNormalCost a q.1.1 (s • q.1.2 i) 0) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma scaledNormalEnvelope_zero (a : M) (s : ℝ) (q : EnvelopeData (Model n) ι) (i : ι) : + scaledNormalEnvelope a s q i 0 = 0 := by simp [scaledNormalEnvelope] + +lemma scaledNormalEnvelope_contDiffAt {a : M} {s : ℝ} + {q : EnvelopeData (Model n) ι} (i : ι) + (hb : q.1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + (hi : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) (s • q.1.2 i) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) : + ContDiffAt ℝ ∞ (fun z : EnvelopeData (Model n) ι × Model n => + scaledNormalEnvelope a s z.1 i z.2) (q,0) := by + have hmean : ContDiff ℝ ∞ (fun z : EnvelopeData (Model n) ι × Model n => + z.1.2.2 • ∑ j, z.1.2.1 j • z.1.1.2 j) := by fun_prop + have hpi : ContDiff ℝ ∞ (fun z : EnvelopeData (Model n) ι × Model n => + s • z.1.1.2 i) := by fun_prop + have hleft := movingNormalCost_contDiffAt hb hp + have hright := movingNormalCost_contDiffAt hb hi + exact ((hleft.comp (q,0) ((contDiffAt_fst.fst.fst.prodMk hmean.contDiffAt).prodMk contDiffAt_snd)).sub + (hleft.comp (q,0) ((contDiffAt_fst.fst.fst.prodMk hmean.contDiffAt).prodMk contDiffAt_const))).sub + ((contDiffAt_fst.snd.snd.div_const s).mul + ((hright.comp (q,0) ((contDiffAt_fst.fst.fst.prodMk hpi.contDiffAt).prodMk contDiffAt_snd)).sub + (hright.comp (q,0) ((contDiffAt_fst.fst.fst.prodMk hpi.contDiffAt).prodMk contDiffAt_const)))) + +lemma scaledNormalEnvelope_first {a : M} {s : ℝ} (hs : s ≠ 0) + {q : EnvelopeData (Model n) ι} (i : ι) + (hb : q.1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + (hi : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) (s • q.1.2 i) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) (v : Model n) : + fderiv ℝ (scaledNormalEnvelope a s q i) 0 v = + q.2.2 * inner ℝ + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (q.1.2 i - ∑ j, q.2.1 j • q.1.2 j)) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) v) := by + have H := ((movingNormalCost_hasFDerivAt_zero hb hp).sub_const + (movingNormalCost a q.1.1 (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) 0)).sub + (((movingNormalCost_hasFDerivAt_zero hb hi).sub_const + (movingNormalCost a q.1.1 (s • q.1.2 i) 0)).const_smul (q.2.2 / s)) + simp only [Pi.sub_def,Pi.smul_def,smul_eq_mul] at H + unfold scaledNormalEnvelope + rw [H.fderiv] + simp only [_root_.sub_apply,_root_.smul_apply,ContinuousLinearMap.comp_apply, + innerSL_apply_apply,map_smul,map_sub,inner_neg_left,real_inner_smul_left,inner_sub_left,smul_eq_mul] + field_simp + ring + +lemma scaledNormalEnvelope_second {a : M} {s : ℝ} + {q : EnvelopeData (Model n) ι} (i : ι) + (hb : q.1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + (hi : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) (s • q.1.2 i) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) (v : Model n) : + fderiv ℝ (fderiv ℝ (scaledNormalEnvelope a s q i)) 0 v v = + hessianValue ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (q.2.2 • ∑ j, q.2.1 j • q.1.2 j)) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) v) - + q.2.2 / s * hessianValue ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) (s • q.1.2 i)) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) v) := by + have hl : ContDiffAt ℝ 2 (movingNormalCost a q.1.1 (q.2.2 • ∑ j, q.2.1 j • q.1.2 j)) 0 := + ((movingNormalCost_contDiffAt hb hp).comp 0 + (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hr : ContDiffAt ℝ 2 (movingNormalCost a q.1.1 (s • q.1.2 i)) 0 := + ((movingNormalCost_contDiffAt hb hi).comp 0 + (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have H := second_fderiv_scaled_differences hl hr 1 (q.2.2 / s) v + unfold scaledNormalEnvelope + simpa only [one_mul,movingNormalCost_second hb hp,movingNormalCost_second hb hi] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyJensen.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyJensen.lean new file mode 100644 index 0000000000000000000000000000000000000000..9e0dc560d1238550bcf12e1caebe241a4773c624 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyJensen.lean @@ -0,0 +1,46 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.JensenAt +import OAI.Analysis.BiholderTransport.Regularity.FamilyComparison + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle MeasureTheory +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma WeakMTW.family_jensen_samples (hmtw : WeakMTW (n := n) (M := M)) + {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) {Kp : Set P} (hKp : IsCompact Kp) + (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) {Lφ : ℝ≥0} + (hφL : ∀ p∈Kp,LipschitzWith Lφ (fun s=>Φ (p,s))) (A B : ℝ) (a : M) : + ∃ R>0,∃ δ>0,∀ p∈Kp,∀ u:M → ℝ,Continuous u → (∀ y,cTransform u y∈Icc A B) → + ∀ ψ:ℝ → ℝ,Continuous ψ → ∀ τ:ℝ,0<τ → τ<1/2 → τ<δ → + ∀ c:M,extChartAt 𝓘(ℝ,Model n) a c∈ball (extChartAt 𝓘(ℝ,Model n) a a) R → + let χ := extChartAt 𝓘(ℝ,Model n) a + let w := fun y=>ψ (cTransform u y) + let g := fun y=>Φ (p,cTransform u y) + (∀ᶠ z in 𝓝 (χ c),chartOuterEnvelope w (1-τ) a z+chartCenterEnvelope g (1-τ) a z≤ + chartOuterEnvelope w (1-τ) a (χ c)+chartCenterEnvelope g (1-τ) a (χ c)) → + ∀ N:Set (Model n),volume N=0 → Nonempty (JensenSamplesAt w g (1-τ) a c N) := by + obtain ⟨R,hR,δ,hδ,H⟩ := hmtw.family_comparison_local_data hΦ hKp hmono hφL A B a + refine ⟨R,hR,δ,hδ,?_⟩ + intro p hp u hu hb ψ hψ τ hτ hhalf hτδ c hc + dsimp only + intro hm N hN + obtain ⟨r,hr,JF,JG,JY,JP,Y,hF,hG,hFL,hGL,hYL,hPL,hact⟩ := + H p hp u hu hb ψ hψ τ hτ hhalf hτδ c hc + exact jensen_samples_at isOpen_ball (mem_ball_self hr) hF hG hFL hGL hYL hPL hact hm hN + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/FamilySemiconvex.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilySemiconvex.lean new file mode 100644 index 0000000000000000000000000000000000000000..099df2b2fc86d7196486b9ff0c77ff5919053d08 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilySemiconvex.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.HopfSupports +import OAI.Analysis.BiholderTransport.Convexity.StrongCostConvexity +import OAI.Analysis.BiholderTransport.Convexity.ParametricSemiconvex + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma uniform_family_chart_semiconvex {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) + {Kp : Set P} (hKp : IsCompact Kp) (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) (A B : ℝ) (a : M) : + ∃ K>0,∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r⊆(extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ p∈Kp,∀ u : M → ℝ,Continuous u → (∀ y,cTransform u y∈Icc A B) → + ConvexOn ℝ (ball (extChartAt 𝓘(ℝ,Model n) a a) r) + (fun z => Φ (p,cTransform u ((extChartAt 𝓘(ℝ,Model n) a).symm z))+K/2*‖z‖^2) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + obtain ⟨K0,hK0,r0,hr0,hr0T,hSup⟩ := uniform_cTransform_chart_lower (n := n) a + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨L,r1,hr1,hr1T,hL⟩ := exists_lipschitzOn_inverse_chart (E := Model n) a + let D : ℝ≥0 := ⟨Metric.diam (univ : Set M),Metric.diam_nonneg⟩ + obtain ⟨K,hK,H⟩ := scalar_family_uniform_semiconvex (E := Model n) hΦ hKp hmono A B K0 hK0.le (D*L) + let r := min r0 r1 + have hr : 0 < r := lt_min hr0 hr1 + have hsub0 : ball (χ a) r⊆ball (χ a) r0 := ball_subset_ball (min_le_left _ _) + have hsub1 : ball (χ a) r⊆ball (χ a) r1 := ball_subset_ball (min_le_right _ _) + refine ⟨K,hK,r,hr,fun z hz => hr0T (hsub0 hz),?_⟩ + intro p hp u hu hb + apply H p hp _ (convex_ball _ _) _ + · exact (cTransform_lipschitz hu (fun x y => + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y))).comp_lipschitzOnWith (hL.mono hsub1) + · exact fun z hz => hb _ + · intro z hz + obtain ⟨l,hl⟩ := hSup u hu z (hsub0 hz) + exact ⟨l,fun y hy => hl y (hsub0 hy)⟩ + +lemma uniform_family_short_action_strongConvex {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) + {Kp : Set P} (hKp : IsCompact Kp) (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) (A B : ℝ) (a : M) : + ∃ m>0,∃ r>0,∃ V∈𝓝 (extChartAt 𝓘(ℝ,Model n) a a),∃ δ>0, + closedBall (extChartAt 𝓘(ℝ,Model n) a a) r⊆(extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ p∈Kp,∀ u : M → ℝ,Continuous u → (∀ y,cTransform u y∈Icc A B) → + ∀ t : ℝ,0 t*Φ (p,cTransform u ((extChartAt 𝓘(ℝ,Model n) a).symm y))+ + chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm z) y) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + obtain ⟨K,hK,R,hR,hRT,hsemi⟩ := uniform_family_chart_semiconvex (n := n) hΦ hKp hmono A B a + obtain ⟨m,hm,r0,hr0,V,hV,hstrong⟩ := chartCost_uniform_strongConvex + (mem_extChartAt_target (I := 𝓘(ℝ,Model n)) a) + let r := min r0 (R/2) + have hr : 0 < r := lt_min hr0 (half_pos hR) + have hsub0 : closedBall (χ a) r⊆closedBall (χ a) r0 := closedBall_subset_closedBall (min_le_left _ _) + have hsubR : closedBall (χ a) r⊆ball (χ a) R := closedBall_subset_ball (lt_of_le_of_lt (min_le_right _ _) (half_lt_self hR)) + refine ⟨m / 2,half_pos hm,r,hr,V,hV,m / (2*K),by positivity,fun z hz => hRT (hsubR hz),?_⟩ + intro p hp u hu hb t ht htδ z hz + have hs : StrongConvexOn (closedBall (χ a) r) m (chartCost a (χ.symm z)) := + ⟨convex_closedBall _ _,fun {x} hx {y} hy {p} {q} hp hq hsum => (hstrong z hz).2 (hsub0 hx) (hsub0 hy) hp hq hsum⟩ + have hh := strongConvexOn_add_semiconvex hs + ((hsemi p hp u hu hb).subset hsubR (convex_closedBall _ _)) ht.le + have htK : t*K< m / 2 := by + apply (lt_div_iff₀ hK).mp + simpa only [div_div] using htδ + have hle : m / 2 ≤ m-t*K := by linarith + have H := _root_.StrongConvexOn.mono hle hh + simpa only [add_comm] using H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyShortEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyShortEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..a94d9ec97e3d25f3e984df7c8b7bcc2c2ace3d82 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/FamilyShortEnvelope.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ChartHopfLocalization +import OAI.Analysis.BiholderTransport.Regularity.KernelBounds +import OAI.Analysis.BiholderTransport.Convexity.StrongEnvelope +import OAI.Analysis.BiholderTransport.Convexity.FamilySemiconvex + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma uniform_family_short_envelope_data {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) + {Kp : Set P} (hKp : IsCompact Kp) (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) + {Lφ : ℝ≥0} (hφL : ∀ p∈Kp,LipschitzWith Lφ (fun s=>Φ (p,s))) + (A B : ℝ) (a : M) : + ∃ J JY : ℝ≥0,∃ r>0,∃ δ>0,∀ p∈Kp,∀ u : M → ℝ,Continuous u → + (∀ y,cTransform u y∈Icc A B) → ∀ t : ℝ,0 t*hopfLax t (fun y => Φ (p,cTransform u y)) + ((extChartAt 𝓘(ℝ,Model n) a).symm z) + (∀ z∈ball (extChartAt 𝓘(ℝ,Model n) a a) r,DifferentiableAt ℝ F z) ∧ + LipschitzOnWith J (fderiv ℝ F) (ball (extChartAt 𝓘(ℝ,Model n) a a) (r/4)) ∧ + ∃ Y0 : Model n → M, + LipschitzOnWith JY (fun z => extChartAt 𝓘(ℝ,Model n) a (Y0 z)) + (ball (extChartAt 𝓘(ℝ,Model n) a a) r) ∧ + ∀ z∈ball (extChartAt 𝓘(ℝ,Model n) a a) r, + Y0 z∈(extChartAt 𝓘(ℝ,Model n) a).source ∧ + ∀ y:M,hopfLax t (fun y => Φ (p,cTransform u y)) + ((extChartAt 𝓘(ℝ,Model n) a).symm z)= + Φ (p,cTransform u y)+cost y ((extChartAt 𝓘(ℝ,Model n) a).symm z)/t ↔ y=Y0 z := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let C : Model n → Model n → ℝ := fun y z => chartCost a (χ.symm z) y + have hc : ContDiffAt ℝ ∞ (Function.uncurry C) (χ a,χ a) := + (chartCost_pair_contDiffAt_diagonal (mem_extChartAt_target (I := 𝓘(ℝ,Model n)) a)).comp + (χ a,χ a) (contDiffAt_snd.prodMk contDiffAt_fst) + obtain ⟨K,H,hK,hH,Rk,hRk,hCs,hrem,hcross⟩ := smooth_kernel_local_bounds hc + obtain ⟨m,hm,R0,hR0,V0,hV0,δ0,hδ0,hR0T,hs⟩ := + uniform_family_short_action_strongConvex (n := n) hΦ hKp hmono A B a + let R := min R0 (Rk/2) + have hR : 0 Φ (p,cTransform u y) + have hw : LipschitzWith (Lφ*D) w := (hφL p hp).comp + (cTransform_lipschitz hu (fun x y => + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y))) + let F : Model n → ℝ := fun z => t*hopfLax t w (χ.symm z) + let W : Model n → ℝ := fun y => t*w (χ.symm y) + choose Y0 hY0 hmin0 using (fun z : Model n => exists_hopfLax_minimizer hw.continuous t (χ.symm z)) + let Y : Model n → Model n := fun z => χ (Y0 z) + have hycoord (z:Model n) (hz:z∈ball (χ a) r) : + Y0 z∈χ.source ∧ Y z∈ball (χ a) R := + hlocal t ht (lt_of_lt_of_le htδ (min_le_right _ _)) z (hrV hz).2.1 w hw (Y0 z) (hY0 z) + have hY : ∀ z∈ball (χ a) r,Y z∈closedBall (χ a) R := + fun z hz => ball_subset_closedBall ((hycoord z hz).2) + have hval : ∀ z∈ball (χ a) r,F z=W (Y z)+C (Y z) z := by + intro z hz + dsimp only [F,W,C,chartCost,Y] + rw [χ.left_inv (hycoord z hz).1,hY0 z] + field_simp + have hmin : ∀ z∈ball (χ a) r,∀ y∈closedBall (χ a) R,F z≤W y+C y z := by + intro z hz y hy + have HH := mul_le_mul_of_nonneg_left (hopfLax_le hw.continuous t (χ.symm z) (χ.symm y)) ht.le + dsimp only [F,W,C,chartCost] + simpa only [mul_add,←mul_div_assoc,mul_div_cancel_left₀ _ ht.ne'] using HH + have hstrong : ∀ z∈ball (χ a) r, + StrongConvexOn (closedBall (χ a) R) m (fun y => W y+C y z) := by + intro z hz + have HH := hs p hp u hu hb t ht (lt_of_lt_of_le htδ (min_le_left _ _)) z (hrV hz).1 + exact ⟨convex_closedBall _ _,fun {x} hx {y} hy {p} {q} hp hq hsum => + HH.2 (hS0 hx) (hS0 hy) hp hq hsum⟩ + have HC : ∀ y∈closedBall (χ a) R,∀ y'∈closedBall (χ a) R, + ∀ z∈ball (χ a) r,∀ z'∈ball (χ a) r, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖ := + fun y hy y' hy' z hz z' hz' => hcross y (hSk hy) y' (hSk hy') + z (hrV hz).2.2 z' (hrV hz').2.2 + have HR : ∀ z∈ball (χ a) r,∀ z'∈ball (χ a) r, + |C (Y z) z'-C (Y z) z-fderiv ℝ (C (Y z)) z (z'-z)|≤H*‖z'-z‖^2 := + fun z hz z' hz' => hrem (Y z) (hSk (hY z hz)) z (hrV hz).2.2 z' (hrV hz').2.2 + obtain ⟨hd,hLip⟩ := strong_envelope_C11 hr hm hK hH hY hval hmin hstrong HC HR + refine ⟨fun z hz => (hd z hz).differentiableAt,hLip,Y0, + strong_envelope_minimizer_lipschitz hm hK hY hval hmin hstrong HC,?_⟩ + intro z hz + refine ⟨(hycoord z hz).1,?_⟩ + intro y + constructor + · intro hy + have hym := hlocal t ht (lt_of_lt_of_le htδ (min_le_right _ _)) + z (hrV hz).2.1 w hw y hy + have hyeq : F z=W (χ y)+C (χ y) z := by + dsimp only [F,W,C,chartCost] + rw [χ.left_inv hym.1,hy] + field_simp + rfl + have he := strongly_convex_minimizer_unique hm (hstrong z hz) (hY z hz) + (ball_subset_closedBall hym.2) + (show IsMinOn (fun y => W y+C y z) (closedBall (χ a) R) (Y z) from by + intro y' hy' + change W (Y z)+C (Y z) z≤W y'+C y' z + rw [←hval z hz] + exact hmin z hz y' hy') ((hval z hz).symm.trans hyeq) + exact χ.injOn hym.1 (hycoord z hz).1 he.symm + · rintro rfl + exact hY0 z + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/Fermat.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/Fermat.lean new file mode 100644 index 0000000000000000000000000000000000000000..d9be510bb4bd5f51d2cf80a138a7249e25f5681e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/Fermat.lean @@ -0,0 +1,93 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + +lemma isLocalMin_hasMFDerivAt_eq_zero {f : M → ℝ} {x : M} + {L : TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ} + (h : IsLocalMin f x) (hD : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f x L) : L = 0 := by + let c := extChartAt 𝓘(ℝ,E) x + have hx : x ∈ c.source := mem_extChartAt_source x + have hcx : c x ∈ c.target := c.map_source hx + have hc : ContinuousAt c.symm (c x) := + ((continuousOn_extChartAt_symm x) _ hcx).continuousAt ((isOpen_extChartAt_target x).mem_nhds hcx) + have hmin : IsLocalMin (fun w : E => f (c.symm w)) (c x) := by + have hh : IsLocalMin f (c.symm (c x)) := by rw [c.left_inv hx]; exact h + exact hh.comp_continuous hc + have hDf : HasFDerivAt (fun w : E => f (c.symm w)) L (c x) := by + convert! hD.2.hasFDerivAt (by simp only [mfld_simps,Filter.univ_mem]) + exact hmin.hasFDerivAt_eq_zero hDf + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/FirstCutConvex.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/FirstCutConvex.lean new file mode 100644 index 0000000000000000000000000000000000000000..77c76caaff8a412cb32eff2be3e7706233a62dc5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/FirstCutConvex.lean @@ -0,0 +1,246 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.FirstCutSegment + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.convex_nonconjugate_subset (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {C : Set (TangentSpace 𝓘(ℝ,Model n) x)} + (hC : Convex ℝ C) (hmin : C ⊆ minimizingVectors x) : + Convex ℝ {p | p ∈ C ∧ Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)} := by + intro u hu v hv a b ha hb hab + refine ⟨hC hu.1 hv.1 ha hb hab,?_⟩ + by_cases ha0 : a=0 + · have hb1 : b=1 := by linarith + simpa only [ha0,hb1,zero_smul,zero_add,one_smul] using hv.2 + by_cases hb0 : b=0 + · have ha1 : a=1 := by linarith + simpa only [hb0,ha1,zero_smul,add_zero,one_smul] using hu.2 + by_cases huv : u=v + · have heq : a • u+b • v=v := by rw [huv,←add_smul,hab,one_smul] + rw [heq] + exact hv.2 + let p := a • u+b • v + let e := v-u + have he : e≠0 := sub_ne_zero.mpr (Ne.symm huv) + have hleftEq : p+(-b) • e=u := by + dsimp [p,e] + rw [show a=1-b by linarith] + module + have hrightEq : p+a • e=v := by + dsimp [p,e] + rw [show b=1-a by linarith] + module + have hseg : ∀ s ∈ Icc (-b) a, p+s • e ∈ minimizingVectors x := by + intro s hs + have hq : p+s • e=(a-s) • u+(b+s) • v := by dsimp [p,e]; module + rw [hq] + exact hmin (hC hu.1 hv.1 (sub_nonneg.mpr hs.2) (by linarith [hs.1]) (by linarith)) + have hleft : Function.Injective (fderiv ℝ (fun w => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+(-b) • e)) (riemannianExp x w)) (p+(-b) • e)) := by + rw [hleftEq] + exact hu.2 + have hright : Function.Injective (fderiv ℝ (fun w => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+a • e)) (riemannianExp x w)) (p+a • e)) := by + rw [hrightEq] + exact hv.2 + let D := fderiv ℝ (fun w => extChartAt 𝓘(ℝ,Model n) (riemannianExp x p) (riemannianExp x w)) p + have hzero (k) (hk : D k=0) : k=0 := by + apply hmtw.firstcut_segment_kernel_zero (neg_neg_iff_pos.mpr (lt_of_le_of_ne hb (Ne.symm hb0))) + (lt_of_le_of_ne ha (Ne.symm ha0)) he hseg hleft hright + rw [exp_mfderiv_apply_eq_coordinate] + exact hk + intro k l hkl + apply sub_eq_zero.mp + apply hzero (k-l) + rw [map_sub,hkl,sub_self] + +lemma WeakMTW.convexHull_nonconjugate (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {S : Set (TangentSpace 𝓘(ℝ,Model n) x)} + (hmin : convexHull ℝ S ⊆ minimizingVectors x) + (hreg : ∀ p ∈ S, Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ convexHull ℝ S) : + Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p) := by + have hsub : S ⊆ {q | q ∈ convexHull ℝ S ∧ Function.Injective (fderiv ℝ (fun v => + extChartAt 𝓘(ℝ,Model n) (riemannianExp x q) (riemannianExp x v)) q)} := + fun q hq => ⟨subset_convexHull ℝ S hq,hreg q hq⟩ + exact (convexHull_min hsub (hmtw.convex_nonconjugate_subset (convex_convexHull ℝ S) hmin) hp).2 +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAt.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAt.lean new file mode 100644 index 0000000000000000000000000000000000000000..ff39f8fc5f9d75792d3f0d0053dbedebbc0c1f79 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAt.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.SimultaneousC11Jensen +import OAI.Analysis.BiholderTransport.LinearAlgebra.C11HessianLimits +import OAI.Analysis.BiholderTransport.Convexity.JensenPackage + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure JensenSamplesAt (v g : M → ℝ) (t : ℝ) (a c : M) (N : Set (Model n)) where + z : ℕ → Model n + Y : Model n → M + Af : Model n →L[ℝ] Model n →L[ℝ] ℝ + Ac : Model n →L[ℝ] Model n →L[ℝ] ℝ + points : Tendsto z atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a c)) + outerHessians : Tendsto (fun i=>fderiv ℝ (fderiv ℝ (chartOuterEnvelope v t a)) (z i)) atTop (𝓝 Af) + centerHessians : Tendsto (fun i=>fderiv ℝ (fderiv ℝ (chartCenterEnvelope g t a)) (z i)) atTop (𝓝 Ac) + gradients : Tendsto (fun i=>fderiv ℝ (chartOuterEnvelope v t a) (z i)+ + fderiv ℝ (chartCenterEnvelope g t a) (z i)) atTop (𝓝 0) + upper : ∀ d:Model n,Af d d+Ac d d≤0 + region : Set (Model n) + openRegion : IsOpen region + centerInRegion : extChartAt 𝓘(ℝ,Model n) a c∈region + sampleInRegion : ∀ i,z i∈region + outerDifferentiable : ∀ z∈region,DifferentiableAt ℝ (chartOuterEnvelope v t a) z + centerDifferentiable : ∀ z∈region,DifferentiableAt ℝ (chartCenterEnvelope g t a) z + outerGradientContinuous : ContinuousOn (fderiv ℝ (chartOuterEnvelope v t a)) region + centerGradientContinuous : ContinuousOn (fderiv ℝ (chartCenterEnvelope g t a)) region + selectorContinuous : ContinuousOn (fun z=>extChartAt 𝓘(ℝ,Model n) a (Y z)) region + actual : ∀ z∈region, + let χ := extChartAt 𝓘(ℝ,Model n) a + let P : Model n → M := chartActualPole v t a + let χP := extChartAt 𝓘(ℝ,Model n) (P (χ c)) + Y z∈χ.source ∧ P z∈χP.source ∧ + (∀ y:M,chartCenterEnvelope g t a z=g y+cost y (χ.symm z)/(1-t) ↔ y=Y z) ∧ + chartOuterEnvelope v t a z=cTransform v (P z)+cost (P z) (χ.symm z)/t + samples : ∀ i, + let χ := extChartAt 𝓘(ℝ,Model n) a + let P : Model n → M := chartActualPole v t a + let χP := extChartAt 𝓘(ℝ,Model n) (P (χ c)) + let F : Model n → ℝ := chartOuterEnvelope v t a + let C := chartCenterEnvelope g t a + Y (z i)∈χ.source ∧ P (z i)∈χP.source ∧ + (∀ y:M,C (z i)=g y+cost y (χ.symm (z i))/(1-t) ↔ y=Y (z i)) ∧ + F (z i)=cTransform v (P (z i))+cost (P (z i)) (χ.symm (z i))/t ∧ + HasFDerivAt (fun w=>χ (Y w)) (fderiv ℝ (fun w=>χ (Y w)) (z i)) (z i) ∧ + HasFDerivAt (fun w=>χP (P w)) (fderiv ℝ (fun w=>χP (P w)) (z i)) (z i) ∧ + ((fderiv ℝ (fun w=>χ (Y w)) (z i)).det≠0 → χ (Y (z i))∉N) ∧ + DifferentiableAt ℝ (fderiv ℝ F) (z i) ∧ DifferentiableAt ℝ (fderiv ℝ C) (z i) ∧ + HasSecondTaylor (fun h=>F (z i+h)) (fderiv ℝ F (z i)) (fderiv ℝ (fderiv ℝ F) (z i)) ∧ + HasSecondTaylor (fun h=>C (z i+h)) (fderiv ℝ C (z i)) (fderiv ℝ (fderiv ℝ C) (z i)) + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma jensen_samples_at {v g : M → ℝ} {t : ℝ} {a c : M} + {S : Set (Model n)} (hS : IsOpen S) (hz0 : extChartAt 𝓘(ℝ,Model n) a c∈S) + {Y : Model n → M} {JF JG JY JP : ℝ≥0} + (hF : ∀ z∈S,DifferentiableAt ℝ (chartOuterEnvelope v t a) z) + (hG : ∀ z∈S,DifferentiableAt ℝ (chartCenterEnvelope g t a) z) + (hFL : LipschitzOnWith JF (fderiv ℝ (chartOuterEnvelope v t a)) S) + (hGL : LipschitzOnWith JG (fderiv ℝ (chartCenterEnvelope g t a)) S) + (hYL : LipschitzOnWith JY (fun z=>extChartAt 𝓘(ℝ,Model n) a (Y z)) S) + (hPL : LipschitzOnWith JP (fun z=>extChartAt 𝓘(ℝ,Model n) + (chartActualPole v t a (extChartAt 𝓘(ℝ,Model n) a c)) (chartActualPole v t a z)) S) + (hactual : ∀ z∈S, + let χ := extChartAt 𝓘(ℝ,Model n) a + let P : Model n → M := chartActualPole v t a + let χP := extChartAt 𝓘(ℝ,Model n) (P (χ c)) + Y z∈χ.source ∧ P z∈χP.source ∧ + (∀ y:M,chartCenterEnvelope g t a z=g y+cost y (χ.symm z)/(1-t) ↔ y=Y z) ∧ + chartOuterEnvelope v t a z=cTransform v (P z)+cost (P z) (χ.symm z)/t) + (hmax : ∀ᶠ z in 𝓝 (extChartAt 𝓘(ℝ,Model n) a c), + chartOuterEnvelope v t a z+chartCenterEnvelope g t a z≤ + chartOuterEnvelope v t a (extChartAt 𝓘(ℝ,Model n) a c)+ + chartCenterEnvelope g t a (extChartAt 𝓘(ℝ,Model n) a c)) + {N : Set (Model n)} (hN : volume N=0) : Nonempty (JensenSamplesAt (n := n) v g t a c N) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let F : Model n → ℝ := chartOuterEnvelope v t a + let G : Model n → ℝ := chartCenterEnvelope g t a + let P : Model n → M := chartActualPole v t a + let χP := extChartAt 𝓘(ℝ,Model n) (P (χ c)) + let R := fun z:Model n=> + Y z∈χ.source ∧ P z∈χP.source ∧ + (∀ y:M,G z=g y+cost y (χ.symm z)/(1-t) ↔ y=Y z) ∧ + F z=cTransform v (P z)+cost (P z) (χ.symm z)/t ∧ + HasFDerivAt (fun q=>χ (Y q)) (fderiv ℝ (fun q=>χ (Y q)) z) z ∧ + HasFDerivAt (fun q=>χP (P q)) (fderiv ℝ (fun q=>χP (P q)) z) z ∧ + ((fderiv ℝ (fun q=>χ (Y q)) z).det≠0 → χ (Y z)∉N) ∧ + DifferentiableAt ℝ (fderiv ℝ F) z ∧ DifferentiableAt ℝ (fderiv ℝ G) z ∧ + HasSecondTaylor (fun h=>F (z+h)) (fderiv ℝ F z) (fderiv ℝ (fderiv ℝ F) z) ∧ + HasSecondTaylor (fun h=>G (z+h)) (fderiv ℝ G z) (fderiv ℝ (fderiv ℝ G) z) + have hselect : ∀ rho eta:ℝ,0(hz i).1, + hF,hG,hFL.continuousOn,hGL.continuousOn,hYL.continuousOn,hactual,fun i=>(hz i).2⟩⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAtCenter.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAtCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..37b698f7ee33f1faa19261c2c503ca079644271c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenAtCenter.lean @@ -0,0 +1,48 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CenterSupportFamily +import OAI.Analysis.BiholderTransport.Convexity.JensenAt + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section JensenAtCenter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.jensen_at_center_row (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) {Lv : ℝ≥0} (hv : LipschitzWith Lv v) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hφ : Continuous φ) (hmono : Monotone φ) + {w : M → ℝ} {t l : ℝ} (ht : 0φ (v y)) t a c N) (k : ℕ) + (hd : HasDerivAt φ l (v (J.Y (J.z k)))) (hl : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.jensen_at_first_limit_in_chart (hmtw : WeakMTW (n := n) (M := M)) + {v g : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0e.symm (χ.symm (J.z k))) (e.symm c)) := by + let χ := extChartAt 𝓘(ℝ,Model n) d + let e := hmtw.graphHomeomorph hv ht ht1 + let q := fun k=>e.symm (χ.symm (J.z k)) + let q₀ := e.symm c + have hproj : ∀ k,graphProjection (cTransform v) t (q k)=χ.symm (J.z k) := + fun k=>e.apply_symm_apply _ + have hproj₀ : graphProjection (cTransform v) t q₀=c := e.apply_symm_apply c + have hat := χ.map_source hcd + have hleft : χ.symm (χ c)=c := χ.left_inv hcd + have hzman : Tendsto (fun k=>χ.symm (J.z k)) atTop (𝓝 c) := by + have hc : ContinuousAt χ.symm (χ c) := continuousAt_extChartAt_symm'' hat + have H := hc.tendsto.comp J.points + rwa [hleft] at H + have hz : Tendsto (fun k=>graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀)) := by + simpa only [hproj,hproj₀] using hzman + have he : ∀ᶠ k in atTop,χ (graphProjection (cTransform v) t (q k))=J.z k := by + filter_upwards [J.points.eventually ((isOpen_extChartAt_target d).mem_nhds hat)] with k hk + rw [hproj] + exact χ.right_inv hk + have hc : graphProjection (cTransform v) t q₀∈χ.source := + hproj₀ ▸ hcd + have hpole : q₀.1.1=chartActualPole v t d (χ c) := by + dsimp only [chartActualPole] + rw [hleft] + exact hmtw.graphHomeomorph_inverse_pole hv ht ht1 c + have hder : ∀ᶠ k in atTop, + DifferentiableAt ℝ (fderiv ℝ (chartOuterEnvelope v t d)) + (χ (graphProjection (cTransform v) t (q k))) ∧ + DifferentiableAt ℝ (fderiv ℝ (chartCenterEnvelope g t d)) + (χ (graphProjection (cTransform v) t (q k))) ∧ + DifferentiableAt ℝ (fun w:Model n=>extChartAt 𝓘(ℝ,Model n) q₀.1.1 + (chartActualPole v t d w)) (χ (graphProjection (cTransform v) t (q k))) := by + filter_upwards [he] with k hk + rw [hk,hpole] + have H := J.samples k + exact ⟨H.2.2.2.2.2.2.2.1,H.2.2.2.2.2.2.2.2.1,H.2.2.2.2.2.1.differentiableAt⟩ + have ha0 : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source := by + rw [hmtw.graphHomeomorph_inverse_pole hv ht ht1 c] + exact ha + apply hmtw.first_fixed_prefix_limit_in_chart hv ht ht1 q q₀ hz ha0 hc + (mem_extChartAt_source q₀.1.1) J.Af J.Ac + · simpa only [hproj₀] using hF + · simpa only [hproj₀] using hC + · simpa only [hproj₀] using hnear + · exact J.outerHessians.congr' (he.mono (fun k hk=>congrArg + (fderiv ℝ (fderiv ℝ (chartOuterEnvelope v t d))) hk.symm)) + · exact J.centerHessians.congr' (he.mono (fun k hk=>congrArg + (fderiv ℝ (fderiv ℝ (chartCenterEnvelope g t d))) hk.symm)) + · exact J.gradients.congr' (he.mono (fun k hk=>congrArg + (fun z=>fderiv ℝ (chartOuterEnvelope v t d) z+fderiv ℝ (chartCenterEnvelope g t d) z) hk.symm)) + · exact J.upper + · exact hder + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenMaximum.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenMaximum.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ef8779b1cb160c810f52ab6eb38323b9560fce5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenMaximum.lean @@ -0,0 +1,135 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + +lemma jensen_C11_select {f : E → ℝ} {g : E → E} {x0 : E} {r eta : ℝ} + {L : ℝ≥0} (hr : 0 < r) (heta : 0 < eta) + (hf : ContinuousOn f (Metric.closedBall x0 r)) + (hmax : ∀ x ∈ Metric.closedBall x0 r, f x ≤ f x0) + (hd : ∀ x ∈ Metric.ball x0 r, HasFDerivAt f ((innerSL ℝ) (g x)) x) + (hlip : LipschitzOnWith L g (Metric.closedBall x0 r)) + (μ : Measure E) [μ.IsAddHaarMeasure] {P : E → Prop} (hP : ∀ᵐ z ∂μ, P z) : + ∃ z ∈ Metric.ball x0 r, P z ∧ ‖g z‖ ≤ 2*eta*r ∧ + ∀ x ∈ Metric.closedBall x0 r, + f x ≤ f z + inner ℝ (g z) (x-z) + eta/2*‖x-z‖^2 := by + let nu : Measure E := Measure.hausdorffMeasure (Module.finrank ℝ E) + let psi : E → E := fun x => g x - eta • (x-x0) + let N : Set E := Metric.closedBall x0 r ∩ {x | ¬P x} + have hN : μ N = 0 := measure_mono_null inter_subset_right (ae_iff.mp hP) + have hNnu : nu N = 0 := (Measure.absolutelyContinuous_isAddHaarMeasure nu μ) hN + have hpsi : LipschitzOnWith (L+⟨eta,heta.le⟩) psi (Metric.closedBall x0 r) := by + apply LipschitzOnWith.of_dist_le_mul + intro x hx y hy + have heq : psi x - psi y = (g x-g y)-eta • (x-y) := by + dsimp [psi] + simp only [smul_sub] + abel + rw [dist_eq_norm,heq] + calc + ‖(g x-g y)-eta • (x-y)‖ ≤ ‖g x-g y‖+‖eta • (x-y)‖ := norm_sub_le _ _ + _ ≤ L * dist x y + eta * dist x y := by + simp only [norm_smul_of_nonneg heta.le,← dist_eq_norm] + exact add_le_add (hlip.dist_le_mul x hx y hy) le_rfl + _ = (↑(L+⟨eta,heta.le⟩) : ℝ) * dist x y := by change (L:ℝ)*dist x y+eta*dist x y=((L:ℝ)+eta)*dist x y; ring + have hnullnu : nu (psi '' N) = 0 := by + have hh := (hpsi.mono (show N ⊆ Metric.closedBall x0 r from inter_subset_left)).hausdorffMeasure_image_le + (by positivity : (0:ℝ) ≤ Module.finrank ℝ E) + simpa only [nu,hNnu,mul_zero,nonpos_iff_eq_zero] using hh + have hnull : μ (psi '' N) = 0 := + (Measure.absolutelyContinuous_isAddHaarMeasure μ nu) hnullnu + have hdense : Dense {a | a ∉ psi '' N} := μ.dense_of_ae + (ae_iff.mpr (by simpa only [not_not,Set.ofPred_mem_eq] using hnull)) + obtain ⟨a,ha,han⟩ := hdense.inter_open_nonempty (Metric.ball 0 (eta*r/4)) + Metric.isOpen_ball (Metric.nonempty_ball.mpr (by positivity)) + have hanorm : ‖a‖ < eta*r/4 := by simpa only [Metric.mem_ball,dist_zero_right] using ha + let F : E → ℝ := fun x => f x - eta/2*‖x-x0‖^2-inner ℝ a (x-x0) + have hFc : ContinuousOn F (Metric.closedBall x0 r) := by + exact (hf.sub (by fun_prop)).sub (by fun_prop) + obtain ⟨z,hz,hzmax⟩ := (isCompact_closedBall x0 r).exists_isMaxOn + (Metric.nonempty_closedBall.mpr hr.le) hFc + have hcenter : F x0 ≤ F z := hzmax (Metric.mem_closedBall_self hr.le) + have hzb : z ∈ Metric.ball x0 r := by + have hzn : ‖z-x0‖ ≤ r := by simpa only [Metric.mem_closedBall,dist_eq_norm] using hz + have hlin := abs_real_inner_le_norm a (z-x0) + have hz0 := hmax z hz + have hanon : -‖a‖*‖z-x0‖ ≤ inner ℝ a (z-x0) := by + have hh := (abs_le.mp hlin).1 + nlinarith + by_contra hn + have hzeq : ‖z-x0‖ = r := by + have hh : r ≤ ‖z-x0‖ := by simpa only [Metric.mem_ball,dist_eq_norm,not_lt] using hn + exact le_antisymm hzn hh + dsimp [F] at hcenter + simp only [sub_self,norm_zero,zero_pow (by decide : 2 ≠ 0),mul_zero,inner_zero_right,sub_zero] at hcenter + rw [hzeq] at hcenter hanon + have hh : ‖a‖*r < eta*r^2/4 := by nlinarith + have hpos : 0 < eta*r^2 := mul_pos heta (sq_pos_of_pos hr) + nlinarith + have hdF : HasFDerivAt F ((innerSL ℝ) (psi z-a)) z := by + have hdq : HasFDerivAt (fun x:E => eta/2*‖x-x0‖^2) + ((eta/2) • (2 • ((innerSL ℝ) (z-x0)))) z := by + simpa only [id_eq,ContinuousLinearMap.comp_id] using + ((((hasFDerivAt_id (𝕜 := ℝ) z).sub_const x0).norm_sq).const_mul (eta/2)) + have hda : HasFDerivAt (fun x:E => inner ℝ a (x-x0)) ((innerSL ℝ) a) z := by + simpa only [id_eq,ContinuousLinearMap.comp_id,Function.comp_def,innerSL_apply_apply] using + (((innerSL ℝ) a).hasFDerivAt.comp z + ((hasFDerivAt_id (𝕜 := ℝ) z).sub_const x0)) + apply (((hd z hzb).sub hdq).sub hda).congr_fderiv + ext h + simp only [psi,sub_apply,smul_apply,innerSL_apply_apply,inner_sub_left,real_inner_smul_left] + ring + have hzero := (hzmax.isLocalMax (mem_of_superset + (Metric.isOpen_ball.mem_nhds hzb) Metric.ball_subset_closedBall)).hasFDerivAt_eq_zero hdF + have hpsia : psi z = a := by + have heval := congrArg (fun A : E →L[ℝ] ℝ => A (psi z-a)) hzero + simp only [innerSL_apply_apply,zero_apply,real_inner_self_eq_norm_sq] at heval + exact sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp heval)) + have hzP : P z := by + by_contra hn + exact han ⟨z,⟨hz,hn⟩,hpsia⟩ + have hg : g z = eta • (z-x0)+a := by + dsimp [psi] at hpsia + exact (sub_eq_iff_eq_add.mp hpsia).trans (add_comm _ _) + refine ⟨z,hzb,hzP,?_,?_⟩ + · have hzn : ‖z-x0‖ < r := by simpa only [Metric.mem_ball,dist_eq_norm] using hzb + calc + ‖g z‖ ≤ eta*‖z-x0‖+‖a‖ := by rw [hg]; simpa only [norm_smul_of_nonneg heta.le] using norm_add_le (eta • (z-x0)) a + _ ≤ 2*eta*r := by nlinarith + · intro x hx + have hm := hzmax hx + have hnorm : ‖x-x0‖^2 = ‖x-z‖^2+2*inner ℝ (x-z) (z-x0)+‖z-x0‖^2 := by + have heq : x-x0 = (x-z)+(z-x0) := by abel + rw [heq] + simp only [← real_inner_self_eq_norm_sq,inner_add_left,inner_add_right] + have hcom : inner ℝ (z-x0) (x-z) = inner ℝ (x-z) (z-x0) := real_inner_comm _ _ + rw [hcom] + ring + have hinner : inner ℝ a (x-x0) = inner ℝ a (x-z)+inner ℝ a (z-x0) := by + rw [show x-x0 = (x-z)+(z-x0) by abel,inner_add_right] + dsimp [F] at hm + rw [hnorm,hinner] at hm + rw [hg,inner_add_left,real_inner_smul_left] + have hcom : inner ℝ (x-z) (z-x0) = inner ℝ (z-x0) (x-z) := real_inner_comm _ _ + rw [hcom] at hm + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPackage.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPackage.lean new file mode 100644 index 0000000000000000000000000000000000000000..99538b21ffaff920b5dccb0eeb2e0b2e5422c102 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPackage.lean @@ -0,0 +1,28 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +abbrev chartOuterEnvelope (v : M → ℝ) (t : ℝ) (a : M) : Model n → ℝ := + fun z=>hopfLax t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) a).symm z) +abbrev chartCenterEnvelope (g : M → ℝ) (t : ℝ) (a : M) : Model n → ℝ := + fun z=>hopfLax (1-t) g ((extChartAt 𝓘(ℝ,Model n) a).symm z) +abbrev chartActualPole (v : M → ℝ) (t : ℝ) (a : M) : Model n → M := + fun z=>hopfPole (n := n) t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) a).symm z) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhase.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhase.lean new file mode 100644 index 0000000000000000000000000000000000000000..5214d2ebcdb8e81ed4a3208a704b48f49a68be38 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhase.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.JensenAt +import OAI.Analysis.BiholderTransport.Regularity.ModifiedPhase +import OAI.Analysis.BiholderTransport.Calculus.PhaseGraphDerivative + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.jensen_phase_graph_identity (hmtw:WeakMTW (n:=n) (M:=M)) + {u v w:M → ℝ} (hu:Continuous u) {L:ℝ≥0} (hv:LipschitzWith L v) + (hdual:IsCostDualPair u v) {φ:ℝ → ℝ} (hφ:ContDiff ℝ ∞ φ) + (hslope:∀y:M,0φ (v y)) t a c N) (i:ℕ) + (hi:J.z i∈(extChartAt 𝓘(ℝ,Model n) a).target) + {p:Model n} {A:Model n →L[ℝ] Model n} {r K:ℝ} (hr:0φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a (J.Y (J.z i))+h)))) p A) + (hsem:ConvexOn ℝ (Metric.ball (extChartAt 𝓘(ℝ,Model n) a (J.Y (J.z i))) r) + (fun q=>φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm q))+K/2*‖q‖^2)) + (hflow:DifferentiableAt ℝ (fun q:Phase n=>coordinatePhaseFlow a (1-t,q)) + (J.z i,fderiv ℝ (chartCenterEnvelope (fun y=>φ (v y)) t a) (J.z i))) : + (fderiv ℝ (fun q:Phase n=>coordinatePhaseFlow a (1-t,q)) + (J.z i,fderiv ℝ (chartCenterEnvelope (fun y=>φ (v y)) t a) (J.z i))).comp + ((ContinuousLinearMap.id ℝ (Model n)).prod + (fderiv ℝ (fderiv ℝ (chartCenterEnvelope (fun y=>φ (v y)) t a)) (J.z i)))= + (fderiv ℝ (fun z=>extChartAt 𝓘(ℝ,Model n) a (J.Y z)) (J.z i)).prod + (((innerSL ℝ).comp A).comp + (fderiv ℝ (fun z=>extChartAt 𝓘(ℝ,Model n) a (J.Y z)) (J.z i))) := by + let χ:=extChartAt 𝓘(ℝ,Model n) a + let G:=chartCenterEnvelope (n := n) (fun y=>φ (v y)) t a + have hY:HasFDerivAt (fun z=>χ (J.Y z)) (fderiv ℝ (fun z=>χ (J.Y z)) (J.z i)) (J.z i) := + (J.samples i).2.2.2.2.1 + have hsub:∀ᶠ z in 𝓝 (J.z i), + (coordinatePhaseFlow a (1-t,z,fderiv ℝ G z)).1=χ (J.Y z) ∧ + IsSemiconvexSubgradientOn (fun q=>φ (v (χ.symm q))) (Metric.ball (χ (J.Y (J.z i))) r) K + (χ (J.Y z)) ((InnerProductSpace.toDual ℝ (Model n)).symm + (coordinatePhaseFlow a (1-t,z,fderiv ℝ G z)).2) := by + filter_upwards [J.openRegion.mem_nhds (J.sampleInRegion i), + (isOpen_extChartAt_target a).mem_nhds hi, + hY.continuousAt.preimage_mem_nhds (Metric.ball_mem_nhds _ hr)] with z hz hzt hball + have H:=hmtw.modified_phase_subgradient (s := Metric.ball (χ (J.Y (J.z i))) r) hu hv hdual hφ.continuous + ((hφ.differentiable (by simp)).differentiableAt.hasDerivAt (x := v (J.Y z))) + (hslope _).1 (hslope _).2 (sub_pos.mpr ht1) (by linarith : 1-t<1) + (((J.actual z hz).2.2.1 (J.Y z)).mpr rfl) (J.actual z hz).1 (χ.map_target hzt) + (by rw [χ.right_inv hzt]; exact J.centerDifferentiable z hz) hball hsem + simpa only [χ, G, chartCenterEnvelope, (extChartAt 𝓘(ℝ,Model n) a).right_inv hzt] using H + exact semiconvex_phase_graph_derivative hA hexp hr K hY + ((J.samples i).2.2.2.2.2.2.2.2.1.hasFDerivAt) hflow.hasFDerivAt + (hsub.mono (fun _ h=>h.1)) (hsub.mono (fun _ h=>h.2)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhaseGradient.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhaseGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..f64e13d71aaf22a4d3e23ee92b7baf5b560f4c3c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenPhaseGradient.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.JensenAt +import OAI.Analysis.BiholderTransport.Regularity.ModifiedPhase + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.jensen_phase_gradient (hmtw:WeakMTW (n:=n) (M:=M)) + {u v w:M → ℝ} (hu:Continuous u) {L:ℝ≥0} (hv:LipschitzWith L v) + (hdual:IsCostDualPair u v) {φ:ℝ → ℝ} (hφ:ContDiff ℝ ∞ φ) + (hslope:∀y:M,0φ (v y)) t a c N) (i:ℕ) + (hi:J.z i∈(extChartAt 𝓘(ℝ,Model n) a).target) + {p:Model n} {A:Model n →L[ℝ] Model n} {r K:ℝ} (hr:0φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a (J.Y (J.z i))+h)))) p A) + (hsem:ConvexOn ℝ (Metric.ball (extChartAt 𝓘(ℝ,Model n) a (J.Y (J.z i))) r) + (fun q=>φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm q))+K/2*‖q‖^2)) : + (coordinatePhaseFlow a (1-t,J.z i,fderiv ℝ + (chartCenterEnvelope (fun y=>φ (v y)) t a) (J.z i))).2=innerSL ℝ p := by + let χ:=extChartAt 𝓘(ℝ,Model n) a + have H:=hmtw.modified_phase_subgradient + (s:=Metric.ball (χ (J.Y (J.z i))) r) hu hv hdual hφ.continuous + ((hφ.differentiable (by simp)).differentiableAt.hasDerivAt (x:=v (J.Y (J.z i)))) + (hslope _).1 (hslope _).2 (sub_pos.mpr ht1) (by linarith : 1-t<1) + (((J.actual (J.z i) (J.sampleInRegion i)).2.2.1 (J.Y (J.z i))).mpr rfl) + (J.samples i).1 (χ.map_target hi) + (by rw [χ.right_inv hi]; exact J.centerDifferentiable _ (J.sampleInRegion i)) + (Metric.mem_ball_self hr) hsem + simp only [(extChartAt 𝓘(ℝ,Model n) a).right_inv hi] at H + have HH:=semiconvex_subgradient_eq_at_expansion hA hexp hr K H.2 + apply (InnerProductSpace.toDual ℝ (Model n)).symm.injective + change _=(InnerProductSpace.toDual ℝ (Model n)).symm ((InnerProductSpace.toDual ℝ (Model n)) p) + rw [(InnerProductSpace.toDual ℝ (Model n)).symm_apply_apply] + exact HH + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma phase_gradient_tendsto {a:M} {t:ℕ → ℝ} {z:ℕ → Model n} + {g:ℕ → Model n →L[ℝ] ℝ} {g0:Model n →L[ℝ] ℝ} {p:ℕ → Model n} + (ht:Tendsto t atTop (𝓝 1)) + (hz:Tendsto z atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hg:Tendsto g atTop (𝓝 g0)) + (hp:∀ᶠ k in atTop,(coordinatePhaseFlow a (1-t k,z k,g k)).2=innerSL ℝ (p k)) : + Tendsto (fun k=>innerSL ℝ (p k)) atTop (𝓝 g0) := by + have hτ:Tendsto (fun k=>1-t k) atTop (𝓝 (0:ℝ)):=by + simpa only [sub_self] using (tendsto_const_nhds.sub ht : + Tendsto (fun k=>(1:ℝ)-t k) atTop (𝓝 (1-1))) + have H:=((coordinatePhaseFlow_contDiffAt (q:=(extChartAt 𝓘(ℝ,Model n) a a,g0)) + (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a)).continuousAt.tendsto).comp + (hτ.prodMk_nhds (hz.prodMk_nhds hg)) + have HH:=H.snd_nhds + rw [coordinatePhaseFlow_zero (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a)] at HH + exact HH.congr' hp +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/JensenUndoShort.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenUndoShort.lean new file mode 100644 index 0000000000000000000000000000000000000000..07ee26ae30d567cbf7c7ae9557ffa0309737f813 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/JensenUndoShort.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.JensenPhase +import OAI.Analysis.BiholderTransport.Calculus.PhaseJet + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.jensen_undo_short (hmtw:WeakMTW (n:=n) (M:=M)) + {u v:M → ℝ} (hu:Continuous u) {L:ℝ≥0} (hv:LipschitzWith L v) + (hdual:IsCostDualPair u v) {φ:ℕ → ℝ → ℝ} (hφ:∀k,ContDiff ℝ ∞ (φ k)) + (hslope:∀k,∀y:M,0φ k (v y)) (t k) a (c k) N) + (i:ℕ → ℕ) (hti:Tendsto t atTop (𝓝 1)) + {g:Model n →L[ℝ] ℝ} {H:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hz:Tendsto (fun k=>(J k).z (i k)) atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hg:Tendsto (fun k=>fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a) + ((J k).z (i k))) atTop (𝓝 g)) + (hH:Tendsto (fun k=>fderiv ℝ (fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a)) + ((J k).z (i k))) atTop (𝓝 H)) + (hexp:∀ᶠ k in atTop,∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>v ((extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a ((J k).Y ((J k).z (i k)))+h))) p A) + (hsem:∀ᶠ k in atTop,∃r>0,∃K:ℝ, + ConvexOn ℝ (Metric.ball (extChartAt 𝓘(ℝ,Model n) a ((J k).Y ((J k).z (i k)))) r) + (fun q=>φ k (v ((extChartAt 𝓘(ℝ,Model n) a).symm q))+K/2*‖q‖^2)) : + ∃p:ℕ → Model n,∃A:ℕ → Model n →L[ℝ] Model n, + (∀ᶠ k in atTop,(∀d e,inner ℝ (A k d) e=inner ℝ d (A k e)) ∧ + HasQuadraticExpansion (fun h=>φ k (v ((extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a ((J k).Y ((J k).z (i k)))+h)))) (p k) (A k)) ∧ + Tendsto (fun k=>(innerSL ℝ).comp (A k)) atTop (𝓝 H) ∧ + Tendsto (fun k=>fderiv ℝ (fun z=>extChartAt 𝓘(ℝ,Model n) a ((J k).Y z)) + ((J k).z (i k))) atTop (𝓝 1) := by + classical + let χ:=extChartAt 𝓘(ℝ,Model n) a + let P:=fun k (p:Model n) (A:Model n →L[ℝ] Model n)=> + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>φ k (v (χ.symm (χ ((J k).Y ((J k).z (i k)))+h)))) p A + have hP:∀ᶠ k in atTop,∃p A,P k p A := by + filter_upwards [hexp] with k hk + obtain ⟨p,A,hs,hA⟩:=hk + exact quadratic_expansion_scalar_exists hA ((hφ k).contDiffAt.of_le (WithTop.coe_le_coe.mpr le_top : (2:WithTop ℕ∞)≤∞)) + have hchoice:∀k,∃p A,(∃p A,P k p A) → P k p A := by + intro k + by_cases hk:∃p A,P k p A + · obtain ⟨p,A,h⟩:=hk + exact ⟨p,A,fun _=>h⟩ + · exact ⟨0,0,fun h=>False.elim (hk h)⟩ + choose p A hPA using hchoice + have hPA':∀ᶠ k in atTop,P k (p k) (A k):=hP.mono (fun k hk=>hPA k hk) + have hτ:Tendsto (fun k=>1-t k) atTop (𝓝 (0:ℝ)):=by + simpa only [sub_self] using (tendsto_const_nhds.sub hti : Tendsto (fun k=>(1:ℝ)-t k) atTop (𝓝 (1-1))) + have hq:Tendsto (fun k=>((J k).z (i k),fderiv ℝ + (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a) ((J k).z (i k)))) + atTop (𝓝 (χ a,g)):=hz.prodMk_nhds hg + have hflow:∀ᶠ k in atTop,DifferentiableAt ℝ + (fun q:Phase n=>coordinatePhaseFlow a (1-t k,q)) + ((J k).z (i k),fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a) ((J k).z (i k))) := by + have HH:=((coordinatePhaseFlow_contDiffAt (q := (χ a,g)) + (mem_extChartAt_target (I := 𝓘(ℝ,Model n)) a)).of_le + (by norm_num : (1:WithTop ℕ∞)≤∞)).eventually (by norm_num) + filter_upwards [(hτ.prodMk_nhds hq).eventually HH] with k hk + exact (hk.differentiableAt (by norm_num)).comp _ + ((contDiffAt_const.prodMk contDiffAt_id : ContDiffAt ℝ 1 (fun q:Phase n=>(1-t k,q)) _).differentiableAt (by norm_num)) + have hi:∀ᶠ k in atTop,(J k).z (i k)∈χ.target:= + hz.eventually ((isOpen_extChartAt_target a).mem_nhds (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a)) + have hid:∀ᶠ k in atTop, + (fderiv ℝ (fun q:Phase n=>coordinatePhaseFlow a (1-t k,q)) + ((J k).z (i k),fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a) ((J k).z (i k)))).comp + ((ContinuousLinearMap.id ℝ (Model n)).prod + (fderiv ℝ (fderiv ℝ (chartCenterEnvelope (fun y=>φ k (v y)) (t k) a)) ((J k).z (i k))))= + (fderiv ℝ (fun z=>χ ((J k).Y z)) ((J k).z (i k))).prod + (((innerSL ℝ).comp (A k)).comp (fderiv ℝ (fun z=>χ ((J k).Y z)) ((J k).z (i k)))) := by + filter_upwards [hi,hPA',hsem,hflow] with k hik hk hs hf + obtain ⟨r,hr,K,hK⟩:=hs + exact hmtw.jensen_phase_graph_identity hu hv hdual (hφ k) (hslope k) (ht k) (ht1 k) + (J k) (i k) hik hr hk.1 hk.2 hK hf + have HH:=coordinate_phase_jet_limit (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a) hτ hq hH hid + exact ⟨p,A,hPA',HH.2,HH.1⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensen.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensen.lean new file mode 100644 index 0000000000000000000000000000000000000000..f63daa51686fb45d495bcec9c9f58bfefc062cef --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensen.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumRow +import OAI.Analysis.BiholderTransport.Convexity.JensenAtFirstLimit + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma JensenSamplesAt.near_differentiable {v g : M → ℝ} {t : ℝ} {a c : M} + {N : Set (Model n)} (J : JensenSamplesAt v g t a c N) : + ∀ᶠ z in 𝓝 (extChartAt 𝓘(ℝ,Model n) a c), + DifferentiableAt ℝ (chartOuterEnvelope v t a) z ∧ + DifferentiableAt ℝ (chartCenterEnvelope g t a) z := by + filter_upwards [J.openRegion.mem_nhds J.centerInRegion] with z hz + exact ⟨J.outerDifferentiable z hz,J.centerDifferentiable z hz⟩ + +lemma MaximumRow.jensen_first_limit {v : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {z a c : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + (hmtw : WeakMTW (n := n) (M := M)) (hv : Continuous v) (ho : Continuous Bo) + (ht : 0e.symm ((extChartAt 𝓘(ℝ,Model n) c).symm (J.z k))) R.q) := by + have hpole : hopfPole (n := n) t (cTransform (modifiedDatum v α D b Bo)) z=R.q.1.1 := by + rw [←hmtw.graphHomeomorph_inverse_pole (continuous_modifiedDatum hv α D b ho) ht ht1 z, + R.graph_inverse hmtw hv ho ht ht1] + have H := hmtw.jensen_at_first_limit_in_chart (continuous_modifiedDatum hv α D b ho) ht ht1 J hc + (J.outerGradientContinuous.continuousAt (J.openRegion.mem_nhds J.centerInRegion)) + (J.centerGradientContinuous.continuousAt (J.openRegion.mem_nhds J.centerInRegion)) + J.near_differentiable (hpole ▸ ha) + dsimp only at H ⊢ + rwa [R.graph_inverse hmtw hv ho ht ht1] at H + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma MaximumRow.jensen_center_limit {v : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {z c : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + {N : Set (Model n)} + (J : JensenSamplesAt (modifiedDatum v α D b Bo) (modifiedDatum v α D b Bc) t c z N) + (hc : z∈(extChartAt 𝓘(ℝ,Model n) c).source) : + Tendsto (fun k=>extChartAt 𝓘(ℝ,Model n) c (J.Y (J.z k))) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c (riemannianExp R.q.1.1 R.q.1.2))) := by + let χ := extChartAt 𝓘(ℝ,Model n) c + have hdata := J.actual (χ z) J.centerInRegion + have hval := (hdata.2.2.1 (J.Y (χ z))).mpr rfl + change hopfLax (1-t) (modifiedDatum v α D b Bc) (χ.symm (χ z))=_ at hval + rw [χ.left_inv hc] at hval + have hy : J.Y (χ z)=riemannianExp R.q.1.1 R.q.1.2 := (R.center _).mp hval + have H := (J.selectorContinuous.continuousAt (J.openRegion.mem_nhds J.centerInRegion)).tendsto.comp J.points + rwa [hy] at H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensenFamily.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensenFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..df3ac6a0840cf59cfdac9892d09c96b49d4e1ea9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/MaximumJensenFamily.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumCompact +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensen +import OAI.Analysis.BiholderTransport.Convexity.FamilyJensen + +namespace OAI + + +noncomputable section +open Set Filter Metric Manifold Bundle MeasureTheory +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure MaximumJensenFamily {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + (hmtw : WeakMTW (n := n) (M := M)) (hv : Continuous v) (ho : Continuous Bo) + (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) (a c : M) (N : Set (Model n)) where + poleSource : ∀ k,(F.row k).q.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source + endpointSource : ∀ k,F.z k∈(extChartAt 𝓘(ℝ,Model n) c).source + sample : ∀ k,JensenSamplesAt (modifiedDatum v α D (F.b k) Bo) + (modifiedDatum v α D (F.b k) Bc) (F.t k) c (F.z k) N + first : ∀ k, + let e := hmtw.graphHomeomorph (continuous_modifiedDatum hv α D (F.b k) ho) + (F.prefixTime k).1 (F.prefixTime k).2 + ChartFixedPrefixLimit a (modifiedDatum v α D (F.b k) Bo) + (hopfLax (1-F.t k) (modifiedDatum v α D (F.b k) Bc)) (F.t k) + (fun j=>e.symm ((extChartAt 𝓘(ℝ,Model n) c).symm ((sample k).z j))) (F.row k).q + +lemma MaximumFamily.eventually_jensen_first (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} (ho : Continuous Bo) + (hΦ : ContDiff ℝ ∞ (fun p:ℝ×ℝ=>p.2+p.1*Bc ((p.2-α)/D))) + (hmono : ∀ b∈Icc bminus bplus,Monotone (fun s=>s+b*Bc ((s-α)/D))) {Lφ : ℝ≥0} + (hLip : ∀ b∈Icc bminus bplus,LipschitzWith Lφ (fun s=>s+b*Bc ((s-α)/D))) + {A B : ℝ} (hbound : ∀ y,v y∈Icc A B) + (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) + {Q:TangentBundle 𝓘(ℝ,Model n) M} + (hQ : Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 Q)) {N:Set (Model n)} (hN : volume N=0) : + ∃ K:ℕ,Nonempty (MaximumJensenFamily hmtw hv ho (F.comp (fun k=>k+K) (tendsto_add_atTop_nat K)) + Q.1 (riemannianExp Q.1 Q.2) N) := by + let c := riemannianExp Q.1 Q.2 + let χ := extChartAt 𝓘(ℝ,Model n) c + obtain ⟨R,hR,δ,hδ,H⟩ := hmtw.family_jensen_samples hΦ isCompact_Icc hmono hLip A B c + have hz := F.limit_coordinates hQ |>.2.2.1 + have hχ : Tendsto (fun k=>χ (F.z k)) atTop (𝓝 (χ c)) := + ((continuousOn_extChartAt _).continuousAt ((isOpen_extChartAt_source _).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) c))).tendsto.comp hz + have hpole := (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto Q |>.comp hQ + have htime : Tendsto (fun k=>1-F.t k) atTop (𝓝 (0:ℝ)) := by + simpa only [sub_self] using (tendsto_const_nhds.sub F.time : + Tendsto (fun k=>(1:ℝ)-F.t k) atTop (𝓝 (1-1))) + have hevent : ∀ᶠ k in atTop,(F.row k).q.1.1∈(extChartAt 𝓘(ℝ,Model n) Q.1).source ∧ + F.z k∈χ.source ∧ χ (F.z k)∈ball (χ c) R ∧ 1-F.t k<1/2 ∧ 1-F.t k<δ := by + filter_upwards [hpole.eventually ((isOpen_extChartAt_source _).mem_nhds (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) Q.1)), + hz.eventually ((isOpen_extChartAt_source _).mem_nhds (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) c)), + hχ.eventually (ball_mem_nhds _ hR),htime.eventually (gt_mem_nhds (by norm_num : (0:ℝ)<1/2)), + htime.eventually (gt_mem_nhds hδ)] with k ha hc hb ht hd + exact ⟨ha,hc,hb,ht,hd⟩ + obtain ⟨K,hK⟩ := eventually_atTop.mp hevent + let F1 := F.comp (fun k=>k+K) (tendsto_add_atTop_nat K) + have hk (k:ℕ) := hK (k+K) (Nat.le_add_left _ _) + have HJ : ∀ k,Nonempty (JensenSamplesAt (modifiedDatum v α D (F1.b k) Bo) + (modifiedDatum v α D (F1.b k) Bc) (F1.t k) c (F1.z k) N) := by + intro k + have HB : ∀ y,cTransform u y∈Icc A B := by rwa [←hdual.2] + have Hψ : Continuous (fun s:ℝ=>s+F1.b k*Bo ((s-α)/D)) := + continuous_id.add (continuous_const.mul (ho.comp ((continuous_id.sub continuous_const).div_const D))) + have HH := H (F1.b k) (Ioo_subset_Icc_self (F1.parameter k)) u hu HB + (fun s=>s+F1.b k*Bo ((s-α)/D)) Hψ (1-F1.t k) (by linarith [(F1.prefixTime k).2]) + (hk k).2.2.2.1 (hk k).2.2.2.2 (F1.z k) (hk k).2.2.1 + have hback : 1-(1-F1.t k)=F1.t k := by ring + rw [hback,←hdual.2] at HH + apply HH ?_ N hN + have HM : ∀ w:Model n, + chartOuterEnvelope (modifiedDatum v α D (F1.b k) Bo) (F1.t k) c w+ + chartCenterEnvelope (modifiedDatum v α D (F1.b k) Bc) (F1.t k) c w≤ + chartOuterEnvelope (modifiedDatum v α D (F1.b k) Bo) (F1.t k) c (χ (F1.z k))+ + chartCenterEnvelope (modifiedDatum v α D (F1.b k) Bc) (F1.t k) c (χ (F1.z k)) := by + intro w + have HX := F1.maximum k (F1.b k,χ.symm w) (Ioo_subset_Icc_self (F1.parameter k)) + dsimp only [regularizedComparison] at HX + dsimp only [chartOuterEnvelope,chartCenterEnvelope] + rw [show (extChartAt 𝓘(ℝ,Model n) c).symm (χ (F1.z k))=F1.z k from + χ.left_inv (hk k).2.1] + linarith only [HX] + exact Eventually.of_forall HM + let J := fun k=>Classical.choice (HJ k) + let P := fun k=>Classical.choice ((F1.row k).jensen_first_limit hmtw hv ho + (F1.prefixTime k).1 (F1.prefixTime k).2 (J k) (hk k).2.1 (hk k).1) + exact ⟨K,⟨⟨fun k=>(hk k).1,fun k=>(hk k).2.1,J,P⟩⟩⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ModifiedEnvelopeRegularity.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ModifiedEnvelopeRegularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..99b2ef7921e6a543e4f1925d6418ac08a9e8316a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ModifiedEnvelopeRegularity.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeTaylor +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section + +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +lemma differentiableAt_of_const_mul {f : E → ℝ} {t : ℝ} (ht : t≠0) {x:E} + (hd : DifferentiableAt ℝ (fun z => t*f z) x) : + HasFDerivAt f (t⁻¹ • fderiv ℝ (fun z => t*f z) x) x := by + have H := hd.hasFDerivAt.const_mul t⁻¹ + simpa only [←mul_assoc,inv_mul_cancel₀ ht,one_mul] using H + +lemma C11_const_mul_cancel {f : E → ℝ} {S : Set E} {t : ℝ} {K : ℝ≥0} + (ht : t≠0) (hd : ∀ x∈S,DifferentiableAt ℝ (fun z => t*f z) x) + (hLip : LipschitzOnWith K (fderiv ℝ (fun z => t*f z)) S) : + (∀ x∈S,DifferentiableAt ℝ f x) ∧ + LipschitzOnWith (‖t⁻¹‖₊*K) (fderiv ℝ f) S := by + have H (x:E) (hx:x∈S) := differentiableAt_of_const_mul ht (hd x hx) + refine ⟨fun x hx => (H x hx).differentiableAt,?_⟩ + apply LipschitzOnWith.of_dist_le_mul + intro x hx y hy + rw [(H x hx).fderiv,(H y hy).fderiv,dist_eq_norm,←smul_sub,norm_smul] + have HH := mul_le_mul_of_nonneg_left (hLip.dist_le_mul x hx y hy) (norm_nonneg t⁻¹) + simpa only [dist_eq_norm,NNReal.coe_mul,coe_nnnorm,mul_assoc] using HH + +end + +open Set Filter MeasureTheory Metric +open scoped Topology NNReal + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma HasSecondTaylor.hasQuadraticExpansion {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) : + HasQuadraticExpansion f ((InnerProductSpace.toDual ℝ E).symm l) (bilinearOperator B) := by + intro ε hε + obtain ⟨r,hr,hball⟩ := Metric.eventually_nhds_iff.mp (hf.eventually hε) + refine ⟨r,hr,?_⟩ + intro h hh + have H := hball (by simpa only [mem_ball,dist_zero_right] using hh) + simpa only [quadraticTaylor,bilinearOperator_inner,InnerProductSpace.toDual_symm_apply, + sub_add_eq_sub_sub] using H + +variable [MeasurableSpace E] [BorelSpace E] (μ : Measure E) [μ.IsAddHaarMeasure] + +lemma ae_secondTaylor_of_C11 {f : E → ℝ} {S : Set E} (hS : IsOpen S) + (hd : ∀ x∈S,DifferentiableAt ℝ f x) {K : ℝ≥0} + (hK : LipschitzOnWith K (fderiv ℝ f) S) : + ∀ᵐ x ∂μ,x∈S → DifferentiableAt ℝ (fderiv ℝ f) x ∧ + HasSecondTaylor (fun h => f (x+h)) (fderiv ℝ f x) + (fderiv ℝ (fderiv ℝ f) x) := by + filter_upwards [hK.ae_differentiableWithinAt_of_mem (μ := μ)] with x hx hxS + have H := (hx hxS).differentiableAt (hS.mem_nhds hxS) + refine ⟨H,hasSecondTaylor_of_second_derivative ?_ H.hasFDerivAt⟩ + filter_upwards [hS.mem_nhds hxS] with y hy + exact (hd y hy).hasFDerivAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/MovingCenterSemibound.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/MovingCenterSemibound.lean new file mode 100644 index 0000000000000000000000000000000000000000..3004d82f7e224657c791e31a19d386dbaebb6139 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/MovingCenterSemibound.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateMatrices +import OAI.Analysis.BiholderTransport.Regularity.JointMovingPrefix +import OAI.Analysis.BiholderTransport.Convexity.ShortPullbackSemibound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MovingCenterSemibound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +omit [Nonempty M] in +lemma moving_energy_hessian_tendsto {a : M} {q : Model n} + (hq : (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) {bj qj : ℕ → Model n} {tj : ℕ → ℝ} + (hb : Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq : Tendsto qj atTop (𝓝 q)) (ht : Tendsto tj atTop (𝓝 1)) + : Tendsto (fun i=>fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i)) atTop + (𝓝 (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 (extChartAt 𝓘(ℝ,Model n) a a))) q)) := by + let b := extChartAt 𝓘(ℝ,Model n) a a + have hb0 : b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hp0 : (1:ℝ) • chartFiberInverse a b q∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm b) := by + rw [chartFiberInverse_at_center] + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] + change (1:ℝ) • (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a + rw [one_smul] + exact hq + let f : (ℝ×Model n) → Model n → ℝ := fun z r=>movingPrefixEnergy a z.1 z.2 r + have henergy : ContDiffAt ℝ ∞ (Function.uncurry f) ((1,b),q) := + joint_movingPrefixEnergy_contDiffAt hb0 one_ne_zero hp0 + have hd : ContDiffAt ℝ ∞ (fun z:(ℝ×Model n)×Model n=>fderiv ℝ (fderiv ℝ (f z.1)) z.2) ((1,b),q) := + ContDiffAt.partial_snd_fderiv_two (f := f) (q := (1,b)) (h := q) henergy + have harg : Tendsto (fun i=>((tj i,bj i),qj i)) atTop (𝓝 ((1,b),q)) := + (ht.prodMk_nhds hb).prodMk_nhds hqq + have H := hd.continuousAt.tendsto.comp harg + exact H + +omit [Nonempty M] in +lemma moving_energy_sequential_lower {a : M} {q : Model n} + (hq : (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) {bj qj : ℕ → Model n} {tj : ℕ → ℝ} + (hb : Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq : Tendsto qj atTop (𝓝 q)) (ht : Tendsto tj atTop (𝓝 1)) + {ε : ℝ} (hε : 0<ε) : + ∀ᶠ i in atTop,∀ d : Model n, + inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from d) d-ε*‖d‖^2≤ + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i) d d := by + let b := extChartAt 𝓘(ℝ,Model n) a a + have hElim := moving_energy_hessian_tendsto hq hb hqq ht + have hEsmall := ((Metric.tendsto_nhds (α := Model n →L[ℝ] Model n →L[ℝ] ℝ)).mp hElim) ε hε + filter_upwards [hEsmall] with i hei + intro d + have HE := (abs_le.mp (bilinear_diag_sub_bound + (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i)) + (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 b)) q) d)).1 + rw [movingPrefixEnergy_hessian_at_center hq] at HE + have hei' : ‖(fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i))- + (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 b)) q)‖<ε := by + exact (dist_eq_norm (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i)) + (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 b)) q)).symm ▸ hei + have HM := mul_le_mul_of_nonneg_right hei'.le (sq_nonneg ‖d‖) + linarith only [HE,HM] + +omit [Nonempty M] [CompleteSpace P] in +lemma moving_chart_support_jet {a c : M} {ψ : P×Model n → ℝ} {p : P} {x q : Model n} + (hψ : ContDiffAt ℝ ∞ ψ (p,x)) + (he : extChartAt 𝓘(ℝ,Model n) c (riemannianExp a q)=x) + (hc : riemannianExp a q∈(extChartAt 𝓘(ℝ,Model n) c).source) (d : Model n) : + let g := movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a) + secondJetPullback (fderiv ℝ (fun w=>ψ (p,w)) x) + (fderiv ℝ (fderiv ℝ (fun w=>ψ (p,w))) x) + (fderiv ℝ g q) (fderiv ℝ (fderiv ℝ g) q) d d= + fderiv ℝ (fderiv ℝ (fun r=>ψ (p,extChartAt 𝓘(ℝ,Model n) c (riemannianExp a r)))) q d d := by + let b := extChartAt 𝓘(ℝ,Model n) a a + let g := movingPrefixChart a c 1 b + have hb0 : b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hgc : movingPrefix a 1 b q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + simpa only [b,movingPrefix_at_center,one_smul] using hc + have hg : ContDiffAt ℝ ∞ (fun z:(ℝ×Model n)×Model n=>movingPrefixChart a c z.1.1 z.1.2 z.2) ((1,b),q) := + joint_movingPrefixChart_contDiffAt hb0 hgc + have hgb : ContDiffAt ℝ 2 g q := + (hg.comp q (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hge : g q=x := by + simpa only [g,movingPrefixChart,b,movingPrefix_at_center,one_smul] using he + have hψb : ContDiffAt ℝ 2 (fun w=>ψ (p,w)) (g q) := by + rw [hge] + exact (hψ.comp x (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + change secondJetPullback _ _ (fderiv ℝ g q) (fderiv ℝ (fderiv ℝ g) q) d d=_ + rw [←hge,secondJetPullback_apply,←second_fderiv_comp_with_acceleration hψb hgb] + have hgfun : g=(fun r : Model n=>extChartAt 𝓘(ℝ,Model n) c (riemannianExp a r)) := by + funext r + simp only [g,movingPrefixChart,b,movingPrefix_at_center,one_smul] + rw [hgfun] + rfl + +lemma moving_center_sequential_semibound {a c : M} {ψ : P×Model n → ℝ} + {p : P} {x q : Model n} (L : ℝ≥0) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) c).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) + (hq : (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) (he : extChartAt 𝓘(ℝ,Model n) c (riemannianExp a q)=x) + (hc : riemannianExp a q∈(extChartAt 𝓘(ℝ,Model n) c).source) + {pj : ℕ → P} {xj bj qj : ℕ → Model n} {tj τj : ℕ → ℝ} {f : ℕ → M → ℝ} + (hp : Tendsto pj atTop (𝓝 p)) (hxx : Tendsto xj atTop (𝓝 x)) + (hb : Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq : Tendsto qj atTop (𝓝 q)) (ht : Tendsto tj atTop (𝓝 1)) + (hτ : Tendsto τj atTop (𝓝 0)) (hτpos : ∀ᶠ i in atTop,0<τj i) + (hlip : ∀ᶠ i in atTop,LipschitzWith L (f i)) + (hbelow : ∀ᶠ i in atTop,∀ w,ψ (pj i,w)≤f i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (htouch : ∀ᶠ i in atTop,f i ((extChartAt 𝓘(ℝ,Model n) c).symm (xj i))=ψ (pj i,xj i)) + (hz : ∀ᶠ i in atTop,movingPrefixChart a c (tj i) (bj i) (qj i)= + parametricShortForward c ψ ((pj i,τj i),xj i)) + (hjet : ∀ᶠ i in atTop, + (∀ᶠ z in 𝓝 (movingPrefixChart a c (tj i) (bj i) (qj i)),DifferentiableAt ℝ + (fun z=>hopfLax (τj i) (f i) ((extChartAt 𝓘(ℝ,Model n) c).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (fun z=>hopfLax (τj i) (f i) ((extChartAt 𝓘(ℝ,Model n) c).symm z))) + (movingPrefixChart a c (tj i) (bj i) (qj i))) + {ε : ℝ} (hε : 0<ε) : + ∀ᶠ i in atTop,∀ d : Model n, + inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from d) d+ + fderiv ℝ (fderiv ℝ (fun r=>ψ (p,extChartAt 𝓘(ℝ,Model n) c (riemannianExp a r)))) q d d- + ε*‖d‖^2 ≤ coordinateCenterMatrix a (tj i) (hopfLax (τj i) (f i)) (bj i) (qj i) d d := by + let b := extChartAt 𝓘(ℝ,Model n) a a + let g := fun (t:ℝ×Model n) (r:Model n)=>movingPrefixChart a c t.1 t.2 r + have hb0 : b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hgc : movingPrefix a 1 b q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + simpa only [b,movingPrefix_at_center,one_smul] using hc + have hg : ContDiffAt ℝ ∞ (Function.uncurry g) ((1,b),q) := + joint_movingPrefixChart_contDiffAt hb0 hgc + have harg := (ht.prodMk_nhds hb).prodMk_nhds hqq + have hm := (ContDiffAt.partial_snd_fderiv hg).continuousAt.tendsto.comp harg + have hr := (ContDiffAt.partial_snd_fderiv_two hg).continuousAt.tendsto.comp harg + have hgj : ∀ᶠ i in atTop,ContDiffAt ℝ 2 (g (tj i,bj i)) (qj i) := by + have hg2 := hg.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + filter_upwards [harg.eventually (hg2.eventually (by norm_num))] with i hi + exact hi.comp (qj i) (contDiffAt_const.prodMk contDiffAt_id) + have H := parametric_short_pullback_semibound L hx hψ hp hxx hτ hτpos hlip hbelow htouch + hz ((hjet.and hgj).mono (fun i hi=>⟨hi.1.1,hi.1.2,hi.2⟩)) hm hr (half_pos hε) + have HE := moving_energy_sequential_lower hq hb hqq ht (half_pos hε) + have hpull := moving_chart_support_jet hψ he hc + have hbjt := hb.eventually ((isOpen_extChartAt_target a).mem_nhds hb0) + have hcjt : ∀ᶠ i in atTop,movingPrefix a (tj i) (bj i) (qj i)∈(extChartAt 𝓘(ℝ,Model n) c).source := + ((joint_movingPrefix_contMDiffAt hb0).continuousAt.tendsto.comp harg).eventually + ((isOpen_extChartAt_source _).mem_nhds hgc) + filter_upwards [H,HE,hbjt,hcjt] with i hi hei hbi hci + intro d + have HD := hi d + rw [hpull d] at HD + have HD2 := hei d + rw [coordinateCenterMatrix_chart hbi hci,add_apply,add_apply] + linarith only [HD,HD2] + +end MovingCenterSemibound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricSemiconvex.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricSemiconvex.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ddd8d96274efb29e75bf697c3905c4f951d9b44 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricSemiconvex.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Contact.Inner + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {E P : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma scalar_family_uniform_semiconvex {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) + {Kp : Set P} (hKp : IsCompact Kp) (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) + (a b K : ℝ) (hK : 0≤K) (L : ℝ≥0) : + ∃ C>0,∀ p∈Kp,∀ S : Set E,Convex ℝ S → ∀ f:E → ℝ, + LipschitzOnWith L f S → (∀ x∈S,f x∈Icc a b) → + (∀ x∈S,∃ l:E →L[ℝ] ℝ,∀ y∈S,f x+l (y-x)-K*‖y-x‖^2≤f y) → + ConvexOn ℝ S (fun x=>Φ (p,f x)+C/2*‖x‖^2) := by + let dd := fun q:P×ℝ=>fderiv ℝ (fun s=>Φ (q.1,s)) q.2 + let hh := fun q:P×ℝ=>fderiv ℝ (fderiv ℝ (fun s=>Φ (q.1,s))) q.2 + have hdd : Continuous dd := continuous_iff_continuousAt.mpr (fun q=> + (ContDiffAt.partial_snd_fderiv (f := fun p s=>Φ (p,s)) (hΦ.contDiffAt (x := q))).continuousAt) + have hhh : Continuous hh := continuous_iff_continuousAt.mpr (fun q=> + (ContDiffAt.partial_snd_fderiv_two (f := fun p s=>Φ (p,s)) (hΦ.contDiffAt (x := q))).continuousAt) + obtain ⟨A0,hA0⟩ := (hKp.prod (isCompact_Icc (a := a) (b := b))).exists_bound_of_continuousOn (f := dd) hdd.continuousOn + obtain ⟨B0,hB0⟩ := (hKp.prod (isCompact_Icc (a := a) (b := b))).exists_bound_of_continuousOn (f := hh) hhh.continuousOn + let A := max A0 0 + let B := max B0 0 + have hA : 0≤A := le_max_right _ _ + have hB : 0≤B := le_max_right _ _ + let C := 2*(A*K+B*(L:ℝ)^2+1) + refine ⟨C,by dsimp [C]; positivity,?_⟩ + intro p hp S hS f hlip hrange hs + let φ := fun s=>Φ (p,s) + have hφ : ContDiff ℝ 2 φ := (hΦ.comp (contDiff_const.prodMk contDiff_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + apply convexOn_of_quadratic_lower_supports hS (C/2) + intro x hx + obtain ⟨l,hl⟩ := hs x hx + refine ⟨deriv φ (f x) • l,?_⟩ + intro y hy + have H := first_order_remainder_le_of_hessian_bound (convex_Icc a b) hB + (fun z hz=>hφ.contDiffAt) (fun z hz=>by exact (hB0 (p,z) ⟨hp,hz⟩).trans (le_max_left _ _)) + (hrange x hx) (hrange y hy) + rw [fderiv_eq_deriv_mul] at H + have Hlow := (abs_le.mp H).1 + have Hf := mul_le_mul_of_nonneg_left (hl y hy) ((hmono p hp).deriv_nonneg (x := f x)) + have Hlip := hlip.dist_le_mul y hy x hx + rw [dist_eq_norm,dist_eq_norm] at Hlip + have Hsq := sq_le_sq₀ (norm_nonneg (f y-f x)) (by positivity : 0≤(L:ℝ)*‖y-x‖) |>.mpr Hlip + have HB := mul_le_mul_of_nonneg_left Hsq hB + have HA : deriv φ (f x)≤A := by + have hh0 := hA0 (p,f x) ⟨hp,hrange x hx⟩ + have hh1 : |deriv φ (f x)|≤A0 := by + simpa only [dd,←norm_deriv_eq_norm_fderiv,Real.norm_eq_abs] using hh0 + exact (le_abs_self _).trans (hh1.trans (le_max_left _ _)) + have HK := mul_le_mul_of_nonneg_right HA (mul_nonneg hK (sq_nonneg ‖y-x‖)) + simp only [_root_.smul_apply,smul_eq_mul] + dsimp only [C] + nlinarith [sq_nonneg ‖y-x‖] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..29a5dbc8f0c98a126c3d6ce65acee882431354c9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerEnvelope.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.GeometricEnvelope + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle Asymptotics +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma scalar_normal_remainder {v : M → ℝ} {L : ℝ≥0} (hv : LipschitzWith L v) + {φ : ℝ → ℝ} {x : M} {l : ℝ} (hφ : HasDerivAt φ l (v x)) : + (fun h : TangentSpace 𝓘(ℝ,Model n) x => + φ (v (riemannianExp x h))-φ (v x)-l*(v (riemannianExp x h)-v x)) + =o[𝓝 0] (fun h => ‖h‖) := by + have ht : Tendsto (fun h : TangentSpace 𝓘(ℝ,Model n) x => v (riemannianExp x h)) + (𝓝 0) (𝓝 (v x)) := by + simpa only [Function.comp_def,riemannianExp_zero] using (hv.continuous.comp (continuous_riemannianExp (n := n) x)).continuousAt.tendsto (x := 0) + have hO : (fun h : TangentSpace 𝓘(ℝ,Model n) x => v (riemannianExp x h)-v x) + =O[𝓝 0] (fun h => ‖h‖) := by + apply IsBigO.of_bound (L:ℝ) + filter_upwards [] with h + have H := hv.dist_le_mul (riemannianExp x h) x + have H1 := mul_le_mul_of_nonneg_left (dist_riemannianExp_le x h) L.coe_nonneg + rw [dist_comm x] at H1 + simpa only [Real.dist_eq,Real.norm_eq_abs,abs_norm] using H.trans H1 + simpa only [Function.comp_def,smul_eq_mul,mul_comm] using + (hφ.isLittleO.comp_tendsto ht).trans_isBigO hO + +omit [Nonempty M] in +lemma scalar_normalSubdifferential_inv {v : M → ℝ} {L : ℝ≥0} + (hv : LipschitzWith L v) {φ : ℝ → ℝ} {x : M} {l : ℝ} + (hφ : HasDerivAt φ l (v x)) (hl : 0 φ (v y)) x) : + l⁻¹ • r∈normalSubdifferential v x := by + intro ε hε + have hres := scalar_normal_remainder (n := n) hv hφ + filter_upwards [hr (l*ε/2) (by positivity),hres.bound (by positivity : 0 φ (v a)+cost a (riemannianExp y (τ • r))/τ) y) : + l⁻¹ • r∈minimizingVectors y ∧ + contactGap v u y (riemannianExp y (l⁻¹ • r))=0 ∧ r∈injectivityDomain y := by + have hsub := scalar_normalSubdifferential_inv hv hφ hl + (local_min_divided_cost_subgradient hτ hr hmin) + have H := hmtw.subgradient_dual_contact hv.continuous hu ⟨hdual.2,hdual.1⟩ hsub + refine ⟨H.1,H.2,?_⟩ + have HI := contracted_minimizer_mem_injectivityDomain H.1 hl hl1 + simpa only [smul_smul,mul_inv_cancel₀ hl.ne',one_smul] using HI + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerJets.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..2e7dceb872c3257cb96a7c8a32998304993afd3f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ParametricShortLowerJets.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.HopfApproximation +import OAI.Analysis.BiholderTransport.Regularity.UniformShortMinima +import OAI.Analysis.BiholderTransport.Calculus.ShortPoleIdentities + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +lemma exists_parametric_short_lower_jets {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} (L : ℝ≥0) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ∃ r>0, ∃ (B : (P×ℝ)×Model n → Model n) (U : (P×ℝ)×Model n → ℝ), + ContDiffAt ℝ ∞ B ((p,0),x) ∧ ContDiffAt ℝ ∞ U ((p,0),x) ∧ B ((p,0),x)=x ∧ + (∀ᶠ q in 𝓝 ((p,0),x),parametricShortForward a ψ (q.1,B q)=q.2) ∧ + (∀ᶠ q in 𝓝 ((p,0),x),B (q.1,parametricShortForward a ψ q)=q.2) ∧ + (∀ᶠ q in 𝓝 ((p,0),x),0 fderiv ℝ (fun y => U (q.1,y)) q.2) + (𝓝 ((p,0),x)) (𝓝 (fderiv ℝ (fun y => ψ (p,y)) x)) ∧ + Tendsto (fun q : (P×ℝ)×Model n => fderiv ℝ (fderiv ℝ (fun y => U (q.1,y))) q.2) + (𝓝 ((p,0),x)) (𝓝 (fderiv ℝ (fderiv ℝ (fun y => ψ (p,y))) x)) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + obtain ⟨B,U,hB,hU,hBx,hBZ,hZB,hUE,hUH⟩ := geometric_parametric_short_family hx hψ + obtain ⟨r,hr,V,hV,hmin⟩ := exists_parametric_short_action_local_minima hx hψ + have hBmap : ContinuousAt (fun q : (P×ℝ)×Model n => (q.1,B q)) ((p,0),x) := + continuousAt_fst.prodMk hB.continuousAt + have hBreg := hBmap.eventually (show ∀ᶠ q in 𝓝 ((p,0),B ((p,0),x)), + q.2∈χ.target ∧ chartGradientVector a q.2 (q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2)∈ + injectivityDomain (χ.symm q.2) ∧ + coordinateBackward a (-1,q.2,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2)∈χ.source by + rw [hBx]; exact parametricShortForward_regular_near hx hψ) + have hPsib : ∀ᶠ q in 𝓝 ((p,(0:ℝ)),x), ContDiffAt ℝ 1 (fun y => ψ (q.1.1,y)) (B q) := by + have hc : ContinuousAt (fun q : (P×ℝ)×Model n => (q.1.1,B q)) ((p,0),x) := + continuousAt_fst.fst.prodMk hB.continuousAt + have H := hc.eventually (show ∀ᶠ v in 𝓝 (p,B ((p,0),x)),ContDiffAt ℝ 1 ψ v by + rw [hBx]; exact (hψ.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 1)).eventually (by simp)) + filter_upwards [H] with q hq + exact hq.comp (B q) (contDiffAt_const.prodMk contDiffAt_id) + have hBr : ∀ᶠ q in 𝓝 ((p,(0:ℝ)),x), B q∈Metric.closedBall x r := by + have H := hB.continuousAt.preimage_mem_nhds (show Metric.ball x r∈𝓝 (B ((p,0),x)) by + rw [hBx]; exact Metric.ball_mem_nhds x hr) + exact Filter.Eventually.mono H fun _ hy => Metric.ball_subset_closedBall hy + have hcx : χ.symm x∈χ.source := χ.map_target hx + have hcm : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ χ (χ.symm x) := + contMDiffAt_extChartAt' (by simpa only [χ,extChartAt_source] using hcx) + have hWM : χ.source ∩ χ ⁻¹' Metric.ball x r∈𝓝 (χ.symm x) := + Filter.inter_mem ((isOpen_extChartAt_source a).mem_nhds hcx) + (hcm.continuousAt.preimage_mem_nhds (by rw [χ.right_inv hx]; exact Metric.ball_mem_nhds x hr)) + have hi : ContinuousAt χ.symm x := continuousAt_extChartAt_symm'' hx + have hloc := (continuousAt_fst.snd.prodMk (hi.comp (x := ((p,(0:ℝ)),x)) continuousAt_snd)).eventually + (uniform_hopfLax_minimizers_eventually_in L hWM) + refine ⟨r,hr,B,U,hB,hU,hBx,hBZ,hZB,?_,short_family_first_jet_limit hx hU hZB hUE,hUH⟩ + filter_upwards [hBreg,hPsib,hBr,hloc,hBZ,hV] with q hreg hps hbr hlocq hz hq + intro ht f hf hs + have he : coordinateBackward a (-1,B q,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) (B q))=χ.symm q.2 := by + calc + _=χ.symm (χ (coordinateBackward a (-1,B q,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) (B q)))) := + (χ.left_inv hreg.2.2).symm + _=χ.symm q.2 := congrArg χ.symm hz + obtain ⟨ha,hd⟩ := shortForward_action (a := a) (ψ := fun y => ψ (q.1.1,y)) + (q := (q.1.2,B q)) hreg.1 hreg.2.1 + rw [he] at ha hd + have hstat : fderiv ℝ (fun w => q.1.2*ψ (q.1.1,w)+chartCost a (χ.symm q.2) w) (B q)=0 := by + have H := ((hps.differentiableAt (by simp)).hasFDerivAt.const_mul q.1.2).add hd + convert! H.fderiv using 1 + simp only [add_neg_cancel] + have heU : U q=ψ (q.1.1,B q)+cost (χ.symm (B q)) (χ.symm q.2)/q.1.2 := by + rw [hUE,ha] + dsimp only [parametricShortEnergy] + congr 1 + field_simp + have hlo : U q≤hopfLax q.1.2 f (χ.symm q.2) := by + obtain ⟨y,hy,_⟩ := exists_hopfLax_minimizer hf.continuous q.1.2 (χ.symm q.2) + obtain ⟨hys,hyw⟩ := hlocq ht f hf y hy + have hh := hmin q hq (B q) hbr hstat (χ y) (Metric.ball_subset_closedBall hyw) + have hyy : χ.symm (χ y)=y := χ.left_inv hys + have hysup := hs (χ y) (Metric.ball_subset_closedBall hyw) + change q.1.2*ψ (q.1.1,B q)+cost (χ.symm (B q)) (χ.symm q.2)≤ + q.1.2*ψ (q.1.1,χ y)+cost (χ.symm (χ y)) (χ.symm q.2) at hh + rw [hyy] at hh hysup + rw [heU,hy] + apply (mul_le_mul_iff_left₀ ht).mp + have hd1 : (ψ (q.1.1,B q)+cost (χ.symm (B q)) (χ.symm q.2)/q.1.2)*q.1.2= + q.1.2*ψ (q.1.1,B q)+cost (χ.symm (B q)) (χ.symm q.2) := by field_simp + have hd2 : (f y+cost y (χ.symm q.2)/q.1.2)*q.1.2=q.1.2*f y+cost y (χ.symm q.2) := by field_simp + rw [hd1,hd2] + exact hh.trans (add_le_add (mul_le_mul_of_nonneg_left hysup ht.le) le_rfl) + refine ⟨hlo,fun hc => hlo.antisymm ?_⟩ + rw [heU,←hc] + exact hopfLax_le hf.continuous q.1.2 (χ.symm q.2) (χ.symm (B q)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ProximalProducer.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ProximalProducer.lean new file mode 100644 index 0000000000000000000000000000000000000000..e34a155e8c03e5f7931ea18de014a6463a82b06a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ProximalProducer.lean @@ -0,0 +1,91 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SubgradientDifferential + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +lemma lower_contact_subgradient_on {f g : E → ℝ} {s : Set E} + (hc : ConvexOn ℝ s f) {x : E} (hx : x∈s) + {g' : E →L[ℝ] ℝ} (hg : HasFDerivAt g g' x) + (heq : g x=f x) (hle : g≤ᶠ[𝓝 x]f) : + IsSubgradientOn f s x ((InnerProductSpace.toDual ℝ E).symm g') := by + intro v hv + rw [InnerProductSpace.toDual_symm_apply] + have hp : HasDerivAt (fun t : ℝ => x+t • (v-x)) (v-x) 0 := by + simpa using ((hasDerivAt_id (0:ℝ)).smul_const (v-x)).const_add x + have hd : HasDerivAt (fun t : ℝ => g (x+t • (v-x))) (g' (v-x)) 0 := by + exact (show HasFDerivAt g g' (x+(0:ℝ) • (v-x)) from by simpa using hg).comp_hasDerivAt 0 hp + have htend : Tendsto (fun t : ℝ => x+t • (v-x)) (𝓝[>]0) (𝓝 x) := by + simpa only [zero_smul,add_zero] using hp.continuousAt.tendsto.mono_left nhdsWithin_le_nhds + have hb : ∀ᶠ t : ℝ in 𝓝[>]0, + t⁻¹*(g (x+t • (v-x))-g x)≤f v-f x := by + filter_upwards [Ioo_mem_nhdsGT (by norm_num : (0:ℝ)<1),htend.eventually hle] with t ht htf + have hcv := hc.2 hx hv (by linarith [ht.2] : 0≤1-t) ht.1.le (by ring : 1-t+t=1) + have he : (1-t) • x+t • v=x+t • (v-x) := by + simp only [sub_smul,one_smul,smul_sub]; abel + rw [he] at hcv + simp only [smul_eq_mul] at hcv + rw [inv_mul_eq_div,div_le_iff₀ ht.1,heq] + nlinarith only [hcv,htf] + have hlim : Tendsto (fun t : ℝ => t⁻¹*(g (x+t • (v-x))-g x)) + (𝓝[>]0) (𝓝 (g' (v-x))) := by + simpa only [zero_add,zero_smul,add_zero,smul_eq_mul] using hd.tendsto_slope_zero_right + have H := le_of_tendsto hlim hb + linarith only [H] + +lemma lower_contact_semiconvex_subgradient_on {f g : E → ℝ} {s : Set E} {K : ℝ} + (hc : ConvexOn ℝ s (fun z => f z+K/2*‖z‖^2)) {x : E} (hx : x∈s) + {g' : E →L[ℝ] ℝ} (hg : HasFDerivAt g g' x) + (heq : g x=f x) (hle : g≤ᶠ[𝓝 x]f) : + IsSemiconvexSubgradientOn f s K x ((InnerProductSpace.toDual ℝ E).symm g') := by + rw [semiconvex_subgradient_iff] + have hq := (hasStrictFDerivAt_norm_sq x).hasFDerivAt.const_mul (K/2) + have hh : (fun z => g z+K/2*‖z‖^2)≤ᶠ[𝓝 x](fun z => f z+K/2*‖z‖^2) := by + filter_upwards [hle] with z hz + linarith only [hz] + have h := lower_contact_subgradient_on hc hx (hg.add hq) (by simp only [Pi.add_apply,heq]) hh + convert h using 1 + apply (InnerProductSpace.toDual ℝ E).injective + simp only [map_add,map_smul,LinearIsometryEquiv.apply_symm_apply] + ext z + simp only [add_apply,smul_apply, + InnerProductSpace.toDual_apply_apply,innerSL_apply_apply,smul_eq_mul] + ring + +lemma kernel_minimum_semiconvex_subgradient {f k : E → ℝ} {s : Set E} {K : ℝ} + (hc : ConvexOn ℝ s (fun z => f z+K/2*‖z‖^2)) {x : E} (hx : x∈s) + {k' : E →L[ℝ] ℝ} (hk : HasFDerivAt k k' x) + (hmin : ∀ᶠ y in 𝓝 x, f x+k x≤f y+k y) : + IsSemiconvexSubgradientOn f s K x ((InnerProductSpace.toDual ℝ E).symm (-k')) := by + apply lower_contact_semiconvex_subgradient_on hc hx + (hk.neg.const_add (f x+k x)) (by simp only [Pi.neg_apply]; ring) + filter_upwards [hmin] with y hy + simp only [Pi.neg_apply] + linarith only [hy] + +omit [CompleteSpace E] in +lemma semiconvex_subgradient_eq_at_expansion {f : E → ℝ} {x p ξ : E} + {A : E →L[ℝ] E} (hA : ∀ v w,inner ℝ (A v) w=inner ℝ v (A w)) + (hexp : HasQuadraticExpansion (fun h => f (x+h)) p A) + {r : ℝ} (hr : 0 < r) (K : ℝ) + (hsub : IsSemiconvexSubgradientOn f (Metric.ball x r) K x ξ) : ξ=p := by + obtain ⟨d,hd,H⟩ := semiconvex_subgradient_uniform_differential hA hexp hr K 1 zero_lt_one + have hh := H 0 ξ (by simpa using hd) (by + intro w hw + have hw' : x+w∈Metric.ball x r := by + simpa only [Metric.mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using hw + simpa only [add_zero,sub_zero,add_sub_cancel_left] using hsub (x+w) hw') + have hn : ‖ξ-p‖≤0 := by simpa only [map_zero,sub_zero,norm_zero,mul_zero] using hh + exact sub_eq_zero.mp (norm_eq_zero.mp (le_antisymm hn (norm_nonneg _))) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeJetTest.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeJetTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..95da4bb52f0ee73bc74b550b092072be8706eb9c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeJetTest.lean @@ -0,0 +1,89 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeSemibound + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +def secondJetPullback (j : F →L[ℝ] ℝ) (h : F →L[ℝ] F →L[ℝ] ℝ) + (m : E →L[ℝ] F) (r : E →L[ℝ] E →L[ℝ] F) : E →L[ℝ] E →L[ℝ] ℝ := + ((ContinuousLinearMap.compL ℝ E F ℝ).flip m).comp (h.comp m)+ + (ContinuousLinearMap.compL ℝ E F ℝ j).comp r + +lemma secondJetPullback_apply (j : F →L[ℝ] ℝ) (h : F →L[ℝ] F →L[ℝ] ℝ) + (m : E →L[ℝ] F) (r : E →L[ℝ] E →L[ℝ] F) (v w : E) : + secondJetPullback j h m r v w=h (m v) (m w)+j (r v w) := rfl + +lemma secondJetPullback_tendsto {ι : Type*} {L : Filter ι} + {j : ι → F →L[ℝ] ℝ} {h : ι → F →L[ℝ] F →L[ℝ] ℝ} + {m : ι → E →L[ℝ] F} {r : ι → E →L[ℝ] E →L[ℝ] F} + {j₀ : F →L[ℝ] ℝ} {h₀ : F →L[ℝ] F →L[ℝ] ℝ} + {m₀ : E →L[ℝ] F} {r₀ : E →L[ℝ] E →L[ℝ] F} + (hj : Tendsto j L (𝓝 j₀)) (hh : Tendsto h L (𝓝 h₀)) + (hm : Tendsto m L (𝓝 m₀)) (hr : Tendsto r L (𝓝 r₀)) : + Tendsto (fun i => secondJetPullback (j i) (h i) (m i) (r i)) L + (𝓝 (secondJetPullback j₀ h₀ m₀ r₀)) := by + let : NormedAddCommGroup (F →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (F →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (E →L[ℝ] F) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (E →L[ℝ] F) := ContinuousLinearMap.toNormedSpace + have hm' := (((ContinuousLinearMap.compL ℝ E F ℝ).flip).continuous.tendsto m₀).comp hm + have hh' := ((ContinuousLinearMap.compL ℝ E F (F →L[ℝ] ℝ)).continuous₂.tendsto (h₀,m₀)).comp + (hh.prodMk_nhds hm) + have hfirst := ((ContinuousLinearMap.compL ℝ E (F →L[ℝ] ℝ) (E →L[ℝ] ℝ)).continuous₂.tendsto + (((ContinuousLinearMap.compL ℝ E F ℝ).flip) m₀,h₀.comp m₀)).comp (hm'.prodMk_nhds hh') + have hj' := ((ContinuousLinearMap.compL ℝ E F ℝ).continuous.tendsto j₀).comp hj + have hsecond := ((ContinuousLinearMap.compL ℝ E (E →L[ℝ] F) (E →L[ℝ] ℝ)).continuous₂.tendsto + (ContinuousLinearMap.compL ℝ E F ℝ j₀,r₀)).comp (hj'.prodMk_nhds hr) + exact hfirst.add hsecond + +lemma rough_smooth_pullback_limit_semibound {ι : Type*} {L : Filter ι} + {f q : ι → F → ℝ} {g : ι → E → F} {x : ι → E} + {j₀ : F →L[ℝ] ℝ} {h₀ : F →L[ℝ] F →L[ℝ] ℝ} + {m₀ : E →L[ℝ] F} {r₀ : E →L[ℝ] E →L[ℝ] F} + (hjet : ∀ᶠ i in L, + (∀ᶠ y in 𝓝 (g i (x i)),DifferentiableAt ℝ (f i) y) ∧ + DifferentiableAt ℝ (fderiv ℝ (f i)) (g i (x i)) ∧ + ContDiffAt ℝ 2 (q i) (g i (x i)) ∧ ContDiffAt ℝ 2 (g i) (x i) ∧ + q i (g i (x i))=f i (g i (x i)) ∧ q i≤ᶠ[𝓝 (g i (x i))] f i) + (hj : Tendsto (fun i => fderiv ℝ (q i) (g i (x i))) L (𝓝 j₀)) + (hh : Tendsto (fun i => fderiv ℝ (fderiv ℝ (q i)) (g i (x i))) L (𝓝 h₀)) + (hm : Tendsto (fun i => fderiv ℝ (g i) (x i)) L (𝓝 m₀)) + (hr : Tendsto (fun i => fderiv ℝ (fderiv ℝ (g i)) (x i)) L (𝓝 r₀)) + {ε : ℝ} (hε : 0<ε) : + ∀ᶠ i in L,∀ d:E, secondJetPullback j₀ h₀ m₀ r₀ d d-ε*‖d‖^2≤ + fderiv ℝ (fderiv ℝ (fun a => f i (g i a))) (x i) d d := by + have Hlim := secondJetPullback_tendsto hj hh hm hr + have Hsmall := ((Metric.tendsto_nhds (α := E →L[ℝ] E →L[ℝ] ℝ)).mp Hlim) ε hε + filter_upwards [hjet,Hsmall] with i hi hs + intro d + have Hle := second_fderiv_comp_minorant_le hi.1 hi.2.1 hi.2.2.1 hi.2.2.2.1 + hi.2.2.2.2.1 hi.2.2.2.2.2 d + rw [second_fderiv_comp_with_acceleration hi.2.2.1 hi.2.2.2.1] at Hle + have Habs := (abs_le.mp (bilinear_diag_sub_bound + (secondJetPullback (fderiv ℝ (q i) (g i (x i))) + (fderiv ℝ (fderiv ℝ (q i)) (g i (x i))) + (fderiv ℝ (g i) (x i)) (fderiv ℝ (fderiv ℝ (g i)) (x i))) + (secondJetPullback j₀ h₀ m₀ r₀) d)).1 + rw [dist_eq_norm + (secondJetPullback (fderiv ℝ (q i) (g i (x i))) + (fderiv ℝ (fderiv ℝ (q i)) (g i (x i))) + (fderiv ℝ (g i) (x i)) (fderiv ℝ (fderiv ℝ (g i)) (x i))) + (secondJetPullback j₀ h₀ m₀ r₀)] at hs + have Hmul := mul_le_mul_of_nonneg_right hs.le (sq_nonneg ‖d‖) + rw [secondJetPullback_apply] at Habs + linarith only [Hle,Habs,Hmul] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeSemibound.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeSemibound.lean new file mode 100644 index 0000000000000000000000000000000000000000..6dbd1636ebb6dc78f36066498e21fe442a31ffd6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortEnvelopeSemibound.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeTaylor +import OAI.Analysis.BiholderTransport.Contact.SmoothSupportSemibound + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_fderiv_comp_at {f : F → ℝ} {g : E → F} {x : E} + (hnear : ∀ᶠ y in 𝓝 (g x),DifferentiableAt ℝ f y) + (hf : DifferentiableAt ℝ (fderiv ℝ f) (g x)) + (hg : ContDiffAt ℝ 2 g x) (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => f (g a))) x v w = + fderiv ℝ (fderiv ℝ f) (g x) (fderiv ℝ g x v) (fderiv ℝ g x w)+ + fderiv ℝ f (g x) (fderiv ℝ (fderiv ℝ g) x v w) := by + have hgd := (hg.differentiableAt (by norm_num)).hasFDerivAt + have hd1 := hf.hasFDerivAt.comp (f := g) x hgd + have hd2 := ((hg.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt + have hd := hd1.clm_comp hd2 + have heq : (fun a => (fderiv ℝ f (g a)).comp (fderiv ℝ g a)) =ᶠ[𝓝 x] + fderiv ℝ (fun a => f (g a)) := by + filter_upwards [hgd.continuousAt.eventually hnear,hg.eventually (by norm_num)] + with a hfa hga + exact (hfa.hasFDerivAt.comp (f := g) a + (hga.differentiableAt (by norm_num)).hasFDerivAt).fderiv.symm + have H := congrArg (fun A : E →L[ℝ] E →L[ℝ] ℝ => A v w) + (hd.congr_of_eventuallyEq heq.symm).fderiv + simpa only [Function.comp_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.compL_apply,ContinuousLinearMap.flip_apply,add_apply,add_comm] using H + +lemma second_fderiv_comp_minorant_le {f q : F → ℝ} {g : E → F} {x : E} + (hnear : ∀ᶠ y in 𝓝 (g x),DifferentiableAt ℝ f y) + (hf : DifferentiableAt ℝ (fderiv ℝ f) (g x)) + (hq : ContDiffAt ℝ 2 q (g x)) (hg : ContDiffAt ℝ 2 g x) + (hval : q (g x)=f (g x)) (hlo : q≤ᶠ[𝓝 (g x)] f) (d:E) : + fderiv ℝ (fderiv ℝ (fun a => q (g a))) x d d≤ + fderiv ℝ (fderiv ℝ (fun a => f (g a))) x d d := by + have hd := (hnear.self_of_nhds).hasFDerivAt + have hmin : IsLocalMin (fun y => f y-q y) (g x) := by + filter_upwards [hlo] with y hy + change f (g x)-q (g x)≤f y-q y + rw [hval,sub_self] + linarith only [hy] + have hD : fderiv ℝ f (g x)=fderiv ℝ q (g x) := + sub_eq_zero.mp (hmin.hasFDerivAt_eq_zero + (hd.sub (hq.differentiableAt (by norm_num)).hasFDerivAt)) + have hj := hasSecondTaylor_of_second_derivative + (hnear.mono (fun y hy => hy.hasFDerivAt)) hf.hasFDerivAt + have H := hj.smooth_support_diag_le_at hd hq hval hlo (fderiv ℝ g x d) + rw [second_fderiv_comp_with_acceleration hq hg, + second_fderiv_comp_at hnear hf hg,hD] + linarith only [H] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/ShortPullbackSemibound.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortPullbackSemibound.lean new file mode 100644 index 0000000000000000000000000000000000000000..77b8e06908f85632fd50bcf3a77016f8d1cbc11f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/ShortPullbackSemibound.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeJetTest +import OAI.Analysis.BiholderTransport.Regularity.ParametricLowerSequence + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section ShortPullbackSemibound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P E : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma parametric_short_pullback_semibound {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} (L : ℝ≥0) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) + {pj : ℕ → P} {xj : ℕ → Model n} {tj : ℕ → ℝ} {f : ℕ → M → ℝ} + (hp : Tendsto pj atTop (𝓝 p)) (hxx : Tendsto xj atTop (𝓝 x)) + (ht : Tendsto tj atTop (𝓝 0)) (htpos : ∀ᶠ i in atTop,0hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (fun z=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm z))) (g i (y i)) ∧ + ContDiffAt ℝ 2 (g i) (y i)) + {m : E →L[ℝ] Model n} {r : E →L[ℝ] E →L[ℝ] Model n} + (hm : Tendsto (fun i=>fderiv ℝ (g i) (y i)) atTop (𝓝 m)) + (hr : Tendsto (fun i=>fderiv ℝ (fderiv ℝ (g i)) (y i)) atTop (𝓝 r)) + {ε : ℝ} (hε : 0<ε) : + ∀ᶠ i in atTop,∀ d:E, + secondJetPullback (fderiv ℝ (fun w=>ψ (p,w)) x) + (fderiv ℝ (fderiv ℝ (fun w=>ψ (p,w))) x) m r d d-ε*‖d‖^2≤ + fderiv ℝ (fderiv ℝ (fun w=>hopfLax (tj i) (f i) + ((extChartAt 𝓘(ℝ,Model n) a).symm (g i w)))) (y i) d d := by + obtain ⟨U,hU,hD,hH⟩ := exists_parametric_short_lower_sequence L hx hψ hp hxx ht htpos hlip hbelow htouch + have hj : ∀ᶠ i in atTop, + (∀ᶠ z in 𝓝 (g i (y i)),DifferentiableAt ℝ + (fun z=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (fun z=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm z))) (g i (y i)) ∧ + ContDiffAt ℝ 2 (U i) (g i (y i)) ∧ ContDiffAt ℝ 2 (g i) (y i) ∧ + U i (g i (y i))=hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm (g i (y i))) ∧ + U i≤ᶠ[𝓝 (g i (y i))] (fun z=>hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm z)) := by + filter_upwards [hU,hjet,hgxy] with i hUi hji he + rw [←he] at hUi + exact ⟨hji.1,hji.2.1,hUi.1,hji.2.2,hUi.2.1,hUi.2.2⟩ + apply rough_smooth_pullback_limit_semibound hj ?_ ?_ hm hr hε + · exact hD.congr' (hgxy.mono (fun i hi=>congrArg (fderiv ℝ (U i)) hi.symm)) + · exact hH.congr' (hgxy.mono (fun i hi=>congrArg (fderiv ℝ (fderiv ℝ (U i))) hi.symm)) + +end ShortPullbackSemibound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/SimultaneousC11Jensen.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/SimultaneousC11Jensen.lean new file mode 100644 index 0000000000000000000000000000000000000000..984108b7b9b71484de016f56e818f21a83f2f700 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/SimultaneousC11Jensen.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Taylor +import OAI.Analysis.BiholderTransport.Convexity.JensenMaximum +import OAI.Analysis.BiholderTransport.Volume.JensenNullPullback +import OAI.Analysis.BiholderTransport.Convexity.ModifiedEnvelopeRegularity + +namespace OAI + +noncomputable section +open Set Filter Metric MeasureTheory +open scoped Topology NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + +lemma simultaneous_C11_jensen {f k : E → ℝ} {Y Z : E → E} + {S : Set E} (hS : IsOpen S) {x0 : E} {r eta : ℝ} + (hr : 0 f (z+h)) (fderiv ℝ f z) (fderiv ℝ (fderiv ℝ f) z) ∧ + HasSecondTaylor (fun h => k (z+h)) (fderiv ℝ k z) (fderiv ℝ (fderiv ℝ k) z) ∧ + ‖fderiv ℝ f z+fderiv ℝ k z‖≤2*eta*r ∧ + ∀ e:E,fderiv ℝ (fderiv ℝ f) z e e+fderiv ℝ (fderiv ℝ k) z e e≤eta*‖e‖^2 := by + let g : E → E := fun x => (InnerProductSpace.toDual ℝ E).symm + (fderiv ℝ f x+fderiv ℝ k x) + have hlip : LipschitzOnWith (Lf+Lk) g (closedBall x0 r) := by + apply LipschitzOnWith.of_dist_le_mul + intro x hx y hy + change dist ((InnerProductSpace.toDual ℝ E).symm _) + ((InnerProductSpace.toDual ℝ E).symm _)≤_ + rw [(InnerProductSpace.toDual ℝ E).symm.isometry.dist_eq] + exact ((hfl.add hkl).mono hsub).dist_le_mul x hx y hy + have hd : ∀ x∈ball x0 r, + HasFDerivAt (fun x => f x+k x) ((innerSL ℝ) (g x)) x := by + intro x hx + have HH := (hf x (hsub (ball_subset_closedBall hx))).hasFDerivAt.add + (hk x (hsub (ball_subset_closedBall hx))).hasFDerivAt + have hg : (innerSL ℝ) (g x)=fderiv ℝ f x+fderiv ℝ k x := + (InnerProductSpace.toDual ℝ E).apply_symm_apply _ + rwa [hg] + have hc : ContinuousOn (fun x => f x+k x) (closedBall x0 r) := + fun x hx => ((hf x (hsub hx)).continuousAt.add (hk x (hsub hx)).continuousAt).continuousWithinAt + have H : ∀ᵐ z ∂μ,z∈ball x0 r → P z ∧ + HasFDerivAt Y (fderiv ℝ Y z) z ∧ HasFDerivAt Z (fderiv ℝ Z z) z ∧ + ((fderiv ℝ Y z).det≠0 → Y z∉N) ∧ + HasSecondTaylor (fun h => f (z+h)) (fderiv ℝ f z) (fderiv ℝ (fderiv ℝ f) z) ∧ + HasSecondTaylor (fun h => k (z+h)) (fderiv ℝ k z) (fderiv ℝ (fderiv ℝ k) z) := by + filter_upwards [hP,ae_secondTaylor_of_C11 μ hS hf hfl, + ae_secondTaylor_of_C11 μ hS hk hkl, + hY.ae_differentiableWithinAt_of_mem (μ := μ), + hZ.ae_differentiableWithinAt_of_mem (μ := μ), + ae_nonsingular_map_avoids_null (D := fderiv ℝ Y) μ hN] + with z hzP hzf hzk hzY hzZ hzN hzb + have hzS := hsub (ball_subset_closedBall hzb) + have hyD := ((hzY hzS).differentiableAt (hS.mem_nhds hzS)).hasFDerivAt + exact ⟨hzP hzS,hyD,((hzZ hzS).differentiableAt (hS.mem_nhds hzS)).hasFDerivAt, + hzN hyD,(hzf hzS).2,(hzk hzS).2⟩ + obtain ⟨z,hz,hby,hgz,hu⟩ := jensen_C11_select hr heta hc hmax hd hlip μ H + obtain ⟨hzP,hzY,hzZ,hzN,hzf,hzk⟩ := hby hz + refine ⟨z,hz,hzP,hzY,hzZ,hzN,hzf,hzk,?_,?_⟩ + · simpa only [g,(InnerProductSpace.toDual ℝ E).symm.norm_map] using hgz + · have hA := (hzf.add hzk).hasQuadraticExpansion + have hzn : ‖z-x0‖ f (z+h)) (fderiv ℝ f z) (fderiv ℝ (fderiv ℝ f) z) ∧ + HasSecondTaylor (fun h => k (z+h)) (fderiv ℝ k z) (fderiv ℝ (fderiv ℝ k) z) ∧ + ‖fderiv ℝ f z+fderiv ℝ k z‖≤eta ∧ + ∀ e:E,fderiv ℝ (fderiv ℝ f) z e e+fderiv ℝ (fderiv ℝ k) z e e≤eta*‖e‖^2 := by + obtain ⟨R,hR,HR⟩ := Metric.eventually_nhds_iff.mp + (hmax.and (hS.mem_nhds hx)) + let r := min (R/2) (min rho (1/2)) + have hr : 0 (hlocal z hz).2) hf hk hfl hkl hY hZ + (fun z hz => (hlocal z hz).1) hN hP + refine ⟨z,ball_subset_ball hrrho hz,hp,hy,hzD,hn,htf,htk,hg.trans ?_,hh⟩ + nlinarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/StrongCostConvexity.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/StrongCostConvexity.lean new file mode 100644 index 0000000000000000000000000000000000000000..f926139e0446514bbd35a9a67e26a28d37d24fa9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/StrongCostConvexity.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.DiagonalCostConvexity +import OAI.Analysis.BiholderTransport.Coordinates.ShortLocalMinimum +import OAI.Analysis.BiholderTransport.LinearAlgebra.OuterDisplacementJetBound + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance strongCostDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance strongCostDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance strongCostBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance strongCostBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma chartCost_uniform_strongConvex {a : M} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ∃ m>0,∃ r>0,∃ V∈𝓝 x,∀ z∈V, + StrongConvexOn (Metric.closedBall x r) m + (chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm z)) := by + let F : Model n → Model n → ℝ := fun z => + chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm z) + have hc : ContDiffAt ℝ ∞ (Function.uncurry F) (x,x) := + chartCost_pair_contDiffAt_diagonal hx + have hH : ContinuousAt (fun q : Model n×Model n => + fderiv ℝ (fderiv ℝ (F q.1)) q.2) (x,x) := + (ContDiffAt.partial_snd_fderiv_two hc).continuousAt + obtain ⟨k,hk,hpos⟩ := chartCost_diagonal_coercive hx + have H := @ContinuousAt.norm (Model n×Model n) (Model n →L[ℝ] Model n →L[ℝ] ℝ) _ _ _ _ + (hH.sub (continuousAt_const (y := fderiv ℝ (fderiv ℝ (F x)) x))) + have hn : ∀ᶠ q : Model n×Model n in 𝓝 (x,x), + ‖fderiv ℝ (fderiv ℝ (F q.1)) q.2-fderiv ℝ (fderiv ℝ (F x)) x‖ (q.1,z)) q.2 (contDiffAt_const.prodMk contDiffAt_id) + obtain ⟨V,hV,U,hU,hVU⟩ := mem_nhds_prod_iff.mp (hn.and hd) + obtain ⟨r,hr,hrU⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hU + refine ⟨k/2,half_pos hk,r,hr,V,hV,?_⟩ + intro z hz + apply strongConvexOn_of_hessian_lower (convex_closedBall x r) + (fun w hw => (hVU (a := (z,w)) ⟨hz,hrU hw⟩).2) + intro w hw d + have hn' := (hVU (a := (z,w)) ⟨hz,hrU hw⟩).1 + have hb := (fderiv ℝ (fderiv ℝ (F z)) w-fderiv ℝ (fderiv ℝ (F x)) x).le_opNorm₂ d d + have hh := hpos d + have hm := mul_le_mul_of_nonneg_right hn'.le (sq_nonneg ‖d‖) + have ha := neg_le_abs (fderiv ℝ (fderiv ℝ (F z)) w d d- + fderiv ℝ (fderiv ℝ (F x)) x d d) + simp only [sub_apply,Real.norm_eq_abs] at hb + dsimp only [F] at hb ha hm + nlinarith only [hb,ha,hh,hm] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/StrongEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/StrongEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..4a37d6dac46970968a20305d7922e7d6d47a539c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/StrongEnvelope.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.MatchedSupports +import OAI.Analysis.BiholderTransport.LinearAlgebra.OuterDisplacementJetBound + +namespace OAI + +noncomputable section +open Set Filter Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +variable {S T : Set E} {w F : E → ℝ} {C : E → E → ℝ} {Y : E → E} + {m K B : ℝ} + +lemma strongly_convex_minimizer_unique {f : E → ℝ} {x y:E} + (hm : 0 < m) (hf : StrongConvexOn S m f) (hx : x∈S) (hy : y∈S) + (hmin : IsMinOn f S x) (heq : f x=f y) : x=y := by + have H := StrongConvexOn.quadratic_growth_half hf hx hy hmin + rw [heq] at H + have hnonneg := sq_nonneg ‖y-x‖ + have hs : ‖y-x‖^2=0 := by nlinarith only [H,hm,hnonneg] + exact (sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp hs))).symm + +lemma strong_envelope_minimizer_lipschitz (hm : 0 < m) (hK : 0 ≤ K) + (hY : ∀ z∈T,Y z∈S) + (hval : ∀ z∈T,F z=w (Y z)+C (Y z) z) + (hmin : ∀ z∈T,∀ y∈S,F z≤w y+C y z) + (hstrong : ∀ z∈T,StrongConvexOn S m (fun y => w y+C y z)) + (hcross : ∀ y∈S,∀ y'∈S,∀ z∈T,∀ z'∈T, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖) : + LipschitzOnWith (Real.toNNReal (2*K/m)) Y T := by + apply LipschitzOnWith.of_dist_le_mul + intro z hz z' hz' + have hy := hY z hz + have hy' := hY z' hz' + have HM : IsMinOn (fun y => w y+C y z) S (Y z) := by + intro y hy + change w (Y z)+C (Y z) z≤w y+C y z + rw [←hval z hz] + exact hmin z hz y hy + have HM' : IsMinOn (fun y => w y+C y z') S (Y z') := by + intro y hy + change w (Y z')+C (Y z') z'≤w y+C y z' + rw [←hval z' hz'] + exact hmin z' hz' y hy + have HG := StrongConvexOn.quadratic_growth_half (hstrong z hz) hy hy' HM + have HG' := StrongConvexOn.quadratic_growth_half (hstrong z' hz') hy' hy HM' + have HC := (abs_le.mp (hcross (Y z) hy (Y z') hy' z hz z' hz')).1 + rw [norm_sub_rev (Y z) (Y z')] at HG' + rw [dist_eq_norm,dist_eq_norm,Real.coe_toNNReal _ (div_nonneg (by positivity) hm.le)] + rw [norm_sub_rev (Y z) (Y z'),norm_sub_rev z z'] + by_cases hd : ‖Y z'-Y z‖=0 + · rw [hd]; positivity + have hp : 0<‖Y z'-Y z‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hd) + have H : m/2*‖Y z'-Y z‖^2≤K*‖Y z'-Y z‖*‖z'-z‖ := by linarith only [HG,HG',HC] + rw [div_mul_eq_mul_div] + apply (le_div_iff₀ hm).mpr + change ‖Y z'-Y z‖*m≤2*K*‖z'-z‖ + nlinarith only [H,hp,hm] + +lemma strong_envelope_quadratic_remainder (hm : 0 < m) + (hY : ∀ z∈T,Y z∈S) + (hval : ∀ z∈T,F z=w (Y z)+C (Y z) z) + (hmin : ∀ z∈T,∀ y∈S,F z≤w y+C y z) + (hstrong : ∀ z∈T,StrongConvexOn S m (fun y => w y+C y z)) + (hcross : ∀ y∈S,∀ y'∈S,∀ z∈T,∀ z'∈T, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖) + {l:E → E →L[ℝ] ℝ} + (hrem : ∀ z∈T,∀ z'∈T, + |C (Y z) z'-C (Y z) z-l z (z'-z)|≤B*‖z'-z‖^2) : + ∀ z∈T,∀ z'∈T, + |F z'-F z-l z (z'-z)|≤(B+K^2/m)*‖z'-z‖^2 := by + intro z hz z' hz' + have hy := hY z hz + have hy' := hY z' hz' + have HM : IsMinOn (fun y => w y+C y z) S (Y z) := by + intro y hy + change w (Y z)+C (Y z) z≤w y+C y z + rw [←hval z hz] + exact hmin z hz y hy + have HG := StrongConvexOn.quadratic_growth_half (hstrong z hz) hy hy' HM + have HC := (abs_le.mp (hcross (Y z) hy (Y z') hy' z hz z' hz')).1 + have HR := abs_le.mp (hrem z hz z' hz') + have HU := hmin z' hz' (Y z) hy + have hYz := hval z hz + have hYz' := hval z' hz' + have hsquare := sq_nonneg (m*‖Y z'-Y z‖-2*K*‖z'-z‖) + have hdiv : (K^2/m)*m=K^2 := div_mul_cancel₀ _ hm.ne' + have Hcomplete : -(K^2/m)*‖z'-z‖^2≤ + m/4*‖Y z'-Y z‖^2-K*‖Y z'-Y z‖*‖z'-z‖ := by + nlinarith only [hsquare,hdiv,hm] + apply abs_le.mpr + constructor + · nlinarith only [HG,HC,HR.1,hYz,hYz',Hcomplete] + · have hn : 0 ≤ K^2/m*‖z'-z‖^2 := by positivity + nlinarith only [HU,hYz,HR.2,hn] + +lemma strong_envelope_C11 {a:E} {r:ℝ} (hr : 0 < r) (hm : 0 < m) (hK : 0 ≤ K) (hB : 0 ≤ B) + (hY : ∀ z∈ball a r,Y z∈S) + (hval : ∀ z∈ball a r,F z=w (Y z)+C (Y z) z) + (hmin : ∀ z∈ball a r,∀ y∈S,F z≤w y+C y z) + (hstrong : ∀ z∈ball a r,StrongConvexOn S m (fun y => w y+C y z)) + (hcross : ∀ y∈S,∀ y'∈S,∀ z∈ball a r,∀ z'∈ball a r, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖) + {l:E → E →L[ℝ] ℝ} + (hrem : ∀ z∈ball a r,∀ z'∈ball a r, + |C (Y z) z'-C (Y z) z-l z (z'-z)|≤B*‖z'-z‖^2) : + (∀ z∈ball a r,HasFDerivAt F (l z) z) ∧ + LipschitzOnWith (Real.toNNReal (6*(B+K^2/m))) (fderiv ℝ F) (ball a (r/4)) := by + have H := strong_envelope_quadratic_remainder hm hY hval hmin hstrong hcross hrem + have hconst : 0 ≤ B+K^2/m := add_nonneg hB (div_nonneg (pow_nonneg hK 2) hm.le) + have hd : ∀ z∈ball a r,HasFDerivAt F (l z) z := by + intro z hz + exact hasFDerivAt_of_quadratic_remainder hconst + (by filter_upwards [isOpen_ball.mem_nhds hz] with z' hz'; exact H z hz z' hz') + refine ⟨hd,?_⟩ + rw [Real.toNNReal_of_nonneg (show 0≤6*(B+K^2/m) from by positivity)] + exact derivative_lipschitz_of_quadratic_remainder hr hconst + (fun z hz z' hz' => by rw [(hd z hz).fderiv]; exact H z hz z' hz') +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/TransformSemiconvex.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/TransformSemiconvex.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a7dd9e4bd713f023c796cb09d2d0a8a47e6e50c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/TransformSemiconvex.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull +import OAI.Analysis.BiholderTransport.Contact.Inner +import OAI.Analysis.BiholderTransport.LinearAlgebra.HalfCostUniform + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TransformSemiconvex +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma uniform_cTransform_semiconvex (a : M) : + ∃ K>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ v : M → ℝ, Continuous v → + ConvexOn ℝ (ball (extChartAt 𝓘(ℝ,Model n) a a) r) + (fun z => cTransform v ((extChartAt 𝓘(ℝ,Model n) a).symm z)+K/2*‖z‖^2) := by + obtain ⟨B,hB,r,hr,hrT,hjet⟩ := uniform_half_cost_hessian (n := n) a + refine ⟨4*B,by positivity,r,hr,hrT,?_⟩ + intro v hv + have he : 4*B/2=2*B := by ring + rw [he] + apply convexOn_of_quadratic_lower_supports (convex_ball _ _) + intro x hx + let χ := extChartAt 𝓘(ℝ,Model n) a + obtain ⟨p,hp⟩ := nonempty_activeLogs (n := n) hv (χ.symm x) + let f := chartCost (n := n) a (riemannianExp (χ.symm x) ((1/2:ℝ) • p)) + refine ⟨(-2:ℝ) • fderiv ℝ f x,?_⟩ + intro z hz + have hrem := first_order_remainder_le_of_hessian_bound (convex_ball _ _) hB.le + (fun w hw => (hjet x hx p hp.1 w hw).1) + (fun w hw => (hjet x hx p hp.1 w hw).2) hx hz + have hlow := active_split_lower_support hv hp.1 hp.2 + (by norm_num : (0:ℝ)<1/2) (by norm_num : (1/2:ℝ)<1) (χ.symm z) + change |f z-f x-fderiv ℝ f x (z-x)|≤B*‖z-x‖^2 at hrem + change -(f z-f x)/(1/2:ℝ)≤cTransform v (χ.symm z)-cTransform v (χ.symm x) at hlow + have hU := (abs_le.mp hrem).2 + simp only [_root_.smul_apply,smul_eq_mul] + norm_num at hlow + nlinarith + +end TransformSemiconvex +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/TranslatedMinorant.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/TranslatedMinorant.lean new file mode 100644 index 0000000000000000000000000000000000000000..889e96b09d591be8d0f75550b7bc0f44f0f18084 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/TranslatedMinorant.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.QuadraticTest + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TranslatedMinorant +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma HasLowerSecondTaylor.exists_smooth_minorant_at {f : E → ℝ} {x : E} + {l : E →L[ℝ] ℝ} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasLowerSecondTaylor (fun h => f (x+h)) l B) {ε : ℝ} (hε : 0<ε) : + ∃ q:E → ℝ,ContDiffAt ℝ 2 q x ∧ q x=f x ∧ fderiv ℝ q x=l ∧ + (∀ᶠ y in 𝓝 x,q y≤f y) ∧ + ∀ d:E,fderiv ℝ (fderiv ℝ q) x d d=B d d-ε*‖d‖^2 := by + obtain ⟨q,hq,hval,hd,hlo,hH⟩ := hf.exists_smooth_minorant hε + let Q : E → ℝ := fun y => q (y-x) + have hQ : ContDiffAt ℝ 2 Q x := + (show ContDiffAt ℝ 2 q (x-x) by simpa only [sub_self] using hq).comp (f := fun y:E => y-x) x + (contDiffAt_id.sub contDiffAt_const) + have hshift : ∀ y:E,fderiv ℝ Q y=fderiv ℝ q (y-x) := by + intro y + simpa only [Q,sub_eq_add_neg] using (fderiv_comp_add_right (-x) (f := q) (x := y)) + refine ⟨Q,hQ,?_,?_,?_,?_⟩ + · simpa only [Q,sub_self,add_zero] using hval + · rw [hshift,sub_self,hd] + · have ht : Tendsto (fun y:E => y-x) (𝓝 x) (𝓝 (0:E)) := by + convert! ((tendsto_id : Tendsto (fun y:E => y) (𝓝 x) (𝓝 x)).sub + (tendsto_const_nhds (x := x))) using 1 + simp only [sub_self] + filter_upwards [ht.eventually hlo] with y hy + simpa only [Q,add_sub_cancel] using hy + · intro d + rw [show fderiv ℝ Q=(fun y => fderiv ℝ q (y-x)) from funext hshift] + have HH := fderiv_comp_add_right (𝕜 := ℝ) (-x) (f := fderiv ℝ q) (x := x) + simp only [←sub_eq_add_neg,sub_self] at HH + rw [HH] + exact hH d + +end TranslatedMinorant +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Convexity/UniformEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/Convexity/UniformEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5e55804f7bab848a9f3ac4e4b5547ee6be0e8e8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Convexity/UniformEnvelope.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.CompactSmoothGrowth +import OAI.Analysis.BiholderTransport.Convexity.EnvelopeData +import OAI.Analysis.BiholderTransport.LinearAlgebra.ScaledSlack + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +abbrev chartFiberInverse (a : M) (b : Model n) := + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) + +omit [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartFiberInverse_injective {a : M} {b : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) : + Function.Injective (chartFiberInverse a b) := by + let e := trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + have hx : (extChartAt 𝓘(ℝ,Model n) a).symm b ∈ e.baseSet := by + simpa only [e,TangentBundle.trivializationAt_baseSet,extChartAt_source] using + (extChartAt 𝓘(ℝ,Model n) a).map_target hb + rw [show (chartFiberInverse a b : Model n → _) = + (e.continuousLinearEquivAt ℝ _ hx).symm from (e.symm_continuousLinearEquivAt_eq hx).symm] + exact (e.continuousLinearEquivAt ℝ _ hx).symm.injective + +lemma scaledNormalEnvelope_mean {ι : Type*} [Fintype ι] + {a : M} {s : ℝ} (hs : s ≠ 0) {q : EnvelopeData (Model n) ι} + (hb : q.1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : chartFiberInverse a q.1.1 (q.2.2 • ∑ j, q.2.1 j • q.1.2 j) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + (hi : ∀ i, chartFiberInverse a q.1.1 (s • q.1.2 i) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + (hsum : ∑ i, q.2.1 i = 1) (v : Model n) : + ∑ i, q.2.1 i * fderiv ℝ (scaledNormalEnvelope a s q i) 0 v = 0 := by + let L := chartFiberInverse a q.1.1 + let r := ∑ j, q.2.1 j • q.1.2 j + have he : (∑ i, q.2.1 i • L (q.1.2 i-r)) = 0 := by + simp only [map_sub,smul_sub,Finset.sum_sub_distrib,←Finset.sum_smul,hsum,one_smul] + rw [show (∑ i, q.2.1 i • L (q.1.2 i)) = L r by simp only [r,map_sum,map_smul]] + exact sub_self _ + calc + _ = q.2.2 * inner ℝ (∑ i, q.2.1 i • L (q.1.2 i-r)) (L v) := by + simp only [scaledNormalEnvelope_first hs _ hb hp (hi _),sum_inner, + real_inner_smul_left,Finset.mul_sum,L,r] + apply Finset.sum_congr rfl + intro i _ + ring + _ = 0 := by rw [he,inner_zero_left,mul_zero] + +lemma WeakMTW.compact_scaled_envelope_growth + (hmtw : WeakMTW (n := n) (M := M)) + {P : Type*} [TopologicalSpace P] [CompactSpace P] + {ι : Type*} [Fintype ι] [Nonempty ι] + (a : M) (s : ℝ) (hs : 0 < s) (hs1 : s < 1) + (d : P → EnvelopeData (Model n) ι) (hd : Continuous d) + (hb : ∀ z, (d z).1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hw : ∀ z i, 0 ≤ (d z).2.1 i) (hsum : ∀ z, ∑ i, (d z).2.1 i = 1) + (ht : ∀ z, 0 ≤ (d z).2.2) (hts : ∀ z, (d z).2.2 < s) + (hmin : ∀ z i, chartFiberInverse a (d z).1.1 ((d z).1.2 i) ∈ + minimizingVectors ((extChartAt 𝓘(ℝ,Model n) a).symm (d z).1.1)) + (hID : ∀ z p, p ∈ convexHull ℝ (range (fun i => chartFiberInverse a (d z).1.1 ((d z).1.2 i))) → + (d z).2.2 • p ∈ injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (d z).1.1)) : + ∃ b > 0, ∀ᶠ h : Model n in 𝓝 0, ∀ z : P, ∃ i, + b * ‖h‖^2 ≤ scaledNormalEnvelope a s (d z) i h := by + have hi : ∀ z i, chartFiberInverse a (d z).1.1 (s • (d z).1.2 i) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (d z).1.1) := by + intro z i + rw [map_smul] + exact contracted_minimizer_mem_injectivityDomain (hmin z i) hs hs1 + have hp : ∀ z, chartFiberInverse a (d z).1.1 ((d z).2.2 • ∑ j, (d z).2.1 j • (d z).1.2 j) ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (d z).1.1) := by + intro z + simp only [map_smul,map_sum] + apply hID z + exact (convex_convexHull ℝ _).sum_mem (fun i _ => hw z i) (hsum z) + (fun i _ => subset_convexHull ℝ _ (mem_range_self i)) + apply compact_smooth_data_transverse_growth (scaledNormalEnvelope a s) d hd + (fun z => (d z).2.1) hw hsum + · intro i + exact (continuous_apply i).comp hd.snd.fst + · intro z i + exact scaledNormalEnvelope_contDiffAt i (hb z) (hp z) (hi z i) + · intro z i + exact scaledNormalEnvelope_zero a s (d z) i + · intro z v + exact scaledNormalEnvelope_mean hs.ne' (hb z) (hp z) (hi z) (hsum z) v + · intro z v hv hle + let L := chartFiberInverse a (d z).1.1 + have hLv : L v ≠ 0 := by + intro he + have hv0 : v = 0 := (chartFiberInverse_injective (hb z)) (he.trans (map_zero L).symm) + simp only [hv0,norm_zero] at hv + norm_num at hv + have H := hmtw.finite_scaled_transverse_positive + (fun i => L ((d z).1.2 i)) ((d z).2.1) (hw z) (hsum z) (hmin z) + (ht z) (hts z) hs1 (hID z) hLv + have hl : ∀ i, (d z).2.2 * inner ℝ + (L ((d z).1.2 i) - ∑ j, (d z).2.1 j • L ((d z).1.2 j)) (L v) ≤ 0 := by + intro i + simpa only [scaledNormalEnvelope_first hs.ne' i (hb z) (hp z) (hi z i), + map_sub,map_sum,map_smul,L] using hle i + have HH := H hl + simpa only [scaledNormalEnvelope_second _ (hb z) (hp z) (hi z _), + map_smul,map_sum,L] using HH + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/AECertificates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/AECertificates.lean new file mode 100644 index 0000000000000000000000000000000000000000..08edfde18c8da6a4b84bf22d85401bb9fb359341 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/AECertificates.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Midpoint +import OAI.Analysis.BiholderTransport.CostGeometry.SectionDiameter +import OAI.Analysis.BiholderTransport.Coordinates.ManifoldLipschitz +import OAI.Analysis.BiholderTransport.Duality.RiemannianTransport + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology ContDiff NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section PowerEndpoint +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.section_diameter_of_exp_bound (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {L : ℝ≥0} (hL : ∀ x : M, ∀ p q : TangentSpace 𝓘(ℝ,Model n) x, + ‖p‖≤Metric.diam (univ : Set M) → ‖q‖≤Metric.diam (univ : Set M) → + dist (riemannianExp x p) (riemannianExp x q)≤L*‖p-q‖) + {x : M} {r : ℝ} (hr : 0≤r) {y y' : M} + (hy : y∈gapSection u v x r) (hy' : y'∈gapSection u v x r) : + dist y y'≤L*Real.sqrt (8*(sectionOscillation u v x r+r)) := by + rw [←liftedGapSection_image (n := n) u v x r] at hy hy' + obtain ⟨p,hp,rfl⟩ := hy + obtain ⟨q,hq,rfl⟩ := hy' + have hb : ∀ w∈minimizingVectors (n := n) x, ‖w‖≤Metric.diam (univ : Set M) := by + intro w hw + rw [←show dist x (riemannianExp x w)=‖w‖ from hw] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ _) (mem_univ _) + apply (hL x p q (hb p hp.1) (hb q hq.1)).trans + apply mul_le_mul_of_nonneg_left _ L.coe_nonneg + apply Real.le_sqrt_of_sq_le + simpa only [add_comm] using hmtw.liftedGapSection_diameter_sq hu hv hdual hr hp hq + +variable [MeasurableSpace M] + +lemma WeakMTW.contact_bounds_of_class_power (hmtw : WeakMTW (n := n) (M := M)) + {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hpower : HasPowerUpperBound (classOscillation vol lam cap x0)) : + ∃ alpha C : ℝ, 0 + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + have hr1 : 0 hs x (S x) (hS x)) + rw [hST] at hpush + have hgap := dualPair_gap_nonneg uv.2.continuous hdual + refine ⟨T,isOptimalMap_of_dual_contact hlam hrho0 hrho1 + uv.1.continuous uv.2.continuous hgap T.continuous.measurable hpush hT,?_,hTf,hTr⟩ + intro S hS + exact optimalMap_ae_eq_of_singleton_contacts hlam hrho0 hrho1 + uv.1.continuous uv.2.continuous hgap T.continuous.measurable hpush hT hs hS + +end PowerEndpoint +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveCompact.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..06e97a11d4bb04e59b2c9cb74d31a9f8e50053ec --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveCompact.lean @@ -0,0 +1,288 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma isCompact_total_activeLogs {v : M → ℝ} (hv : Continuous v) : + IsCompact {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ activeLogs (n := n) v z.1} := by + cases isEmpty_or_nonempty M with + | inl h => + have he : {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ activeLogs (n := n) v z.1}=∅ := by + ext z + exact isEmptyElim z.1 + rw [he] + exact isCompact_empty + | inr h => + have hc : Continuous (fun z : TangentBundle 𝓘(ℝ,Model n) M => + contactGap (cTransform v) v z.1 (riemannianExp z.1 z.2)) := by + have hp : Continuous (fun z : TangentBundle 𝓘(ℝ,Model n) M => z.1) := + FiberBundle.continuous_proj _ _ + have he := (contMDiff_riemannianExp (n := n) (M := M)).continuous + exact (((continuous_cTransform hv).comp hp).add + (((hp.dist he).pow 2).div_const 2)).add (hv.comp he) + exact (isCompact_total_minimizingVectors (n := n) (M := M)).inter_right + (isClosed_eq hc continuous_const) + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma active_hull_norm_le_diam {v : M → ℝ} {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) : + ‖p‖≤Metric.diam (univ : Set M) := by + have hs : activeLogs (n := n) v x ⊆ + Metric.closedBall (0 : TangentSpace 𝓘(ℝ,Model n) x) (Metric.diam (univ : Set M)) := by + intro q hq + rw [Metric.mem_closedBall,dist_zero_right,←hq.1] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ _) (mem_univ _) + simpa only [Metric.mem_closedBall,dist_zero_right] using + (convexHull_min hs (convex_closedBall _ _)) hp + +lemma exists_uniform_short_contraction_into_ID (D : ℝ) : + ∃ τ>0, τ<1 ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ‖p‖≤D → ∀ t : ℝ, 0≤t → t≤τ → t • p ∈ injectivityDomain x := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + have hK := isCompact_bundle_disk (F := Model n) + (E := fun x : M => TangentSpace 𝓘(ℝ,Model n) x) D + have H : ∀ᶠ t : ℝ in 𝓝 0, ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + ‖z.2‖≤D → t • z.2 ∈ injectivityDomain z.1 := by + apply hK.eventually_forall_of_forall_eventually + intro z hz + have ho := (isOpen_total_injectivityDomain (n := n) (M := M)).preimage + (contMDiff_tangentScale (E := Model n) (M := M)).continuous + apply ho.mem_nhds + change (0:ℝ) • z.2 ∈ injectivityDomain z.1 + simpa only [zero_smul] using zero_mem_injectivityDomain (n := n) z.1 + obtain ⟨δ,hδ,Hδ⟩ := Metric.eventually_nhds_iff.mp H + obtain ⟨τ,hτ,hτm⟩ := exists_between (lt_min hδ (show (0:ℝ)<1 by norm_num)) + refine ⟨τ,hτ,(lt_min_iff.mp hτm).2,?_⟩ + intro x p hp t ht htτ + exact Hδ (by simpa only [Real.dist_eq,sub_zero,abs_of_nonneg ht] using + htτ.trans_lt (lt_min_iff.mp hτm).1) ⟨x,p⟩ hp + +lemma exists_uniform_short_active_hull_contraction : + ∃ τ>0, τ<1 ∧ ∀ v : M → ℝ, ∀ x : M, + ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + ∀ t : ℝ, 0≤t → t≤τ → t • p ∈ injectivityDomain x := by + obtain ⟨τ,hτ,hτ1,H⟩ := exists_uniform_short_contraction_into_ID (n := n) (M := M) + (Metric.diam (univ : Set M)) + exact ⟨τ,hτ,hτ1,fun _ x p hp => H x p (active_hull_norm_le_diam hp)⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveDifferentiability.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveDifferentiability.lean new file mode 100644 index 0000000000000000000000000000000000000000..141c732f36e338740ef0987f5f67427680bfdcf0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveDifferentiability.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull +import OAI.Analysis.BiholderTransport.Coordinates.LocalMetricCharts + +namespace OAI + +noncomputable section +open Set Filter MeasureTheory Manifold Bundle +open scoped ENNReal NNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma activeLog_derivative_eq {v : M → ℝ} (hv : Continuous v) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ activeLogs v x) + {D : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ} + (hD : HasFDerivAt (fun h => cTransform v (riemannianExp x h)) D 0) : + D = innerSL ℝ p := by + have hID := contracted_minimizer_mem_injectivityDomain hp.1 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let f := fun h : TangentSpace 𝓘(ℝ,Model n) x => + cTransform v (riemannianExp x h) + 2 * normalCost x ((1/2:ℝ) • p) h + have hmin : IsLocalMin f 0 := by + apply Filter.Eventually.of_forall + intro h + have hh := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (riemannianExp x h) + dsimp [f,normalCost] + rw [riemannianExp_zero] + linarith + have hf : HasFDerivAt f (D - innerSL ℝ p) 0 := by + apply (hD.add ((normalCost_hasFDerivAt_zero hID).const_mul 2)).congr_fderiv + ext h + simp only [_root_.add_apply,_root_.sub_apply, + _root_.smul_apply,innerSL_apply_apply,inner_neg_left, + real_inner_smul_left,smul_eq_mul] + ring + exact sub_eq_zero.mp (hmin.hasFDerivAt_eq_zero hf) + +lemma activeLogs_subsingleton_of_mdifferentiable {v : M → ℝ} (hv : Continuous v) + {x : M} (hD : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) : + (activeLogs (n := n) v x).Subsingleton := by + have hD' : DifferentiableAt ℝ (fun h : TangentSpace 𝓘(ℝ,Model n) x => cTransform v (riemannianExp x h)) 0 := by + have he := ((contMDiff_riemannianExp_fiber (n := n) x 0).mdifferentiableAt (by simp)) + have hD0 : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) + (riemannianExp (n := n) x 0) := by simpa only [riemannianExp_zero] using hD + exact (hD0.comp 0 he).differentiableAt + intro p hp q hq + have hh := (activeLog_derivative_eq hv hp hD'.hasFDerivAt).symm.trans + (activeLog_derivative_eq hv hq hD'.hasFDerivAt) + apply ext_inner_right ℝ + intro h + exact congrArg (fun D : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => D h) hh + +lemma contact_singleton_of_mdifferentiable {v : M → ℝ} (hv : Continuous v) + {x : M} (hD : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {y z : M} (hy : contactGap (cTransform v) v x y = 0) + (hz : contactGap (cTransform v) v x z = 0) : y = z := by + obtain ⟨p,hp,hep⟩ := exists_minimizing_vector (n := n) x y + obtain ⟨q,hq,heq⟩ := exists_minimizing_vector (n := n) x z + have hp' : p ∈ activeLogs v x := ⟨hp,by simpa only [hep] using hy⟩ + have hq' : q ∈ activeLogs v x := ⟨hq,by simpa only [heq] using hz⟩ + have he := activeLogs_subsingleton_of_mdifferentiable hv hD hp' hq' + exact hep.symm.trans ((congrArg (riemannianExp x) he).trans heq) + +variable [MeasurableSpace M] [BorelSpace M] + +lemma lipschitz_ae_mdifferentiable_metricVolume {u : M → ℝ} {K : ℝ≥0} + (hu : LipschitzWith K u) : + ∀ᵐ x ∂(metricVolume (M := M) n), MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) u x := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + have hh := lipschitz_ae_mdifferentiable (E := Model n) hu + have hh' : ∀ᵐ x ∂(Measure.hausdorffMeasure (n : ℝ) : Measure M), + MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) u x := by + simpa [Model] using hh + exact Measure.smul_absolutelyContinuous.ae_le hh' + +lemma cTransform_ae_singleton_contacts [Nonempty M] {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ x ∂(metricVolume (M := M) n), + ∀ y z : M, contactGap (cTransform v) v x y = 0 → + contactGap (cTransform v) v x z = 0 → y = z := by + have hlip := cTransform_lipschitz hv (D := ⟨Metric.diam (univ : Set M),Metric.diam_nonneg⟩) + (fun x y => Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y)) + filter_upwards [lipschitz_ae_mdifferentiable_metricVolume (n := n) hlip] with x hx + exact fun y z hy hz => contact_singleton_of_mdifferentiable hv hx hy hz + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHull.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..517d110dbe887028607603ef3fc279c23b79024e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHull.lean @@ -0,0 +1,246 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ActiveLocalGrowth + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def activeLogs (v : M → ℝ) (x : M) : Set (TangentSpace 𝓘(ℝ,Model n) x) := + {p | p ∈ minimizingVectors x ∧ contactGap (cTransform v) v x (riemannianExp x p)=0} + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma nonempty_activeLogs {v : M → ℝ} (hv : Continuous v) (x : M) : + (activeLogs (n := n) v x).Nonempty := by + let : Nonempty M := ⟨x⟩ + obtain ⟨y,hy⟩ := cTransform_gap_zero hv x + obtain ⟨p,hp,he⟩ := exists_minimizing_vector (n := n) x y + exact ⟨p,hp,by simpa only [he] using hy⟩ + +lemma isCompact_activeLogs {v : M → ℝ} (hv : Continuous v) (x : M) : + IsCompact (activeLogs (n := n) v x) := by + have hc : Continuous (fun p : TangentSpace 𝓘(ℝ,Model n) x => + contactGap (cTransform v) v x (riemannianExp x p)) := by + exact (continuous_const.add ((continuous_cost_right x).comp (continuous_riemannianExp x))).add + (hv.comp (continuous_riemannianExp x)) + exact (isCompact_minimizingVectors x).inter_right (isClosed_eq hc continuous_const) + +lemma WeakMTW.active_hull_local_growth (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {t : ℝ} (ht : 00, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + b*‖h‖^2 ≤ cTransform v (riemannianExp x h)-cTransform v x+ + (cost (riemannianExp x h) (riemannianExp x (t • p))- + cost x (riemannianExp x (t • p)))/t := by + obtain ⟨ι,inst,z,w,hz,_,hw,hsum,heq⟩ := eq_pos_convex_span_of_mem_convexHull hp + let : Fintype ι := inst + have : Nonempty ι := by + by_contra h + have : IsEmpty ι := not_nonempty_iff.mp h + simp at hsum + have hsub : convexHull ℝ (range z) ⊆ convexHull ℝ (activeLogs (n := n) v x) := convexHull_mono hz + have H := hmtw.active_local_growth hv z w hw hsum (fun i => (hz (mem_range_self i)).1) + (fun i => (hz (mem_range_self i)).2) ht ht1 (fun q hq => hID q (hsub hq)) + simpa only [heq] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHullUniform.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHullUniform.lean new file mode 100644 index 0000000000000000000000000000000000000000..a926ea8f365082abf63e5328670e2fc789ee4ce2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveHullUniform.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveUniformGrowth +import OAI.Analysis.BiholderTransport.Regularity.FiniteSimplexRepresentation + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +section +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma movingNormal_chart {a x : M} (hx : x ∈ (extChartAt 𝓘(ℝ,Model n) a).source) + (p : TangentSpace 𝓘(ℝ,Model n) x) : + movingNormal a (extChartAt 𝓘(ℝ,Model n) a x, + tangentCoordChange 𝓘(ℝ,Model n) x a x p) = riemannianExp x p := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hs : (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) ∈ χ.source := + (tangent_chart_source_iff _ _).mpr hx + change riemannianExp (χ.symm (χ ⟨x,p⟩)).1 (χ.symm (χ ⟨x,p⟩)).2 = _ + rw [χ.left_inv hs] + +lemma movingNormal_trivialization {a x : M} + (hx : x ∈ (extChartAt 𝓘(ℝ,Model n) a).source) + (p : TangentSpace 𝓘(ℝ,Model n) x) : + movingNormal a (extChartAt 𝓘(ℝ,Model n) a x, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p) = + riemannianExp x p := by + have hx' : x ∈ (chartAt (Model n) a).source := by simpa only [extChartAt_source] using hx + rw [TangentBundle.continuousLinearMapAt_trivializationAt_eq_core hx'] + exact movingNormal_chart hx p + +end + +lemma WeakMTW.active_hull_uniform_strict_growth + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {a : M} {K : Set M} (hK : IsCompact K) + (hKa : K ⊆ (extChartAt 𝓘(ℝ,Model n) a).source) + {T : ℝ} (hT : T < 1) + (hID : ∀ x ∈ K, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + ∀ t ∈ Icc (0:ℝ) T, t • p ∈ injectivityDomain x) : + ∀ᶠ h : Model n in 𝓝 0, ∀ x ∈ K, + ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), ∀ t ∈ Icc (0:ℝ) T, + h ≠ 0 → + 0 < t * (cTransform v (movingNormal a (extChartAt 𝓘(ℝ,Model n) a x,h)) - cTransform v x) + + cost (movingNormal a (extChartAt 𝓘(ℝ,Model n) a x,h)) (riemannianExp x (t • p)) - + cost x (riemannianExp x (t • p)) := by + classical + let k := Module.finrank ℝ (Model n) + 1 + have H : ∀ᶠ h : Model n in 𝓝 0, ∀ m ∈ Finset.Icc 1 k, + ∀ q ∈ activeConfiguration v a K T (Fin m), h ≠ 0 → + 0 < q.2.2 * (cTransform v (movingNormal a (q.1.1,h)) - + cTransform v ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + + movingNormalCost a q.1.1 (q.2.2 • ∑ i, q.2.1 i • q.1.2 i) h - + movingNormalCost a q.1.1 (q.2.2 • ∑ i, q.2.1 i • q.1.2 i) 0 := by + rw [Filter.eventually_all_finset] + intro m hm + have hm0 : 0 < m := (Finset.mem_Icc.mp hm).1 + let : Nonempty (Fin m) := ⟨⟨0,hm0⟩⟩ + obtain ⟨b,hb,Hb⟩ := hmtw.active_configurations_uniform_growth + (ι := Fin m) hv hK hKa hT hID + filter_upwards [Hb] with h hh q hq hh0 + exact (mul_pos hb (sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hh0))).trans_le (hh q hq) + filter_upwards [H] with h hh x hx p hp t ht hh0 + let b := extChartAt 𝓘(ℝ,Model n) a x + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x + let S := L '' activeLogs (n := n) v x + have hp' : L p ∈ convexHull ℝ S := by + change L p ∈ convexHull ℝ (L.toLinearMap '' activeLogs v x) + rw [←L.toLinearMap.image_convexHull] + exact ⟨p,hp,rfl⟩ + obtain ⟨m,hm0,hmk,z,w,hz,hw,hsum,hmean⟩ := finite_simplex_representation hp' + let q : EnvelopeData (Model n) (Fin m) := ((b,z),(w,t)) + have hq : q ∈ activeConfiguration v a K T (Fin m) := by + refine ⟨?_,hw,hsum,ht⟩ + intro i + obtain ⟨r,hr,hri⟩ := hz i + refine ⟨(⟨x,r⟩ : TangentBundle 𝓘(ℝ,Model n) M),⟨hr,hx⟩,?_⟩ + have hLr : L r = tangentCoordChange 𝓘(ℝ,Model n) x a x r := by + dsimp only [L] + rw [TangentBundle.continuousLinearMapAt_trivializationAt_eq_core + (show x ∈ (chartAt (Model n) a).source by simpa only [extChartAt_source] using hKa hx)] + rfl + change (b,tangentCoordChange 𝓘(ℝ,Model n) x a x r) = (b,z i) + rw [←hLr,hri] + have hstrict := hh m (Finset.mem_Icc.mpr ⟨hm0,hmk⟩) q hq hh0 + have hbase : (extChartAt 𝓘(ℝ,Model n) a).symm b = x := + (extChartAt 𝓘(ℝ,Model n) a).left_inv (hKa hx) + have hy : movingNormal a (b,t • ∑ i, w i • z i) = riemannianExp x (t • p) := by + rw [hmean,←map_smul] + exact movingNormal_trivialization (hKa hx) (t • p) + have hx0 : movingNormal a (b,0) = x := by + rw [movingNormal_zero ((extChartAt 𝓘(ℝ,Model n) a).map_source (hKa hx)),hbase] + simpa only [q,movingNormalCost,hbase,hy,hx0,b] using hstrict + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveUniformGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveUniformGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..845b2d2746aa6c23f982e390502a3c565c9ca000 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActiveUniformGrowth.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CompactConfigurations + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def activeCoordinates (v : M → ℝ) (a : M) (K : Set M) : Set (Model n × Model n) := + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)) '' + {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ activeLogs v z.1 ∧ z.1 ∈ K} + +def activeConfiguration (v : M → ℝ) (a : M) (K : Set M) (T : ℝ) (ι : Type*) [Fintype ι] := + {q : EnvelopeData (Model n) ι | (∀ i, (q.1.1,q.1.2 i) ∈ activeCoordinates v a K) ∧ + (∀ i, 0 ≤ q.2.1 i) ∧ (∑ i, q.2.1 i = 1) ∧ q.2.2 ∈ Icc 0 T} + +lemma WeakMTW.active_configurations_uniform_growth + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {a : M} {K : Set M} (hK : IsCompact K) + (hKa : K ⊆ (extChartAt 𝓘(ℝ,Model n) a).source) + {ι : Type*} [Fintype ι] [Nonempty ι] {T : ℝ} (hT : T < 1) + (hID : ∀ x ∈ K, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + ∀ t ∈ Icc (0:ℝ) T, t • p ∈ injectivityDomain x) : + ∃ b > 0, ∀ᶠ h : Model n in 𝓝 0, + ∀ q ∈ activeConfiguration v a K T ι, + b * ‖h‖^2 ≤ q.2.2 * + (cTransform v (movingNormal a (q.1.1,h)) - + cTransform v ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) + + movingNormalCost a q.1.1 (q.2.2 • ∑ i, q.2.1 i • q.1.2 i) h - + movingNormalCost a q.1.1 (q.2.2 • ∑ i, q.2.1 i • q.1.2 i) 0 := by + classical + obtain ⟨s,hTs,hs1⟩ := exists_between (max_lt (show (0:ℝ)<1 by norm_num) hT) + have hs : 0 < s := (le_max_left 0 T).trans_lt hTs + have hTs' : T < s := (le_max_right 0 T).trans_lt hTs + let Q := activeConfiguration (n := n) v a K T ι + have hQ : IsCompact Q := compact_common_base_configurations + (isCompact_active_coordinates hv hK hKa) T + let : CompactSpace Q := isCompact_iff_compactSpace.mp hQ + have hmem (q : Q) (i : ι) := mem_active_coordinates hKa (q.2.1 i) + have hbase (q : Q) : q.1.1.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target := + (hmem q (Classical.arbitrary ι)).1 + have H := hmtw.compact_scaled_envelope_growth a s hs hs1 + (fun q : Q => q.1) continuous_subtype_val hbase + (fun q i => q.2.2.1 i) (fun q => q.2.2.2.1) + (fun q => q.2.2.2.2.1) (fun q => q.2.2.2.2.2.trans_lt hTs') + (fun q i => (hmem q i).2.1.1) (fun q p hp => hID _ + (hmem q (Classical.arbitrary ι)).2.2 p + ((convexHull_mono (by rintro _ ⟨i,rfl⟩; exact (hmem q i).2.1)) hp) + _ q.2.2.2.2) + obtain ⟨b,hb,H⟩ := H + refine ⟨b,hb,?_⟩ + filter_upwards [H] with h hh q hq + obtain ⟨i,hi⟩ := hh ⟨q,hq⟩ + have hp := (hmem ⟨q,hq⟩ i).2.1 + have hsup := active_split_lower_support hv hp.1 hp.2 hs hs1 + (movingNormal a (q.1.1,h)) + have he : riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (s • chartFiberInverse a q.1.1 (q.1.2 i)) = movingNormal a (q.1.1,s • q.1.2 i) := by + rw [movingNormal_eq (hbase ⟨q,hq⟩),map_smul] + rw [he] at hsup + have hsup' := mul_le_mul_of_nonneg_left hsup hq.2.2.2.1 + unfold scaledNormalEnvelope movingNormalCost at hi + rw [movingNormal_zero (hbase ⟨q,hq⟩)] at hi + change b * ‖h‖^2 ≤ _ + unfold movingNormalCost + rw [movingNormal_zero (hbase ⟨q,hq⟩)] + nlinarith [show q.2.2 * (-(cost (movingNormal a (q.1.1,h)) + (movingNormal a (q.1.1,s • q.1.2 i)) - + cost ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (movingNormal a (q.1.1,s • q.1.2 i))) / s) = + -(q.2.2 / s) * (cost (movingNormal a (q.1.1,h)) + (movingNormal a (q.1.1,s • q.1.2 i)) - + cost ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1) + (movingNormal a (q.1.1,s • q.1.2 i))) by ring] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ActualLowerTestBound.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActualLowerTestBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..45bd9c41510f7d38ac649ec3afce73604bd463ba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ActualLowerTestBound.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ContactRelationChart +import OAI.Analysis.BiholderTransport.Contact.LowerTestContact + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section ActualLowerTestBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.lower_test_chart_det_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} {rho0 rho1 : M → ℝ} (hlam : 0 < lam) (hcap : 0 ≤ cap) + (hrho0 : AdmissibleDensity (metricVolume n) lam cap rho0) + (hrho1 : AdmissibleDensity (metricVolume n) lam cap rho1) + {u v : M →ᵇ ℝ} (hdual : IsCostDualPair u v) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (u,v) ≤ + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (a,b)) + {a b : M} {z : Model n} {r ε : ℝ} {T : Set M} {Da Cb : ℝ≥0} + {φ : Model n → ℝ} {S : Model n → Model n} {J : Model n →L[ℝ] Model n} + (hr : 0 < r) (hε : 0 < ε) + (hchart : Metric.closedBall z r⊆(extChartAt 𝓘(ℝ,Model n) a).target) + (hDa : LipschitzOnWith Da (extChartAt 𝓘(ℝ,Model n) a).symm (Metric.closedBall z r)) + (hCb : LipschitzOnWith Cb (extChartAt 𝓘(ℝ,Model n) b) T) + (hφ : ContinuousOn φ (Metric.closedBall z r)) + (hz : u ((extChartAt 𝓘(ℝ,Model n) a).symm z)=φ z) + (hgap : ∀ w∈Metric.closedBall z r, + ε*dist w z^2≤u ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) + (hSregion : ∀ w∈Metric.ball z r, + S w∈(extChartAt 𝓘(ℝ,Model n) b).target ∧ + (extChartAt 𝓘(ℝ,Model n) b).symm (S w)∈T) + (hmountain : ∀ w∈Metric.ball z r, ∀ q∈Metric.closedBall z r, + φ w+cost ((extChartAt 𝓘(ℝ,Model n) a).symm w) + ((extChartAt 𝓘(ℝ,Model n) b).symm (S w)) ≤ + φ q+cost ((extChartAt 𝓘(ℝ,Model n) a).symm q) + ((extChartAt 𝓘(ℝ,Model n) b).symm (S w))) + (hS : HasStrictFDerivAt S J z) : |J.det| ≤ (cap/lam)*((Cb:ℝ)*(Da:ℝ))^n := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let ψ := extChartAt 𝓘(ℝ,Model n) b + let C := (cap/lam)*((Cb:ℝ)*(Da:ℝ))^n + have hC : 0 ≤ C := by dsimp only [C]; positivity + have hχ : ContinuousOn χ.symm (Metric.closedBall z r) := + (continuousOn_extChartAt_symm a).mono hchart + apply lower_test_abs_det_le (metricVolume n) hr hε hC + (u.continuous.comp_continuousOn hχ) hφ + (fun y => (continuous_cost_left (ψ.symm y)).comp_continuousOn hχ) hz hgap + (R := chartContactRelation a b u v T) ?_ hmountain ?_ hS + · intro w hw q hq hlocal + exact ⟨(hSregion q hq).1,(hSregion q hq).2, + hmtw.chart_local_contact_global u.continuous v.continuous hdual + (hchart (Metric.ball_subset_closedBall hw)) hlocal⟩ + · intro A hA hAball + have HA := chartContactRelation_volume_upper hlam hrho0 hrho1 hdual hmin hA + (fun w hw => hchart (Metric.ball_subset_closedBall (hAball hw))) + (hDa.mono (fun w hw => Metric.ball_subset_closedBall (hAball hw))) hCb + have heq : ENNReal.ofReal lam*ENNReal.ofReal C= + ENNReal.ofReal cap*((Cb:ℝ≥0∞)*(Da:ℝ≥0∞))^n := by + rw [←ENNReal.ofReal_mul hlam.le] + have H : lam*C=cap*((Cb:ℝ)*(Da:ℝ))^n := by dsimp only [C]; field_simp + rw [H,ENNReal.ofReal_mul hcap,ENNReal.ofReal_pow (by positivity), + ENNReal.ofReal_mul (by positivity),ENNReal.ofReal_coe_nnreal,ENNReal.ofReal_coe_nnreal] + apply (ENNReal.mul_le_mul_iff_left (ENNReal.ofReal_ne_zero_iff.mpr hlam) + ENNReal.ofReal_ne_top).mp + rw [←heq] at HA + simpa only [mul_assoc,mul_left_comm,mul_comm] using HA + +end ActualLowerTestBound +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Add.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Add.lean new file mode 100644 index 0000000000000000000000000000000000000000..c82a0eb6dcb2ca67e04abd9056788d3ada16a9a4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Add.lean @@ -0,0 +1,29 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Inner + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma HasQuadraticExpansion.add {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {f g : E → ℝ} {p q : E} {H K : E →L[ℝ] E} + (hf : HasQuadraticExpansion f p H) (hg : HasQuadraticExpansion g q K) : + HasQuadraticExpansion (fun d => f d+g d) (p+q) (H+K) := by + rw [hasQuadraticExpansion_iff_isLittleO] at hf hg ⊢ + convert! hf.add hg using 1 + funext d + simp only [quadraticTaylor,inner_add_left,add_apply] + ring + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/AePullbackLipschitzChart.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/AePullbackLipschitzChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..2dbeee659c0312c1f4a2ee0dc7e078d3a8c1a5de --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/AePullbackLipschitzChart.lean @@ -0,0 +1,77 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.LocalCharts + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Metric +open scoped ENNReal NNReal Topology + +namespace WeakMTWTransport + +lemma ae_pullback_of_lipschitz_chart_inverse {n : ℕ} {M : Type*} + [MetricSpace M] [MeasurableSpace M] [BorelSpace M] + (d : PartialEquiv M (Model n)) {G : Set M} (hGm : MeasurableSet G) + (hGs : G⊆d.source) (hIm : MeasurableSet (d '' G)) + {D : ℝ≥0} (hdi : LipschitzOnWith D d.symm (d '' G)) + {P : Model n → Prop} (hP : ∀ᵐ z ∂volume.restrict (d '' G), P z) : + ∀ᵐ x ∂(metricVolume n).restrict G, P (d x) := by + let N := {z | z∈d '' G ∧ ¬P z} + have hN : volume N=0 := by + have H := ae_iff.mp ((ae_restrict_iff' hIm).mp hP) + apply measure_mono_null _ H + exact fun z hz h => hz.2 (h hz.1) + have hNsub : N⊆d '' G := fun z hz => hz.1 + have hNi : metricVolume n (d.symm '' N)=0 := by + apply le_antisymm _ (show (0:ℝ≥0∞)≤_ from zero_le) + have H := metricVolume_lipschitz_image_le_nat (n := n) (hdi.mono hNsub) + rw [metricVolume_model,hN,mul_zero] at H + exact H + rw [ae_restrict_iff' hGm] + apply ae_iff.mpr + apply measure_mono_null _ hNi + intro x hx + have hxG : x∈G := by by_contra h; exact hx (fun hh => False.elim (h hh)) + have hn : ¬P (d x) := fun h => hx (fun _ => h) + exact ⟨d x,⟨⟨x,hxG,rfl⟩,hn⟩,d.left_inv (hGs hxG)⟩ + +lemma ae_chart_jacobian_bounds {n : ℕ} {M : Type*} + [MetricSpace M] [MeasurableSpace M] [BorelSpace M] + (d e : PartialEquiv M (Model n)) {G : Set M} {T : M → M} + (hGm : MeasurableSet G) (hIm : MeasurableSet (d '' G)) + (hGs : G⊆d.source) (hTs : T '' G⊆e.source) (hTi : InjOn T G) + {C D H K : ℝ≥0} (hC : 0 a/((C:ℝ≥0∞)^n*(K:ℝ≥0∞)^n)≤ENNReal.ofReal |(f' z).det| ∧ + ENNReal.ofReal |(f' z).det|≤(H:ℝ≥0∞)^n*b*(D:ℝ≥0∞)^n) + apply ae_jacobian_bounds_of_image_mass volume hIm hf' + · rintro z ⟨x,hx,rfl⟩ w ⟨y,hy,rfl⟩ heq + simp only [Function.comp_apply,d.left_inv (hGs hx),d.left_inv (hGs hy)] at heq + have hTxs : T x∈e.source := hTs ⟨x,hx,rfl⟩ + have hTys : T y∈e.source := hTs ⟨y,hy,rfl⟩ + exact congrArg d (hTi hx hy (e.injOn hTxs hTys heq)) + · exact fun A hA hAs => image_mass_in_bilipschitz_coordinates d e hGs hTs + hC hK hd hdi he hei hmass hA hAs + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartBaseline.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartBaseline.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ac2944fbdfa01f257d98e6f606e7592597e269a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartBaseline.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.NormLower +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateTrueLog +import OAI.Analysis.BiholderTransport.LinearAlgebra.BranchDividedBaseline + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section BranchChartBaseline +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma exists_branch_chart_baseline {a:M} {r : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈minimizingVectors a) {G : M×M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (a,riemannianExp a r)) + (hagree : ∀ᶠ z in 𝓝 (⟨a,r⟩ : TangentBundle 𝓘(ℝ,Model n) M), + z.2∈injectivityDomain z.1 → + (fun q:M×M => cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) + {l:ℝ} (hl : 1 G ((extChartAt 𝓘(ℝ,Model n) a).symm w,riemannianExp a r) + ContDiffAt ℝ 2 c z ∧ + ∃ L:Model n →L[ℝ] ℝ, fderiv ℝ c z= -l • L ∧ + chartGradientVector a z L∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm z) ∧ + ∃ m>0,∀ d:Model n,m*‖d‖^2≤ + l*fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,L)))) z d d- + fderiv ℝ (fderiv ℝ c) z d d := by + dsimp only + let z := extChartAt 𝓘(ℝ,Model n) a a + let V := TangentSpace 𝓘(ℝ,Model n) a + let c := fun w:Model n => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,riemannianExp a r) + let b := riemannianExp a (l⁻¹ • r) + let cN : V → ℝ := fun v => G (riemannianExp a v,riemannianExp a r) + let cT := normalCost a (l⁻¹ • r) + have hlp : 0 contracted_minimizer_mem_injectivityDomain hr hs.1 hs.2) + have hcN : ContDiffAt ℝ 2 cN 0 := by + have hh : ContDiffAt ℝ ∞ cN 0 := by simpa only [cN,one_smul] using hCJ.1 + exact hh.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hcND : fderiv ℝ cN 0=innerSL ℝ (-r) := by simpa only [cN,one_smul] using hCJ.2.1.fderiv + have hcT : ContDiffAt ℝ 2 cT 0 := + (normalCost_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + obtain ⟨L,hLreg,hLb,hLD⟩ := exists_chart_covector_for_log hp + obtain ⟨e,he,he0,hei,hi⟩ := exists_smooth_chart_fiber_log (a := a) + (zero_mem_injectivityDomain (n := n) a) + (by simpa only [riemannianExp_zero] using mem_extChartAt_source (I := 𝓘(ℝ,Model n)) a) + simp only [riemannianExp_zero] at he he0 hei hi + change ContDiffAt ℝ ∞ e z at he + change e z=0 at he0 + change Function.Injective (fderiv ℝ e z) at hi + have he2 : ContDiffAt ℝ 2 e z := he.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + obtain ⟨k,hk,Hk⟩ := exists_norm_sq_lower_of_injective (fderiv ℝ e z) hi + have hce : c =ᶠ[𝓝 z] (fun w => cN (e w)) := by + filter_upwards [hei] with w hw + simp only [c,cN,hw] + have hTe : chartCost a b =ᶠ[𝓝 z] (fun w => cT (e w)) := by + filter_upwards [hei] with w hw + simp only [cT,b,normalCost,chartCost,hw] + have hc : ContDiffAt ℝ 2 c z := ((he0.symm ▸ hcN).comp z he2).congr_of_eventuallyEq hce + have hT : ContDiffAt ℝ 2 (chartCost a b) z := ((he0.symm ▸ hcT).comp z he2).congr_of_eventuallyEq hTe + have hstat : fderiv ℝ (fun v => l*cT v-cN v) 0=0 := by + rw [fderiv_fun_sub ((hcT.differentiableAt (by norm_num)).const_mul _) (hcN.differentiableAt (by norm_num))] + change fderiv ℝ (l • cT) 0-fderiv ℝ cN 0=0 + rw [fderiv_const_smul_field,Pi.smul_apply,hcND,(normalCost_hasFDerivAt_zero hp).fderiv] + simp only [map_neg,map_smul,smul_neg,smul_smul,mul_inv_cancel₀ hlp.ne',one_smul,sub_self] + have hstatC : fderiv ℝ (fun w => l*chartCost a b w-c w) z=0 := by + have H : (fun w => l*chartCost a b w-c w)=ᶠ[𝓝 z] (fun w => l*cT (e w)-cN (e w)) := by + filter_upwards [hTe,hce] with w hw hw' + rw [hw,hw'] + rw [H.fderiv_eq,fderiv_fun_comp z (g := fun v:V => l*cT v-cN v) + (by simpa only [he0] using (((contDiffAt_const (c := l)).mul hcT).sub hcN).differentiableAt (by norm_num)) + (he2.differentiableAt (by norm_num)),he0,hstat,ContinuousLinearMap.zero_comp] + have hcD : fderiv ℝ c z= -l • L := by + rw [fderiv_fun_sub ((hT.differentiableAt (by norm_num)).const_mul _) (hc.differentiableAt (by norm_num))] at hstatC + change fderiv ℝ (l • chartCost a b) z-fderiv ℝ c z=0 at hstatC + rw [fderiv_const_smul_field,Pi.smul_apply,hLD.fderiv] at hstatC + calc + _ = l • (-L) := (sub_eq_zero.mp hstatC).symm + _ = -l • L := by ext d; simp only [smul_apply,neg_apply,smul_eq_mul,mul_neg,neg_mul] + refine ⟨hc,L,hcD,hLreg,m*k,mul_pos hm hk,?_⟩ + intro d + have HF := second_fderiv_comp_stationary (f := fun v => l*cT v-cN v) (g := e) + (he0.symm ▸ (contDiffAt_const.mul hcT).sub hcN) he2 (by rwa [he0]) d d + rw [he0,second_fderiv_sub (contDiffAt_const.mul hcT) hcN,second_fderiv_const_mul] at HF + have H : (fun w => l*chartCost a b w-c w)=ᶠ[𝓝 z] (fun w => l*cT (e w)-cN (e w)) := by + filter_upwards [hTe,hce] with w hw hw' + rw [hw,hw'] + have HH := congrArg (fun A:Model n →L[ℝ] Model n →L[ℝ] ℝ => A d d) H.fderiv.fderiv_eq + rw [second_fderiv_sub (contDiffAt_const.mul hT) hc,second_fderiv_const_mul] at HH + rw [hLb,HH,HF] + have Hb := Hm (fderiv ℝ e z d) + rw [hessianValue_eq_normalHessian hp] at Hb + change m*‖fderiv ℝ e z d‖^2≤ + fderiv ℝ (fderiv ℝ cT) 0 (fderiv ℝ e z d) (fderiv ℝ e z d)/l⁻¹- + fderiv ℝ (fderiv ℝ cN) 0 (fderiv ℝ e z d) (fderiv ℝ e z d) at Hb + rw [div_inv_eq_mul] at Hb + nlinarith only [Hb,mul_le_mul_of_nonneg_left (Hk d) hm.le] + +end BranchChartBaseline +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartJets.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..c76d6b10b923ffc079fd1cdfac2af4bbc891aa77 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchChartJets.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section BranchChartJets +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma branch_chart_jet_continuous {G : M×M → ℝ} {a y : M} {z : Model n} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + G ((extChartAt 𝓘(ℝ,Model n) a).symm z,y)) : + ContinuousAt (fun q : Model n×M => fderiv ℝ (fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2)) q.1) (z,y) ∧ + ContinuousAt (fun q : Model n×M => fderiv ℝ (fderiv ℝ ((fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2)))) q.1) (z,y) ∧ + ∀ᶠ q : Model n×M in 𝓝 (z,y), ContDiffAt ℝ 2 ((fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2))) q.1 := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let d := extChartAt 𝓘(ℝ,Model n) y + let F : Model n → Model n → ℝ := fun b z => G (χ.symm z,d.symm b) + have hdy : d.symm (d y)=y := d.left_inv (mem_extChartAt_source y) + have hA : ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×Model n => χ.symm q.2) (d y,z) := + ((contMDiffWithinAt_extChartAt_symm_target a hz).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds hz)).comp (d y,z) contDiffAt_snd.contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×Model n => d.symm q.1) (d y,z) := + ((contMDiffWithinAt_extChartAt_symm_target y + (d.map_source (mem_extChartAt_source y))).contMDiffAt + ((isOpen_extChartAt_target y).mem_nhds (d.map_source (mem_extChartAt_source y)))).comp + (d y,z) contDiffAt_fst.contMDiffAt + have hF : ContDiffAt ℝ ∞ (Function.uncurry F) (d y,z) := by + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + G (χ.symm z,d.symm (d y)) := by simpa only [hdy] using hc + exact (hc'.comp (d y,z) (hA.prodMk hB)).contDiffAt + have hchart : ContinuousAt d y := continuousAt_extChartAt y + have hq : ContinuousAt (fun q : Model n×M => (d q.2,q.1)) (z,y) := + (hchart.comp (x := (z,y)) (f := fun q : Model n×M => q.2) continuousAt_snd).prodMk continuousAt_fst + have hnear : ∀ᶠ q : Model n×M in 𝓝 (z,y), q.2∈d.source := + continuousAt_snd.preimage_mem_nhds (extChartAt_source_mem_nhds y) + have heq : ∀ᶠ q : Model n×M in 𝓝 (z,y), F (d q.2)=(fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2)) := by + filter_upwards [hnear] with q hq + funext w + dsimp [F,χ] + rw [d.left_inv hq] + refine ⟨?_,?_,?_⟩ + · have H := (ContDiffAt.partial_snd_fderiv hF).continuousAt.comp + (x := (z,y)) (f := fun q : Model n×M => (d q.2,q.1)) hq + apply H.congr_of_eventuallyEq + filter_upwards [heq] with q hq + change fderiv ℝ (fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2)) q.1 = + fderiv ℝ (F (d q.2)) q.1 + rw [hq] + · have H := (ContDiffAt.partial_snd_fderiv_two hF).continuousAt.comp + (x := (z,y)) (f := fun q : Model n×M => (d q.2,q.1)) hq + apply H.congr_of_eventuallyEq + filter_upwards [heq] with q hq + change fderiv ℝ (fderiv ℝ ((fun w => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,q.2)))) q.1 = + fderiv ℝ (fderiv ℝ (F (d q.2))) q.1 + rw [hq] + · have H := (hF.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + filter_upwards [hq.tendsto.eventually H,heq] with q hq he + have H' := hq.comp q.1 (contDiffAt_const.prodMk contDiffAt_id) + change ContDiffAt ℝ 2 (F (d q.2)) q.1 at H' + rw [he] at H' + exact H' + +end BranchChartJets +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchInverse.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..64fa17a9a6f1cb68b2e6634056b8ec2583ca2438 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchInverse.lean @@ -0,0 +1,315 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugacy + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_joint_exp_inverse_of_nonconjugate (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + ∃ e : OpenPartialHomeomorph (Model n × Model n) (Model n × Model n), + (e : Model n × Model n → Model n × Model n) = + (fun q => (q.1, d (riemannianExp (χ.symm q).1 (χ.symm q).2))) ∧ + χ z ∈ e.source ∧ e.source ⊆ χ.target ∧ + (∀ q ∈ e.source, riemannianExp (χ.symm q).1 (χ.symm q).2 ∈ d.source) ∧ + ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + let f : Model n × Model n → Model n := fun q => + d (riemannianExp (χ.symm q).1 (χ.symm q).2) + let S := χ.target ∩ (fun q => riemannianExp (χ.symm q).1 (χ.symm q).2) ⁻¹' d.source + have hχz : χ z ∈ χ.target := χ.map_source (mem_extChartAt_source z) + have hχinv : χ.symm (χ z)=z := χ.left_inv (mem_extChartAt_source z) + have hχ : ContMDiffOn 𝓘(ℝ,Model n × Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ χ.symm χ.target := + contMDiffOn_extChartAt_symm z + have hE : ContMDiffOn 𝓘(ℝ,Model n × Model n) 𝓘(ℝ,Model n) ∞ + (fun q => riemannianExp (χ.symm q).1 (χ.symm q).2) χ.target := + contMDiff_riemannianExp.comp_contMDiffOn hχ + have hS : IsOpen S := + hE.continuousOn.isOpen_inter_preimage (isOpen_extChartAt_target z) (isOpen_extChartAt_source _) + have hzS : χ z ∈ S := ⟨hχz,by change riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2 ∈ d.source; rw [hχinv]; exact mem_extChartAt_source _⟩ + have hd : ContMDiffOn 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d d.source := by + simpa only [d,extChartAt_source] using (contMDiffOn_extChartAt (I := 𝓘(ℝ,Model n)) (n := ∞) (x := riemannianExp z.1 z.2)) + have hf : ContDiffOn ℝ ∞ f S := + (hd.comp (hE.mono (inter_subset_left)) (fun q hq => hq.2)).contDiffOn + let τ := trivializationAt (Model n) (fun b : M => TangentSpace 𝓘(ℝ,Model n) b) z.1 + let L : TangentSpace 𝓘(ℝ,Model n) z.1 ≃L[ℝ] Model n := + τ.continuousLinearEquivAt ℝ z.1 (mem_baseSet_trivializationAt (Model n) _ z.1) + have hχsecond : (χ z).2=L z.2 := rfl + have hχfiber (w : Model n) : χ.symm ((χ z).1,w) = + (⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + have hforward : χ (⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M) = ((χ z).1,w) := by + apply Prod.ext + · rfl + · change L (L.symm w)=w + exact L.apply_symm_apply w + rw [←hforward] + apply χ.left_inv + exact (tangent_chart_source_iff z _).mpr (mem_extChartAt_source z.1) + let F : TangentSpace 𝓘(ℝ,Model n) z.1 → Model n := + fun v => d (riemannianExp z.1 v) + have hF : ContDiffAt ℝ ∞ F z.2 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp z.1 z.2) from + contMDiffAt_extChartAt).comp z.2 (contMDiff_riemannianExp_fiber z.1 z.2)).contDiffAt + have hFi : Function.Injective (fderiv ℝ F z.2) := hz + have hpart : (fun w => f ((χ z).1,w)) = F ∘ L.symm := by + funext w + dsimp [f] + rw [hχfiber] + have hpartder : fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2 = + (fderiv ℝ F z.2).comp (L.symm : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) z.1) := by + rw [hpart,hχsecond] + have hF' : HasFDerivAt F (fderiv ℝ F z.2) (L.symm (L z.2)) := by + simpa only [L.symm_apply_apply] using (hF.differentiableAt (by simp)).hasFDerivAt + exact (hF'.comp (L z.2) L.symm.hasFDerivAt).fderiv + have hpi : (fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2).IsInvertible := by + have hi : Function.Injective (fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2) := by + rw [hpartder] + exact hFi.comp L.symm.injective + have hs := LinearMap.injective_iff_surjective.mp hi + exact ⟨ContinuousLinearEquiv.ofBijective _ (LinearMap.ker_eq_bot.mpr hi) + (LinearMap.range_eq_top.mpr hs),rfl⟩ + have hi := first_coordinate_preserving_derivative_invertible + ((hf.contDiffAt (hS.mem_nhds hzS)).differentiableAt (by simp)) hpi + obtain ⟨e,he,hz',heS,heD,heInv⟩ := exists_smooth_local_diffeomorphism hS + (contDiffOn_fst.prodMk hf) hzS hi + exact ⟨e,he,hz',fun q hq => (heS hq).1,fun q hq => (heS hq).2,heD,heInv⟩ + +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_exp_branch (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + ∃ P : M×M → TangentBundle 𝓘(ℝ,Model n) M, + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P + (z.1,riemannianExp z.1 z.2) ∧ + P (z.1,riemannianExp z.1 z.2)=z ∧ + (∀ᶠ r in 𝓝 z, P (r.1,riemannianExp r.1 r.2)=r) ∧ + (∀ᶠ q in 𝓝 (z.1,riemannianExp z.1 z.2), + (P q).1=q.1 ∧ riemannianExp (P q).1 (P q).2=q.2) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let c := extChartAt 𝓘(ℝ,Model n) z.1 + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + let y : M×M := (z.1,riemannianExp z.1 z.2) + let J : M×M → Model n × Model n := fun q => (c q.1,d q.2) + obtain ⟨e,he,hze,_,hend,_,hei⟩ := exists_joint_exp_inverse_of_nonconjugate z hz + have hχz := χ.map_source (mem_extChartAt_source z) + have hχinv : χ.symm (χ z)=z := χ.left_inv (mem_extChartAt_source z) + have hJy : J y = e (χ z) := by + rw [he] + change (c z.1,d (riemannianExp z.1 z.2)) = + ((χ z).1,d (riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2)) + rw [hχinv] + rfl + have hyT : J y ∈ e.target := by + simpa only [hJy] using e.map_source hze + have hiy : e.symm (J y)=χ z := by rw [hJy,e.left_inv hze] + have hJ : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,Model n × Model n) ∞ J y := by + have hc₀ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ c y.1 := contMDiffAt_extChartAt + have hd₀ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y.2 := contMDiffAt_extChartAt + exact (hc₀.comp y contMDiffAt_fst).prodMk_space (hd₀.comp y contMDiffAt_snd) + have hi := (hei.contDiffAt (e.open_target.mem_nhds hyT)).contMDiffAt.comp y hJ + have hc : ContMDiffAt 𝓘(ℝ,Model n × Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ χ.symm + (e.symm (J y)) := + (contMDiffOn_extChartAt_symm z).contMDiffAt + ((isOpen_extChartAt_target z).mem_nhds (by simpa only [hiy] using hχz)) + let P : M×M → TangentBundle 𝓘(ℝ,Model n) M := fun q => χ.symm (e.symm (J q)) + have hP : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P y := + hc.comp y hi + have hPy : P y = z := by dsimp [P]; rw [hiy,hχinv] + refine ⟨P,hP,hPy,?_,?_⟩ + · have hχnear : ∀ᶠ r in 𝓝 z, χ r ∈ e.source := + (show ContinuousAt χ z from continuousAt_extChartAt z).preimage_mem_nhds (e.open_source.mem_nhds hze) + filter_upwards [hχnear,extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z] with r hre hrs + have hJr : J (r.1,riemannianExp r.1 r.2)=e (χ r) := by + rw [he] + change (c r.1,d (riemannianExp r.1 r.2)) = + ((χ r).1,d (riemannianExp (χ.symm (χ r)).1 (χ.symm (χ r)).2)) + rw [χ.left_inv hrs] + rfl + dsimp only [P] + rw [hJr,e.left_inv hre,χ.left_inv hrs] + · have hJnear : ∀ᶠ q in 𝓝 y, J q ∈ e.target := + hJ.continuousAt.preimage_mem_nhds (e.open_target.mem_nhds hyT) + have hcnear : ∀ᶠ q : M×M in 𝓝 y, q.1 ∈ c.source := + (continuous_fst : Continuous (fun q : M×M => q.1)).continuousAt.preimage_mem_nhds + (show c.source ∈ 𝓝 y.1 from extChartAt_source_mem_nhds z.1) + have hdnear : ∀ᶠ q : M×M in 𝓝 y, q.2 ∈ d.source := + (continuous_snd : Continuous (fun q : M×M => q.2)).continuousAt.preimage_mem_nhds + (show d.source ∈ 𝓝 y.2 from extChartAt_source_mem_nhds (riemannianExp z.1 z.2)) + filter_upwards [hJnear,hcnear,hdnear] with q hqJ hqc hqd + have his := e.map_target hqJ + have hmap := e.right_inv hqJ + rw [he] at hmap + constructor + · change (χ.symm (e.symm (J q))).1=q.1 + rw [tangent_chart_symm_base] + have hf := congrArg Prod.fst hmap + change (e.symm (J q)).1=c q.1 at hf + rw [hf,c.left_inv hqc] + · apply d.injOn (hend _ his) hqd + exact congrArg Prod.snd hmap + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchJets.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..994096c5351ad9e432fba783511b1a30a89d1e2e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/BranchJets.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiniteActiveGrowth +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Geodesics.BranchExtension + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cost_branch_normal_jets {x : M} {r : TangentSpace 𝓘(ℝ,Model n) x} + {T : ℝ} (hT : 0 < T) {G : M × M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (x,riemannianExp x (T • r))) + (hagree : ∀ᶠ z in 𝓝 (⟨x,T • r⟩ : TangentBundle 𝓘(ℝ,Model n) M), + z.2 ∈ injectivityDomain z.1 → + (fun q : M × M => cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) + (hID : ∀ t ∈ Ioo (0:ℝ) T, t • r ∈ injectivityDomain x) : + let f := fun h : TangentSpace 𝓘(ℝ,Model n) x => + G (riemannianExp x h,riemannianExp x (T • r)) + ContDiffAt ℝ ∞ f 0 ∧ HasFDerivAt f (innerSL ℝ (-(T • r))) 0 ∧ + ∀ ξ : TangentSpace 𝓘(ℝ,Model n) x, + Tendsto (fun t : ℝ => hessianValue x (t • r) ξ) (𝓝[<] T) + (𝓝 (fderiv ℝ (fderiv ℝ f) 0 ξ ξ)) := by + let F := fun (t : ℝ) (h : TangentSpace 𝓘(ℝ,Model n) x) => + G (riemannianExp x h,riemannianExp x (t • r)) + have hfamily : ContDiffAt ℝ ∞ (Function.uncurry F) (T,0) := smooth_branch_normal_family hG + have hFT : ContDiffAt ℝ ∞ (F T) 0 := hfamily.comp 0 (contDiffAt_const.prodMk contDiffAt_id) + have H : ∀ᶠ t in 𝓝[<] T, t • r ∈ injectivityDomain x ∧ + normalCost x (t • r) =ᶠ[𝓝 0] F t := by + filter_upwards [(cost_branch_normal_eventuallyEq hagree).filter_mono nhdsWithin_le_nhds, + (eventually_gt_nhds hT).filter_mono nhdsWithin_le_nhds,self_mem_nhdsWithin] with t ht ht0 htT + have htID := hID t ⟨ht0,htT⟩ + exact ⟨htID,ht htID⟩ + have hL : ContinuousAt (fun t => fderiv ℝ (F t) 0) T := + (ContDiffAt.partial_snd_fderiv hfamily).continuousAt.comp (f := fun t : ℝ => (t,(0 : TangentSpace 𝓘(ℝ,Model n) x))) + (continuousAt_id.prodMk continuousAt_const) + have hLe : fderiv ℝ (F T) 0 = innerSL ℝ (-(T • r)) := by + have hR : ContinuousAt (fun t : ℝ => innerSL ℝ (-(t • r))) T := by fun_prop + apply tendsto_nhds_unique_of_eventuallyEq (l := 𝓝[<] T) + (hL.tendsto.mono_left nhdsWithin_le_nhds) (hR.tendsto.mono_left nhdsWithin_le_nhds) + filter_upwards [H] with t ht + rw [←ht.2.fderiv_eq] + exact (normalCost_hasFDerivAt_zero ht.1).fderiv + refine ⟨hFT,?_,?_⟩ + · rw [←hLe] + exact (hFT.differentiableAt (by simp)).hasFDerivAt + · intro ξ + have hB : ContinuousAt (fun t => fderiv ℝ (fderiv ℝ (F t)) 0 ξ ξ) T := + (((ContDiffAt.partial_snd_fderiv_two hfamily).continuousAt.comp (f := fun t : ℝ => (t,(0 : TangentSpace 𝓘(ℝ,Model n) x))) + (continuousAt_id.prodMk continuousAt_const)).clm_apply continuousAt_const).clm_apply continuousAt_const + apply (hB.tendsto.mono_left nhdsWithin_le_nhds).congr' + filter_upwards [H] with t ht + rw [hessianValue_eq_normalHessian ht.1] + dsimp only [normalHessian] + rw [ht.2.fderiv.fderiv_eq] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartActiveLimit.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartActiveLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4bf325a25659ff4ea3708e1e5e1157d91996bd4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartActiveLimit.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.GraphInverse +import OAI.Analysis.BiholderTransport.Regularity.ActiveLimit +import OAI.Analysis.BiholderTransport.Coordinates.GraphCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma compact_in_chart_tail {x : ℕ → M} {a y : M} (hx : Tendsto x atTop (𝓝 y)) + (hy : y∈(extChartAt 𝓘(ℝ,Model n) a).source) : + ∃ K : Set M,IsCompact K ∧ K⊆(extChartAt 𝓘(ℝ,Model n) a).source ∧ + ∃ N : ℕ,∀ k,x (k+N)∈K := by + obtain ⟨r,hr,hs⟩ := Metric.isOpen_iff.mp (isOpen_extChartAt_source (I := 𝓘(ℝ,Model n)) a) y hy + have hhalf : 0Metric.ball_subset_closedBall (hN (k+N) (Nat.le_add_left N k))⟩ + +lemma WeakMTW.graph_coordinate_limit_in_chart + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀))) + {a : M} (ha : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + Tendsto (fun k=>graphBaseCoordinate a (q k).1) atTop (𝓝 (graphBaseCoordinate a q₀.1)) ∧ + Tendsto (fun k=>graphVelocityCoordinate a (q k).1) atTop (𝓝 (graphVelocityCoordinate a q₀.1)) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hs : q₀.1∈χ.source := (tangent_chart_source_iff _ _).mpr ha + have H := ((continuousOn_extChartAt _).continuousAt + ((isOpen_extChartAt_source _).mem_nhds hs)).tendsto.comp + (hmtw.graph_points_tendsto hv ht ht1 hz) + exact ⟨H.fst_nhds,H.snd_nhds⟩ + +lemma WeakMTW.active_barycentric_limit_in_chart + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀))) + {a : M} (ha : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) + {K : Set M} (hK : IsCompact K) (hKa : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hqK : ∀ k,(q k).1.1∈K) : + ∃ pj : ℕ → Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃ w : ℕ → Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃ p₀ : Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃ w₀ : Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃ σ : ℕ → ℕ, StrictMono σ ∧ + (∀ k,(∀ i,(graphBaseCoordinate a (q k).1,pj k i)∈activeCoordinates v a K) ∧ + (∀ i,0≤w k i) ∧ ∑ i,w k i=1 ∧ ∑ i,w k i • pj k i=graphVelocityCoordinate a (q k).1) ∧ + Tendsto (pj ∘ σ) atTop (𝓝 p₀) ∧ Tendsto (w ∘ σ) atTop (𝓝 w₀) ∧ + (∀ i,(graphBaseCoordinate a q₀.1,p₀ i)∈activeCoordinates v a K) ∧ (∀ i,0≤w₀ i) ∧ + ∑ i,w₀ i=1 ∧ ∑ i,w₀ i • p₀ i=graphVelocityCoordinate a q₀.1 := by + obtain ⟨hbase,hvel⟩ := hmtw.graph_coordinate_limit_in_chart hv ht ht1 hz ha + have hrep : ∀ k,graphVelocityCoordinate a (q k).1∈convexHull ℝ + {p | (graphBaseCoordinate a (q k).1,p)∈activeCoordinates v a K} := by + intro k + let L : TangentSpace 𝓘(ℝ,Model n) (q k).1.1 →ₗ[ℝ] Model n := + (tangentCoordChange 𝓘(ℝ,Model n) (q k).1.1 a (q k).1.1).toLinearMap + have hh : L (q k).1.2 ∈ L '' convexHull ℝ (activeLogs v (q k).1.1) := + mem_image_of_mem L (normalSubdifferential_subset_active_hull hv _ (q k).2) + rw [L.image_convexHull] at hh + apply convexHull_mono (t := {p | (graphBaseCoordinate a (q k).1,p)∈activeCoordinates v a K}) ?_ hh + rintro p ⟨r,hr,rfl⟩ + exact ⟨⟨(q k).1.1,r⟩,⟨hr,hqK k⟩,rfl⟩ + exact compact_barycentric_limit (isCompact_active_coordinates hv hK hKa) hbase hvel hrep + +lemma WeakMTW.active_barycentric_tail_limit_in_chart + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀))) + {a : M} (ha : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + ∃ K : Set M,IsCompact K ∧ K⊆(extChartAt 𝓘(ℝ,Model n) a).source ∧ + ∃ pj : ℕ → Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃ w : ℕ → Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃ p₀ : Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃ w₀ : Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃ σ : ℕ → ℕ, StrictMono σ ∧ + (∀ k,(∀ i,(graphBaseCoordinate a (q (σ k)).1,pj k i)∈activeCoordinates v a K) ∧ + (∀ i,0≤w k i) ∧ ∑ i,w k i=1 ∧ ∑ i,w k i • pj k i=graphVelocityCoordinate a (q (σ k)).1) ∧ + Tendsto pj atTop (𝓝 p₀) ∧ Tendsto w atTop (𝓝 w₀) ∧ + (∀ i,(graphBaseCoordinate a q₀.1,p₀ i)∈activeCoordinates v a K) ∧ (∀ i,0≤w₀ i) ∧ + ∑ i,w₀ i=1 ∧ ∑ i,w₀ i • p₀ i=graphVelocityCoordinate a q₀.1 := by + have hbase := (FiberBundle.continuous_proj (Model n) + (TangentSpace 𝓘(ℝ,Model n))).tendsto q₀.1 |>.comp + (hmtw.graph_points_tendsto hv ht ht1 hz) + obtain ⟨K,hK,hKs,N,hN⟩ := compact_in_chart_tail hbase ha + have hshift : Tendsto (fun k:ℕ=>k+N) atTop atTop := tendsto_add_atTop_nat N + obtain ⟨pj,w,p₀,w₀,σ,hσ,hs,hp,hw,hact,hn,h1,hb⟩ := + hmtw.active_barycentric_limit_in_chart hv ht ht1 (fun k=>q (k+N)) q₀ + (hz.comp hshift) ha hK hKs hN + exact ⟨K,hK,hKs,pj ∘ σ,w ∘ σ,p₀,w₀,fun k=>σ k+N, + fun i j hij=>Nat.add_lt_add_right (hσ hij) N,fun k=>hs (σ k),hp,hw,hact,hn,h1,hb⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartAlexandrov.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartAlexandrov.lean new file mode 100644 index 0000000000000000000000000000000000000000..38278be6d8725291198118c67b08076ac9807517 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartAlexandrov.lean @@ -0,0 +1,53 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.Measurable +import OAI.Analysis.BiholderTransport.Convexity.TransformSemiconvex + +namespace OAI + +section + +noncomputable section +open Set Filter Metric Manifold Bundle MeasureTheory +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartAlexandrov +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +omit [Nonempty M] in +lemma original_chart_alexandrov_null {u v:M → ℝ} (hu:Continuous u) + (hdual:IsCostDualPair u v) (a:M) : + ∃r>0,∃N:Set (Model n),volume N=0 ∧ + Metric.ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀x∈Metric.ball (extChartAt 𝓘(ℝ,Model n) a a) r,x∉N → + ∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>v ((extChartAt 𝓘(ℝ,Model n) a).symm (x+h))) p A := by + obtain ⟨K,hK,r,hr,ht,hs⟩:=uniform_cTransform_semiconvex (n:=n) a + have H:=ConvexProximal.ae_quadraticExpansion_semiconvex_open K isOpen_ball (hs u hu) volume + rw [←hdual.2] at H + let good:=fun x:Model n=> ∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>v ((extChartAt 𝓘(ℝ,Model n) a).symm (x+h))) p A + let N: Set (Model n):={x | x∈Metric.ball (extChartAt 𝓘(ℝ,Model n) a a) r ∧ ¬good x} + refine ⟨r,hr,N,?_,ht,?_⟩ + · have H':∀ᵐ x:Model n ∂volume,x∉N := H.mono (fun x hx ⟨hb,hbad⟩=>hbad (hx hb)) + rw [ae_iff] at H' + convert H' using 1 + congr 1 + ext x + simp only [Set.mem_ofPred_eq,not_not] + · intro x hx hN + by_contra hn + exact hN ⟨hx,hn⟩ +end ChartAlexandrov +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartCenterGain.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartCenterGain.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec18b67b5a3f09ee5974cc3c926de3d0e4deca8f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartCenterGain.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.TrueCenterGain +import OAI.Analysis.BiholderTransport.Coordinates.ChartTrueCenter + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartCenterGain +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance chartCenterGainFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma exists_chart_true_center_gain : ∃δ>0,∀ᶠ l:ℝ in 𝓝 1,l<1 → 0φ (cTransform u ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c y+h)))) s S → + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0 cost q.1 q.2) ((extChartAt 𝓘(ℝ,Model n) a).symm z,y)) : + ContinuousAt (fun q : Model n×M => fderiv ℝ (fderiv ℝ (chartCost a q.2)) q.1) (z,y) ∧ + ∀ᶠ q : Model n×M in 𝓝 (z,y), ContDiffAt ℝ 2 (chartCost a q.2) q.1 := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let d := extChartAt 𝓘(ℝ,Model n) y + let F : Model n → Model n → ℝ := fun b z => cost (χ.symm z) (d.symm b) + have hdy : d.symm (d y)=y := d.left_inv (mem_extChartAt_source y) + have hA : ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×Model n => χ.symm q.2) (d y,z) := + ((contMDiffWithinAt_extChartAt_symm_target a hz).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds hz)).comp (d y,z) contDiffAt_snd.contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : Model n×Model n => d.symm q.1) (d y,z) := + ((contMDiffWithinAt_extChartAt_symm_target y + (d.map_source (mem_extChartAt_source y))).contMDiffAt + ((isOpen_extChartAt_target y).mem_nhds (d.map_source (mem_extChartAt_source y)))).comp + (d y,z) contDiffAt_fst.contMDiffAt + have hF : ContDiffAt ℝ ∞ (Function.uncurry F) (d y,z) := by + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (χ.symm z,d.symm (d y)) := by simpa only [hdy] using hc + exact (hc'.comp (d y,z) (hA.prodMk hB)).contDiffAt + have hchart : ContinuousAt d y := continuousAt_extChartAt y + have hq : ContinuousAt (fun q : Model n×M => (d q.2,q.1)) (z,y) := + (hchart.comp (x := (z,y)) (f := fun q : Model n×M => q.2) continuousAt_snd).prodMk continuousAt_fst + have hnear : ∀ᶠ q : Model n×M in 𝓝 (z,y), q.2∈d.source := + continuousAt_snd.preimage_mem_nhds (extChartAt_source_mem_nhds y) + have heq : ∀ᶠ q : Model n×M in 𝓝 (z,y), F (d q.2)=chartCost a q.2 := by + filter_upwards [hnear] with q hq + funext w + dsimp [F,chartCost,χ] + rw [d.left_inv hq] + constructor + · have H := (ContDiffAt.partial_snd_fderiv_two hF).continuousAt.comp + (x := (z,y)) (f := fun q : Model n×M => (d q.2,q.1)) hq + apply H.congr_of_eventuallyEq + filter_upwards [heq] with q hq + change fderiv ℝ (fderiv ℝ (chartCost a q.2)) q.1 = + fderiv ℝ (fderiv ℝ (F (d q.2))) q.1 + rw [hq] + · have H := (hF.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + filter_upwards [hq.tendsto.eventually H,heq] with q hq he + have H' := hq.comp q.1 (contDiffAt_const.prodMk contDiffAt_id) + change ContDiffAt ℝ 2 (F (d q.2)) q.1 at H' + rw [he] at H' + exact H' + +end + +open Set Filter +open scoped Topology + +lemma compact_eventually_fiberwise_bound {A X T F : Type*} + [TopologicalSpace A] [TopologicalSpace X] [T2Space X] [TopologicalSpace T] + [NormedAddCommGroup F] + {K : Set A} (hK : IsCompact K) {f : A → X} (hf : Continuous f) + {g : T → X} {t : T} (hg : ContinuousAt g t) {h : T×A → F} + (hh : ∀ a∈K, f a=g t → ContinuousAt h (t,a)) : + ∃ B>0, ∀ᶠ s in 𝓝 t, ∀ a∈K, f a=g s → ‖h (s,a)‖≤B := by + let S := K∩{a | f a=g t} + have hS : IsCompact S := hK.inter_right (isClosed_eq hf continuous_const) + have hcont : ContinuousOn (fun a => h (t,a)) S := by + intro a ha + exact ((hh a ha.1 ha.2).comp + (x := a) (f := fun a => (t,a)) (continuousAt_const.prodMk continuousAt_id)).continuousWithinAt + obtain ⟨C,hC⟩ := hS.exists_bound_of_continuousOn hcont + refine ⟨max C 0+1,by positivity,?_⟩ + apply compact_eventually_fiberwise hK hf hg + intro a ha he + have haS : a∈S := ⟨ha,he⟩ + have hlt : ‖h (t,a)‖< max C 0+1 := lt_of_le_of_lt ((hC a haS).trans (le_max_left _ _)) (lt_add_one _) + exact ((hh a ha he).norm.eventually_lt continuousAt_const hlt).mono (fun _ h => h.le) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartGradientMap.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartGradientMap.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb4c9d5f96c973ed252386a5fda891f477adea0e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartGradientMap.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def chartGradientVector (a : M) (z : Model n) (L : Model n →L[ℝ] ℝ) : + TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm z) := + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm z) ((riemannianCoordinateMetric a z).inverse L) + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinateBackward_eq_exp_chartGradient {a : M} {z : Model n} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (L : Model n →L[ℝ] ℝ) : + coordinateBackward a (-1,z,L)=riemannianExp + ((extChartAt 𝓘(ℝ,Model n) a).symm z) (chartGradientVector a z L) := by + rw [coordinateBackward,neg_neg,one_smul,movingNormal_eq hz] + rfl + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartGradientVector_total_eq {a : M} {q : Model n×(Model n →L[ℝ] ℝ)} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm q.1,chartGradientVector a q.1 q.2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) = + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).symm + (q.1,(riemannianCoordinateMetric a q.1).inverse q.2) := by + have hx : (extChartAt 𝓘(ℝ,Model n) a).symm q.1∈(chartAt (Model n) a).source := by + simpa only [extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hq + dsimp only [chartGradientVector] + rw [TangentBundle.symmL_trivializationAt_eq_core hx] + rfl + +omit [CompactSpace M] [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinateRaise_contDiffAt {a : M} {q : Model n×(Model n →L[ℝ] ℝ)} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContDiffAt ℝ ∞ (fun q : Model n×(Model n →L[ℝ] ℝ) => + (q.1,(riemannianCoordinateMetric a q.1).inverse q.2)) q := by + have hg := (contDiffOn_riemannianCoordinateMetric (E := Model n) a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds hq) + have hi := (riemannianCoordinateMetric_isInvertible hq).contDiffAt_map_inverse.comp q.1 hg + exact contDiffAt_fst.prodMk ((hi.comp q contDiffAt_fst).clm_apply contDiffAt_snd) + +omit [CompactSpace M] [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartGradientVector_total_continuousAt {a : M} {q : Model n×(Model n →L[ℝ] ℝ)} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContinuousAt (fun q : Model n×(Model n →L[ℝ] ℝ) => + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm q.1,chartGradientVector a q.1 q.2⟩ : + TangentBundle 𝓘(ℝ,Model n) M)) q := by + let c := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + let f := fun q : Model n×(Model n →L[ℝ] ℝ) => + (q.1,(riemannianCoordinateMetric a q.1).inverse q.2) + have hT : f q∈c.target := (tangent_chart_target_iff _ (f q)).mpr hq + have hc : ContinuousAt c.symm (f q) := + (continuousOn_extChartAt_symm _).continuousAt ((isOpen_extChartAt_target _).mem_nhds hT) + have hf : ContinuousAt f q := (coordinateRaise_contDiffAt hq).continuousAt + apply (hc.comp (x := q) hf).congr_of_eventuallyEq + have he : ∀ᶠ q' : Model n×(Model n →L[ℝ] ℝ) in 𝓝 q, + q'.1∈(extChartAt 𝓘(ℝ,Model n) a).target := + continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_target a).mem_nhds hq) + filter_upwards [he] with q' hq' + exact chartGradientVector_total_eq hq' + +omit [Nonempty M] in +lemma chartGradientVector_regular_near {a : M} {q : Model n×(Model n →L[ℝ] ℝ)} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : chartGradientVector a q.1 q.2∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1)) : + ∀ᶠ q' : Model n×(Model n →L[ℝ] ℝ) in 𝓝 q, + chartGradientVector a q'.1 q'.2∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm q'.1) := + (chartGradientVector_total_continuousAt hq).preimage_mem_nhds + (isOpen_total_injectivityDomain.mem_nhds hp) + +omit [Nonempty M] in +lemma chartCost_gradient_at_contact {a : M} {z : Model n} {L : Model n →L[ℝ] ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : chartGradientVector a z L∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) : + HasFDerivAt (chartCost a (coordinateBackward a (-1,z,L))) (-L) z := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let x := χ.symm z + let p := chartGradientVector a z L + have hx : x∈χ.source := χ.map_target hz + have hx' : x∈(chartAt (Model n) a).source := by simpa only [χ,extChartAt_source] using hx + have H := coordinate_gradient_of_hasMFDerivAt (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) + hx (fun w => cost w (riemannianExp x p)) (-1) + (by simpa only [neg_one_smul] using cost_start_gradient_of_injectivityDomain hp) + have hcoord : (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 = + (riemannianCoordinateMetric a z).inverse L := by + have hsame : (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 = + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p := by + rw [TangentBundle.continuousLinearMapAt_trivializationAt_eq_core hx'] + rfl + rw [hsame] + exact Trivialization.continuousLinearMapAt_symmL _ hx' _ + dsimp only [Bundle.TotalSpace.proj,Bundle.TotalSpace.snd] at H + rw [hcoord] at H + have he : χ x=z := χ.right_inv hz + change HasFDerivAt (fun q => cost (χ.symm q) (riemannianExp x p)) + ((-1:ℝ) • riemannianCoordinateMetric a (χ x) ((riemannianCoordinateMetric a z).inverse L)) (χ x) at H + rw [he,(riemannianCoordinateMetric_isInvertible hz).self_apply_inverse] at H + rw [coordinateBackward_eq_exp_chartGradient hz] + apply H.congr_fderiv + ext w + change (-1:ℝ)*L w= -L w + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartHopfLocalization.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartHopfLocalization.lean new file mode 100644 index 0000000000000000000000000000000000000000..158c1d9fc4b0fd112787935f2e8ecbd8906a206d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartHopfLocalization.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.HopfApproximation + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma uniform_hopfLax_chart_localization (L : ℝ≥0) (a : M) {R:ℝ} (hR : 00,∃ V∈𝓝 (extChartAt 𝓘(ℝ,Model n) a a), + ∀ t:ℝ,0 (q.1,χ.symm q.2)) (𝓝 (0,χ a)) (𝓝 (0,a)) := by + simpa only [Function.comp_apply,Prod.snd,he] using (continuousAt_fst.prodMk (hi.comp (x := ((0:ℝ),χ a)) continuousAt_snd)).tendsto + have HH := hq.eventually H + obtain ⟨U,hU,V,hV,hUV⟩ := mem_nhds_prod_iff.mp HH + obtain ⟨δ,hδ,hδU⟩ := Metric.mem_nhds_iff.mp hU + refine ⟨δ,hδ,V,hV,?_⟩ + intro t ht htδ z hz w hw y hy + have htU : t∈U := hδU (by simpa only [mem_ball,Real.dist_eq,sub_zero,abs_of_pos ht] using htδ) + exact hUV (a := (t,z)) ⟨htU,hz⟩ ht w hw y hy +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartLipschitz.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartLipschitz.lean new file mode 100644 index 0000000000000000000000000000000000000000..e46e32a0c332bfdd33a1e9538dbf74f74b598ee7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartLipschitz.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model +import OAI.Analysis.BiholderTransport.Calculus.RiemannianContinuous + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section ChartLipschitz +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace normedSpaceTangentSpaceVectorSpace + +local instance (y : Model n) (x : M) : NormedAddCommGroup + (TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) := + ContinuousLinearMap.toNormedAddCommGroup +local instance (y : Model n) (x : M) : NormedSpace ℝ + (TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) := + ContinuousLinearMap.toNormedSpace + +lemma exists_lipschitz_inverse_chart (x : M) : + ∃ C : ℝ≥0, ∃ r>0, ball (extChartAt 𝓘(ℝ,Model n) x x) r ⊆ (extChartAt 𝓘(ℝ,Model n) x).target ∧ + LipschitzOnWith C (extChartAt 𝓘(ℝ,Model n) x).symm + (ball (extChartAt 𝓘(ℝ,Model n) x x) r) := by + let d := extChartAt 𝓘(ℝ,Model n) x + have : IsContinuousRiemannianBundle (Model n) (fun z : M => TangentSpace 𝓘(ℝ,Model n) z) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨C,hCpos,hC⟩ := eventually_enorm_mfderivWithin_symm_extChartAt_lt 𝓘(ℝ,Model n) x + have hC' : ∀ᶠ y in 𝓝 (d x), ‖mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d.symm y‖ₑ < C := by + simpa only [ModelWithCorners.range_eq_univ,nhdsWithin_univ,mfderivWithin_univ] using hC + have hdT : d.target∈𝓝 (d x) := + (isOpen_extChartAt_target x).mem_nhds (mem_extChartAt_target x) + obtain ⟨r,hr,hboth⟩ := Metric.mem_nhds_iff.mp (inter_mem hdT hC') + have htarget : ball (d x) r⊆d.target := fun y hy => (hboth hy).1 + have hbound : ∀ y∈ball (d x) r, ‖mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d.symm y‖ₑ≤C := + fun y hy => (hboth hy).2.le + refine ⟨C,r,hr,htarget,?_⟩ + intro u hu v hv + let η := ContinuousAffineMap.lineMap (R := ℝ) u v + let γ := d.symm ∘ η + have hη : MapsTo η (Icc 0 1) (ball (d x) r) := by + change Icc 0 1 ⊆ η ⁻¹' ball (d x) r + rw [←image_subset_iff] + simp only [η,ContinuousAffineMap.coe_lineMap_eq,←segment_eq_image_lineMap] + exact (convex_ball _ _).segment_subset hu hv + have hηT : MapsTo η (Icc 0 1) d.target := hη.mono_right htarget + have η_smooth : ContMDiffOn 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) 1 η (Icc 0 1) := + (ContinuousAffineMap.contDiff η).contMDiff.contMDiffOn + have hγ : ContMDiffOn 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) 1 γ (Icc 0 1) := + (contMDiffOn_extChartAt_symm (I := 𝓘(ℝ,Model n)) (n := (1:ℕ∞ω)) x).comp η_smooth hηT + have H : riemannianEDist 𝓘(ℝ,Model n) (d.symm u) (d.symm v)≤pathELength 𝓘(ℝ,Model n) γ 0 1 := by + apply riemannianEDist_le_pathELength _ _ _ zero_le_one + · exact hγ + · simp only [γ,Function.comp_apply,η,ContinuousAffineMap.coe_lineMap_eq,AffineMap.lineMap_apply_zero] + · simp only [γ,Function.comp_apply,η,ContinuousAffineMap.coe_lineMap_eq,AffineMap.lineMap_apply_one] + rw [←IsRiemannianManifold.out] at H + apply H.trans + rw [←lintegral_fderiv_lineMap_eq_edist, pathELength_eq_lintegral_mfderivWithin_Icc, + ←lintegral_const_mul' _ _ ENNReal.coe_ne_top] + apply setLIntegral_mono' measurableSet_Icc + intro t ht + have hD : mfderivWithin 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ (Icc 0 1) t = + (mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d.symm (η t)).comp (mfderivWithin 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) η (Icc 0 1) t) := by + apply mfderiv_comp_mfderivWithin + · exact (contMDiffWithinAt_extChartAt_symm_target (n := (1:ℕ∞ω)) x (hηT ht)).contMDiffAt + ((isOpen_extChartAt_target x).mem_nhds (hηT ht)) |>.mdifferentiableAt (by norm_num : (1:ℕ∞ω)≠0) + · exact η_smooth.mdifferentiableOn one_ne_zero t ht + · rw [uniqueMDiffWithinAt_iff_uniqueDiffWithinAt] + exact uniqueDiffOn_Icc zero_lt_one t ht + rw [hD,ContinuousLinearMap.comp_apply] + apply (ContinuousLinearMap.le_opENorm _ _).trans + gcongr + · exact hbound _ (hη ht) + · simp only [mfderivWithin_eq_fderivWithin] + exact le_rfl + +end ChartLipschitz +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartParameter.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartParameter.lean new file mode 100644 index 0000000000000000000000000000000000000000..b79b1e90987b848148703861d9ffe926e980f316 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartParameter.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumRow +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartFirstMatrix + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartParameter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma MaximumRow.parameter_nonnegative {v : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {z : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + {ι : Type} [Fintype ι] (pj : ι → TangentSpace 𝓘(ℝ,Model n) R.q.1.1) (w : ι → ℝ) + (hw : ∀ i,0≤w i) (hs : ∑ i,w i=1) (hb : ∑ i,w i • pj i=R.q.1.2) + (ha : ∀ i,pj i∈activeLogs (modifiedDatum v α D b Bo) R.q.1.1) : + 1/4096+4*b/bplus≤Bc ((v (riemannianExp R.q.1.1 R.q.1.2)-α)/D)- + ∑ i,w i*Bo ((v (riemannianExp R.q.1.1 (pj i))-α)/D) := by + classical + let κ := {i : ι // 0pj i) (fun i=>w i) (fun i=>i.2) + H.2.1 (H.2.2.1.trans hb) (fun i=>ha i) + rw [H.2.2.2 (fun i=>Bo ((v (riemannianExp R.q.1.1 (pj i))-α)/D))] at HP + exact HP + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma MaximumRow.chart_first_limit_parameter {v G : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {a z : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + (ha : R.q.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) + {q : ℕ → subgradientGraph (n := n) (cTransform (modifiedDatum v α D b Bo))} + (J : ChartFixedPrefixLimit a (modifiedDatum v α D b Bo) G t q R.q) : + let x := graphBaseCoordinate a R.q.1 + 1/4096+4*b/bplus≤Bc ((v (movingNormal a (x,graphVelocityCoordinate a R.q.1))-α)/D)- + ∑ i,J.w₀ i*Bo ((v (movingNormal a (x,J.pj₀ i))-α)/D) := by + let x := graphBaseCoordinate a R.q.1 + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ R.q.1.1 + have hre := graph_coordinate_reconstruction ha + have hbase : (extChartAt 𝓘(ℝ,Model n) a).symm x=R.q.1.1 := + congrArg Bundle.TotalSpace.proj hre + have hvel : A (graphVelocityCoordinate a R.q.1)=R.q.1.2 := by + have H := congrArg (fun w:TangentBundle 𝓘(ℝ,Model n) M=>show Model n from w.2) hre + change chartFiberInverse a x (graphVelocityCoordinate a R.q.1)=R.q.1.2 at H + unfold chartFiberInverse at H + rw [hbase] at H + exact H + let pj : Fin (Module.finrank ℝ (Model n)+1) → TangentSpace 𝓘(ℝ,Model n) R.q.1.1 := + fun i=>A (J.pj₀ i) + have hbar : ∑ i,J.w₀ i • pj i=R.q.1.2 := by + calc + _=A (∑ i,J.w₀ i • J.pj₀ i) := by simp [pj] + _=R.q.1.2 := by rw [J.baryLimit]; exact hvel + have hactive : ∀ i,pj i∈activeLogs (modifiedDatum v α D b Bo) R.q.1.1 := by + intro i + have HH := J.activeLimit i + change chartFiberInverse a x (J.pj₀ i)∈activeLogs _ ((extChartAt 𝓘(ℝ,Model n) a).symm x) at HH + unfold chartFiberInverse at HH + rw [hbase] at HH + exact HH + have HP := R.parameter_nonnegative pj J.w₀ J.nonnegLimit J.totalLimit hbar hactive + have hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target := (extChartAt 𝓘(ℝ,Model n) a).map_source ha + have he (p : Model n) : movingNormal a (x,p)=riemannianExp R.q.1.1 (A p) := by + rw [movingNormal_eq hx,hbase] + change 1/4096+4*b/bplus≤Bc ((v (movingNormal a (x,graphVelocityCoordinate a R.q.1))-α)/D)- + ∑ i,J.w₀ i*Bo ((v (movingNormal a (x,J.pj₀ i))-α)/D) + simp only [he,hvel] + exact HP + +end ChartParameter +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTransition.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTransition.lean new file mode 100644 index 0000000000000000000000000000000000000000..21ab122d2d878aad67dbc1c6d885f41e6ec71744 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTransition.lean @@ -0,0 +1,182 @@ +import Mathlib + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + +lemma hasFDerivAt_chart_transition {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) : + HasFDerivAt (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (tangentCoordChange 𝓘(ℝ,E) a b x) (extChartAt 𝓘(ℝ,E) a x) := by + simpa only [ModelWithCorners.range_eq_univ,hasFDerivWithinAt_univ] using + hasFDerivWithinAt_tangentCoordChange (I := 𝓘(ℝ,E)) ⟨ha,hb⟩ + +lemma contDiffAt_chart_transition {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) : + ContDiffAt ℝ ∞ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (extChartAt 𝓘(ℝ,E) a x) := by + have h1 := (contMDiffOn_extChartAt_symm (I := 𝓘(ℝ,E)) (n := ∞) a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds ((extChartAt 𝓘(ℝ,E) a).map_source ha)) + have h2 := (contMDiffOn_extChartAt (I := 𝓘(ℝ,E)) (n := ∞) (x := b)).contMDiffAt + (by simpa only [extChartAt_source] using ((isOpen_extChartAt_source b).mem_nhds hb)) + have h2' : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,E) ∞ (extChartAt 𝓘(ℝ,E) b) + ((extChartAt 𝓘(ℝ,E) a).symm (extChartAt 𝓘(ℝ,E) a x)) := by + rwa [(extChartAt 𝓘(ℝ,E) a).left_inv ha] + exact (h2'.comp _ h1).contDiffAt + +lemma chart_transition_derivative_surjective {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) : + Function.Surjective (fderiv ℝ + (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (extChartAt 𝓘(ℝ,E) a x)) := by + rw [(hasFDerivAt_chart_transition ha hb).fderiv] + intro v + refine ⟨tangentCoordChange 𝓘(ℝ,E) b a x v,?_⟩ + rw [tangentCoordChange_comp ⟨⟨hb,ha⟩,hb⟩,tangentCoordChange_self hb] + +lemma symmL_chart_transition {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) (v : E) : + (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) b).symmL ℝ x + (fderiv ℝ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (extChartAt 𝓘(ℝ,E) a x) v) = + (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ x v := by + have ha' : x ∈ (chartAt E a).source := by simpa only [extChartAt_source] using ha + have hb' : x ∈ (chartAt E b).source := by simpa only [extChartAt_source] using hb + rw [(hasFDerivAt_chart_transition ha hb).fderiv, + Trivialization.symmL_apply _ hb', Trivialization.symmL_apply _ ha'] + have hsA (u : E) : (trivializationAt E (TangentSpace 𝓘(ℝ,E)) a).symm x u = + tangentCoordChange 𝓘(ℝ,E) a x x u := + (tangentBundleCore 𝓘(ℝ,E) M).localTriv_symm_apply (i := achart E a) ha' u + have hsB (u : E) : (trivializationAt E (TangentSpace 𝓘(ℝ,E)) b).symm x u = + tangentCoordChange 𝓘(ℝ,E) b x x u := + (tangentBundleCore 𝓘(ℝ,E) M).localTriv_symm_apply (i := achart E b) hb' u + rw [hsA,hsB] + have h := tangentCoordChange_comp (I := 𝓘(ℝ,E)) (w := a) (x := b) (y := x) + (z := x) (v := v) ⟨⟨ha,hb⟩,mem_extChartAt_source x⟩ + exact h + +variable [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma chart_metric_transition {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) + {g h : E → E →L[ℝ] E →L[ℝ] ℝ} + (hg : ∀ u v : E, g (extChartAt 𝓘(ℝ,E) a x) u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ x u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ x v)) + (hh : ∀ u v : E, h (extChartAt 𝓘(ℝ,E) b x) u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) b).symmL ℝ x u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) b).symmL ℝ x v)) + (u v : E) : + g (extChartAt 𝓘(ℝ,E) a x) u v = + h (extChartAt 𝓘(ℝ,E) b x) + (fderiv ℝ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (extChartAt 𝓘(ℝ,E) a x) u) + (fderiv ℝ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) + (extChartAt 𝓘(ℝ,E) a x) v) := by + rw [hg,hh,symmL_chart_transition ha hb,symmL_chart_transition ha hb] + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] [IsManifold 𝓘(ℝ,E) ∞ M] + +lemma tangent_chart_apply (c z : TangentBundle 𝓘(ℝ,E) M) : + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) c z = + (extChartAt 𝓘(ℝ,E) c.1 z.1, tangentCoordChange 𝓘(ℝ,E) z.1 c.1 z.1 z.2) := by + rfl + +lemma tangent_chart_symm_base (c : TangentBundle 𝓘(ℝ,E) M) (z : E × E) : + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) c).symm z).1 = (extChartAt 𝓘(ℝ,E) c.1).symm z.1 := by + rfl + +lemma tangent_chart_symm_fiber (c : TangentBundle 𝓘(ℝ,E) M) (z : E × E) : + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) c).symm z).2 = + tangentCoordChange 𝓘(ℝ,E) c.1 ((extChartAt 𝓘(ℝ,E) c.1).symm z.1) + ((extChartAt 𝓘(ℝ,E) c.1).symm z.1) z.2 := by + rfl + +lemma tangent_chart_transition_apply (a b : TangentBundle 𝓘(ℝ,E) M) (z : E × E) + (ha : z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target) + (hb : (extChartAt 𝓘(ℝ,E) a.1).symm z.1 ∈ (extChartAt 𝓘(ℝ,E) b.1).source) : + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) b ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm z) = + ((extChartAt 𝓘(ℝ,E) b.1 ∘ (extChartAt 𝓘(ℝ,E) a.1).symm) z.1, + fderiv ℝ (extChartAt 𝓘(ℝ,E) b.1 ∘ (extChartAt 𝓘(ℝ,E) a.1).symm) z.1 z.2) := by + rw [tangent_chart_apply,tangent_chart_symm_base,tangent_chart_symm_fiber] + apply Prod.ext + · rfl + · have hsrc := (extChartAt 𝓘(ℝ,E) a.1).map_target ha + rw [tangentCoordChange_comp ⟨⟨hsrc,mem_extChartAt_source _⟩,hb⟩] + simp only [tangentCoordChange_def,ModelWithCorners.range_eq_univ,fderivWithin_univ, + (extChartAt 𝓘(ℝ,E) a.1).right_inv ha] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTrueCenter.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTrueCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..af1dbcb5cdac0dfdc8e33fb6351bec27a06dadeb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ChartTrueCenter.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartTrueMatrix +import OAI.Analysis.BiholderTransport.LinearAlgebra.TrueCenterMatrix +import OAI.Analysis.BiholderTransport.Calculus.TrueCenterGradient + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartTrueCenter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance chartTrueFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma chart_true_center_matrix {u:M → ℝ} {a c y:M} {b q:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hq:chartFiberInverse a b q∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hy:movingPrefix a 1 b q=y) (hc:y∈(extChartAt 𝓘(ℝ,Model n) c).source) + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) + (hp:∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d) + {l:ℝ} (hl:0φ (cTransform u + ((extChartAt 𝓘(ℝ,Model n) c).symm (extChartAt 𝓘(ℝ,Model n) c y+h)))) s S) : + ∃ R:TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) → + TangentSpace 𝓘(ℝ,Model n) y, + ∃ V:Model n →L[ℝ] Model n, + DifferentiableAt ℝ R (chartFiberInverse a b q) ∧ R (chartFiberInverse a b q)=0 ∧ + (∀ᶠ z in 𝓝 (chartFiberInverse a b q),riemannianExp y (R z)= + riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) z) ∧ + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + V.det=(chartFiberInverse a b).toLinearMap.normDet^2*l^n* + (expJacobian ((extChartAt 𝓘(ℝ,Model n) a).symm b) (chartFiberInverse a b q))^2* + (normalHessianOperator y p+A).det ∧ + ∀d,chartJetMatrix a c b q (innerSL ℝ s) ((innerSL ℝ).comp S) d d= + inner ℝ (V d) d+ + (normalHessian y (l • p) + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d)) + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d))- + l*normalHessian y p + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d)) + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d)))+ + (iteratedDeriv 2 φ (cTransform u y)/l^2)* + (inner ℝ (chartFiberInverse a b q) (chartFiberInverse a b d))^2 := by + let x: M := (extChartAt 𝓘(ℝ,Model n) a).symm b + let B:=chartFiberInverse a b + have he:riemannianExp x (B q)=y:=by + simpa only [movingPrefix_eq hb,one_smul,x,B,chartFiberInverse] using hy + obtain ⟨R,r,T,hR,hR0,hRe,hT,hTe,hV,hVdet,hmat⟩:= + true_center_matrix hA hp hq he hl hl1 hpx hφ hφd + let C:=fderiv ℝ R (B q) + let W:=normalHessianOperator y p+A + let V0:=l • C.adjoint.comp (W.comp C) + let V:=B.adjoint.comp (V0.comp B) + have hWs:=normal_contact_matrix_symmetric hA + have hV0s:∀d e,inner ℝ (V0 d) e=inner ℝ d (V0 e):=by + intro d e + simp only [V0,smul_apply,ContinuousLinearMap.comp_apply, + real_inner_smul_left,real_inner_smul_right,ContinuousLinearMap.adjoint_inner_left, + ContinuousLinearMap.adjoint_inner_right] + rw [hWs] + have hB:Function.Injective B:=by + exact chartFiberInverse_injective hb + have hdim:Module.finrank ℝ (Model n)=Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x):=by + rw [tangent_finrank] + exact finrank_euclideanSpace_fin + have hP:=det_positive_hessian_pullback (B:=B) (W:=V0) hdim hB hV0s hV (show (0:ℝ)<1 by norm_num) + simp only [one_smul,one_pow,one_mul] at hP + have hr:r=l • p:=quadratic_scalar_gradient hA.2.2.2 + (by simpa only [riemannianExp_zero,hφd] using (hφ.differentiableAt (by norm_num)).hasDerivAt) hTe + rw [hr] at hTe + have hpr:l • p∈injectivityDomain y:=contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors y hA.2.1) hl hl1 + have hid:=chartJetMatrix_normal_identity (f:=fun z=>φ (cTransform u z)) hb hq hy hc hpr hpx hTe hS hSe + (hR.differentiableAt (by simp)) hR0 hRe + refine ⟨R,V,hR.differentiableAt (by simp),hR0,hRe,?_,hP.1,?_,?_⟩ + · intro d e + simp only [V,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left, + ContinuousLinearMap.adjoint_inner_right,hV0s] + · change V.det=_ + rw [hP.2] + change B.toLinearMap.normDet^2*V0.det=_ + rw [hVdet] + ring + · intro d + rw [hid d,hmat (B d)] + simp only [V,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] + rfl +end ChartTrueCenter +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Charts.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Charts.lean new file mode 100644 index 0000000000000000000000000000000000000000..c5151ea6d427fe87c85435a3b1713cff39c33d43 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Charts.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.LocalMetricCharts +import OAI.Analysis.BiholderTransport.Geodesics.ChartLipschitz + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Metric Bundle +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section Charts +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_bilipschitz_chart (a : M) : + ∃ C D : ℝ≥0, ∃ r>0, ball a r⊆(extChartAt 𝓘(ℝ,Model n) a).source ∧ + LipschitzOnWith C (extChartAt 𝓘(ℝ,Model n) a) (ball a r) ∧ + LipschitzOnWith D (extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a '' ball a r) := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨C,r,hr,hs,hC⟩ := exists_lipschitzOn_chart (n := n) a + obtain ⟨D,s,hspos,_,hD⟩ := exists_lipschitzOn_inverse_chart (E := Model n) a + obtain ⟨t,ht,htsub⟩ := Metric.mem_nhds_iff.mp + (inter_mem (ball_mem_nhds a hr) ((continuousAt_extChartAt (I := 𝓘(ℝ,Model n)) a).preimage_mem_nhds + (ball_mem_nhds _ hspos))) + refine ⟨C,D,t,ht,fun x hx => hs (htsub hx).1,hC.mono (fun x hx => (htsub hx).1),?_⟩ + apply hD.mono + rintro z ⟨x,hx,rfl⟩ + exact (htsub hx).2 + +variable [MeasurableSpace M] [BorelSpace M] +end Charts +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactConfigurations.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactConfigurations.lean new file mode 100644 index 0000000000000000000000000000000000000000..20e50388c86ba2c316ee67aa1a0003f78bbb54a8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactConfigurations.lean @@ -0,0 +1,136 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveCompact +import OAI.Analysis.BiholderTransport.Convexity.UniformEnvelope + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CompactConfigurations +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma tangent_chart_symm_eq {a : M} {b : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) (p : Model n) : + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).symm (b,p) = + ⟨(extChartAt 𝓘(ℝ,Model n) a).symm b, chartFiberInverse a b p⟩ := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + have hx : x ∈ (chartAt (Model n) a).source := by + simpa only [x,extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hb + change (⟨x,tangentCoordChange 𝓘(ℝ,Model n) a x x p⟩ : TangentBundle 𝓘(ℝ,Model n) M) = _ + congr 1 + rw [chartFiberInverse,TangentBundle.symmL_trivializationAt_eq_core hx] + rfl + +lemma isCompact_active_coordinates {v : M → ℝ} (hv : Continuous v) + {a : M} {K : Set M} (hK : IsCompact K) + (hKa : K ⊆ (extChartAt 𝓘(ℝ,Model n) a).source) : + IsCompact ((extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)) '' + {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ activeLogs v z.1 ∧ z.1 ∈ K}) := by + have hk : IsCompact {z : TangentBundle 𝓘(ℝ,Model n) M | + z.2 ∈ activeLogs v z.1 ∧ z.1 ∈ K} := + (isCompact_total_activeLogs hv).inter_right + (hK.isClosed.preimage (FiberBundle.continuous_proj _ _)) + apply hk.image_of_continuousOn + apply (continuousOn_extChartAt _).mono + intro z hz + exact (tangent_chart_source_iff _ z).mpr (hKa hz.2) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma mem_active_coordinates {v : M → ℝ} {a : M} {K : Set M} + (hKa : K ⊆ (extChartAt 𝓘(ℝ,Model n) a).source) + {b p : Model n} + (h : (b,p) ∈ (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)) '' + {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ activeLogs v z.1 ∧ z.1 ∈ K}) : + b ∈ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + chartFiberInverse a b p ∈ activeLogs v ((extChartAt 𝓘(ℝ,Model n) a).symm b) ∧ + (extChartAt 𝓘(ℝ,Model n) a).symm b ∈ K := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + obtain ⟨z,hz,he⟩ := h + have hzS : z ∈ χ.source := (tangent_chart_source_iff _ z).mpr (hKa hz.2) + have hbp : (b,p) ∈ χ.target := by + rw [←he] + exact χ.map_source hzS + have hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target := + (tangent_chart_target_iff _ (b,p)).mp hbp + have hzinv : χ.symm (b,p) = z := by + rw [←he] + exact χ.left_inv hzS + have heq : (⟨(extChartAt 𝓘(ℝ,Model n) a).symm b, + chartFiberInverse a b p⟩ : TangentBundle 𝓘(ℝ,Model n) M) = z := by + exact (tangent_chart_symm_eq hb p).symm.trans hzinv + refine ⟨hb,?_⟩ + have hh := congrArg (fun z : TangentBundle 𝓘(ℝ,Model n) M => + z.2 ∈ activeLogs v z.1 ∧ z.1 ∈ K) heq + exact hh.mpr hz + +end CompactConfigurations + +lemma compact_common_base_configurations {E : Type*} [TopologicalSpace E] [T2Space E] + {ι : Type*} [Fintype ι] [Nonempty ι] {C : Set (E×E)} (hC : IsCompact C) + (T : ℝ) : + IsCompact {q : EnvelopeData E ι | (∀ i, (q.1.1, q.1.2 i) ∈ C) ∧ + (∀ i, 0 ≤ q.2.1 i) ∧ (∑ i, q.2.1 i = 1) ∧ q.2.2 ∈ Icc 0 T} := by + classical + let i₀ : ι := Classical.arbitrary ι + let Q := {z : (ι → C) × (Convexity.StdSimplex ℝ ι × Icc (0:ℝ) T) | + ∀ i, (z.1 i).1.1 = (z.1 i₀).1.1} + let : CompactSpace C := isCompact_iff_compactSpace.mp hC + have hQ : IsCompact Q := by + have he : Q = ⋂ i, {z : (ι → C) × (Convexity.StdSimplex ℝ ι × Icc (0:ℝ) T) | + (z.1 i).1.1 = (z.1 i₀).1.1} := by ext; simp [Q] + rw [he] + exact (isClosed_iInter (fun i => isClosed_eq + (continuous_fst.comp (continuous_subtype_val.comp ((continuous_apply i).comp continuous_fst))) + (continuous_fst.comp (continuous_subtype_val.comp ((continuous_apply i₀).comp continuous_fst))))).isCompact + let F : ((ι → C) × (Convexity.StdSimplex ℝ ι × Icc (0:ℝ) T)) → EnvelopeData E ι := + fun z => (((z.1 i₀).1.1, fun i => (z.1 i).1.2),(z.2.1.weights,z.2.2.1)) + have hF : Continuous F := by + dsimp [F] + fun_prop + have he : F '' Q = {q : EnvelopeData E ι | (∀ i, (q.1.1, q.1.2 i) ∈ C) ∧ + (∀ i, 0 ≤ q.2.1 i) ∧ (∑ i, q.2.1 i = 1) ∧ q.2.2 ∈ Icc 0 T} := by + ext q + constructor + · rintro ⟨z,hz,rfl⟩ + refine ⟨?_,z.2.1.weights_nonneg,z.2.1.total_of_fintype,z.2.2.2⟩ + intro i + change ((z.1 i₀).1.1,(z.1 i).1.2) ∈ C + rw [←hz i] + exact (z.1 i).2 + · rintro ⟨hc,hw,hsum,ht⟩ + let weights : Convexity.StdSimplex ℝ ι := { + weights := Finsupp.equivFunOnFinite.symm q.2.1 + nonneg index := by simpa using hw index + total := by simpa [Finsupp.sum_fintype] using hsum } + refine ⟨(fun i => ⟨(q.1.1,q.1.2 i),hc i⟩,weights,⟨q.2.2,ht⟩),?_,?_⟩ + · intro i + rfl + · rfl + rw [←he] + exact hQ.image hF + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactEventuallyFiberwise.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactEventuallyFiberwise.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ba03cf53d2f0ce8b80c4245963e8fc09d526ff2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CompactEventuallyFiberwise.lean @@ -0,0 +1,234 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +lemma compact_eventually_fiberwise {A X T : Type*} + [TopologicalSpace A] [TopologicalSpace X] [T2Space X] [TopologicalSpace T] + {K : Set A} (hK : IsCompact K) {f : A → X} (hf : Continuous f) + {g : T → X} {t : T} (hg : ContinuousAt g t) {P : T → A → Prop} + (hP : ∀ a∈K, f a=g t → ∀ᶠ q : T×A in 𝓝 (t,a), P q.1 q.2) : + ∀ᶠ s in 𝓝 t, ∀ a∈K, f a=g s → P s a := by + apply hK.eventually_forall_of_forall_eventually + intro a ha + by_cases he : f a=g t + · filter_upwards [hP a ha he] with q hq using fun _ => hq + · have hc1 : ContinuousAt (fun q : T×A => f q.2) (t,a) := hf.continuousAt.comp continuousAt_snd + have hc2 : ContinuousAt (fun q : T×A => g q.1) (t,a) := hg.comp continuousAt_fst + have hn : ∀ᶠ q : T×A in 𝓝 (t,a), f q.2≠g q.1 := + (hc1.prodMk hc2).preimage_mem_nhds (isClosed_diagonal.isOpen_compl.mem_nhds he) + filter_upwards [hn] with q hq using fun heq => (hq heq).elim +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateExpansion.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateExpansion.lean new file mode 100644 index 0000000000000000000000000000000000000000..745ff1f6cf13b6c959cf948e5be49d7b981769cc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateExpansion.lean @@ -0,0 +1,221 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.Measurable +import OAI.Analysis.BiholderTransport.Coordinates.ChartLipschitz +import OAI.Analysis.BiholderTransport.Coordinates.Inner +import OAI.Analysis.BiholderTransport.Convexity.CoordinateSemiconvex + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section CoordinateExpansion +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + [NormedAddCommGroup F] [InnerProductSpace ℝ F] [CompleteSpace F] + +lemma contDiffAt_exists_quadraticExpansion {f : E → ℝ} (hf : ContDiffAt ℝ 2 f 0) : + ∃ p : E, ∃ A : E →L[ℝ] E, + (∀ u v, inner ℝ (A u) v=inner ℝ u (A v)) ∧ HasQuadraticExpansion f p A := by + let J := (InnerProductSpace.toDual ℝ E).symm + let p : E := J (fderiv ℝ f 0) + let A : E →L[ℝ] E := J.toContinuousLinearEquiv.toContinuousLinearMap.comp + (fderiv ℝ (fderiv ℝ f) 0) + have hA (u v : E) : inner ℝ (A u) v=fderiv ℝ (fderiv ℝ f) 0 u v := + InnerProductSpace.toDual_symm_apply + have hp (u : E) : inner ℝ p u=fderiv ℝ f 0 u := InnerProductSpace.toDual_symm_apply + refine ⟨p,A,?_,?_⟩ + · intro u v + have hc : inner ℝ u (A v)=inner ℝ (A v) u := real_inner_comm _ _ + rw [hA,hc,hA] + exact (hf.isSymmSndFDerivAt (by norm_num)).eq u v + · rw [hasQuadraticExpansion_iff_isLittleO] + convert contDiffAt_second_order_remainder hf using 1 + funext h + simp only [quadraticTaylor,hp,hA] + ring + +omit [CompleteSpace E] in +lemma HasQuadraticExpansion.of_isLittleO_sub {f g : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hg : HasQuadraticExpansion g p A) (h0 : f 0=g 0) + (hfg : (fun h => f h-g h) =o[𝓝 0] (fun h : E => ‖h‖^2)) : + HasQuadraticExpansion f p A := by + rw [hasQuadraticExpansion_iff_isLittleO] at hg ⊢ + convert! hfg.add hg using 1 + funext h + rw [h0] + ring + +omit [CompleteSpace E] in +lemma HasQuadraticExpansion.congr_eventually {f g : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hf : HasQuadraticExpansion f p A) (hfg : f =ᶠ[𝓝 0] g) : + HasQuadraticExpansion g p A := by + rw [hasQuadraticExpansion_iff_isLittleO] at hf ⊢ + apply hf.congr' _ (Filter.EventuallyEq.refl _ _) + filter_upwards [hfg] with h hh + rw [hh,hfg.self_of_nhds] + +omit [CompleteSpace F] in +lemma HasQuadraticExpansion.comp_contDiffAt {f : F → ℝ} {p : F} {A : F →L[ℝ] F} + (hf : HasQuadraticExpansion f p A) {η : E → F} (hη0 : η 0=0) + (hη : ContDiffAt ℝ 2 η 0) : + ∃ q : E, ∃ B : E →L[ℝ] E, + (∀ u v, inner ℝ (B u) v=inner ℝ u (B v)) ∧ + HasQuadraticExpansion (fun h => f (η h)) q B := by + let P : F → ℝ := quadraticTaylor (f 0) p A + have hP : ContDiff ℝ 2 P := by + dsimp [P,quadraticTaylor] + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + obtain ⟨q,B,hBs,hB⟩ := contDiffAt_exists_quadraticExpansion (hP.contDiffAt.comp 0 hη) + refine ⟨q,B,hBs,hB.of_isLittleO_sub ?_ ?_⟩ + · simp only [Function.comp_apply,hη0,P,quadraticTaylor,map_zero,inner_zero_right,zero_div,add_zero] + · have hD := (hη.differentiableAt (by norm_num)).hasFDerivAt + have hO : η =O[𝓝 0] (fun h : E => h) := by + simpa only [hη0,sub_zero] using hD.isBigO_sub + have hO2 : (fun h : E => ‖η h‖^2) =O[𝓝 0] (fun h : E => ‖h‖^2) := by + simpa only [←sq] using hO.norm_norm.mul hO.norm_norm + have ht : Tendsto η (𝓝 0) (𝓝 0) := by + simpa only [ContinuousAt,hη0] using hη.continuousAt + exact ((hasQuadraticExpansion_iff_isLittleO.mp hf).comp_tendsto ht).trans_isBigO hO2 + +end CoordinateExpansion +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section AENormalExpansion +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] in +lemma cTransform_ae_normal_quadraticExpansion {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ w ∂metricVolume (M := M) n, + ∃ p : TangentSpace 𝓘(ℝ,Model n) w, ∃ A : TangentSpace 𝓘(ℝ,Model n) w →L[ℝ] TangentSpace 𝓘(ℝ,Model n) w, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (riemannianExp w h)) p A := by + suffices HH : ∀ x∈(univ : Set M), ∃ U : Set M, IsOpen U ∧ x∈U ∧ + (∀ᵐ w ∂metricVolume (M := M) n, w∈U → + ∃ p : TangentSpace 𝓘(ℝ,Model n) w, ∃ A : TangentSpace 𝓘(ℝ,Model n) w →L[ℝ] TangentSpace 𝓘(ℝ,Model n) w, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (riemannianExp w h)) p A) by + simpa only [mem_univ,true_implies] using ae_of_locally_ae (metricVolume (M := M) n) HH + intro x _ + obtain ⟨C,r,hr,htarget,hLip⟩ := exists_lipschitz_inverse_chart (n := n) x + let d := extChartAt 𝓘(ℝ,Model n) x + let ψ := fun z : Model n => d.symm (d x+z) + have hψ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ ψ 0 := by + apply (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d.symm (d x+0) from by + simpa only [add_zero] using (contMDiffOn_extChartAt_symm x).contMDiffAt + ((isOpen_extChartAt_target x).mem_nhds (mem_extChartAt_target x))).comp + exact (contDiff_const.add contDiff_id).contDiffAt.contMDiffAt + obtain ⟨R,hR,K,hK,hconv⟩ := cTransform_uniform_smooth_coordinate_semiconvex hψ + let B := ball (0:Model n) (min R r) + let U := d.source ∩ (fun w => d w-d x) ⁻¹' B + have hU : IsOpen U := ((continuousOn_extChartAt x).sub continuousOn_const).isOpen_inter_preimage + (isOpen_extChartAt_source x) isOpen_ball + refine ⟨U,hU,⟨mem_extChartAt_source x,by simpa [B] using And.intro hR hr⟩,?_⟩ + have hBtarget : ∀ z∈B, d x+z∈d.target := by + intro z hz + apply htarget + change d x+z∈ball (d x) r + simpa only [mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using + Metric.ball_subset_ball (min_le_right R r) hz + have hB' : ∀ z∈B, d x+z∈ball (d x) r := by + intro z hz + simpa only [mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using + Metric.ball_subset_ball (min_le_right R r) hz + have hψLip : LipschitzOnWith C ψ B := by + intro a ha b hb + simpa only [ψ,edist_dist,dist_eq_norm,add_sub_add_left_eq_sub] using + hLip (hB' a ha) (hB' b hb) + let μ : Measure (Model n) := Measure.hausdorffMeasure (n:ℝ) + have hdim : Module.finrank ℝ (Model n)=n := by simp [Model] + have : μ.IsAddHaarMeasure := by + dsimp only [μ] + rw [←hdim] + infer_instance + have hc : ConvexOn ℝ B (fun z => cTransform v (ψ z)+(2*K)/2*‖z‖^2) := by + simpa only [mul_div_cancel_left₀ K (show (2:ℝ)≠0 by norm_num)] using + (hconv v hv).subset (Metric.ball_subset_ball (min_le_left R r)) (convex_ball _ _) + have hAlex := ConvexProximal.ae_quadraticExpansion_semiconvex_open (2*K) isOpen_ball hc μ + let N := {z : Model n | z∈B ∧ ¬∃ p : Model n, ∃ A : Model n →L[ℝ] Model n, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (ψ (z+h))) p A} + have hN : μ N=0 := by + apply measure_mono_null _ (ae_iff.mp hAlex) + intro z hz + exact fun hh => hz.2 (hh hz.1) + have hImage : (Measure.hausdorffMeasure (n:ℝ) : Measure M) (ψ '' N)=0 := by + apply le_antisymm _ (show (0:ℝ≥0∞)≤_ from zero_le) + have hNsub : N⊆B := fun _ h => h.1 + have H := (hψLip.mono hNsub).hausdorffMeasure_image_le + (d := (n:ℝ)) (by positivity) + change _≤(C : ℝ≥0∞)^(n:ℝ)*μ N at H + simpa only [hN,mul_zero] using H + have hImageVol : metricVolume (M := M) n (ψ '' N)=0 := by + simp only [metricVolume,Measure.smul_apply,smul_eq_mul,hImage,mul_zero] + have hOutside : ∀ᵐ w ∂metricVolume (M := M) n, w∉ψ '' N := ae_iff.mpr (by simpa only [not_not,Set.ofPred_mem_eq] using hImageVol) + filter_upwards [hOutside] with w hw hwU + let z := d w-d x + have hzB : z∈B := hwU.2 + have hψz : ψ z=w := by simp only [ψ,z,add_sub_cancel,d.left_inv hwU.1] + have hzN : z∉N := fun h => hw ⟨z,h,hψz⟩ + have hzQ : ∃ p : Model n, ∃ A : Model n →L[ℝ] Model n, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (ψ (z+h))) p A := by + by_contra hh + exact hzN ⟨hzB,hh⟩ + obtain ⟨p,A,_,hQ⟩ := hzQ + let η := fun h : TangentSpace 𝓘(ℝ,Model n) w => d (riemannianExp w h)-d w + have hη0 : η 0=0 := by simp [η,riemannianExp_zero] + have hη : ContDiffAt ℝ ∞ η 0 := by + have hc : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d w := + contMDiffAt_extChartAt' (by simpa only [d,extChartAt_source] using hwU.1) + have hd := (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp w 0) from by + simpa only [riemannianExp_zero] using hc).comp 0 (contMDiff_riemannianExp_fiber w 0) + exact hd.contDiffAt.sub contDiffAt_const + obtain ⟨q,B,hBs,hB⟩ := hQ.comp_contDiffAt hη0 + (hη.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + refine ⟨q,B,hBs,hB.congr_eventually ?_⟩ + have hsource : d.source∈𝓝 w := (isOpen_extChartAt_source x).mem_nhds hwU.1 + have hsource' : d.source∈𝓝 (riemannianExp (n := n) w 0) := by + simpa only [riemannianExp_zero] using hsource + have hnear := (contMDiff_riemannianExp_fiber (n := n) w).continuous.continuousAt.preimage_mem_nhds hsource' + filter_upwards [hnear] with h hh + have he : ψ (z+η h)=riemannianExp w h := by + dsimp [ψ,z,η] + rw [show d x+(d w-d x+(d (riemannianExp w h)-d w))=d (riemannianExp w h) by abel] + exact d.left_inv hh + exact congrArg (cTransform v) he + +end AENormalExpansion +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateGradient.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..844f10d226a1763928b9bc250bfadba18ccefe12 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateGradient.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.IntrinsicGradient + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma coordinate_gradient_of_hasMFDerivAt {a : M} (z : TangentBundle 𝓘(ℝ,E) M) + (hz : z.1 ∈ (extChartAt 𝓘(ℝ,E) a).source) (f : M → ℝ) (τ : ℝ) + (hM : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f z.1 (innerSL ℝ (τ • z.2))) : + HasFDerivAt (fun q : E => f ((extChartAt 𝓘(ℝ,E) a).symm q)) + (τ • riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a z.1) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) z).2)) + (extChartAt 𝓘(ℝ,E) a z.1) := by + let c := extChartAt 𝓘(ℝ,E) a + let F : E → ℝ := fun q => f (c.symm q) + have hc : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,E) ∞ c.symm (c z.1) := + (contMDiffOn_extChartAt_symm a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds (c.map_source hz)) + have hm : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f (c.symm (c z.1)) := by + rw [c.left_inv hz]; exact hM.mdifferentiableAt + have hF : DifferentiableAt ℝ F (c z.1) := + (hm.comp (c z.1) (hc.mdifferentiableAt (by simp))).differentiableAt + have hz' : z.1 ∈ (chartAt E a).source := by simpa only [extChartAt_source] using hz + have hDc := (mdifferentiableAt_extChartAt (I := 𝓘(ℝ,E)) hz').hasMFDerivAt + have H := hF.hasFDerivAt.hasMFDerivAt.comp z.1 hDc + have heq : f =ᶠ[𝓝 z.1] (fun y : M => F (c y)) := by + filter_upwards [(isOpen_extChartAt_source a).mem_nhds hz] with y hy + dsimp [F]; rw [c.left_inv hy] + have H' := H.congr_of_eventuallyEq heq + have hEq := H'.mfderiv.symm.trans hM.mfderiv + have hsur : Function.Surjective (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c z.1) := by + obtain ⟨A,hA⟩ := isInvertible_mfderiv_extChartAt hz + rw [←hA] + exact A.surjective + apply hF.hasFDerivAt.congr_fderiv + ext u + obtain ⟨v,rfl⟩ := hsur u + have hh := congrArg (fun D : TangentSpace 𝓘(ℝ,E) z.1 →L[ℝ] ℝ => D v) hEq + change fderiv ℝ F (c z.1) (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c z.1 v) = + τ * riemannianCoordinateMetric a (c z.1) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) z).2) + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c z.1 v) + rw [tangent_chart_apply,←mfderiv_extChartAt_eq_tangentCoordChange hz] + dsimp only [Prod.snd] + erw [coordinate_metric_chart_pairing hz z.2 v] + convert! hh using 1 + simp only [innerSL_apply_apply,real_inner_smul_left] + +end + +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {M : Type*} [MetricSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + +lemma coordinate_cost_contDiffAt {a : M} {δ : ℝ} + (hC : ContMDiffOn (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => dist z.1 z.2^2/2) (Metric.ball a δ ×ˢ Metric.ball a δ)) + {b : F → M} {v : F} {q : E} + (hb : ContMDiffAt 𝓘(ℝ,F) 𝓘(ℝ,E) ∞ b v) + (hbδ : b v ∈ Metric.ball a δ) + (hq : q ∈ (extChartAt 𝓘(ℝ,E) a).target) + (hqδ : (extChartAt 𝓘(ℝ,E) a).symm q ∈ Metric.ball a δ) : + ContDiffAt ℝ ∞ (fun z : F×E => dist (b z.1) ((extChartAt 𝓘(ℝ,E) a).symm z.2)^2/2) (v,q) := by + have hc : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,E) ∞ (extChartAt 𝓘(ℝ,E) a).symm q := + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds hq) + have hcost := hC.contMDiffAt ((Metric.isOpen_ball.prod Metric.isOpen_ball).mem_nhds (show (b v,(extChartAt 𝓘(ℝ,E) a).symm q) ∈ Metric.ball a δ ×ˢ Metric.ball a δ from ⟨hbδ,hqδ⟩)) + exact (hcost.comp (v,q) ((hb.comp (v,q) contDiffAt_fst.contMDiffAt).prodMk + (hc.comp (v,q) contDiffAt_snd.contMDiffAt))).contDiffAt + +lemma coordinate_outgoing_cost_contDiffAt {a y : M} {δ : ℝ} + (hC : ContMDiffOn (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => dist z.1 z.2^2/2) (Metric.ball a δ ×ˢ Metric.ball a δ)) + {q : E} (hy : y ∈ Metric.ball a δ) + (hq : q ∈ (extChartAt 𝓘(ℝ,E) a).target) + (hqδ : (extChartAt 𝓘(ℝ,E) a).symm q ∈ Metric.ball a δ) : + ContDiffAt ℝ ∞ (fun q : E => dist ((extChartAt 𝓘(ℝ,E) a).symm q) y^2/2) q := by + have hc : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,E) ∞ (extChartAt 𝓘(ℝ,E) a).symm q := + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds hq) + have hcost := hC.contMDiffAt ((Metric.isOpen_ball.prod Metric.isOpen_ball).mem_nhds (show ((extChartAt 𝓘(ℝ,E) a).symm q,y) ∈ Metric.ball a δ ×ˢ Metric.ball a δ from ⟨hqδ,hy⟩)) + exact (hcost.comp q (hc.prodMk contMDiffAt_const)).contDiffAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMatrices.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMatrices.lean new file mode 100644 index 0000000000000000000000000000000000000000..f700772c8eff6c668b63f3f5c832cc2cbc68dde0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMatrices.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CoordinatePole +import OAI.Analysis.BiholderTransport.Coordinates.GraphCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinateCenterMatrix (a : M) (t : ℝ) (G : M → ℝ) (b p : Model n) : + Model n →L[ℝ] Model n →L[ℝ] ℝ := + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p+ + fderiv ℝ (fderiv ℝ (fun q=>G (movingPrefix a t b q))) p + +omit [Nonempty M] in +lemma coordinatePoleMatrix_chart {a c : M} {t : ℝ} {v : M → ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) : + coordinatePoleMatrix a t v b p= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p- + fderiv ℝ (fderiv ℝ (fun q=>hopfLax t (cTransform v) + ((extChartAt 𝓘(ℝ,Model n) c).symm (movingPrefixChart a c t b q)))) p := by + exact congrArg (fun B=>fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p-B) + (((movingPrefix_chart_pullback hb hc _).fderiv (𝕜 := ℝ)).fderiv_eq.symm) + +omit [Nonempty M] in +lemma coordinateCenterMatrix_chart {a c : M} {t : ℝ} {G : M → ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) : + coordinateCenterMatrix a t G b p= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p+ + fderiv ℝ (fderiv ℝ (fun q=>G + ((extChartAt 𝓘(ℝ,Model n) c).symm (movingPrefixChart a c t b q)))) p := by + exact congrArg (fun B=>fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p+B) + (((movingPrefix_chart_pullback hb hc _).fderiv (𝕜 := ℝ)).fderiv_eq.symm) + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma graphCoordinate_normalSubdifferential {a : M} {u : M → ℝ} + (q : subgradientGraph (n := n) u) + (hq : q.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + chartFiberInverse a (graphBaseCoordinate a q.1) (graphVelocityCoordinate a q.1)∈ + normalSubdifferential (n := n) u + ((extChartAt 𝓘(ℝ,Model n) a).symm (graphBaseCoordinate a q.1)) := by + exact (congrArg (fun z:TangentBundle 𝓘(ℝ,Model n) M=>z.2∈normalSubdifferential u z.1) + (graph_coordinate_reconstruction hq)).mpr q.2 + +lemma WeakMTW.graphCoordinate_prefix_regular (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0t • z.2∈injectivityDomain z.1) + (graph_coordinate_reconstruction hq)).mpr (hmtw.active_hull_precut hv ht ht1 _ _ + (normalSubdifferential_subset_active_hull hv _ q.2)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMetricNorm.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMetricNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..c8827b90bd69a91d473ca2f570f66985a888905b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateMetricNorm.lean @@ -0,0 +1,158 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma coordinate_metric_norm {a : M} {z : E} + (hz : z ∈ (extChartAt 𝓘(ℝ,E) a).target) + {g : E →L[ℝ] E →L[ℝ] ℝ} + (hg : ∀ u v : E, g u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ + ((extChartAt 𝓘(ℝ,E) a).symm z) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ + ((extChartAt 𝓘(ℝ,E) a).symm z) v)) (v : E) : + Real.sqrt (g v v) = ‖mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a).symm z v‖ := by + have hsrc := (extChartAt 𝓘(ℝ,E) a).map_target hz + have hsrc' : (extChartAt 𝓘(ℝ,E) a).symm z ∈ (chartAt E a).source := by + simpa only [extChartAt_source] using hsrc + have heq := TangentBundle.symmL_trivializationAt (I := 𝓘(ℝ,E)) hsrc' + rw [ModelWithCorners.range_eq_univ,mfderivWithin_univ] at heq + have hinv : extChartAt 𝓘(ℝ,E) a ((extChartAt 𝓘(ℝ,E) a).symm z) = z := + (extChartAt 𝓘(ℝ,E) a).right_inv hz + rw [hinv] at heq + rw [hg,heq,real_inner_self_eq_norm_sq,Real.sqrt_sq_eq_abs,abs_norm] + rfl + +lemma coordinate_metric_chart_derivative_norm {a y : M} + (hy : y ∈ (extChartAt 𝓘(ℝ,E) a).source) + {g : E →L[ℝ] E →L[ℝ] ℝ} + (hg : ∀ u v : E, g u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ y u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ y v)) + (v : TangentSpace 𝓘(ℝ,E) y) : + Real.sqrt (g (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y v) + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y v)) = ‖v‖ := by + let w : E := mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y v + change Real.sqrt (g w w) = ‖v‖ + have hy' : y ∈ (chartAt E a).source := by simpa only [extChartAt_source] using hy + have hbase : y ∈ (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).baseSet := hy' + have hv := (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL_continuousLinearMapAt (R := ℝ) hbase v + rw [TangentBundle.continuousLinearMapAt_trivializationAt hy'] at hv + change (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ y w = v at hv + rw [hg,hv,real_inner_self_eq_norm_sq,Real.sqrt_sq_eq_abs,abs_norm] + +lemma coordinate_path_length {c : M} {γ : ℝ → M} {a b : ℝ} + (hγ : ContMDiffOn 𝓘(ℝ,ℝ) 𝓘(ℝ,E) 1 γ (Icc a b)) + (himg : MapsTo γ (Icc a b) (extChartAt 𝓘(ℝ,E) c).source) + (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ t ∈ Icc a b, ∀ u v : E, g (extChartAt 𝓘(ℝ,E) c (γ t)) u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ (γ t) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ (γ t) v)) : + pathELength 𝓘(ℝ,E) γ a b = + ∫⁻ t in Icc a b, ENNReal.ofReal (Real.sqrt (g (extChartAt 𝓘(ℝ,E) c (γ t)) + (deriv ((extChartAt 𝓘(ℝ,E) c) ∘ γ) t) + (deriv ((extChartAt 𝓘(ℝ,E) c) ∘ γ) t))) := by + rw [pathELength_eq_lintegral_mfderiv_Ioo,←restrict_Ioo_eq_restrict_Icc] + apply setLIntegral_congr_fun measurableSet_Ioo + intro t ht + have ht' : t ∈ Icc a b := Ioo_subset_Icc_self ht + have hγd := (hγ t ht').contMDiffAt (Icc_mem_nhds ht.1 ht.2) |>.mdifferentiableAt one_ne_zero + have hsrc' : γ t ∈ (chartAt E c).source := by simpa only [extChartAt_source] using himg ht' + have hχd := mdifferentiableAt_extChartAt (I := 𝓘(ℝ,E)) hsrc' + have hcomp := mfderiv_comp t hχd hγd + rw [mfderiv_eq_fderiv] at hcomp + have hval : deriv ((extChartAt 𝓘(ℝ,E) c) ∘ γ) t = + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) c) (γ t)) + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) := by + change (fderiv ℝ ((extChartAt 𝓘(ℝ,E) c) ∘ γ) t) 1 = _ + exact congrArg (fun L : ℝ →L[ℝ] E => L 1) hcomp + have hn := coordinate_metric_chart_derivative_norm (himg ht') (hg t ht') + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) + dsimp only + rw [←ofReal_norm] + congr 1 + rw [hval] + exact hn.symm + +lemma inverse_coordinate_path_length {c : M} {η : ℝ → E} {a b : ℝ} + (hη : ContDiffOn ℝ 1 η (Icc a b)) + (himg : MapsTo η (Icc a b) (extChartAt 𝓘(ℝ,E) c).target) + (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ t ∈ Icc a b, ∀ u v : E, g (η t) u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm (η t)) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm (η t)) v)) : + pathELength 𝓘(ℝ,E) ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) a b = + ∫⁻ t in Icc a b, ENNReal.ofReal (Real.sqrt (g (η t) (deriv η t) (deriv η t))) := by + rw [pathELength_eq_lintegral_mfderiv_Ioo,←restrict_Ioo_eq_restrict_Icc] + apply setLIntegral_congr_fun measurableSet_Ioo + intro t ht + have ht' : t ∈ Icc a b := Ioo_subset_Icc_self ht + have hηd := (hη.contDiffAt (Icc_mem_nhds ht.1 ht.2)).differentiableAt one_ne_zero + have hφd : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) c).symm (η t) := + ((contMDiffOn_extChartAt_symm (n := ∞) c) _ (himg ht')).contMDiffAt + ((isOpen_extChartAt_target (I := 𝓘(ℝ,E)) c).mem_nhds (himg ht')) |>.mdifferentiableAt (by simp) + have hcomp := mfderiv_comp t hφd (mdifferentiableAt_iff_differentiableAt.mpr hηd) + have hval := congrArg (fun L => L (1:ℝ)) hcomp + rw [mfderiv_eq_fderiv] at hval + have hn := coordinate_metric_norm (himg ht') (hg t ht') (deriv η t) + have hnval : ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) t 1‖ = + ‖mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) c).symm (η t) (deriv η t)‖ := + congrArg (fun v : TangentSpace 𝓘(ℝ,E) ((extChartAt 𝓘(ℝ,E) c).symm (η t)) => ‖v‖) hval + exact (ofReal_norm _).symm.trans (congrArg ENNReal.ofReal (hnval.trans hn.symm)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePairingDerivative.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePairingDerivative.lean new file mode 100644 index 0000000000000000000000000000000000000000..64b43bb1805a3600845276d028ed4419bda89de1 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePairingDerivative.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.GaussLemma + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +local instance coordinatePairingDerivativeNormedSpace : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance coordinatePairingDerivativeDualNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance coordinatePairingDerivativeDualNormedSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance coordinatePairingDerivativeBilinearNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance coordinatePairingDerivativeBilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance coordinatePairingDerivativeTrilinearNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance coordinatePairingDerivativeTrilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + +lemma coordinate_pairing_hasDerivAt + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hi : ∀ x ∈ S, (g x).IsInvertible) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {A V : ℝ × ℝ → E} {U : Set (ℝ×ℝ)} (hU : IsOpen U) + (hA : ContDiffOn ℝ ∞ A U) (hV : ContDiffOn ℝ ∞ V U) + (himg : ∀ z ∈ U, A z ∈ S) + (hode : ∀ z ∈ U, + HasDerivAt (fun q => A (q,z.2)) (V z) z.1 ∧ + HasDerivAt (fun q => V (q,z.2)) + (-coordinateChristoffel g (A z) (V z) (V z)) z.1) + {t s e : ℝ} (hz : (t,s) ∈ U) + (henergy : HasDerivAt (fun r => g (A (t,r)) (V (t,r)) (V (t,r))) e s) : + HasDerivAt (fun r => g (A (r,s)) (V (r,s)) + (directionalDerivative A (0,1) (r,s))) (e/2) t := by + have hgd : DifferentiableAt ℝ g (A (t,s)) := + (hg.contDiffAt (hS.mem_nhds (himg _ hz))).differentiableAt (by simp) + have hAr := hasDerivAt_slice_right ((hA.contDiffAt (hU.mem_nhds hz)).differentiableAt (by simp)) + have hVr := hasDerivAt_slice_right ((hV.contDiffAt (hU.mem_nhds hz)).differentiableAt (by simp)) + have hE := ((hgd.hasFDerivAt.comp_hasDerivAt s hAr).clm_apply hVr).clm_apply hVr + have he := hE.unique henergy + have hJ := variation_mixed_derivative hU hA (fun z hz => (hode z hz).1) hz + have hG := metric_geodesic_variation_derivative + (γ := fun r => A (r,s)) (V := fun r => V (r,s)) + (J := fun r => directionalDerivative A (0,1) (r,s)) hgd + (hi _ (himg _ hz)) (hode _ hz).1 (hode _ hz).2 hJ + have hval : (1/2:ℝ)*(fderiv ℝ g (A (t,s))) + (directionalDerivative A (0,1) (t,s)) (V (t,s)) (V (t,s)) + + g (A (t,s)) (V (t,s)) (directionalDerivative V (0,1) (t,s)) = e/2 := by + simp only [Function.comp_apply,add_apply] at he + rw [hsym _ (himg _ hz) (directionalDerivative V (0,1) (t,s)) (V (t,s))] at he + linarith + exact hval ▸ hG + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePole.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePole.lean new file mode 100644 index 0000000000000000000000000000000000000000..710c38b122b3ceb99659ff7f077e13615e104344 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinatePole.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.LowerTaylorComposition +import OAI.Analysis.BiholderTransport.Calculus.SampleJetData +import OAI.Analysis.BiholderTransport.Regularity.MovingPrefix +import OAI.Analysis.BiholderTransport.Regularity.RoughLinear + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinatePoleMatrix (a : M) (t : ℝ) (v : M → ℝ) (b p : Model n) : + Model n →L[ℝ] Model n →L[ℝ] ℝ := + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p- + fderiv ℝ (fderiv ℝ (fun q=>hopfLax t (cTransform v) (movingPrefix a t b q))) p + +omit [Nonempty M] in +lemma movingPrefix_chart_pullback {a c : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) (f : M → ℝ) : + (fun q=>f ((extChartAt 𝓘(ℝ,Model n) c).symm (movingPrefixChart a c t b q)))=ᶠ[𝓝 p] + (fun q=>f (movingPrefix a t b q)) := by + have hN : ContinuousAt (movingPrefix a t b) p := + ((movingPrefix_contMDiffAt (p := p) hb).continuousAt).comp + (show ContinuousAt (fun q:Model n=>(b,q)) p from by fun_prop) + filter_upwards [hN.eventually ((isOpen_extChartAt_source (I := 𝓘(ℝ,Model n)) c).mem_nhds hc)] + with q hq + exact congrArg f ((extChartAt 𝓘(ℝ,Model n) c).left_inv hq) + +lemma WeakMTW.coordinate_sample_pole_matrix (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 extChartAt 𝓘(ℝ,Model n) d + (hopfPole (n := n) t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (extChartAt 𝓘(ℝ,Model n) c (movingPrefix a t b p))) : + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + let L := coordinatePoleMatrix a t v b p + (∀ r:Model n,0≤L r r) ∧ (∀ r s:Model n,L r s=L s r) ∧ + (∀ q:Model n,A q∈activeLogs v x → ∀ r:Model n,L (q-p) r=0) ∧ + (∀ (ι:Type) [Fintype ι] (pj:ι → Model n) (w:ι → ℝ), + (∀ j,0≤w j) → (∑ j,w j=1) → (∑ j,w j • pj j=p) → + (∀ j,A (pj j)∈activeLogs v x) → ∀ i,0v (movingNormal a (b,pj i+r))+ + ‖A (pj i+r)‖^2/2) 0 (w i • L)) := by + dsimp only + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + let V := TangentSpace 𝓘(ℝ,Model n) x + let I : V →L[ℝ] V →L[ℝ] ℝ := innerSL ℝ + let f : V → ℝ := fun q=>hopfLax t (cTransform v) (riemannianExp x (t • q)) + let L₀ : V →L[ℝ] V →L[ℝ] ℝ := t • I-fderiv ℝ (fderiv ℝ f) (A p) + have hz' : riemannianExp x (t • A p)∈(extChartAt 𝓘(ℝ,Model n) c).source := by + simpa only [movingPrefix_eq hb] using hz + have hD' : DifferentiableAt ℝ + (fun w:Model n=>extChartAt 𝓘(ℝ,Model n) d + (hopfPole (n := n) t (cTransform v) ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (extChartAt 𝓘(ℝ,Model n) c (riemannianExp x (t • A p))) := by + simpa only [movingPrefix_eq hb] using hD + obtain ⟨hfd,hpos,hsym,hker,hjet⟩ := hmtw.actual_sample_pole_matrix hv ht ht1 hp hz' hx hD' + have hpre := hmtw.active_hull_precut hv ht ht1 x (A p) + (normalSubdifferential_subset_active_hull hv x hp) + have hnear : ∀ᶠ q in 𝓝 (A p),DifferentiableAt ℝ f q := + Filter.Eventually.of_forall (fun q=>hmtw.prefix_hopfLax_differentiable + (continuous_cTransform hv) (continuous_cTransform (continuous_cTransform hv)) + ⟨(cTransform_triple hv).symm,rfl⟩ ht ht1 x q) + have he : coordinatePoleMatrix a t v b p=pullBilinear L₀ A := by + ext r s + have hf : (fun q=>hopfLax t (cTransform v) (movingPrefix a t b q))=(fun q=>f (A q)) := by + funext q + exact congrArg (hopfLax t (cTransform v)) (movingPrefix_eq hb t q) + rw [coordinatePoleMatrix,sub_apply,sub_apply,movingPrefixEnergy_hessian hb hpre,hf, + second_fderiv_comp_linear_at A hnear hfd,pullBilinear_apply] + rfl + rw [he] + refine ⟨fun r=>hpos (A r),fun r s=>hsym (A r) (A s),?_,?_⟩ + · intro q hq r + change L₀ (A (q-p)) (A r)=0 + rw [map_sub] + exact hker (A q) hq (A r) + · intro ι _ pj w hw hw1 hbar ha i hi + have hbar' : ∑ i,w i • A (pj i)=A p := by + simpa only [map_sum,map_smul] using congrArg A hbar + have H := hjet ι (fun j=>A (pj j)) w hw hw1 hbar' ha i hi + have H' := H.comp_stationary (A.hasFDerivAt (x := 0)) (map_zero A) + have heB : pullBilinear (w i • L₀) A=w i • pullBilinear L₀ A := by + ext r s + rfl + rw [heB] at H' + convert H' using 1 + funext r + simp only [movingNormal_eq hb,map_add] + rfl + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateTrueLog.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateTrueLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..f7dbd3b6dba7c446ab8f4b1bb232a32017656bbd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateTrueLog.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ChartGradientMap + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CoordinateTrueLog +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_chart_covector_for_log {a : M} {p : TangentSpace 𝓘(ℝ,Model n) a} + (hp : p∈injectivityDomain a) : + let z := extChartAt 𝓘(ℝ,Model n) a a + ∃ L : Model n →L[ℝ] ℝ, + chartGradientVector a z L∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm z) ∧ + coordinateBackward a (-1,z,L)=riemannianExp a p ∧ + HasFDerivAt (chartCost a (riemannianExp a p)) (-L) z := by + let : Nonempty M := ⟨a⟩ + let z := extChartAt 𝓘(ℝ,Model n) a a + let A : TangentBundle 𝓘(ℝ,Model n) M := ⟨a,0⟩ + let P : TangentBundle 𝓘(ℝ,Model n) M := ⟨a,p⟩ + let c := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) A + let L := riemannianCoordinateMetric a z (c P).2 + have hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hPs : P∈c.source := (tangent_chart_source_iff A P).mpr (mem_extChartAt_source a) + have he : (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z L⟩ : + TangentBundle 𝓘(ℝ,Model n) M)=P := by + rw [chartGradientVector_total_eq (q := (z,L)) hz] + have hinv : (riemannianCoordinateMetric a z).inverse L=(c P).2 := + (riemannianCoordinateMetric_isInvertible hz).inverse_apply_self _ + rw [hinv] + exact c.left_inv hPs + have hreg : chartGradientVector a z L∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z) := by + have H : P∈{Q : TangentBundle 𝓘(ℝ,Model n) M | Q.2∈injectivityDomain Q.1} := hp + rwa [←he] at H + have hex : coordinateBackward a (-1,z,L)=riemannianExp a p := by + rw [coordinateBackward_eq_exp_chartGradient hz] + exact congrArg (fun Q : TangentBundle 𝓘(ℝ,Model n) M => riemannianExp Q.1 Q.2) he + refine ⟨L,hreg,hex,?_⟩ + rw [←hex] + exact chartCost_gradient_at_contact hz hreg + +end CoordinateTrueLog +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateVariation.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateVariation.lean new file mode 100644 index 0000000000000000000000000000000000000000..1806b96c630ae842e0fe4eabc57e7d3e721ea42d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CoordinateVariation.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Coordinates + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +local instance : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace + +lemma coordinateChristoffel_smul_left (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (x u v : E) (c : ℝ) : + coordinateChristoffel g x (c • u) v = c • coordinateChristoffel g x u v := by + unfold coordinateChristoffel + rw [←map_smul] + congr 1 + ext w + simp only [smul_apply,map_smul,sub_apply,add_apply,flip_apply,smul_eq_mul] + ring + +lemma coordinateChristoffel_smul_right (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (x u v : E) (c : ℝ) : + coordinateChristoffel g x u (c • v) = c • coordinateChristoffel g x u v := by + unfold coordinateChristoffel + rw [←map_smul] + congr 1 + ext w + simp only [smul_apply,map_smul,sub_apply,add_apply,flip_apply,smul_eq_mul] + ring +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Coordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Coordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d6fba6f4c2252381a58bab9c1ee8ad15349bc8b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Coordinates.lean @@ -0,0 +1,190 @@ +import Mathlib + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +local instance (x : M) : NormedAddCommGroup (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance (x : M) : NormedSpace ℝ (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance : ∀ x : M, ContinuousAdd (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + fun _ => inferInstance +local instance : ∀ x : M, ContinuousSMul ℝ (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + fun _ => inferInstance +end + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +local instance : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace + +lemma metricDual_isInvertible [FiniteDimensional ℝ E] (b : E →L[ℝ] E →L[ℝ] ℝ) + (hb : ∀ v : E, v ≠ 0 → 0 < b v v) : b.IsInvertible := by + have hinj : Function.Injective b := by + intro u v huv + have hz : b (u-v) = 0 := by rw [map_sub,huv,sub_self] + by_contra huv' + have hp := hb (u-v) (sub_ne_zero.mpr huv') + simp only [hz,zero_apply] at hp + exact (lt_irrefl 0) hp + let A : E →L[ℝ] E := (InnerProductSpace.toDual ℝ E).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp b + have hA : Function.Injective A := (InnerProductSpace.toDual ℝ E).symm.injective.comp hinj + have hAsur : Function.Surjective A := LinearMap.injective_iff_surjective.mp hA + have hsur : Function.Surjective b := by + intro q + obtain ⟨v,hv⟩ := hAsur ((InnerProductSpace.toDual ℝ E).symm q) + refine ⟨v,(InnerProductSpace.toDual ℝ E).symm.injective hv⟩ + exact ⟨ContinuousLinearEquiv.ofBijective b (LinearMap.ker_eq_bot.mpr hinj) + (LinearMap.range_eq_top.mpr hsur),rfl⟩ + +def coordinateChristoffel (g : E → E →L[ℝ] E →L[ℝ] ℝ) (x u v : E) : E := + (g x).inverse ((1/2:ℝ) • + ((fderiv ℝ g x) u v + (fderiv ℝ g x) v u - + (((fderiv ℝ g x).flip u).flip v))) + +lemma coordinateChristoffel_metric (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (x u v w : E) (hg : (g x).IsInvertible) : + 2 * g x (coordinateChristoffel g x u v) w = + (fderiv ℝ g x) u v w + (fderiv ℝ g x) v u w - (fderiv ℝ g x) w u v := by + rw [coordinateChristoffel,hg.self_apply_inverse] + simp only [smul_apply,sub_apply,add_apply,flip_apply,smul_eq_mul] + ring + +lemma coordinateChristoffel_self_metric (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (x v : E) (hg : (g x).IsInvertible) : + 2 * g x (coordinateChristoffel g x v v) v = (fderiv ℝ g x) v v v := by + have hh := coordinateChristoffel_metric g x v v v hg + linarith + +def coordinateGeodesicField (g : E → E →L[ℝ] E →L[ℝ] ℝ) (z : E × E) : E × E := + (z.2,-coordinateChristoffel g z.1 z.2 z.2) + +lemma metric_speed_derivative {g : E → E →L[ℝ] E →L[ℝ] ℝ} + {γ v : ℝ → E} {t : ℝ} + (hg : DifferentiableAt ℝ g (γ t)) (hi : (g (γ t)).IsInvertible) + (hs : ∀ a b, g (γ t) a b = g (γ t) b a) + (hγ : HasDerivAt γ (v t) t) + (hv : HasDerivAt v (-coordinateChristoffel g (γ t) (v t) (v t)) t) : + HasDerivAt (fun s => g (γ s) (v s) (v s)) 0 t := by + have hgγ : HasDerivAt (fun s => g (γ s)) ((fderiv ℝ g (γ t)) (v t)) t := + hg.hasFDerivAt.comp_hasDerivAt t hγ + have hgv : HasDerivAt (fun s => g (γ s) (v s)) + ((fderiv ℝ g (γ t)) (v t) (v t) + + g (γ t) (-coordinateChristoffel g (γ t) (v t) (v t))) t := + hgγ.clm_apply hv + have h : HasDerivAt (fun s => g (γ s) (v s) (v s)) + (((fderiv ℝ g (γ t)) (v t) (v t) + + g (γ t) (-coordinateChristoffel g (γ t) (v t) (v t))) (v t) + + g (γ t) (v t) (-coordinateChristoffel g (γ t) (v t) (v t))) t := + hgv.clm_apply hv + have hid := coordinateChristoffel_self_metric g (γ t) (v t) hi + have heq : ((fderiv ℝ g (γ t)) (v t) (v t) + + g (γ t) (-coordinateChristoffel g (γ t) (v t) (v t))) (v t) + + g (γ t) (v t) (-coordinateChristoffel g (γ t) (v t) (v t)) = 0 := by + simp only [add_apply,map_neg,neg_apply] + rw [hs (v t) (coordinateChristoffel g (γ t) (v t) (v t))] + linarith + exact heq ▸ h + +lemma contDiffAt_coordinateChristoffel [CompleteSpace E] + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {x u v : E} + (hg : ContDiffAt ℝ ∞ g x) (hi : (g x).IsInvertible) : + ContDiffAt ℝ ∞ (fun z : E × E × E => coordinateChristoffel g z.1 z.2.1 z.2.2) + (x,u,v) := by + have hd : ContDiffAt ℝ ∞ (fderiv ℝ g) x := hg.fderiv_right (by simp) + have hinv : ContDiffAt ℝ ∞ (fun x => (g x).inverse) x := + hi.contDiffAt_map_inverse.comp x hg + have hf1 : ContDiffAt ℝ ∞ (fun x => (fderiv ℝ g x).flip) x := + hd.continuousLinearMap_comp + (ContinuousLinearMap.flipₗᵢ ℝ E E (E →L[ℝ] ℝ)).toContinuousLinearEquiv.toContinuousLinearMap + have hx : ContDiffAt ℝ ∞ (fun z : E × E × E => z.1) (x,u,v) := contDiffAt_fst + have hu : ContDiffAt ℝ ∞ (fun z : E × E × E => z.2.1) (x,u,v) := + contDiffAt_fst.comp (x,u,v) contDiffAt_snd + have hv : ContDiffAt ℝ ∞ (fun z : E × E × E => z.2.2) (x,u,v) := + contDiffAt_snd.comp (x,u,v) contDiffAt_snd + have hfc : ContDiffAt ℝ ∞ (fun z : E × E × E => (fderiv ℝ g z.1).flip) + (x,u,v) := ContDiffAt.comp + (g := fun y : E => (fderiv ℝ g y).flip) + (f := fun z : E × E × E => z.1) (x,u,v) hf1 hx + have hfu : ContDiffAt ℝ ∞ (fun z : E × E × E => (fderiv ℝ g z.1).flip z.2.1) + (x,u,v) := hfc.clm_apply hu + have hfu' : ContDiffAt ℝ ∞ (fun z : E × E × E => ((fderiv ℝ g z.1).flip z.2.1).flip) + (x,u,v) := hfu.continuousLinearMap_comp + (ContinuousLinearMap.flipₗᵢ ℝ E E ℝ).toContinuousLinearEquiv.toContinuousLinearMap + have hf2 : ContDiffAt ℝ ∞ (fun z : E × E × E => + (((fderiv ℝ g z.1).flip z.2.1).flip z.2.2)) (x,u,v) := hfu'.clm_apply hv + have hduv : ContDiffAt ℝ ∞ (fun z : E × E × E => (fderiv ℝ g z.1) z.2.1 z.2.2) + (x,u,v) := ((hd.comp (x,u,v) hx).clm_apply hu).clm_apply hv + have hdvu : ContDiffAt ℝ ∞ (fun z : E × E × E => (fderiv ℝ g z.1) z.2.2 z.2.1) + (x,u,v) := ((hd.comp (x,u,v) hx).clm_apply hv).clm_apply hu + exact (hinv.comp (x,u,v) hx).clm_apply + (((hduv.add hdvu).sub hf2).const_smul (1/2:ℝ)) + +lemma contDiffAt_coordinateGeodesicField [CompleteSpace E] + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {x v : E} + (hg : ContDiffAt ℝ ∞ g x) (hi : (g x).IsInvertible) : + ContDiffAt ℝ ∞ (coordinateGeodesicField g) (x,v) := by + have hΓ : ContDiffAt ℝ ∞ (fun z : E × E => coordinateChristoffel g z.1 z.2 z.2) (x,v) := + (contDiffAt_coordinateChristoffel (u := v) (v := v) hg hi).comp (x,v) + (contDiffAt_fst.prodMk (contDiffAt_snd.prodMk contDiffAt_snd)) + exact contDiffAt_snd.prodMk hΓ.neg + +lemma coordinate_geodesic_speed_constant + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {γ v : ℝ → E} {a b s t : ℝ} + (hg : ∀ r ∈ Ioo a b, DifferentiableAt ℝ g (γ r)) + (hi : ∀ r ∈ Ioo a b, (g (γ r)).IsInvertible) + (hs : ∀ r ∈ Ioo a b, ∀ u w, g (γ r) u w = g (γ r) w u) + (hder : ∀ r ∈ Ioo a b, HasDerivAt γ (v r) r ∧ + HasDerivAt v (-coordinateChristoffel g (γ r) (v r) (v r)) r) + (hs_mem : s ∈ Ioo a b) (ht_mem : t ∈ Ioo a b) : + g (γ s) (v s) (v s) = g (γ t) (v t) (v t) := by + have hd : ∀ r ∈ Ioo a b, HasDerivAt (fun q => g (γ q) (v q) (v q)) 0 r := + fun r hr => metric_speed_derivative (hg r hr) (hi r hr) (hs r hr) + (hder r hr).1 (hder r hr).2 + exact isOpen_Ioo.is_const_of_deriv_eq_zero (convex_Ioo a b).isPreconnected + (fun r hr => (hd r hr).differentiableAt.differentiableWithinAt) + (fun r hr => (hd r hr).deriv) hs_mem ht_mem + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/CutCharacterization.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/CutCharacterization.lean new file mode 100644 index 0000000000000000000000000000000000000000..1c72f59117b21b5d89708621403de20c47ceeb4e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/CutCharacterization.lean @@ -0,0 +1,52 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.InjectivityOpen +import OAI.Analysis.BiholderTransport.Regularity.InteriorCompactUniqueFiber +import OAI.Analysis.BiholderTransport.Coordinates.BranchInverse + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma joint_exp_locally_injective_of_nonconjugate (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + ∃ U : Set (TangentBundle 𝓘(ℝ,Model n) M), IsOpen U ∧ z ∈ U ∧ + InjOn (fun q : TangentBundle 𝓘(ℝ,Model n) M => (q.1,riemannianExp q.1 q.2)) U := by + obtain ⟨P,_,_,hleft,_⟩ := exists_smooth_exp_branch z hz + obtain ⟨U,hUP,hU,hzU⟩ := mem_nhds_iff.mp hleft + refine ⟨U,hU,hzU,?_⟩ + exact (show LeftInvOn P + (fun point : TangentBundle 𝓘(ℝ,Model n) M => + (point.1,riemannianExp point.1 point.2)) U from hUP).injOn + +lemma mem_injectivityDomain_of_nonconjugate_unique {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)) + (hu : ∀ q ∈ minimizingVectors x, riemannianExp x q=riemannianExp x p → q=p) : + p ∈ injectivityDomain x := by + apply interior_minimizingVectors_subset x + apply interior_of_compact_unique_fiber (isCompact_minimizingVectors x) + (continuous_riemannianExp x) (exists_minimizing_vector x) hu + obtain ⟨U,hU,hpU,hinj⟩ := joint_exp_locally_injective_of_nonconjugate ⟨x,p⟩ hp + let I := fun q : TangentSpace 𝓘(ℝ,Model n) x => (⟨x,q⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hI : Continuous I := FiberBundle.continuous_totalSpaceMk (Model n) _ x + refine ⟨I ⁻¹' U,hU.preimage hI,hpU,?_⟩ + intro a ha b hb he + exact TotalSpace.mk_injective x (hinj ha hb (Prod.ext rfl he)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Endpoint.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Endpoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..424271b44520dfbb854becd65c0b73a2b6e5c7e6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Endpoint.lean @@ -0,0 +1,33 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Inner + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section Endpoint +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma HasQuadraticExpansion.sub {f g : E → ℝ} {p q : E} {H K : E →L[ℝ] E} + (hf : HasQuadraticExpansion f p H) (hg : HasQuadraticExpansion g q K) : + HasQuadraticExpansion (fun d => f d-g d) (p-q) (H-K) := by + rw [hasQuadraticExpansion_iff_isLittleO] at hf hg ⊢ + convert! hf.sub hg using 1 + funext d + simp only [quadraticTaylor,inner_sub_left,sub_apply] + ring +end Endpoint +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpJacContinuity.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpJacContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..593bc227df1997843c1cef33589ccd0e60248963 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpJacContinuity.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.FixedJoinSpectrum +import OAI.Analysis.BiholderTransport.Coordinates.ExpVertical +import OAI.Analysis.BiholderTransport.Regularity.FrameDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpJacContinuity +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance expJacContFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma frameNormDet_at {a x:M} (hx:x∈(extChartAt 𝓘(ℝ,Model n) a).source) : + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a x)).toLinearMap.normDet= + ((trivializationAt (Model n) (fun y:M=>TangentSpace 𝓘(ℝ,Model n) y) a).symmL ℝ x).toLinearMap.normDet := by + exact congrArg (fun y:M=>((trivializationAt (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x) a).symmL ℝ y).toLinearMap.normDet) + ((extChartAt 𝓘(ℝ,Model n) a).left_inv hx) + +lemma expJacobian_coordinate_identity (c z:TangentBundle 𝓘(ℝ,Model n) M) + (hz:z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) + (he:riemannianExp z.1 z.2∈(extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2)).source) : + expJacobian z.1 z.2 * + (chartFiberInverse c.1 (extChartAt 𝓘(ℝ,Model n) c.1 z.1)).toLinearMap.normDet= + (chartFiberInverse (riemannianExp c.1 c.2) + (extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2) (riemannianExp z.1 z.2))).toLinearMap.normDet* + |(coordinateEndpointVertical c z).det| := by + let U:=trivializationAt (Model n) (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x) c.1 + let V:=trivializationAt (Model n) (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x) (riemannianExp c.1 c.2) + let B:=U.symmL ℝ z.1 + let C:=V.symmL ℝ (riemannianExp z.1 z.2) + let A:=coordinateEndpointVertical c z + let E:TangentSpace 𝓘(ℝ,Model n) z.1 →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp z.1 z.2):= + mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) z.1) 𝓘(ℝ,Model n) (riemannianExp z.1) z.2 + have hz':z.1∈(extChartAt 𝓘(ℝ,Model n) c.1).source:=(tangent_chart_source_iff _ _).mp hz + have hU:z.1∈U.baseSet:=by simpa only [U,TangentBundle.trivializationAt_baseSet,extChartAt_source] using hz' + have hV:riemannianExp z.1 z.2∈V.baseSet:=by simpa only [V,TangentBundle.trivializationAt_baseSet,extChartAt_source] using he + have hEB:E.comp B=C.comp A:=by + apply ContinuousLinearMap.ext + intro d + have HH:=coordinateEndpointVertical_apply c z hz he (B d) + rw [U.continuousLinearMapAt_symmL hU] at HH + have HHH:=congrArg C HH + rw [V.symmL_continuousLinearMapAt hV] at HHH + exact HHH.symm + rw [frameNormDet_at hz',frameNormDet_at he] + change E.toLinearMap.normDet*B.toLinearMap.normDet=C.toLinearMap.normDet*|A.det| + have h1:=LinearMap.normDet_comp_of_finrank_eq B.toLinearMap E.toLinearMap (show Module.finrank ℝ (Model n)=Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) z.1) by rw [tangent_finrank]; exact finrank_euclideanSpace_fin) + have h2:=LinearMap.normDet_comp_of_finrank_eq A.toLinearMap C.toLinearMap rfl + rw [LinearMap.normDet_eq_abs_det] at h2 + change (E.comp B).toLinearMap.normDet=_ at h1 + change (C.comp A).toLinearMap.normDet=_ at h2 + rw [←h1,hEB,h2] + +lemma continuous_expJacobian : Continuous (fun z:TangentBundle 𝓘(ℝ,Model n) M=>expJacobian z.1 z.2) := by + apply continuous_iff_continuousAt.mpr + intro c + let e:=riemannianExp c.1 c.2 + let s:=fun z:TangentBundle 𝓘(ℝ,Model n) M=> + (chartFiberInverse c.1 (extChartAt 𝓘(ℝ,Model n) c.1 z.1)).toLinearMap.normDet + let t:=fun z:TangentBundle 𝓘(ℝ,Model n) M=> + (chartFiberInverse e (extChartAt 𝓘(ℝ,Model n) e (riemannianExp z.1 z.2))).toLinearMap.normDet + have hproj:Continuous (fun z:TangentBundle 𝓘(ℝ,Model n) M=>z.1):= + (Bundle.contMDiff_proj (n:=∞) (IB:=𝓘(ℝ,Model n)) (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)).continuous + have hE:Continuous (fun z:TangentBundle 𝓘(ℝ,Model n) M=>riemannianExp z.1 z.2):=contMDiff_riemannianExp.continuous + have hsc:ContinuousAt (fun z:TangentBundle 𝓘(ℝ,Model n) M=>extChartAt 𝓘(ℝ,Model n) c.1 z.1) c:= + (continuousAt_extChartAt (I:=𝓘(ℝ,Model n)) c.1).comp hproj.continuousAt + have htc:ContinuousAt (fun z:TangentBundle 𝓘(ℝ,Model n) M=>extChartAt 𝓘(ℝ,Model n) e (riemannianExp z.1 z.2)) c:= + (continuousAt_extChartAt (I:=𝓘(ℝ,Model n)) e).tendsto.comp hE.continuousAt + have hs:ContinuousAt s c:= (frameNormDet_continuousAt (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) c.1)).tendsto.comp hsc.tendsto + have ht:ContinuousAt t c:= (frameNormDet_continuousAt (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) e)).tendsto.comp htc.tendsto + have hsp:0|(coordinateEndpointVertical c z).det|) c:= + (ContinuousLinearMap.continuous_det.continuousAt.comp (coordinateEndpointVertical_continuousAt c)).abs + have H:ContinuousAt (fun z=>t z*|(coordinateEndpointVertical c z).det|/s z) c:=(ht.mul Hd).div hs hsp.ne' + apply H.congr_of_eventuallyEq + filter_upwards [extChartAt_source_mem_nhds (I:=𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c, + hE.continuousAt.eventually (extChartAt_source_mem_nhds (I:=𝓘(ℝ,Model n)) e), + hs.eventually (lt_mem_nhds hsp)] with z hzs hzt hsz + exact (eq_div_iff hsz.ne').mpr (expJacobian_coordinate_identity c z hzs hzt) +end ExpJacContinuity +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpLocalBounds.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpLocalBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..6de4e4d80d43df359bfcbbccb7951de17df55077 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpLocalBounds.lean @@ -0,0 +1,115 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactLocalPositiveBounds +import OAI.Analysis.BiholderTransport.Coordinates.ExpVertical +import OAI.Analysis.BiholderTransport.LinearAlgebra.OperatorBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpLocalBounds +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma eventually_exp_differential_bounds {c : TangentBundle 𝓘(ℝ,Model n) M} + (hc : c.2∈injectivityDomain c.1) : + ∃ l u : ℝ, 0 TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + let U := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let V := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (riemannianExp c.1 c.2) + obtain ⟨l,u,hl,hu,hlu⟩ := eventually_injective_operator_bounds + (coordinateEndpointVertical_continuousAt c) (coordinateEndpointVertical_injective hc) + obtain ⟨CU,hCU,hUb⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + obtain ⟨DU,hDU,hUib⟩ := eventually_norm_symmL_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + obtain ⟨CV,hCV,hVb⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (riemannianExp c.1 c.2) + obtain ⟨DV,hDV,hVib⟩ := eventually_norm_symmL_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (riemannianExp c.1 c.2) + have hproj : Continuous (fun z : TangentBundle 𝓘(ℝ,Model n) M => z.1) := + (Bundle.contMDiff_proj (n := ∞) (IB := 𝓘(ℝ,Model n)) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)).continuous + have hE := (contMDiff_riemannianExp (n := n) (M := M)).continuous.continuousAt (x := c) + have hsource := extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + have htarget := hE.eventually (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) (riemannianExp c.1 c.2)) + refine ⟨l/(DU*CV),DV*u*CU,div_pos hl (mul_pos hDU hCV), + mul_pos (mul_pos hDV hu) hCU,?_⟩ + filter_upwards [hlu,hsource,htarget,hproj.continuousAt.eventually hUb, + hproj.continuousAt.eventually hUib,hE.eventually hVb,hE.eventually hVib] + with z hz hzs hzt hzU hzUi hzV hzVi + have hzUs : z.1∈U.baseSet := by + simpa only [U,TangentBundle.trivializationAt_baseSet,extChartAt_source] + using (tangent_chart_source_iff c z).mp hzs + have hzVs : riemannianExp z.1 z.2∈V.baseSet := by + dsimp only [V] + rw [TangentBundle.trivializationAt_baseSet] + rw [extChartAt_source] at hzt + exact hzt + exact operator_bounds_through_charts (U.continuousLinearMapAt ℝ z.1) (U.symmL ℝ z.1) + (V.continuousLinearMapAt ℝ (riemannianExp z.1 z.2)) (V.symmL ℝ (riemannianExp z.1 z.2)) + (coordinateEndpointVertical c z) + (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) z.1) 𝓘(ℝ,Model n) (riemannianExp z.1) z.2) + (U.symmL_continuousLinearMapAt hzUs) (V.symmL_continuousLinearMapAt hzVs) + (coordinateEndpointVertical_apply c z hzs hzt) + hl hu hCU hDU hCV hDV hzU.le hzUi.le hzV.le hzVi.le hz + +end ExpLocalBounds +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpCompactBounds +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma compact_exp_differential_bounds {K : Set (TangentBundle 𝓘(ℝ,Model n) M)} + (hK : IsCompact K) (hI : ∀ z∈K, z.2∈injectivityDomain z.1) : + ∃ l u : ℝ, 0 eventually_exp_differential_bounds (hI z hz) + +end ExpCompactBounds +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugacy.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugacy.lean new file mode 100644 index 0000000000000000000000000000000000000000..31822baf63b7ec178a388b5ce638b03a131d034a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugacy.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayNonconjugacy + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma riemannianExp_interior_nonconjugate {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : + Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p) := by + obtain ⟨a,ha,hpa⟩ := hp + have hm : dist x (sprayFlow a (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 = a*‖p‖ := by + rw [←riemannianExp_smul] + exact hpa + simpa only [riemannianExp_eq_sprayFlow] using + sprayFlow_interior_nonconjugate x p zero_lt_one ha hm + +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma contMDiff_riemannianExp_fiber (x : M) : + ContMDiff 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) ∞ (riemannianExp (n := n) x) := by + have H := (Bundle.contMDiff_proj (fun z : M => TangentSpace 𝓘(ℝ,Model n) z)).comp + (contMDiff_spray_fiber x 1) + apply H.congr + intro v + exact riemannianExp_eq_sprayFlow x v + +lemma exists_coordinate_exp_inverse {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : + ∃ e : OpenPartialHomeomorph (TangentSpace 𝓘(ℝ,Model n) x) (Model n), + (e : TangentSpace 𝓘(ℝ,Model n) x → Model n) = + (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) (riemannianExp (n := n) x v)) ∧ + p ∈ e.source ∧ ContDiffAt ℝ ∞ e.symm (e p) := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + let f := fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) (riemannianExp (n := n) x v) + have hf : ContDiffAt ℝ ∞ f p := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ + (extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p)) (riemannianExp (n := n) x p) from + contMDiffAt_extChartAt).comp p (contMDiff_riemannianExp_fiber x p)).contDiffAt + let D := fderiv ℝ f p + have hi : Function.Injective D := riemannianExp_interior_nonconjugate hp + let τ := trivializationAt (Model n) (fun b : M => TangentSpace 𝓘(ℝ,Model n) b) x + let L : TangentSpace 𝓘(ℝ,Model n) x ≃L[ℝ] Model n := + τ.continuousLinearEquivAt ℝ x (mem_baseSet_trivializationAt (Model n) _ x) + have hs : Function.Surjective D := + (LinearMap.injective_iff_surjective_of_finrank_eq_finrank L.toLinearEquiv.finrank_eq).mp hi + let A := ContinuousLinearEquiv.ofBijective D (LinearMap.ker_eq_bot.mpr hi) + (LinearMap.range_eq_top.mpr hs) + have hd : HasFDerivAt f (A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] Model n) p := + (hf.differentiableAt (by simp)).hasFDerivAt + let e := hf.toOpenPartialHomeomorph f hd (by simp) + have he : p ∈ e.source := hf.mem_toOpenPartialHomeomorph_source hd (by simp) + refine ⟨e,rfl,he,?_⟩ + apply e.contDiffAt_symm (e.map_source he) + · rw [e.left_inv he] + convert! hd using 1 + · rw [e.left_inv he] + exact hf + +lemma riemannianExp_locally_injective {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : + ∃ U, IsOpen U ∧ p ∈ U ∧ Set.InjOn (riemannianExp (n := n) x) U := by + obtain ⟨e,he,hp',_⟩ := exists_coordinate_exp_inverse hp + refine ⟨e.source,e.open_source,hp',?_⟩ + intro v hv w hw h + apply e.injOn hv hw + rw [he] + exact congrArg (extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p)) h + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugateLimit.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugateLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..092fcf1df0061a4c43a591977a3a33812a00c907 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpNonconjugateLimit.lean @@ -0,0 +1,28 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpNonconjugateLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteNC (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end ExpNonconjugateLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpReciprocity.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpReciprocity.lean new file mode 100644 index 0000000000000000000000000000000000000000..ccc97205e69f87f57e80e4383b5386c388f4e1ff --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpReciprocity.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalLogMixed +import OAI.Analysis.BiholderTransport.Coordinates.LocalInverseCalculus +import OAI.Analysis.BiholderTransport.Regularity.ReciprocalInverses + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_reciprocal_normal_exp_coordinates {x y : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {q : TangentSpace 𝓘(ℝ,Model n) y} + (hp : p∈injectivityDomain x) (hq : q∈injectivityDomain y) + (hpx : riemannianExp x p=y) (hqy : riemannianExp y q=x) : + ∃ L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y, + ∃ R : TangentSpace 𝓘(ℝ,Model n) y → TangentSpace 𝓘(ℝ,Model n) x, + ContDiffAt ℝ ∞ L p ∧ ContDiffAt ℝ ∞ R q ∧ L p=0 ∧ R q=0 ∧ + (∀ᶠ v in 𝓝 p, riemannianExp y (L v)=riemannianExp x v) ∧ + (∀ᶠ w in 𝓝 q, riemannianExp x (R w)=riemannianExp y w) ∧ + ∀ v w, inner ℝ (fderiv ℝ L p v) w=inner ℝ v (fderiv ℝ R q w) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let W := TangentSpace 𝓘(ℝ,Model n) y + obtain ⟨X,hX,hXp,hXi,hXl⟩ := exists_smooth_two_sided_fiber_log hp + obtain ⟨Y,hY,hYq,hYi,hYl⟩ := exists_smooth_two_sided_fiber_log hq + obtain ⟨Nx,hNx,hNx0,hNxi⟩ := exists_smooth_fiber_log (zero_mem_injectivityDomain (n := n) x) + obtain ⟨Ny,hNy,hNy0,hNyi⟩ := exists_smooth_fiber_log (zero_mem_injectivityDomain (n := n) y) + rw [hpx] at hX hXp hXi + rw [hqy] at hY hYq hYi + simp only [riemannianExp_zero] at hNx hNx0 hNxi hNy hNy0 hNyi + let e : W → V := fun w => X (riemannianExp y w) + let f : V → W := fun v => Y (riemannianExp x v) + let L : V → W := fun v => Ny (riemannianExp x v) + let R : W → V := fun w => Nx (riemannianExp y w) + have he : ContDiffAt ℝ ∞ e 0 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ X (riemannianExp y 0) from + by simpa only [riemannianExp_zero] using hX).comp 0 (contMDiff_riemannianExp_fiber y 0)).contDiffAt + have hf : ContDiffAt ℝ ∞ f 0 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,W) ∞ Y (riemannianExp x 0) from + by simpa only [riemannianExp_zero] using hY).comp 0 (contMDiff_riemannianExp_fiber x 0)).contDiffAt + have hL : ContDiffAt ℝ ∞ L p := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,W) ∞ Ny (riemannianExp x p) from + by simpa only [hpx] using hNy).comp p (contMDiff_riemannianExp_fiber x p)).contDiffAt + have hR : ContDiffAt ℝ ∞ R q := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ Nx (riemannianExp y q) from + by simpa only [hqy] using hNx).comp q (contMDiff_riemannianExp_fiber y q)).contDiffAt + have he0 : e 0=p := by dsimp [e]; rw [riemannianExp_zero,hXp] + have hf0 : f 0=q := by dsimp [f]; rw [riemannianExp_zero,hYq] + have hLp : L p=0 := by dsimp [L]; rw [hpx,hNy0] + have hRq : R q=0 := by dsimp [R]; rw [hqy,hNx0] + have hei : ∀ᶠ w in 𝓝 (0:W), riemannianExp x (e w)=riemannianExp y w := + (show ContinuousAt (riemannianExp y) (0:W) from (continuous_riemannianExp y).continuousAt).eventually + (by simpa only [riemannianExp_zero] using hXi) + have hfi : ∀ᶠ v in 𝓝 (0:V), riemannianExp y (f v)=riemannianExp x v := + (show ContinuousAt (riemannianExp x) (0:V) from (continuous_riemannianExp x).continuousAt).eventually + (by simpa only [riemannianExp_zero] using hYi) + have hLi : ∀ᶠ v in 𝓝 p, riemannianExp y (L v)=riemannianExp x v := + (show ContinuousAt (riemannianExp x) p from (continuous_riemannianExp x).continuousAt).eventually + (by simpa only [hpx] using hNyi) + have hRi : ∀ᶠ w in 𝓝 q, riemannianExp x (R w)=riemannianExp y w := + (show ContinuousAt (riemannianExp y) q from (continuous_riemannianExp y).continuousAt).eventually + (by simpa only [hqy] using hNxi) + have heL : (fun v => e (L v)) =ᶠ[𝓝 p] (fun v => v) := by + filter_upwards [hLi,hXl] with v hvi hvl + change X (riemannianExp y (L v))=v + rw [hvi] + exact hvl + have hfR : (fun w => f (R w)) =ᶠ[𝓝 q] (fun w => w) := by + filter_upwards [hRi,hYl] with w hwi hwl + change Y (riemannianExp x (R w))=w + rw [hwi] + exact hwl + have hAL : ∀ v:V, fderiv ℝ e 0 (fderiv ℝ L p v)=v := by + intro v + have H := local_inverse_derivative (by simpa only [hLp] using he.differentiableAt (by simp)) + (hL.differentiableAt (by simp)) heL v + simpa only [hLp] using H + have hBR : ∀ w:W, fderiv ℝ f 0 (fderiv ℝ R q w)=w := by + intro w + have H := local_inverse_derivative (by simpa only [hRq] using hf.differentiableAt (by simp)) + (hR.differentiableAt (by simp)) hfR w + simpa only [hRq] using H + refine ⟨L,R,hL,hR,hLp,hRq,hLi,hRi,?_⟩ + exact reciprocal_inverses (normal_log_derivatives_adjoint he hf (he0 ▸ hp) (hf0 ▸ hq) hei hfi) hAL hBR + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpVertical.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpVertical.lean new file mode 100644 index 0000000000000000000000000000000000000000..8b10fb7cc4b3096f634959f4db96380768b38adc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ExpVertical.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.ExponentialJacobian +import OAI.Analysis.BiholderTransport.Coordinates.SplitLogInjective + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpVertical +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma coordinateEndpointVertical_continuousAt (c : TangentBundle 𝓘(ℝ,Model n) M) : + ContinuousAt (coordinateEndpointVertical c) c := by + have hG := coordinateEndpoint_contDiffAt c c (mem_extChartAt_source c) + (mem_extChartAt_source (riemannianExp c.1 c.2)) + have hG2 : ContDiffAt ℝ 2 (coordinateEndpoint c) + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c c) := + hG.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hD := (hG2.fderiv_right (m := 1) (by norm_num)).continuousAt + have hχ := (contMDiffAt_extChartAt (I := 𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (n := ∞) (x := c)).continuousAt + exact (hD.comp hχ).clm_comp continuousAt_const + +lemma coordinateEndpointVertical_injective {c : TangentBundle 𝓘(ℝ,Model n) M} + (hc : c.2∈injectivityDomain c.1) : Function.Injective (coordinateEndpointVertical c c) := by + let X := TangentSpace 𝓘(ℝ,Model n) c.1 + let Y := TangentSpace 𝓘(ℝ,Model n) (riemannianExp c.1 c.2) + let U := (trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1) + let V := (trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (riemannianExp c.1 c.2)) + have hU : c.1∈U.baseSet := mem_baseSet_trivializationAt (Model n) _ c.1 + have hV : riemannianExp c.1 c.2∈V.baseSet := mem_baseSet_trivializationAt (Model n) _ _ + have hE := (expJacobian_ne_zero_iff (n := n) c.1 c.2).mp + (expJacobian_pos_of_injectivityDomain hc).ne' + apply (injective_iff_map_eq_zero _).mpr + intro w hw + let u : X := U.symmL ℝ c.1 w + have huw : U.continuousLinearMapAt ℝ c.1 u=w := U.continuousLinearMapAt_symmL hU w + have heq := coordinateEndpointVertical_apply c c (mem_extChartAt_source c) + (mem_extChartAt_source _) u + rw [huw,hw] at heq + have hz : mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp c.1) c.2 u=0 := by + have h := congrArg (V.symmL ℝ (riemannianExp c.1 c.2)) heq.symm + rw [V.symmL_continuousLinearMapAt hV,map_zero] at h + exact h + have hu : u=0 := hE (hz.trans (map_zero _).symm) + rw [←huw,hu,map_zero] + +end ExpVertical +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FactorNorm.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FactorNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..188d5fd8eeac67b0a5d6b1880654dcbf43b286cd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FactorNorm.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.RadialIdentity +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.Coordinates.ProperPieces +import OAI.Analysis.BiholderTransport.Coordinates.ExpLocalBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FactorNorm +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma prefix_log_fderiv_exp_norm {x y : M} {t : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hq : DifferentiableAt ℝ q p) + (hqr : ∀ᶠ a in 𝓝 p, riemannianExp y (q a)=riemannianExp x (t • a)) + (v : TangentSpace 𝓘(ℝ,Model n) x) : + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) y) 𝓘(ℝ,Model n) + (riemannianExp y) (q p) (fderiv ℝ q p v)‖= + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) (t • p) (t • v)‖ := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + have he := (contMDiff_riemannianExp_fiber y (q p)).mdifferentiableAt (by simp) + have hD := he.hasMFDerivAt.comp p hq.hasFDerivAt.hasMFDerivAt + have hqr' : (riemannianExp y ∘ q) =ᶠ[𝓝 p] (fun a : X => riemannianExp x (t • a)) := hqr + have hD' := hD.congr_of_eventuallyEq hqr'.symm + have hscale : HasFDerivAt (fun a : X => t • a) (t • ContinuousLinearMap.id ℝ X) p := + (t • ContinuousLinearMap.id ℝ X).hasFDerivAt + have hExp := ((contMDiff_riemannianExp_fiber x (t • p)).mdifferentiableAt + (by simp)).hasMFDerivAt.comp p hscale.hasMFDerivAt + have hN := congrArg (fun L : X →L[ℝ] TangentSpace 𝓘(ℝ,Model n) + (riemannianExp x (t • p)) => ‖L v‖) (hD'.mfderiv.symm.trans hExp.mfderiv) + have he0 := hqr.self_of_nhds + convert! hN using 1 + congr 1 + rw [he0] + +lemma prefix_zero_log_fderiv_norm {x y : M} {t : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hq : DifferentiableAt ℝ q p) (hqp : q p=0) + (hqr : ∀ᶠ a in 𝓝 p, riemannianExp y (q a)=riemannianExp x (t • a)) + (v : TangentSpace 𝓘(ℝ,Model n) x) : + ‖fderiv ℝ q p v‖= + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) (t • p) (t • v)‖ := by + have H := prefix_log_fderiv_exp_norm hq hqr v + rw [hqp,mfderiv_exp_zero_norm] at H + exact H + +end FactorNorm +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformPieces +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma suffix_log_total_eq_reverse {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + (hp : p∈minimizingVectors x) (ht : 0 tangentScale q.1 q.2 + let R : ℝ × TangentBundle 𝓘(ℝ,Model n) M → TangentBundle 𝓘(ℝ,Model n) M := + fun q => reverseRay (tangentScale (1-q.1) (sprayFlow q.1 q.2)) + have hP : Continuous P := contMDiff_tangentScale.continuous + have hR : Continuous R := continuous_reverseRay.comp (contMDiff_tangentScale.continuous.comp + ((continuous_const.sub continuous_fst).prodMk contMDiff_sprayFlow.continuous)) + have hS : IsCompact S := isCompact_Icc.prod (isCompact_total_minimizingVectors (n := n) (M := M)) + have hK : IsCompact (P '' S ∪ R '' S) := (hS.image hP).union (hS.image hR) + have hI : ∀ w∈P '' S ∪ R '' S, w.2∈injectivityDomain w.1 := by + intro w hw + rcases hw with hw | hw + · rcases hw with ⟨⟨t,z⟩,htz,rfl⟩ + exact contracted_minimizer_mem_injectivityDomain htz.2 (by linarith [htz.1.1]) + (by linarith [htz.1.2]) + · rcases hw with ⟨⟨t,z⟩,htz,rfl⟩ + exact reverseRay_injectivityDomain (proper_suffix_in_injectivityDomain htz.2 + (by linarith [htz.1.1]) (by linarith [htz.1.2]) le_rfl) + obtain ⟨l,u,hl,hu,H⟩ := compact_exp_differential_bounds hK hI + refine ⟨l,u,hl,hu,?_⟩ + intro z hz t ht + exact ⟨H (P (t,z)) (Or.inl (mem_image_of_mem _ ⟨ht,hz⟩)), + H (R (t,z)) (Or.inr (mem_image_of_mem _ ⟨ht,hz⟩))⟩ + +end UniformPieces +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberLog.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0c28966983677335c2e2979319899179015b706 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberLog.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugacy + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_fiber_log {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : + ∃ L : M → TangentSpace 𝓘(ℝ,Model n) x, + ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) ∞ L + (riemannianExp x p) ∧ + L (riemannianExp x p)=p ∧ + (∀ᶠ y in 𝓝 (riemannianExp x p), riemannianExp x (L y)=y) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + let d := extChartAt 𝓘(ℝ,Model n) y + obtain ⟨e,he,hpe,hei⟩ := exists_coordinate_exp_inverse hp + have hep : e p=d y := by rw [he] + let L : M → V := fun z => e.symm (d z) + have hL : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ L y := + (show ContDiffAt ℝ ∞ e.symm (d y) from hep ▸ hei).contMDiffAt.comp y + (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y from contMDiffAt_extChartAt) + have hLy : L y=p := by dsimp [L]; rw [←hep,e.left_inv hpe] + refine ⟨L,hL,hLy,?_⟩ + have ht : ∀ᶠ z in 𝓝 y, d z∈e.target := + (continuousAt_extChartAt y).eventually + ((e.open_target.mem_nhds (hep ▸ e.map_source hpe))) + have hcont : ContinuousAt (fun z => riemannianExp x (L z)) y := + (continuous_riemannianExp x).continuousAt.comp hL.continuousAt + have hs : ∀ᶠ z in 𝓝 y, riemannianExp x (L z)∈d.source := by + have H := hcont.eventually (show d.source∈𝓝 (riemannianExp x (L y)) from by + rw [hLy]; exact extChartAt_source_mem_nhds y) + exact H + filter_upwards [ht,hs,extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) y] with z hzt hzs hsz + apply d.injOn hzs hsz + have HR := e.right_inv hzt + rw [he] at HR + exact HR + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_chart_fiber_log {x a : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) + (ha : riemannianExp x p∈(extChartAt 𝓘(ℝ,Model n) a).source) : + let ψ := extChartAt 𝓘(ℝ,Model n) a + let u := ψ (riemannianExp x p) + ∃ e : Model n → TangentSpace 𝓘(ℝ,Model n) x, + ContDiffAt ℝ ∞ e u ∧ e u=p ∧ + (∀ᶠ w in 𝓝 u, riemannianExp x (e w)=ψ.symm w) ∧ + Function.Injective (fderiv ℝ e u) := by + let ψ := extChartAt 𝓘(ℝ,Model n) a + let u := ψ (riemannianExp x p) + let V := TangentSpace 𝓘(ℝ,Model n) x + have hu : u∈ψ.target := ψ.map_source ha + have hui : ψ.symm u=riemannianExp x p := ψ.left_inv ha + obtain ⟨L,hL,hLp,hLi⟩ := exists_smooth_fiber_log hp + have hi : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ ψ.symm u := + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds hu) + let e := fun w : Model n => L (ψ.symm w) + have he : ContDiffAt ℝ ∞ e u := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ L (ψ.symm u) from by + simpa only [hui] using hL).comp u hi).contDiffAt + have heu : e u=p := by dsimp [e]; rw [hui]; exact hLp + have hei : ∀ᶠ w in 𝓝 u, riemannianExp x (e w)=ψ.symm w := + hi.continuousAt.eventually (by simpa only [hui] using hLi) + refine ⟨e,he,heu,hei,?_⟩ + let c : V → Model n := fun v => ψ (riemannianExp x v) + have hc : ContDiffAt ℝ ∞ c p := + ((contMDiffAt_extChartAt' (I := 𝓘(ℝ,Model n)) (by + simpa only [extChartAt_source] using ha)).comp p + (contMDiff_riemannianExp_fiber x p)).contDiffAt + have hid : (fun w => c (e w)) =ᶠ[𝓝 u] (fun w => w) := by + filter_upwards [hei,(isOpen_extChartAt_target a).mem_nhds hu] with w hw hwt + dsimp [c] + rw [hw,ψ.right_inv hwt] + have HD := hid.fderiv_eq (𝕜 := ℝ) + rw [fderiv_fun_comp u (by simpa only [heu] using hc.differentiableAt (by simp)) + (he.differentiableAt (by simp)),fderiv_fun_id] at HD + intro v w hvw + change fderiv ℝ e u v=fderiv ℝ e u w at hvw + have H := congrArg (fun C : Model n →L[ℝ] Model n => C v-C w) HD + apply sub_eq_zero.mp + simpa only [ContinuousLinearMap.comp_apply,hvw,sub_self,ContinuousLinearMap.id_apply] using H.symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberNormal.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberNormal.lean new file mode 100644 index 0000000000000000000000000000000000000000..49f5ac7e4a9d61af6be3d5900de0e3b76d273318 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiberNormal.lean @@ -0,0 +1,40 @@ +import Mathlib + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma outward_inner_ratio {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {p e : E} {t D κ L : ℝ} (he : ‖e‖=1) (ht : 0 h)).snd + continuousOn_invFun := (e.symm.continuousOn.comp + (continuous_const.prodMk continuous_id).continuousOn (fun _ h => h)).snd + open_source := e.open_source.preimage (continuous_const.prodMk continuous_id) + open_target := e.open_target.preimage (continuous_const.prodMk continuous_id) + +end FiberwiseHomeomorphism + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma fiberwiseHomeomorph_contDiffOn + {e : OpenPartialHomeomorph (E × F) (E × F)} + (he : ∀ z : E × F, (e z).1 = z.1) (x : E) + (hsm : ContDiffOn ℝ ∞ e e.source) : + ContDiffOn ℝ ∞ (fiberwiseHomeomorph e he x) (fiberwiseHomeomorph e he x).source := + (hsm.comp (contDiffOn_const.prodMk contDiffOn_id) (fun _ h => h)).snd + +lemma fiberwiseHomeomorph_symm_contDiffOn + {e : OpenPartialHomeomorph (E × F) (E × F)} + (he : ∀ z : E × F, (e z).1 = z.1) (x : E) + (hsm : ContDiffOn ℝ ∞ e.symm e.target) : + ContDiffOn ℝ ∞ (fiberwiseHomeomorph e he x).symm (fiberwiseHomeomorph e he x).target := + (hsm.comp (contDiffOn_const.prodMk contDiffOn_id) (fun _ h => h)).snd + +variable [FiniteDimensional ℝ E] [FiniteDimensional ℝ F] + +lemma first_coordinate_preserving_derivative_invertible {f : E × F → F} {x : E} {v : F} + (hf : DifferentiableAt ℝ f (x,v)) + (hi : (fderiv ℝ (fun w => f (x,w)) v).IsInvertible) : + (fderiv ℝ (fun z : E × F => (z.1,f z)) (x,v)).IsInvertible := by + let L := fderiv ℝ (fun z : E × F => (z.1,f z)) (x,v) + have hL : L = (ContinuousLinearMap.fst ℝ E F).prod (fderiv ℝ f (x,v)) := + ((ContinuousLinearMap.fst ℝ E F).hasFDerivAt.prodMk hf.hasFDerivAt).fderiv + have hpart : fderiv ℝ (fun w => f (x,w)) v = + (fderiv ℝ f (x,v)).comp (ContinuousLinearMap.inr ℝ E F) := + (hf.hasFDerivAt.comp v ((hasFDerivAt_const x v).prodMk (hasFDerivAt_id v))).fderiv + have hinj : Function.Injective L := by + intro a b hab + have hd : L (a-b) = 0 := by rw [map_sub,hab,sub_self] + have hx : a.1-b.1 = 0 := by + have h := congrArg Prod.fst hd + rw [hL] at h + exact h + have hv : a.2-b.2 = 0 := by + apply hi.injective + have h := congrArg Prod.snd hd + have hz : a-b = (0,a.2-b.2) := Prod.ext hx rfl + change (fderiv ℝ (fun w => f (x,w)) v) (a.2-b.2) = + (fderiv ℝ (fun w => f (x,w)) v) 0 + rw [map_zero,hpart] + rw [hL,hz] at h + exact h + exact Prod.ext (sub_eq_zero.mp hx) (sub_eq_zero.mp hv) + have hsur : Function.Surjective L := LinearMap.injective_iff_surjective.mp hinj + exact ⟨ContinuousLinearEquiv.ofBijective L (LinearMap.ker_eq_bot.mpr hinj) + (LinearMap.range_eq_top.mpr hsur),rfl⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteActiveGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteActiveGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..9519f0a726b236c3241877c1d3f53ba8ee5c49f4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteActiveGrowth.lean @@ -0,0 +1,282 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.StrictDividedAction +import OAI.Analysis.BiholderTransport.Calculus.FiniteSmoothTransverseGrowth +import OAI.Analysis.BiholderTransport.Regularity.SecondScaled + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma normalCost_hasFDerivAt_zero {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : + HasFDerivAt (normalCost x p) (innerSL ℝ (-p)) 0 := by + apply ((normalCost_contDiffAt hp).differentiableAt (by simp)).hasFDerivAt.congr_fderiv + ext v + have H := (normalCost_radial_fderiv_near_zero hp v).self_of_nhds + simpa only [zero_smul,zero_sub,neg_one_mul,innerSL_apply_apply,inner_neg_left] using H + +lemma WeakMTW.finite_active_cost_growth (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 00, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, ∃ i, + b*‖h‖^2≤ + (normalCost x (t • (∑ j, w j • p j)) h-normalCost x (t • (∑ j, w j • p j)) 0)/t- + (normalCost x (s • p i) h-normalCost x (s • p i) 0)/s := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + let r := ∑ j, w j • p j + have hrh : r ∈ convexHull ℝ (range p) := + (convex_convexHull ℝ (range p)).sum_mem (fun i _ => (hw i).le) hsum + (fun i _ => subset_convexHull ℝ (range p) (mem_range_self i)) + have hrt := hID r hrh + have hsi : ∀ i, s • p i ∈ injectivityDomain x := + fun i => contracted_minimizer_mem_injectivityDomain (hmin i) (ht.trans hts) hs + let f := fun i (h : TangentSpace 𝓘(ℝ,Model n) x) => + t⁻¹*(normalCost x (t • r) h-normalCost x (t • r) 0)- + s⁻¹*(normalCost x (s • p i) h-normalCost x (s • p i) 0) + have hleft : ContDiffAt ℝ 2 (normalCost x (t • r)) 0 := + (normalCost_contDiffAt hrt).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hright : ∀ i, ContDiffAt ℝ 2 (normalCost x (s • p i)) 0 := + fun i => (normalCost_contDiffAt (hsi i)).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hf : ∀ i, ContDiffAt ℝ 2 (f i) 0 := fun i => + (contDiffAt_const.mul (hleft.sub contDiffAt_const)).sub + (contDiffAt_const.mul ((hright i).sub contDiffAt_const)) + have hfirst : ∀ i, fderiv ℝ (f i) 0=innerSL ℝ (p i-r) := by + intro i + have H := (((normalCost_hasFDerivAt_zero hrt).sub_const (normalCost x (t • r) 0)).const_smul t⁻¹).sub + (((normalCost_hasFDerivAt_zero (hsi i)).sub_const (normalCost x (s • p i) 0)).const_smul s⁻¹) + have H' : HasFDerivAt (f i) (innerSL ℝ (p i-r)) 0 := by + apply H.congr_fderiv + ext v + simp only [sub_apply,smul_apply,innerSL_apply_apply,inner_neg_left, + real_inner_smul_left,inner_sub_left,smul_eq_mul] + field_simp [ht.ne', (ht.trans hts).ne'] + ring + exact H'.fderiv + have hsecond : ∀ i v, fderiv ℝ (fderiv ℝ (f i)) 0 v v= + hessianValue x (t • r) v/t-hessianValue x (s • p i) v/s := by + intro i v + rw [second_fderiv_scaled_differences hleft (hright i)] + rw [hessianValue_eq_normalHessian hrt,hessianValue_eq_normalHessian (hsi i)] + simp only [normalHessian,div_eq_mul_inv] + ring + have hmean : ∀ v, ∑ i, w i*fderiv ℝ (f i) 0 v=0 := by + intro v + simp only [hfirst,innerSL_apply_apply,inner_sub_left,mul_sub,Finset.sum_sub_distrib, + ←Finset.sum_mul,hsum,one_mul] + have heq : (∑ i, w i*inner ℝ (p i) v)=inner ℝ r v := by + simp only [r,sum_inner,real_inner_smul_left] + rw [heq,sub_self] + have hpos : ∀ v, v≠0 → (∀ i, fderiv ℝ (f i) 0 v=0) → + 0<∑ i, w i*fderiv ℝ (fderiv ℝ (f i)) 0 v v := by + intro v hv hl + have hortho : ∀ i, inner ℝ v (p i-r)=0 := by + intro i + rw [real_inner_comm] + simpa only [hfirst,innerSL_apply_apply] using hl i + have H := hmtw.finite_transverse_slack_strict p w hw hsum hmin ht hts hs hID hv hortho + simp only [hsecond,mul_sub,Finset.sum_sub_distrib,←Finset.sum_mul,hsum,one_mul] + exact sub_pos.mpr H + obtain ⟨b,hb,H⟩ := finite_smooth_transverse_growth f hf (fun i => by simp [f]) w hw hsum hmean hpos + refine ⟨b,hb,?_⟩ + filter_upwards [H] with h hh + obtain ⟨i,hi⟩ := hh + refine ⟨i,?_⟩ + simpa only [f,r,div_eq_mul_inv,mul_comm] using hi +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteLogScaleAvoidance.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteLogScaleAvoidance.lean new file mode 100644 index 0000000000000000000000000000000000000000..a24f9d9f1690d1bad36596865d38361ea9623333 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FiniteLogScaleAvoidance.lean @@ -0,0 +1,75 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma finite_log_scale_avoidance (S : Finset ℝ) {lo hi L : ℝ} (hL : 0≤L) + (hwide : lo+((S.card:ℝ)+2)*(2*L+1) lo+((i.val:ℝ)+1)*(2*L+1) + have hu (i : Fin (S.card+1)) : u i∈Ioo lo hi := by + have hv0 : (0:ℝ)≤ i.val := Nat.cast_nonneg _ + have hv1 : (i.val:ℝ)<(S.card:ℝ)+1 := by exact_mod_cast i.isLt + dsimp [u] + constructor <;> nlinarith [mul_nonneg (show 0≤(S.card:ℝ)+1-i.val by linarith) (show 0≤2*L+1 by linarith)] + by_contra h + have hex (i : Fin (S.card+1)) : ∃ s : {s // s∈S}, |u i-s.val|≤L := by + by_contra H + apply h + refine ⟨u i,hu i,?_⟩ + intro s hs + by_contra hh + exact H ⟨⟨s,hs⟩,le_of_not_gt hh⟩ + let g : Fin (S.card+1) → {s // s∈S} := fun i => (hex i).choose + have hg (i : Fin (S.card+1)) : |u i-(g i).val|≤L := (hex i).choose_spec + have hsep (i j : Fin (S.card+1)) (hij : i.val exact hzero + | succ k ih => + have hc := ih (by omega) + rcases hbin (k+1) hk with hsmall|hlarge + · have hs := (abs_le.mp (hstep k (by omega))).1 + linarith + · exact hlarge + exact H N le_rfl +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinDifference.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinDifference.lean new file mode 100644 index 0000000000000000000000000000000000000000..353b6fb071292880e658490f7c4f52a5014d4a0c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinDifference.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FixedJoinMiddle +import OAI.Analysis.BiholderTransport.CostGeometry.DividedPullback + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma fixedJoinMiddle_difference_normal {x z : M} {h T t : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} {q : TangentSpace 𝓘(ℝ,Model n) z} + {g : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) z} + (ht : t≠0) (htime : T-h=(1-h)*t) + (hq : q∈injectivityDomain z) (htq : t • q∈injectivityDomain z) + (hq1 : riemannianExp z q=riemannianExp x p) + (hqT : riemannianExp z (t • q)=riemannianExp x (T • p)) + (hg : ContDiffAt ℝ 2 g p) (hg0 : g p=0) + (hgi : ∀ᶠ b in 𝓝 p, riemannianExp z (g b)=riemannianExp x (h • b)) + (hBT : ContDiffAt ℝ 2 (fixedJoinAction x h T p) (0,p)) + (hB1 : ContDiffAt ℝ 2 (fixedJoinAction x h 1 p) (0,p)) + (k : TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinMiddle x h T p k k-fixedJoinMiddle x h 1 p k k= + (hessianValue z (t • q) (fderiv ℝ g p k)/t- + hessianValue z q (fderiv ℝ g p k))/(1-h) := by + have hST := hBT.comp p (contDiffAt_const.prodMk contDiffAt_id) + have hS1 := hB1.comp p (contDiffAt_const.prodMk contDiffAt_id) + change ContDiffAt ℝ 2 (fun b => fixedJoinAction x h T p (0,b)) p at hST + change ContDiffAt ℝ 2 (fun b => fixedJoinAction x h 1 p (0,b)) p at hS1 + have he : (fun b => fixedJoinAction x h T p (0,b)-fixedJoinAction x h 1 p (0,b)) =ᶠ[𝓝 p] + (fun b => (1-h)⁻¹*(normalCost z (t • q) (g b)/t-normalCost z q (g b))) := by + filter_upwards [hgi] with b hb + simp only [fixedJoinAction,normalCost,hb,hq1,hqT,one_smul,htime,div_eq_mul_inv,mul_inv_rev] + ring + have H := congrArg (fun A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => A k k) (he.fderiv (𝕜 := ℝ)).fderiv_eq + rw [second_fderiv_sub hST hS1,second_fderiv_const_mul, + divided_cost_difference_pullback hq htq ht hg hg0] at H + rw [fixedJoinMiddle_eq_slice hBT,fixedJoinMiddle_eq_slice hB1] + simpa only [div_eq_mul_inv,mul_comm] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinSmooth.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinSmooth.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6b264ab56647f6beee1f638d059d30d58d0acce --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/FixedJoinSmooth.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.StationaryPullback + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma shifted_exp_time (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) (h T : ℝ) : + riemannianExp (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + ((T-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2)= + riemannianExp x (T • p) := by + rw [riemannianExp_eq_sprayFlow] + change (sprayFlow 1 (tangentScale (T-h) (sprayFlow h ⟨x,p⟩))).1=_ + rw [sprayFlow_scale,mul_one,←sprayFlow_add,sub_add_cancel,riemannianExp_smul] + rfl + +lemma fixedJoinAction_joint_contDiffAt {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hTh : T≠h) + (hleft : h • p∈injectivityDomain x) + (hright : (T-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (fun q : ℝ × (TangentSpace 𝓘(ℝ,Model n) x × + (TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x)) => + fixedJoinAction x h q.1 q.2.1 q.2.2) (T,(p,(0,p))) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let a : ℝ × (V×(V×V)) := (T,(p,(0,p))) + have he := contMDiff_riemannianExp_fiber (n := n) x + have hu : ContMDiffAt 𝓘(ℝ,ℝ×(V×(V×V))) 𝓘(ℝ,Model n) ∞ + (fun q : ℝ×(V×(V×V)) => riemannianExp x q.2.2.1) a := + (he _).comp a (show ContDiffAt ℝ ∞ (fun q : ℝ×(V×(V×V)) => q.2.2.1) a from by fun_prop).contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,ℝ×(V×(V×V))) 𝓘(ℝ,Model n) ∞ + (fun q : ℝ×(V×(V×V)) => riemannianExp x (h • q.2.2.2)) a := + (he _).comp a (show ContDiffAt ℝ ∞ (fun q : ℝ×(V×(V×V)) => h • q.2.2.2) a from by fun_prop).contMDiffAt + have hw : ContMDiffAt 𝓘(ℝ,ℝ×(V×(V×V))) 𝓘(ℝ,Model n) ∞ + (fun q : ℝ×(V×(V×V)) => riemannianExp x (q.1 • q.2.1)) a := + (he _).comp a (show ContDiffAt ℝ ∞ (fun q : ℝ×(V×(V×V)) => q.1 • q.2.1) a from by fun_prop).contMDiffAt + have hc₁ := cost_contMDiffAt_of_injectivityDomain + (⟨x,h • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hleft + have hc₂ := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (T-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + have hc₁' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0:V),riemannianExp x (h • p)) := by + simpa only [riemannianExp_zero] using hc₁ + have hc₂' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (h • p),riemannianExp x (T • p)) := by + dsimp only at hc₂ + rw [shifted_exp_time] at hc₂ + simpa only [riemannianExp_smul] using hc₂ + exact ((hc₁'.comp a (hu.prodMk hv)).contDiffAt.div_const h).add + (((hc₂'.comp a (hv.prodMk hw)).contDiffAt).div + (contDiffAt_fst.sub contDiffAt_const) (sub_ne_zero.mpr hTh)) + +lemma fixedJoinAction_contDiffAt {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hTh : T≠h) + (hleft : h • p∈injectivityDomain x) + (hright : (T-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (fixedJoinAction x h T p) (0,p) := by + exact (fixedJoinAction_joint_contDiffAt hTh hleft hright).comp (0,p) + (contDiffAt_const.prodMk (contDiffAt_const.prodMk contDiffAt_id)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/GraphCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/GraphCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..70f4513cf06305e54fe4f2fbd0a715174dfdc213 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/GraphCoordinates.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.UniformEnvelope +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters +import OAI.Analysis.BiholderTransport.Regularity.MovingPrefix + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def graphBaseCoordinate (a : M) (q : TangentBundle 𝓘(ℝ,Model n) M) : Model n := + extChartAt 𝓘(ℝ,Model n) a q.1 + +def graphVelocityCoordinate (a : M) (q : TangentBundle 𝓘(ℝ,Model n) M) : Model n := + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) q).2 + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] in +lemma graph_coordinate_reconstruction {a : M} {q : TangentBundle 𝓘(ℝ,Model n) M} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm (graphBaseCoordinate a q), + chartFiberInverse a (graphBaseCoordinate a q) (graphVelocityCoordinate a q)⟩ : + TangentBundle 𝓘(ℝ,Model n) M)=q := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hs : q∈χ.source := (tangent_chart_source_iff _ _).mpr hq + have hb : (χ q).1∈(extChartAt 𝓘(ℝ,Model n) a).target := + (tangent_chart_target_iff _ _).mp (χ.map_source hs) + have H := χ.left_inv hs + rw [tangent_chart_symm_trivialization hb] at H + exact H + +lemma movingPrefix_graph_coordinates {a : M} {q : TangentBundle 𝓘(ℝ,Model n) M} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).source) (t : ℝ) : + movingPrefix a t (graphBaseCoordinate a q) (graphVelocityCoordinate a q)= + riemannianExp q.1 (t • q.2) := by + simp only [graphBaseCoordinate] + rw [movingPrefix_eq ((extChartAt 𝓘(ℝ,Model n) a).map_source hq)] + exact congrArg (fun z:TangentBundle 𝓘(ℝ,Model n) M=>riemannianExp z.1 (t • z.2)) + (graph_coordinate_reconstruction hq) + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] in +lemma graph_coordinates_at_center (q : TangentBundle 𝓘(ℝ,Model n) M) : + graphVelocityCoordinate q.1 q=q.2 := by + unfold graphVelocityCoordinate + rw [tangent_chart_apply] + exact tangentCoordChange_self (I := 𝓘(ℝ,Model n)) (mem_extChartAt_source q.1) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Inner.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Inner.lean new file mode 100644 index 0000000000000000000000000000000000000000..b988d7b758cb69ddee22e72f021d78eb531f11f9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Inner.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section Inner +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma hasQuadraticExpansion_iff_isLittleO {f : E → ℝ} {p : E} {A : E →L[ℝ] E} : + HasQuadraticExpansion f p A ↔ + (fun h => f h - quadraticTaylor (f 0) p A h) =o[𝓝 0] (fun h : E => ‖h‖^2) := by + rw [Asymptotics.isLittleO_iff] + constructor + · intro H c hc + obtain ⟨d,hd,hbound⟩ := H c hc + filter_upwards [Metric.ball_mem_nhds (0:E) hd] with h hh + simpa only [Set.mem_ofPred_eq,Real.norm_eq_abs,abs_of_nonneg (sq_nonneg ‖h‖)] using + hbound h (by simpa only [Metric.mem_ball,dist_zero_right] using hh) + · intro H c hc + obtain ⟨d,hd,hbound⟩ := Metric.mem_nhds_iff.mp (H hc) + refine ⟨d,hd,?_⟩ + intro h hh + simpa only [Set.mem_ofPred_eq,Real.norm_eq_abs,abs_of_nonneg (sq_nonneg ‖h‖)] using + hbound (show h ∈ Metric.ball (0:E) d by simpa only [Metric.mem_ball,dist_zero_right] using hh) +end Inner +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/IntrinsicGradient.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/IntrinsicGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..605d1fda94ae3a5fdb8f5bfc40626eea24ae82fb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/IntrinsicGradient.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TangentLift +import OAI.Analysis.BiholderTransport.Coordinates.ChartTransition + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma mfderiv_extChartAt_eq_tangentCoordChange {a y : M} + (hy : y ∈ (extChartAt 𝓘(ℝ,E) a).source) : + mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y = + tangentCoordChange 𝓘(ℝ,E) y a y := by + have hy' : y ∈ (chartAt E a).source := by simpa only [extChartAt_source] using hy + rw [(hasMFDerivAt_extChartAt (I := 𝓘(ℝ,E)) hy').mfderiv, + mfderiv_chartAt_eq_tangentCoordChange hy'] + +lemma coordinate_metric_chart_pairing {a y : M} + (hy : y ∈ (extChartAt 𝓘(ℝ,E) a).source) + (u v : TangentSpace 𝓘(ℝ,E) y) : + riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a y) + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y u) + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) y v) = inner ℝ u v := by + let c := extChartAt 𝓘(ℝ,E) a + let e := trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a + have hy' : y ∈ (chartAt E a).source := by simpa only [extChartAt_source] using hy + have hbase : y ∈ e.baseSet := hy' + have hInv : ∀ w : TangentSpace 𝓘(ℝ,E) y, + e.symmL ℝ y (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c y w) = w := by + intro w + have hh := e.symmL_continuousLinearMapAt (R := ℝ) hbase w + rw [TangentBundle.continuousLinearMapAt_trivializationAt hy'] at hh + exact hh + erw [riemannianCoordinateMetric_apply,c.left_inv hy,hInv u,hInv v] + +lemma hasMFDerivAt_of_coordinate_gradient {a : M} (z : TangentBundle 𝓘(ℝ,E) M) + (hz : z.1 ∈ (extChartAt 𝓘(ℝ,E) a).source) (f : M → ℝ) (τ : ℝ) + (hD : HasFDerivAt (fun w : E => f ((extChartAt 𝓘(ℝ,E) a).symm w)) + (τ • riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a z.1) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) z).2)) + (extChartAt 𝓘(ℝ,E) a z.1)) : + HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f z.1 (τ • innerSL ℝ z.2) := by + let c := extChartAt 𝓘(ℝ,E) a + have hz' : z.1 ∈ (chartAt E a).source := by simpa only [extChartAt_source] using hz + have hDc := (mdifferentiableAt_extChartAt (I := 𝓘(ℝ,E)) hz').hasMFDerivAt + have H := hD.hasMFDerivAt.comp z.1 hDc + have heq : f =ᶠ[𝓝 z.1] (fun x : M => f (c.symm (c x))) := by + filter_upwards [(isOpen_extChartAt_source a).mem_nhds hz] with x hx + rw [c.left_inv hx] + have H' := H.congr_of_eventuallyEq heq + apply H'.congr_mfderiv + ext w + change τ * riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a z.1) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) z).2) + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) (extChartAt 𝓘(ℝ,E) a) z.1 w) = τ * inner ℝ z.2 w + congr 1 + rw [tangent_chart_apply] + rw [←mfderiv_extChartAt_eq_tangentCoordChange hz] + exact coordinate_metric_chart_pairing hz z.2 w + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/JetDiffeomorphism.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/JetDiffeomorphism.lean new file mode 100644 index 0000000000000000000000000000000000000000..ff3a5512a92e0f7f011873ad5397c1b8cb88031f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/JetDiffeomorphism.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LowerTaylor +import OAI.Analysis.BiholderTransport.Calculus.LowerTaylorComposition +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma lower_jet_diffeomorphism_bound + {f:E → F} {g:F → E} {p:E} {A:E →L[ℝ] F} {J:F →L[ℝ] E} + (hf:HasFDerivAt f A p) (hg:HasFDerivAt g J (f p)) + (hgf:(fun x=>g (f x)) =ᶠ[𝓝 p] id) + (hfg:(fun y=>f (g y)) =ᶠ[𝓝 (f p)] id) + {v:F → ℝ} {B:E →L[ℝ] E →L[ℝ] ℝ} + (hjet:HasLowerSecondTaylor (fun d=>v (f (p+d))) 0 B) + (hB:∀ d,0 ≤ B d d) + {C:ℝ} (hC:0 ≤ C) + (hbound:∀ H:F →L[ℝ] F →L[ℝ] ℝ, + (∀ w,0 ≤ H w w) → HasLowerSecondTaylor (fun w=>v (f p+w)) 0 H → ∀ w,H w w ≤ C*‖w‖^2) : + ∀ d,B d d ≤ C*‖A‖^2*‖d‖^2 := by + have hg0:g (f p)=p := hgf.eq_of_nhds + have ha:HasFDerivAt (fun w=>g (f p+w)-p) J 0 := by + have hg' : HasFDerivAt g J (f p+id (0:F)) := by simpa only [id_eq,add_zero] using hg + have H:=hg'.comp 0 ((hasFDerivAt_id (0:F)).const_add (f p)) + simpa only [add_zero,ContinuousLinearMap.comp_id,Function.comp_apply,id_eq] using H.sub_const p + have ha0:g (f p+0)-p=0 := by rw [add_zero,hg0,sub_self] + have H:=hjet.comp_stationary ha ha0 + have heq:(fun w=>v (f (p+(g (f p+w)-p)))) =ᶠ[𝓝 (0:F)] + (fun w=>v (f p+w)) := by + have ht:Tendsto (fun w:F=>f p+w) (𝓝 0) (𝓝 (f p)) := by + simpa only [add_zero] using + (tendsto_const_nhds.add (tendsto_id : Tendsto (fun w:F=>w) (𝓝 0) (𝓝 0)) : + Tendsto (fun w:F=>f p+w) (𝓝 0) (𝓝 (f p+0))) + filter_upwards [ht.eventually hfg] with w hw + have hp:p+(g (f p+w)-p)=g (f p+w) := by abel + rw [hp,hw,id_eq] + have HE:=H.mono heq.eq_of_nhds heq.le + have hJA:J.comp A=ContinuousLinearMap.id ℝ E := by + have HD:= (hg.comp p hf).congr_of_eventuallyEq hgf.symm + exact HD.unique (hasFDerivAt_id p) + intro d + have HH:=hbound (pullBilinear B J) (fun w=>by simpa only [pullBilinear_apply] using hB (J w)) HE (A d) + have hid:J (A d)=d := by simpa only [ContinuousLinearMap.comp_apply, + ContinuousLinearMap.id_apply] using congrArg (fun T:E →L[ℝ] E=>T d) hJA + rw [pullBilinear_apply,hid] at HH + have hn:=A.le_opNorm d + have hsq:‖A d‖^2 ≤ ‖A‖^2*‖d‖^2 := by + simpa only [mul_pow] using (sq_le_sq₀ (norm_nonneg _) (by positivity)).mpr hn + exact HH.trans (by nlinarith only [mul_le_mul_of_nonneg_left hsq hC]) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/JoinCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/JoinCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..12908460817942e2a01d31be2df8ba710845ae10 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/JoinCoordinates.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential +import OAI.Analysis.BiholderTransport.Coordinates.SplitLogInjective +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactQuadratic + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section JoinCoordinates +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_join_normal_coordinates {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {h : ℝ} (hh : h≠0) (hp : h • p∈injectivityDomain x) : + ∃ q : TangentSpace 𝓘(ℝ,Model n) x → + TangentSpace 𝓘(ℝ,Model n) (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + q p=0 ∧ ContDiffAt ℝ ∞ q p ∧ Function.Injective (fderiv ℝ q p) ∧ + ∀ᶠ a in 𝓝 p, riemannianExp _ (q a)=riemannianExp x (h • a) := by + let : Nonempty M := ⟨x⟩ + let : MeasurableSpace M := borel M + let : BorelSpace M := ⟨rfl⟩ + let z := sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) + let X := TangentSpace 𝓘(ℝ,Model n) x + let Z := TangentSpace 𝓘(ℝ,Model n) z.1 + obtain ⟨κ,hκ0,hκ,hκr⟩ := exists_normal_local_inverse_at (zero_mem_injectivityDomain (n := n) z.1) + rw [riemannianExp_zero] at hκ0 hκ hκr + let q : X → Z := fun a => κ (riemannianExp x (h • a)) + have heq : riemannianExp x (h • p)=z.1 := riemannianExp_smul x p h + have hE : ContMDiffAt 𝓘(ℝ,X) 𝓘(ℝ,Model n) ∞ + (fun a : X => riemannianExp x (h • a)) p := + (contMDiff_riemannianExp_fiber x _).comp p + (show ContDiffAt ℝ ∞ (fun a : X => h • a) p from by fun_prop).contMDiffAt + have hq : ContDiffAt ℝ ∞ q p := by + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp p _ hE + rwa [heq] + have hqp : q p=0 := by change κ _=0; rw [heq,hκ0] + have hqr : ∀ᶠ a in 𝓝 p, riemannianExp z.1 (q a)=riemannianExp x (h • a) := + hE.continuousAt.eventually (by simpa only [heq] using hκr) + exact ⟨q,hqp,hq,prefix_log_fderiv_injective hh hp (hq.differentiableAt (by simp)) hqr,hqr⟩ + +lemma middle_action_in_join_coordinates {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {h : ℝ} (hp : p∈minimizingVectors x) (hh : 0 diagonalSplitAction x h (p,a)-cost x (riemannianExp x p)) := by + filter_upwards [hqr] with a ha + have hc := middle_action_contact (z := (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)) hp hh hh1 + dsimp only [Function.comp_apply,middleCenteredAction] + rw [middle_normal_prefix,middle_normal_suffix,ha] + dsimp only [diagonalSplitAction,splitNormalAction,normalCost] + simp only [normalCost,riemannianExp_zero,div_eq_mul_inv] at hc ⊢ + nlinarith only [hc] + +end JoinCoordinates +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/JoiningCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/JoiningCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..1d5423dbb60b5f184f8503447247232b9861412d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/JoiningCoordinates.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiberLog + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_joining_coordinates {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {h : ℝ} (hh : h≠0) (hp : h • p∈injectivityDomain x) : + let z := riemannianExp x (h • p) + ∃ g : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) z, + ContDiffAt ℝ ∞ g p ∧ g p=0 ∧ + (∀ᶠ b in 𝓝 p, riemannianExp z (g b)=riemannianExp x (h • b)) ∧ + Function.Injective (fderiv ℝ g p) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let z := riemannianExp x (h • p) + let W := TangentSpace 𝓘(ℝ,Model n) z + obtain ⟨L,hL,hL0,hLi⟩ := exists_smooth_fiber_log (zero_mem_injectivityDomain (n := n) z) + simp only [riemannianExp_zero] at hL hL0 hLi + let s : V →L[ℝ] V := h • ContinuousLinearMap.id ℝ V + have hc : ContMDiffAt 𝓘(ℝ,V) 𝓘(ℝ,Model n) ∞ + (fun b : V => riemannianExp x (h • b)) p := + (contMDiff_riemannianExp_fiber x (h • p)).comp p s.contDiff.contMDiff.contMDiffAt + let g : V → W := fun b => L (riemannianExp x (h • b)) + have hg : ContDiffAt ℝ ∞ g p := (hL.comp p hc).contDiffAt + have hg0 : g p=0 := hL0 + have hgi : ∀ᶠ b in 𝓝 p, riemannianExp z (g b)=riemannianExp x (h • b) := + hc.continuousAt.eventually hLi + refine ⟨g,hg,hg0,hgi,?_⟩ + let cx : V → Model n := fun v => extChartAt 𝓘(ℝ,Model n) z (riemannianExp x v) + let cz : W → Model n := fun v => extChartAt 𝓘(ℝ,Model n) z (riemannianExp z v) + have hcx : ContDiffAt ℝ ∞ cx (h • p) := + (contMDiffAt_extChartAt.comp (h • p) (contMDiff_riemannianExp_fiber x (h • p))).contDiffAt + have hcz : ContDiffAt ℝ ∞ cz 0 := by + have H := (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ + (extChartAt 𝓘(ℝ,Model n) z) (riemannianExp z (0:W)) from by + simpa only [riemannianExp_zero] using + (contMDiffAt_extChartAt (I := 𝓘(ℝ,Model n)) (x := z))).comp 0 + (contMDiff_riemannianExp_fiber z 0) + exact H.contDiffAt + have he : (fun b => cz (g b)) =ᶠ[𝓝 p] (fun b => cx (s b)) := + hgi.mono (fun _ hb => congrArg (extChartAt 𝓘(ℝ,Model n) z) hb) + have hd := he.fderiv_eq (𝕜 := ℝ) + rw [fderiv_fun_comp p (by simpa only [hg0] using hcz.differentiableAt (by simp)) + (hg.differentiableAt (by simp)),fderiv_fun_comp p (f := s) (g := cx) + (by simpa [s] using hcx.differentiableAt (by simp)) s.differentiableAt,s.fderiv] at hd + intro v w hvw + have H := congrArg (fun A : V →L[ℝ] Model n => A v-A w) hd + simp only [ContinuousLinearMap.comp_apply,hvw,sub_self] at H + have hi : Function.Injective (fderiv ℝ cx (h • p)) := + riemannianExp_interior_nonconjugate hp + have Hs : s v=s w := hi (by simpa [s] using sub_eq_zero.mp H.symm) + apply (smul_right_injective V hh) + simpa [s] using Hs + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/JointExpInverse.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/JointExpInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..740ec23910e73250c587bf0016c3a121a82bb290 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/JointExpInverse.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugacy + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_joint_exp_inverse (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z.2 ∈ injectivityDomain z.1) : + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + ∃ e : OpenPartialHomeomorph (Model n × Model n) (Model n × Model n), + (e : Model n × Model n → Model n × Model n) = + (fun q => (q.1, d (riemannianExp (χ.symm q).1 (χ.symm q).2))) ∧ + χ z ∈ e.source ∧ e.source ⊆ χ.target ∧ + (∀ q ∈ e.source, riemannianExp (χ.symm q).1 (χ.symm q).2 ∈ d.source) ∧ + ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + let f : Model n × Model n → Model n := fun q => + d (riemannianExp (χ.symm q).1 (χ.symm q).2) + let S := χ.target ∩ (fun q => riemannianExp (χ.symm q).1 (χ.symm q).2) ⁻¹' d.source + have hχz : χ z ∈ χ.target := χ.map_source (mem_extChartAt_source z) + have hχinv : χ.symm (χ z)=z := χ.left_inv (mem_extChartAt_source z) + have hχ : ContMDiffOn 𝓘(ℝ,Model n × Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ χ.symm χ.target := + contMDiffOn_extChartAt_symm z + have hE : ContMDiffOn 𝓘(ℝ,Model n × Model n) 𝓘(ℝ,Model n) ∞ + (fun q => riemannianExp (χ.symm q).1 (χ.symm q).2) χ.target := + contMDiff_riemannianExp.comp_contMDiffOn hχ + have hS : IsOpen S := + hE.continuousOn.isOpen_inter_preimage (isOpen_extChartAt_target z) (isOpen_extChartAt_source _) + have hzS : χ z ∈ S := ⟨hχz,by change riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2 ∈ d.source; rw [hχinv]; exact mem_extChartAt_source _⟩ + have hd : ContMDiffOn 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d d.source := by + simpa only [d,extChartAt_source] using (contMDiffOn_extChartAt (I := 𝓘(ℝ,Model n)) (n := ∞) (x := riemannianExp z.1 z.2)) + have hf : ContDiffOn ℝ ∞ f S := + (hd.comp (hE.mono (inter_subset_left)) (fun _ hq => hq.2)).contDiffOn + let τ := trivializationAt (Model n) (fun b : M => TangentSpace 𝓘(ℝ,Model n) b) z.1 + let L : TangentSpace 𝓘(ℝ,Model n) z.1 ≃L[ℝ] Model n := + τ.continuousLinearEquivAt ℝ z.1 (mem_baseSet_trivializationAt (Model n) _ z.1) + have hχsecond : (χ z).2=L z.2 := rfl + have hχfiber (w : Model n) : χ.symm ((χ z).1,w) = + (⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + have hforward : χ (⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M) = ((χ z).1,w) := by + apply Prod.ext + · rfl + · change L (L.symm w)=w + exact L.apply_symm_apply w + rw [←hforward] + apply χ.left_inv + exact (tangent_chart_source_iff z _).mpr (mem_extChartAt_source z.1) + let F : TangentSpace 𝓘(ℝ,Model n) z.1 → Model n := + fun v => d (riemannianExp z.1 v) + have hF : ContDiffAt ℝ ∞ F z.2 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp z.1 z.2) from + contMDiffAt_extChartAt).comp z.2 (contMDiff_riemannianExp_fiber z.1 z.2)).contDiffAt + have hFi : Function.Injective (fderiv ℝ F z.2) := riemannianExp_interior_nonconjugate hz + have hpart : (fun w => f ((χ z).1,w)) = F ∘ L.symm := by + funext w + dsimp [f] + rw [hχfiber] + have hpartder : fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2 = + (fderiv ℝ F z.2).comp (L.symm : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) z.1) := by + rw [hpart,hχsecond] + have hF' : HasFDerivAt F (fderiv ℝ F z.2) (L.symm (L z.2)) := by + simpa only [L.symm_apply_apply] using (hF.differentiableAt (by simp)).hasFDerivAt + exact (hF'.comp (L z.2) L.symm.hasFDerivAt).fderiv + have hpi : (fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2).IsInvertible := by + have hi : Function.Injective (fderiv ℝ (fun w => f ((χ z).1,w)) (χ z).2) := by + rw [hpartder] + exact hFi.comp L.symm.injective + have hs := LinearMap.injective_iff_surjective.mp hi + exact ⟨ContinuousLinearEquiv.ofBijective _ (LinearMap.ker_eq_bot.mpr hi) + (LinearMap.range_eq_top.mpr hs),rfl⟩ + have hi := first_coordinate_preserving_derivative_invertible + ((hf.contDiffAt (hS.mem_nhds hzS)).differentiableAt (by simp)) hpi + obtain ⟨e,he,hz',heS,heD,heInv⟩ := exists_smooth_local_diffeomorphism hS + (contDiffOn_fst.prodMk hf) hzS hi + exact ⟨e,he,hz',fun _ hq => (heS hq).1,fun _ hq => (heS hq).2,heD,heInv⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/JointNormalChart.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/JointNormalChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..af39dbfb56999d165cbf1155f46e0f8d09ced208 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/JointNormalChart.lean @@ -0,0 +1,274 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.SmoothCoordinateFlow +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates +import OAI.Analysis.BiholderTransport.LocalFlow.LocalMetricNormal +import OAI.Analysis.BiholderTransport.Coordinates.TangentLift +import OAI.Analysis.BiholderTransport.Coordinates.FiberwiseHomeomorphism + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma exists_joint_smooth_normal_chart + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) + (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {x : E} (hx : x ∈ S) : + ∃ r : ℝ, 0 < r ∧ ∃ Φ : ℝ × (E × E) → E × E, + ContDiffOn ℝ ∞ Φ (Ioo (-r) r ×ˢ Metric.ball (x,0) r) ∧ + (∀ z ∈ Metric.ball (x,0) r, Φ (0,z) = z) ∧ + (∀ t ∈ Ioo (-r) r, ∀ z ∈ Metric.ball (x,0) r, + (Φ (t,z)).1 ∈ S ∧ + HasDerivAt (fun q => (Φ (q,z)).1) (Φ (t,z)).2 t ∧ + HasDerivAt (fun q => (Φ (q,z)).2) + (-coordinateChristoffel g (Φ (t,z)).1 (Φ (t,z)).2 (Φ (t,z)).2) t) ∧ + ∃ τ : ℝ, 0 < τ ∧ τ < r ∧ ∃ e : OpenPartialHomeomorph (E × E) (E × E), + (e : (E × E) → (E × E)) = (fun z => (z.1,(Φ (τ,z)).1)) ∧ + (x,0) ∈ e.source ∧ + e.source ⊆ Metric.ball (x,0) r ∧ + ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target := by + have hi : ∀ y ∈ S, (g y).IsInvertible := + fun y hy => metricDual_isInvertible (g y) (hpos y hy) + obtain ⟨r,hr,Φ,hΦ,hΦ0,hΦode⟩ := exists_smooth_coordinate_flow hS hg hi x 0 hx + have hball : ∀ v ∈ Metric.ball (0:E) r, (x,v) ∈ Metric.ball (x,0) r := by + intro v hv + simpa only [Metric.mem_ball,Prod.dist_eq,dist_self,max_lt_iff] using And.intro hr hv + have hΦc : ContDiffOn ℝ ∞ (fun z : ℝ × E => Φ (z.1,(x,z.2))) + (Ioo (-r) r ×ˢ Metric.ball 0 r) := + hΦ.comp (contDiffOn_fst.prodMk (contDiffOn_const.prodMk contDiffOn_snd)) + (fun z hz => ⟨hz.1,hball z.2 hz.2⟩) + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨neg_neg_of_pos hr,hr⟩ + have hτ : r/2 ∈ Ioo (-r) r := ⟨by linarith,by linarith⟩ + have hinv := coordinate_endpoint_isInvertible (x := x) hS hg hpos hsym hr hΦc.fst hΦc.snd + (fun t ht v hv => (hΦode t ht (x,v) (hball v hv)).1) + (fun t ht v hv => (hΦode t ht (x,v) (hball v hv)).2) + h0 (fun v hv => congrArg Prod.fst (hΦ0 (x,v) (hball v hv))) + (fun v hv => congrArg Prod.snd (hΦ0 (x,v) (hball v hv))) + hτ (by linarith : r/2 ≠ 0) + have hψ : ContDiffOn ℝ ∞ (fun z => (Φ (r/2,z)).1) (Metric.ball (x,0) r) := + (hΦ.comp (contDiffOn_const.prodMk contDiffOn_id) (fun z hz => ⟨hτ,hz⟩)).fst + have hψa := (hψ.contDiffAt (Metric.isOpen_ball.mem_nhds (Metric.mem_ball_self hr))).differentiableAt + (by simp) + have hinv' := first_coordinate_preserving_derivative_invertible hψa hinv + obtain ⟨e,he,hes,hesub,hed,hei⟩ := exists_smooth_local_diffeomorphism + Metric.isOpen_ball (contDiffOn_fst.prodMk hψ) (Metric.mem_ball_self hr) hinv' + exact ⟨r,hr,Φ,hΦ,hΦ0,hΦode,r/2,by positivity,hτ.2,e,he,hes,hesub,hed,hei⟩ + +end +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_uniform_metric_normal_coordinates (a : M) : + ∃ δ r τ : ℝ, 0 < δ ∧ 0 < r ∧ 0 < τ ∧ τ < r ∧ + ∃ Φ : ℝ × (E × E) → E × E, + ∃ e : OpenPartialHomeomorph (E × E) (E × E), + ContDiffOn ℝ ∞ Φ (Ioo (-r) r ×ˢ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r) ∧ + (∀ z ∈ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r, Φ (0,z) = z) ∧ + (∀ t ∈ Ioo (-r) r, ∀ z ∈ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r, + (Φ (t,z)).1 ∈ (extChartAt 𝓘(ℝ,E) a).target ∧ + HasDerivAt (fun q => Φ (q,z)) + (coordinateGeodesicField (riemannianCoordinateMetric a) (Φ (t,z))) t) ∧ + (e : (E × E) → (E × E)) = (fun z => (z.1,(Φ (τ,z)).1)) ∧ + e.source ⊆ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r ∧ + ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target ∧ + (Metric.ball a δ ⊆ (extChartAt 𝓘(ℝ,E) a).source) ∧ + (∀ b ∈ Metric.ball a δ, (extChartAt 𝓘(ℝ,E) a b,0) ∈ e.source) ∧ + (∀ b ∈ Metric.ball a δ, ∀ y ∈ Metric.ball a δ, + (extChartAt 𝓘(ℝ,E) a b,extChartAt 𝓘(ℝ,E) a y) ∈ e.target) ∧ + (∀ b ∈ Metric.ball a δ, ∀ y ∈ Metric.ball a δ, ∀ v : E, + (extChartAt 𝓘(ℝ,E) a b,v) ∈ e.source → + (Φ (τ,(extChartAt 𝓘(ℝ,E) a b,v))).1 = extChartAt 𝓘(ℝ,E) a y → + dist b y = τ * Real.sqrt (riemannianCoordinateMetric a + (extChartAt 𝓘(ℝ,E) a b) v v)) := by + let c := extChartAt 𝓘(ℝ,E) a + let g := riemannianCoordinateMetric (E := E) a + have hS : IsOpen c.target := isOpen_extChartAt_target a + have hg : ContDiffOn ℝ ∞ g c.target := contDiffOn_riemannianCoordinateMetric a + have hpos : ∀ x ∈ c.target, ∀ v : E, v ≠ 0 → 0 < g x v v := + fun _ hx _ hv => riemannianCoordinateMetric_positive hx hv + have hsym : ∀ x ∈ c.target, ∀ u v : E, g x u v = g x v u := + fun x _ u v => riemannianCoordinateMetric_symm a x u v + obtain ⟨r,hr,Φ,hΦ,hΦ0,hode,τ,hτ,hτr,e,he,hes,hesub,hed,hei⟩ := + exists_joint_smooth_normal_chart hS hg hpos hsym (mem_extChartAt_target a) + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨by linarith,hr⟩ + have ht : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have hepres : ∀ z : E × E, (e z).1 = z.1 := by + intro z + rw [he] + have hzero : ∀ x ∈ Metric.ball (c a) r, (Φ (τ,(x,0))).1 = x := by + intro x hx + have hz : (x,(0:E)) ∈ Metric.ball (c a,0) r := by + simpa only [Metric.mem_ball,Prod.dist_eq,dist_self,max_lt_iff] using And.intro hx hr + have hz0 := hΦ0 (x,0) hz + have hh := coordinate_geodesic_zero_velocity + (fun t ht => (hg.contDiffAt (hS.mem_nhds (hode t ht (x,0) hz).1)).differentiableAt (by simp)) + (fun t ht => metricDual_isInvertible _ (hpos _ (hode t ht (x,0) hz).1)) + (fun t ht => hpos _ (hode t ht (x,0) hz).1) + (fun t ht => hsym _ (hode t ht (x,0) hz).1) + (fun t ht => (hode t ht (x,0) hz).2) h0 + (show (Φ (0,(x,0))).2 = 0 from congrArg Prod.snd hz0) ht + exact hh.1.trans (congrArg Prod.fst hz0) + have hediag : e (c a,0) = (c a,c a) := by + rw [he] + exact Prod.ext rfl (hzero _ (Metric.mem_ball_self hr)) + have hat : (c a,c a) ∈ e.target := hediag ▸ e.map_source hes + have hc : ContinuousAt c a := continuousAt_extChartAt a + have hn₁ : {p : M × M | p.1 ∈ c.source ∧ p.2 ∈ c.source} ∈ 𝓝 (a,a) := + inter_mem (continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_source a).mem_nhds (mem_extChartAt_source a))) + (continuousAt_snd.preimage_mem_nhds ((isOpen_extChartAt_source a).mem_nhds (mem_extChartAt_source a))) + have hn₂ : {p : M × M | (c p.1,0) ∈ e.source} ∈ 𝓝 (a,a) := + ((hc.comp continuousAt_fst).prodMk continuousAt_const).preimage_mem_nhds + (e.open_source.mem_nhds hes) + have hn₃ : {p : M × M | (c p.1,c p.2) ∈ e.target} ∈ 𝓝 (a,a) := + ((hc.comp continuousAt_fst).prodMk (hc.comp continuousAt_snd)).preimage_mem_nhds + (e.open_target.mem_nhds hat) + obtain ⟨R,hR,hgood⟩ := Metric.mem_nhds_iff.mp (inter_mem hn₁ (inter_mem hn₂ hn₃)) + have hgood' : ∀ b ∈ Metric.ball a R, ∀ y ∈ Metric.ball a R, + b ∈ c.source ∧ y ∈ c.source ∧ (c b,0) ∈ e.source ∧ (c b,c y) ∈ e.target := by + intro b hb y hy + have hh := hgood (show (b,y) ∈ Metric.ball (a,a) R by + simpa only [Metric.mem_ball,Prod.dist_eq,max_lt_iff] using And.intro hb hy) + exact ⟨hh.1.1,hh.1.2,hh.2.1,hh.2.2⟩ + let δ := R/4 + have hδ : 0 < δ := by dsimp [δ]; positivity + have hδR : δ < R := by dsimp [δ]; linarith + have hballR : Metric.ball a δ ⊆ Metric.ball a R := Metric.ball_subset_ball hδR.le + refine ⟨δ,r,τ,hδ,hr,hτ,hτr,Φ,e,hΦ,hΦ0,?_,he,hesub,hed,hei,?_,?_,?_,?_⟩ + · intro t ht z hz + exact ⟨(hode t ht z hz).1,(hode t ht z hz).2.1.prodMk (hode t ht z hz).2.2⟩ + · intro b hb + exact (hgood' b (hballR hb) a (Metric.mem_ball_self hR)).1 + · intro b hb + exact (hgood' b (hballR hb) a (Metric.mem_ball_self hR)).2.2.1 + · intro b hb y hy + exact (hgood' b (hballR hb) y (hballR hy)).2.2.2 + · intro b hb y hy v hv hval + let f := fiberwiseHomeomorph e hepres (c b) + have hbg := hgood' b (hballR hb) a (Metric.mem_ball_self hR) + have hcb : c b ∈ Metric.ball (c a) r := by + exact (max_lt_iff.mp (show max (dist (c b) (c a)) (dist (0:E) 0) < r + from hesub hbg.2.2.1)).1 + have hball : ∀ w ∈ Metric.ball (0:E) r, (c b,w) ∈ Metric.ball (c a,0) r := by + intro w hw + simpa only [Metric.mem_ball,Prod.dist_eq,max_lt_iff] using And.intro hcb hw + have hΦb : ContDiffOn ℝ ∞ (fun z : ℝ × E => Φ (z.1,(c b,z.2))) + (Ioo (-r) r ×ˢ Metric.ball 0 r) := + hΦ.comp (contDiffOn_fst.prodMk (contDiffOn_const.prodMk contDiffOn_snd)) + (fun z hz => ⟨hz.1,hball z.2 hz.2⟩) + have hf : (f : E → E) = (fun w => (Φ (τ,(c b,w))).1) := by + funext w + change (e (c b,w)).2 = _ + rw [he] + have hfb : Metric.ball b (2*δ) ⊆ c.source ∩ c ⁻¹' f.target := by + intro z hz + have hzR : z ∈ Metric.ball a R := by + have ht' := dist_triangle z b a + have hb' : dist b a < δ := hb + have hz' : dist z b < 2*δ := hz + change dist z a < R + dsimp [δ] at * + linarith + have hh := hgood' b (hballR hb) z hzR + exact ⟨hh.2.1,hh.2.2.2⟩ + have hby : dist b y < 2*δ := by + have ht' := dist_triangle b a y + have hb' : dist b a < δ := hb + have hy' : dist a y < δ := by simpa only [Metric.mem_ball,dist_comm] using hy + linarith + have hnorm := riemannian_coordinate_normal_chart_dist hS hg hpos hsym (Subset.refl _) + (fun _ _ _ _ => rfl) hΦb.fst hΦb.snd + (fun t ht w hw => (hode t ht (c b,w) (hball w hw)).1) + (fun t ht w hw => (hode t ht (c b,w) (hball w hw)).2) h0 + (fun w hw => (congrArg Prod.fst (hΦ0 (c b,w) (hball w hw)) : _ = c b)) + (fun w hw => congrArg Prod.snd (hΦ0 (c b,w) (hball w hw))) ht hτ.le f hf + (by rw [hf]; exact hzero _ hcb) hbg.2.2.1 + (fun w hw => (max_lt_iff.mp (show max (dist (c b) (c a)) (dist w 0) < r + from hesub hw)).2) + (fiberwiseHomeomorph_contDiffOn hepres (c b) hed) + (fiberwiseHomeomorph_symm_contDiffOn hepres (c b) hei) hfb hby + have hv' : f.symm (c y) = v := by + have hfval : f v = c y := by rw [hf]; exact hval + rw [←hfval] + exact f.left_inv hv + rw [hv'] at hnorm + exact hnorm + +end WeakMTWTransport +open Set + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/KernelRadial.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/KernelRadial.lean new file mode 100644 index 0000000000000000000000000000000000000000..46dcd68862b93f48a5750a85ca368f687cd5775c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/KernelRadial.lean @@ -0,0 +1,229 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugacy + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exp_kernel_radial_orthogonal {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) : + inner ℝ p k=0 := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hline : HasDerivAt (fun s : ℝ => p+s • k) k 0 := by + convert! (hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const k) using 1 + simp + let F : V → M := fun v => (sprayFlow 1 (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + have hf : riemannianExp x=F := funext (fun v => riemannianExp_eq_sprayFlow x v) + have hkF : mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) F p k=0 := by + rw [←hf] + exact hk + have hs : ContMDiff 𝓘(ℝ,V) 𝓘(ℝ,Model n) ∞ F := by + rw [←hf] + exact contMDiff_riemannianExp_fiber x + have he := ((hs (p+(0:ℝ) • k)).mdifferentiableAt (by simp)).hasMFDerivAt + have hcomp := he.comp 0 hline.hasFDerivAt.hasMFDerivAt + have hz : mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) (fun s : ℝ => F (p+s • k)) 0 1=0 := by + have hc := hcomp.mfderiv + simp only [Function.comp_def] at hc + rw [hc] + change (mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) F (p+(0:ℝ) • k)) ((1:ℝ) • k)=0 + rw [one_smul] + convert! hkF using 1 + congr 1 + exact mfderiv_congr_point (by simp only [zero_smul,add_zero]) + have H := sprayFlow_gauss x p k (1:ℝ) + rw [hz] at H + have H' : inner ℝ (sprayFlow 1 (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 + (0 : TangentSpace 𝓘(ℝ,Model n) (sprayFlow 1 (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1)=inner ℝ p k := by + convert! H using 1 + simp only [one_mul] + simpa only [inner_zero_right] using H'.symm +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exp_mfderiv_apply_eq_coordinate (x : M) (p k : TangentSpace 𝓘(ℝ,Model n) x) : + mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k= + (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp x p) (riemannianExp x v)) p : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] Model n) k := by + have H := ((contMDiff_riemannianExp_fiber x p).mdifferentiableAt (by simp)).mfderiv + have HH := congrArg (fun L => L k) H + simp only [mfld_simps,chartAt_self_eq,Function.comp_def,fderivWithin_univ] at HH ⊢ + convert! HH using 1 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalInverseCalculus.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalInverseCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..a474a1f9822be39170eb83c8eddb92b117a10723 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalInverseCalculus.lean @@ -0,0 +1,25 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma local_inverse_derivative {e : F → E} {L : E → F} {p : E} + (he : DifferentiableAt ℝ e (L p)) (hL : DifferentiableAt ℝ L p) + (hid : (fun v => e (L v)) =ᶠ[𝓝 p] (fun v => v)) (v : E) : + fderiv ℝ e (L p) (fderiv ℝ L p v)=v := by + have H := hid.fderiv_eq (𝕜 := ℝ) + rw [fderiv_fun_comp p he hL,fderiv_fun_id] at H + exact congrArg (fun A : E →L[ℝ] E => A v) H + + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalMetricCharts.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalMetricCharts.lean new file mode 100644 index 0000000000000000000000000000000000000000..20fd63efcdc81cbb34dab4681982a49fa4d53441 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalMetricCharts.lean @@ -0,0 +1,164 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Bundle Bornology Set MeasureTheory Manifold Filter Metric +open scoped ENNReal NNReal ContDiff Topology + +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace + normedSpaceTangentSpaceVectorSpace +namespace WeakMTWTransport + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) 1 M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContinuousRiemannianBundle E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] +local notation "𝒥" => 𝓘(ℝ,E) + +lemma exists_lipschitzOn_inverse_chart (x : M) : + ∃ C : ℝ≥0, ∃ r : ℝ, 0 < r ∧ + ball (extChartAt 𝓘(ℝ,E) x x) r ⊆ (extChartAt 𝓘(ℝ,E) x).target ∧ + LipschitzOnWith C (extChartAt 𝓘(ℝ,E) x).symm + (ball (extChartAt 𝓘(ℝ,E) x x) r) := by + let (y : E) : ENorm (TangentSpace 𝒥 y →L[ℝ] + TangentSpace 𝒥 ((extChartAt 𝒥 x).symm y)) := + inferInstanceAs (ENorm (E →L[ℝ] TangentSpace 𝒥 ((extChartAt 𝒥 x).symm y))) + obtain ⟨C,hCpos,hC⟩ := eventually_enorm_mfderivWithin_symm_extChartAt_lt 𝒥 x + obtain ⟨r,hrpos,hr⟩ : ∃ r > 0, + ball (extChartAt 𝒥 x x) r ⊆ (extChartAt 𝒥 x).target ∩ + {y : E | ‖mfderiv[range 𝒥] (extChartAt 𝒥 x).symm y‖ₑ < (C : ℝ≥0∞)} := by + have hh := inter_mem (extChartAt_target_mem_nhdsWithin (I := 𝒥) x) hC + have hh' : (extChartAt 𝒥 x).target ∩ + {y : E | ‖mfderiv[range 𝒥] (extChartAt 𝒥 x).symm y‖ₑ < (C : ℝ≥0∞)} ∈ + 𝓝 (extChartAt 𝒥 x x) := by + simp only [ModelWithCorners.range_eq_univ, nhdsWithin_univ] at hh ⊢ + convert hh using 1 + rfl + exact Metric.mem_nhds_iff.mp hh' + refine ⟨C,r,hrpos,fun y hy => (hr hy).1,?_⟩ + intro u hu v hv + let η := ContinuousAffineMap.lineMap (R := ℝ) u v + let γ := (extChartAt 𝒥 x).symm ∘ η + have hη : Icc 0 1 ⊆ ⇑η ⁻¹' ((extChartAt 𝒥 x).target ∩ + {y : E | ‖mfderiv[range 𝒥] (extChartAt 𝒥 x).symm y‖ₑ < (C : ℝ≥0∞)}) := by + simp only [← image_subset_iff,ContinuousAffineMap.coe_lineMap_eq, + ← segment_eq_image_lineMap,η] + exact ((convex_ball _ _).segment_subset hu hv).trans hr + simp only [preimage_inter,subset_inter_iff] at hη + have η_smooth : CMDiff[Icc 0 1] 1 η := by + apply ContMDiff.contMDiffOn + rw [contMDiff_iff_contDiff] + exact ContinuousAffineMap.contDiff _ + have hh : riemannianEDist 𝒥 ((extChartAt 𝒥 x).symm u) ((extChartAt 𝒥 x).symm v) ≤ + pathELength 𝒥 γ 0 1 := by + apply riemannianEDist_le_pathELength _ _ _ zero_le_one + · exact (contMDiffOn_extChartAt_symm x).comp η_smooth hη.1 + · simp [γ,η,ContinuousAffineMap.coe_lineMap_eq] + · simp [γ,η,ContinuousAffineMap.coe_lineMap_eq] + rw [IsRiemannianManifold.out (I := 𝒥)] + apply hh.trans + rw [← lintegral_fderiv_lineMap_eq_edist,pathELength_eq_lintegral_mfderivWithin_Icc, + ← lintegral_const_mul' _ _ ENNReal.coe_ne_top] + apply setLIntegral_mono' measurableSet_Icc (fun t ht => ?_) + have hd : mfderiv[Icc 0 1] γ t = + (mfderiv[range 𝒥] (extChartAt 𝒥 x).symm (η t)) ∘L (mfderiv[Icc 0 1] η t) := by + apply mfderivWithin_comp + · exact mdifferentiableWithinAt_extChartAt_symm (hη.1 ht) + · exact η_smooth.mdifferentiableOn one_ne_zero t ht + · exact hη.1.trans (preimage_mono (extChartAt_target_subset_range x)) + · rw [uniqueMDiffWithinAt_iff_uniqueDiffWithinAt] + exact uniqueDiffOn_Icc zero_lt_one t ht + have hd1 : mfderiv[Icc 0 1] γ t 1 = + (mfderiv[range 𝒥] (extChartAt 𝒥 x).symm (η t)) (mfderiv[Icc 0 1] η t 1) := + congr($hd 1) + rw [hd1] + apply (ContinuousLinearMap.le_opENorm _ _).trans + gcongr + · exact (hη.2 ht).le + · simp only [mfderivWithin_eq_fderivWithin] + exact le_of_eq rfl + +variable [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + [MeasurableSpace M] [BorelSpace M] + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContinuousRiemannianBundle E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in + +lemma hausdorff_nondifferentiable_chart_image_null {u : M → ℝ} {K C : ℝ≥0} + (hu : LipschitzWith K u) (x : M) {r : ℝ} + (hr : ball (extChartAt 𝒥 x x) r ⊆ (extChartAt 𝒥 x).target) + (hC : LipschitzOnWith C (extChartAt 𝒥 x).symm (ball (extChartAt 𝒥 x x) r)) : + (Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure M) + {y | y ∈ (extChartAt 𝒥 x).symm '' ball (extChartAt 𝒥 x x) r ∧ + ¬ MDifferentiableAt 𝒥 𝓘(ℝ,ℝ) u y} = 0 := by + let B : Set E := {z | z ∈ ball (extChartAt 𝒥 x x) r ∧ + ¬ DifferentiableAt ℝ (u ∘ (extChartAt 𝒥 x).symm) z} + have hB : (Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure E) B = 0 := by + have hh := (hu.comp_lipschitzOnWith hC).ae_differentiableWithinAt_of_mem + (μ := (Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure E)) + apply measure_mono_null _ (ae_iff.mp hh) + intro z hz hdiff + exact hz.2 ((hdiff hz.1).differentiableAt (isOpen_ball.mem_nhds hz.1)) + have himage : (Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure M) + ((extChartAt 𝒥 x).symm '' B) = 0 := by + apply le_antisymm ?_ (by positivity) + have hh := (hC.mono (show B ⊆ ball (extChartAt 𝒥 x x) r from fun _ h => h.1)).hausdorffMeasure_image_le (d := (Module.finrank ℝ E : ℝ)) (by positivity) + simpa only [hB,mul_zero] using hh + apply measure_mono_null _ himage + rintro y ⟨⟨z,hz,rfl⟩,hnot⟩ + refine ⟨z,⟨hz,?_⟩,rfl⟩ + intro hdiff + apply hnot + have hsrc : (extChartAt 𝒥 x).symm z ∈ (chartAt E x).source := by + simpa only [extChartAt_source] using (extChartAt 𝒥 x).map_target (hr hz) + have hD : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (u ∘ (extChartAt 𝒥 x).symm) + ((extChartAt 𝒥 x) ((extChartAt 𝒥 x).symm z)) := by + rw [(extChartAt 𝒥 x).right_inv (hr hz)] + exact hdiff.mdifferentiableAt + have hh := hD.comp ((extChartAt 𝒥 x).symm z) + (mdifferentiableAt_extChartAt (I := 𝒥) hsrc) + apply hh.congr_of_eventuallyEq + filter_upwards [(chartAt E x).open_source.mem_nhds hsrc] with w hw + have hw' : w ∈ (extChartAt 𝒥 x).source := by simpa only [extChartAt_source] using hw + simp only [Function.comp_apply,(extChartAt 𝒥 x).left_inv hw'] + +lemma exists_nhds_nondifferentiable_null {u : M → ℝ} {K : ℝ≥0} + (hu : LipschitzWith K u) (x : M) : + ∃ U ∈ 𝓝 x, (Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure M) + {y | y ∈ U ∧ ¬ MDifferentiableAt 𝒥 𝓘(ℝ,ℝ) u y} = 0 := by + obtain ⟨C,r,hrpos,hr,hC⟩ := exists_lipschitzOn_inverse_chart (E := E) x + let U := (extChartAt 𝒥 x).source ∩ + (extChartAt 𝒥 x) ⁻¹' ball (extChartAt 𝒥 x x) r + have hU : U ∈ 𝓝 x := by + apply inter_mem + · simpa only [extChartAt_source] using chart_source_mem_nhds E x + · exact (continuousAt_extChartAt x).preimage_mem_nhds (ball_mem_nhds _ hrpos) + refine ⟨U,hU,?_⟩ + apply measure_mono_null _ (hausdorff_nondifferentiable_chart_image_null hu x hr hC) + intro y hy + exact ⟨⟨(extChartAt 𝒥 x) y,hy.1.2,(extChartAt 𝒥 x).left_inv hy.1.1⟩,hy.2⟩ + +lemma lipschitz_ae_mdifferentiable [CompactSpace M] {u : M → ℝ} {K : ℝ≥0} + (hu : LipschitzWith K u) : + ∀ᵐ x ∂(Measure.hausdorffMeasure (Module.finrank ℝ E : ℝ) : Measure M), + MDifferentiableAt 𝒥 𝓘(ℝ,ℝ) u x := by + classical + choose U hUnhds hUnull using exists_nhds_nondifferentiable_null (E := E) hu + obtain ⟨s,_,hs⟩ := isCompact_univ.elim_nhds_subcover U (fun x _ => hUnhds x) + rw [ae_iff] + apply measure_mono_null (t := ⋃ x ∈ (s : Set M), + {y | y ∈ U x ∧ ¬ MDifferentiableAt 𝒥 𝓘(ℝ,ℝ) u y}) + · intro y hy + obtain ⟨x,hx,hyx⟩ := mem_iUnion₂.mp (hs (mem_univ y)) + exact mem_iUnion₂.mpr ⟨x,hx,hyx,hy⟩ + · exact (measure_biUnion_null_iff s.countable_toSet).mpr (fun x _ => hUnull x) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterJetBound.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterJetBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..d47fa70fa80984961b7c064c55b0493a568e7b22 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterJetBound.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ActualRelativeHessianBound +import OAI.Analysis.BiholderTransport.Calculus.ScalarInverseJet +import OAI.Analysis.BiholderTransport.Convexity.TranslatedMinorant + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section LocalOuterJetBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_outer_chart_jet_bound + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 0 < lam) (hcap : 0≤cap) (a : M) (L : Model n →L[ℝ] ℝ) + (hp : chartGradientVector a (extChartAt 𝓘(ℝ,Model n) a a) L∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a a))) + {m lmax : ℝ} (hm : 0 < m) (hlmax : 0 < lmax) : + ∃ N : Set (Model n×(Model n →L[ℝ] ℝ)), + N∈𝓝 (extChartAt 𝓘(ℝ,Model n) a a,L) ∧ ∃ C≥0, + ∀ (x0:M) (uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ (z : Model n) (c : Model n → ℝ) (l:ℝ),0 < l → l≤lmax → + ContDiffAt ℝ 2 c z → (z,l⁻¹ • (-fderiv ℝ c z))∈N → + (∀ d:Model n,2*m*l*‖d‖^2≤ + l*fderiv ℝ (fderiv ℝ (chartCost a + (coordinateBackward a (-1,z,l⁻¹ • (-fderiv ℝ c z))))) z d d- + fderiv ℝ (fderiv ℝ c) z d d) → + ∀ φ:ℝ → ℝ,StrictMono φ → + ContDiffAt ℝ 2 φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)) → + HasDerivAt φ l (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)) → + iteratedDeriv 2 φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z))≤0 → + ∀ H:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀ d,0≤H d d) → + HasLowerSecondTaylor (fun h => φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm (z+h)))+ + c (z+h)) 0 H → ∀ d,H d d≤C*‖d‖^2 := by + obtain ⟨N,hN,C,hC,HC⟩ := hmtw.exists_local_relative_hessian_bound hlam hcap a L hp hm + refine ⟨N,hN,lmax*(C+m),mul_nonneg hlmax.le (add_nonneg hC hm.le),?_⟩ + intro x0 uv huv z c l hl hll hc hNq hbase φ hmono hφ hd hconc H hH hjet d + let v : Model n → ℝ := fun w => uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w) + let A := fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,l⁻¹ • (-fderiv ℝ c z))))) z + obtain ⟨q,hq,hq0,hqD,hqlo,hqH⟩ := hjet.exists_smooth_minorant_at (f := fun w => φ (v w)+c w) (x := z) (l := 0) (B := H) (mul_pos hm hl) + let F : Model n → ℝ := fun w => q w-c w + have hF : ContDiffAt ℝ 2 F z := hq.sub hc + have hF0 : F z=φ (v z) := by + dsimp only [F,v] + rw [hq0] + ring + have hFlo : ∀ᶠ w in 𝓝 z,F w≤φ (v w) := by + filter_upwards [hqlo] with w hw + change q w≤φ (v w)+c w at hw + dsimp only [F] + linarith only [hw] + have hFD : fderiv ℝ F z= -fderiv ℝ c z := by + rw [show F=(fun w => q w-c w) from rfl, + fderiv_fun_sub (hq.differentiableAt (by norm_num)) (hc.differentiableAt (by norm_num)), + hqD,zero_sub] + obtain ⟨f,hf,hf0,hflo,hfD,hfH⟩ := scalar_inverse_lower_test (E := Model n) (v := v) (F := F) (x := z) hmono hφ hd hl.ne' hF hF0 hFlo + have hfD' : fderiv ℝ f z=l⁻¹ • (-fderiv ℝ c z) := by rw [hfD,hFD] + have Heq (e:Model n) : l*(fderiv ℝ (fderiv ℝ f) z e e+A e e)= + H e e-(m*l)*‖e‖^2+(l*A e e-fderiv ℝ (fderiv ℝ c) z e e)- + (iteratedDeriv 2 φ (v z)/l^2)*(fderiv ℝ F z e)^2 := by + rw [hfH,show F=(fun w => q w-c w) from rfl,second_fderiv_sub hq hc,hqH] + field_simp [hl.ne'] + ring + have hscalar (e:Model n) : + 0≤ -(iteratedDeriv 2 φ (v z)/l^2)*(fderiv ℝ F z e)^2 := + mul_nonneg (neg_nonneg.mpr (div_nonpos_of_nonpos_of_nonneg hconc (sq_nonneg l))) (sq_nonneg _) + have hpos (e:Model n) : m*‖e‖^2≤fderiv ℝ (fderiv ℝ f) z e e+A e e := by + apply (mul_le_mul_iff_right₀ hl).mp + rw [Heq] + have hb := hbase e + change 2*m*l*‖e‖^2≤l*A e e-fderiv ℝ (fderiv ℝ c) z e e at hb + nlinarith only [hb,hH e,hscalar e] + have HB := HC x0 uv huv z f (by rwa [hfD']) hf hf0.symm hflo + (by simpa only [hfD'] using hpos) d + rw [hfD'] at HB + change fderiv ℝ (fderiv ℝ f) z d d+A d d≤C*‖d‖^2 at HB + have HB' := mul_le_mul_of_nonneg_left HB hl.le + rw [Heq] at HB' + have Hb := hbase d + change 2*m*l*‖d‖^2≤l*A d d-fderiv ℝ (fderiv ℝ c) z d d at Hb + have Hzero : 0≤2*m*l*‖d‖^2 := by positivity + have HC' : l*(C+m)*‖d‖^2≤lmax*(C+m)*‖d‖^2 := by + gcongr + nlinarith only [HB',Hb,Hzero,hscalar d,HC'] + +end LocalOuterJetBound +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterLog.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..c1ddd099376c26f9aecad3784a9d40c509f45ee2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/LocalOuterLog.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.EndpointLowerJet +import OAI.Analysis.BiholderTransport.Calculus.FiberJet +import OAI.Analysis.BiholderTransport.CostGeometry.BranchJetSecond + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section LocalOuterLog +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_outer_log_jet_bound (hmtw:WeakMTW (n := n) (M := M)) + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) + (z:TangentBundle 𝓘(ℝ,Model n) M) (hmin:z.2∈minimizingVectors z.1) + (hnc:Function.Injective (fderiv ℝ (fun v=>extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) + {l:ℝ} (hl:1 < l) : + let χ:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + ∃U:Set ((Model n×Model n)×ℝ),U∈𝓝 (χ z,l) ∧ ∃C≥0, + ∀q∈U,∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + let r:=χ.symm q.1 + ∀φ:ℝ → ℝ,StrictMono φ → ContDiffAt ℝ 2 φ (uv.2 (riemannianExp r.1 r.2)) → + HasDerivAt φ q.2 (uv.2 (riemannianExp r.1 r.2)) → + iteratedDeriv 2 φ (uv.2 (riemannianExp r.1 r.2)) ≤ 0 → + ∀B:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀d,0 ≤ B d d) → + HasLowerSecondTaylor (fun d=> + let s:=χ.symm (q.1.1,q.1.2+d) + φ (uv.2 (riemannianExp s.1 s.2))+‖s.2‖^2/2) 0 B → + ∀d,B d d ≤ C*‖d‖^2 := by + dsimp only + let χ:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d:=extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + obtain ⟨e,he,hze,heχ,hes,hfe,hge⟩:=exists_joint_exp_inverse_of_nonconjugate z hnc + have hefirst:∀q,(e q).1=q.1 := by intro q; rw [he] + obtain ⟨W,hW,hWe,K,hK,HK⟩:=exists_uniform_fiber_jet_transfer e hefirst hfe hge hze + obtain ⟨G,hG,hact,hagree⟩:=exists_reverse_branch_with_forward_action z hnc + have Hb:=hmtw.exists_local_branch_jet_bound_second hlam hcap + (reverseRay_minimizing hmin) hG hagree hl + simp only [reverseRay_base,reverseRay_endpoint] at Hb + obtain ⟨N,hN,C,hC,HN⟩:=Hb + have hχleft:χ.symm (χ z)=z := χ.left_inv (mem_extChartAt_source z) + have hχsym:ContinuousAt χ.symm (χ z) := continuousAt_extChartAt_symm'' (mem_extChartAt_target z) + have hχlim:Tendsto χ.symm (𝓝 (χ z)) (𝓝 z) := by simpa only [hχleft] using hχsym.tendsto + have hAct:∀ᶠ q in 𝓝 (χ z),G (riemannianExp (χ.symm q).1 (χ.symm q).2,(χ.symm q).1)=‖(χ.symm q).2‖^2/2 := + hχlim.eventually hact + obtain ⟨V,hV,hVo,hVz⟩:=mem_nhds_iff.mp (inter_mem hW hAct) + have hVe:V⊆e.source := fun q hq=>hWe (hV hq).1 + let J:=fun q:(Model n×Model n)×ℝ=>(((e q.1).2,(χ.symm q.1).1),q.2) + have hJ:ContinuousAt J (χ z,l) := by + have hE : ContinuousAt (fun q : (Model n × Model n) × ℝ => e q.1) (χ z,l) := + (e.continuousAt hze).comp (x := (χ z,l)) (f := Prod.fst) continuousAt_fst + have hχ : ContinuousAt (fun q : (Model n × Model n) × ℝ => χ.symm q.1) (χ z,l) := + hχsym.comp (x := (χ z,l)) (f := Prod.fst) continuousAt_fst + have hb := (FiberBundle.continuous_proj (Model n) + (TangentSpace 𝓘(ℝ,Model n))).continuousAt.comp hχ + exact (hE.snd.prodMk hb).prodMk continuousAt_snd + have hJ0:J (χ z,l)=((d (riemannianExp z.1 z.2),z.1),l) := by + dsimp only [J] + rw [he] + dsimp only + rw [hχleft] + let U:=Prod.fst ⁻¹' V ∩ J ⁻¹' N + have hU:U∈𝓝 (χ z,l) := inter_mem + (continuous_fst.continuousAt.preimage_mem_nhds (hVo.mem_nhds hVz)) + (hJ.preimage_mem_nhds (by rwa [hJ0])) + refine ⟨U,hU,C*K,mul_nonneg hC hK,?_⟩ + intro q hq x0 uv huv φ hmono hφ hd hconc B hB hjet ξ + let r:=χ.symm q.1 + let v:=fun w:Model n=>φ (uv.2 (d.symm w))+G (d.symm w,r.1) + have hqe:q.1∈e.source := hVe hq.1 + have hepoint:d.symm (e q.1).2=riemannianExp r.1 r.2 := by + rw [he] + exact d.left_inv (hes q.1 hqe) + have HEq:(fun δ:Model n=>v ((e (q.1.1,q.1.2+δ)).2)) =ᶠ[𝓝 0] + (fun δ=>let s:=χ.symm (q.1.1,q.1.2+δ) + φ (uv.2 (riemannianExp s.1 s.2))+‖s.2‖^2/2) := by + have ht:ContinuousAt (fun δ:Model n=>(q.1.1,q.1.2+δ)) 0 := + continuousAt_const.prodMk (continuousAt_const.add continuousAt_id) + have hv0:(q.1.1,q.1.2+(0:Model n))∈V := by simpa only [add_zero,Prod.eta] using (show q.1∈V from hq.1) + filter_upwards [ht.preimage_mem_nhds (hVo.mem_nhds hv0)] with δ hδ + have hδe:=hVe hδ + have haδ: G (riemannianExp (χ.symm (q.1.1,q.1.2+δ)).1 (χ.symm (q.1.1,q.1.2+δ)).2, + (χ.symm (q.1.1,q.1.2+δ)).1)=‖(χ.symm (q.1.1,q.1.2+δ)).2‖^2/2 := (hV hδ).2 + dsimp only [v] + rw [he] + dsimp only + rw [d.left_inv (hes _ hδe)] + have hb:(χ.symm (q.1.1,q.1.2+δ)).1=r.1 := rfl + rw [hb] at haδ + congr 1 + have hjet':HasLowerSecondTaylor (fun δ:Model n=>v ((e (q.1.1,q.1.2+δ)).2)) 0 B := + hjet.mono HEq.eq_of_nhds.symm HEq.symm.le + apply HK q.1 (hV hq.1).1 v B hjet' hB C hC _ ξ + intro H hH hHjet η + apply HN (J q) hq.2 x0 uv huv φ hmono _ _ _ H hH _ η + · change ContDiffAt ℝ 2 φ (uv.2 (d.symm (e q.1).2)) + rw [hepoint] + exact hφ + · change HasDerivAt φ q.2 (uv.2 (d.symm (e q.1).2)) + rw [hepoint] + exact hd + · change iteratedDeriv 2 φ (uv.2 (d.symm (e q.1).2)) ≤ 0 + rw [hepoint] + exact hconc + · exact hHjet + +end LocalOuterLog +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/LogActionMixed.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/LogActionMixed.lean new file mode 100644 index 0000000000000000000000000000000000000000..6962f51537623b755d93b55f5558474d48cbfeae --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/LogActionMixed.lean @@ -0,0 +1,108 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitPairing + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +def logJoinAction (z : M) (a : ℝ) (P : E → ℝ) + (g : E → TangentSpace 𝓘(ℝ,Model n) z) + (w : TangentSpace 𝓘(ℝ,Model n) z × E) : ℝ := + P w.2+a*normalCost z w.1 (g w.2) + +lemma logJoinAction_contDiffAt {z : M} {a : ℝ} {P : E → ℝ} + {g : E → TangentSpace 𝓘(ℝ,Model n) z} {p : E} + {q : TangentSpace 𝓘(ℝ,Model n) z} + (hq : q∈injectivityDomain z) (hP : ContDiffAt ℝ ∞ P p) + (hg : ContDiffAt ℝ ∞ g p) (hg0 : g p=0) : + ContDiffAt ℝ ∞ (logJoinAction z a P g) (q,p) := by + let V := TangentSpace 𝓘(ℝ,Model n) z + have hA : ContMDiffAt 𝓘(ℝ,V×E) 𝓘(ℝ,Model n) ∞ + (fun w : V×E => riemannianExp z (g w.2)) (q,p) := + (contMDiff_riemannianExp_fiber z _).comp (q,p) + ((hg.comp (q,p) contDiffAt_snd).contMDiffAt) + have hB : ContMDiffAt 𝓘(ℝ,V×E) 𝓘(ℝ,Model n) ∞ + (fun w : V×E => riemannianExp z w.1) (q,p) := + (contMDiff_riemannianExp_fiber z _).comp (q,p) contDiffAt_fst.contMDiffAt + have hC : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun w : M×M => cost w.1 w.2) (riemannianExp z (g p),riemannianExp z q) := by + simpa only [hg0,riemannianExp_zero] using + cost_contMDiffAt_of_injectivityDomain + (⟨z,q⟩ : TangentBundle 𝓘(ℝ,Model n) M) hq + have HC := (hC.comp (f := fun w : V×E => + (riemannianExp z (g w.2),riemannianExp z w.1)) (q,p) (hA.prodMk hB)).contDiffAt + change ContDiffAt ℝ ∞ (fun w : V×E => normalCost z w.1 (g w.2)) (q,p) at HC + exact (hP.comp (q,p) contDiffAt_snd).add (contDiffAt_const.mul HC) + +lemma logJoinAction_middle_gradient {z : M} {a : ℝ} {P : E → ℝ} + {g : E → TangentSpace 𝓘(ℝ,Model n) z} {p : E} + {q : TangentSpace 𝓘(ℝ,Model n) z} + (hq : q∈injectivityDomain z) (hP : DifferentiableAt ℝ P p) + (hg : DifferentiableAt ℝ g p) (hg0 : g p=0) + (hB : DifferentiableAt ℝ (logJoinAction z a P g) (q,p)) (k : E) : + fderiv ℝ (logJoinAction z a P g) (q,p) (0,k)= + fderiv ℝ P p k-a*inner ℝ q (fderiv ℝ g p k) := by + let V := TangentSpace 𝓘(ℝ,Model n) z + have hC : DifferentiableAt ℝ (normalCost z q) (g p) := by + rw [hg0] + exact (normalCost_contDiffAt hq).differentiableAt (by simp) + have hd := hP.hasFDerivAt.add ((hC.hasFDerivAt.comp p hg.hasFDerivAt).const_smul a) + have HI := (hasFDerivAt_const q p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hD := hB.hasFDerivAt.comp (f := fun b : E => (q,b)) p HI + have H := congrArg (fun L : E →L[ℝ] ℝ => L k) (hD.unique hd) + change fderiv ℝ (logJoinAction z a P g) (q,p) (0,k)= + fderiv ℝ P p k+a*fderiv ℝ (normalCost z q) (g p) (fderiv ℝ g p k) at H + rw [hg0,normalCost_fderiv_zero hq] at H + linarith + +lemma logJoinAction_mixed {z : M} {a : ℝ} {P : E → ℝ} + {g : E → TangentSpace 𝓘(ℝ,Model n) z} {p : E} + {q : TangentSpace 𝓘(ℝ,Model n) z} + (hq : q∈injectivityDomain z) (hP : ContDiffAt ℝ ∞ P p) + (hg : ContDiffAt ℝ ∞ g p) (hg0 : g p=0) + (d : TangentSpace 𝓘(ℝ,Model n) z) (k : E) : + fderiv ℝ (fderiv ℝ (logJoinAction z a P g)) (q,p) (d,0) (0,k)= + -a*inner ℝ d (fderiv ℝ g p k) := by + let V := TangentSpace 𝓘(ℝ,Model n) z + have hB := logJoinAction_contDiffAt hq hP hg hg0 (a := a) + have hB2 := hB.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have HI := (hasFDerivAt_id (𝕜 := ℝ) q).prodMk (hasFDerivAt_const p q) + have hd := (((hB2.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun r : V => (r,p)) q HI).clm_apply + (hasFDerivAt_const ((0:V),k) q) + have he : (fun r : V => fderiv ℝ (logJoinAction z a P g) (r,p) (0,k)) =ᶠ[𝓝 q] + (fun r => fderiv ℝ P p k-a*inner ℝ r (fderiv ℝ g p k)) := by + filter_upwards [(isOpen_injectivityDomain z).mem_nhds hq] with r hr + exact logJoinAction_middle_gradient hr (hP.differentiableAt (by simp)) + (hg.differentiableAt (by simp)) hg0 + ((logJoinAction_contDiffAt hr hP hg hg0).differentiableAt (by simp)) k + have hi : HasFDerivAt (fun r : V => fderiv ℝ P p k-a*inner ℝ r (fderiv ℝ g p k)) + (-a • innerSL ℝ (fderiv ℝ g p k)) q := by + convert! ((((innerSL ℝ (fderiv ℝ g p k)).hasFDerivAt (x := q)).const_smul (-a)).const_add + (fderiv ℝ P p k)) using 1 + funext r + simp only [Pi.smul_apply,smul_eq_mul,sub_eq_add_neg,real_inner_comm,neg_mul,innerSL_apply_apply] + have H := congrArg (fun L : V →L[ℝ] ℝ => L d) + ((hd.congr_of_eventuallyEq he.symm).unique hi) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + zero_apply,zero_add, + ContinuousLinearMap.comp_zero,ContinuousLinearMap.flip_apply, + smul_apply,smul_eq_mul,innerSL_apply_apply,real_inner_comm] at H + exact H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldLipschitz.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldLipschitz.lean new file mode 100644 index 0000000000000000000000000000000000000000..62d4376bad6a2f3c7cadabc0dd2f70aa59eb378b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldLipschitz.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates3 +import OAI.Analysis.BiholderTransport.Coordinates.LocalMetricCharts + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {M : Type*} [MetricSpace M] [ChartedSpace F M] + [IsManifold 𝓘(ℝ,F) 1 M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,F) x)] + [IsContinuousRiemannianBundle F (fun x : M => TangentSpace 𝓘(ℝ,F) x)] + [IsRiemannianManifold 𝓘(ℝ,F) M] + +lemma contMDiffAt_exists_lipschitzOn {f : E → M} {x : E} + (hf : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,F) 1 f x) : + ∃ C : ℝ≥0, ∃ U ∈ 𝓝 x, LipschitzOnWith C f U := by + let χ := extChartAt 𝓘(ℝ,F) (f x) + have hχ : ContMDiffAt 𝓘(ℝ,F) 𝓘(ℝ,F) 1 χ (f x) := + contMDiffAt_extChartAt + obtain ⟨D,V,hV,hD⟩ := (((hχ.comp x hf).contDiffAt)).exists_lipschitzOnWith + obtain ⟨C,r,hr,hsub,hC⟩ := exists_lipschitzOn_inverse_chart (E := F) (f x) + let U := V ∩ f ⁻¹' (χ.source ∩ χ ⁻¹' ball (χ (f x)) r) + have hU : U ∈ 𝓝 x := by + apply inter_mem hV + apply hf.continuousAt.preimage_mem_nhds + exact inter_mem (extChartAt_source_mem_nhds (f x)) + (hχ.continuousAt.preimage_mem_nhds (ball_mem_nhds _ hr)) + refine ⟨C*D,U,hU,?_⟩ + have hmaps : MapsTo (χ ∘ f) U (ball (χ (f x)) r) := fun _ hy => hy.2.2 + have hcomp := hC.comp (hD.mono inter_subset_left) hmaps + intro y hy z hz + have hh := hcomp hy hz + change edist (χ.symm (χ (f y))) (χ.symm (χ (f z))) ≤ _ at hh + rwa [χ.left_inv hy.2.1,χ.left_inv hz.2.1] at hh + +lemma contMDiffOn_exists_lipschitzOn_compact {f : E → M} {K : Set E} + (hK : IsCompact K) (hf : ∀ x∈K, ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,F) 1 f x) : + ∃ C : ℝ≥0, LipschitzOnWith C f K := by + apply LocallyLipschitzOn.exists_lipschitzOnWith_of_compact hK + intro x hx + obtain ⟨C,U,hU,hC⟩ := contMDiffAt_exists_lipschitzOn (hf x hx) + exact ⟨C,U,mem_nhdsWithin_of_mem_nhds hU,hC⟩ + +end + +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +lemma movingNormal_trivialization_exp {a x : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (p : TangentSpace 𝓘(ℝ,Model n) x) : + movingNormal a (extChartAt 𝓘(ℝ,Model n) a x, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p) + = riemannianExp x p := by + rw [movingNormal_eq ((extChartAt 𝓘(ℝ,Model n) a).map_source hx), + (extChartAt 𝓘(ℝ,Model n) a).left_inv hx, + Trivialization.symmL_continuousLinearMapAt] + change x∈(chartAt (Model n) a).source + simpa only [extChartAt_source] using hx + +variable [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exp_lipschitz_near_base (R : ℝ) (a : M) : + ∃ L : ℝ≥0, ∃ K ∈ 𝓝 a, ∀ x∈K, ∀ p q : TangentSpace 𝓘(ℝ,Model n) x, + ‖p‖≤R → ‖q‖≤R → dist (riemannianExp x p) (riemannianExp x q)≤L*‖p-q‖ := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hBpos,hB⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + let Bnn : ℝ≥0 := ⟨B,hBpos.le⟩ + obtain ⟨K,hKn,hKs,hKc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) hB) + let χ := extChartAt 𝓘(ℝ,Model n) a + let P := (χ '' K) ×ˢ closedBall (0 : Model n) (B*R) + have hPc : IsCompact P := + (hKc.image_of_continuousOn ((continuousOn_extChartAt a).mono (fun x hx => (hKs hx).1))).prod + (isCompact_closedBall _ _) + obtain ⟨C,hC⟩ := contMDiffOn_exists_lipschitzOn_compact hPc + (f := movingNormal a) (fun z hz => (movingNormal_contMDiffAt (by + obtain ⟨x,hx,hxz⟩ := hz.1 + rw [←hxz] + exact χ.map_source (hKs hx).1)).of_le (by simp)) + refine ⟨C*Bnn,K,hKn,?_⟩ + intro x hx p q hp hq + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x + have hpP : (χ x,A p)∈P := by + refine ⟨mem_image_of_mem χ hx,?_⟩ + rw [mem_closedBall,dist_zero_right] + exact (A.le_opNorm p).trans (mul_le_mul (hKs hx).2.le hp (norm_nonneg _) hBpos.le) + have hqP : (χ x,A q)∈P := by + refine ⟨mem_image_of_mem χ hx,?_⟩ + rw [mem_closedBall,dist_zero_right] + exact (A.le_opNorm q).trans (mul_le_mul (hKs hx).2.le hq (norm_nonneg _) hBpos.le) + have hd := hC.dist_le_mul _ hpP _ hqP + rw [movingNormal_trivialization_exp (hKs hx).1,movingNormal_trivialization_exp (hKs hx).1] at hd + have hdist : dist (χ x,A p) (χ x,A q)≤B*‖p-q‖ := by + rw [Prod.dist_eq,dist_self,max_eq_right dist_nonneg,dist_eq_norm,←map_sub] + exact (A.le_opNorm _).trans (mul_le_mul_of_nonneg_right (hKs hx).2.le (norm_nonneg _)) + calc + _≤(C:ℝ)*dist (χ x,A p) (χ x,A q) := hd + _≤(C:ℝ)*(B*‖p-q‖) := mul_le_mul_of_nonneg_left hdist C.coe_nonneg + _=↑(C*Bnn : ℝ≥0)*‖p-q‖ := by change (C:ℝ)*(B*‖p-q‖)=(C:ℝ)*B*‖p-q‖; ring + +lemma exists_uniform_exp_lipschitz (R : ℝ) : + ∃ L : ℝ≥0, ∀ x : M, ∀ p q : TangentSpace 𝓘(ℝ,Model n) x, + ‖p‖≤R → ‖q‖≤R → dist (riemannianExp x p) (riemannianExp x q)≤L*‖p-q‖ := by + classical + choose L K hKn hK using exp_lipschitz_near_base (n := n) (M := M) R + obtain ⟨s,hs⟩ := finite_cover_nhds hKn + let C : ℝ≥0 := s.sup L + refine ⟨C,?_⟩ + intro x p q hp hq + have hx : x∈ ⋃ a∈s,K a := by rw [hs]; trivial + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp hx + apply (hK a x hxa p q hp hq).trans + apply mul_le_mul_of_nonneg_right _ (norm_nonneg _) + exact_mod_cast (Finset.le_sup (f := L) ha) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldMinimum.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldMinimum.lean new file mode 100644 index 0000000000000000000000000000000000000000..41106b03cca409cbd2eae7197844ea7b897c362f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ManifoldMinimum.lean @@ -0,0 +1,146 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + +lemma IsLocalMin.mfderiv_eq_zero {f : M → ℝ} {x : M} + (h : IsLocalMin f x) (hd : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f x) : + mfderiv 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f x = 0 := by + let c := extChartAt 𝓘(ℝ,E) x + have hx := mem_extChartAt_source (I := 𝓘(ℝ,E)) x + have hc : ContMDiffAt 𝓘(ℝ,E) 𝓘(ℝ,E) ∞ c.symm (c x) := + (contMDiffOn_extChartAt_symm x).contMDiffAt + ((isOpen_extChartAt_target x).mem_nhds (c.map_source hx)) + let F : E → ℝ := fun q => f (c.symm q) + have hF : DifferentiableAt ℝ F (c x) := by + have hd' : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f (c.symm (c x)) := by + rw [c.left_inv hx]; exact hd + exact (hd'.comp (c x) (hc.mdifferentiableAt (by simp))).differentiableAt + have hmin : IsLocalMin F (c x) := by + have hc' : Tendsto c.symm (𝓝 (c x)) (𝓝 x) := by + have H := hc.continuousAt.tendsto + rw [c.left_inv hx] at H + exact H + filter_upwards [hc'.eventually h] with q hq + simpa only [F,c.left_inv hx] using hq + have hzero : HasFDerivAt F 0 (c x) := + hF.hasFDerivAt.congr_fderiv (hmin.hasFDerivAt_eq_zero hF.hasFDerivAt) + have H := hzero.hasMFDerivAt.comp x + (mdifferentiableAt_extChartAt (I := 𝓘(ℝ,E)) (show x ∈ (chartAt E x).source from mem_chart_source E x)).hasMFDerivAt + have heq : f =ᶠ[𝓝 x] (fun y : M => F (c y)) := by + filter_upwards [extChartAt_source_mem_nhds (I := 𝓘(ℝ,E)) x] with y hy + dsimp [F]; rw [c.left_inv hy] + rw [(H.congr_of_eventuallyEq heq).mfderiv] + ext v + rfl + +lemma upper_contact_mfderiv {f g : M → ℝ} {x : M} + (hf : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f x) + (hg : MDifferentiableAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) g x) + (hle : ∀ᶠ y in 𝓝 x, f y ≤ g y) (heq : f x=g x) : + mfderiv 𝓘(ℝ,E) 𝓘(ℝ,ℝ) f x=mfderiv 𝓘(ℝ,E) 𝓘(ℝ,ℝ) g x := by + have hmin : IsLocalMin (fun y => g y-f y) x := by + filter_upwards [hle] with y hy + change g x-f x ≤ g y-f y + rw [heq,sub_self] + exact sub_nonneg.mpr hy + have H := IsLocalMin.mfderiv_eq_zero hmin (hg.sub hf) + change mfderiv 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (g-f) x = 0 at H + rw [mfderiv_sub hg hf] at H + exact (sub_eq_zero.mp H).symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/MetricLocalGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/MetricLocalGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..5731f76d9d89bb5a99cd6ddddbea1079f7db660b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/MetricLocalGrowth.lean @@ -0,0 +1,258 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma metric_local_growth_of_normal {f : M → ℝ} {x : M} {b : ℝ} + (h : ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + b*‖v‖^2≤f (riemannianExp x v)-f x) : + ∀ᶠ z in 𝓝 x, b*dist x z^2≤f z-f x := by + obtain ⟨δ,hδ,hball⟩ := Metric.eventually_nhds_iff.mp h + filter_upwards [Metric.ball_mem_nhds x hδ] with z hz + obtain ⟨v,hv,he⟩ := exists_minimizing_vector (n := n) x z + have hd : ‖v‖=dist x z := by simpa only [minimizingVectors,mem_ofPred_eq,he] using hv.symm + have hh := hball (y := v) (by simpa only [Metric.mem_ball,dist_zero_right,hd,dist_comm] using hz) + simpa only [he,hd] using hh + +lemma WeakMTW.active_hull_metric_growth (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {t : ℝ} (ht : 00, ∀ᶠ z in 𝓝 x, + b*dist x z^2 ≤ cTransform v z-cTransform v x+ + (cost z (riemannianExp x (t • p))-cost x (riemannianExp x (t • p)))/t := by + obtain ⟨b,hb,H⟩ := hmtw.active_hull_local_growth hv hp ht ht1 hID + refine ⟨b,hb,?_⟩ + have hh := metric_local_growth_of_normal (n := n) + (f := fun z => cTransform v z+cost z (riemannianExp x (t • p))/t) + (b := b) (x := x) (by + filter_upwards [H] with h hh + rw [sub_div] at hh + linarith) + filter_upwards [hh] with z hz + rw [sub_div] + linarith + +lemma WeakMTW.active_hull_strict_local_min (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def movingNormalEndpointJoinAction (a c : M) + (r : ℝ×(Model n×Model n)) (z : Model n×Model n) : ℝ := + cost (movingNormal a (r.2.1,0)) (movingNormal a (r.2.1,r.1 • z.2))/r.1+ + cost (movingNormal a (r.2.1,r.1 • z.2)) (movingNormal c (r.2.2,z.1))/(1-r.1) + +lemma movingNormalEndpointJoinAction_contDiffAt {a c : M} {b e p : Model n} {h : ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (he : e∈(extChartAt 𝓘(ℝ,Model n) c).target) + (h0 : h≠0) (h1 : h≠1) + (hend : (extChartAt 𝓘(ℝ,Model n) c).symm e=movingNormal a (b,p)) + (hleft : h • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hright : (1-h) • (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (Function.uncurry (movingNormalEndpointJoinAction a c)) ((h,(b,e)),(0,p)) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + let Q := (ℝ×(Model n×Model n))×(Model n×Model n) + let q : Q := ((h,(b,e)),(0,p)) + have hA : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal a (z.1.2.1,0)) q := + (movingNormal_contMDiffAt (q := (b,0)) hb).comp q + (contDiffAt_fst.snd.fst.prodMk contDiffAt_const).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal a (z.1.2.1,z.1.1 • z.2.2)) q := + (movingNormal_contMDiffAt (q := (b,h • p)) hb).comp q + (contDiffAt_fst.snd.fst.prodMk (contDiffAt_fst.fst.smul contDiffAt_snd.snd)).contMDiffAt + have hC : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal c (z.1.2.2,z.2.1)) q := + (movingNormal_contMDiffAt (q := (e,0)) he).comp q + (contDiffAt_fst.snd.snd.prodMk contDiffAt_snd.fst).contMDiffAt + have hc₁ := cost_contMDiffAt_of_injectivityDomain + (⟨x,h • L p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hleft + have hc₂ := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow h (⟨x,L p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (1-h) • (sprayFlow h (⟨x,L p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + have hc₁' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + (movingNormal a (b,0),movingNormal a (b,h • p)) := by + simpa only [movingNormal_eq hb,map_zero,riemannianExp_zero,map_smul] using hc₁ + have hc₂' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + (movingNormal a (b,h • p),movingNormal c (e,0)) := by + dsimp only at hc₂ + rw [shifted_exp_endpoint] at hc₂ + simp only [movingNormal_eq he,map_zero,riemannianExp_zero,hend] + simpa only [movingNormal_eq hb,map_smul,riemannianExp_smul] using hc₂ + exact ((hc₁'.comp q (hA.prodMk hB)).contDiffAt.div contDiffAt_fst.fst h0).add + ((hc₂'.comp q (hB.prodMk hC)).contDiffAt.div + (contDiffAt_const.sub contDiffAt_fst.fst) (sub_ne_zero.mpr h1.symm)) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingNormalEndpointJoinAction_trivialization {a c x y : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hy : y∈(extChartAt 𝓘(ℝ,Model n) c).source) (h : ℝ) + (u : TangentSpace 𝓘(ℝ,Model n) y) (v : TangentSpace 𝓘(ℝ,Model n) x) : + movingNormalEndpointJoinAction a c + (h,((extChartAt 𝓘(ℝ,Model n) a) x,(extChartAt 𝓘(ℝ,Model n) c) y)) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) c).continuousLinearMapAt ℝ y u, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x v)= + normalEndpointJoinAction x y h (u,v) := by + dsimp only [movingNormalEndpointJoinAction,normalEndpointJoinAction] + rw [← map_zero ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x), + ←map_smul,movingNormal_trivialization_exp hx,movingNormal_trivialization_exp hx, + movingNormal_trivialization_exp hy,riemannianExp_zero] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..da5ed9556a3eef19707f1f6d685f504e5f15d187 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.GaussLemma + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] +local instance normalCoordinatesNormedSpace : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance normalCoordinatesDualNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance normalCoordinatesDualNormedSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance normalCoordinatesBilinearNormedAddCommGroup : + NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance normalCoordinatesBilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance normalCoordinatesTrilinearNormedAddCommGroup : + NormedAddCommGroup (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance normalCoordinatesTrilinearNormedSpace : + NormedSpace ℝ (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace + +lemma coordinate_endpoint_isInvertible + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) + (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {Ψ W : ℝ × E → E} {a b R : ℝ} (hR : 0 < R) + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo a b ×ˢ Metric.ball 0 R)) + (hW : ContDiffOn ℝ ∞ W (Ioo a b ×ˢ Metric.ball 0 R)) + (himg : ∀ t ∈ Ioo a b, ∀ v ∈ Metric.ball 0 R, Ψ (t,v) ∈ S) + (hode : ∀ t ∈ Ioo a b, ∀ v ∈ Metric.ball 0 R, + HasDerivAt (fun q => Ψ (q,v)) (W (t,v)) t ∧ + HasDerivAt (fun q => W (q,v)) + (-coordinateChristoffel g (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {x : E} (h0 : 0 ∈ Ioo a b) + (hΨ0 : ∀ v ∈ Metric.ball 0 R, Ψ (0,v) = x) + (hW0 : ∀ v ∈ Metric.ball 0 R, W (0,v) = v) + {τ : ℝ} (hτ : τ ∈ Ioo a b) (hτne : τ ≠ 0) : + (fderiv ℝ (fun v => Ψ (τ,v)) 0).IsInvertible := by + have hz : (0:E) ∈ Metric.ball 0 R := Metric.mem_ball_self hR + have hx : x ∈ S := hΨ0 0 hz ▸ himg 0 h0 0 hz + have hi : ∀ y ∈ S, (g y).IsInvertible := + fun y hy => metricDual_isInvertible (g y) (hpos y hy) + have hgd : ∀ t ∈ Ioo a b, ∀ v ∈ Metric.ball 0 R, + DifferentiableAt ℝ g (Ψ (t,v)) := fun t ht v hv => + (hg.contDiffAt (hS.mem_nhds (himg t ht v hv))).differentiableAt (by simp) + have hWτ0 : W (τ,0) = 0 := by + have he := coordinate_geodesic_speed_constant + (fun t ht => hgd t ht 0 hz) (fun t ht => hi _ (himg t ht 0 hz)) + (fun t ht => hsym _ (himg t ht 0 hz)) (fun t ht => hode t ht 0 hz) hτ h0 + simp only [hΨ0 0 hz,hW0 0 hz,map_zero] at he + by_contra hn + exact (ne_of_gt (hpos _ (himg τ hτ 0 hz) _ hn)) he + have hopen : IsOpen (Ioo a b ×ˢ Metric.ball (0:E) R) := + isOpen_Ioo.prod Metric.isOpen_ball + have hψ : ContDiffAt ℝ ∞ (fun v => Ψ (τ,v)) 0 := + (hΨ.contDiffAt (hopen.mem_nhds ⟨hτ,hz⟩)).comp 0 + (contDiffAt_const.prodMk contDiffAt_id) + let L := fderiv ℝ (fun v => Ψ (τ,v)) 0 + have hinj : Function.Injective L := by + apply LinearMap.ker_eq_bot.mp + rw [LinearMap.ker_eq_bot'] + intro w hw + let δ := R / (‖w‖+1) + have hd : 0 < δ := div_pos hR (by positivity) + have hsw : ∀ s ∈ Ioo (-δ) δ, s • w ∈ Metric.ball 0 R := by + intro s hs + rw [Metric.mem_ball,dist_zero_right,norm_smul,Real.norm_eq_abs] + have hsa := abs_lt.mpr hs + have hmul : |s| * (‖w‖+1) < R := (lt_div_iff₀ (by positivity)).mp hsa + nlinarith [abs_nonneg s] + let A : ℝ × ℝ → E := fun z => Ψ (z.1,z.2 • w) + let V : ℝ × ℝ → E := fun z => W (z.1,z.2 • w) + have hA : ContDiffOn ℝ ∞ A (Ioo a b ×ˢ Ioo (-δ) δ) := + hΨ.comp (contDiffOn_fst.prodMk (contDiffOn_snd.smul contDiffOn_const)) + (fun z hz => ⟨hz.1,hsw z.2 hz.2⟩) + have hV : ContDiffOn ℝ ∞ V (Ioo a b ×ˢ Ioo (-δ) δ) := + hW.comp (contDiffOn_fst.prodMk (contDiffOn_snd.smul contDiffOn_const)) + (fun z hz => ⟨hz.1,hsw z.2 hz.2⟩) + have hs0 : (0:ℝ) ∈ Ioo (-δ) δ := ⟨neg_neg_of_pos hd,hd⟩ + have hrect : IsOpen (Ioo a b ×ˢ Ioo (-δ) δ) := isOpen_Ioo.prod isOpen_Ioo + have hAat : ContDiffAt ℝ ∞ A (τ,0) := hA.contDiffAt (hrect.mem_nhds ⟨hτ,hs0⟩) + have hVat : ContDiffAt ℝ ∞ V (τ,0) := hV.contDiffAt (hrect.mem_nhds ⟨hτ,hs0⟩) + have hJat := contDiffAt_directionalDerivative hAat (0,1) + have hAr := hasDerivAt_slice_right (hAat.differentiableAt (by simp)) + have hVr := hasDerivAt_slice_right (hVat.differentiableAt (by simp)) + have hJr := hasDerivAt_slice_right (hJat.differentiableAt (by simp)) + have hswder : HasDerivAt (fun s : ℝ => s • w) w 0 := by + convert (hasDerivAt_id (0:ℝ)).smul_const w using 1 <;> first | rfl | simp only [one_smul] + have hψder := (show HasFDerivAt (fun v => Ψ (τ,v)) L ((0:ℝ) • w) by + simpa only [zero_smul] using (hψ.differentiableAt (by simp)).hasFDerivAt + ).comp_hasDerivAt 0 hswder + have hJ0 : directionalDerivative A (0,1) (τ,0) = 0 := by + have he : directionalDerivative A (0,1) (τ,0) = L w := hAr.unique hψder + exact he.trans hw + have hV0' : V (τ,0) = 0 := by simpa only [V,zero_smul] using hWτ0 + have hgdA : DifferentiableAt ℝ g (A (τ,0)) := by + simpa only [A,zero_smul] using hgd τ hτ 0 hz + have hAg : HasDerivAt (fun s => g (A (τ,s))) + ((fderiv ℝ g (A (τ,0))) (directionalDerivative A (0,1) (τ,0))) 0 := + hgdA.hasFDerivAt.comp_hasDerivAt 0 hAr + have hH := (hAg.clm_apply hVr).clm_apply hJr + have hH0 : HasDerivAt (fun s => g (A (τ,s)) (V (τ,s)) + (directionalDerivative A (0,1) (τ,s))) 0 0 := by + convert hH using 1 + simp only [hJ0,hV0',map_zero,zero_apply,add_zero,zero_add] + have hHeq : (fun s => g (A (τ,s)) (V (τ,s)) + (directionalDerivative A (0,1) (τ,s))) =ᶠ[𝓝 0] + (fun s => (τ * g x w w) * s) := by + filter_upwards [isOpen_Ioo.mem_nhds hs0] with s hs + have hν : HasDerivAt (fun s : ℝ => s • w) w s := by + convert (hasDerivAt_id s).smul_const w using 1 <;> first | rfl | simp only [one_smul] + have hG := coordinate_gauss_variation hS hg hi hsym hA hV + (fun t ht r hr => himg t ht (r • w) (hsw r hr)) + (fun t ht r hr => hode t ht (r • w) (hsw r hr)) + h0 (fun r hr => hΨ0 (r • w) (hsw r hr)) + (fun r hr => hW0 (r • w) (hsw r hr)) hτ hs hν + dsimp only [A,V] at hG ⊢ + rw [hG] + simp only [map_smul,smul_apply,smul_eq_mul] + ring + have hderRight : HasDerivAt (fun s => (τ * g x w w) * s) (τ * g x w w) 0 := by + convert (hasDerivAt_id (0:ℝ)).const_mul (τ * g x w w) using 1 <;> first | rfl | simp only [mul_one] + have he := (hH0.congr_of_eventuallyEq hHeq.symm).unique hderRight + have hgww : g x w w = 0 := (mul_eq_zero.mp he.symm).resolve_left hτne + by_contra hn + exact (ne_of_gt (hpos x hx w hn)) hgww + have hsur : Function.Surjective L := LinearMap.injective_iff_surjective.mp hinj + exact ⟨ContinuousLinearEquiv.ofBijective L (LinearMap.ker_eq_bot.mpr hinj) + (LinearMap.range_eq_top.mpr hsur),rfl⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates2.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates2.lean new file mode 100644 index 0000000000000000000000000000000000000000..9841676c411cf0d98fdbf108a5765851296ebb2d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates2.lean @@ -0,0 +1,164 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ImplicitNeighborhood +import OAI.Analysis.BiholderTransport.Geodesics.GaussLemma + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +omit [FiniteDimensional ℝ E] in +lemma coordinate_endpoint_gauss + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hi : ∀ x ∈ S, (g x).IsInvertible) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {Ψ W : ℝ × E → E} {a b R : ℝ} + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo a b ×ˢ Metric.ball 0 R)) + (hW : ContDiffOn ℝ ∞ W (Ioo a b ×ˢ Metric.ball 0 R)) + (himg : ∀ t ∈ Ioo a b, ∀ v ∈ Metric.ball 0 R, Ψ (t,v) ∈ S) + (hode : ∀ t ∈ Ioo a b, ∀ v ∈ Metric.ball 0 R, + HasDerivAt (fun q => Ψ (q,v)) (W (t,v)) t ∧ + HasDerivAt (fun q => W (q,v)) + (-coordinateChristoffel g (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {x : E} (h0 : 0 ∈ Ioo a b) + (hΨ0 : ∀ v ∈ Metric.ball 0 R, Ψ (0,v) = x) + (hW0 : ∀ v ∈ Metric.ball 0 R, W (0,v) = v) + {τ : ℝ} (hτ : τ ∈ Ioo a b) {v : E} (hv : v ∈ Metric.ball 0 R) (w : E) : + g (Ψ (τ,v)) (W (τ,v)) ((fderiv ℝ (fun z => Ψ (τ,z)) v) w) = τ * g x v w := by + have hνc : ContinuousAt (fun s : ℝ => v + s • w) 0 := by fun_prop + have hnear : ∀ᶠ s : ℝ in 𝓝 0, v + s • w ∈ Metric.ball 0 R := + hνc (by simpa only [zero_smul,add_zero] using Metric.isOpen_ball.mem_nhds hv) + obtain ⟨δ,hd,hδ⟩ := Metric.mem_nhds_iff.mp hnear + have hνmem : ∀ s ∈ Ioo (-δ) δ, v + s • w ∈ Metric.ball 0 R := by + intro s hs + exact hδ (by simpa only [Metric.mem_ball,Real.dist_eq,sub_zero] using abs_lt.mpr hs) + let A : ℝ × ℝ → E := fun z => Ψ (z.1,v + z.2 • w) + let V : ℝ × ℝ → E := fun z => W (z.1,v + z.2 • w) + have hA : ContDiffOn ℝ ∞ A (Ioo a b ×ˢ Ioo (-δ) δ) := + hΨ.comp (contDiffOn_fst.prodMk (contDiffOn_const.add + (contDiffOn_snd.smul contDiffOn_const))) (fun z hz => ⟨hz.1,hνmem z.2 hz.2⟩) + have hV : ContDiffOn ℝ ∞ V (Ioo a b ×ˢ Ioo (-δ) δ) := + hW.comp (contDiffOn_fst.prodMk (contDiffOn_const.add + (contDiffOn_snd.smul contDiffOn_const))) (fun z hz => ⟨hz.1,hνmem z.2 hz.2⟩) + have hs0 : (0:ℝ) ∈ Ioo (-δ) δ := ⟨neg_neg_of_pos hd,hd⟩ + have hν : HasDerivAt (fun s : ℝ => v + s • w) w 0 := by + convert ((hasDerivAt_id (0:ℝ)).smul_const w).const_add v using 1 <;> + first | rfl | simp only [one_smul] + have hG := coordinate_gauss_variation hS hg hi hsym hA hV + (fun t ht s hs => himg t ht (v+s•w) (hνmem s hs)) + (fun t ht s hs => hode t ht (v+s•w) (hνmem s hs)) + h0 (fun s hs => hΨ0 (v+s•w) (hνmem s hs)) + (fun s hs => hW0 (v+s•w) (hνmem s hs)) hτ hs0 hν + have hψd : DifferentiableAt ℝ (fun z => Ψ (τ,z)) v := + ((hΨ.contDiffAt ((isOpen_Ioo.prod Metric.isOpen_ball).mem_nhds ⟨hτ,hv⟩)).comp v + (contDiffAt_const.prodMk contDiffAt_id)).differentiableAt (by simp) + have hψder := (show HasFDerivAt (fun z => Ψ (τ,z)) + (fderiv ℝ (fun z => Ψ (τ,z)) v) (v+(0:ℝ)•w) by + simpa only [zero_smul,add_zero] using hψd.hasFDerivAt).comp_hasDerivAt 0 hν + have hAr := hasDerivAt_slice_right ((hA.contDiffAt + ((isOpen_Ioo.prod isOpen_Ioo).mem_nhds ⟨hτ,hs0⟩)).differentiableAt (by simp)) + have hJ : directionalDerivative A (0,1) (τ,0) = + (fderiv ℝ (fun z => Ψ (τ,z)) v) w := hAr.unique hψder + simpa only [A,V,zero_smul,add_zero,hJ] using hG + +omit [FiniteDimensional ℝ E] in +lemma coordinate_geodesic_zero_velocity + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {γ V : ℝ → E} {a b : ℝ} + (hg : ∀ t ∈ Ioo a b, DifferentiableAt ℝ g (γ t)) + (hi : ∀ t ∈ Ioo a b, (g (γ t)).IsInvertible) + (hpos : ∀ t ∈ Ioo a b, ∀ w : E, w ≠ 0 → 0 < g (γ t) w w) + (hsym : ∀ t ∈ Ioo a b, ∀ u v, g (γ t) u v = g (γ t) v u) + (hode : ∀ t ∈ Ioo a b, HasDerivAt γ (V t) t ∧ + HasDerivAt V (-coordinateChristoffel g (γ t) (V t) (V t)) t) + {s : ℝ} (hs : s ∈ Ioo a b) (hVs : V s = 0) {t : ℝ} (ht : t ∈ Ioo a b) : + γ t = γ s ∧ V t = 0 := by + have hVz : ∀ q ∈ Ioo a b, V q = 0 := by + intro q hq + have h := coordinate_geodesic_speed_constant hg hi hsym hode hq hs + simp only [hVs,map_zero] at h + by_contra hn + exact (ne_of_gt (hpos q hq _ hn)) h + refine ⟨?_,hVz t ht⟩ + apply isOpen_Ioo.is_const_of_deriv_eq_zero (convex_Ioo a b).isPreconnected + (fun q hq => (hode q hq).1.differentiableAt.differentiableWithinAt) _ ht hs + intro q hq + exact (hode q hq).1.deriv.trans (hVz q hq) + +end + +variable {Y : Type*} [NormedAddCommGroup Y] [NormedSpace ℝ Y] [CompleteSpace Y] +lemma exists_smooth_local_diffeomorphism {f : Y → Y} {S : Set Y} + (hS : IsOpen S) (hf : ContDiffOn ℝ ∞ f S) {a : Y} (ha : a ∈ S) + (hi : (fderiv ℝ f a).IsInvertible) : + ∃ e : OpenPartialHomeomorph Y Y, (e : Y → Y) = f ∧ a ∈ e.source ∧ + e.source ⊆ S ∧ ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target := by + have hfa : ContDiffAt ℝ ∞ f a := hf.contDiffAt (hS.mem_nhds ha) + obtain ⟨L,hL⟩ := hi + have hder : HasFDerivAt f (L : Y →L[ℝ] Y) a := + hL ▸ (hfa.differentiableAt (by simp)).hasFDerivAt + let e := hfa.toOpenPartialHomeomorph f hder (by simp) + have hea : a ∈ e.source := hfa.mem_toOpenPartialHomeomorph_source hder (by simp) + have hfc : ContinuousAt (fderiv ℝ f) a := + (hf.continuousOn_fderiv_of_isOpen hS (by simp) a ha).continuousAt (hS.mem_nhds ha) + have hev : ∀ᶠ y in 𝓝 a, y ∈ S ∧ (fderiv ℝ f y).IsInvertible := + (show ∀ᶠ y in 𝓝 a, y ∈ S from hS.mem_nhds ha).and + (hfc (isOpen_invertible_endomorphism.mem_nhds ⟨L,hL⟩)) + obtain ⟨U,hUsub,hU,haU⟩ := mem_nhds_iff.mp hev + let d := e.restrOpen U hU + have hdf : (d : Y → Y) = f := rfl + have hdsub : d.source ⊆ S := fun _ hz => (hUsub hz.2).1 + refine ⟨d,hdf,⟨hea,haU⟩,hdsub,?_,?_⟩ + · simpa only [hdf] using hf.mono hdsub + · intro z hz + have hy := d.map_target hz + have hfy : ContDiffAt ℝ ∞ f (d.symm z) := hf.contDiffAt (hS.mem_nhds (hdsub hy)) + obtain ⟨A,hA⟩ := (hUsub hy.2).2 + have hdy : HasFDerivAt d (A : Y →L[ℝ] Y) (d.symm z) := by + rw [hdf,hA] + exact (hfy.differentiableAt (by simp)).hasFDerivAt + exact (d.contDiffAt_symm hz hdy (by simpa only [hdf] using hfy)).contDiffWithinAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates3.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates3.lean new file mode 100644 index 0000000000000000000000000000000000000000..675569224b3b285e1daa1e133c106ffe1fb05ff3 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalCoordinates3.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiniteActiveGrowth +import OAI.Analysis.BiholderTransport.Regularity.SecondFderivCompLinear + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma hessianValue_zero (x : M) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + hessianValue x 0 xi = ‖xi‖^2 := by + have hA := (hessianValue_contDiffAt (zero_mem_injectivityDomain (n := n) x) xi).continuousAt + have hl : ContinuousAt (fun r : ℝ => r • xi) 0 := continuousAt_id.smul continuousAt_const + have h0 : (0:ℝ) • xi = 0 := zero_smul ℝ xi + have hc : ContinuousAt (fun r : ℝ => hessianValue x (r • xi) xi) 0 := by + exact (show ContinuousAt (fun q => hessianValue x q xi) ((0:ℝ) • xi) by simpa using hA).comp (x := (0:ℝ)) (f := fun r : ℝ => r • xi) hl + have he : ∀ᶠ r : ℝ in 𝓝 0, r • xi ∈ injectivityDomain x := by + exact hl.preimage_mem_nhds ((isOpen_injectivityDomain x).mem_nhds (by simpa using zero_mem_injectivityDomain (n := n) x)) + have heq : (fun r : ℝ => hessianValue x (r • xi) xi) =ᶠ[𝓝[≠] 0] (fun _ => ‖xi‖^2) := by + filter_upwards [he.filter_mono nhdsWithin_le_nhds,self_mem_nhdsWithin] with r hr hr0 + exact hessianValue_contracted_radial hr0 hr + have H := tendsto_nhds_unique_of_eventuallyEq (hc.mono_left nhdsWithin_le_nhds) + (continuousAt_const.mono_left nhdsWithin_le_nhds) heq + simpa only [zero_smul] using H + +def movingNormal (a : M) (q : Model n × Model n) : M := + let z := (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).symm q + riemannianExp z.1 z.2 + +lemma movingNormal_contMDiffAt {a : M} {q : Model n × Model n} + (hq : q.1 ∈ (extChartAt 𝓘(ℝ,Model n) a).target) : + ContMDiffAt 𝓘(ℝ,Model n × Model n) 𝓘(ℝ,Model n) ∞ (movingNormal a) q := by + have hT : q ∈ (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).target := + (tangent_chart_target_iff _ q).mpr hq + exact (contMDiff_riemannianExp (n := n) (M := M) _).comp q ((contMDiffOn_extChartAt_symm _).contMDiffAt ((isOpen_extChartAt_target _).mem_nhds hT)) + +section +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +lemma movingNormal_eq {a : M} {b : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) (h : Model n) : + movingNormal a (b,h) = riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) h) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + have hx : x ∈ (chartAt (Model n) a).source := by + simpa only [x,extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hb + change riemannianExp x (tangentCoordChange 𝓘(ℝ,Model n) a x x h) = _ + rw [TangentBundle.symmL_trivializationAt_eq_core hx] + rfl + +lemma movingNormal_zero {a : M} {b : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) : + movingNormal a (b,0) = (extChartAt 𝓘(ℝ,Model n) a).symm b := by + rw [movingNormal_eq hb,map_zero,riemannianExp_zero] + +def movingNormalCost (a : M) (b p h : Model n) : ℝ := + cost (movingNormal a (b,h)) (movingNormal a (b,p)) + +lemma movingNormalCost_eq {a : M} {b : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) (p h : Model n) : + movingNormalCost a b p h = + normalCost ((extChartAt 𝓘(ℝ,Model n) a).symm b) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) h) := by + simp only [movingNormalCost,movingNormal_eq hb,normalCost] + +end + +lemma movingNormalCost_contDiffAt {a : M} {b p : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + ContDiffAt ℝ ∞ (fun q : (Model n × Model n) × Model n => + movingNormalCost a q.1.1 q.1.2 q.2) ((b,p),0) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + have hA : ContMDiffAt 𝓘(ℝ,(Model n × Model n) × Model n) 𝓘(ℝ,Model n) ∞ + (fun q : (Model n × Model n) × Model n => movingNormal a (q.1.1,q.2)) ((b,p),0) := + (movingNormal_contMDiffAt (q := (b,0)) hb).comp ((b,p),0) + (contDiffAt_fst.fst.prodMk contDiffAt_snd).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,(Model n × Model n) × Model n) 𝓘(ℝ,Model n) ∞ + (fun q : (Model n × Model n) × Model n => movingNormal a (q.1.1,q.1.2)) ((b,p),0) := + (movingNormal_contMDiffAt (q := (b,p)) hb).comp ((b,p),0) contDiffAt_fst.contMDiffAt + have hC : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (movingNormal a (b,0),movingNormal a (b,p)) := by + rw [movingNormal_zero hb,movingNormal_eq hb] + exact cost_contMDiffAt_of_injectivityDomain ⟨x,L p⟩ hp + exact ((hC.comp ((b,p),0) (hA.prodMk hB)).contDiffAt) + +lemma movingNormalCost_hasFDerivAt_zero {a : M} {b p : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + HasFDerivAt (movingNormalCost a b p) + ((innerSL ℝ (-((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p))).comp + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b))) 0 := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + have he : movingNormalCost a b p = (fun h => normalCost x (L p) (L h)) := by + funext h + exact movingNormalCost_eq hb p h + rw [he] + exact (show HasFDerivAt (normalCost x (L p)) (innerSL ℝ (-L p)) (L 0) by + simpa only [map_zero] using normalCost_hasFDerivAt_zero hp).comp 0 L.hasFDerivAt + +lemma movingNormalCost_second {a : M} {b p : Model n} + (hb : b ∈ (extChartAt 𝓘(ℝ,Model n) a).target) + (hp : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p ∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) (v : Model n) : + fderiv ℝ (fderiv ℝ (movingNormalCost a b p)) 0 v v = + hessianValue ((extChartAt 𝓘(ℝ,Model n) a).symm b) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) v) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + have he : movingNormalCost a b p = (fun h => normalCost x (L p) (L h)) := by + funext h + exact movingNormalCost_eq hb p h + rw [he, second_fderiv_comp_linear_zero + ((normalCost_contDiffAt hp).of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)), hessianValue_eq_normalHessian hp] + rfl + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEikonal.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEikonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..a408b378fd7c4f48c5b23a1b3c878ee1ba505444 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEikonal.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section NormalEikonal +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def doubleNormalCost (x y : M) + (z : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) y) : ℝ := + cost (riemannianExp x z.1) (riemannianExp y z.2) + +lemma doubleNormalCost_contDiffAt {x y : M} {r : TangentSpace 𝓘(ℝ,Model n) y} + (hr : r∈injectivityDomain y) (he : riemannianExp y r=x) : + ContDiffAt ℝ ∞ (doubleNormalCost (n := n) x y) (0,0) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + have hu : ContMDiffAt 𝓘(ℝ,X×Y) 𝓘(ℝ,Model n) ∞ + (fun z : X×Y => riemannianExp y z.2) (0,0) := + (contMDiff_riemannianExp_fiber y _).comp (0,0) contDiffAt_snd.contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,X×Y) 𝓘(ℝ,Model n) ∞ + (fun z : X×Y => riemannianExp x z.1) (0,0) := + (contMDiff_riemannianExp_fiber x _).comp (0,0) contDiffAt_fst.contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨y,r⟩ : TangentBundle 𝓘(ℝ,Model n) M) hr + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp y (0:Y),riemannianExp x (0:X)) := by + simpa only [riemannianExp_zero,he] using hc + have H := (hc'.comp (0,0) (hu.prodMk hv)).contDiffAt + convert! H using 1 + funext z + exact congrArg (fun d : ℝ => d^2/2) (dist_comm _ _) + +lemma exists_normal_eikonal_log {x y : M} {r : TangentSpace 𝓘(ℝ,Model n) y} + (hr : r∈injectivityDomain y) (he : riemannianExp y r=x) : + ∃ q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y, + q 0=r ∧ ContDiffAt ℝ ∞ q 0 ∧ + (∀ᶠ a in 𝓝 0, riemannianExp y (q a)=riemannianExp x a) ∧ + (∀ᶠ a in 𝓝 0, + doubleNormalCost x y (a,0)=‖q a‖^2/2 ∧ + fderiv ℝ (fun b => doubleNormalCost x y (a,b)) 0=innerSL ℝ (-q a)) := by + let : Nonempty M := ⟨x⟩ + let : MeasurableSpace M := borel M + let : BorelSpace M := ⟨rfl⟩ + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + obtain ⟨κ,hκ0,hκ,hκright⟩ := exists_normal_local_inverse_at hr + rw [he] at hκ0 hκ hκright + let q : X → Y := κ ∘ riemannianExp (n := n) x + have hq0 : q 0=r := by simp only [q,Function.comp_apply,riemannianExp_zero,hκ0] + have hq : ContDiffAt ℝ ∞ q 0 := by + apply ContMDiffAt.contDiffAt + exact (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Y) ∞ κ (riemannianExp x (0:X)) from + by simpa only [riemannianExp_zero] using hκ).comp 0 (contMDiff_riemannianExp_fiber x 0) + have hqright : ∀ᶠ a in 𝓝 0, riemannianExp y (q a)=riemannianExp x a := + (show ContinuousAt (riemannianExp (n := n) x) (0:X) from + (continuous_riemannianExp x).continuousAt).eventually + (by simpa only [riemannianExp_zero] using hκright) + have hqI : ∀ᶠ a in 𝓝 0, q a∈injectivityDomain y := + hq.continuousAt.preimage_mem_nhds ((isOpen_injectivityDomain y).mem_nhds (hq0.symm ▸ hr)) + refine ⟨q,hq0,hq,hqright,?_⟩ + filter_upwards [hqright,hqI] with a ha haI + change riemannianExp y (q a)=riemannianExp x a at ha + change q a∈injectivityDomain y at haI + constructor + · have hm := injectivityDomain_subset_minimizingVectors y haI + change dist y (riemannianExp y (q a))=‖q a‖ at hm + simp only [doubleNormalCost,riemannianExp_zero,cost,←ha,dist_comm _ y,hm] + · have heq : (fun b => doubleNormalCost x y (a,b))=normalCost y (q a) := by + funext b + dsimp [doubleNormalCost,normalCost,cost] + rw [←ha,dist_comm] + rw [heq] + exact (normalCost_hasFDerivAt_zero haI).fderiv + +end NormalEikonal +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointInverse.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..adc21888ce18ae6b90156cf299de4bdc332ae064 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointInverse.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.FixedJoinSpectrum +import OAI.Analysis.BiholderTransport.Volume.UniformJacobian +import OAI.Analysis.BiholderTransport.Convexity.EndpointLowerJet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section NormalEndpointInverse +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma exists_normal_endpoint_inverse {x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + (hp:Function.Injective (fderiv ℝ (fun v=>extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)) : + ∃ (e:TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p) → TangentSpace 𝓘(ℝ,Model n) x) + (C:TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p)), + ContDiffAt ℝ ∞ e 0 ∧ e 0=p ∧ + (∀ᶠ w in 𝓝 0,riemannianExp x (e w)=riemannianExp (riemannianExp x p) w) ∧ + Function.Injective C ∧ C.comp (fderiv ℝ e 0)=ContinuousLinearMap.id ℝ _ ∧ + (fderiv ℝ e 0).comp C=ContinuousLinearMap.id ℝ _ ∧ + expJacobian x p=C.toLinearMap.normDet := by + let y:=riemannianExp x p + let E:=TangentSpace 𝓘(ℝ,Model n) x + let F:=TangentSpace 𝓘(ℝ,Model n) y + obtain ⟨e,he,he0,hei,heD⟩:=exists_smooth_normal_endpoint_log_of_nonconjugate (y:=y) rfl hp + obtain ⟨R,hR,hR0,hRi⟩:=exists_normal_endpoint_coordinates x p + let C:E →L[ℝ] F:=fderiv ℝ R p + let J:F →L[ℝ] E:=fderiv ℝ e 0 + have hJD:HasFDerivAt e J 0:= (he.differentiableAt (by simp)).hasFDerivAt + have hCD:HasFDerivAt R C p:= (hR.differentiableAt (by simp)).hasFDerivAt + have hn:injectivityDomain y∈𝓝 (0:F):= + (isOpen_injectivityDomain y).mem_nhds (zero_mem_injectivityDomain y) + have hRcomp:ContinuousAt (fun w=>R (e w)) 0:= + (show ContinuousAt R (e 0) from by rw [he0]; exact hR.continuousAt).comp he.continuousAt + have hRcomp0:R (e 0)=0:=by rw [he0,hR0] + have hId:(fun w:F=>R (e w)) =ᶠ[𝓝 0] id:=by + have hrn:=hRcomp.eventually (show injectivityDomain y∈𝓝 (R (e 0)) from by rw [hRcomp0]; exact hn) + have hri:=he.continuousAt.eventually (show ∀ᶠ v in 𝓝 (e 0), + riemannianExp y (R v)=riemannianExp x v from by rw [he0]; exact hRi) + filter_upwards [hei,hrn,hn,hri] with w hw hr hw0 hri + exact riemannianExp_injOn_injectivityDomain y hr hw0 (hri.trans hw) + have hCJ:C.comp J=ContinuousLinearMap.id ℝ F:=by + have H:HasFDerivAt (fun w=>R (e w)) (C.comp J) 0:= + (show HasFDerivAt R C (e 0) from by rw [he0]; exact hCD).comp 0 hJD + exact H.fderiv.symm.trans (hId.fderiv_eq.trans (fderiv_id)) + have hsur:Function.Surjective J:=(LinearMap.injective_iff_surjective_of_finrank_eq_finrank + ((tangent_finrank (n:=n) y).trans (tangent_finrank (n:=n) x).symm)).mp heD + have hJC:J.comp C=ContinuousLinearMap.id ℝ E:=by + ext d + obtain ⟨w,rfl⟩:=hsur d + have H:=congrArg (fun A:F →L[ℝ] F=>A w) hCJ + change C (J w)=w at H + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply,H] + have hCI:Function.Injective C:=by + intro d e h + have h1:=congrArg (fun A:E →L[ℝ] E=>A d) hJC + have h2:=congrArg (fun A:E →L[ℝ] E=>A e) hJC + change J (C d)=d at h1 + change J (C e)=e at h2 + exact h1.symm.trans ((congrArg J h).trans h2) + exact ⟨e,C,he,he0,hei,hCI,hCJ,hJC, + expJacobian_eq_normal_endpoint (hR.differentiableAt (by simp)) hR0 hRi⟩ +end NormalEndpointInverse +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointJoin.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointJoin.lean new file mode 100644 index 0000000000000000000000000000000000000000..faf53f4e808d2891ac07932ce346ee479ec91573 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalEndpointJoin.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.PrefixAction +import OAI.Analysis.BiholderTransport.Coordinates.FixedJoinSmooth +import OAI.Analysis.BiholderTransport.Regularity.FixedJoinMiddle + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteNormalEndpoint (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def normalEndpointJoinAction (x y : M) (h : ℝ) + (q : TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost x (riemannianExp x (h • q.2))/h+ + cost (riemannianExp x (h • q.2)) (riemannianExp y q.1)/(1-h) + +lemma normalEndpointJoinAction_contDiffAt {x y : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hend : riemannianExp x p=y) + (hleft : h • p∈injectivityDomain x) + (hright : (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (normalEndpointJoinAction x y h) (0,p) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let W := TangentSpace 𝓘(ℝ,Model n) y + have hP : ContDiffAt ℝ ∞ (fun b : V => cost x (riemannianExp x (h • b))/h) p := by + have H := (prefixAction_contDiffAt hleft).comp p (contDiffAt_const.prodMk contDiffAt_id) + simpa only [prefixAction,Function.comp_def,riemannianExp_zero] using H + have hA : ContMDiffAt 𝓘(ℝ,W×V) 𝓘(ℝ,Model n) ∞ + (fun q : W×V => riemannianExp x (h • q.2)) (0,p) := + (contMDiff_riemannianExp_fiber x (h • p)).comp (0,p) + (((contDiffAt_const (c := h)).smul contDiffAt_snd).contMDiffAt) + have hB : ContMDiffAt 𝓘(ℝ,W×V) 𝓘(ℝ,Model n) ∞ + (fun q : W×V => riemannianExp y q.1) (0,p) := + (contMDiff_riemannianExp_fiber y 0).comp (0,p) contDiffAt_fst.contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + dsimp only at hc + rw [shifted_exp_endpoint,hend] at hc + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (h • p),riemannianExp (n := n) y 0) := by + simpa only [riemannianExp_smul,riemannianExp_zero] using hc + exact (hP.comp (0,p) contDiffAt_snd).add ((hc'.comp (0,p) (hA.prodMk hB)).contDiffAt.div_const (1-h)) + +lemma normalEndpointJoinAction_factor {x y : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + {L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hh : 0 (L v,v)) p := hL.continuousAt.prodMk continuousAt_id + have hBn := hmap.eventually ((hBL.of_le (m := 1) (by norm_num)).eventually (by norm_num)) + filter_upwards [split_regular_legs_near hleft hright,hBn,hLi] with v hvreg hvB hvi + change ContDiffAt ℝ 1 B (L v,v) at hvB + intro k + have heq : (fun b => B (L v,b))=(fun b => diagonalSplitAction x h (v,b)) := by + funext b + simp only [B,normalEndpointJoinAction,hvi,diagonalSplitAction,splitNormalAction,riemannianExp_zero] + rw [←fderiv_snd_slice (hvB.differentiableAt (by norm_num)) k,heq, + fderiv_snd_slice ((diagonalSplitAction_contDiffAt hvreg.1 hvreg.2).differentiableAt (by simp))] + exact diagonalSplitAction_stationary hh hh1 hvreg.1 hvreg.2 k + have hFactor := diagonal_stationary_factorization hBL + (hL.differentiableAt (by simp)).hasFDerivAt hstat + have hfixed := (fixedJoinAction_contDiffAt hh1.ne' hleft hright).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have heq : (fun b : V => fixedJoinAction x h 1 p (0,b))=(fun b => B (0,b)) := by + funext b + simp only [fixedJoinAction,B,normalEndpointJoinAction,riemannianExp_zero,one_smul,hend] + rw [fixedJoinMiddle_eq_slice hfixed,heq,second_fderiv_snd_slice hB2] + simpa only [hLp] using hFactor d k + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalFrameTaylor.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalFrameTaylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..6eccd4f120ef773c9045b91c84ed4053923db730 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalFrameTaylor.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.JetPullback +import OAI.Analysis.BiholderTransport.Coordinates.NormalPoleTaylor + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section NormalFrameTaylor +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteNF (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance tangentCompleteNF (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +omit [Nonempty M] in +lemma chart_normal_pole_frame_identity {E:Type*} [NormedAddCommGroup E] + [InnerProductSpace ℝ E] [CompleteSpace E] [FiniteDimensional ℝ E] {f:M → ℝ} {x y a:M} + {r:TangentSpace 𝓘(ℝ,Model n) y} {q:TangentSpace 𝓘(ℝ,Model n) x} + (B:E →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) + (hr:r∈injectivityDomain y) (hq:q∈injectivityDomain x) + (hyx:riemannianExp y r=x) (hxy:riemannianExp x q=y) + (hy:y∈(extChartAt 𝓘(ℝ,Model n) a).source) + {S:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hS:HasQuadraticExpansion (fun h=>f (riemannianExp y h)) r S) + {p:Model n} {A:Model n →L[ℝ] Model n} + (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) + (hAe:HasQuadraticExpansion (fun h=>f ((extChartAt 𝓘(ℝ,Model n) a).symm + (extChartAt 𝓘(ℝ,Model n) a y+h))) p A) + {R:TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hR:DifferentiableAt ℝ R q) (hR0:R q=0) + (hRe:∀ᶠ v in 𝓝 q,riemannianExp y (R v)=riemannianExp x v) : + let g:=fun h:E=> + extChartAt 𝓘(ℝ,Model n) a (riemannianExp x (q+B h))-extChartAt 𝓘(ℝ,Model n) a y + ∀d,‖B d‖^2+secondJetPullback (innerSL ℝ p) ((innerSL ℝ).comp A) + (fderiv ℝ g 0) (fderiv ℝ (fderiv ℝ g) 0) d d= + inner ℝ (S (fderiv ℝ R q (B d))) (fderiv ℝ R q (B d))+ + normalHessian y r (fderiv ℝ R q (B d)) (fderiv ℝ R q (B d)) := by + dsimp only + let χ:=extChartAt 𝓘(ℝ,Model n) a + let g:=fun h:E=>χ (riemannianExp x (q+B h))-χ y + have hg0:g 0=0:=by simp only [g,map_zero,add_zero,hxy,sub_self] + have hchart:ContDiffAt ℝ ∞ (fun v:TangentSpace 𝓘(ℝ,Model n) x=>χ (riemannianExp x v)) q:=by + apply contMDiffAt_iff_contDiffAt.mp + exact (contMDiffAt_extChartAt' (x:=a) (by simpa only [hxy,extChartAt_source] using hy)).comp q + (contMDiff_riemannianExp_fiber x q) + have hg:ContDiffAt ℝ 2 g 0:=by + apply ContDiffAt.of_le _ (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hc : ContDiffAt ℝ ∞ (fun v:TangentSpace 𝓘(ℝ,Model n) x=>χ (riemannianExp x v)) (q+B 0) := by + simpa only [map_zero,add_zero] using hchart + exact (hc.comp 0 (contDiffAt_const.add B.contDiff.contDiffAt)).sub contDiffAt_const + have H:=quadratic_expansion_comp_proxy hAe hg hg0 + simp only [add_zero] at H + let P:=quadraticTaylor (f (χ.symm (χ y))) p A + have he:HasSecondTaylor (fun h=>f (riemannianExp x (q+B h))) + (fderiv ℝ (fun h=>P (g h)) 0) (fderiv ℝ (fderiv ℝ (fun h=>P (g h))) 0):=by + apply H.congr_of_eventuallyEq + have ht:ContinuousAt (fun h:E=>riemannianExp x (q+B h)) 0:= + (contMDiff_riemannianExp_fiber x).continuous.continuousAt.comp (continuousAt_const.add B.continuous.continuousAt) + have hh:=ht.eventually ((isOpen_extChartAt_source a).mem_nhds (by simpa only [map_zero,add_zero,hxy] using hy)) + filter_upwards [hh] with h hh + change f (riemannianExp x (q+B h))=f (χ.symm (χ y+(χ (riemannianExp x (q+B h))-χ y))) + rw [show χ y+(χ (riemannianExp x (q+B h))-χ y)=χ (riemannianExp x (q+B h)) by abel,χ.left_inv hh] + have hn:ContDiffAt ℝ 2 (fun h:E=>‖q+B h‖^2/2) 0:= + (half_norm_sq_contDiff.comp (contDiff_const.add B.contDiff)).contDiffAt.of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have HT:=he.add (hasSecondTaylor_of_contDiffAt hn) + have HT2:=(normal_stationary_pole_taylor hr hq hyx hS hR hR0 hRe).comp_stationary B.hasFDerivAt (map_zero B) + intro d + have HH:=HT.diagonal_unique' HT2 d + rw [quadratic_proxy_pullback hA hg hg0] at HH + simp only [add_apply,ContinuousLinearMap.comp_apply] at HH + have hshift: fderiv ℝ (fderiv ℝ (fun h:E=>‖q+B h‖^2/2)) 0 d d=‖B d‖^2:=by + have hf:ContDiffAt ℝ 2 (fun v:TangentSpace 𝓘(ℝ,Model n) x=>‖v‖^2/2) (q+B 0) := + half_norm_sq_contDiff.contDiffAt.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + simpa only [ContinuousLinearMap.id_apply,half_norm_sq_second_fderiv,innerSL_apply_apply,real_inner_self_eq_norm_sq] using + second_fderiv_comp_affine B q 0 hf d d + rw [hshift] at HH + change secondJetPullback (innerSL ℝ p) ((innerSL ℝ).comp A) + (fderiv ℝ g 0) (fderiv ℝ (fderiv ℝ g) 0) d d+‖B d‖^2= + inner ℝ (S (fderiv ℝ R q (B d))) (fderiv ℝ R q (B d))+ + normalHessian y r (fderiv ℝ R q (B d)) (fderiv ℝ R q (B d)) at HH + linarith only [HH] +end NormalFrameTaylor +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalGradient.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf335d5d7330f22f1b055ef5b0fcf58d5f6b03d4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalGradient.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.RadialCalibration + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma normal_action_hasFDerivAt + (e : OpenPartialHomeomorph E E) {y : E} (hy : y ∈ e.target) + (he : DifferentiableAt ℝ e (e.symm y)) (hi : DifferentiableAt ℝ e.symm y) + (g₀ g₁ : E →L[ℝ] E →L[ℝ] ℝ) (hsym : ∀ u v, g₀ u v = g₀ v u) + (V : E) (τ : ℝ) + (hgauss : ∀ w, g₁ V ((fderiv ℝ e (e.symm y)) w) = τ * g₀ (e.symm y) w) : + HasFDerivAt (fun z => (τ^2/2) * g₀ (e.symm z) (e.symm z)) + (τ • g₁ V) y := by + have hg := (((g₀.hasFDerivAt.comp y hi.hasFDerivAt).clm_apply hi.hasFDerivAt).const_mul (τ^2/2)) + convert! hg using 1 + ext w + have hd := congrArg (fun L : E →L[ℝ] E => L w) + (fderiv_partial_homeomorph_right_inverse e hy he hi) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply] at hd + have hG := hgauss ((fderiv ℝ e.symm y) w) + rw [hd] at hG + simp only [smul_apply,add_apply, + ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply,smul_eq_mul,Function.comp_apply] + rw [hsym ((fderiv ℝ e.symm y) w) (e.symm y)] + rw [hG] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLogMixed.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLogMixed.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ca098a4cb58828c994982ca7e3093a1d2264644 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLogMixed.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions +import OAI.Analysis.BiholderTransport.Coordinates.LogActionMixed +import OAI.Analysis.BiholderTransport.Calculus.SliceDerivatives + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {F : Type*} [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma normalCost_log_contDiffAt {x : M} {e : F → TangentSpace 𝓘(ℝ,Model n) x} + {b : F} (he : ContDiffAt ℝ ∞ e b) (hp : e b∈injectivityDomain x) : + ContDiffAt ℝ ∞ (fun q : F×TangentSpace 𝓘(ℝ,Model n) x => normalCost x (e q.1) q.2) (b,0) := by + have H := logJoinAction_contDiffAt hp (contDiffAt_const (c := (0:ℝ))) + (contDiffAt_id (𝕜 := ℝ)) rfl (a := 1) + have HH := H.comp (b,0) ((he.comp (b,0) contDiffAt_fst).prodMk contDiffAt_snd) + simpa only [logJoinAction,zero_add,one_mul,Function.comp_def,id_eq] using HH + +lemma normalCost_log_mixed {x : M} {e : F → TangentSpace 𝓘(ℝ,Model n) x} + {b : F} (he : ContDiffAt ℝ ∞ e b) (hp : e b∈injectivityDomain x) + (d : F) (k : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (fun q : F×TangentSpace 𝓘(ℝ,Model n) x => + normalCost x (e q.1) q.2)) (b,0) (d,0) (0,k) = -inner ℝ (fderiv ℝ e b d) k := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let B := logJoinAction x (1:ℝ) (fun _:V => (0:ℝ)) (id:V→V) + have hB : ContDiffAt ℝ ∞ B (e b,0) := + logJoinAction_contDiffAt hp contDiffAt_const contDiffAt_id rfl + have heq : (fun q : F×V => normalCost x (e q.1) q.2)=(fun q => B (e q.1,q.2)) := by + ext q; simp only [B,logJoinAction,zero_add,one_mul,id_eq] + rw [heq,second_fderiv_map_fst + (hB.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + (he.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2))] + have H := logJoinAction_mixed hp (contDiffAt_const (c := (0:ℝ))) + (contDiffAt_id (𝕜 := ℝ)) rfl (a := 1) (fderiv ℝ e b d) k + simpa only [B,fderiv_id,ContinuousLinearMap.id_apply,neg_one_mul] using H + +lemma normal_log_derivatives_adjoint {x y : M} + {e : TangentSpace 𝓘(ℝ,Model n) y → TangentSpace 𝓘(ℝ,Model n) x} + {f : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (he : ContDiffAt ℝ ∞ e 0) (hf : ContDiffAt ℝ ∞ f 0) + (hep : e 0∈injectivityDomain x) (hfq : f 0∈injectivityDomain y) + (hei : ∀ᶠ v in 𝓝 0, riemannianExp x (e v)=riemannianExp y v) + (hfi : ∀ᶠ u in 𝓝 0, riemannianExp y (f u)=riemannianExp x u) + (d : TangentSpace 𝓘(ℝ,Model n) y) (k : TangentSpace 𝓘(ℝ,Model n) x) : + inner ℝ (fderiv ℝ e 0 d) k=inner ℝ d (fderiv ℝ f 0 k) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let W := TangentSpace 𝓘(ℝ,Model n) y + let A : W×V → ℝ := fun q => normalCost x (e q.1) q.2 + let B : V×W → ℝ := fun q => normalCost y (f q.1) q.2 + have hA := normalCost_log_contDiffAt he hep + have hB := normalCost_log_contDiffAt hf hfq + have hA2 := hA.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hB2 := hB.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have heq : A =ᶠ[𝓝 (0,0)] (fun q => B q.swap) := by + filter_upwards [continuousAt_fst.eventually hei,continuousAt_snd.eventually hfi] with q hqe hqf + change cost (riemannianExp x q.2) (riemannianExp x (e q.1))= + cost (riemannianExp y q.1) (riemannianExp y (f q.2)) + rw [hqe,hqf] + exact cost_symm _ _ + let S := (ContinuousLinearEquiv.prodComm ℝ W V).toContinuousLinearMap + have HS := second_fderiv_comp_affine (f := B) S 0 (0:W×V) + (by simpa [S,B,Prod.swap] using hB2) (d,0) (0,k) + have H : fderiv ℝ (fderiv ℝ A) (0,0) (d,0) (0,k)= + fderiv ℝ (fderiv ℝ B) (0,0) (0,d) (k,0) := by + rw [(heq.fderiv (𝕜 := ℝ)).fderiv_eq (𝕜 := ℝ)] + simp only [S,zero_add,map_zero,ContinuousLinearEquiv.coe_coe, + ContinuousLinearEquiv.prodComm_apply,Prod.swap_prod_mk,zero_add] at HS + simpa only [Prod.zero_eq_mk] using HS + have Hsym := (hB2.isSymmSndFDerivAt (by norm_num)).eq (0,d) (k,0) + rw [Hsym] at H + change fderiv ℝ (fderiv ℝ A) (0,0) (d,0) (0,k)= + fderiv ℝ (fderiv ℝ B) (0,0) (k,0) (0,d) at H + rw [normalCost_log_mixed he hep,normalCost_log_mixed hf hfq] at H + exact (neg_injective H).trans (real_inner_comm _ _) + +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_two_sided_fiber_log {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : + ∃ L : M → TangentSpace 𝓘(ℝ,Model n) x, + ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) ∞ L + (riemannianExp x p) ∧ + L (riemannianExp x p)=p ∧ + (∀ᶠ y in 𝓝 (riemannianExp x p), riemannianExp x (L y)=y) ∧ + (∀ᶠ v in 𝓝 p, L (riemannianExp x v)=v) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + let d := extChartAt 𝓘(ℝ,Model n) y + obtain ⟨e,he,hpe,hei⟩ := exists_coordinate_exp_inverse hp + have hep : e p=d y := by rw [he] + let L : M → V := fun z => e.symm (d z) + have hL : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ L y := + (show ContDiffAt ℝ ∞ e.symm (d y) from hep ▸ hei).contMDiffAt.comp y + (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y from contMDiffAt_extChartAt) + have hLy : L y=p := by dsimp [L]; rw [←hep,e.left_inv hpe] + refine ⟨L,hL,hLy,?_,?_⟩ + · have ht : ∀ᶠ z in 𝓝 y, d z∈e.target := + (continuousAt_extChartAt y).eventually (e.open_target.mem_nhds (hep ▸ e.map_source hpe)) + have hcont : ContinuousAt (fun z => riemannianExp x (L z)) y := + (continuous_riemannianExp x).continuousAt.comp hL.continuousAt + have hs : ∀ᶠ z in 𝓝 y, riemannianExp x (L z)∈d.source := by + have H := hcont.eventually (show d.source∈𝓝 (riemannianExp x (L y)) from by + rw [hLy]; exact extChartAt_source_mem_nhds y) + exact H + filter_upwards [ht,hs,extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) y] with z hzt hzs hsz + apply d.injOn hzs hsz + have HR := e.right_inv hzt + rw [he] at HR + exact HR + · filter_upwards [e.open_source.mem_nhds hpe] with v hv + change e.symm (d (riemannianExp x v))=v + rw [←show e v=d (riemannianExp x v) from congrFun he v] + exact e.left_inv hv + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLowerTaylorBound.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLowerTaylorBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..8813e0ef8d9f85c7db2ce97ffbf978f25e862811 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalLowerTaylorBound.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.UniformReverseGain +import OAI.Analysis.BiholderTransport.Contact.CenterSupport + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma reverse_normal_pairing {a b : M} + {p : TangentSpace 𝓘(ℝ,Model n) a} {q : TangentSpace 𝓘(ℝ,Model n) b} + (hp : p∈injectivityDomain a) (hq : q∈injectivityDomain b) + (hpq : riemannianExp a p=b) + {R : TangentSpace 𝓘(ℝ,Model n) b → TangentSpace 𝓘(ℝ,Model n) a} + (hR : DifferentiableAt ℝ R q) (hR0 : R q=0) + (hRe : ∀ᶠ w in 𝓝 q,riemannianExp a (R w)=riemannianExp b w) + (w : TangentSpace 𝓘(ℝ,Model n) b) : + inner ℝ p (fderiv ℝ R q w)=-inner ℝ q w := by + have heq : (fun v => normalCost a p (R v)) =ᶠ[𝓝 q] (fun v => ‖v‖^2/2) := by + filter_upwards [hRe,(isOpen_injectivityDomain b).mem_nhds hq] with v hv hvreg + dsimp only [normalCost] + rw [hv,hpq] + change dist (riemannianExp b v) b^2/2=‖v‖^2/2 + rw [dist_comm,injectivityDomain_subset_minimizingVectors b hvreg] + have hg : HasFDerivAt (normalCost a p) (innerSL ℝ (-p)) (R q) := by + rw [hR0]; exact normalCost_hasFDerivAt_zero hp + have hh : HasFDerivAt (fun v : TangentSpace 𝓘(ℝ,Model n) b => ‖v‖^2/2) + (innerSL ℝ q) q := by + convert! ((hasStrictFDerivAt_norm_sq q).hasFDerivAt.const_mul (1/2:ℝ)) using 1 + · ext v; ring + · ext v + simp only [smul_apply,smul_eq_mul] + ring + have H : (innerSL ℝ (-p)).comp (fderiv ℝ R q)=innerSL ℝ q := + ((hg.comp q hR.hasFDerivAt).congr_of_eventuallyEq heq.symm).unique hh + have HV := congrArg (fun A => A w) H + simp only [ContinuousLinearMap.comp_apply,innerSL_apply_apply,inner_neg_left] at HV + linarith only [HV] + +lemma exists_uniform_center_support_pullback : + ∃ c>0,∀ᶠ l : ℝ in 𝓝 1, l<1 → ∀ a b : M, + ∀ p : TangentSpace 𝓘(ℝ,Model n) a, + ∀ q : TangentSpace 𝓘(ℝ,Model n) b, + p∈minimizingVectors a → q∈injectivityDomain b → + riemannianExp a (l • p)=b → riemannianExp b q=a → + ∀ (φ : ℝ → ℝ) (v : ℝ), ContDiffAt ℝ 2 φ v → deriv φ v=l → + ∃ R : TangentSpace 𝓘(ℝ,Model n) b → TangentSpace 𝓘(ℝ,Model n) a, + ContDiffAt ℝ ∞ R q ∧ R q=0 ∧ + (∀ᶠ w in 𝓝 q,riemannianExp a (R w)=riemannianExp b w) ∧ + ∀ w : TangentSpace 𝓘(ℝ,Model n) b, + c*(1-l)*‖w‖^2+(iteratedDeriv 2 φ v/l^2)*(inner ℝ q w)^2 ≤ + fderiv ℝ (fderiv ℝ (fun h => + scalarCostSupport φ v a p ((1+l)/2) (riemannianExp a h))) 0 + (fderiv ℝ R q w) (fderiv ℝ R q w)+ + hessianValue a (l • p) (fderiv ℝ R q w) := by + obtain ⟨c,hc,H⟩ := exists_uniform_reverse_divided_gain (n := n) (M := M) + have hpair : Tendsto (fun l : ℝ => (l,(1+l)/2)) (𝓝 1) (𝓝 (1,1)) := by + have hc : ContinuousAt (fun l : ℝ => (l,(1+l)/2)) (1:ℝ) := + continuousAt_id.prodMk ((continuousAt_const.add continuousAt_id).div_const 2) + simpa using hc.tendsto + refine ⟨c/4,by positivity,?_⟩ + filter_upwards [hpair.eventually H,eventually_gt_nhds (by norm_num : (1/2:ℝ)<1)] with l hl hhalf + intro hl1 a b p q hp hq hpb hqa φ v hφ hφd + have hl0 : 0 ‖offset‖) =o[𝓝 0] (fun _ => (1:ℝ)) := + (Asymptotics.isLittleO_one_iff ℝ).mpr (by + simpa only [norm_zero] using continuous_norm.tendsto (0:E)) + have hSquare : (fun offset : E => ‖offset‖^2) =o[𝓝 0] + (fun offset : E => ‖offset‖) := by + simpa only [pow_two,one_mul] using + hNorm.mul_isBigO (Asymptotics.isBigO_refl (fun offset : E => ‖offset‖) (𝓝 0)) + have hBilinear : (fun offset : E => H offset offset) =o[𝓝 0] + (fun offset : E => ‖offset‖) := + (bilinear_isBigO_norm_mul (𝓝 (0:E)) H (fun offset => offset) + (fun offset => offset)).trans_isLittleO + (by simpa only [pow_two] using hSquare) + have hQuadratic : (fun offset : E => H offset offset/2) =o[𝓝 0] + (fun offset : E => ‖offset‖) := by + simpa only [div_eq_mul_inv,mul_comm] using hBilinear.const_mul_left (2:ℝ)⁻¹ + rw [hasFDerivAt_iff_isLittleO_nhds_zero] + simpa only [zero_add,sub_add_cancel] using + ((hf.trans_isBigO hSquare.isBigO).add hQuadratic).of_norm_right + +omit [FiniteDimensional ℝ E] in +lemma HasSecondTaylor.diagonal_unique' {f:E → ℝ} {l k:E →L[ℝ] ℝ} + {H K:E →L[ℝ] E →L[ℝ] ℝ} (hf:HasSecondTaylor f l H) (hg:HasSecondTaylor f k K) (d:E) : + H d d=K d d := by + have he:=hf.hasFDerivAt'.unique hg.hasFDerivAt' + subst k + exact hf.diagonal_unique hg d +end TaylorUniqueness +section NormalPoleTaylor +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFinitePole (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance tangentCompletePole (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +omit [Nonempty M] in +lemma normal_stationary_pole_taylor {f:M → ℝ} {x y:M} + {r:TangentSpace 𝓘(ℝ,Model n) y} {q:TangentSpace 𝓘(ℝ,Model n) x} + (hr:r∈injectivityDomain y) (hq:q∈injectivityDomain x) + (hyx:riemannianExp y r=x) + {S:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hS:HasQuadraticExpansion (fun h=>f (riemannianExp y h)) r S) + {R:TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hR:DifferentiableAt ℝ R q) (hR0:R q=0) + (hRe:∀ᶠ v in 𝓝 q,riemannianExp y (R v)=riemannianExp x v) : + HasSecondTaylor (fun h=>f (riemannianExp x (q+h))+‖q+h‖^2/2) 0 + (pullBilinear (((innerSL ℝ).comp S : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ)+normalHessian y r) (fderiv ℝ R q)) := by + let C:=normalCost y r + have hc:ContDiffAt ℝ 2 C 0:= + (normalCost_contDiffAt hr).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hct:HasSecondTaylor C (innerSL ℝ (-r)) (normalHessian y r):=by + simpa only [C,(normalCost_hasFDerivAt_zero hr).fderiv,normalHessian] using + hasSecondTaylor_of_contDiffAt hc + have H:HasSecondTaylor (fun h=>f (riemannianExp y h)+C h) 0 + (((innerSL ℝ).comp S : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ)+normalHessian y r):=by + simpa only [map_neg,add_neg_cancel] using hS.hasSecondTaylor'.add hct + have ha:HasFDerivAt (fun h=>R (q+h)) (fderiv ℝ R q) 0:=by + simpa only [Function.comp_def,add_zero,ContinuousLinearMap.comp_id] using + (show HasFDerivAt R (fderiv ℝ R q) (q+0) from by simpa only [add_zero] using hR.hasFDerivAt).comp 0 ((hasFDerivAt_id (0:TangentSpace 𝓘(ℝ,Model n) x)).const_add q) + have hs:=H.comp_stationary ha (by simpa only [add_zero] using hR0) + apply hs.congr_of_eventuallyEq + have ht:Tendsto (fun h:TangentSpace 𝓘(ℝ,Model n) x=>q+h) (𝓝 0) (𝓝 q):=by + have hc : ContinuousAt (fun h:TangentSpace 𝓘(ℝ,Model n) x=>q+h) 0 := continuousAt_const.add continuousAt_id + simpa only [add_zero] using hc.tendsto + filter_upwards [ht.eventually hRe,ht.eventually ((isOpen_injectivityDomain x).mem_nhds hq)] with h hh hhr + dsimp only [C,normalCost] + rw [hh,hyx] + congr 1 + change ‖q+h‖^2/2=dist (riemannianExp x (q+h)) x^2/2 + rw [dist_comm,injectivityDomain_subset_minimizingVectors x hhr] +end NormalPoleTaylor +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalRigidity.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalRigidity.lean new file mode 100644 index 0000000000000000000000000000000000000000..989e8cec3cbbda031cbce53fea274d11e3f8f8bb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalRigidity.lean @@ -0,0 +1,181 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.RadialCalibration +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateMetricNorm +import OAI.Analysis.BiholderTransport.Coordinates.TangentLift +import OAI.Analysis.BiholderTransport.CostGeometry.LinearRadialDerivative +import OAI.Analysis.BiholderTransport.CostGeometry.RadialVelocityMetricEqualities + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +lemma normal_chart_radial_rigidity + (e : OpenPartialHomeomorph E E) + (hed : ContDiffOn ℝ ∞ e e.source) (hei : ContDiffOn ℝ ∞ e.symm e.target) + (g₀ : E →L[ℝ] E →L[ℝ] ℝ) (hs₀ : ∀ u v, g₀ u v = g₀ v u) + (g : E → E →L[ℝ] E →L[ℝ] ℝ) (V : E → E) (τ k : ℝ) + (hp : ∀ v ∈ e.source, ∀ w : E, w ≠ 0 → 0 < g (e v) w w) + (hs : ∀ v ∈ e.source, ∀ u w, g (e v) u w = g (e v) w u) + (henergy : ∀ v ∈ e.source, g (e v) (V v) (V v) = g₀ v v) + (hgauss : ∀ v ∈ e.source, ∀ w, + g (e v) (V v) (fderiv ℝ e v w) = τ*g₀ v w) + (hradial : ∀ v ∈ e.source, fderiv ℝ e v v = τ • V v) + {f : ℝ → E} {l r a : ℝ} (hf : ContDiffOn ℝ ∞ f (Ioo l r)) + (ha : a ∈ Ioo l r) (himg : MapsTo f (Ioo l r) e.source) + (hspeed : ∀ s ∈ Ioo l r, + g (e (f s)) (deriv (e ∘ f) s) (deriv (e ∘ f) s) = k^2) + (hdist : ∀ s ∈ Ioo l r, τ^2*g₀ (f s) (f s) = (s-a)^2*k^2) : + ∀ s ∈ Ioo l r, f s = (s-a) • deriv f a := by + apply linear_of_radial_derivative hf ha + intro s hs' + have hfs := himg hs' + have hfD := (hf.contDiffAt (isOpen_Ioo.mem_nhds hs')).differentiableAt (by simp) + have heD := (hed.contDiffAt (e.open_source.mem_nhds hfs)).differentiableAt (by simp) + have hiD := (hei.contDiffAt (e.open_target.mem_nhds (e.map_source hfs))).differentiableAt (by simp) + have hqder : deriv (e ∘ f) s = fderiv ℝ e (f s) (deriv f s) := + (heD.hasFDerivAt.comp_hasDerivAt s hfD.hasDerivAt).deriv + have heq : (fun t => τ^2*g₀ (f t) (f t)) =ᶠ[𝓝 s] (fun t => (t-a)^2*k^2) := by + filter_upwards [isOpen_Ioo.mem_nhds hs'] with t ht + exact hdist t ht + have hpair := bilinear_metric_radial_derivative hs₀ hfD heq + have hvelocity : (s-a) • deriv (e ∘ f) s = τ • V (f s) := by + apply radial_velocity_of_metric_equalities (hp _ hfs) (hs _ hfs) (hspeed s hs') + · rw [henergy _ hfs]; exact hdist s hs' + · rw [hqder,hgauss _ hfs] + nlinarith [hpair] + have hL : (fderiv ℝ e.symm (e (f s))).comp (fderiv ℝ e (f s)) = + ContinuousLinearMap.id ℝ E := by + have H := fderiv_partial_homeomorph_right_inverse e.symm hfs + (by simpa only [OpenPartialHomeomorph.symm_symm] using hiD) heD + simpa only [OpenPartialHomeomorph.symm_symm,e.left_inv hfs] using H + have hinj : Function.Injective (fderiv ℝ e (f s)) := by + intro u v huv + have H := congrArg (fderiv ℝ e.symm (e (f s))) huv + simpa only [←ContinuousLinearMap.comp_apply,hL,ContinuousLinearMap.id_apply] using H + apply hinj + rw [map_smul,←hqder,hradial _ hfs] + exact hvelocity +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [FiniteDimensional ℝ E] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma coordinate_curve_speed_square {γ : ℝ → M} {t : ℝ} {a : M} + (hγ : MDifferentiableAt 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t) + (ha : γ t ∈ (extChartAt 𝓘(ℝ,E) a).source) : + riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a (γ t)) + (deriv (extChartAt 𝓘(ℝ,E) a ∘ γ) t) (deriv (extChartAt 𝓘(ℝ,E) a ∘ γ) t) = + ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)‖^2 := by + let c := extChartAt 𝓘(ℝ,E) a + let g := riemannianCoordinateMetric a (c (γ t)) + have hm := mfderiv_comp t (mdifferentiableAt_extChartAt + (I := 𝓘(ℝ,E)) (x := a) (by simpa only [extChartAt_source] using ha)) hγ + rw [mfderiv_eq_fderiv] at hm + have hval : deriv (c ∘ γ) t = mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c (γ t) + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) := + congrArg (fun L : ℝ →L[ℝ] E => L 1) hm + have hnorm := coordinate_metric_chart_derivative_norm ha + (g := g) (by + intro u v + change riemannianCoordinateMetric a (c (γ t)) u v = _ + rw [riemannianCoordinateMetric_apply,c.left_inv ha]) + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) + rw [←hval] at hnorm + calc + _ = (Real.sqrt (g (deriv (c ∘ γ) t) (deriv (c ∘ γ) t)))^2 := + (Real.sq_sqrt (positive_bilinear_nonneg g + (fun v hv => riemannianCoordinateMetric_positive (c.map_source ha) hv) _)).symm + _ = _ := congrArg (fun x : ℝ => x^2) hnorm + +omit [FiniteDimensional ℝ E] [IsRiemannianManifold 𝓘(ℝ,E) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma coordinate_curve_derivative_at_center {γ : ℝ → M} {t : ℝ} + (hγ : MDifferentiableAt 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t) : + deriv (extChartAt 𝓘(ℝ,E) (γ t) ∘ γ) t = + mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ) := by + have H := mfderiv_comp t (mdifferentiableAt_extChartAt + (I := 𝓘(ℝ,E)) (mem_chart_source E (γ t))) hγ + rw [mfderiv_eq_fderiv,mfderiv_extChartAt_self] at H + exact congrArg (fun L : ℝ →L[ℝ] E => L 1) H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalSubdifferential.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalSubdifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c5729cc17e1a271ea6ded17fa2de80e2fc2ac99 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalSubdifferential.lean @@ -0,0 +1,273 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport + +lemma hasFDerivAt_affine_lower_support {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} {D : E →L[ℝ] ℝ} (hD : HasFDerivAt f D 0) : + ∀ ε>0, ∀ᶠ h : E in 𝓝 0, D h-ε*‖h‖≤f h-f 0 := by + intro ε hε + have H := hD.isLittleO.bound hε + filter_upwards [H] with h hh + simp only [sub_zero,Real.norm_eq_abs] at hh + linarith [(abs_le.mp hh).1] + +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def normalSubdifferential (u : M → ℝ) (x : M) : Set (TangentSpace 𝓘(ℝ,Model n) x) := + {p | ∀ ε>0, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + inner ℝ p h-ε*‖h‖≤u (riemannianExp x h)-u x} + +lemma convex_normalSubdifferential (u : M → ℝ) (x : M) : + Convex ℝ (normalSubdifferential (n := n) u x) := by + intro p hp q hq a b ha hb hab ε hε + filter_upwards [hp ε hε,hq ε hε] with h hh hk + calc + inner ℝ (a • p+b • q) h-ε*‖h‖ = + a*(inner ℝ p h-ε*‖h‖)+b*(inner ℝ q h-ε*‖h‖) := by + simp only [inner_add_left,real_inner_smul_left,mul_sub] + have he := congrArg (fun r : ℝ => r*(ε*‖h‖)) hab + nlinarith [he] + _ ≤ a*(u (riemannianExp x h)-u x)+b*(u (riemannianExp x h)-u x) := + add_le_add (mul_le_mul_of_nonneg_left hh ha) (mul_le_mul_of_nonneg_left hk hb) + _ = u (riemannianExp x h)-u x := by rw [←add_mul,hab,one_mul] + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma activeLogs_subset_normalSubdifferential {v : M → ℝ} (hv : Continuous v) (x : M) : + activeLogs (n := n) v x ⊆ normalSubdifferential (cTransform v) x := by + intro p hp + have hID := contracted_minimizer_mem_injectivityDomain hp.1 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let f := fun h : TangentSpace 𝓘(ℝ,Model n) x => + (-2:ℝ)*(normalCost x ((1/2:ℝ) • p) h-normalCost x ((1/2:ℝ) • p) 0) + have hD : HasFDerivAt f (innerSL ℝ p) 0 := by + apply (((normalCost_hasFDerivAt_zero hID).sub_const + (normalCost x ((1/2:ℝ) • p) 0)).const_smul (-2:ℝ)).congr_fderiv + ext h + simp only [smul_apply,innerSL_apply_apply,inner_neg_left,real_inner_smul_left,smul_eq_mul] + ring + intro ε hε + filter_upwards [hasFDerivAt_affine_lower_support hD ε hε] with h hh + have hs := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (riemannianExp x h) + have hf0 : f 0=0 := by simp [f] + rw [hf0,sub_zero] at hh + simp only [innerSL_apply_apply] at hh + apply hh.trans + have he : f h = -(cost (riemannianExp x h) (riemannianExp x ((1/2:ℝ) • p)) - + cost x (riemannianExp x ((1/2:ℝ) • p))) / (1/2:ℝ) := by + dsimp [f,normalCost] + rw [riemannianExp_zero] + ring + rw [he] + exact hs + +lemma active_hull_subset_normalSubdifferential {v : M → ℝ} (hv : Continuous v) (x : M) : + convexHull ℝ (activeLogs (n := n) v x) ⊆ normalSubdifferential (cTransform v) x := + convexHull_min (activeLogs_subset_normalSubdifferential hv x) + (convex_normalSubdifferential (cTransform v) x) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalTestChart.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalTestChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..f1d5a86faa7e6d3e2ee24795190ef83ce7e5b1f2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/NormalTestChart.lean @@ -0,0 +1,189 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.NormLower +import OAI.Analysis.BiholderTransport.Volume.IntrinsicJacobian +import OAI.Analysis.BiholderTransport.Regularity.MixedIntrinsic + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section NormalTestChart +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance normalTestFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] in +lemma exists_chart_covector_for_log_fixed {a x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hp : p∈injectivityDomain x) : + let z := extChartAt 𝓘(ℝ,Model n) a x + ∃ L : Model n →L[ℝ] ℝ, + chartGradientVector a z L∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm z) ∧ + coordinateBackward a (-1,z,L)=riemannianExp x p ∧ + HasFDerivAt (chartCost a (riemannianExp x p)) (-L) z := by + let : Nonempty M := ⟨a⟩ + let z := extChartAt 𝓘(ℝ,Model n) a x + let A : TangentBundle 𝓘(ℝ,Model n) M := ⟨a,0⟩ + let P : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + let c := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) A + let L := riemannianCoordinateMetric a z (c P).2 + have hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source hx + have hPs : P∈c.source := (tangent_chart_source_iff A P).mpr hx + have he : (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z L⟩ : + TangentBundle 𝓘(ℝ,Model n) M)=P := by + rw [chartGradientVector_total_eq (q := (z,L)) hz] + have hinv : (riemannianCoordinateMetric a z).inverse L=(c P).2 := + (riemannianCoordinateMetric_isInvertible hz).inverse_apply_self _ + rw [hinv] + exact c.left_inv hPs + have hreg : chartGradientVector a z L∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z) := by + have H : P∈{Q : TangentBundle 𝓘(ℝ,Model n) M | Q.2∈injectivityDomain Q.1} := hp + rwa [←he] at H + have hex : coordinateBackward a (-1,z,L)=riemannianExp x p := by + rw [coordinateBackward_eq_exp_chartGradient hz] + exact congrArg (fun Q : TangentBundle 𝓘(ℝ,Model n) M => riemannianExp Q.1 Q.2) he + refine ⟨L,hreg,hex,?_⟩ + rw [←hex] + exact chartCost_gradient_at_contact hz hreg + +omit [Nonempty M] in +lemma normal_test_to_chart {a x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + (hx:x∈(extChartAt 𝓘(ℝ,Model n) a).source) (hp:p∈injectivityDomain x) + {u:M → ℝ} {φ:TangentSpace 𝓘(ℝ,Model n) x → ℝ} + (hφ:ContDiffAt ℝ 2 φ 0) (hφD:fderiv ℝ φ 0=innerSL ℝ p) + (hval:u x=φ 0) (hlo:∀ᶠ w in 𝓝 0,φ w≤u (riemannianExp x w)) + (hpos:∃m>0,∀d,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) 0 d d+hessianValue x p d) : + let z:=extChartAt 𝓘(ℝ,Model n) a x + ∃ψ:Model n → ℝ,∃R:Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x, + ContDiffAt ℝ 2 ψ z ∧ + chartGradientVector a z (fderiv ℝ ψ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z) ∧ + coordinateBackward a (-1,z,fderiv ℝ ψ z)=riemannianExp x p ∧ + u ((extChartAt 𝓘(ℝ,Model n) a).symm z)=ψ z ∧ + (∀ᶠ w in 𝓝 z,ψ w≤u ((extChartAt 𝓘(ℝ,Model n) a).symm w)) ∧ + (∃k>0,∀d:Model n,k*‖d‖^2≤fderiv ℝ (fderiv ℝ ψ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (riemannianExp x p))) z d d) ∧ + chartJacobian (n:=n) a x*R.toLinearMap.normDet=1 ∧ + bilinearOperator (fderiv ℝ (fderiv ℝ ψ) z+ + fderiv ℝ (fderiv ℝ (chartCost a (riemannianExp x p))) z)= + R.adjoint.comp ((bilinearOperator + (fderiv ℝ (fderiv ℝ φ) 0+normalHessian x p)).comp R) := by + let z:=extChartAt 𝓘(ℝ,Model n) a x + let E:=TangentSpace 𝓘(ℝ,Model n) x + let c:=normalCost x p + obtain ⟨m,hm,hpos⟩:=hpos + obtain ⟨L,hLreg,hLb,hLD⟩:=exists_chart_covector_for_log_fixed hx hp + obtain ⟨e,he,he0,hei,hi⟩:=exists_smooth_chart_fiber_log (a:=a) + (zero_mem_injectivityDomain (n:=n) x) (by simpa only [riemannianExp_zero] using hx) + simp only [riemannianExp_zero] at he he0 hei hi + change ContDiffAt ℝ ∞ e z at he + change e z=0 at he0 + change Function.Injective (fderiv ℝ e z) at hi + have he2:ContDiffAt ℝ 2 e z:=he.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + obtain ⟨k,hk,Hk⟩:=exists_norm_sq_lower_of_injective (fderiv ℝ e z) hi + let ψ:Model n → ℝ:=fun w=>φ (e w) + let R:=fderiv ℝ e z + have hψ:ContDiffAt ℝ 2 ψ z:=(he0.symm ▸ hφ).comp z he2 + have hc:ContDiffAt ℝ 2 c 0:= + (normalCost_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hce:chartCost a (riemannianExp x p)=ᶠ[𝓝 z] (fun w=>c (e w)):=by + filter_upwards [hei] with w hw + simp only [c,normalCost,chartCost,hw] + have hcc:ContDiffAt ℝ 2 (chartCost a (riemannianExp x p)) z:= + ((he0.symm ▸ hc).comp z he2).congr_of_eventuallyEq hce + have hψD:fderiv ℝ ψ z=L:=by + have Hc:=hce.fderiv_eq (𝕜:=ℝ) + rw [hLD.fderiv,fderiv_fun_comp z + (by simpa only [he0] using hc.differentiableAt (by norm_num)) + (he2.differentiableAt (by norm_num)),he0,(normalCost_hasFDerivAt_zero hp).fderiv] at Hc + rw [show ψ=(fun w=>φ (e w)) from rfl,fderiv_fun_comp z + (by simpa only [he0] using hφ.differentiableAt (by norm_num)) + (he2.differentiableAt (by norm_num)),he0,hφD] + apply ContinuousLinearMap.ext + intro d + have HH:=congrArg (fun A:Model n →L[ℝ] ℝ=>A d) Hc + simpa only [neg_apply,ContinuousLinearMap.comp_apply, + innerSL_apply_apply,inner_neg_left,neg_inj] using HH.symm + have hψlo:∀ᶠ w in 𝓝 z,ψ w≤u ((extChartAt 𝓘(ℝ,Model n) a).symm w):=by + have HH:=he.continuousAt.eventually + (show ∀ᶠ v in 𝓝 (e z),φ v≤u (riemannianExp x v) by rwa [he0]) + filter_upwards [HH,hei] with w hw hwi + simpa only [ψ,hwi] using hw + have Hpull (d v:Model n): fderiv ℝ (fderiv ℝ ψ) z d v+ + fderiv ℝ (fderiv ℝ (chartCost a (riemannianExp x p))) z d v= + fderiv ℝ (fderiv ℝ φ) 0 (R d) (R v)+normalHessian x p (R d) (R v):=by + have hzF:fderiv ℝ (fun v=>φ v+c v) 0=0:=by + rw [fderiv_fun_add (hφ.differentiableAt (by norm_num)) (hc.differentiableAt (by norm_num)), + hφD,(normalCost_hasFDerivAt_zero hp).fderiv] + simp only [map_neg,add_neg_cancel] + have HF:=second_fderiv_comp_stationary (f:=fun v=>φ v+c v) (g:=e) + (he0.symm ▸ hφ.add hc) he2 (by rwa [he0]) d v + rw [he0,second_fderiv_add_eq hφ hc] at HF + have Heq:(fun w=>ψ w+chartCost a (riemannianExp x p) w)=ᶠ[𝓝 z] + (fun w=>φ (e w)+c (e w)):=by + filter_upwards [hce] with w hw + rw [hw] + have HH:=congrArg (fun A:Model n →L[ℝ] Model n →L[ℝ] ℝ=>A d v) Heq.fderiv.fderiv_eq + rw [second_fderiv_add_eq hψ hcc] at HH + exact HH.trans HF + have hRp: (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n:=n) x) 0).comp R= + ContinuousLinearMap.id ℝ (Model n):=by + let f: E → Model n := (extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n:=n) x + have hf:ContDiffAt ℝ ∞ f 0:=chart_normal_smooth (by simpa only [riemannianExp_zero] using hx) + have hid:(fun w=>f (e w))=ᶠ[𝓝 z] (fun w=>w):=by + filter_upwards [hei,(isOpen_extChartAt_target a).mem_nhds + ((extChartAt 𝓘(ℝ,Model n) a).map_source hx)] with w hw ht + simp only [f,Function.comp_apply,hw,(extChartAt 𝓘(ℝ,Model n) a).right_inv ht] + have HD:=hid.fderiv_eq (𝕜:=ℝ) + rw [fderiv_fun_comp z (by simpa only [he0] using hf.differentiableAt (by simp)) + (he.differentiableAt (by simp)),he0,fderiv_fun_id] at HD + exact HD + have hRdet:chartJacobian (n:=n) a x*R.toLinearMap.normDet=1:=by + have hh:=congrArg (fun F:Model n →L[ℝ] Model n=>F.toLinearMap.normDet) hRp + rw [show (ContinuousLinearMap.id ℝ (Model n)).toLinearMap=LinearMap.id by rfl, + LinearMap.normDet_id] at hh + change ((fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n:=n) x) 0).toLinearMap ∘ₗ + R.toLinearMap).normDet=1 at hh + erw [LinearMap.normDet_comp_of_finrank_eq R.toLinearMap + (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n:=n) x) 0).toLinearMap rfl] at hh + rwa [normDet_chart_exp_zero a x hx] at hh + refine ⟨ψ,R,hψ,?_,?_,?_,hψlo,?_,hRdet,?_⟩ + · rwa [hψD] + · rwa [hψD] + · change u ((extChartAt 𝓘(ℝ,Model n) a).symm z)=φ (e z) + rw [he0] + exact ((congrArg u ((extChartAt 𝓘(ℝ,Model n) a).left_inv hx)).trans hval) + · refine ⟨m*k,mul_pos hm hk,fun d=>?_⟩ + rw [Hpull] + simp only [hessianValue_eq_normalHessian hp] at hpos + calc + _ = m*(k*‖d‖^2):=by ring + _ ≤ m*‖R d‖^2:=mul_le_mul_of_nonneg_left (Hk d) hm.le + _ ≤ _:=hpos (R d) + · apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro v + simp only [bilinearOperator_inner,add_apply, + ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] + exact Hpull d v + +end NormalTestChart +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/OuterCoordinate.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/OuterCoordinate.lean new file mode 100644 index 0000000000000000000000000000000000000000..a4f31ebd7896820efb6d73f6b7fc7f1ea7e87ced --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/OuterCoordinate.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters +import OAI.Analysis.BiholderTransport.Coordinates.LocalOuterLog + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OuterCoordinate +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_outer_coordinate_jet_bound (hmtw:WeakMTW (n := n) (M := M)) + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {a:M} + {p:Model n} (hmin:p∈minimizingVectors a) + (hnc:Function.Injective (fderiv ℝ (fun v=>extChartAt 𝓘(ℝ,Model n) + (riemannianExp a p) (riemannianExp a v)) p)) + {l:ℝ} (hl:1 < l) : + ∃U:Set ((Model n×Model n)×ℝ),U∈𝓝 ((extChartAt 𝓘(ℝ,Model n) a a,(p:Model n)),l) ∧ ∃C≥0, + ∀q∈U,∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀φ:ℝ → ℝ,StrictMono φ → ContDiffAt ℝ 2 φ (uv.2 (movingNormal a q.1)) → + HasDerivAt φ q.2 (uv.2 (movingNormal a q.1)) → + iteratedDeriv 2 φ (uv.2 (movingNormal a q.1)) ≤ 0 → + ∀B:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀d,0 ≤ B d d) → + HasLowerSecondTaylor (fun d=>φ (uv.2 (movingNormal a (q.1.1,q.1.2+d)))+ + ‖chartFiberInverse a q.1.1 (q.1.2+d)‖^2/2) 0 B → + ∀d,B d d ≤ C*‖d‖^2 := by + let z:TangentBundle 𝓘(ℝ,Model n) M:=⟨a,p⟩ + have H:=hmtw.exists_local_outer_log_jet_bound hlam hcap z hmin hnc hl + dsimp only at H + have hz:extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z z= + (extChartAt 𝓘(ℝ,Model n) a a,(p:Model n)) := tangent_chart_at_self_base z p + rw [hz] at H + obtain ⟨U,hU,C,hC,HC⟩:=H + let V:=U∩(fun q:(Model n×Model n)×ℝ=>q.1.1) ⁻¹' (extChartAt 𝓘(ℝ,Model n) a).target + have hV:V∈𝓝 ((extChartAt 𝓘(ℝ,Model n) a a,(p:Model n)),l) := + inter_mem hU ((continuous_fst.comp continuous_fst).continuousAt.preimage_mem_nhds + ((isOpen_extChartAt_target a).mem_nhds (mem_extChartAt_target a))) + refine ⟨V,hV,C,hC,?_⟩ + intro q hq x0 uv huv φ hmono hφ hd hconc B hB hjet d + have hqt:q.1.1∈(extChartAt 𝓘(ℝ,Model n) a).target := hq.2 + apply HC q hq.1 x0 uv huv φ hmono + · exact hφ + · exact hd + · exact hconc + · exact hB + · convert hjet using 1 + funext δ + have he:=tangent_chart_symm_trivialization (q := (q.1.1,q.1.2+δ)) hqt + change (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z).symm (q.1.1,q.1.2+δ)=_ at he + rw [he] + simp only [movingNormal_eq hqt] +end OuterCoordinate +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/PoleCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/PoleCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9923a52a0bff09591038da0aaf3bc804d365e26 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/PoleCoordinates.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.HopfGradient + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma hopfLax_lipschitz {u : M → ℝ} (hu : Continuous u) {D : ℝ≥0} + (hD : ∀ x y : M, dist x y≤D) {t : ℝ} (ht : 0 t*u x) (continuous_const.mul hu) hD).dist_le_mul x y + rw [Real.dist_eq] at H + calc + _ ≤ (D:ℝ)*dist x y/t := div_le_div_of_nonneg_right H ht.le + _ = _ := by rw [NNReal.coe_div,Real.coe_toNNReal _ ht.le]; ring + +def coordinateBackward (a : M) (q : ℝ × Model n × (Model n →L[ℝ] ℝ)) : M := + movingNormal a (q.2.1,-q.1 • (riemannianCoordinateMetric a q.2.1).inverse q.2.2) + +omit [Nonempty M] in +lemma coordinateBackward_contMDiffAt {a : M} {q : ℝ × Model n × (Model n →L[ℝ] ℝ)} + (hq : q.2.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContMDiffAt 𝓘(ℝ,ℝ × Model n × (Model n →L[ℝ] ℝ)) 𝓘(ℝ,Model n) ∞ + (coordinateBackward a) q := by + have hg := (contDiffOn_riemannianCoordinateMetric (E := Model n) a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds hq) + have hi := (riemannianCoordinateMetric_isInvertible hq).contDiffAt_map_inverse.comp q.2.1 hg + have hz : ContDiffAt ℝ ∞ (fun q : ℝ × Model n × (Model n →L[ℝ] ℝ) => q.2.1) q := + contDiffAt_fst.comp q contDiffAt_snd + have hl : ContDiffAt ℝ ∞ (fun q : ℝ × Model n × (Model n →L[ℝ] ℝ) => q.2.2) q := + contDiffAt_snd.comp q contDiffAt_snd + have hv := (contDiffAt_fst.neg.smul ((hi.comp q hz).clm_apply hl)) + exact (movingNormal_contMDiffAt hq).comp q (hz.prodMk hv).contMDiffAt + +omit [Nonempty M] in +lemma coordinateBackward_of_derivative {a : M} (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z.1∈(extChartAt 𝓘(ℝ,Model n) a).source) {f : M → ℝ} + (hf : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f z.1 (innerSL ℝ z.2)) (t : ℝ) : + coordinateBackward a (t,extChartAt 𝓘(ℝ,Model n) a z.1, + fderiv ℝ (fun w => f ((extChartAt 𝓘(ℝ,Model n) a).symm w)) + (extChartAt 𝓘(ℝ,Model n) a z.1)) = (sprayFlow (-t) z).1 := by + have hd := coordinate_gradient_of_hasMFDerivAt z hz f 1 (by simpa using hf) + simp only [one_smul] at hd + rw [coordinateBackward,hd.fderiv] + have hT := (extChartAt 𝓘(ℝ,Model n) a).map_source hz + have hi := riemannianCoordinateMetric_isInvertible hT + rw [hi.inverse_apply_self] + rw [movingNormal_eq hT, (extChartAt 𝓘(ℝ,Model n) a).left_inv hz,map_smul] + have hbase : z.1∈(chartAt (Model n) a).source := by simpa only [extChartAt_source] using hz + have hcoord : (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) z).2 = + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ z.1 z.2 := by + rw [TangentBundle.continuousLinearMapAt_trivializationAt_eq_core hbase] + rfl + rw [hcoord] + change riemannianExp z.1 ((-t) • + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ z.1 + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ z.1 z.2))) = _ + rw [Trivialization.symmL_continuousLinearMapAt _ hbase,riemannianExp_smul] + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma hasMFDerivAt_riemannianGradient {f : M → ℝ} {x : M} + (hd : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x) : + HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x + (innerSL ℝ (riemannianGradient (n := n) f x)) := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + apply hd.hasMFDerivAt.congr_mfderiv + exact ((InnerProductSpace.toDual ℝ (TangentSpace 𝓘(ℝ,Model n) x)).apply_symm_apply _).symm + +def hopfPole (t : ℝ) (u : M → ℝ) (z : M) : M := + (sprayFlow (-t) (⟨z,riemannianGradient (n := n) (hopfLax t u) z⟩ : + TangentBundle 𝓘(ℝ,Model n) M)).1 + +lemma WeakMTW.coordinateBackward_eq_pole (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 hopfLax t u ((extChartAt 𝓘(ℝ,Model n) a).symm w)) z) = + hopfPole (n := n) t u ((extChartAt 𝓘(ℝ,Model n) a).symm z) := by + have H := coordinateBackward_of_derivative + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z, + riemannianGradient (n := n) (hopfLax t u) ((extChartAt 𝓘(ℝ,Model n) a).symm z)⟩ : + TangentBundle 𝓘(ℝ,Model n) M) + ((extChartAt 𝓘(ℝ,Model n) a).map_target hz) + (hasMFDerivAt_riemannianGradient (hmtw.mdifferentiable_hopfLax hu hv hdual ht ht1 _)) t + simpa only [hopfPole, (extChartAt 𝓘(ℝ,Model n) a).right_inv hz] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Prefix.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Prefix.lean new file mode 100644 index 0000000000000000000000000000000000000000..fa32e2ed980f45adc506ae3b484bc3e717501594 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Prefix.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitPairing +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingSplit + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +section Prefix +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def prefixNormalCost (x : M) (t : ℝ) + (q : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost (riemannianExp x q.1) (riemannianExp x (t • q.2))/t + +lemma prefixNormalCost_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) : + ContDiffAt ℝ ∞ (prefixNormalCost x t) (0,p) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have he := contMDiff_riemannianExp_fiber (n := n) x + have hu : ContMDiffAt 𝓘(ℝ,V×V) 𝓘(ℝ,Model n) ∞ + (fun q : V×V => riemannianExp x q.1) (0,p) := + (he _).comp (0,p) contDiffAt_fst.contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,V×V) 𝓘(ℝ,Model n) ∞ + (fun q : V×V => riemannianExp x (t • q.2)) (0,p) := + (he _).comp (0,p) (show ContDiffAt ℝ ∞ (fun q : V×V => t • q.2) (0,p) from by fun_prop).contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨x,t • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hleft + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0:V),riemannianExp x (t • p)) := by + simpa only [riemannianExp_zero] using hc + exact ((hc'.comp (0,p) (hu.prodMk hv)).contDiffAt.div_const t) + +lemma prefixNormalCost_zero {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 < t) (hp : t • p ∈ injectivityDomain x) : + prefixNormalCost x t (0,p) = t/2*‖p‖^2 := by + have H := injectivityDomain_subset_minimizingVectors x hp + change dist x (riemannianExp x (t • p)) = ‖t • p‖ at H + simp only [prefixNormalCost,riemannianExp_zero,cost,H,norm_smul_of_nonneg ht.le] + field_simp + +lemma prefixNormalCost_source_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t ≠ 0) (hp : t • p ∈ injectivityDomain x) + (u : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (prefixNormalCost x t) (0,p) (u,0) = -inner ℝ p u := by + have hB := (prefixNormalCost_contDiffAt hp).differentiableAt (by simp) + have hnc := ((normalCost_contDiffAt hp).differentiableAt (by simp)).hasFDerivAt + have H := hnc.mul_const t⁻¹ + have H' : HasFDerivAt (fun a => prefixNormalCost x t (a,p)) + (t⁻¹ • fderiv ℝ (normalCost x (t • p)) 0) 0 := by + simpa only [prefixNormalCost,normalCost,div_eq_mul_inv] using H + have hpair := (hasFDerivAt_id (𝕜 := ℝ) (0 : TangentSpace 𝓘(ℝ,Model n) x)).prodMk + (hasFDerivAt_const p (0 : TangentSpace 𝓘(ℝ,Model n) x)) + have heq := (hB.hasFDerivAt.comp (f := fun a => (a,p)) 0 hpair).unique H' + have hh := congrArg (fun A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => A u) heq + change fderiv ℝ (prefixNormalCost x t) (0,p) (u,0) = + t⁻¹ * fderiv ℝ (normalCost x (t • p)) 0 u at hh + rw [normalCost_fderiv_zero hp,real_inner_smul_left] at hh + rw [hh] + field_simp + +lemma prefixNormalCost_target_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 < t) (hp : t • p ∈ injectivityDomain x) + (u : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (prefixNormalCost x t) (0,p) (0,u) = t*inner ℝ p u := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hB := (prefixNormalCost_contDiffAt hp).differentiableAt (by simp) + have hnear : ∀ᶠ q : V in 𝓝 p, t • q ∈ injectivityDomain x := + (show ContinuousAt (fun q : V => t • q) p from by fun_prop).preimage_mem_nhds + (isOpen_injectivityDomain x |>.mem_nhds hp) + have heq : (fun q : V => prefixNormalCost x t (0,q)) =ᶠ[𝓝 p] + (fun q : V => t/2*‖q‖^2) := hnear.mono (fun _ h => prefixNormalCost_zero ht h) + have H := ((hasFDerivAt_id (𝕜 := ℝ) p).norm_sq).const_mul (t/2) + have Hd : HasFDerivAt (fun q : V => prefixNormalCost x t (0,q)) + ((t/2) • (2 • innerSL ℝ p)) p := by + exact H.congr_of_eventuallyEq heq + have hpair := (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hh := congrArg (fun A : V →L[ℝ] ℝ => A u) + ((hB.hasFDerivAt.comp (f := fun q : V => ((0:V),q)) p hpair).unique Hd) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply,zero_apply, + smul_apply,innerSL_apply_apply] at hh + convert! hh using 1 + simp only [smul_eq_mul] + ring + +lemma prefixNormalCost_hessian_blocks {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 < t) (hp : t • p ∈ injectivityDomain x) + (u v : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixNormalCost x t)) (0,p) (u,0) (0,v) = -inner ℝ u v ∧ + fderiv ℝ (fderiv ℝ (prefixNormalCost x t)) (0,p) (0,u) (0,v) = t*inner ℝ u v := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hB₂ := (prefixNormalCost_contDiffAt hp).of_le (m := 2) + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hnear : ∀ᶠ q : V in 𝓝 p, t • q ∈ injectivityDomain x := + (show ContinuousAt (fun q : V => t • q) p from by fun_prop).preimage_mem_nhds + (isOpen_injectivityDomain x |>.mem_nhds hp) + constructor + · have heq : (fun q : V => fderiv ℝ (prefixNormalCost x t) (0,q) (u,0)) =ᶠ[𝓝 p] + (fun q : V => -inner ℝ u q) := by + filter_upwards [hnear] with q hq + rw [prefixNormalCost_source_gradient ht.ne' hq,real_inner_comm] + have H := pair_hessian_snd_from_gradient hB₂ (u,0) heq + (((innerSL ℝ u).hasFDerivAt (x := p)).neg) v + rw [(hB₂.isSymmSndFDerivAt (by simp)).eq] at H + exact H + · have heq : (fun q : V => fderiv ℝ (prefixNormalCost x t) (0,q) (0,v)) =ᶠ[𝓝 p] + (fun q : V => t*inner ℝ v q) := by + filter_upwards [hnear] with q hq + rw [prefixNormalCost_target_gradient ht hq,real_inner_comm] + have H := pair_hessian_snd_from_gradient hB₂ (0,v) heq + (((innerSL ℝ v).hasFDerivAt (x := p)).const_mul t) u + simpa only [smul_apply,innerSL_apply_apply,real_inner_comm v u,smul_eq_mul] using H + +end Prefix +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ProperPieces.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ProperPieces.lean new file mode 100644 index 0000000000000000000000000000000000000000..a9ab4e0d23836a01bc9f7344268dec686a2ae9ce --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ProperPieces.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.Reversal + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ProperPieces +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + +lemma tangentScale_mul (a b : ℝ) (z : TangentBundle 𝓘(ℝ,Model n) M) : + tangentScale a (tangentScale b z)=tangentScale (a*b) z := by + rcases z with ⟨x,v⟩ + change (⟨x,a • b • v⟩ : TangentBundle 𝓘(ℝ,Model n) M)=⟨x,(a*b) • v⟩ + exact congrArg (fun w => (⟨x,w⟩ : TangentBundle 𝓘(ℝ,Model n) M)) (smul_smul a b v) + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +lemma reverseRay_segment (z : TangentBundle 𝓘(ℝ,Model n) M) (h T : ℝ) (hT : T≠0) : + reverseRay (tangentScale (T-h) (sprayFlow h z))= + tangentScale ((T-h)/T) (reverseRay (tangentScale T z)) := by + unfold reverseRay + rw [sprayFlow_scale,mul_one,←sprayFlow_add,sub_add_cancel, + sprayFlow_scale,mul_one] + rw [tangentScale_mul,tangentScale_mul,tangentScale_mul] + congr 1 + field_simp + +variable [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma proper_suffix_in_injectivityDomain {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈minimizingVectors z.1) {h T : ℝ} (hh : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma normal_log_fderiv_exp_norm {x y : M} + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hq : DifferentiableAt ℝ q 0) + (hqr : ∀ᶠ a in 𝓝 0, riemannianExp y (q a)=riemannianExp x a) + (v : TangentSpace 𝓘(ℝ,Model n) x) : + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) y) 𝓘(ℝ,Model n) + (riemannianExp y) (q 0) (fderiv ℝ q 0 v)‖=‖v‖ := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + have he := (contMDiff_riemannianExp_fiber y (q 0)).mdifferentiableAt (by simp) + have hD := (he.hasMFDerivAt.comp 0 hq.hasFDerivAt.hasMFDerivAt) + have hqr' : (riemannianExp y ∘ q) =ᶠ[𝓝 0] riemannianExp x := hqr + have hD' := hD.congr_of_eventuallyEq hqr'.symm + have hE := hD'.mfderiv + have hN := mfderiv_exp_zero_norm x v + rw [hE] at hN + have he0 := hqr.self_of_nhds + convert! hN using 1 + congr 1 + rw [he0] + +lemma normalHessian_radial_derivative_factor {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : + ∃ L : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) (reverseRay (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + Function.Injective L ∧ + (∀ v, ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) (reverseRay (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + 𝓘(ℝ,Model n) (riemannianExp (reverseRay (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (reverseRay (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 (L v)‖=‖v‖) ∧ ∀ v, + HasDerivAt (fun s : ℝ => normalHessian x (s • p) v v) + (normalHessian x p v v-‖L v‖^2) 1 := by + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + let y := (reverseRay z).1 + let r := (reverseRay z).2 + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + have hr : r∈injectivityDomain y := reverseRay_injectivityDomain hp + have he : riemannianExp y r=x := reverseRay_endpoint z + obtain ⟨q,hq0,hq,hqr,hqeq⟩ := exists_normal_eikonal_log hr he + let L := fderiv ℝ q 0 + refine ⟨L,normal_log_fderiv_injective (hq.differentiableAt (by simp)) hqr,?_,?_⟩ + · intro v + have H := normal_log_fderiv_exp_norm (hq.differentiableAt (by simp)) hqr v + rw [hq0] at H + exact H + intro v + let B := doubleNormalCost (n := n) x y + have hB : ContDiffAt ℝ 3 B (0,0) := (doubleNormalCost_contDiffAt hr he).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 3) + have hq2 : ContDiffAt ℝ 2 q 0 := hq.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have heik : (fun a : X => B (a,0))=ᶠ[𝓝 0] fun a => ‖-q a‖^2/2 := by + filter_upwards [hqeq] with a ha + simpa only [norm_neg] using ha.1 + have hgrad : ∀ᶠ a : X in 𝓝 0, ∀ w : Y, + fderiv ℝ B (a,0) (0,w)=inner ℝ (-q a) w := by + have hBa : ∀ᶠ a : X in 𝓝 0, ContDiffAt ℝ 3 B (a,0) := + (continuousAt_id.prodMk continuousAt_const).eventually (hB.eventually (by norm_num)) + filter_upwards [hqeq,hBa] with a ha hBa + intro w + have hd := (hBa.differentiableAt (by norm_num)).hasFDerivAt.comp 0 + ((hasFDerivAt_const a (0:Y)).prodMk (hasFDerivAt_id 0)) + have hv := congrArg (fun D : Y →L[ℝ] ℝ => D w) hd.fderiv + change fderiv ℝ (fun b => doubleNormalCost x y (a,b)) 0 w= + fderiv ℝ B (a,0) (0,w) at hv + rw [ha.2] at hv + exact hv.symm + have heik3 := eikonal_third_derivative hB hq2.neg heik hgrad (v := v) + have hS := second_derivative_source_slice (hB.of_le (by norm_num)) v v + have hBzero : (fun a : X => B (a,0))=normalCost x p := by + funext a + simp only [B,doubleNormalCost,normalCost,riemannianExp_zero] + rw [riemannianExp_eq_sprayFlow x p] + rfl + rw [hBzero] at hS + change normalHessian x p v v=_ at hS + have hneg : fderiv ℝ (fun a : X => -q a) 0 = -L := by + exact fderiv_fun_neg + rw [hq0,hneg] at heik3 + change fderiv ℝ (fderiv ℝ B) (0,0) (v,0) (v,0)= + ‖-(L v)‖^2+fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (0,0) (0,-r) (v,0) (v,0) at heik3 + rw [norm_neg,←hS] at heik3 + have hline := hasDerivAt_source_hessian_line (a := (0:X)) (b := (0:Y)) + (w := -r) (t := 1) (v := v) hB + have hf : (fun s : ℝ => fderiv ℝ (fderiv ℝ + (fun a : X => B (a,(0:Y)+(s-1) • (-r)))) 0 v v)= + (fun s : ℝ => normalHessian x (s • p) v v) := by + funext s + congr 3 + funext a + dsimp [B,doubleNormalCost,normalCost] + have hs : (0:Y)+(s-1) • (-r)=(1-s) • r := by + simp only [zero_add,smul_neg,←neg_smul] + congr 1 + ring + rw [hs,exp_reverseRay_line z s] + rfl + rw [hf] at hline + convert hline using 1 + linarith + +end RadialFactor +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/RadialIdentity.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/RadialIdentity.lean new file mode 100644 index 0000000000000000000000000000000000000000..549919f1d2e5036bdced796f138a49eb4fa3c888 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/RadialIdentity.lean @@ -0,0 +1,236 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.CostGradient +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSmooth + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def normalCost (x : M) (p u : TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost (riemannianExp x u) (riemannianExp x p) + +lemma normalCost_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : ContDiffAt ℝ ∞ (normalCost x p) 0 := by + have hc := cost_contMDiffAt_of_injectivityDomain (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0 : TangentSpace 𝓘(ℝ,Model n) x),riemannianExp x p) := by + simpa only [riemannianExp_zero] using hc + exact (hc'.comp 0 ((contMDiff_riemannianExp_fiber x 0).prodMk contMDiffAt_const)).contDiffAt + +lemma shifted_exp_endpoint (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) (t : ℝ) : + riemannianExp (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + ((1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2) = riemannianExp x p := by + rw [riemannianExp_eq_sprayFlow] + change (sprayFlow 1 (tangentScale (1-t) (sprayFlow t ⟨x,p⟩))).1 = _ + rw [sprayFlow_scale,mul_one,←sprayFlow_add,sub_add_cancel] + exact (riemannianExp_eq_sprayFlow x p).symm + +lemma shifted_injectivityDomain_near_zero {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : ∀ᶠ t : ℝ in 𝓝 0, + (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + let Z : ℝ → TangentBundle 𝓘(ℝ,Model n) M := fun t => tangentScale (1-t) (sprayFlow t ⟨x,p⟩) + have hZ : ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Z := + contMDiff_tangentScale.comp ((contMDiff_const.sub contMDiff_id).prodMk + (contMDiff_sprayFlow.comp (contMDiff_id.prodMk contMDiff_const))) + have hZ0 : Z 0=⟨x,p⟩ := by + dsimp [Z] + rw [sprayFlow_zero] + simp [tangentScale] + have hh : Z 0 ∈ {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ injectivityDomain z.1} := by + rw [hZ0]; exact hp + exact hZ.continuous.continuousAt.preimage_mem_nhds (isOpen_total_injectivityDomain.mem_nhds hh) + +lemma normalCost_radial_fderiv_of_shift {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (xi : TangentSpace 𝓘(ℝ,Model n) x) {t : ℝ} (ht : t ≠ 0) (ht1 : t ≠ 1) + (hp : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (hf : DifferentiableAt ℝ (normalCost x p) (t • p)) : + fderiv ℝ (normalCost x p) (t • p) xi = (t-1)*inner ℝ p xi := by + have hD := cost_start_gradient_of_injectivityDomain hp + rw [shifted_exp_endpoint] at hD + have hD' : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) + (fun b => dist b (riemannianExp x p)^2/2) + (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + (innerSL ℝ ((-(1-t)) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2)) := by + simpa only [cost,neg_smul] using hD + have he : 1-t ≠ 0 := sub_ne_zero.mpr ht1.symm + have H := spray_action_line_stationary x p xi t (1-t) he (riemannianExp x p) hD' + have hv : HasDerivAt (fun s : ℝ => t • (p+s • xi)) (t • xi) 0 := by + convert! (((hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const xi)).const_smul t) using 1 + simp + have hf' : HasFDerivAt (normalCost x p) (fderiv ℝ (normalCost x p) (t • p)) (t • (p+(0:ℝ) • xi)) := by + simpa only [zero_smul,add_zero] using hf.hasFDerivAt + have hfc := hf'.comp_hasDerivAt 0 hv + have hn : HasDerivAt (fun s : ℝ => t*‖p+s • xi‖^2/2) (t*inner ℝ p xi) 0 := by + convert! (((hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const xi)).norm_sq.const_mul t).div_const 2 using 1 + simp + ring + have HH := hn.add (hfc.div_const (1-t)) + have hh : (t*inner ℝ p xi)+fderiv ℝ (normalCost x p) (t • p) (t • xi)/(1-t)=0 := by + apply HH.unique + convert! H using 1 + funext s + simp only [normalCost,cost,riemannianExp_smul,Function.comp_def] + rfl + rw [map_smul,smul_eq_mul] at hh + field_simp at hh + have hh' : t * (fderiv ℝ (normalCost x p) (t • p) xi - (t-1)*inner ℝ p xi)=0 := by nlinarith + exact sub_eq_zero.mp ((mul_eq_zero.mp hh').resolve_left ht) + +lemma normalCost_radial_fderiv_near_zero {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + (fun t : ℝ => fderiv ℝ (normalCost x p) (t • p) xi) =ᶠ[𝓝 0] + (fun t : ℝ => (t-1)*inner ℝ p xi) := by + have hf := normalCost_contDiffAt hp + have hline : ContDiffAt ℝ ∞ (fun t : ℝ => t • p) 0 := contDiffAt_id.smul contDiffAt_const + have hline0 : (0:ℝ) • p=0 := zero_smul ℝ p + have hfnear : ∀ᶠ t : ℝ in 𝓝 0, DifferentiableAt ℝ (normalCost x p) (t • p) := by + have hh : ∀ᶠ u in 𝓝 (0 : TangentSpace 𝓘(ℝ,Model n) x), ContDiffAt ℝ 1 (normalCost x p) u := + (hf.of_le (m := 1) (by simp)).eventually (by norm_num) + have ht : Tendsto (fun t : ℝ => t • p) (𝓝 0) (𝓝 0) := by + simpa only [ContinuousAt,hline0] using hline.continuousAt + exact (ht.eventually hh).mono (fun _ h => h.differentiableAt (by norm_num)) + have hnear : ∀ᶠ t : ℝ in 𝓝 0, t≠0 → + fderiv ℝ (normalCost x p) (t • p) xi=(t-1)*inner ℝ p xi := by + filter_upwards [shifted_injectivityDomain_near_zero hp,hfnear, + eventually_ne_nhds (show (0:ℝ)≠1 by norm_num)] with t ht hft ht1 + exact fun htn => normalCost_radial_fderiv_of_shift xi htn ht1 ht hft + have hleft : ContinuousAt (fun t : ℝ => fderiv ℝ (normalCost x p) (t • p) xi) 0 := by + have hdf := (hf.fderiv_right (m := ∞) (by simp)).continuousAt + have hdf' : ContinuousAt (fderiv ℝ (normalCost x p)) ((0:ℝ) • p) := by rwa [hline0] + exact (ContinuousAt.comp (f := fun t : ℝ => t • p) hdf' hline.continuousAt).clm_apply continuousAt_const + have hright : ContinuousAt (fun t : ℝ => (t-1)*inner ℝ p xi) 0 := by fun_prop + have heqpunct : (fun t : ℝ => fderiv ℝ (normalCost x p) (t • p) xi) =ᶠ[𝓝[≠] 0] + (fun t : ℝ => (t-1)*inner ℝ p xi) := by + filter_upwards [hnear.filter_mono nhdsWithin_le_nhds,self_mem_nhdsWithin] with t ht htn + exact ht htn + have heq0 := tendsto_nhds_unique_of_eventuallyEq + (hleft.mono_left nhdsWithin_le_nhds) (hright.mono_left nhdsWithin_le_nhds) heqpunct + filter_upwards [hnear] with t ht + by_cases ht0 : t=0 + · simpa only [ht0] using heq0 + · exact ht ht0 + +lemma normalCost_radial_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (normalCost x p)) 0 p xi = inner ℝ p xi := by + have hf := (normalCost_contDiffAt hp).of_le (m := 2) + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hd0 : HasDerivAt (fun t : ℝ => fderiv ℝ (normalCost x p) (t • p) xi) + (fderiv ℝ (fderiv ℝ (normalCost x p)) 0 p xi) 0 := by + simpa only [zero_add] using directional_fderiv_hasDerivAt hf p xi + have heq := normalCost_radial_fderiv_near_zero hp xi + have hright : HasDerivAt (fun t : ℝ => (t-1)*inner ℝ p xi) (inner ℝ p xi) 0 := by + convert! ((hasDerivAt_id (0:ℝ)).sub_const 1).mul_const (inner ℝ p xi) using 1; simp only [one_mul] + exact hd0.unique (hright.congr_of_eventuallyEq heq) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/RayBenchmark.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/RayBenchmark.lean new file mode 100644 index 0000000000000000000000000000000000000000..75bc8cec43421a242010f3f54580ce9bdea9a2ea --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/RayBenchmark.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.SectionDiameter +import OAI.Analysis.BiholderTransport.Regularity.ModifiedData +import OAI.Analysis.BiholderTransport.Regularity.RayAnchor + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section RayBenchmark +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.section_initial_logs (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {x : M} {p q : TangentSpace 𝓘(ℝ,Model n) x} {r a D : ℝ} + (hr : 0≤r) (hrD : r≤D/5) + (hp : p∈liftedGapSection u v x r) (hq : q∈liftedGapSection u v x r) + (ha : v (riemannianExp x p)=a) (ha1 : v (riemannianExp x q)=a+D) + (hosc : sectionOscillation u v x r≤D) : + |‖p‖^2-‖q‖^2-2*D|≤2*r ∧ ‖p-q‖^2≤8*(D+r) ∧ + ‖p‖^2-inner ℝ p q≤6*D ∧ D≤‖p‖^2 := by + have hdiam := (hmtw.liftedGapSection_diameter_sq hu hv hdual hr hp hq).trans + (mul_le_mul_of_nonneg_left (show r + sectionOscillation u v x r ≤ D + r by linarith only [hosc]) (by norm_num : (0:ℝ)≤8)) + have hp0 := dualPair_gap_nonneg hv hdual x (riemannianExp x p) + have hq0 := dualPair_gap_nonneg hv hdual x (riemannianExp x q) + have hp1 := (mem_liftedGapSection_iff.mp hp).2 + have hq1 := (mem_liftedGapSection_iff.mp hq).2 + change contactGap u v x (riemannianExp x p)≤r at hp1 + change contactGap u v x (riemannianExp x q)≤r at hq1 + rw [contactGap,cost_minimizingVector hp.1,ha] at hp0 hp1 + rw [contactGap,cost_minimizingVector hq.1,ha1] at hq0 hq1 + have hid := norm_sub_sq_real p q + refine ⟨abs_le.mpr ⟨by linarith only [hp0,hq1],by linarith only [hp1,hq0]⟩,?_,?_,?_⟩ + · linarith only [hdiam] + · nlinarith only [hid,hdiam,hp1,hq0,hrD] + · nlinarith only [hp0,hq1,hrD,hr,sq_nonneg ‖q‖] + +lemma ray_benchmark {v : M → ℝ} (hv : Continuous v) {x : M} + {p q : TangentSpace 𝓘(ℝ,Model n) x} {a D r C d t : ℝ} + (hp : p∈minimizingVectors x) (hq : q∈minimizingVectors x) + (ha : v (riemannianExp x p)=a) + (hgap : contactGap (cTransform v) v x (riemannianExp x q)≤r) + (hangle : ‖p‖^2-inner ℝ p q≤6*D) (ht : 0≤t) (hsmall : ‖t • p‖ TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteReverseGain (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma exists_reverse_exp_rescaled_fixedJoin_factor {x y : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} {q : TangentSpace 𝓘(ℝ,Model n) y} + (hh : 0 inverse_of_bilinear_pairing hDS v + have hBu : ∀ v:V, B (U v)=v := fun v => inverse_of_bilinear_pairing hBU v + have hBs : B.toLinearMap.IsSymmetric := fixedJoinOperator_symmetric + ((fixedJoinAction_regular_contDiffAt hpt hh hht).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + have hUn : ∀ v:V, 0 ≤ inner ℝ (U v) v := + fixedJoinOperator_inverse_nonneg hpt hh hht hBu + have hfac : ∀ v:V, D v=fderiv ℝ R q (C v) := fun v => + congrArg (fun A : V →L[ℝ] V => A v) hfactor + have hCs : Function.Surjective C := factor_surjective_of_right_inverse + (show finrank ℝ V=finrank ℝ W from rfl) hDs hfac + have hCn : ‖C‖≤a := by + dsimp only [C] + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hs,LinearIsometryEquiv.norm_map] + exact hbound + have hC : ∀ v:V, ‖C v‖≤a*‖v‖ := fun v => + (C.le_opNorm v).trans (mul_le_mul_of_nonneg_right hCn (norm_nonneg v)) + have hcross' : ∀ v:V, c*‖v‖^2≤ inner ℝ ((D-B) v) v := by + intro v + simpa only [sub_apply,inner_sub_left,D,B,fixedJoinOperator_inner] + using hcross v + refine ⟨R,hR,hRq,hRi,?_⟩ + intro w + have H := inverse_difference_isotropic_of_factor ha hc hBs hBu + (left_inverse_of_right_inverse hDs) hUn hcross' hfac hCs hC w + rw [inner_sub_left] at H + linarith only [H,hAs (fderiv ℝ R q w),hAt (fderiv ℝ R q w)] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ScalarExpansion.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ScalarExpansion.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ed9c1c028e0c0ad6ea4f49f75d77c6335264447 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ScalarExpansion.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient +import OAI.Analysis.BiholderTransport.Calculus.FullSet +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder + +namespace OAI + +noncomputable section +open Set Filter Asymptotics +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +omit [CompleteSpace E] in +lemma quadratic_expansion_polynomial_remainder {f:E → ℝ} {p:E} {A:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) : + (fun h=>f h-quadraticTaylor (f 0) p A h)=o[𝓝 0] (fun h:E=>‖h‖^2) := by + apply IsLittleO.of_bound + intro ε hε + obtain ⟨r,hr,H⟩:=hf ε hε + filter_upwards [Metric.ball_mem_nhds (0:E) hr] with h hh + simpa only [Real.norm_eq_abs,abs_of_nonneg (sq_nonneg ‖h‖)] using + H h (by simpa only [Metric.mem_ball,dist_zero_right] using hh) + +omit [CompleteSpace E] in +lemma HasSecondTaylor.of_littleO_difference {f g:E → ℝ} + {l:E →L[ℝ] ℝ} {B:E →L[ℝ] E →L[ℝ] ℝ} + (hg:HasSecondTaylor g l B) (h0:f 0=g 0) + (hfg:(fun h=>f h-g h)=o[𝓝 0] (fun h:E=>‖h‖^2)) : HasSecondTaylor f l B := by + unfold HasSecondTaylor at hg ⊢ + convert! hfg.add hg using 1 + funext h + rw [h0] + ring + +omit [CompleteSpace E] in +lemma quadratic_expansion_scalar_proxy {f:E → ℝ} {p:E} {A:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) {φ:ℝ → ℝ} (hφ:ContDiffAt ℝ 2 φ (f 0)) : + let P:=quadraticTaylor (f 0) p A + HasSecondTaylor (fun h=>φ (f h)) (fderiv ℝ (fun h=>φ (P h)) 0) + (fderiv ℝ (fderiv ℝ (fun h=>φ (P h))) 0) := by + let P:=quadraticTaylor (f 0) p A + have hP:ContDiff ℝ 2 P := by + dsimp only [P,quadraticTaylor] + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + have hp0:P 0=f 0 := by simp only [P,quadraticTaylor,map_zero,inner_zero_right,zero_div,add_zero] + have hQ:ContDiffAt ℝ 2 (fun h=>φ (P h)) 0 := (hp0.symm ▸ hφ).comp 0 hP.contDiffAt + apply (hasSecondTaylor_of_contDiffAt hQ).of_littleO_difference + · simp only [hp0] + · obtain ⟨K,s,hs,hK⟩:=(hφ.of_le (by norm_num : (1:WithTop ℕ∞)≤2)).exists_lipschitzOnWith + have hpc:Tendsto P (𝓝 0) (𝓝 (f 0)) := hp0 ▸ hP.continuous.continuousAt.tendsto + have hrem:Tendsto (fun vector => f vector-P vector) (𝓝 0) (𝓝 0) := + (quadratic_expansion_polynomial_remainder hf).trans_tendsto (by + simpa using (continuous_norm.tendsto (0:E)).pow 2) + have hfc:ContinuousAt f 0 := by + change Tendsto f (𝓝 0) (𝓝 (f 0)) + simpa only [sub_add_cancel,zero_add] using hrem.add hpc + have H:(fun h=>φ (f h)-φ (P h))=O[𝓝 0] (fun h=>f h-P h) := by + apply IsBigO.of_bound (K:ℝ) + filter_upwards [hfc hs,hpc hs] with h hf hs + simpa only [dist_eq_norm] using hK.dist_le_mul (f h) hf (P h) hs + exact H.trans_isLittleO (quadratic_expansion_polynomial_remainder hf) + +lemma quadratic_expansion_scalar_exists [FiniteDimensional ℝ E] {f:E → ℝ} {p:E} {A:E →L[ℝ] E} + (hf:HasQuadraticExpansion f p A) {φ:ℝ → ℝ} (hφ:ContDiffAt ℝ 2 φ (f 0)) : + ∃q:E,∃B:E →L[ℝ] E,(∀d e,inner ℝ (B d) e=inner ℝ d (B e)) ∧ + HasQuadraticExpansion (fun h=>φ (f h)) q B := by + let P:=quadraticTaylor (f 0) p A + have hP:ContDiff ℝ 2 P := by + dsimp only [P,quadraticTaylor] + exact (contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2) + have hp0:P 0=f 0 := by simp only [P,quadraticTaylor,map_zero,inner_zero_right,zero_div,add_zero] + have hQ:ContDiffAt ℝ 2 (fun h=>φ (P h)) 0 := (hp0.symm ▸ hφ).comp 0 hP.contDiffAt + have H:=quadratic_expansion_scalar_proxy hf hφ + refine ⟨(InnerProductSpace.toDual ℝ E).symm (fderiv ℝ (fun h=>φ (P h)) 0), + bilinearOperator (fderiv ℝ (fderiv ℝ (fun h=>φ (P h))) 0),?_,?_⟩ + · intro first second + rw [bilinearOperator_inner] + calc + _ = fderiv ℝ (fderiv ℝ (fun h=>φ (P h))) 0 second first := + (hQ.isSymmSndFDerivAt (by norm_num)).eq first second + _ = _ := by rw [real_inner_comm,bilinearOperator_inner] + · intro epsilon hepsilon + obtain ⟨radius,hradius,hball⟩ := Metric.eventually_nhds_iff.mp (H.eventually hepsilon) + refine ⟨radius,hradius,?_⟩ + intro vector hvector + have hbound := hball (by simpa only [Metric.mem_ball,dist_zero_right] using hvector) + simpa only [P,quadraticTaylor,bilinearOperator_inner,InnerProductSpace.toDual_symm_apply, + sub_add_eq_sub_sub] using hbound +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/ShortLocalMinimum.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/ShortLocalMinimum.lean new file mode 100644 index 0000000000000000000000000000000000000000..571fdcbed5a43ca984c75cc21be2e3dd331b4822 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/ShortLocalMinimum.lean @@ -0,0 +1,37 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.CostSmooth +import OAI.Analysis.BiholderTransport.Coordinates.ChartCostJets + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma chartCost_pair_contDiffAt_diagonal {a : M} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContDiffAt ℝ ∞ (fun q : Model n×Model n => + chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm q.1) q.2) (x,x) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + have hi : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ χ.symm x := + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds hx) + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨χ.symm x,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + (zero_mem_injectivityDomain (n := n) (χ.symm x)) + simp only [riemannianExp_zero] at hc + exact (hc.comp (x,x) ((hi.comp (x,x) contDiffAt_snd.contMDiffAt).prodMk + (hi.comp (x,x) contDiffAt_fst.contMDiffAt))).contDiffAt +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/SmoothUpperTest.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/SmoothUpperTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..f0b9bba428ef3800a93cd729eadbe267c05fb951 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/SmoothUpperTest.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.Measurable +import OAI.Analysis.BiholderTransport.CostGeometry.UpperTest +import OAI.Analysis.BiholderTransport.Convexity.CoordinateSemiconvex + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport + +lemma HasQuadraticExpansion.smooth_upper_test + {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {f : E → ℝ} {p : E} {A : E →L[ℝ] E} (h : HasQuadraticExpansion f p A) : + ∃ P : E → ℝ, ContDiff ℝ ∞ P ∧ P 0=f 0 ∧ ∀ᶠ z in 𝓝 0, f z≤P z := by + let P := fun z => quadraticTaylor (f 0) p A z+‖z‖^2 + have hP : ContDiff ℝ ∞ P := by + dsimp [P,quadraticTaylor] + exact ((contDiff_const.add (contDiff_const.inner ℝ contDiff_id)).add + ((A.contDiff.inner ℝ contDiff_id).div_const 2)).add (contDiff_norm_sq ℝ) + refine ⟨P,hP,by simp [P,quadraticTaylor],?_⟩ + obtain ⟨r,hr,hR⟩ := h 1 zero_lt_one + filter_upwards [Metric.ball_mem_nhds (0:E) hr] with z hz + have H := (abs_le.mp (hR z (by simpa using hz))).2 + dsimp [P] + linarith + +section AEUpperTest +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma cTransform_ae_normal_smooth_upper_test {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ w ∂metricVolume (M := M) n, + ∃ φ : TangentSpace 𝓘(ℝ,Model n) w → ℝ, ContDiffAt ℝ 2 φ 0 ∧ + φ 0=cTransform v w ∧ + ∀ᶠ h in 𝓝 0, cTransform v (riemannianExp w h)≤φ h := by + suffices HH : ∀ x∈(univ : Set M), ∃ U : Set M, IsOpen U ∧ x∈U ∧ + (∀ᵐ w ∂metricVolume (M := M) n, w∈U → + ∃ φ : TangentSpace 𝓘(ℝ,Model n) w → ℝ, ContDiffAt ℝ 2 φ 0 ∧ + φ 0=cTransform v w ∧ + ∀ᶠ h in 𝓝 0, cTransform v (riemannianExp w h)≤φ h) by + simpa only [mem_univ,true_implies] using ae_of_locally_ae (metricVolume (M := M) n) HH + intro x _ + obtain ⟨C,r,hr,htarget,hLip⟩ := exists_lipschitz_inverse_chart (n := n) x + let d := extChartAt 𝓘(ℝ,Model n) x + let ψ := fun z : Model n => d.symm (d x+z) + have hψ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ ψ 0 := by + apply (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d.symm (d x+0) from by + simpa only [add_zero] using (contMDiffOn_extChartAt_symm x).contMDiffAt + ((isOpen_extChartAt_target x).mem_nhds (mem_extChartAt_target x))).comp + exact (contDiff_const.add contDiff_id).contDiffAt.contMDiffAt + obtain ⟨R,hR,K,hK,hconv⟩ := cTransform_uniform_smooth_coordinate_semiconvex hψ + let B := ball (0:Model n) (min R r) + let U := d.source ∩ (fun w => d w-d x) ⁻¹' B + have hU : IsOpen U := ((continuousOn_extChartAt x).sub continuousOn_const).isOpen_inter_preimage + (isOpen_extChartAt_source x) isOpen_ball + refine ⟨U,hU,⟨mem_extChartAt_source x,by simpa [B] using And.intro hR hr⟩,?_⟩ + have hBtarget : ∀ z∈B, d x+z∈d.target := by + intro z hz + apply htarget + change d x+z∈ball (d x) r + simpa only [mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using + Metric.ball_subset_ball (min_le_right R r) hz + have hB' : ∀ z∈B, d x+z∈ball (d x) r := by + intro z hz + simpa only [mem_ball,dist_eq_norm,add_sub_cancel_left,sub_zero] using + Metric.ball_subset_ball (min_le_right R r) hz + have hψLip : LipschitzOnWith C ψ B := by + intro a ha b hb + simpa only [ψ,edist_dist,dist_eq_norm,add_sub_add_left_eq_sub] using + hLip (hB' a ha) (hB' b hb) + let μ : Measure (Model n) := Measure.hausdorffMeasure (n:ℝ) + have hdim : Module.finrank ℝ (Model n)=n := by simp [Model] + have : μ.IsAddHaarMeasure := by + dsimp only [μ] + rw [←hdim] + infer_instance + have hc : ConvexOn ℝ B (fun z => cTransform v (ψ z)+(2*K)/2*‖z‖^2) := by + simpa only [mul_div_cancel_left₀ K (show (2:ℝ)≠0 by norm_num)] using + (hconv v hv).subset (Metric.ball_subset_ball (min_le_left R r)) (convex_ball _ _) + have hAlex := ConvexProximal.ae_quadraticExpansion_semiconvex_open (2*K) isOpen_ball hc μ + let N := {z : Model n | z∈B ∧ ¬∃ p : Model n, ∃ A : Model n →L[ℝ] Model n, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (ψ (z+h))) p A} + have hN : μ N=0 := by + apply measure_mono_null _ (ae_iff.mp hAlex) + intro z hz + exact fun hh => hz.2 (hh hz.1) + have hImage : (Measure.hausdorffMeasure (n:ℝ) : Measure M) (ψ '' N)=0 := by + apply le_antisymm _ (show (0:ℝ≥0∞)≤_ from zero_le) + have hNsub : N⊆B := fun _ h => h.1 + have H := (hψLip.mono hNsub).hausdorffMeasure_image_le + (d := (n:ℝ)) (by positivity) + change _≤(C : ℝ≥0∞)^(n:ℝ)*μ N at H + simpa only [hN,mul_zero] using H + have hImageVol : metricVolume (M := M) n (ψ '' N)=0 := by + simp only [metricVolume,Measure.smul_apply,smul_eq_mul,hImage,mul_zero] + have hOutside : ∀ᵐ w ∂metricVolume (M := M) n, w∉ψ '' N := ae_iff.mpr (by simpa only [not_not,Set.ofPred_mem_eq] using hImageVol) + filter_upwards [hOutside] with w hw hwU + let z := d w-d x + have hzB : z∈B := hwU.2 + have hψz : ψ z=w := by simp only [ψ,z,add_sub_cancel,d.left_inv hwU.1] + have hzN : z∉N := fun h => hw ⟨z,h,hψz⟩ + have hzQ : ∃ p : Model n, ∃ A : Model n →L[ℝ] Model n, + (∀ h k, inner ℝ (A h) k=inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => cTransform v (ψ (z+h))) p A := by + by_contra hh + exact hzN ⟨hzB,hh⟩ + obtain ⟨p,A,_,hQ⟩ := hzQ + obtain ⟨P,hP,hP0,hPup⟩ := hQ.smooth_upper_test + let η := fun h : TangentSpace 𝓘(ℝ,Model n) w => d (riemannianExp w h)-d w + have hη0 : η 0=0 := by simp [η,riemannianExp_zero] + have hη : ContDiffAt ℝ ∞ η 0 := by + have hc : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d w := + contMDiffAt_extChartAt' (by simpa only [d,extChartAt_source] using hwU.1) + have hd := (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp w 0) from by + simpa only [riemannianExp_zero] using hc).comp 0 (contMDiff_riemannianExp_fiber w 0) + exact hd.contDiffAt.sub contDiffAt_const + refine ⟨P ∘ η,?_,?_,?_⟩ + · exact ((hP.contDiffAt.comp 0 hη).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + · simpa only [Function.comp_apply,hη0,add_zero,hψz] using hP0 + · have hsource : d.source∈𝓝 w := (isOpen_extChartAt_source x).mem_nhds hwU.1 + have hsource' : d.source∈𝓝 (riemannianExp (n := n) w 0) := by + simpa only [riemannianExp_zero] using hsource + have hnear := (contMDiff_riemannianExp_fiber (n := n) w).continuous.continuousAt.preimage_mem_nhds hsource' + have hPnear : ∀ᶠ h in 𝓝 0, cTransform v (ψ (z+η h))≤P (η h) := + (show Tendsto η (𝓝 0) (𝓝 0) by simpa only [ContinuousAt,hη0] using hη.continuousAt).eventually hPup + filter_upwards [hnear,hPnear] with h hh hPh + have he : ψ (z+η h)=riemannianExp w h := by + dsimp [ψ,z,η] + rw [show d x+(d w-d x+(d (riemannianExp w h)-d w))=d (riemannianExp w h) by abel] + exact d.left_inv hh + simpa only [Function.comp_apply,he] using hPh + +lemma cTransform_ae_active_before_cut {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ x ∂metricVolume (M := M) n, ∀ p∈activeLogs (n := n) v x, + p∈injectivityDomain x := by + filter_upwards [cTransform_ae_mdifferentiableAt hv,cTransform_ae_normal_smooth_upper_test hv] + with x hx htest + obtain ⟨φ,hφ,hφ0,hup⟩ := htest + exact fun p hp => active_before_cut_of_differentiable_upper_test hv hx hφ hφ0 hup hp + +end AEUpperTest +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitAction.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f05e7cd2188336c659ebcb49faa0e588f0ee39f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitAction.lean @@ -0,0 +1,221 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.RadialIdentity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma shifted_injectivityDomain_near_one (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + ∀ᶠ t : ℝ in 𝓝 1, + (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + let Z : ℝ → TangentBundle 𝓘(ℝ,Model n) M := fun t => tangentScale (1-t) (sprayFlow t ⟨x,p⟩) + have hZ : ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Z := + contMDiff_tangentScale.comp ((contMDiff_const.sub contMDiff_id).prodMk + (contMDiff_sprayFlow.comp (contMDiff_id.prodMk contMDiff_const))) + have hh : Z 1 ∈ {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ injectivityDomain z.1} := by + change (1-(1:ℝ)) • (sprayFlow 1 (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ injectivityDomain (sprayFlow 1 (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + rw [sub_self,zero_smul] + exact zero_mem_injectivityDomain _ + exact hZ.continuous.continuousAt.preimage_mem_nhds (isOpen_total_injectivityDomain.mem_nhds hh) + +lemma exists_minimizing_two_regular_legs {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) : ∃ t : ℝ, 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma normalCost_le_splitNormalAction (x : M) (p u v : TangentSpace 𝓘(ℝ,Model n) x) + {t : ℝ} (ht : 0 simp only [normalCost,splitNormalAction,cost,div_div,mul_comm] + +lemma splitNormalAction_contact {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) {t : ℝ} (ht : 0 + splitNormalAction x t z.1 z.2) (p,(0,p)) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let a : V × (V×V) := (p,(0,p)) + have he := contMDiff_riemannianExp_fiber (n := n) x + have hu : ContMDiffAt 𝓘(ℝ,V×(V×V)) 𝓘(ℝ,Model n) ∞ + (fun z : V×(V×V) => riemannianExp x z.2.1) a := + (he _).comp a (contDiffAt_fst.comp a contDiffAt_snd).contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,V×(V×V)) 𝓘(ℝ,Model n) ∞ + (fun z : V×(V×V) => riemannianExp x (t • z.2.2)) a := + (he _).comp a (show ContDiffAt ℝ ∞ (fun z : V×(V×V) => t • z.2.2) a from by fun_prop).contMDiffAt + have hw : ContMDiffAt 𝓘(ℝ,V×(V×V)) 𝓘(ℝ,Model n) ∞ + (fun z : V×(V×V) => riemannianExp x z.1) a := + (he _).comp a contDiffAt_fst.contMDiffAt + have hc₁ := cost_contMDiffAt_of_injectivityDomain + (⟨x,t • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hleft + have hc₂ := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + have hc₁' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0:V),riemannianExp x (t • p)) := by + simpa only [riemannianExp_zero] using hc₁ + have hc₂' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (t • p),riemannianExp x p) := by + dsimp only at hc₂ + rw [shifted_exp_endpoint] at hc₂ + simpa only [riemannianExp_smul] using hc₂ + exact ((hc₁'.comp a (hu.prodMk hv)).contDiffAt.div_const t).add + ((hc₂'.comp a (hv.prodMk hw)).contDiffAt.div_const (1-t)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitLogInjective.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitLogInjective.lean new file mode 100644 index 0000000000000000000000000000000000000000..01064d00489e84ea5f96fc104e058ec379d12716 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitLogInjective.lean @@ -0,0 +1,185 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.KernelRadial +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SplitLogInjective +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma prefix_log_fderiv_injective {x y : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} (ht : t≠0) + (hleft : t • p∈injectivityDomain x) + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hq : DifferentiableAt ℝ q p) + (hqr : ∀ᶠ a in 𝓝 p, riemannianExp y (q a)=riemannianExp x (t • a)) : + Function.Injective (fderiv ℝ q p) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + apply (injective_iff_map_eq_zero (fderiv ℝ q p)).mpr + intro v hv + have he := (contMDiff_riemannianExp_fiber y (q p)).mdifferentiableAt (by simp) + have hD := he.hasMFDerivAt.comp p hq.hasFDerivAt.hasMFDerivAt + have hqr' : (riemannianExp y ∘ q) =ᶠ[𝓝 p] (fun a : X => riemannianExp x (t • a)) := hqr + have hD' := hD.congr_of_eventuallyEq hqr'.symm + have hE := hD'.mfderiv + have hV : mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (fun a : X => riemannianExp x (t • a)) p v=0 := by + rw [hE] + change mfderiv 𝓘(ℝ,Y) 𝓘(ℝ,Model n) (riemannianExp y) (q p) (fderiv ℝ q p v)=0 + rw [hv] + exact map_zero _ + have hscale : HasFDerivAt (fun a : X => t • a) (t • ContinuousLinearMap.id ℝ X) p := + (t • ContinuousLinearMap.id ℝ X).hasFDerivAt + have hExp := ((contMDiff_riemannianExp_fiber x (t • p)).mdifferentiableAt + (by simp)).hasMFDerivAt.comp p hscale.hasMFDerivAt + have hEV := congrArg (fun L : X →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp x (t • p)) => L v) hExp.mfderiv + have hW : mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp x) (t • p) (t • v)=0 := + hEV.symm.trans hV + rw [exp_mfderiv_apply_eq_coordinate] at hW + have htv : t • v=0 := (riemannianExp_interior_nonconjugate hleft) + (hW.trans (map_zero _).symm) + exact (smul_eq_zero.mp htv).resolve_left ht + +end SplitLogInjective +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExpCoordinates +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinateEndpoint (c : TangentBundle 𝓘(ℝ,Model n) M) (q : Model n×Model n) : Model n := + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2) + (riemannianExp (χ.symm q).1 (χ.symm q).2) + +def coordinateEndpointVertical (c z : TangentBundle 𝓘(ℝ,Model n) M) : Model n →L[ℝ] Model n := + (fderiv ℝ (coordinateEndpoint c) + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c z)).comp (inr ℝ (Model n) (Model n)) + +lemma coordinateEndpoint_contDiffAt (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) + (hy : riemannianExp z.1 z.2∈(extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2)).source) : + ContDiffAt ℝ ∞ (coordinateEndpoint c) + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c z) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2) + have hχ : ContMDiffAt 𝓘(ℝ,Model n×Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ χ.symm (χ z) := + (contMDiffOn_extChartAt_symm c).contMDiffAt ((isOpen_extChartAt_target c).mem_nhds (χ.map_source hz)) + have hE := contMDiff_riemannianExp.contMDiffAt.comp (χ z) hχ + have hd : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp z.1 z.2) := + (contMDiffOn_extChartAt (n := ∞) (x := riemannianExp c.1 c.2)).contMDiffAt + (by simpa only [extChartAt_source] using (isOpen_extChartAt_source _).mem_nhds hy) + have hd' : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d + (riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2) := by rwa [χ.left_inv hz] + exact (hd'.comp (χ z) hE).contDiffAt + +omit [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma tangent_chart_fiber_inverse (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) : + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let τ := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let L := τ.continuousLinearEquivAt ℝ z.1 (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz) + ∀ w, χ.symm ((χ z).1,w)=(⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + intro χ τ L w + have hf : χ (⟨z.1,L.symm w⟩ : TangentBundle 𝓘(ℝ,Model n) M)=((χ z).1,w) := by + apply Prod.ext + · rfl + · change L (L.symm w)=w + exact L.apply_symm_apply w + rw [←hf] + exact χ.left_inv ((tangent_chart_source_iff c _).mpr (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz)) + +lemma coordinateEndpointVertical_apply (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) + (hy : riemannianExp z.1 z.2∈(extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2)).source) + (v : TangentSpace 𝓘(ℝ,Model n) z.1) : + coordinateEndpointVertical c z + ((trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1).continuousLinearMapAt ℝ z.1 v)= + (trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) + (riemannianExp c.1 c.2)).continuousLinearMapAt ℝ (riemannianExp z.1 z.2) + (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) z.1) 𝓘(ℝ,Model n) (riemannianExp z.1) z.2 v) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp c.1 c.2) + let X := TangentSpace 𝓘(ℝ,Model n) z.1 + let τ := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let L := τ.continuousLinearEquivAt ℝ z.1 (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz) + let F : X → Model n := fun a => d (riemannianExp z.1 a) + have hd : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d (riemannianExp z.1 z.2) := + (contMDiffOn_extChartAt (n := ∞) (x := riemannianExp c.1 c.2)).contMDiffAt + (by simpa only [extChartAt_source] using (isOpen_extChartAt_source _).mem_nhds hy) + have hF : ContDiffAt ℝ ∞ F z.2 := + (hd.comp z.2 (contMDiff_riemannianExp_fiber z.1 z.2)).contDiffAt + have hpart : (fun w => coordinateEndpoint c ((χ z).1,w))=F ∘ L.symm := by + funext w + dsimp only [coordinateEndpoint,F,Function.comp_apply] + rw [tangent_chart_fiber_inverse c z hz w] + have hG := (coordinateEndpoint_contDiffAt c z hz hy).differentiableAt (by simp) + have hpartD := (hG.hasFDerivAt.comp (χ z).2 + ((hasFDerivAt_const (χ z).1 (χ z).2).prodMk (hasFDerivAt_id (χ z).2))).fderiv + have hLz : (χ z).2=L z.2 := rfl + have hFD : HasFDerivAt F (fderiv ℝ F z.2) (L.symm (χ z).2) := by + rw [hLz,L.symm_apply_apply] + exact (hF.differentiableAt (by simp)).hasFDerivAt + have hRD := (hFD.comp (χ z).2 L.symm.hasFDerivAt).fderiv + change fderiv ℝ (fun w => coordinateEndpoint c ((χ z).1,w)) (χ z).2 = + (fderiv ℝ (coordinateEndpoint c) (χ z)).comp (inr ℝ _ _) at hpartD + rw [hpart] at hpartD + have hA : coordinateEndpointVertical c z=(fderiv ℝ F z.2).comp (L.symm : Model n →L[ℝ] X) := + hpartD.symm.trans hRD + have hD := (hd.mdifferentiableAt (by simp)).hasMFDerivAt.comp z.2 + ((contMDiff_riemannianExp_fiber z.1 z.2).mdifferentiableAt (by simp)).hasMFDerivAt + have hDE : fderiv ℝ F z.2=(mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d (riemannianExp z.1 z.2)).comp + (mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp z.1) z.2) := by + have hm := hD.mfderiv + rw [mfderiv_eq_fderiv] at hm + exact hm + have hLv : τ.continuousLinearMapAt ℝ z.1 v=L v := by + simp only [L,Trivialization.coe_continuousLinearEquivAt_eq] + rw [hLv] + rw [hA,ContinuousLinearMap.comp_apply] + change fderiv ℝ F z.2 (L.symm (L v))=_ + rw [L.symm_apply_apply,hDE] + rw [TangentBundle.continuousLinearMapAt_trivializationAt (by simpa only [extChartAt_source] using hy)] + rfl + +end ExpCoordinates +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitPairing.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitPairing.lean new file mode 100644 index 0000000000000000000000000000000000000000..80fac6bba19cd8fca2c78ee484a6d675f95e5036 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/SplitPairing.lean @@ -0,0 +1,198 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitAction + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma normalCost_fderiv_zero {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (normalCost x p) 0 xi = -inner ℝ p xi := by + have H := (normalCost_radial_fderiv_near_zero hp xi).self_of_nhds + simpa only [zero_smul,zero_sub,neg_mul,one_mul] using H + +lemma splitNormalAction_source_gradient {x : M} {p v : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t≠0) (hv : t • v ∈ injectivityDomain x) + (hB : DifferentiableAt ℝ (splitNormalAction x t p) (0,v)) + (xi : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (splitNormalAction x t p) (0,v) (xi,0) = -inner ℝ v xi := by + have hnc := ((normalCost_contDiffAt hv).differentiableAt (by simp)).hasFDerivAt + have H := (hnc.mul_const t⁻¹).add_const + (cost (riemannianExp x (t • v)) (riemannianExp x p)/(1-t)) + have hp₀ := (hasFDerivAt_id (𝕜 := ℝ) (0 : TangentSpace 𝓘(ℝ,Model n) x)).prodMk + (hasFDerivAt_const v (0 : TangentSpace 𝓘(ℝ,Model n) x)) + have H' : HasFDerivAt (fun u => splitNormalAction x t p (u,v)) + (t⁻¹ • fderiv ℝ (normalCost x (t • v)) 0) 0 := by + simpa only [splitNormalAction,normalCost,div_eq_mul_inv] using H + have heq := (hB.hasFDerivAt.comp (f := fun u => (u,v)) 0 hp₀).unique H' + have hh := congrArg (fun A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => A xi) heq + change fderiv ℝ (splitNormalAction x t p) (0,v) (xi,0) = + t⁻¹ * fderiv ℝ (normalCost x (t • v)) 0 xi at hh + rw [normalCost_fderiv_zero hv,real_inner_smul_left] at hh + rw [hh] + field_simp + +lemma splitNormalAction_mixed_pairing {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t≠0) (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (xi k : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (splitNormalAction x t p)) (0,p) (xi,0) (0,k) = -inner ℝ k xi := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let B := splitNormalAction x t p + have hBc : ContDiffAt ℝ ∞ B (0,p) := + (splitNormalAction_contDiffAt hleft hright).comp (f := fun q : V×V => (p,q)) (0,p) (contDiffAt_const.prodMk contDiffAt_id) + have hB₂ := hBc.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hdf := (hB₂.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hL : HasFDerivAt (fun v : V => ((0:V),v)) + ((0 : V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V)) p := + (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := ((hdf.hasFDerivAt.comp (f := fun v : V => ((0:V),v)) p hL).clm_apply + (hasFDerivAt_const (xi,(0:V)) p)).fderiv + have hnB : ∀ᶠ v : V in 𝓝 p, DifferentiableAt ℝ B (0,v) := by + have hn := (hBc.of_le (m := 1) (by simp)).eventually (by norm_num) + exact (hL.continuousAt.eventually hn).mono (fun _ h => h.differentiableAt (by norm_num)) + have hscale : Continuous (fun v : V => t • v) := by fun_prop + have hnleft : ∀ᶠ v : V in 𝓝 p, t • v ∈ injectivityDomain x := + hscale.continuousAt.preimage_mem_nhds + ((isOpen_injectivityDomain x).mem_nhds hleft) + have heq : (fun v : V => fderiv ℝ B (0,v) (xi,0)) =ᶠ[𝓝 p] + (fun v : V => -inner ℝ v xi) := by + filter_upwards [hnB,hnleft] with v hv hvleft + exact splitNormalAction_source_gradient ht hvleft hv xi + have hinner : HasFDerivAt (fun v : V => -inner ℝ v xi) (-(innerSL ℝ xi)) p := by + convert! ((innerSL ℝ xi).hasFDerivAt (x := p)).neg using 1 + funext v + exact congrArg Neg.neg (real_inner_comm xi v) + have H := congrArg (fun A : V →L[ℝ] ℝ => A k) (hd.symm.trans (heq.fderiv_eq.trans hinner.fderiv)) + simp only [add_apply,ContinuousLinearMap.comp_apply, + zero_apply,map_zero,zero_add,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply,neg_apply] at H + change fderiv ℝ (fderiv ℝ B) (0,p) (0,k) (xi,0) = -inner ℝ xi k at H + rw [real_inner_comm] at H + rwa [(hB₂.isSymmSndFDerivAt (by simp)).eq] at H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Stationary.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Stationary.lean new file mode 100644 index 0000000000000000000000000000000000000000..495ccfbd7c8cbd42fb07b2e74392ef91c059cdca --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Stationary.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Taylor +import OAI.Analysis.BiholderTransport.Coordinates.Inner + +namespace OAI + +section + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section MintySign +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma HasQuadraticExpansion.neg {f : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hf : HasQuadraticExpansion f p A) : HasQuadraticExpansion (fun q => -f q) (-p) (-A) := by + rw [hasQuadraticExpansion_iff_isLittleO] at hf ⊢ + convert! hf.const_mul_left (-1:ℝ) using 1 + funext q + simp only [quadraticTaylor,neg_apply,inner_neg_left] + ring + +lemma HasQuadraticExpansion.nonneg_of_localMin {f : E → ℝ} {A : E →L[ℝ] E} + (hf : HasQuadraticExpansion f 0 A) (hmin : IsLocalMin f 0) (e : E) : + 0 ≤ inner ℝ (A e) e := by + obtain ⟨r,hr,hh⟩ := Metric.mem_nhds_iff.mp hmin + have H := hf.neg.hessian_le_of_upper_support (eta := 0) hr (by + intro q hq + have hq' := hh (show q∈Metric.ball (0:E) r by simpa only [Metric.mem_ball,dist_zero_right] using hq) + simpa only [neg_zero,inner_zero_left,add_zero,zero_div,zero_mul] using neg_le_neg hq') e + simpa only [neg_apply,inner_neg_left,zero_mul,neg_nonpos] using H +end MintySign +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/TangentLift.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/TangentLift.lean new file mode 100644 index 0000000000000000000000000000000000000000..6985964f3992c6a27e41ae56003e0b2ec935c46e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/TangentLift.lean @@ -0,0 +1,190 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SmoothDistance + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +local instance tangentLiftNormedSpace : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance tangentLiftNormedAddCommGroupEndomorphism : NormedAddCommGroup (E →L[ℝ] E) := ContinuousLinearMap.toNormedAddCommGroup +local instance tangentLiftNormedSpaceEndomorphism : NormedSpace ℝ (E →L[ℝ] E) := ContinuousLinearMap.toNormedSpace +local instance tangentLiftNormedAddCommGroupDual : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance tangentLiftNormedSpaceDual : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance tangentLiftNormedAddCommGroupBilinear : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance tangentLiftNormedSpaceBilinear : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + +def coordinateTangentLift (φ : E → E) (z : E × E) : E × E := + (φ z.1, fderiv ℝ φ z.1 z.2) + +lemma fderiv_coordinateTangentLift {φ : E → E} {x : E} + (hφ : DifferentiableAt ℝ φ x) (hDφ : DifferentiableAt ℝ (fderiv ℝ φ) x) + (v u w : E) : + fderiv ℝ (coordinateTangentLift φ) (x,v) (u,w) = + (fderiv ℝ φ x u, fderiv ℝ (fderiv ℝ φ) x u v + fderiv ℝ φ x w) := by + have h1 := hφ.hasFDerivAt.comp (x,v) (hasFDerivAt_fst (𝕜 := ℝ)) + have h2 := (hDφ.hasFDerivAt.comp (x,v) (hasFDerivAt_fst (𝕜 := ℝ))).clm_apply + (hasFDerivAt_snd (𝕜 := ℝ)) + have he := congrArg (fun L : (E × E) →L[ℝ] (E × E) => L (u,w)) (h1.prodMk h2).fderiv + change fderiv ℝ (fun y : E × E => (φ y.1, fderiv ℝ φ y.1 y.2)) (x,v) (u,w) = _ + convert he using 1 <;> simp [add_comm] + +lemma coordinateTangentLift_push_geodesicField + {g h : E → E →L[ℝ] E →L[ℝ] ℝ} {φ : E → E} {x v : E} + (hg : DifferentiableAt ℝ g x) (hh : DifferentiableAt ℝ h (φ x)) + (hφ : ContDiffAt ℝ ∞ φ x) (hφs : Function.Surjective (fderiv ℝ φ x)) + (hmetric : ∀ᶠ y in 𝓝 x, ∀ u v, + g y u v = h (φ y) (fderiv ℝ φ y u) (fderiv ℝ φ y v)) + (hgi : (g x).IsInvertible) (hhi : (h (φ x)).IsInvertible) + (hhs : ∀ u v, h (φ x) u v = h (φ x) v u) : + fderiv ℝ (coordinateTangentLift φ) (x,v) (coordinateGeodesicField g (x,v)) = + coordinateGeodesicField h (coordinateTangentLift φ (x,v)) := by + have hpd := hφ.differentiableAt (by simp) + have hD := (hφ.fderiv_right (m := ∞) (by simp)).differentiableAt (by simp) + have heq := christoffel_pushforward hg hh hφ hφs hmetric hgi hhi hhs v v + change fderiv ℝ (coordinateTangentLift φ) (x,v) (v,-coordinateChristoffel g x v v) = _ + rw [fderiv_coordinateTangentLift hpd hD] + apply Prod.ext + · rfl + · change fderiv ℝ (fderiv ℝ φ) x v v + fderiv ℝ φ x (-coordinateChristoffel g x v v) = + -coordinateChristoffel h (φ x) (fderiv ℝ φ x v) (fderiv ℝ φ x v) + rw [map_neg,heq] + abel + +end + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +local instance tangentLiftNormedAddCommGroupCotangent (x : M) : NormedAddCommGroup (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance tangentLiftNormedSpaceCotangent (x : M) : NormedSpace ℝ (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance tangentLiftContinuousAddCotangent : ∀ x : M, ContinuousAdd (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + fun _ => inferInstance +local instance tangentLiftContinuousSMulCotangent : ∀ x : M, ContinuousSMul ℝ (TangentSpace 𝓘(ℝ,E) x →L[ℝ] ℝ) := + fun _ => inferInstance + +def riemannianCoordinateMetric (a : M) (z : E) : E →L[ℝ] E →L[ℝ] ℝ := + let y := (extChartAt 𝓘(ℝ,E) a).symm z + let L := (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ y + (innerSL ℝ (E := TangentSpace 𝓘(ℝ,E) y)).bilinearComp L L + +lemma riemannianCoordinateMetric_apply (a : M) (z u v : E) : + riemannianCoordinateMetric a z u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ + ((extChartAt 𝓘(ℝ,E) a).symm z) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).symmL ℝ + ((extChartAt 𝓘(ℝ,E) a).symm z) v) := rfl + +lemma riemannianCoordinateMetric_symm (a : M) (z u v : E) : + riemannianCoordinateMetric a z u v = riemannianCoordinateMetric a z v u := +by + simp only [riemannianCoordinateMetric_apply] + exact real_inner_comm _ _ + +lemma riemannianCoordinateMetric_positive {a : M} {z : E} + (hz : z ∈ (extChartAt 𝓘(ℝ,E) a).target) {v : E} (hv : v ≠ 0) : + 0 < riemannianCoordinateMetric a z v v := by + rw [riemannianCoordinateMetric_apply,real_inner_self_pos] + have hbase : (extChartAt 𝓘(ℝ,E) a).symm z ∈ + (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).baseSet := by + simpa only [TangentBundle.trivializationAt_baseSet,← extChartAt_source 𝓘(ℝ,E)] using + (extChartAt 𝓘(ℝ,E) a).map_target hz + exact fun hzero => hv (((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a).continuousLinearEquivAt ℝ _ hbase).symm.injective + (by simpa only [Trivialization.symm_continuousLinearEquivAt_eq,map_zero] using hzero)) + +variable [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma contDiffOn_riemannianCoordinateMetric (a : M) : + ContDiffOn ℝ ∞ (riemannianCoordinateMetric a) (extChartAt 𝓘(ℝ,E) a).target := by + let T := fun x : M => TangentSpace 𝓘(ℝ,E) x + obtain ⟨b,hb,hinner⟩ := IsContMDiffRiemannianBundle.exists_contMDiff + (IB := 𝓘(ℝ,E)) (n := ∞) (F := E) (E := T) + let e := trivializationAt E T a + let eB := trivializationAt (E →L[ℝ] E →L[ℝ] ℝ) (fun x => T x →L[ℝ] T x →L[ℝ] ℝ) a + let c : M → E →L[ℝ] E →L[ℝ] ℝ := fun x => + inCoordinates E T (E →L[ℝ] ℝ) (fun x => T x →L[ℝ] ℝ) a x a x (b x) + have hc : ContMDiffOn 𝓘(ℝ,E) 𝓘(ℝ,E →L[ℝ] E →L[ℝ] ℝ) ∞ c e.baseSet := by + intro x hx + have hxB : x ∈ eB.baseSet := by + change x ∈ e.baseSet ∩ (e.baseSet ∩ univ) + exact ⟨hx,hx,mem_univ x⟩ + have hh := (eB.contMDiffAt_section_iff hxB).mp (hb x) + exact hh.contMDiffWithinAt + have hmaps : MapsTo (extChartAt 𝓘(ℝ,E) a).symm + (extChartAt 𝓘(ℝ,E) a).target e.baseSet := by + intro z hz + change (extChartAt 𝓘(ℝ,E) a).symm z ∈ (chartAt E a).source + simpa only [extChartAt_source] using (extChartAt 𝓘(ℝ,E) a).map_target hz + have hs := hc.comp (contMDiffOn_extChartAt_symm a) hmaps + apply (contMDiffOn_iff_contDiffOn.mp hs).congr + intro z hz + ext u v + change riemannianCoordinateMetric a z u v = c ((extChartAt 𝓘(ℝ,E) a).symm z) u v + simp only [c] + rw [inCoordinates_apply_eq₂ (hmaps hz) (hmaps hz) (mem_univ _)] + rw [riemannianCoordinateMetric_apply,hinner] + simp only [Trivial.fiberBundle_trivializationAt',Trivial.linearMapAt_trivialization, + LinearMap.id_coe,id_eq] + change b _ (e.symmL ℝ _ u) (e.symmL ℝ _ v) = b _ (e.symm _ u) (e.symm _ v) + rw [Trivialization.symmL_apply e (hmaps hz),Trivialization.symmL_apply e (hmaps hz)] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/Taylor.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/Taylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d0446e710ff7e7f33f9b48df67105f67b9e80c9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/Taylor.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma HasQuadraticExpansion.hasFDerivAt {f : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hexp : HasQuadraticExpansion f p A) : HasFDerivAt f ((innerSL ℝ) p) 0 := by + obtain ⟨d,hd,hbound⟩ := hexp 1 zero_lt_one + let K : ℝ := 1+‖A‖/2 + have hK : 0 < K := by dsimp [K]; positivity + rw [hasFDerivAt_iff_isLittleO_nhds_zero,Asymptotics.isLittleO_iff] + intro c hc + have hpos : 0 < min d (c/K) := by positivity + filter_upwards [Metric.ball_mem_nhds (0:E) hpos] with h hh + have hn : ‖h‖ < min d (c/K) := by simpa only [Metric.mem_ball,dist_zero_right] using hh + have hb := hbound h (lt_of_lt_of_le hn (min_le_left _ _)) + have hA : |inner ℝ (A h) h| ≤ ‖A‖*‖h‖^2 := by + calc + _ ≤ ‖A h‖*‖h‖ := abs_real_inner_le_norm _ _ + _ ≤ (‖A‖*‖h‖)*‖h‖ := mul_le_mul_of_nonneg_right (A.le_opNorm h) (norm_nonneg _) + _ = _ := by ring + have heq : f h-f 0-inner ℝ p h = + (f h-quadraticTaylor (f 0) p A h)+inner ℝ (A h) h/2 := by + simp only [quadraticTaylor] + ring + have hb' : |f h-f 0-inner ℝ p h| ≤ K*‖h‖^2 := by + rw [heq] + have ht := abs_add_le (f h-quadraticTaylor (f 0) p A h) (inner ℝ (A h) h/2) + rw [abs_div,abs_of_pos (by norm_num : (0:ℝ)<2)] at ht + dsimp [K] + nlinarith + have hmul : ‖h‖*K ≤ c := (le_div_iff₀ hK).mp (le_of_lt (lt_of_lt_of_le hn (min_le_right _ _))) + have hbc : K*‖h‖^2 ≤ c*‖h‖ := by + nlinarith [mul_le_mul_of_nonneg_right hmul (norm_nonneg h)] + simpa only [zero_add,innerSL_apply_apply,Real.norm_eq_abs] using hb'.trans hbc + +lemma HasQuadraticExpansion.hessian_le_of_upper_support {f : E → ℝ} {p : E} + {A : E →L[ℝ] E} (hexp : HasQuadraticExpansion f p A) {eta R : ℝ} + (hR : 0 < R) + (hu : ∀ h : E, ‖h‖ < R → + f h ≤ f 0+inner ℝ p h+eta/2*‖h‖^2) : + ∀ e : E, inner ℝ (A e) e ≤ eta*‖e‖^2 := by + intro e + have hbound (eps : ℝ) (heps : 0 < eps) : + inner ℝ (A e) e ≤ (eta+2*eps)*‖e‖^2 := by + obtain ⟨d,hd,hrem⟩ := hexp eps heps + let t : ℝ := min R d / (2*(‖e‖+1)) + have ht : 0 < t := by dsimp [t]; positivity + have hteq : t*(2*(‖e‖+1)) = min R d := + div_mul_cancel₀ _ (by positivity) + have htn : t*‖e‖ < min R d := by nlinarith [norm_nonneg e] + have hnorm : ‖t • e‖ = t*‖e‖ := norm_smul_of_nonneg ht.le _ + have hi := hu (t • e) (by rw [hnorm]; exact lt_of_lt_of_le htn (min_le_left _ _)) + have hr := (abs_le.mp (hrem (t • e) (by + rw [hnorm]; exact lt_of_lt_of_le htn (min_le_right _ _)))).1 + simp only [quadraticTaylor,map_smul,real_inner_smul_left,real_inner_smul_right,hnorm] at hr hi + have hscale : t^2 * inner ℝ (A e) e ≤ t^2 * ((eta+2*eps)*‖e‖^2) := by + nlinarith + nlinarith [sq_pos_of_pos ht] + have hcl : (0:ℝ) ∈ closure (Ioo 0 1) := by + rw [closure_Ioo (by norm_num : (0:ℝ) ≠ 1)] + exact ⟨le_rfl,zero_le_one⟩ + have hc : Continuous (fun eps : ℝ => (eta+2*eps)*‖e‖^2) := by fun_prop + have hh := ContinuousWithinAt.closure_le hcl + (continuousWithinAt_const (b := inner ℝ (A e) e)) hc.continuousWithinAt + (fun eps heps => hbound eps heps.1) + simpa only [mul_zero,add_zero] using hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/TotalInjectivity.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/TotalInjectivity.lean new file mode 100644 index 0000000000000000000000000000000000000000..50fa2cb25c7e09e5de45f3b339c9e0cb9162cc6d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/TotalInjectivity.lean @@ -0,0 +1,185 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.InjectivityOpen +import OAI.Analysis.BiholderTransport.Coordinates.JointExpInverse +import OAI.Analysis.BiholderTransport.Regularity.InteriorCompactUniqueFiber + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma joint_exp_locally_injective (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z.2 ∈ injectivityDomain z.1) : + ∃ U : Set (TangentBundle 𝓘(ℝ,Model n) M), IsOpen U ∧ z ∈ U ∧ + InjOn (fun q : TangentBundle 𝓘(ℝ,Model n) M => (q.1,riemannianExp q.1 q.2)) U := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + obtain ⟨e,he,hze,_,_,_,_⟩ := exists_joint_exp_inverse z hz + let U := χ.source ∩ χ ⁻¹' e.source + have hU : IsOpen U := (continuousOn_extChartAt z).isOpen_inter_preimage (isOpen_extChartAt_source z) e.open_source + refine ⟨U,hU,⟨mem_extChartAt_source z,hze⟩,?_⟩ + intro q hq r hr hqr + apply χ.injOn hq.1 hr.1 + apply e.injOn hq.2 hr.2 + rw [he] + change ((χ q).1,d (riemannianExp (χ.symm (χ q)).1 (χ.symm (χ q)).2)) = + ((χ r).1,d (riemannianExp (χ.symm (χ r)).1 (χ.symm (χ r)).2)) + rw [χ.left_inv hq.1,χ.left_inv hr.1] + apply Prod.ext + · simp only [χ,tangent_chart_apply] + exact congrArg (extChartAt 𝓘(ℝ,Model n) z.1) (congrArg Prod.fst hqr) + · exact congrArg d (congrArg Prod.snd hqr) + +lemma interior_total_minimizingVectors (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z.2 ∈ injectivityDomain z.1) : + z ∈ interior {q : TangentBundle 𝓘(ℝ,Model n) M | q.2 ∈ minimizingVectors q.1} := by + apply interior_of_compact_unique_fiber isCompact_total_minimizingVectors + ((FiberBundle.continuous_proj _ _).prodMk contMDiff_riemannianExp.continuous) + · intro y + obtain ⟨p,hp,he⟩ := exists_minimizing_vector (n := n) y.1 y.2 + exact ⟨⟨y.1,p⟩,hp,Prod.ext rfl he⟩ + · rintro ⟨b,v⟩ hv hqz + rcases z with ⟨a,u⟩ + have hba : b=a := congrArg Prod.fst hqz + subst b + have huv : u=v := riemannianExp_interior_unique hz hv (congrArg Prod.snd hqz).symm + subst v + rfl + · exact joint_exp_locally_injective z hz + +lemma total_injectivityDomain_eq_interior : + {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ injectivityDomain z.1} = + interior {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ minimizingVectors z.1} := by + apply subset_antisymm + · exact fun z hz => interior_total_minimizingVectors z hz + · intro z hz + apply interior_minimizingVectors_subset z.1 + apply mem_interior_iff_mem_nhds.mpr + exact (FiberBundle.continuous_totalSpaceMk (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) z.1).continuousAt.preimage_mem_nhds + (mem_interior_iff_mem_nhds.mp hz) + +lemma isOpen_total_injectivityDomain : + IsOpen {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ injectivityDomain z.1} := by + rw [total_injectivityDomain_eq_interior] + exact isOpen_interior + +end +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma contMDiff_tangent_energy : + ContMDiff (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,ℝ) ∞ + (fun z : TangentBundle 𝓘(ℝ,E) M => ‖z.2‖^2/2) := by + intro z + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z + have hbase : (χ z).1 ∈ (extChartAt 𝓘(ℝ,E) z.1).target := + (extChartAt 𝓘(ℝ,E) z.1).map_source (mem_extChartAt_source z.1) + have hg := (contDiffOn_riemannianCoordinateMetric z.1).contDiffAt + ((isOpen_extChartAt_target z.1).mem_nhds hbase) + have henergy : ContDiffAt ℝ ∞ + (fun q : E×E => riemannianCoordinateMetric z.1 q.1 q.2 q.2/2) (χ z) := + (((hg.comp (χ z) contDiffAt_fst).clm_apply contDiffAt_snd).clm_apply contDiffAt_snd).div_const 2 + apply (henergy.contMDiffAt.comp z (show ContMDiffAt + (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E×E) ∞ χ z from contMDiffAt_extChartAt)).congr_of_eventuallyEq + filter_upwards [extChartAt_source_mem_nhds (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) z] with q hq + exact congrArg (fun a : ℝ => a/2) (coordinate_spray_energy z q ((tangent_chart_source_iff z q).mp hq)).symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/TwoSidedFiberLog.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/TwoSidedFiberLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..db362a8fdb2aa06665f9a8ed025827c89e7f9e63 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/TwoSidedFiberLog.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugacy + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TwoSidedFiberLog +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_coordinate_exp_inverse_of_nonconjugate {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : Function.Injective (fderiv ℝ + (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) + (riemannianExp (n := n) x v)) p)) : + ∃ e : OpenPartialHomeomorph (TangentSpace 𝓘(ℝ,Model n) x) (Model n), + (e : TangentSpace 𝓘(ℝ,Model n) x → Model n) = + (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) (riemannianExp (n := n) x v)) ∧ + p ∈ e.source ∧ ContDiffAt ℝ ∞ e.symm (e p) := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + let f := fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) (riemannianExp (n := n) x v) + have hf : ContDiffAt ℝ ∞ f p := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ + (extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p)) (riemannianExp (n := n) x p) from + contMDiffAt_extChartAt).comp p (contMDiff_riemannianExp_fiber x p)).contDiffAt + let D := fderiv ℝ f p + have hi : Function.Injective D := hp + let τ := trivializationAt (Model n) (fun b : M => TangentSpace 𝓘(ℝ,Model n) b) x + let L : TangentSpace 𝓘(ℝ,Model n) x ≃L[ℝ] Model n := + τ.continuousLinearEquivAt ℝ x (mem_baseSet_trivializationAt (Model n) _ x) + have hs : Function.Surjective D := + (LinearMap.injective_iff_surjective_of_finrank_eq_finrank L.toLinearEquiv.finrank_eq).mp hi + let A := ContinuousLinearEquiv.ofBijective D (LinearMap.ker_eq_bot.mpr hi) + (LinearMap.range_eq_top.mpr hs) + have hd : HasFDerivAt f (A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] Model n) p := + (hf.differentiableAt (by simp)).hasFDerivAt + let e := hf.toOpenPartialHomeomorph f hd (by simp) + have he : p ∈ e.source := hf.mem_toOpenPartialHomeomorph_source hd (by simp) + refine ⟨e,rfl,he,?_⟩ + exact hf.to_localInverse hd (by simp) + +lemma exists_smooth_two_sided_fiber_log_of_nonconjugate {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : Function.Injective (fderiv ℝ + (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) + (riemannianExp (n := n) x v)) p)) : + ∃ L : M → TangentSpace 𝓘(ℝ,Model n) x, + ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) ∞ L + (riemannianExp x p) ∧ + L (riemannianExp x p)=p ∧ + (∀ᶠ y in 𝓝 (riemannianExp x p), riemannianExp x (L y)=y) ∧ + (∀ᶠ v in 𝓝 p, L (riemannianExp x v)=v) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + let d := extChartAt 𝓘(ℝ,Model n) y + obtain ⟨e,he,hpe,hei⟩ := exists_coordinate_exp_inverse_of_nonconjugate hp + have hep : e p=d y := by rw [he] + let L : M → V := fun z => e.symm (d z) + have hL : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ L y := + (show ContDiffAt ℝ ∞ e.symm (d y) from hep ▸ hei).contMDiffAt.comp y + (show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y from contMDiffAt_extChartAt) + have hLy : L y=p := by dsimp [L]; rw [←hep,e.left_inv hpe] + refine ⟨L,hL,hLy,?_,?_⟩ + · have ht : ∀ᶠ z in 𝓝 y, d z∈e.target := + (continuousAt_extChartAt y).eventually (e.open_target.mem_nhds (hep ▸ e.map_source hpe)) + have hcont : ContinuousAt (fun z => riemannianExp x (L z)) y := + (continuous_riemannianExp x).continuousAt.comp hL.continuousAt + have hs : ∀ᶠ z in 𝓝 y, riemannianExp x (L z)∈d.source := by + have H := hcont.eventually (show d.source∈𝓝 (riemannianExp x (L y)) from by + rw [hLy]; exact extChartAt_source_mem_nhds y) + exact H + filter_upwards [ht,hs,extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) y] with z hzt hzs hsz + apply d.injOn hzs hsz + have HR := e.right_inv hzt + rw [he] at HR + exact HR + · filter_upwards [e.open_source.mem_nhds hpe] with v hv + change e.symm (d (riemannianExp x v))=v + rw [←show e v=d (riemannianExp x v) from congrFun he v] + exact e.left_inv hv + +end TwoSidedFiberLog +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Coordinates/UniformLog.lean b/lean/OAI/Analysis/BiholderTransport/Coordinates/UniformLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..80c5f2711b14397995e0047147affb24301771d9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Coordinates/UniformLog.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FactorNorm + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformLog +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma uniform_prefix_log_derivative_bounds : + ∃ c C : ℝ, 0 TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [FiniteDimensional ℝ E] [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma contMDiff_tangentScale : + ContMDiff (𝓘(ℝ,ℝ).prod (𝓘(ℝ,E).prod 𝓘(ℝ,E))) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (fun p : ℝ × TangentBundle 𝓘(ℝ,E) M => tangentScale p.1 p.2) := by + intro p + have hpr : ContMDiffAt (𝓘(ℝ,ℝ).prod (𝓘(ℝ,E).prod 𝓘(ℝ,E))) + (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ (fun q : ℝ × TangentBundle 𝓘(ℝ,E) M => q.2) p := + contMDiffAt_snd + rw [Bundle.contMDiffAt_totalSpace] at hpr ⊢ + refine ⟨hpr.1,?_⟩ + let e := trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) p.2.1 + have hnear : ∀ᶠ q : ℝ × TangentBundle 𝓘(ℝ,E) M in 𝓝 p, q.2.1 ∈ e.baseSet := + hpr.1.continuousAt.preimage_mem_nhds + (e.open_baseSet.mem_nhds (mem_baseSet_trivializationAt E _ p.2.1)) + apply (contMDiffAt_fst.smul hpr.2).congr_of_eventuallyEq + filter_upwards [hnear] with q hq + exact (e.linear ℝ hq).map_smul q.1 q.2.2 + +lemma sprayFlow_zero_velocity_base (a : M) (t : ℝ) : + (sprayFlow t (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M)).1 = a := by + have hh := dist_sprayFlow_le (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) 0 t + exact (show a = (sprayFlow t ⟨a,0⟩).1 by + simpa only [sprayFlow_zero,norm_zero,mul_zero,dist_le_zero] using hh).symm + +lemma sprayFlow_minimizing_near_zero_section (a : M) : + ∃ τ : ℝ, 0 < τ ∧ ∀ᶠ z : TangentBundle 𝓘(ℝ,E) M in 𝓝 ⟨a,0⟩, + dist z.1 (sprayFlow τ z).1 = τ * ‖z.2‖ := by + obtain ⟨δ,r,τ,hδ,hr,hτ,hτr,Φ,e,hΦ,hΦ0,hode,he,hesub,hed,hei,hsrc,hdiag,htarget,hdist⟩ := + exists_uniform_metric_normal_coordinates (E := E) a + let A : TangentBundle 𝓘(ℝ,E) M := ⟨a,0⟩ + let c := extChartAt 𝓘(ℝ,E) a + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) A + have hchart0 : χ A = (c a,0) := by + rw [tangent_chart_apply] + change (c a,tangentCoordChange 𝓘(ℝ,E) a a a 0) = (c a,0) + rw [tangentCoordChange_self (mem_extChartAt_source a)] + have hbase : ContinuousAt (fun z : TangentBundle 𝓘(ℝ,E) M => z.1) A := + (FiberBundle.continuous_proj E (fun x : M => TangentSpace 𝓘(ℝ,E) x)).continuousAt + have hflow₀ : Continuous (fun z : TangentBundle 𝓘(ℝ,E) M => sprayFlow τ z) := + contMDiff_sprayFlow.continuous.comp (continuous_const.prodMk continuous_id) + have hflow : ContinuousAt (fun z : TangentBundle 𝓘(ℝ,E) M => (sprayFlow τ z).1) A := + (FiberBundle.continuous_proj E (fun x : M => TangentSpace 𝓘(ℝ,E) x)).continuousAt.comp + hflow₀.continuousAt + have hnear₁ : ∀ᶠ z in 𝓝 A, z.1 ∈ Metric.ball a δ := + hbase.preimage_mem_nhds (Metric.ball_mem_nhds a hδ) + have hnear₂ : ∀ᶠ z in 𝓝 A, (sprayFlow τ z).1 ∈ Metric.ball a δ := + hflow.preimage_mem_nhds (by rw [sprayFlow_zero_velocity_base]; exact Metric.ball_mem_nhds a hδ) + have hnear₃ : ∀ᶠ z in 𝓝 A, χ z ∈ e.source := + (continuousAt_extChartAt A).preimage_mem_nhds + (e.open_source.mem_nhds (hchart0 ▸ hdiag a (Metric.mem_ball_self hδ))) + refine ⟨τ,hτ,?_⟩ + filter_upwards [hnear₁,hnear₂,hnear₃] with z hz hy hez + have hzsrc : z ∈ χ.source := (tangent_chart_source_iff A z).mpr (hsrc hz) + have hball := hesub hez + have h₀ : χ.symm (Φ (0,χ z)) = z := by rw [hΦ0 _ hball,χ.left_inv hzsrc] + have ht : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have hex := sprayFlow_eq_coordinate_curve A hr + (fun t ht => (hode t ht (χ z) hball).1) + (fun t ht => (hode t ht (χ z) hball).2) h₀ ht + have hchart : χ (sprayFlow τ z) = Φ (τ,χ z) := by + rw [hex,χ.right_inv ((tangent_chart_target_iff A _).mpr (hode τ ht (χ z) hball).1)] + have hmet := hdist z.1 hz (sprayFlow τ z).1 hy (χ z).2 + have hcz : (c z.1,(χ z).2) = χ z := by + exact Prod.ext (congrArg Prod.fst (tangent_chart_apply A z)).symm rfl + rw [hcz] at hmet + have hend : (Φ (τ,χ z)).1 = c (sprayFlow τ z).1 := by + rw [←hchart]; exact congrArg Prod.fst (tangent_chart_apply A _) + have hh := hmet hez hend + have hen := coordinate_spray_energy A z (hsrc hz) + have hfst : (χ z).1 = c z.1 := congrArg Prod.fst (tangent_chart_apply A z) + rw [hfst] at hen + rw [hen,Real.sqrt_sq (norm_nonneg _)] at hh + exact hh + +lemma sprayFlow_uniformly_short_minimizing (z₀ : TangentBundle 𝓘(ℝ,E) M) : + ∀ᶠ p : ℝ × TangentBundle 𝓘(ℝ,E) M in 𝓝 (0,z₀), + dist p.2.1 (sprayFlow p.1 p.2).1 = |p.1| * ‖p.2.2‖ := by + obtain ⟨τ,hτ,H⟩ := sprayFlow_minimizing_near_zero_section (E := E) z₀.1 + let S : ℝ × TangentBundle 𝓘(ℝ,E) M → TangentBundle 𝓘(ℝ,E) M := + fun p => tangentScale (p.1/τ) p.2 + have hS : ContinuousAt S (0,z₀) := + contMDiff_tangentScale.continuous.continuousAt.comp + ((continuousAt_fst.div_const τ).prodMk continuousAt_snd) + have hS0 : S (0,z₀) = ⟨z₀.1,0⟩ := by simp [S,tangentScale] + have hnear := (show Tendsto S (𝓝 (0,z₀)) (𝓝 ⟨z₀.1,0⟩) by + simpa only [ContinuousAt,hS0] using hS).eventually H + filter_upwards [hnear] with p hp + change dist p.2.1 (sprayFlow τ (tangentScale (p.1/τ) p.2)).1 = + τ * ‖(p.1/τ) • p.2.2‖ at hp + rw [sprayFlow_scale,div_mul_cancel₀ _ hτ.ne'] at hp + change dist p.2.1 (sprayFlow p.1 p.2).1 = τ * ‖(p.1/τ) • p.2.2‖ at hp + rw [norm_smul,Real.norm_eq_abs,abs_div,abs_of_pos hτ] at hp + rw [hp, ← mul_assoc, mul_div_cancel₀ _ (ne_of_gt hτ)] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPole.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPole.lean new file mode 100644 index 0000000000000000000000000000000000000000..8837f7e010710a47805fc8bb9a06db71416abc76 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPole.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates +import OAI.Analysis.BiholderTransport.LinearAlgebra.PrefixActionJets +import OAI.Analysis.BiholderTransport.Contact.EnvelopePole + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.hopfPole_minimizer (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 + hopfLax t u (riemannianExp x (t • q))) := by + intro q + have he := (contMDiff_riemannianExp_fiber (n := n) x (t • q)).mdifferentiableAt (by simp) + have hl : MDifferentiableAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) + 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) (fun q => t • q) q := + (show ContDiffAt ℝ ∞ (fun q : TangentSpace 𝓘(ℝ,Model n) x => t • q) q from by + fun_prop).contMDiffAt.mdifferentiableAt (by simp) + exact ((hmtw.mdifferentiable_hopfLax hu hv hdual ht ht1 _).comp q + (he.comp q hl)).differentiableAt + +lemma WeakMTW.actualPole_supports (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 + hopfLax t u (riemannianExp x (t • q)))) + (t • innerSL ℝ-(innerSL ℝ).comp R) p := by + have hC := (prefixAction_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + apply envelope_pole_second_derivative hC ha ha0 + (Filter.Eventually.of_forall (hmtw.prefix_hopfLax_differentiable hu hv hdual ht ht1 x)) + (hmtw.actualPole_supports hu hv hdual ht ht1 harep) + (prefixAction_endpoint_hessian hp) + intro d e + rw [hC.isSymmSndFDerivAt (by norm_num) |>.eq] + rw [prefixAction_mixed ht.ne' hp] + exact congrArg Neg.neg (real_inner_comm d e) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPoleKernel.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPoleKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..19632bac7604c5f146025f1656bc05d543f052c7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ActualPoleKernel.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.SplitEndpointCost +import OAI.Analysis.BiholderTransport.Contact.ActualPoleJet + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.actualPole_kernel (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t s : ℝ} (ht : 0 hopfLax t u (riemannianExp x (t • q)) + let B : V×V → ℝ := prefixAction x t + let D : V → ℝ := fun b => splitEndpointCost x s (b,pj) + have hpole : hopfPole (n := n) t u (riemannianExp x (t • p))=x := by + have H := harep.self_of_nhds + rw [ha0,riemannianExp_zero] at H + exact H.symm + have hB : DifferentiableAt ℝ B (0,p) := + (prefixAction_contDiffAt hp).differentiableAt (by simp) + have hBa : ∀ b d:V, fderiv ℝ B (0,p) (b,d) = -inner ℝ p b+t*inner ℝ p d := by + intro b d + rw [show (b,d)=((b,0):V×V)+(0,d) by simp,map_add] + rw [prefixAction_source_gradient ht.ne' hp,prefixAction_endpoint_gradient hp] + have hD : HasFDerivAt D (-innerSL ℝ pj) 0 := by + have HD := ((splitEndpointCost_contDiffAt hleft hright).differentiableAt + (by simp)).hasFDerivAt.comp (f := fun b : V => (b,pj)) 0 + ((hasFDerivAt_id (𝕜 := ℝ) (0:V)).prodMk (hasFDerivAt_const pj (0:V))) + apply HD.congr_fderiv + ext b + change fderiv ℝ (splitEndpointCost x s) (0,pj) (b,0) = -inner ℝ pj b + exact splitEndpointCost_source_gradient hs.ne' hleft hright b + have henv : ∀ᶠ q in 𝓝 p, f q-B (a q,q)=u (riemannianExp x (a q)) := by + filter_upwards [harep] with q hq + have H := hmtw.hopfPole_minimizer hu hv hdual ht ht1 (riemannianExp x (t • q)) + rw [←hq] at H + dsimp [f,B,prefixAction] + linarith + have hm : IsLocalMin (fun q => f q-B (a q,q)+D (a q)) p := by + have hpEq := henv.self_of_nhds + have hc : D 0=cost x (riemannianExp x pj) := by + change splitEndpointCost x s (0,pj)=cost x (riemannianExp x pj) + rw [splitEndpointCost_axis hs hs1 hleft hright] + have H := hmin + change dist x (riemannianExp x pj)=‖pj‖ at H + rw [cost,H] + filter_upwards [henv] with q hq + rw [hpEq,ha0,riemannianExp_zero,hc,hq] + have HG := dualPair_gap_nonneg hv hdual (riemannianExp x (a q)) (riemannianExp x pj) + have HC : cost (riemannianExp x (a q)) (riemannianExp x pj)≤D (a q) := + normalCost_le_splitNormalAction x pj (a q) pj hs hs1 + dsimp only [contactGap] at HG hactive + linarith + exact pole_kernel_of_active_support ha ha0 + (hmtw.actualPole_first_derivative hu hv hdual ht ht1 hp hpole) hB hBa hD hm + (hmtw.actualPole_taylor hu hv hdual ht ht1 hp ha ha0 harep).2.2 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchActiveGrowth.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchActiveGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..ae289505653aaaf4fb03aa520b78fd5f05464a57 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchActiveGrowth.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.MetricLocalGrowth +import OAI.Analysis.BiholderTransport.CostGeometry.BranchGrowth + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.active_hull_branch_growth (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {T : ℝ} (hT : 0 cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) : + ∃ b>0, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, + b*‖h‖^2 ≤ cTransform v (riemannianExp x h)-cTransform v x+ + (G (riemannianExp x h,riemannianExp x (T • p))-G (x,riemannianExp x (T • p)))/T := by + obtain ⟨ι,inst,z,w,hz,_,hw,hsum,heq⟩ := eq_pos_convex_span_of_mem_convexHull hp + let : Fintype ι := inst + have : Nonempty ι := by + by_contra h + have : IsEmpty ι := not_nonempty_iff.mp h + simp at hsum + have hsub : convexHull ℝ (range z) ⊆ convexHull ℝ (activeLogs (n := n) v x) := convexHull_mono hz + obtain ⟨s,hTs,hs⟩ := exists_between hT1 + obtain ⟨b,hb,H⟩ := hmtw.finite_branch_cost_growth z w hw hsum + (fun i => (hz (mem_range_self i)).1) hT hTs hs + (fun t ht q hq => hID t ht q (hsub hq)) (by simpa only [heq] using hG) + (by simpa only [heq] using hagree) + refine ⟨b,hb,?_⟩ + filter_upwards [H] with h hh + obtain ⟨i,hi⟩ := hh + have hiA := hz (mem_range_self i) + have hsup := active_split_lower_support hv hiA.1 hiA.2 (hT.trans hTs) hs (riemannianExp x h) + simp only [normalCost,riemannianExp_zero,heq] at hi + rw [neg_div] at hsup + linarith + +lemma WeakMTW.active_hull_branch_strict_growth (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (n := n) v x)) + {T : ℝ} (hT : 0 cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) : + ∀ᶠ a in 𝓝 x, a≠x → cTransform v x+G (x,riemannianExp x (T • p))/T < + cTransform v a+G (a,riemannianExp x (T • p))/T := by + obtain ⟨b,hb,H⟩ := hmtw.active_hull_branch_growth hv hp hT hT1 hID hG hagree + have hh := metric_local_growth_of_normal (n := n) + (f := fun a => cTransform v a+G (a,riemannianExp x (T • p))/T) + (b := b) (x := x) (by + filter_upwards [H] with h hh + rw [sub_div] at hh + linarith) + filter_upwards [hh] with a ha hax + have hd : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_cost_branch (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + ∃ G : M×M → ℝ, + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (z.1,riemannianExp z.1 z.2) ∧ + ∀ᶠ r in 𝓝 z, r.2 ∈ injectivityDomain r.1 → + (fun q : M×M => cost q.1 q.2) =ᶠ[𝓝 (r.1,riemannianExp r.1 r.2)] G := by + obtain ⟨P,hP,hPz,hleft,hright⟩ := exists_smooth_exp_branch z hz + let G : M×M → ℝ := fun q => ‖(P q).2‖^2/2 + refine ⟨G,(contMDiff_tangent_energy (P (z.1,riemannianExp z.1 z.2))).comp _ hP,?_⟩ + let F : TangentBundle 𝓘(ℝ,Model n) M → M×M := fun r => (r.1,riemannianExp r.1 r.2) + have hF : Continuous F := + ((Bundle.contMDiff_proj (fun v : M => TangentSpace 𝓘(ℝ,Model n) v)).prodMk contMDiff_riemannianExp).continuous + have hPnear : ∀ᶠ q in 𝓝 (F z), ContinuousAt P q := by + have hzero : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 0 P (F z) := hP.of_le bot_le + exact ((contMDiffAt_iff_contMDiffAt_nhds (by simp)).mp hzero).mono + (fun point hpoint => hpoint.continuousAt) + have hRnear : ∀ᶠ q in 𝓝 (F z), ∀ᶠ q' in 𝓝 q, + (P q').1=q'.1 ∧ riemannianExp (P q').1 (P q').2=q'.2 := + eventually_eventually_nhds.mpr hright + filter_upwards [hleft,(hF.continuousAt.eventually (hPnear.and hRnear))] with r hr hnear + intro hrID + have hC : {v : TangentBundle 𝓘(ℝ,Model n) M | v.2 ∈ minimizingVectors v.1} ∈ 𝓝 (P (F r)) := by + rw [show P (F r)=r from hr] + exact mem_interior_iff_mem_nhds.mp (interior_total_minimizingVectors r hrID) + have hmin := hnear.1.preimage_mem_nhds hC + filter_upwards [hmin,hnear.2] with q hqmin hq + change dist q.1 q.2^2/2=‖(P q).2‖^2/2 + change dist (P q).1 (riemannianExp (P q).1 (P q).2)=‖(P q).2‖ at hqmin + have hd : dist q.1 q.2=‖(P q).2‖ := + (congrArg₂ dist hq.1.symm hq.2.symm).trans hqmin + rw [hd] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchCost2.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchCost2.lean new file mode 100644 index 0000000000000000000000000000000000000000..eceeec535ce74e41e86dc9dae69949ccd8fcad30 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchCost2.lean @@ -0,0 +1,186 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.BranchInverse +import OAI.Analysis.BiholderTransport.Regularity.ReverseRegular + +namespace OAI + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_cost_branch_with_action (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + ∃ G : M×M → ℝ, + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (z.1,riemannianExp z.1 z.2) ∧ + (∀ᶠ r in 𝓝 z,G (r.1,riemannianExp r.1 r.2)=‖r.2‖^2/2) ∧ + ∀ᶠ r in 𝓝 z, r.2 ∈ injectivityDomain r.1 → + (fun q : M×M => cost q.1 q.2) =ᶠ[𝓝 (r.1,riemannianExp r.1 r.2)] G := by + obtain ⟨P,hP,hPz,hleft,hright⟩ := exists_smooth_exp_branch z hz + let G : M×M → ℝ := fun q => ‖(P q).2‖^2/2 + refine ⟨G,(contMDiff_tangent_energy (P (z.1,riemannianExp z.1 z.2))).comp _ hP,?_,?_⟩ + · filter_upwards [hleft] with r hr + change ‖(P (r.1,riemannianExp r.1 r.2)).2‖^2/2=‖r.2‖^2/2 + rw [hr] + let F : TangentBundle 𝓘(ℝ,Model n) M → M×M := fun r => (r.1,riemannianExp r.1 r.2) + have hF : Continuous F := + ((Bundle.contMDiff_proj (fun v : M => TangentSpace 𝓘(ℝ,Model n) v)).prodMk contMDiff_riemannianExp).continuous + have hPnear : ∀ᶠ q in 𝓝 (F z), ContinuousAt P q := by + have hzero : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 0 P (F z) := hP.of_le bot_le + exact ((contMDiffAt_iff_contMDiffAt_nhds (by simp)).mp hzero).mono + (fun point hpoint => hpoint.continuousAt) + have hRnear : ∀ᶠ q in 𝓝 (F z), ∀ᶠ q' in 𝓝 q, + (P q').1=q'.1 ∧ riemannianExp (P q').1 (P q').2=q'.2 := + eventually_eventually_nhds.mpr hright + filter_upwards [hleft,(hF.continuousAt.eventually (hPnear.and hRnear))] with r hr hnear + intro hrID + have hC : {v : TangentBundle 𝓘(ℝ,Model n) M | v.2 ∈ minimizingVectors v.1} ∈ 𝓝 (P (F r)) := by + rw [show P (F r)=r from hr] + exact mem_interior_iff_mem_nhds.mp (interior_total_minimizingVectors r hrID) + have hmin := hnear.1.preimage_mem_nhds hC + filter_upwards [hmin,hnear.2] with q hqmin hq + change dist q.1 q.2^2/2=‖(P q).2‖^2/2 + change dist (P q).1 (riemannianExp (P q).1 (P q).2)=‖(P q).2‖ at hqmin + have hd : dist q.1 q.2=‖(P q).2‖ := + (congrArg₂ dist hq.1.symm hq.2.symm).trans hqmin + rw [hd] +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma contMDiff_reverseRay : ContMDiff + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ (reverseRay (n := n) (M := M)) := by + exact contMDiff_tangentScale.comp + (contMDiff_const.prodMk (contMDiff_sprayFlow.comp (contMDiff_const.prodMk contMDiff_id))) + +lemma reverseRay_base (z : TangentBundle 𝓘(ℝ,Model n) M) : + (reverseRay z).1=riemannianExp z.1 z.2 := by + rw [riemannianExp_eq_sprayFlow] + rfl + +lemma reverseRay_endpoint (z : TangentBundle 𝓘(ℝ,Model n) M) : + riemannianExp (reverseRay z).1 (reverseRay z).2=z.1 := by + rw [←reverseRay_base,reverseRay_involutive] + +lemma fiber_nonconjugate_of_smooth_left_inverse + (z : TangentBundle 𝓘(ℝ,Model n) M) + (P : M×M → TangentBundle 𝓘(ℝ,Model n) M) + (hP : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P (z.1,riemannianExp z.1 z.2)) + (hPz : P (z.1,riemannianExp z.1 z.2)=z) + (hleft : ∀ᶠ r in 𝓝 z,P (r.1,riemannianExp r.1 r.2)=r) : + Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2) := by + let V := TangentSpace 𝓘(ℝ,Model n) z.1 + let y := riemannianExp z.1 z.2 + let d := extChartAt 𝓘(ℝ,Model n) y + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let τ := trivializationAt (Model n) (fun b : M => TangentSpace 𝓘(ℝ,Model n) b) z.1 + let L : V ≃L[ℝ] Model n := + τ.continuousLinearEquivAt ℝ z.1 (mem_baseSet_trivializationAt (Model n) _ z.1) + let f : V → Model n := fun v => d (riemannianExp z.1 v) + let g : Model n → Model n := fun w => (χ (P (z.1,d.symm w))).2 + have hdy : d.symm (d y)=y := d.left_inv (mem_extChartAt_source y) + have hd : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d.symm (d y) := + (contMDiffOn_extChartAt_symm y).contMDiffAt + ((isOpen_extChartAt_target y).mem_nhds (d.map_source (mem_extChartAt_source y))) + have hp : ContMDiffAt 𝓘(ℝ,Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun w => P (z.1,d.symm w)) (d y) := by + have hm : ContMDiffAt 𝓘(ℝ,Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun w => (z.1,d.symm w)) (d y) := contMDiffAt_const.prodMk hd + have hP' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P (z.1,d.symm (d y)) := by + rw [hdy]; exact hP + exact hP'.comp (d y) hm + have hχ : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + 𝓘(ℝ,Model n×Model n) ∞ χ (P (z.1,d.symm (d y))) := by + rw [hdy,hPz] + exact contMDiffAt_extChartAt + have hg : ContDiffAt ℝ ∞ g (f z.2) := + contDiffAt_snd.comp (f z.2) (hχ.comp (d y) hp).contDiffAt + have hf : ContDiffAt ℝ ∞ f z.2 := + ((show ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y from + contMDiffAt_extChartAt).comp z.2 (contMDiff_riemannianExp_fiber z.1 z.2)).contDiffAt + have hfiber : Continuous (fun v : V => (⟨z.1,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)) := + (contMDiff_fiber_embedding z.1).continuous + have hfleft : ∀ᶠ v in 𝓝 z.2,P (z.1,riemannianExp z.1 v)=⟨z.1,v⟩ := + hfiber.continuousAt.eventually hleft + have hsrc : ∀ᶠ v in 𝓝 z.2,riemannianExp z.1 v∈d.source := + (continuous_riemannianExp z.1).continuousAt.eventually (extChartAt_source_mem_nhds y) + have heq : g ∘ f =ᶠ[𝓝 z.2] L := by + filter_upwards [hfleft,hsrc] with v hv hvs + change (χ (P (z.1,d.symm (d (riemannianExp z.1 v))))).2=L v + rw [d.left_inv hvs,hv] + rfl + have hD : (fderiv ℝ g (f z.2)).comp (fderiv ℝ f z.2)=(L : V →L[ℝ] Model n) := by + rw [←fderiv_comp _ (hg.differentiableAt (by simp)) (hf.differentiableAt (by simp)), + heq.fderiv_eq,L.fderiv] + intro u v huv + apply L.injective + have H := congrArg (fderiv ℝ g (f z.2)) huv + change ((fderiv ℝ g (f z.2)).comp (fderiv ℝ f z.2)) u= + ((fderiv ℝ g (f z.2)).comp (fderiv ℝ f z.2)) v at H + rw [hD] at H + exact H + +lemma reverseRay_nonconjugate (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2)) : + Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp (reverseRay z).1 (reverseRay z).2) + (riemannianExp (reverseRay z).1 v)) (reverseRay z).2) := by + obtain ⟨P,hP,hPz,hleft,_⟩ := exists_smooth_exp_branch z hz + let Q : M×M → TangentBundle 𝓘(ℝ,Model n) M := fun q => reverseRay (P (q.2,q.1)) + have hQ : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Q + ((reverseRay z).1,riemannianExp (reverseRay z).1 (reverseRay z).2) := by + rw [reverseRay_endpoint,reverseRay_base] + have hs : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ (fun q : M×M => (q.2,q.1)) + (riemannianExp z.1 z.2,z.1) := contMDiffAt_snd.prodMk contMDiffAt_fst + have hp : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ (fun q : M×M => P (q.2,q.1)) + (riemannianExp z.1 z.2,z.1) := hP.comp (riemannianExp z.1 z.2,z.1) hs + exact contMDiff_reverseRay.contMDiffAt.comp (riemannianExp z.1 z.2,z.1) hp + apply fiber_nonconjugate_of_smooth_left_inverse (reverseRay z) Q hQ + · dsimp only [Q] + rw [reverseRay_endpoint,reverseRay_base,hPz] + · have H := continuous_reverseRay.continuousAt.eventually + (show ∀ᶠ r in 𝓝 (reverseRay (reverseRay z)),P (r.1,riemannianExp r.1 r.2)=r from + by rw [reverseRay_involutive]; exact hleft) + filter_upwards [H] with r hr + dsimp only [Q] + rw [reverseRay_endpoint,reverseRay_base] at hr + rw [hr,reverseRay_involutive] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchGrowth.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..a1c4187ba120eec3e309e5872276cea3db4507dd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchGrowth.lean @@ -0,0 +1,149 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.BranchJets + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.branch_transverse_slack_strict (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 0 hessianValue x (t • (∑ j, w j • p j)) ξ) (𝓝[<] T) (𝓝 A)) : + (∑ i, w i*(hessianValue x (s • p i) ξ/s)) < A/T := by + obtain ⟨a,hTa,has⟩ := exists_between hTs + have hlim' := hlim.div (continuousAt_id.tendsto.mono_left nhdsWithin_le_nhds) hT.ne' + have hle : (∑ i, w i*(hessianValue x (a • p i) ξ/a)) ≤ A/T := by + apply ge_of_tendsto hlim' + filter_upwards [(eventually_gt_nhds hT).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with t ht htT + exact (hmtw.finite_transverse_slack_strict p w hw hsum hmin ht (htT.trans hTa) + (has.trans hs) (hID t ⟨ht,htT⟩) hξ hortho).le + apply lt_of_lt_of_le _ hle + apply Finset.sum_lt_sum + · intro i _ + exact (mul_lt_mul_of_pos_left + (divided_hessian_strict_decrease (hmin i) (hT.trans hTa) has hs hξ) (hw i)).le + · obtain ⟨i⟩ := ‹Nonempty ι› + exact ⟨i,Finset.mem_univ i,mul_lt_mul_of_pos_left + (divided_hessian_strict_decrease (hmin i) (hT.trans hTa) has hs hξ) (hw i)⟩ + +lemma finite_normal_branch_envelope_growth + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 00, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, ∃ i, + b*‖h‖^2≤ (g h-g 0)/T- + (normalCost x (s • p i) h-normalCost x (s • p i) 0)/s := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + let r := ∑ j, w j • p j + have hsi : ∀ i, s • p i ∈ injectivityDomain x := + fun i => contracted_minimizer_mem_injectivityDomain (hmin i) hs0 hs + let f := fun i (h : TangentSpace 𝓘(ℝ,Model n) x) => + T⁻¹*(g h-g 0)-s⁻¹*(normalCost x (s • p i) h-normalCost x (s • p i) 0) + have hleft : ContDiffAt ℝ 2 g 0 := hg + have hright : ∀ i, ContDiffAt ℝ 2 (normalCost x (s • p i)) 0 := + fun i => (normalCost_contDiffAt (hsi i)).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hf : ∀ i, ContDiffAt ℝ 2 (f i) 0 := fun i => + (contDiffAt_const.mul (hleft.sub contDiffAt_const)).sub + (contDiffAt_const.mul ((hright i).sub contDiffAt_const)) + have hfirst : ∀ i, fderiv ℝ (f i) 0=innerSL ℝ (p i-r) := by + intro i + have H := ((hgfirst.sub_const (g 0)).const_smul T⁻¹).sub + (((normalCost_hasFDerivAt_zero (hsi i)).sub_const (normalCost x (s • p i) 0)).const_smul s⁻¹) + have H' : HasFDerivAt (f i) (innerSL ℝ (p i-r)) 0 := by + apply H.congr_fderiv + ext v + simp only [_root_.sub_apply,_root_.smul_apply,innerSL_apply_apply,inner_neg_left, + real_inner_smul_left,inner_sub_left,smul_eq_mul] + field_simp [hT.ne', hs0.ne'] + ring + exact H'.fderiv + have hsecond : ∀ i v, fderiv ℝ (fderiv ℝ (f i)) 0 v v= + fderiv ℝ (fderiv ℝ g) 0 v v/T-hessianValue x (s • p i) v/s := by + intro i v + rw [second_fderiv_scaled_differences hleft (hright i)] + rw [hessianValue_eq_normalHessian (hsi i)] + simp only [normalHessian,div_eq_mul_inv] + ring + have hmean : ∀ v, ∑ i, w i*fderiv ℝ (f i) 0 v=0 := by + intro v + simp only [hfirst,innerSL_apply_apply,inner_sub_left,mul_sub,Finset.sum_sub_distrib, + ←Finset.sum_mul,hsum,one_mul] + have heq : (∑ i, w i*inner ℝ (p i) v)=inner ℝ r v := by + simp only [r,sum_inner,real_inner_smul_left] + rw [heq,sub_self] + have hpos : ∀ v, v≠0 → (∀ i, fderiv ℝ (f i) 0 v=0) → + 0<∑ i, w i*fderiv ℝ (fderiv ℝ (f i)) 0 v v := by + intro v hv hl + have hortho : ∀ i, inner ℝ v (p i-r)=0 := by + intro i + rw [real_inner_comm] + simpa only [hfirst,innerSL_apply_apply] using hl i + have H := hslack v hv hortho + simp only [hsecond,mul_sub,Finset.sum_sub_distrib,←Finset.sum_mul,hsum,one_mul] + exact sub_pos.mpr H + obtain ⟨b,hb,H⟩ := finite_smooth_transverse_growth f hf (fun i => by simp [f]) w hw hsum hmean hpos + refine ⟨b,hb,?_⟩ + filter_upwards [H] with h hh + obtain ⟨i,hi⟩ := hh + refine ⟨i,?_⟩ + simpa only [f,r,div_eq_mul_inv,mul_comm] using hi + +lemma WeakMTW.finite_branch_cost_growth (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 0 cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) : + ∃ b>0, ∀ᶠ h : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 0, ∃ i, + b*‖h‖^2≤ + (G (riemannianExp x h,riemannianExp x (T • (∑ j, w j • p j)))- + G (x,riemannianExp x (T • (∑ j, w j • p j))))/T- + (normalCost x (s • p i) h-normalCost x (s • p i) 0)/s := by + let r := ∑ j, w j • p j + let g := fun h : TangentSpace 𝓘(ℝ,Model n) x => G (riemannianExp x h,riemannianExp x (T • r)) + have hrh : r ∈ convexHull ℝ (range p) := + (convex_convexHull ℝ (range p)).sum_mem (fun i _ => (hw i).le) hsum + (fun i _ => subset_convexHull ℝ (range p) (mem_range_self i)) + obtain ⟨hg,hgfirst,hglim⟩ := cost_branch_normal_jets hT hG hagree (fun t ht => hID t ht r hrh) + have hg2 : ContDiffAt ℝ 2 g 0 := hg.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have H := finite_normal_branch_envelope_growth p w hw hsum hmin hT (hT.trans hTs) hs g hg2 hgfirst + (fun ξ hξ ho => hmtw.branch_transverse_slack_strict p w hw hsum hmin hT hTs hs hID hξ ho (hglim ξ)) + simpa only [g,r,riemannianExp_zero] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchJetSecond.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchJetSecond.lean new file mode 100644 index 0000000000000000000000000000000000000000..82a7a76380e48cd482a6b8d21a941947da836087 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/BranchJetSecond.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.LocalBranchJetBound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section BranchJetSecond +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_branch_jet_bound_second (hmtw:WeakMTW (n := n) (M := M)) + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {a:M} + {r:TangentSpace 𝓘(ℝ,Model n) a} (hr:r∈minimizingVectors a) + {G:M×M → ℝ} + (hG:ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G (a,riemannianExp a r)) + (hagree:∀ᶠ z in 𝓝 (⟨a,r⟩:TangentBundle 𝓘(ℝ,Model n) M), + z.2∈injectivityDomain z.1 → (fun q:M×M=>cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) + {l:ℝ} (hl:1 < l) : + let d:=extChartAt 𝓘(ℝ,Model n) a + ∃ U:Set ((Model n×M)×ℝ),U∈𝓝 ((d a,riemannianExp a r),l) ∧ ∃ C≥0, + ∀q∈U,∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀φ:ℝ → ℝ,StrictMono φ → ContDiffAt ℝ 2 φ (uv.2 (d.symm q.1.1)) → + HasDerivAt φ q.2 (uv.2 (d.symm q.1.1)) → + iteratedDeriv 2 φ (uv.2 (d.symm q.1.1)) ≤ 0 → + ∀H:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀w,0 ≤ H w w) → + HasLowerSecondTaylor (fun w=>φ (uv.2 (d.symm (q.1.1+w)))+G (d.symm (q.1.1+w),q.1.2)) 0 H → + ∀w,H w w ≤ C*‖w‖^2 := by + dsimp only + obtain ⟨U,hU,C,hC,HC⟩:=hmtw.exists_local_branch_jet_bound hlam hcap hr hG hagree hl + refine ⟨U,hU,C,hC,?_⟩ + intro q hq x0 uv huv φ hmono hφ hd hconc H hH hjet w + let vu:=reverseNormalizedPair x0 uv + let ψ:=fun s:ℝ=>φ (uv.2 x0+s) + have heq (y:M):uv.2 x0+vu.1 y=uv.2 y := by + change uv.2 x0+(uv.2 y+-uv.2 x0)=uv.2 y + ring + have hψ:ContDiffAt ℝ 2 ψ (vu.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) := + ((heq _).symm ▸ hφ).comp _ (contDiffAt_const.add contDiffAt_id) + have hdψ:HasDerivAt ψ q.2 (vu.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) := by + have hd':HasDerivAt φ q.2 (uv.2 x0+vu.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) := (heq _).symm ▸ hd + have HH:=hd'.comp _ ((hasDerivAt_id _).const_add (uv.2 x0)) + simpa only [mul_one,Function.comp_def,ψ] using HH + have hcψ:iteratedDeriv 2 ψ (vu.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) ≤ 0 := by + dsimp only [ψ] + rw [iteratedDeriv_comp_const_add] + dsimp only + rw [heq] + exact hconc + apply HC q hq x0 vu (densityDualClass_reverse hlam huv) ψ + (fun _ _ h=>hmono (by linarith)) hψ hdψ hcψ H hH _ w + simpa only [ψ,heq] using hjet + +end BranchJetSecond +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostGradient.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..cff7574db87cc3fe3148af7c68fa9134bd247487 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostGradient.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SplitMinimizingAction +import OAI.Analysis.BiholderTransport.CostGeometry.CostSmooth +import OAI.Analysis.BiholderTransport.Coordinates.ManifoldMinimum + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cost_start_gradient_of_injectivityDomain {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) : + HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (fun y => cost y (riemannianExp x p)) + x (innerSL ℝ (-p)) := by + have hpmin := injectivityDomain_subset_minimizingVectors x hp + obtain ⟨δ,hδ,H⟩ := exists_local_spray_cost_start_gradient (E := Model n) x + have hnear : ∀ᶠ s : ℝ in 𝓝 0, riemannianExp x (s • p) ∈ Metric.ball x δ := by + have ht : ContinuousAt (fun s : ℝ => riemannianExp x (s • p)) 0 := + ((continuous_riemannianExp x).comp (continuous_id.smul continuous_const)).continuousAt + have hx : riemannianExp x ((0:ℝ) • p) ∈ Metric.ball x δ := by simpa using hδ + exact ht.preimage_mem_nhds (Metric.isOpen_ball.mem_nhds hx) + have hsmall : ∀ᶠ s : ℝ in 𝓝[>] 0, + riemannianExp x (s • p) ∈ Metric.ball x δ ∧ s<1 ∧ 0 cost y (riemannianExp x (s • p))/s+(1-s)*‖p‖^2/2 + have hG : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) G x (innerSL ℝ (-p)) := by + have HH := (hD.const_smul (s⁻¹)).add + (hasMFDerivAt_const (I := 𝓘(ℝ,Model n)) (I' := 𝓘(ℝ,ℝ)) ((1-s)*‖p‖^2/2) x) + have hGG : G =ᶠ[𝓝 x] + ((s⁻¹ • fun y => dist y (riemannianExp x (s • p))^2/2) + fun _ => (1-s)*‖p‖^2/2) := by + apply Filter.Eventually.of_forall + intro y + dsimp [G,cost] + simp only [div_eq_mul_inv] + ring + apply (HH.congr_of_eventuallyEq hGG).congr_mfderiv + have heq : (s⁻¹ • innerSL ℝ ((-s) • p)) + 0 = innerSL ℝ (-p) := by + ext v + simp only [_root_.smul_apply,add_zero,innerSL_apply_apply,real_inner_smul_left,inner_neg_left,smul_eq_mul] + field_simp [ne_of_gt hs] + convert! heq using 1 + have hcost := cost_contMDiffAt_of_injectivityDomain (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hF : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) + (fun y => cost y (riemannianExp x p)) x := + ((hcost.comp x (contMDiffAt_id.prodMk contMDiffAt_const)).mdifferentiableAt (by simp)) + have heq := upper_contact_mfderiv hF hG.mdifferentiableAt + (Filter.Eventually.of_forall (minimizing_split_upper_support hpmin hs hs1)) + (minimizing_split_contact hpmin hs hs1).symm + exact hF.hasMFDerivAt.congr_mfderiv (heq.trans hG.mfderiv) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostSmooth.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostSmooth.lean new file mode 100644 index 0000000000000000000000000000000000000000..63c8427ca8056abfb9643410de518eccfba51713 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CostSmooth.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TotalInjectivity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cost_contMDiffAt_of_injectivityDomain (z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z.2 ∈ injectivityDomain z.1) : + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (z.1,riemannianExp z.1 z.2) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) z + let c := extChartAt 𝓘(ℝ,Model n) z.1 + let d := extChartAt 𝓘(ℝ,Model n) (riemannianExp z.1 z.2) + let y : M×M := (z.1,riemannianExp z.1 z.2) + let J : M×M → Model n × Model n := fun q => (c q.1,d q.2) + obtain ⟨e,he,hze,_,hend,_,hei⟩ := exists_joint_exp_inverse z hz + have hχz := χ.map_source (mem_extChartAt_source z) + have hχinv : χ.symm (χ z)=z := χ.left_inv (mem_extChartAt_source z) + have hJy : J y = e (χ z) := by + rw [he] + change (c z.1,d (riemannianExp z.1 z.2)) = + ((χ z).1,d (riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2)) + rw [hχinv] + rfl + have hyT : J y ∈ e.target := hJy ▸ e.map_source hze + have hiy : e.symm (J y)=χ z := by rw [hJy,e.left_inv hze] + have hJ : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,Model n × Model n) ∞ J y := by + have hc₀ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ c y.1 := contMDiffAt_extChartAt + have hd₀ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ d y.2 := contMDiffAt_extChartAt + exact (hc₀.comp y contMDiffAt_fst).prodMk_space (hd₀.comp y contMDiffAt_snd) + have hi := (hei.contDiffAt (e.open_target.mem_nhds hyT)).contMDiffAt.comp y hJ + have hc : ContMDiffAt 𝓘(ℝ,Model n × Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ χ.symm + (e.symm (J y)) := + (contMDiffOn_extChartAt_symm z).contMDiffAt ((isOpen_extChartAt_target z).mem_nhds (hiy ▸ hχz)) + let P : M×M → TangentBundle 𝓘(ℝ,Model n) M := fun q => χ.symm (e.symm (J q)) + have hP : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ P y := + hc.comp y hi + have hPy : P y = z := by dsimp [P]; rw [hiy,hχinv] + have hmin : ∀ᶠ q in 𝓝 y, (P q).2 ∈ minimizingVectors (P q).1 := by + have hC : {r : TangentBundle 𝓘(ℝ,Model n) M | r.2 ∈ minimizingVectors r.1} ∈ 𝓝 (P y) := by + rw [hPy] + exact mem_interior_iff_mem_nhds.mp (interior_total_minimizingVectors z hz) + exact hP.continuousAt.preimage_mem_nhds hC + have hJnear : ∀ᶠ q in 𝓝 y, J q ∈ e.target := hJ.continuousAt.preimage_mem_nhds (e.open_target.mem_nhds hyT) + have hcharts : ∀ᶠ q : M×M in 𝓝 y, q.1 ∈ c.source ∧ q.2 ∈ d.source := by + have hcnear : ∀ᶠ q : M×M in 𝓝 y, q.1 ∈ c.source := + (continuous_fst : Continuous (fun q : M×M => q.1)).continuousAt.preimage_mem_nhds + (show c.source ∈ 𝓝 y.1 from extChartAt_source_mem_nhds z.1) + have hdnear : ∀ᶠ q : M×M in 𝓝 y, q.2 ∈ d.source := + (continuous_snd : Continuous (fun q : M×M => q.2)).continuousAt.preimage_mem_nhds + (show d.source ∈ 𝓝 y.2 from extChartAt_source_mem_nhds (riemannianExp z.1 z.2)) + exact hcnear.and hdnear + apply ((contMDiff_tangent_energy (P y)).comp y hP).congr_of_eventuallyEq + filter_upwards [hmin,hJnear,hcharts] with q hqmin hqJ hqc + have his := e.map_target hqJ + have hmap := e.right_inv hqJ + rw [he] at hmap + have hfirst : (P q).1=q.1 := by + change (χ.symm (e.symm (J q))).1=q.1 + rw [tangent_chart_symm_base] + have hf := congrArg Prod.fst hmap + change (e.symm (J q)).1=c q.1 at hf + rw [hf,c.left_inv hqc.1] + have hlast : riemannianExp (P q).1 (P q).2=q.2 := by + apply d.injOn (hend _ his) hqc.2 + exact congrArg Prod.snd hmap + change dist q.1 q.2^2/2 = ‖(P q).2‖^2/2 + change dist (P q).1 (riemannianExp (P q).1 (P q).2)=‖(P q).2‖ at hqmin + calc + dist q.1 q.2^2/2 = dist (P q).1 (riemannianExp (P q).1 (P q).2)^2/2 := by rw [hlast,hfirst] + _ = _ := by rw [hqmin] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/CrossingUniform.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CrossingUniform.lean new file mode 100644 index 0000000000000000000000000000000000000000..0c14e8af1433e5c318ab77f7ac70c0df75b9ece7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CrossingUniform.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ExpLocalBounds +import OAI.Analysis.BiholderTransport.Coordinates.RadialFactor +import OAI.Analysis.BiholderTransport.LinearAlgebra.PositiveSingular + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CrossingUniform +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma compact_bundle_radialCrossingValue_bounds + {K : Set (TangentBundle 𝓘(ℝ,Model n) M)} (hK : IsCompact K) + (hI : ∀ z∈K, z.2∈injectivityDomain z.1) : + ∃ c C : ℝ, 0.mpr hb.2] + rw [inv_mul_le_iff₀ (sq_pos_of_pos hu)] + exact hs + · have hs : l^2*‖L v‖^2≤‖v‖^2 := by + nlinarith [sq_le_sq₀ (mul_nonneg hl.le (norm_nonneg (L v))) (norm_nonneg v) |>.mpr hb.1] + rw [le_inv_mul_iff₀ (sq_pos_of_pos hl)] + exact hs + +end CrossingUniform +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurveAdvance.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurveAdvance.lean new file mode 100644 index 0000000000000000000000000000000000000000..b8ac50c0c7dc18269ecede73616def1fd945eecc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurveAdvance.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHull + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma curve_deriv_eq_active_pairing {v : M → ℝ} (hv : Continuous v) + {γ : ℝ → M} {t d : ℝ} + (hγ : MDifferentiableAt 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t) + (hd : HasDerivAt (fun s => cTransform v (γ s)) d t) + {p : TangentSpace 𝓘(ℝ,Model n) (γ t)} (hp : p∈activeLogs v (γ t)) : + d=inner ℝ p (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t 1) := by + have hID := contracted_minimizer_mem_injectivityDomain hp.1 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let f := fun s : ℝ => cTransform v (γ s)+2*cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p)) + have hmin : IsLocalMin f t := by + apply Filter.Eventually.of_forall + intro s + have H := active_split_lower_support hv hp.1 hp.2 + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (γ s) + dsimp [f] + linarith + have hc : HasDerivAt + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) + (inner ℝ (-((1/2:ℝ) • p)) (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t 1)) t := by + let D : ℝ →L[ℝ] ℝ := (innerSL ℝ (-((1/2:ℝ) • p))).comp + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t) + have hcomp : HasMFDerivAt 𝓘(ℝ,ℝ) 𝓘(ℝ,ℝ) + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) t D := + (cost_start_gradient_of_injectivityDomain hID).comp t hγ.hasMFDerivAt + have hfd : HasFDerivAt + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) D t := + hcomp.hasFDerivAt + exact hfd.hasDerivAt + have H := hmin.hasDerivAt_eq_zero (hd.add (hc.const_mul (2:ℝ))) + simp only [inner_neg_left,real_inner_smul_left] at H + linarith only [H] + +lemma curve_neg_cost_deriv_eq_pairing {γ : ℝ → M} {t d : ℝ} + (hγ : MDifferentiableAt 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t) + {p : TangentSpace 𝓘(ℝ,Model n) (γ t)} (hp : p∈minimizingVectors (γ t)) + (hd : HasDerivAt (fun s => -cost (γ s) (riemannianExp (γ t) p)) d t) : + d=inner ℝ p (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t 1) := by + have hID := contracted_minimizer_mem_injectivityDomain hp + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + let f := fun s : ℝ => -cost (γ s) (riemannianExp (γ t) p)+ + 2*cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p)) + have hmin : IsLocalMin f t := by + apply Filter.Eventually.of_forall + intro s + have H := minimizing_split_upper_support hp + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) (γ s) + have H0 := minimizing_split_contact hp + (show (0:ℝ)<1/2 by norm_num) (show (1/2:ℝ)<1 by norm_num) + dsimp [f] + linarith only [H,H0] + have hc : HasDerivAt + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) + (inner ℝ (-((1/2:ℝ) • p)) (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t 1)) t := by + let D : ℝ →L[ℝ] ℝ := (innerSL ℝ (-((1/2:ℝ) • p))).comp + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t) + have hcomp : HasMFDerivAt 𝓘(ℝ,ℝ) 𝓘(ℝ,ℝ) + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) t D := + (cost_start_gradient_of_injectivityDomain hID).comp t hγ.hasMFDerivAt + have hfd : HasFDerivAt + (fun s : ℝ => cost (γ s) (riemannianExp (γ t) ((1/2:ℝ) • p))) D t := + hcomp.hasFDerivAt + exact hfd.hasDerivAt + have H := hmin.hasDerivAt_eq_zero (hd.add (hc.const_mul (2:ℝ))) + simp only [inner_neg_left,real_inner_smul_left] at H + linarith only [H] + +lemma spray_neg_cost_deriv_le {z : TangentBundle 𝓘(ℝ,Model n) M} {t d : ℝ} {y : M} + (hd : HasDerivAt (fun s => -cost (sprayFlow s z).1 y) d t) : + d ≤ dist (sprayFlow t z).1 y*‖z.2‖ := by + obtain ⟨p,hp,he⟩ := exists_minimizing_vector (n := n) (sprayFlow t z).1 y + have hproj := hasMFDerivAt_spray_projection ((sprayFlow_curve z).isMIntegralCurveAt t) + have H := curve_neg_cost_deriv_eq_pairing hproj.mdifferentiableAt hp (by simpa only [he] using hd) + have hvel : mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) (fun s => (sprayFlow s z).1) t (1:ℝ)= + (sprayFlow t z).2 := spray_velocity_eq_mfderiv ((sprayFlow_curve z).isMIntegralCurveAt t) + have H' : d=inner ℝ p (sprayFlow t z).2 := + H.trans (congrArg (fun q => inner ℝ p q) hvel) + rw [H'] + have hn : dist (sprayFlow t z).1 y=‖p‖ := by + change dist (sprayFlow t z).1 (riemannianExp (sprayFlow t z).1 p)=‖p‖ at hp + rwa [he] at hp + rw [hn] + exact (real_inner_le_norm _ _).trans_eq (by rw [sprayFlow_speed]) + +lemma curve_deriv_le_active_norm {v : M → ℝ} (hv : Continuous v) + {γ : ℝ → M} {t d : ℝ} + (hγ : MDifferentiableAt 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t) + (hd : HasDerivAt (fun s => cTransform v (γ s)) d t) + {p : TangentSpace 𝓘(ℝ,Model n) (γ t)} (hp : p∈activeLogs v (γ t)) : + d ≤ ‖p‖*‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) γ t 1‖ := by + rw [curve_deriv_eq_active_pairing hv hγ hd hp] + exact real_inner_le_norm _ _ + +lemma spray_deriv_le_active_norm {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} {t d : ℝ} + (hd : HasDerivAt (fun s => cTransform v (sprayFlow s z).1) d t) + {p : TangentSpace 𝓘(ℝ,Model n) (sprayFlow t z).1} + (hp : p∈activeLogs v (sprayFlow t z).1) : d ≤ ‖p‖*‖z.2‖ := by + have hproj := hasMFDerivAt_spray_projection ((sprayFlow_curve z).isMIntegralCurveAt t) + have H := curve_deriv_le_active_norm hv hproj.mdifferentiableAt hd hp + have hvel : mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) (fun s => (sprayFlow s z).1) t (1:ℝ)= + (sprayFlow t z).2 := spray_velocity_eq_mfderiv ((sprayFlow_curve z).isMIntegralCurveAt t) + exact H.trans_eq (congrArg (fun q => ‖p‖*‖q‖) hvel |>.trans (by rw [sprayFlow_speed])) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurvedQuadratic.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurvedQuadratic.lean new file mode 100644 index 0000000000000000000000000000000000000000..5938a5320463c1a7b9e25f63a2091cd0bb27c75c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/CurvedQuadratic.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ContDiffQuadraticUpper + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma contDiffAt_curved_quadratic_upper {Q : E → ℝ} {p e : E} + (hQ : ContDiffAt ℝ 2 Q p) (hQ0 : Q p=0) + (hmin : ∀ᶠ s : ℝ in 𝓝 0, 0≤Q (p+s • e)) : + ∃ eps C : ℝ, 0 p+s • e) e 0 := by + convert! (hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const e) using 1 + simp + have hQ' : HasFDerivAt Q (fderiv ℝ Q p) (p+(0:ℝ) • e) := by + simpa only [zero_smul,add_zero] using (hQ.differentiableAt (by norm_num)).hasFDerivAt + have hlocal : IsLocalMin (fun s : ℝ => Q (p+s • e)) 0 := by + change ∀ᶠ s : ℝ in 𝓝 0, Q (p+(0:ℝ) • e) ≤ Q (p+s • e) + simpa only [zero_smul,add_zero,hQ0] using hmin + have hderivzero : fderiv ℝ Q p e=0 := + hlocal.hasDerivAt_eq_zero (hQ'.comp_hasDerivAt (f := fun s : ℝ => p+s • e) 0 hl) + let L : ℝ → E := fun s => (1-s^2) • (p+s • e) + have hL0 : L 0=p := by simp [L] + have hL : HasDerivAt L e 0 := by + convert! ((hasDerivAt_const (0:ℝ) (1:ℝ)).sub ((hasDerivAt_id (0:ℝ)).pow 2)).smul hl using 1 + simp + have hLc : ContDiffAt ℝ 2 L 0 := by dsimp [L]; fun_prop + have hQc : ContDiffAt ℝ 2 (Q ∘ L) 0 := by + have hQ' : ContDiffAt ℝ 2 Q (L 0) := by rwa [hL0] + exact hQ'.comp 0 hLc + have hqd : HasDerivAt (Q ∘ L) 0 0 := by + have hd : HasFDerivAt Q (fderiv ℝ Q p) (L 0) := by + simpa only [hL0] using (hQ.differentiableAt (by norm_num)).hasFDerivAt + simpa only [hderivzero,Function.comp_def] using hd.comp_hasDerivAt (f := L) 0 hL + exact contDiffAt_quadratic_upper (f := Q ∘ L) hQc (by change Q (L 0)=0; rw [hL0,hQ0]) hqd.deriv +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/DividedAction.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/DividedAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..2f96830257c7a8ba18c110437a0d8de91beb3132 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/DividedAction.lean @@ -0,0 +1,94 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {M : Type*} [PseudoMetricSpace M] + +lemma squared_dist_divided_action_le (x y z : M) {s : ℝ} (hs : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma divided_cost_difference_pullback {z : M} {p : TangentSpace 𝓘(ℝ,Model n) z} + {t : ℝ} {g : E → TangentSpace 𝓘(ℝ,Model n) z} {a : E} + (hp : p∈injectivityDomain z) (htp : t • p∈injectivityDomain z) (ht : t≠0) + (hg : ContDiffAt ℝ 2 g a) (hg0 : g a=0) (k : E) : + fderiv ℝ (fderiv ℝ (fun b => + normalCost z (t • p) (g b)/t-normalCost z p (g b))) a k k = + hessianValue z (t • p) (fderiv ℝ g a k)/t- + hessianValue z p (fderiv ℝ g a k) := by + let F := fun v => t⁻¹*normalCost z (t • p) v-normalCost z p v + have hA := (normalCost_contDiffAt htp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hB := (normalCost_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hF : ContDiffAt ℝ 2 F 0 := (contDiffAt_const.mul hA).sub hB + have hzero : fderiv ℝ F 0=0 := by + ext v + rw [fderiv_fun_sub ((hA.differentiableAt (by norm_num)).const_mul _) + (hB.differentiableAt (by norm_num))] + change (fderiv ℝ (t⁻¹ • normalCost z (t • p)) 0) v- + fderiv ℝ (normalCost z p) 0 v=0 + rw [fderiv_const_smul_field] + simp only [Pi.smul_apply,smul_apply,smul_eq_mul, + normalCost_fderiv_zero htp,normalCost_fderiv_zero hp,real_inner_smul_left] + field_simp [ht] + ring + have HH := second_fderiv_comp_stationary (g := g) + (by simpa only [hg0] using hF) hg (by simpa only [hg0] using hzero) k k + rw [hg0,second_fderiv_sub (contDiffAt_const.mul hA) hB, + second_fderiv_const_mul] at HH + rw [hessianValue_eq_normalHessian htp,hessianValue_eq_normalHessian hp] + simpa only [F,normalHessian,div_eq_mul_inv,mul_comm] using HH +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/ExactTemplateCurvature.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ExactTemplateCurvature.lean new file mode 100644 index 0000000000000000000000000000000000000000..b0cec835093660820d5b840700b377c359d22479 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ExactTemplateCurvature.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.MiddleExclusion +import OAI.Analysis.BiholderTransport.CostGeometry.OuterCurvature + +namespace OAI + +noncomputable section +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma centerTemplate_deriv_polynomial (s:ℝ) : + deriv centerTemplate s= -(centerGamma/2)*(1-(centerTemplate s)^2) := by + rw [(hasDerivAt_centerTemplate s).deriv] + unfold centerTemplate + have hd : 1+Real.exp (-centerGamma*(s-5/8)) ≠ 0 := ne_of_gt (by positivity) + field_simp + ring + +lemma centerTemplate_second (s:ℝ) : + iteratedDeriv 2 centerTemplate s=centerGamma*centerTemplate s*deriv centerTemplate s := by + have H : deriv centerTemplate=(fun s=> -(centerGamma/2)*(1-(centerTemplate s)^2)) := + funext centerTemplate_deriv_polynomial + have HD:=(((hasDerivAt_centerTemplate s).pow 2).const_sub 1).const_mul (-(centerGamma/2)) + have HD' : HasDerivAt (fun x=> -(centerGamma/2)*(1-(centerTemplate x)^2)) + (centerGamma*centerTemplate s*deriv centerTemplate s) s := by + convert! HD using 1 + rw [(hasDerivAt_centerTemplate s).deriv] + norm_num + ring + simp only [iteratedDeriv_succ,iteratedDeriv_zero] + calc + deriv (deriv centerTemplate) s = deriv (fun x=> -(centerGamma/2)*(1-(centerTemplate x)^2)) s := + congrArg (fun f=>deriv f s) H + _ = _ := HD'.deriv + +lemma centerTemplate_deriv_bound (s:ℝ) : + 0 < -deriv centerTemplate s ∧ -deriv centerTemplate s ≤ centerGamma/2 := by + refine ⟨neg_pos.mpr (centerTemplate_deriv_neg s),?_⟩ + rw [centerTemplate_deriv_polynomial] + nlinarith only [centerGamma_pos,sq_nonneg (centerTemplate s)] + +lemma centerTemplate_curvature {s:ℝ} (hs:0 < centerTemplate s) : + iteratedDeriv 2 centerTemplate s < 0 ∧ + -iteratedDeriv 2 centerTemplate s ≤ centerGamma*(-deriv centerTemplate s) ∧ + -iteratedDeriv 2 centerTemplate s ≤ centerGamma^2/2 := by + rw [centerTemplate_second] + have hd:=centerTemplate_deriv_neg s + have hb:=(centerTemplate_bounds s).2 + have hu:=(centerTemplate_deriv_bound s).2 + have H : -(centerGamma*centerTemplate s*deriv centerTemplate s) ≤ + centerGamma*(-deriv centerTemplate s) := by + nlinarith only [mul_nonneg centerGamma_pos.le (neg_nonneg.mpr hd.le),hb] + refine ⟨mul_neg_of_pos_of_neg (mul_pos centerGamma_pos hs) hd,H,?_⟩ + nlinarith only [H,mul_le_mul_of_nonneg_left hu centerGamma_pos.le] + +lemma outerTemplate_eq_profile (M K eta:ℝ) : outerTemplate M K eta=outerProfile K M eta := by + funext s + simp only [outerTemplate,outerPrimitive,outerProfile,outerJ,templateEps_eq] + congr 2 + norm_num + +lemma exact_outer_curvature {M K eta s:ℝ} (hK:1 ≤ K) (hM:2 ≤ M) (heta:0 < eta) + (hs:-2*eta ≤ s) (hs':s ≤ 1-eta) (hcap:outerTemplate M K eta s ≤ M) : + 0 < deriv (outerTemplate M K eta) s ∧ + iteratedDeriv 2 (outerTemplate M K eta) s ≤ -K := by + rw [outerTemplate_eq_profile] at hcap ⊢ + exact outerProfile_curvature hK hM heta hs hs' hcap + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutLower.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutLower.lean new file mode 100644 index 0000000000000000000000000000000000000000..0afff1ddb35cdf17957a5442f1baac980a996981 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutLower.lean @@ -0,0 +1,269 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.RadialNull +import OAI.Analysis.BiholderTransport.Regularity.TrialBlowup +import OAI.Analysis.BiholderTransport.LinearAlgebra.BranchHessian + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.contracted_segment_concaveOn (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {p e xi : TangentSpace 𝓘(ℝ,Model n) x} {a b r : ℝ} + (hseg : ∀ s ∈ Icc a b, p+s • e ∈ minimizingVectors x) + (hr : 0 hessianValue x (r • (p+s • e)) xi) := by + have heq (s : ℝ) : r • p+s • (r • e)=r • (p+s • e) := by + simp only [smul_add,smul_smul,mul_comm] + have H := hmtw.transverse_concaveOn_injectivityDomain x (r • p) xi (r • e) (convex_Icc a b) + (fun s hs => by rw [heq]; exact contracted_minimizer_mem_injectivityDomain (hseg s hs) hr hr1) + (by simp only [real_inner_smul_right,hortho,mul_zero]) + simpa only [heq] using H + +lemma WeakMTW.firstcut_transverse_lower (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {p e xi : TangentSpace 𝓘(ℝ,Model n) x} {a b : ℝ} + (ha : a<0) (hb : 0 extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+a • e)) (riemannianExp x v)) (p+a • e))) + (hright : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+b • e)) (riemannianExp x v)) (p+b • e))) + (hortho : inner ℝ xi e=0) : + ∃ L : ℝ, ∀ᶠ r : ℝ in 𝓝[<] 1, ∀ s ∈ Icc a b, + L≤hessianValue x (r • (p+s • e)) xi := by + have hab : a≤b := (ha.trans hb).le + obtain ⟨C,hC⟩ := nonconjugate_inward_hessian_bounded (hseg a ⟨le_rfl,hab⟩) hleft xi + obtain ⟨D,hD⟩ := nonconjugate_inward_hessian_bounded (hseg b ⟨hab,le_rfl⟩) hright xi + refine ⟨min (-C) (-D),?_⟩ + filter_upwards [hC,hD, + (eventually_gt_nhds (show (0:ℝ)<1 by norm_num)).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with r hrC hrD hr0 hr1 + intro s hs + have H := (hmtw.contracted_segment_concaveOn hseg hr0 hr1 hortho).min_le_of_mem_Icc + (show a ∈ Icc a b from ⟨le_rfl,hab⟩) (show b ∈ Icc a b from ⟨hab,le_rfl⟩) hs + exact (min_le_min (neg_le_of_abs_le hrC) (neg_le_of_abs_le hrD)).trans H + +lemma WeakMTW.firstcut_kernel_transverse_orthogonal (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {p e k : TangentSpace 𝓘(ℝ,Model n) x} {a b : ℝ} + (ha : a<0) (hb : 0 extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+a • e)) (riemannianExp x v)) (p+a • e))) + (hright : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+b • e)) (riemannianExp x v)) (p+b • e))) + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) + (xi : TangentSpace 𝓘(ℝ,Model n) x) (hortho : inner ℝ xi e=0) : inner ℝ xi k=0 := by + by_contra hpair + have hp : p ∈ minimizingVectors x := by simpa using hseg 0 ⟨ha.le,hb.le⟩ + have hneg := conjugate_radial_hessian_tendsto_atBot hp hk + (by rwa [real_inner_comm] : inner ℝ k xi≠0) + obtain ⟨L,hL⟩ := hmtw.firstcut_transverse_lower ha hb hseg hleft hright hortho + have hlo : ∀ᶠ r : ℝ in 𝓝[<] 1, L≤hessianValue x (r • p) xi := + hL.mono (fun r hr => by simpa using hr 0 ⟨ha.le,hb.le⟩) + obtain ⟨r,hr,hrr⟩ := (hlo.and (hneg.eventually (eventually_lt_atBot L))).exists + exact (not_lt_of_ge hr) hrr +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.firstcut_radial_lower (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {p e : TangentSpace 𝓘(ℝ,Model n) x} {b : ℝ} + (hb : 0 extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+b • e)) (riemannianExp x v)) (p+b • e))) + (hortho : inner ℝ p e=0) : + ∃ D : ℝ, ∀ᶠ r : ℝ in 𝓝[<] 1, ∀ s ∈ Icc 0 b, + -D * s ≤ s^2 * hessianValue x (r • (p+s • e)) e := by + have hp : p ∈ minimizingVectors x := by simpa using hseg 0 ⟨le_rfl,hb.le⟩ + obtain ⟨C,hC⟩ := nonconjugate_inward_hessian_bounded (hseg b ⟨hb.le,le_rfl⟩) hright p + let D := (C+‖p‖^2)/b + refine ⟨D,?_⟩ + filter_upwards [hC, + (eventually_gt_nhds (show (0:ℝ)<1 by norm_num)).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with r hrC hr0 hr1 + have hconc := hmtw.contracted_segment_concaveOn hseg hr0 hr1 hortho + have hconv := hconc.neg.add_const (‖p‖^2) + have hrad0 := hessianValue_contracted_radial hr0.ne' + (contracted_minimizer_mem_injectivityDomain hp hr0 hr1) + have hz : -hessianValue x (r • (p+(0:ℝ) • e)) p+‖p‖^2=0 := by + simp only [zero_smul,add_zero,hrad0,neg_add_cancel] + have hend : -hessianValue x (r • (p+b • e)) p+‖p‖^2≤D*b := by + have hd : D*b=C+‖p‖^2 := div_mul_cancel₀ _ hb.ne' + rw [hd] + linarith [neg_le_of_abs_le hrC] + intro s hs + have hlin := convex_linear_bound hb hconv hz hend hs + have hrad := hessianValue_transverse_radial_identity hr0.ne' + (contracted_minimizer_mem_injectivityDomain (hseg s hs) hr0 hr1) hortho + dsimp only [Pi.neg_apply,Pi.add_apply] at hlin + nlinarith [mul_nonneg (sq_nonneg s) (sq_nonneg ‖e‖)] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutSegment.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutSegment.lean new file mode 100644 index 0000000000000000000000000000000000000000..ec62030e42589cc493190de4be60957acf8c5feb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/FirstCutSegment.lean @@ -0,0 +1,247 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.CurvedBlowup +import OAI.Analysis.BiholderTransport.CostGeometry.FirstCutLower +import OAI.Analysis.BiholderTransport.Coordinates.KernelRadial + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma kernel_parallel_of_transverse_orthogonal_ne_zero + {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {e k : E} (he : e ≠ 0) + (hk : ∀ xi : E, inner ℝ xi e=0 → inner ℝ xi k=0) : + k=(inner ℝ k e / inner ℝ e e) • e := by + have hee : inner ℝ e e ≠ 0 := inner_self_ne_zero.mpr he + let xi := k-(inner ℝ k e / inner ℝ e e) • e + have hxi : inner ℝ xi e=0 := by + dsimp [xi] + simp only [inner_sub_left,real_inner_smul_left,div_mul_cancel₀ _ hee,sub_self] + have hxik := hk xi hxi + have hxixi : inner ℝ xi xi=0 := by + change inner ℝ xi (k-(inner ℝ k e / inner ℝ e e) • e)=0 + simp only [inner_sub_right,real_inner_smul_right,hxik,hxi,mul_zero,sub_zero] + exact sub_eq_zero.mp (inner_self_eq_zero.mp hxixi) + +lemma WeakMTW.firstcut_segment_kernel_zero (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {p e k : TangentSpace 𝓘(ℝ,Model n) x} {a b : ℝ} + (ha : a<0) (hb : 0 extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+a • e)) (riemannianExp x v)) (p+a • e))) + (hright : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (p+b • e)) (riemannianExp x v)) (p+b • e))) + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) : + k=0 := by + by_contra hk0 + have hpar := kernel_parallel_of_transverse_orthogonal_ne_zero he + (hmtw.firstcut_kernel_transverse_orthogonal ha hb hseg hleft hright hk) + have hpair : inner ℝ k e≠0 := by + intro hh + rw [hh,zero_div,zero_smul] at hpar + exact hk0 hpar + have hortho : inner ℝ p e=0 := by + have hh := exp_kernel_radial_orthogonal hk + rw [hpar,real_inner_smul_right] at hh + exact (mul_eq_zero.mp hh).resolve_left (div_ne_zero hpair (inner_self_ne_zero.mpr he)) + have hp : p ∈ minimizingVectors x := by simpa using hseg 0 ⟨ha.le,hb.le⟩ + have hnear : ∀ᶠ s : ℝ in 𝓝 0, p+s • e ∈ minimizingVectors x := by + filter_upwards [Ioo_mem_nhds ha hb] with s hs + exact hseg s ⟨hs.1.le,hs.2.le⟩ + obtain ⟨eps,B,c,heps,hc,hupper⟩ := conjugate_curved_hessian_upper hp hnear hk hpair + obtain ⟨D,hD⟩ := hmtw.firstcut_radial_lower hb + (fun s hs => hseg s ⟨ha.le.trans hs.1,hs.2⟩) hright hortho + have hcurve : Tendsto (fun s : ℝ => 1-s^2) (𝓝[>] 0) (𝓝[<] 1) := by + apply tendsto_nhdsWithin_iff.mpr + constructor + · simpa using (show ContinuousAt (fun s : ℝ => 1-s^2) 0 from by fun_prop).tendsto.mono_left nhdsWithin_le_nhds + · filter_upwards [self_mem_nhdsWithin] with s hs + change 1-s^2<1 + have hs0 : 0] 0, c≤D*s+B*s^2 := by + filter_upwards [hcurve.eventually hD,self_mem_nhdsWithin, + (eventually_lt_nhds heps).filter_mono nhdsWithin_le_nhds, + (eventually_lt_nhds hb).filter_mono nhdsWithin_le_nhds] with s hs hs0 hseps hsb + have hspos : 0 D*s+B*s^2) (𝓝[>] 0) (𝓝 0) := by + simpa using (show ContinuousAt (fun s : ℝ => D*s+B*s^2) 0 from by fun_prop).tendsto.mono_left nhdsWithin_le_nhds + have hc0 : c≤0 := le_of_tendsto_of_tendsto tendsto_const_nhds htend hpoly + exact (not_le_of_gt hc) hc0 +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/GraphOpen.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/GraphOpen.lean new file mode 100644 index 0000000000000000000000000000000000000000..ac2c38f9df8d7d00845dfcb0a8582724dfb718d7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/GraphOpen.lean @@ -0,0 +1,302 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.BranchInverse +import OAI.Analysis.BiholderTransport.Contact.ActiveContinuationLocal +import OAI.Analysis.BiholderTransport.Contact.SubgradientUpper + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.local_projection_surjective (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈normalSubdifferential (n := n) (cTransform v) x) + {t : ℝ} (ht : 0 tangentScale t⁻¹ (P q) + have hQ : ContinuousAt Q (x,y₀) := + (contMDiff_tangentScale (E := Model n) (M := M)).continuous.continuousAt.comp + (continuousAt_const.prodMk hP.continuousAt) + have hQ0 : Q (x,y₀)=(⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + dsimp only [Q,y₀] + rw [hP0] + simp only [tangentScale,smul_smul,inv_mul_cancel₀ ht.ne',one_smul] + have hQO : ∀ᶠ q : M×M in 𝓝 (x,y₀), Q q∈O := + hQ.preimage_mem_nhds (hQ0.symm ▸ hO) + have hPID : ∀ᶠ q : M×M in 𝓝 (x,y₀), (P q).2∈injectivityDomain (P q).1 := by + have hmem : {z : TangentBundle 𝓘(ℝ,Model n) M | z.2∈injectivityDomain z.1} ∈ + 𝓝 (P (x,y₀)) := by + apply (isOpen_total_injectivityDomain (n := n) (M := M)).mem_nhds + rw [hP0] + exact htp + exact hP.continuousAt.preimage_mem_nhds hmem + have H := (hQO.and hPID).and hPinv + obtain ⟨U,hU,V,hV,hUV⟩ := mem_nhds_prod_iff.mp H + have hpH : p∈convexHull ℝ (activeLogs (n := n) v x) := + normalSubdifferential_subset_active_hull hv x hp + have hIDH : ∀ q∈convexHull ℝ (activeLogs (n := n) v x), t • q∈injectivityDomain x := + fun q hq => hID q (active_hull_subset_normalSubdifferential hv x hq) + have hmin := hmtw.active_hull_nearby_local_min hv hpH ht ht1 hIDH U hU + filter_upwards [hV,hmin] with y hy hh + obtain ⟨a,ha,hmin⟩ := hh + have hq := hUV (show (a,y)∈U ×ˢ V from ⟨ha,hy⟩) + rcases hPa : P (a,y) with ⟨b,r⟩ + change (tangentScale t⁻¹ (P (a,y))∈O ∧ + (P (a,y)).2∈injectivityDomain (P (a,y)).1) ∧ + (P (a,y)).1=a ∧ riemannianExp (P (a,y)).1 (P (a,y)).2=y at hq + rw [hPa] at hq + have hb : b=a := hq.2.1 + subst b + have hr : r∈injectivityDomain a := hq.1.2 + have hE : riemannianExp a r=y := hq.2.2 + have htr : t • (t⁻¹ • r)=r := by rw [smul_smul,mul_inv_cancel₀ ht.ne',one_smul] + refine ⟨⟨a,t⁻¹ • r⟩,?_,?_,?_⟩ + · exact hq.1.1 + · apply local_min_divided_cost_subgradient ht.ne' + · simpa only [htr] using hr + · simpa only [htr,hE] using hmin + · simpa only [htr] using hE + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/LimitIsolation.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/LimitIsolation.lean new file mode 100644 index 0000000000000000000000000000000000000000..a05f01f9f7648b7684553c14c2e4ea0b38effdff --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/LimitIsolation.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GraphCompact +import OAI.Analysis.BiholderTransport.CostGeometry.BranchActiveGrowth +import OAI.Analysis.BiholderTransport.Coordinates.CutCharacterization +import OAI.Analysis.BiholderTransport.Regularity.LimitGeometry + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.isolated_graph_fiber_at_left_limit + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {T : ℝ} (hT : 0 tangentScale T w.1) := + contMDiff_tangentScale.continuous.comp (continuous_const.prodMk continuous_subtype_val) + have hproj : Continuous (fun w : subgradientGraph (n := n) (cTransform v) => w.1.1) := + (FiberBundle.continuous_proj _ _).comp continuous_subtype_val + have hcostz : cost z.1.1 (graphProjection (cTransform v) T z)= + G (z.1.1,graphProjection (cTransform v) T z) := + hbranch.self_of_nhds (hglobal z).1 + filter_upwards [hscale.continuousAt.eventually hbranch, + hscale.continuousAt.preimage_mem_nhds (hU.mem_nhds hzU), + hproj.continuousAt.eventually hbase] with w hwG hwU hwbase he + have hcostw : cost w.1.1 (graphProjection (cTransform v) T w)= + G (w.1.1,graphProjection (cTransform v) T w) := hwG (hglobal w).1 + have hsame : w.1.1=z.1.1 := by + by_contra hn + have hlt := hwbase hn + change cTransform v z.1.1+G (z.1.1,graphProjection (cTransform v) T z)/T < + cTransform v w.1.1+G (w.1.1,graphProjection (cTransform v) T z)/T at hlt + rw [he] at hcostw + rw [←hcostz,←hcostw] at hlt + have hle := (hglobal w).2 z.1.1 + rw [he] at hle + exact (not_lt_of_ge hle) hlt + apply Subtype.ext + apply tangentScale_injective hT.ne' + exact hUinj hwU hzU (Prod.ext hsame he) + +lemma WeakMTW.injective_graphProjection_at_left_limit + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {T : ℝ} (hT : 0 t) (b := 𝓝[<] T) + · apply Filter.Eventually.frequently + filter_upwards [(eventually_gt_nhds hT).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with t ht htT + exact ⟨hinj t ⟨ht,htT⟩,surjective_graphProjection (continuous_cTransform hv) ht⟩ + · exact tendsto_id.mono_right nhdsWithin_le_nhds + intro z w he + have hconn := isPreconnected_fiber_of_mem_closure_bijective + (graphProjection (n := n) (cTransform v)) (continuous_graphProjection_family _) hclosure + (graphProjection (cTransform v) T z) + have hs : {q : subgradientGraph (n := n) (cTransform v) | graphProjection (cTransform v) T q=graphProjection (cTransform v) T z}.Subsingleton := by + apply fiber_subsingleton_of_preconnected_isolated hconn + intro q hq + obtain ⟨U,hUP,hU,hqU⟩ := mem_nhds_iff.mp (hmtw.isolated_graph_fiber_at_left_limit hv hT hT1 hinj q) + refine ⟨U,hU,hqU,?_⟩ + intro r hr + exact hUP hr.1 (hr.2.trans hq.symm) + exact hs rfl he.symm + +lemma WeakMTW.active_hull_precut_at_left_limit + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {T : ℝ} (hT : 0 hf.contDiffAt (isOpen_Ioo.mem_nhds hs) + have hdd : ∀ s ∈ Ioo l r, ContDiffAt ℝ ∞ (deriv f) s := + fun s hs => (hfd s hs).derivWithin (m := ∞) (by simp) + have hddd : ∀ s ∈ Ioo l r, ContDiffAt ℝ ∞ (deriv (deriv f)) s := + fun s hs => (hdd s hs).derivWithin (m := ∞) (by simp) + have hdz : ∀ s ∈ Ioo l r, s ≠ a → deriv (deriv f) s = 0 := by + intro s hs hsa + have hL := ((hasDerivAt_id s).sub_const a).smul + ((hdd s hs).differentiableAt (by simp)).hasDerivAt + have heq : (fun u => (u-a) • deriv f u) =ᶠ[𝓝 s] f := by + filter_upwards [isOpen_Ioo.mem_nhds hs] with u hu + exact he u hu + have H := (hL.congr_of_eventuallyEq heq.symm).unique + ((hfd s hs).differentiableAt (by simp)).hasDerivAt + simp only [one_smul,id_eq] at H + have hz : (s-a) • deriv (deriv f) s = 0 := by + have H' : deriv f s + (s-a) • deriv (deriv f) s = deriv f s := by + simpa only [add_comm] using H + exact add_eq_left.mp H' + exact (smul_eq_zero.mp hz).resolve_left (sub_ne_zero.mpr hsa) + have hdza : deriv (deriv f) a = 0 := by + have hnear : deriv (deriv f) =ᶠ[𝓝[≠] a] (fun _ => 0) := by + filter_upwards [self_mem_nhdsWithin, + Filter.Eventually.filter_mono nhdsWithin_le_nhds (isOpen_Ioo.mem_nhds ha)] with s hsa hs + exact hdz s hs hsa + exact tendsto_nhds_unique ((hddd a ha).continuousAt.mono_left nhdsWithin_le_nhds) + (tendsto_const_nhds.congr' hnear.symm) + have hdzall : ∀ s ∈ Ioo l r, deriv (deriv f) s = 0 := by + intro s hs + by_cases hsa : s = a + · simpa only [hsa] using hdza + · exact hdz s hs hsa + have hconstant : ∀ s ∈ Ioo l r, deriv f s = deriv f a := by + intro s hs + exact isOpen_Ioo.is_const_of_deriv_eq_zero (convex_Ioo l r).isPreconnected + (fun u hu => ((hdd u hu).differentiableAt (by simp)).differentiableWithinAt) hdzall hs ha + intro s hs + calc + f s = (s-a) • deriv f s := (he s hs).symm + _ = _ := by rw [hconstant s hs] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/LocalBranchJetBound.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/LocalBranchJetBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..cef74d0599d892d809b0584b0ac19e863dfaa5fe --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/LocalBranchJetBound.lean @@ -0,0 +1,138 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SmoothSupportSemibound +import OAI.Analysis.BiholderTransport.Coordinates.BranchChartBaseline +import OAI.Analysis.BiholderTransport.Coordinates.BranchChartJets +import OAI.Analysis.BiholderTransport.Coordinates.LocalOuterJetBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section LocalBranchJetBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_branch_jet_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 0 cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) + {l:ℝ} (hl : 1 fun w:Model n => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,y) + ∃ U : Set ((Model n×M)×ℝ), + U∈𝓝 ((extChartAt 𝓘(ℝ,Model n) a a,riemannianExp a r),l) ∧ ∃ C≥0, + ∀ q∈U,∀ (x0:M) (uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ φ:ℝ → ℝ,StrictMono φ → + ContDiffAt ℝ 2 φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) → + HasDerivAt φ q.2 (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1)) → + iteratedDeriv 2 φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm q.1.1))≤0 → + ∀ H:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀ d,0≤H d d) → + HasLowerSecondTaylor (fun h => + φ (uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm (q.1.1+h)))+c q.1.2 (q.1.1+h)) 0 H → + ∀ d,H d d≤C*‖d‖^2 := by + dsimp only + let z := extChartAt 𝓘(ℝ,Model n) a a + let b := riemannianExp a r + let q0 : (Model n×M)×ℝ := ((z,b),l) + let c := fun y:M => fun w:Model n => G ((extChartAt 𝓘(ℝ,Model n) a).symm w,y) + obtain ⟨hc,L,hcD,hpreg,m,hm,Hm⟩ := exists_branch_chart_baseline hr hG hagree hl + have hlp : 0 q.2⁻¹ • (-fderiv ℝ (c q.1.2) q.1.1) + have hP0 : P q0=L := by + dsimp only [P,q0,c,z,b] + rw [hcD] + ext d + simp only [smul_apply,neg_apply,smul_eq_mul,neg_mul,neg_neg] + field_simp [hlp.ne'] + have hP : ContinuousAt P q0 := + (continuousAt_snd.inv₀ hlp.ne').smul ((hD.comp (x := q0) (f := fun q : (Model n×M)×ℝ => q.1) continuousAt_fst).neg) + let J := fun q:(Model n×M)×ℝ => (q.1.1,P q) + have hJ : ContinuousAt J q0 := (continuousAt_fst.comp continuousAt_fst).prodMk hP + have hJ0 : J q0=(z,L) := by simp only [J,q0,hP0] + let Y := fun q:(Model n×M)×ℝ => coordinateBackward a (-1,q.1.1,P q) + have hY : ContinuousAt Y q0 := + ((coordinateBackward_contMDiffAt (q := (-1,z,P q0)) ha).continuousAt).comp (x := q0) + (f := fun q : (Model n×M)×ℝ => (-1,q.1.1,P q)) (continuousAt_const.prodMk hJ) + have hY0 : Y q0=coordinateBackward a (-1,z,L) := by simp only [Y,q0,hP0] + have hcost : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q:M×M => cost q.1 q.2) ((extChartAt 𝓘(ℝ,Model n) a).symm z,Y q0) := by + rw [hY0,coordinateBackward_eq_exp_chartGradient ha] + exact cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z L⟩ : TangentBundle 𝓘(ℝ,Model n) M) hpreg + have htrue := (chartCost_jet_continuous ha hcost).1.comp (x := q0) + (f := fun q : (Model n×M)×ℝ => (q.1.1,Y q)) + ((continuousAt_fst.comp continuousAt_fst).prodMk hY) + let W := fun q:(Model n×M)×ℝ => + q.2 • fderiv ℝ (fderiv ℝ (chartCost a (Y q))) q.1.1-fderiv ℝ (fderiv ℝ (c q.1.2)) q.1.1 + let : NormedAddCommGroup (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup + have hW : ContinuousAt W q0 := (continuousAt_snd.smul htrue).sub (hH.comp (x := q0) (f := fun q : (Model n×M)×ℝ => q.1) continuousAt_fst) + have hW0 (d:Model n) : m*‖d‖^2≤W q0 d d := by + dsimp only [W,q0] + rw [hY0] + exact Hm d + let U := {q:(Model n×M)×ℝ | J q∈N ∧ 0he hy) (he hx)) + +lemma outerJ_affine_integral {K M η : ℝ} (hK : 1≤K) (hη : 0<η) : + outerJ K M η (1/(128*(K+1)))-outerJ K M η 0= + M+3-1/(32768*(K+1)) := by + let h : ℝ := 1/(128*(K+1)) + have hh : 0128*(M+3)*(K+1)*z-(K+1)*z^2/2) + (128*(M+3)*(K+1)-(K+1)*s) s := by + intro s + convert! ((hasDerivAt_id s).const_mul (128*(M+3)*(K+1))).sub + ((((hasDerivAt_id s).pow 2).const_mul (K+1)).div_const 2) using 1 + simp only [id_eq] + ring + rw [intervalIntegral.integral_eq_sub_of_hasDerivAt (fun s _=>hd s) + ((continuous_const.sub (continuous_const.mul continuous_id)).intervalIntegrable _ _)] at he + have H := outerJ_add_integral K M η 0 h + have heq : 128*(M+3)*(K+1)*h-(K+1)*h^2/2- + (128*(M+3)*(K+1)*(0 : ℝ)-(K+1)*(0 : ℝ)^2/2)=M+3-1/(32768*(K+1)) := by + dsimp only [h] + field_simp [show K+1≠0 by linarith] + ring + rw [heq] at he + linarith only [H,he] + +lemma outerJ_barrier {K M η : ℝ} (hK : 1≤K) (_ : 2≤M) (hη : 0<η) : + outerJ K M η 0+M+1 < outerJ K M η (1/(128*(K+1))) := by + have H := outerJ_affine_integral hK hη (M := M) + have hh : 1/(32768*(K+1)) < (1 : ℝ) := by + apply (div_lt_iff₀ (by positivity : 0<32768*(K+1))).mpr + linarith + linarith only [H,hh] + +lemma outerProfile_forces_affine {K M η s : ℝ} (hK : 1≤K) (hM : 2≤M) (hη : 0<η) + (hs : s≤1-η) (hcap : outerProfile K M η s≤M) : s<1/(128*(K+1)) := by + rw [outerProfile_left hη hs] at hcap + by_contra hh + have HM := (outerJ_monotone hK hM hη) (le_of_not_gt hh) + have HB := outerJ_barrier hK hM hη + rw [outerJ_zero] at HB + linarith only [hcap,HM,HB] + +lemma outerProfile_derivatives_left {K M η s : ℝ} (hη : 0<η) (hs : s≤1-η) : + deriv (outerProfile K M η) s=outerW K M η s ∧ + iteratedDeriv 2 (outerProfile K M η) s=deriv (outerW K M η) s := by + have hd : ∀x∈Iic (1-η),deriv (outerProfile K M η) x=deriv (outerJ K M η) x := by + intro x hx + exact (uniqueDiffOn_Iic (1-η) x hx).eq_deriv _ + (((outerProfile_contDiff K M η).differentiable (by simp) x).hasDerivAt.hasDerivWithinAt) + ((((outerJ_contDiff K M η).differentiable (by simp) x).hasDerivAt.hasDerivWithinAt).congr + (fun y hy=>outerProfile_left hη hy) (outerProfile_left hη hx)) + have hdiff : deriv (outerJ K M η)=outerW K M η := funext (fun x=>(outerJ_hasDerivAt K M η x).deriv) + constructor + · rw [hd s hs,hdiff] + · simp only [iteratedDeriv_succ,iteratedDeriv_zero] + exact (uniqueDiffOn_Iic (1-η) s hs).eq_deriv _ + ((((contDiff_infty_iff_deriv.mp (outerProfile_contDiff K M η)).2).differentiable (by simp) s).hasDerivAt.hasDerivWithinAt) + ((((outerW_contDiff K M η).differentiable (by simp) s).hasDerivAt.hasDerivWithinAt).congr + (fun y hy=>by rw [hd y hy,hdiff]) (by rw [hd s hs,hdiff])) + +lemma outerProfile_curvature {K M η s : ℝ} (hK : 1≤K) (hM : 2≤M) (hη : 0<η) + (hs : -2 * η ≤ s) (hs' : s ≤ 1 - η) (hcap : outerProfile K M η s≤M) : + 0outerW_affine hK hη hy.1 hy.2) + have hf : deriv (fun x : ℝ=>128*(M+3)*(K+1)-(K+1)*x) s= -(K+1) := by + simp + simp only [id_eq] at hder + rw [hf] at hder + obtain ⟨H1,H2⟩ := outerProfile_derivatives_left hη hs' + rw [H1,H2,outerW_affine hK hη hs hhi.le,hder] + have hh : 1/(128*(K+1)) < 128*(M+3) := by + apply (div_lt_iff₀ (by positivity : 0<128*(K+1))).mpr + nlinarith + constructor <;> nlinarith +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/OuterNonconjugacy.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/OuterNonconjugacy.lean new file mode 100644 index 0000000000000000000000000000000000000000..746d8887b643c4b61cd840bf2ef33b1fd587cfb5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/OuterNonconjugacy.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.NormalRelativeHessianBound +import OAI.Analysis.BiholderTransport.Regularity.OuterSplitLowerTest +import OAI.Analysis.BiholderTransport.LinearAlgebra.PositiveBilinearBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OuterNonconjugacy +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.modified_outer_nonconjugate (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 0 < lam) (hcap : 0 ≤ cap) {x0 a : M} + {uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)} (huv : uv∈densityDualClass (metricVolume n) lam cap x0) + {r : TangentSpace 𝓘(ℝ,Model n) a} (hr : r∈minimizingVectors a) + {φ : ℝ → ℝ} (hmono : StrictMono φ) (hφ : ContDiffAt ℝ 2 φ (uv.1 a)) + {l : ℝ} (hd : HasDerivAt φ l (uv.1 a)) (hl : 1 < l) + (hconc : iteratedDeriv 2 φ (uv.1 a) ≤ 0) + (hmount : ∀ y : M,φ (uv.1 a)+cost a (riemannianExp a r)-cost y (riemannianExp a r) ≤ φ (uv.1 y)) : + Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp a r) (riemannianExp a v)) r) := by + have hlp : 0 < l := zero_lt_one.trans hl + have ht : 0 < l⁻¹ := inv_pos.mpr hlp + have ht1 : l⁻¹ < 1 := (inv_lt_one₀ hlp).mpr hl + let s0 := (l⁻¹+1)/2 + have hts : l⁻¹ < s0 := by dsimp [s0]; linarith only [ht1] + have hs0 : s0 < 1 := by dsimp [s0]; linarith only [ht1] + have hp := contracted_minimizer_mem_injectivityDomain hr ht ht1 + obtain ⟨m,hm,Hm⟩ := exists_divided_hessian_baseline hr ht hts hs0 + obtain ⟨C,hC,HC⟩ := hmtw.exists_normal_relative_hessian_bound hlam hcap hp (div_pos hm hlp) + let D := fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) (riemannianExp a r) (riemannianExp a v)) r + have hz (ξ : TangentSpace 𝓘(ℝ,Model n) a) (hξ : D ξ=0) : ξ=0 := by + by_contra hne + have hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) a) 𝓘(ℝ,Model n) + (riemannianExp a) r ξ=0 := by rw [exp_mfderiv_apply_eq_coordinate]; exact hξ + have H := conjugate_radial_hessian_tendsto_atBot hr hk (inner_self_ne_zero.mpr hne) + let A := hessianValue a (l⁻¹ • r) ξ + let K := |A|+C*‖ξ‖^2 + have hK : 0 ≤ K := add_nonneg (abs_nonneg A) (mul_nonneg hC (sq_nonneg _)) + have hb := H.eventually (eventually_lt_atBot (-l*K-1)) + have hn : ∀ᶠ s : ℝ in 𝓝[<] 1,s0 ≤ s ∧ s < 1 := + (((eventually_gt_nhds hs0).filter_mono nhdsWithin_le_nhds).mono (fun _ h => h.le)).and self_mem_nhdsWithin + obtain ⟨s,hs,hlt⟩ := (hn.and hb).exists + have hsp : 0 < s := ht.trans_le (hts.le.trans hs.1) + obtain ⟨f,hf,hfv,hflo,hfD,hfH⟩ := outer_split_lower_test hr hmono hφ hd hlp.ne' hmount hsp hs.2 + have hscalar (d : TangentSpace 𝓘(ℝ,Model n) a) : + 0 ≤ -(iteratedDeriv 2 φ (uv.1 a)/l^3)*(inner ℝ r d)^2 := + mul_nonneg (neg_nonneg.mpr (div_nonpos_of_nonpos_of_nonneg hconc (pow_nonneg hlp.le _))) (sq_nonneg _) + have hpos (d : TangentSpace 𝓘(ℝ,Model n) a) : + (m/l)*‖d‖^2 ≤ fderiv ℝ (fderiv ℝ f) 0 d d+hessianValue a (l⁻¹ • r) d := by + rw [hfH] + have Hbase := mul_le_mul_of_nonneg_left (Hm s hs.1 hs.2 d) ht.le + have Halgebra : l⁻¹*(hessianValue a (l⁻¹ • r) d/l⁻¹-hessianValue a (s • r) d/s)= + -(l*s)⁻¹*hessianValue a (s • r) d+hessianValue a (l⁻¹ • r) d := by + field_simp + ring + rw [Halgebra] at Hbase + have HP := hscalar d + simp only [div_eq_mul_inv] at Hbase HP ⊢ + nlinarith only [Hbase,HP] + have HB := HC x0 uv huv f hf hfD hfv.symm hflo hpos ξ + rw [hfH] at HB + have HA : -A ≤ |A| := neg_le_abs A + have HS := hscalar ξ + have Hbound : -hessianValue a (s • r) ξ/(l*s) ≤ K := by + dsimp [A,K] at * + simp only [mul_inv_rev,div_eq_mul_inv] at * + nlinarith only [HB,HA,HS] + have Hmul := (div_le_iff₀ (mul_pos hlp hsp)).mp Hbound + have Hls : l*s ≤ l := by nlinarith only [hs.2,hlp] + have Hmul' := mul_le_mul_of_nonneg_left Hls hK + linarith only [Hmul,Hmul',hlt] + intro p q hpq + apply sub_eq_zero.mp + apply hz (p-q) + rw [map_sub,hpq,sub_self] + +end OuterNonconjugacy +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/PoleLipschitz.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/PoleLipschitz.lean new file mode 100644 index 0000000000000000000000000000000000000000..717480b6b0ab148d1cc9fd32f40a7be8e88dbb5c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/PoleLipschitz.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ManifoldLipschitz +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.uniform_hopfPole_lipschitz (hmtw : WeakMTW (n := n) (M := M)) (a : M) : + ∃ C>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ t : ℝ, 1/2≤t → t<1 → ∀ u v : M → ℝ, Continuous u → Continuous v → + IsCostDualPair u v → + LipschitzOnWith (Real.toNNReal (C/(1-t))) + (fun z => hopfPole (n := n) t u ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (ball (extChartAt 𝓘(ℝ,Model n) a a) r) := by + let : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hB,r₁,hr₁,hT₁,H⟩ := hmtw.uniform_hopfLax_C11 a + let D : ℝ≥0 := Real.toNNReal (Metric.diam (univ : Set M)) + have hD : ∀ x y : M, dist x y≤D := by + intro x y + rw [Real.coe_toNNReal _ Metric.diam_nonneg] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + obtain ⟨L,r₂,hr₂,hT₂,hL⟩ := exists_lipschitzOn_inverse_chart (E := Model n) a + let χ := extChartAt 𝓘(ℝ,Model n) a + let r := min (r₁/8) (r₂/2) + have hr : 0 + hT₁ ((closedBall_subset_ball (by linarith : r (coordinateBackward_contMDiffAt (hT hq.2.1)).of_le (by simp)) + let C : ℝ := (A:ℝ)*(1+12*B)+1 + have hC : 0 hT (ball_subset_closedBall hz),?_⟩ + intro t ht ht1 u v hu hv hdual + have ht0 : 0 hopfLax t u (χ.symm z) + have hf := (hopfLax_lipschitz hu hD ht0).comp_lipschitzOnWith hL + have hd_bound : ∀ z∈ball (χ a) r, ‖fderiv ℝ f z‖≤2*(D:ℝ)*L := by + intro z hz + have hz₂ : z∈ball (χ a) r₂ := ball_subset_ball hr₂'.le hz + have hn := norm_fderiv_le_of_lipschitzOn ℝ (isOpen_ball.mem_nhds hz₂) hf + have hdiv : (D:ℝ)/t≤2*D := (div_le_iff₀ ht0).mpr (by nlinarith [D.coe_nonneg]) + calc + _≤↑((D/Real.toNNReal t)*L : ℝ≥0) := hn + _=(D:ℝ)/t*L := by rw [NNReal.coe_mul,NNReal.coe_div,Real.coe_toNNReal _ ht0.le] + _≤_ := mul_le_mul_of_nonneg_right hdiv L.coe_nonneg + have hd_lip := (H t ht0 ht1 u v hu hv hdual).2 + have hcoef : 6*(B/t+B/(1-t)) ≤ (12*B)/(1-t) := by + have hdualT : B/t≤B/(1-t) := div_le_div_of_nonneg_left hB.le hs (by linarith) + calc + _ ≤ 6*(B/(1-t)+B/(1-t)) := by linarith + _ = _ := by ring + rw [lipschitzOnWith_iff_dist_le_mul] + intro z hz w hw + have hzK : (t,z,fderiv ℝ f z)∈K := + ⟨⟨ht,ht1.le⟩,ball_subset_closedBall hz,by simpa only [mem_closedBall,dist_zero_right] using hd_bound z hz⟩ + have hwK : (t,w,fderiv ℝ f w)∈K := + ⟨⟨ht,ht1.le⟩,ball_subset_closedBall hw,by simpa only [mem_closedBall,dist_zero_right] using hd_bound w hw⟩ + have Hz := hmtw.coordinateBackward_eq_pole hu hv hdual ht0 ht1 (hT (ball_subset_closedBall hz)) + have Hw := hmtw.coordinateBackward_eq_pole hu hv hdual ht0 ht1 (hT (ball_subset_closedBall hw)) + change dist (hopfPole (n := n) t u (χ.symm z)) (hopfPole (n := n) t u (χ.symm w))≤_ + rw [←Hz,←Hw] + have hder := hd_lip.dist_le_mul z (ball_subset_ball hr₁'.le hz) + w (ball_subset_ball hr₁'.le hw) + rw [Real.coe_toNNReal _ (by positivity)] at hder + have hd : dist (t,z,fderiv ℝ f z) (t,w,fderiv ℝ f w)≤ + ((1+12*B)/(1-t))*dist z w := by + rw [Prod.dist_eq,dist_self,Prod.dist_eq,max_eq_right (le_max_of_le_left dist_nonneg)] + apply max_le + · have h1 : 1≤(1+12*B)/(1-t) := (le_div_iff₀ hs).mpr (by nlinarith) + simpa using mul_le_mul_of_nonneg_right h1 (dist_nonneg (x := z) (y := w)) + · calc + _≤6*(B/t+B/(1-t))*dist z w := hder + _≤((12*B)/(1-t))*dist z w := mul_le_mul_of_nonneg_right hcoef dist_nonneg + _≤((1+12*B)/(1-t))*dist z w := mul_le_mul_of_nonneg_right + (div_le_div_of_nonneg_right (by linarith) hs.le) dist_nonneg + calc + _≤(A:ℝ)*dist (t,z,fderiv ℝ f z) (t,w,fderiv ℝ f w) := hA.dist_le_mul _ hzK _ hwK + _≤(A:ℝ)*(((1+12*B)/(1-t))*dist z w) := mul_le_mul_of_nonneg_left hd A.coe_nonneg + _≤(C/(1-t))*dist z w := by + have hc : (A:ℝ)*((1+12*B)/(1-t))≤C/(1-t) := by + rw [←mul_div_assoc] + apply div_le_div_of_nonneg_right _ hs.le + dsimp [C]; linarith + simpa only [mul_assoc] using mul_le_mul_of_nonneg_right hc (dist_nonneg (x := z) (y := w)) + _=_ := by rw [Real.coe_toNNReal _ (div_nonneg hC.le hs.le)] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/PrecutExtension.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/PrecutExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..173c5f1450b90f91dd4b29250b9a3bed26496bc6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/PrecutExtension.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GraphCompact + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma eventually_uniform_graph_precut {v : M → ℝ} (hv : Continuous v) {T : ℝ} + (hID : ∀ x : M, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + T • p ∈ injectivityDomain x) : + ∀ᶠ t in 𝓝 T, ∀ x : M, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + t • p ∈ injectivityDomain x := by + let : CompactSpace (subgradientGraph (n := n) (cTransform v)) := + isCompact_iff_compactSpace.mp (isCompact_subgradientGraph hv) + have hf : Continuous (fun q : ℝ × subgradientGraph (n := n) (cTransform v) => tangentScale q.1 q.2.1) := + contMDiff_tangentScale.continuous.comp (continuous_fst.prodMk (continuous_subtype_val.comp continuous_snd)) + have H : ∀ᶠ t in 𝓝 T, ∀ z : subgradientGraph (n := n) (cTransform v), + t • z.1.2 ∈ injectivityDomain z.1.1 := by + have HH : ∀ᶠ t in 𝓝 T, ∀ z ∈ (univ : Set (subgradientGraph (n := n) (cTransform v))), + t • z.1.2 ∈ injectivityDomain z.1.1 := by + apply isCompact_univ.eventually_forall_of_forall_eventually + intro z _ + exact (isOpen_total_injectivityDomain.preimage hf).mem_nhds + (hID z.1.1 z.1.2 (normalSubdifferential_subset_active_hull hv z.1.1 z.2)) + exact HH.mono (fun _ h z => h z (mem_univ z)) + filter_upwards [H] with t ht x p hp + exact ht ⟨⟨x,p⟩,active_hull_subset_normalSubdifferential hv x hp⟩ + +lemma scaled_injectivityDomain_of_le {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t S : ℝ} (hS : 0 F p.1 p.2)) + (q : X → Z) (hq : Continuous q) {T : P} {δ : ℝ} (hδ : 0<δ) + (hT : Function.Injective (F T)) + (hloc : ∀ᶠ t in 𝓝 T, ∀ x y, dist (q x) (q y)<δ → F t x=F t y → x=y) : + ∀ᶠ t in 𝓝 T, Function.Injective (F t) := by + have hopen : IsOpen {p : P × (X × X) | + dist (q p.2.1) (q p.2.2)<δ ∨ F p.1 p.2.1 ≠ F p.1 p.2.2} := + (isOpen_lt ((hq.comp (continuous_fst.comp continuous_snd)).dist + (hq.comp (continuous_snd.comp continuous_snd))) continuous_const).union + (isOpen_ne_fun (hF.comp (continuous_fst.prodMk (continuous_fst.comp continuous_snd))) + (hF.comp (continuous_fst.prodMk (continuous_snd.comp continuous_snd)))) + have hfar : ∀ᶠ t in 𝓝 T, ∀ xy ∈ (univ : Set (X×X)), + dist (q xy.1) (q xy.2)<δ ∨ F t xy.1 ≠ F t xy.2 := by + apply isCompact_univ.eventually_forall_of_forall_eventually + intro xy _ + apply hopen.mem_nhds + by_cases hxy : xy.1=xy.2 + · exact Or.inl (by simpa only [hxy,dist_self] using hδ) + · exact Or.inr (fun he => hxy (hT he)) + filter_upwards [hloc,hfar] with t ht hf x y he + rcases hf (x,y) (mem_univ _) with hclose | hne + · exact ht x y hclose he + · exact (hne he).elim + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/ProjectionContinuation.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ProjectionContinuation.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d29cb993f9568d83cbf0545ec3720ef6aa29903 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/ProjectionContinuation.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.UniformLocalGap +import OAI.Analysis.BiholderTransport.CostGeometry.LimitIsolation +import OAI.Analysis.BiholderTransport.CostGeometry.PrecutExtension + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.extend_injective_graphProjection + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {T : ℝ} (hT : 0 z.1.1) ((FiberBundle.continuous_proj _ _).comp continuous_subtype_val) hδ hTI + filter_upwards [eventually_gt_nhds hT,eventually_lt_nhds hTS] with t ht htS + exact hsep t ⟨ht,htS.le⟩ + obtain ⟨ε,hε,hball⟩ := Metric.mem_nhds_iff.mp hnear + let R := T+min (ε/2) ((1-T)/2) + have hTR : T h.2.1.le⟩ + have hB : 0 h.2.1.le) + have hBI : ∀ s ∈ Ioo (0:ℝ) (sSup A), + Function.Injective (graphProjection (n := n) (cTransform v) s) := by + intro s hs + obtain ⟨R,hRA,hsR⟩ := exists_lt_of_lt_csSup hA hs.2 + exact hRA.2.2 s ⟨hs.1,hsR.le⟩ + have heq : sSup A=1 := by + apply le_antisymm hB1 + by_contra hn + obtain ⟨R,hBR,hR1,hRI⟩ := hmtw.extend_injective_graphProjection hv hB (lt_of_not_ge hn) hBI + have hRA : R∈A := ⟨hB.trans hBR,hR1,hRI⟩ + exact (not_lt_of_ge (le_csSup hAb hRA)) hBR + apply hBI t + exact ⟨ht,by rwa [heq]⟩ + +lemma WeakMTW.active_hull_precut + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0 hmtw.injective_graphProjection hv hs.1 (hs.2.trans ht1)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/QuantitativeDividedAction.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/QuantitativeDividedAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..88559ac5366e5cc35b11753e44fa3f7762872d71 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/QuantitativeDividedAction.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.JetPullback +import OAI.Analysis.BiholderTransport.Regularity.PrefixAction +import OAI.Analysis.BiholderTransport.Calculus.CompactParameterJets + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma splitTrialValue_middle_shortLeg {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p∈injectivityDomain x) + (hF : ContDiffAt ℝ 2 (shortLegCost x t p) 0) : + splitTrialValue x t 0 k p = t*‖k‖^2+ + fderiv ℝ (fderiv ℝ (shortLegCost x t p)) 0 k k/(1-t) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hline : Tendsto (fun r : ℝ => p+r • k) (𝓝 0) (𝓝 p) := by + simpa only [ContinuousAt,zero_smul,add_zero] using + (show ContinuousAt (fun r : ℝ => p+r • k) 0 from by fun_prop) + have he : (fun r : ℝ => splitNormalAction x t p (r • (0:V),p+r • k)) =ᶠ[𝓝 0] + (fun r : ℝ => t*(‖p+r • k‖^2/2)+shortLegCost x t p (r • k)/(1-t)) := by + filter_upwards [hline.eventually (prefixAction_axis_near hp)] with r hr + simp only [splitNormalAction,smul_zero,riemannianExp_zero,shortLegCost] + have H : cost x (riemannianExp x (t • (p+r • k)))/t=t*(‖p+r • k‖^2/2) := by + simpa only [prefixAction,riemannianExp_zero] using hr + rw [H] + have hnorm : ContDiffAt ℝ 2 (fun v : V => ‖v‖^2/2) p := + ((half_norm_sq_contDiff (E := V)).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + have hnline : ContDiffAt ℝ 2 (fun r : ℝ => ‖p+r • k‖^2/2) 0 := by + exact (show ContDiffAt ℝ 2 (fun v : V => ‖v‖^2/2) (p+(0:ℝ) • k) from by + simpa only [zero_smul,add_zero] using hnorm).comp (f := fun r:ℝ => p+r • k) 0 (by fun_prop) + have hsline : ContDiffAt ℝ 2 (fun r : ℝ => shortLegCost x t p (r • k)) 0 := by + exact (show ContDiffAt ℝ 2 (shortLegCost x t p) ((0:ℝ) • k) from by + simpa only [zero_smul] using hF).comp (f := fun r:ℝ => r • k) 0 (by fun_prop) + rw [splitTrialValue,he.iteratedDeriv_eq 2, + iteratedDeriv_fun_add (contDiffAt_const.mul hnline) (hsline.div_const (1-t)), + iteratedDeriv_const_mul t hnline] + have hN := iteratedDeriv_two_affine_line hnorm k + rw [half_norm_sq_second_fderiv,real_inner_self_eq_norm_sq] at hN + have hS := iteratedDeriv_two_affine_line hF k + simp only [zero_add] at hS + rw [hN,iteratedDeriv_div_const,hS] + +lemma exists_uniform_scaled_middle_bound (R : ℝ) : + ∃ C>0, ∀ᶠ t in 𝓝 (1:ℝ), ∀ x : M, + ∀ p k : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖≤R → 00, ∀ᶠ t in 𝓝 (1:ℝ), ∀ x : M, + ∀ p xi : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖≤R → 0 field_simp [hC.ne'] + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialBounds.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..c1066e58369742b04c60cd513ee04e90766725dc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialBounds.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ScaledSpectrum +import OAI.Analysis.BiholderTransport.LinearAlgebra.ScaledQuadraticBoundEigenvalues + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff BigOperators + +namespace WeakMTWTransport +section RadialBounds +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_radial_defect_quadratic_bounds : + ∃ C : ℝ, 0 nlinarith only [hb.1,hb.2,hk0,hku,hdn,hun] +end RadialBounds +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialSingular.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialSingular.lean new file mode 100644 index 0000000000000000000000000000000000000000..13fc1e1e9911937913c38c16875b4fa625c1b443 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialSingular.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.CongruenceSpectrum +import OAI.Analysis.BiholderTransport.LinearAlgebra.MiddleScaling + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section RadialSingular +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_endpoint_middle_singular_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + p ∈ minimizingVectors x → ∀ t ∈ Icc (1/4:ℝ) (3/4), + ∀ i : Fin (Module.finrank ℝ (Model n)), + (endpointExpDifferential x p).toLinearMap.singularValues i ≤ C * + middleSingularValue (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) t 1 i ∧ + middleSingularValue (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) t 1 i ≤ c * + (endpointExpDifferential x p).toLinearMap.singularValues i := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_endpoint_middle_ordered_comparison (n := n) (M := M) + refine ⟨c,C,hc,hC,?_⟩ + intro x p hp t ht i + have hD := middleHessianOperator_positive_one (z := ⟨x,p⟩) hp + (show 0 < t by linarith [ht.1]) (show t < 1 by linarith [ht.2]) + have hE := positive_singularValues_eq_eigenvalues hD rfl i + change middleSingularValue (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) t 1 i = _ at hE + simpa only [hE] using H x p hp t ht i + +lemma uniform_middle_singular_crossing : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2 ∈ minimizingVectors z.1 → ∀ δ ∈ Icc (0:ℝ) (1/2), + ∀ i : Fin (Module.finrank ℝ (Model n)), + middleSingularValue z (1/4) 1 i+c*δ ≤ middleSingularValue z (1/4) (1-δ) i ∧ + middleSingularValue z (1/4) (1-δ) i ≤ middleSingularValue z (1/4) 1 i+C*δ := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_middle_ordered_crossing (n := n) (M := M) + refine ⟨c,C,hc,hC,?_⟩ + intro z hz δ hd i + have h0 := positive_singularValues_eq_eigenvalues + (shortened_middle_operator_positive hz (show (0:ℝ) ≤ 0 by norm_num) + (show (0:ℝ) ≤ 1/2 by norm_num)) rfl i + have h1 := positive_singularValues_eq_eigenvalues + (shortened_middle_operator_positive hz hd.1 hd.2) rfl i + simp only [sub_zero] at h0 + change middleSingularValue z (1/4) 1 i = _ at h0 + change middleSingularValue z (1/4) (1-δ) i = _ at h1 + simpa only [h0,h1,sub_zero] using H z hz δ hd.1 hd.2 i + +lemma uniform_radial_singular_shortening : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + p ∈ minimizingVectors x → ∀ δ ∈ Icc (0:ℝ) (1/2), + ∀ i : Fin (Module.finrank ℝ (Model n)), + c*((endpointExpDifferential x p).toLinearMap.singularValues i+δ) ≤ + (endpointExpDifferential x ((1-δ) • p)).toLinearMap.singularValues i ∧ + (endpointExpDifferential x ((1-δ) • p)).toLinearMap.singularValues i ≤ + C*((endpointExpDifferential x p).toLinearMap.singularValues i+δ) := by + obtain ⟨a,b,ha,hb,H⟩ := uniform_endpoint_middle_singular_comparison (n := n) (M := M) + obtain ⟨l,u,hl,hu,J⟩ := uniform_middle_singular_crossing (n := n) (M := M) + refine ⟨1/(2*a*(b+1/l)),b*(a+u),div_pos (by norm_num) + (by positivity),mul_pos hb (add_pos ha hu),?_⟩ + intro x p hp δ hd i + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + let T := 1-δ + have hT : 0 < T := by dsimp [T]; linarith [hd.2] + have hT1 : T ≤ 1 := by dsimp [T]; linarith [hd.1] + have hThalf : (1/2:ℝ) ≤ T := by dsimp [T]; linarith [hd.2] + have ht : (1/4:ℝ)/T ∈ Icc (1/4:ℝ) (3/4) := by + constructor + · rw [le_div_iff₀ hT]; nlinarith + · rw [div_le_iff₀ hT]; nlinarith + have H0 := H x p hp (1/4) (by constructor <;> norm_num) i + have H1 := H x (T • p) (minimizingVectors_smul hp hT.le hT1) ((1/4)/T) ht i + have HS := middleSingularValue_scaled_ray z (1/4) T hT i + change middleSingularValue (⟨x,T • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) ((1/4)/T) 1 i = _ at HS + rw [HS] at H1 + have J1 := J z hp δ hd i + let S := (endpointExpDifferential x p).toLinearMap.singularValues i + let R := (endpointExpDifferential x (T • p)).toLinearMap.singularValues i + let d0 := middleSingularValue z (1/4) 1 i + let d1 := middleSingularValue z (1/4) T i + change S ≤ b*d0 ∧ d0 ≤ a*S at H0 + change R ≤ b*(T*d1) ∧ T*d1 ≤ a*R at H1 + change d0+l*δ ≤ d1 ∧ d1 ≤ d0+u*δ at J1 + have hd0 : 0 ≤ d0 := (middleHessianOperator z (1/4) 1).toLinearMap.singularValues_nonneg i + have hd1 : 0 ≤ d1 := (middleHessianOperator z (1/4) T).toLinearMap.singularValues_nonneg i + have hS : 0 ≤ S := (endpointExpDifferential x p).toLinearMap.singularValues_nonneg i + have hR : 0 ≤ R := (endpointExpDifferential x (T • p)).toLinearMap.singularValues_nonneg i + have hlowD : d1 ≤ 2*a*R := by + have hh := mul_le_mul_of_nonneg_right hThalf hd1 + nlinarith [H1.2] + have hupD : d1 ≤ a*S+u*δ := J1.2.trans (add_le_add H0.2 le_rfl) + have hSle : S ≤ b*d1 := H0.1.trans (mul_le_mul_of_nonneg_left + (by nlinarith [J1.1,mul_nonneg hl.le hd.1]) hb.le) + have hdle : δ ≤ (1/l)*d1 := by + rw [one_div,mul_comm,←div_eq_mul_inv,le_div_iff₀ hl] + nlinarith [J1.1] + constructor + · change (1/(2*a*(b+1/l)))*(S+δ) ≤ R + rw [one_div,mul_comm,←div_eq_mul_inv,div_le_iff₀ (by positivity : 0 < 2*a*(b+1/l))] + calc + S+δ ≤ (b+1/l)*d1 := by nlinarith only [hSle,hdle] + _ ≤ (b+1/l)*(2*a*R) := mul_le_mul_of_nonneg_left hlowD (by positivity) + _ = R*(2*a*(b+1/l)) := by ring + · change R ≤ b*(a+u)*(S+δ) + have hh := mul_le_mul_of_nonneg_right hT1 hd1 + have hh2 := H1.1.trans (mul_le_mul_of_nonneg_left (by simpa only [one_mul] using hh) hb.le) + calc + R ≤ b*d1 := hh2 + _ ≤ b*(a*S+u*δ) := mul_le_mul_of_nonneg_left hupD hb.le + _ ≤ b*(a+u)*(S+δ) := by + have h1 := mul_nonneg ha.le hd.1 + have h2 := mul_nonneg hu.le hS + nlinarith [mul_nonneg hb.le h1,mul_nonneg hb.le h2] + +end RadialSingular +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialVelocityMetricEqualities.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialVelocityMetricEqualities.lean new file mode 100644 index 0000000000000000000000000000000000000000..f60ee9288d7ddb9dc582540751f0b7c20e807db8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/RadialVelocityMetricEqualities.lean @@ -0,0 +1,102 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +lemma radial_velocity_of_metric_equalities {g : E →L[ℝ] E →L[ℝ] ℝ} + (hp : ∀ v : E, v ≠ 0 → 0 < g v v) (hs : ∀ v w, g v w = g w v) + {u V : E} {s τ k : ℝ} (hu : g u u = k^2) + (hV : τ^2*g V V = s^2*k^2) (hm : τ*g V u = s*k^2) : + s • u = τ • V := by + have hz : g (s • u - τ • V) (s • u - τ • V) = 0 := by + simp only [map_sub,map_smul,sub_apply,smul_apply,smul_eq_mul] + rw [hs u V,hu] + nlinarith [congrArg (fun z : ℝ => s*z) hm] + by_contra he + have hpos := hp (s • u - τ • V) (sub_ne_zero.mpr he) + linarith + +lemma bilinear_metric_radial_derivative {g : E →L[ℝ] E →L[ℝ] ℝ} + (hs : ∀ u v, g u v = g v u) {f : ℝ → E} {s a τ k : ℝ} + (hf : DifferentiableAt ℝ f s) + (he : (fun t => τ^2*g (f t) (f t)) =ᶠ[𝓝 s] (fun t => (t-a)^2*k^2)) : + τ^2*g (f s) (deriv f s) = (s-a)*k^2 := by + have hL := (((g.hasFDerivAt.comp_hasDerivAt s hf.hasDerivAt).clm_apply + hf.hasDerivAt).const_mul (τ^2)) + have hR := (((hasDerivAt_id s).sub_const a).pow 2).mul_const (k^2) + have H := (hL.congr_of_eventuallyEq he.symm).unique hR + simp only [Function.comp_apply, Nat.reduceSub, pow_one, id_eq, mul_one, + Nat.cast_ofNat] at H + rw [hs (deriv f s) (f s)] at H + linarith +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/SectionDiameter.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SectionDiameter.lean new file mode 100644 index 0000000000000000000000000000000000000000..353d5123e937dddcabbe0fa4cd0bd65bad2afe1d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SectionDiameter.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.SectionOscillation +import OAI.Analysis.BiholderTransport.Regularity.LiftedSections + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SectionDiameter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.liftedGapSection_diameter_sq (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (huv : IsCostDualPair u v) + {x : M} {r : ℝ} (hr : 0≤r) {p q : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈liftedGapSection u v x r) (hq : q∈liftedGapSection u v x r) : + ‖p-q‖^2≤8*(r+sectionOscillation u v x r) := by + let m := (1/2:ℝ) • p+(1/2:ℝ) • q + have hm : m∈liftedGapSection u v x r := + (hmtw.convex_liftedGapSection hu hv huv x r) hp hq (by norm_num) (by norm_num) (by norm_num) + obtain ⟨y₀,_,y₁,_,hmin,hmax,heq⟩ := sectionOscillation_extrema hv huv x hr + have hpS := (mem_liftedGapSection_iff.mp hp).2 + have hqS := (mem_liftedGapSection_iff.mp hq).2 + have hmS := (mem_liftedGapSection_iff.mp hm).2 + have hpl := hmin _ hpS + have hql := hmin _ hqS + have hmu := hmax _ hmS + have hpm := hp.2 + have hqm := hq.2 + have hmn := dualPair_gap_nonneg hv huv x (riemannianExp x m) + rw [contactGap,cost_minimizingVector hm.1] at hmn + have norm_m : ‖m‖^2=(‖p‖^2+‖q‖^2)/2-‖p-q‖^2/4 := by + have hpar := parallelogram_law_with_norm ℝ p q + dsimp [m] + rw [←smul_add,norm_smul] + norm_num + nlinarith [hpar] + rw [heq] + nlinarith [norm_m] + +end SectionDiameter +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Bundle Bornology Set MeasureTheory Manifold Filter Metric +open scoped ENNReal NNReal ContDiff Topology + +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace + normedSpaceTangentSpaceVectorSpace + +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/Slack.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/Slack.lean new file mode 100644 index 0000000000000000000000000000000000000000..9af0b8bb3ca4181904bb7620766ad1dc04704754 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/Slack.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.StrictDividedAction +import OAI.Analysis.BiholderTransport.Regularity.FiniteNonnegativeWeightPos + +namespace OAI + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.finite_nonnegative_transverse_slack_strict + (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] {x : M} (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 0 ≤ w i) (hsum : ∑ i, w i = 1) + (hmin : ∀ i, p i ∈ minimizingVectors x) + {t s : ℝ} (ht : 0 < t) (hts : t < s) (hs : s < 1) + (hID : ∀ q ∈ convexHull ℝ (range p), t • q ∈ injectivityDomain x) + {xi : TangentSpace 𝓘(ℝ,Model n) x} (hxi : xi ≠ 0) + (hortho : ∀ i, 0 < w i → inner ℝ xi (p i - ∑ j, w j • p j) = 0) : + (∑ i, w i * (hessianValue x (s • p i) xi / s)) < + hessianValue x (t • (∑ i, w i • p i)) xi / t := by + classical + let S := Finset.univ.filter (fun i => 0 < w i) + let r := ∑ i, w i • p i + let C := convexHull ℝ (range p) ∩ {q | inner ℝ xi q = inner ℝ xi r} + have hhyper : Convex ℝ {q : TangentSpace 𝓘(ℝ,Model n) x | inner ℝ xi q = inner ℝ xi r} := by + intro u hu v hv a b ha hb hab + simp only [mem_ofPred_eq,inner_add_right,real_inner_smul_right] at hu hv ⊢ + rw [hu,hv,←add_mul,hab,one_mul] + have hC : Convex ℝ C := (convex_convexHull ℝ (range p)).inter hhyper + have hS : ∀ i ∈ S, p i ∈ C := by + intro i hi + refine ⟨subset_convexHull ℝ (range p) (mem_range_self i),?_⟩ + exact sub_eq_zero.mp (by simpa only [inner_sub_right] using hortho i (Finset.mem_filter.mp hi).2) + have hsumS : ∑ i ∈ S, w i = 1 := by + have H := sum_filter_positive_weights w hw (fun _ => (1:ℝ)) + simpa only [S,smul_eq_mul,mul_one,hsum] using H + have hc := hmtw.contracted_transverse_concaveOn_set hC (fun q hq => hID q hq.1) + (fun u hu v hv => by rw [inner_sub_right,hu.2,hv.2,sub_self]) + have hj := hc.le_map_sum (t := S) (w := w) (p := p) (fun i _ => hw i) hsumS hS + rw [sum_filter_positive_weights w hw p, + sum_filter_positive_weights w hw (fun q => hessianValue x (t • p q) xi)] at hj + simp only [smul_eq_mul] at hj + have hj' := div_le_div_of_nonneg_right hj ht.le + rw [Finset.sum_div] at hj' + have hpos : ∃ i, 0 < w i := by + by_contra hn + have hz : ∀ i, w i = 0 := fun i => le_antisymm (le_of_not_gt (fun h => hn ⟨i,h⟩)) (hw i) + simp only [hz,Finset.sum_const_zero] at hsum + norm_num at hsum + obtain ⟨j,hjpos⟩ := hpos + have hlt : (∑ i, w i * (hessianValue x (s • p i) xi / s)) < + ∑ i, w i * hessianValue x (t • p i) xi / t := by + apply Finset.sum_lt_sum + · intro i _ + rw [mul_div_assoc] + exact mul_le_mul_of_nonneg_left (divided_hessian_strict_decrease (hmin i) ht hts hs hxi).le (hw i) + · refine ⟨j,Finset.mem_univ j,?_⟩ + rw [mul_div_assoc] + exact mul_lt_mul_of_pos_left (divided_hessian_strict_decrease (hmin j) ht hts hs hxi) hjpos + exact hlt.trans_le hj' + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitEndpoint.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitEndpoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..5195f3461e886ea73e46be68129669838e8a437d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitEndpoint.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions +import OAI.Analysis.BiholderTransport.CostGeometry.SplitStationary + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SplitEndpoint +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma diagonalSplitAction_endpoint_gradient {x : M} + {p v : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + {r : TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p)} + (hr : r∈injectivityDomain (riemannianExp x p)) + (heq : riemannianExp (riemannianExp x p) r=riemannianExp x (t • v)) + (hF : DifferentiableAt ℝ (diagonalSplitAction x t) (p,v)) + (k : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (diagonalSplitAction x t) (p,v) (k,0)= + -inner ℝ r (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) p k)/(1-t) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + have hc := cost_start_gradient_of_injectivityDomain hr + rw [heq] at hc + have hc' : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) + (fun z => cost (riemannianExp x (t • v)) z) y (innerSL ℝ (-r)) := by + have hswap : (fun z => cost (riemannianExp x (t • v)) z)= + (fun z => cost z (riemannianExp x (t • v))) := funext (fun z => cost_symm _ _) + rw [hswap] + exact hc + have hE := (contMDiff_riemannianExp_fiber x p).mdifferentiableAt (by simp) + have hD := hc'.comp p hE.hasMFDerivAt + have hD' : HasFDerivAt (fun w : X => cost (riemannianExp x (t • v)) (riemannianExp x w)) + ((innerSL ℝ (-r)).comp (mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp x) p)) p := by + convert! hD.hasFDerivAt using 1 + have hpart := (hD'.mul_const (1-t)⁻¹).const_add + (cost x (riemannianExp x (t • v))/t) + have heqfun : (fun w : X => diagonalSplitAction x t (w,v)) = + (fun w : X => cost x (riemannianExp x (t • v))/t + + cost (riemannianExp x (t • v)) (riemannianExp x w)*(1-t)⁻¹) := by + funext w + simp only [diagonalSplitAction,splitNormalAction,riemannianExp_zero,div_eq_mul_inv] + rw [←heqfun] at hpart + have hl := (hasFDerivAt_id (𝕜 := ℝ) p).prodMk (hasFDerivAt_const v p) + have hfull := hF.hasFDerivAt.comp (f := fun w : X => (w,v)) p hl + have H := congrArg (fun A : X →L[ℝ] ℝ => A k) (hfull.unique hpart) + change fderiv ℝ (diagonalSplitAction x t) (p,v) (k,0)= + (1-t)⁻¹ * inner ℝ (-r) (mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp x) p k) at H + rw [H,inner_neg_left,div_eq_mul_inv,mul_comm] + +lemma diagonalSplitAction_mixed_endpoint {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + (hleft : t • p∈injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p)} + (hq : DifferentiableAt ℝ q p) + (hqI : ∀ᶠ v in 𝓝 p, q v∈injectivityDomain (riemannianExp x p)) + (hqr : ∀ᶠ v in 𝓝 p, riemannianExp (riemannianExp x p) (q v)=riemannianExp x (t • v)) + (a k : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (diagonalSplitAction x t)) (p,p) (0,a) (k,0)= + -inner ℝ (fderiv ℝ q p a) (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) p k)/(1-t) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let F := diagonalSplitAction (n := n) x t + let E := mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp x) p + have hF : ContDiffAt ℝ 2 F (p,p) := (diagonalSplitAction_contDiffAt hleft hright).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hdf := (hF.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hl := (hasFDerivAt_const p p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hD := ((hdf.hasFDerivAt.comp (f := fun v : X => (p,v)) p hl).clm_apply + (hasFDerivAt_const (k,(0:X)) p)).fderiv + have hnF : ∀ᶠ v : X in 𝓝 p, DifferentiableAt ℝ F (p,v) := + (hl.continuousAt.eventually ((hF.of_le (m := 1) (by norm_num)).eventually (by norm_num))).mono + (fun _ h => h.differentiableAt (by norm_num)) + have heq : (fun v : X => fderiv ℝ F (p,v) (k,0)) =ᶠ[𝓝 p] + (fun v => -inner ℝ (E k) (q v)*(1-t)⁻¹) := by + filter_upwards [hnF,hqI,hqr] with v hv hvI hvr + rw [diagonalSplitAction_endpoint_gradient hvI hvr hv,real_inner_comm,div_eq_mul_inv] + have hi := (((innerSL ℝ (E k)).hasFDerivAt.comp p hq.hasFDerivAt).neg.mul_const (1-t)⁻¹).fderiv + have H := congrArg (fun A : X →L[ℝ] ℝ => A a) (hD.symm.trans (heq.fderiv_eq.trans hi)) + simp only [_root_.add_apply,ContinuousLinearMap.comp_apply,_root_.zero_apply, + map_zero,zero_add,ContinuousLinearMap.flip_apply,ContinuousLinearMap.prod_apply, + _root_.smul_apply,smul_eq_mul,_root_.neg_apply] at H + change fderiv ℝ (fderiv ℝ F) (p,p) (0,a) (k,0)= + (1-t)⁻¹ * (-inner ℝ (E k) (fderiv ℝ q p a)) at H + rw [H,real_inner_comm,div_eq_mul_inv,mul_comm] + +end SplitEndpoint +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitStationary.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitStationary.lean new file mode 100644 index 0000000000000000000000000000000000000000..b68dcac623b1a89270f3f39db001a09323a3dbb4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitStationary.lean @@ -0,0 +1,199 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitAction + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def diagonalSplitAction (x : M) (t : ℝ) + (q : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + splitNormalAction x t q.1 (0,q.2) + +lemma split_regular_legs_near {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 p, t • v ∈ injectivityDomain x ∧ + (1-t) • (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + have hscale : Continuous (fun v : TangentSpace 𝓘(ℝ,Model n) x => t • v) := by fun_prop + have h₁ : ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 p, t • v ∈ injectivityDomain x := + hscale.continuousAt.preimage_mem_nhds + ((isOpen_injectivityDomain x).mem_nhds hleft) + have hZ := contMDiff_tangentScale.comp ((contMDiff_const (c := 1-t)).prodMk (contMDiff_spray_fiber (E := Model n) x t)) + have h₂ : ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 p, + (1-t) • (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := + (hZ.continuous.continuousAt (x := p)).preimage_mem_nhds + (isOpen_total_injectivityDomain.mem_nhds hright) + exact h₁.and h₂ + +lemma diagonalSplitAction_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (diagonalSplitAction x t) (p,p) := + (splitNormalAction_contDiffAt hleft hright).comp (p,p) + (contDiffAt_fst.prodMk (contDiffAt_const.prodMk contDiffAt_snd)) + +lemma diagonalSplitAction_stationary {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 dist b (riemannianExp x p)^2/2) + (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + (innerSL ℝ ((-(1-t)) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2)) := by + simpa only [cost,neg_smul] using hD + have H := spray_action_line_stationary x p xi t (1-t) (sub_pos.mpr ht1).ne' (riemannianExp x p) hD' + have hline : ContinuousAt (fun s : ℝ => p+s • xi) 0 := by fun_prop + have hnear : ∀ᶠ s : ℝ in 𝓝 0, t • (p+s • xi) ∈ injectivityDomain x := by + have hn := (split_regular_legs_near hleft hright).mono (fun _ h => h.1) + have hl : Tendsto (fun s : ℝ => p+s • xi) (𝓝 0) (𝓝 p) := by simpa only [ContinuousAt,zero_smul,add_zero] using hline + exact hl.eventually hn + have heq : (fun s : ℝ => diagonalSplitAction x t (p,p+s • xi)) =ᶠ[𝓝 0] + (fun s : ℝ => t*‖p+s • xi‖^2/2 + + dist (sprayFlow t (⟨x,p+s • xi⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 (riemannianExp x p)^2/2/(1-t)) := by + filter_upwards [hnear] with s hs + have hm := injectivityDomain_subset_minimizingVectors x hs + change dist x (riemannianExp x (t • (p+s • xi)))=‖t • (p+s • xi)‖ at hm + simp only [diagonalSplitAction,splitNormalAction,riemannianExp_zero,cost] + rw [hm,norm_smul,Real.norm_eq_abs,abs_of_pos ht] + rw [riemannianExp_smul] + field_simp + have hstat := H.congr_of_eventuallyEq heq + have hp₀ : HasDerivAt (fun s : ℝ => (p,p+s • xi)) (0,xi) 0 := by + convert! (hasDerivAt_const (0:ℝ) p).prodMk + ((hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const xi)) using 1 + simp + have hf := ((diagonalSplitAction_contDiffAt hleft hright).differentiableAt (by simp)).hasFDerivAt + have hf' : HasFDerivAt (diagonalSplitAction x t) + (fderiv ℝ (diagonalSplitAction x t) (p,p)) (p,p+(0:ℝ) • xi) := by + simpa only [zero_smul,add_zero] using hf + exact (hf'.comp_hasDerivAt (f := fun s : ℝ => (p,p+s • xi)) 0 hp₀).unique hstat + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitTrial.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitTrial.lean new file mode 100644 index 0000000000000000000000000000000000000000..1d1d2735e0c472c089523a42bf0c409b72ff9c0c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/SplitTrial.lean @@ -0,0 +1,244 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ActualRadial +import OAI.Analysis.BiholderTransport.LinearAlgebra.SchurEnvelope +import OAI.Analysis.BiholderTransport.Coordinates.SplitPairing +import OAI.Analysis.BiholderTransport.Volume.DiagonalKernel + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def splitTrialValue (x : M) (t : ℝ) (xi k w : TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + iteratedDeriv 2 (fun s : ℝ => splitNormalAction x t w (s • xi,w+s • k)) 0 + +lemma splitTrialValue_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (xi k : TangentSpace 𝓘(ℝ,Model n) x) : + ContDiffAt ℝ ∞ (splitTrialValue x t xi k) p := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hp := splitNormalAction_contDiffAt hleft hright + have hl : ContDiffAt ℝ ∞ (fun q : V×ℝ => (q.1,(q.2 • xi,q.1+q.2 • k))) (p,0) := by fun_prop + have hs : ContDiffAt ℝ ∞ (fun q : V×ℝ => splitNormalAction x t q.1 (q.2 • xi,q.1+q.2 • k)) (p,0) := by + have hp' : ContDiffAt ℝ ∞ (fun z : V×(V×V) => splitNormalAction x t z.1 z.2) + (p,((0:ℝ) • xi,p+(0:ℝ) • k)) := by simpa using hp + exact hp'.comp (p,0) hl + exact contDiffAt_iteratedDeriv_parameter hs 2 + +lemma splitTrialValue_eq_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (xi k : TangentSpace 𝓘(ℝ,Model n) x) : + splitTrialValue x t xi k p = + fderiv ℝ (fderiv ℝ (splitNormalAction x t p)) (0,p) (xi,k) (xi,k) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hc := (splitNormalAction_contDiffAt hleft hright).comp + (f := fun q : V×V => (p,q)) (0,p) (contDiffAt_const.prodMk contDiffAt_id) + simpa only [Function.comp_def,splitTrialValue,Prod.mk_add_mk,Prod.smul_mk,Prod.fst_add,Prod.smul_fst,Prod.snd_add,Prod.smul_snd,zero_add] using + iteratedDeriv_two_affine_line (hc.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) (xi,k) + +lemma splitTrialValue_middle_eq_diagonal {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + splitTrialValue x t 0 k p = + fderiv ℝ (fderiv ℝ (diagonalSplitAction x t)) (p,p) (0,k) (0,k) := by + simpa only [splitTrialValue,diagonalSplitAction,Prod.fst_add,Prod.smul_fst, + Prod.snd_add,Prod.smul_snd,smul_zero,add_zero] using + iteratedDeriv_two_affine_line ((diagonalSplitAction_contDiffAt hleft hright).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) ((0 : TangentSpace 𝓘(ℝ,Model n) x),k) + +lemma splitTrialValue_nonneg {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 splitNormalAction x t p (0,p+s • k) + have hmin : IsLocalMin f 0 := by + apply Filter.Eventually.of_forall + intro s + change splitNormalAction x t p (0,p+(0:ℝ) • k) ≤ splitNormalAction x t p (0,p+s • k) + simp only [zero_smul,add_zero,splitNormalAction_contact hp ht ht1] + exact normalCost_le_splitNormalAction x p 0 (p+s • k) ht ht1 + have hp' : ContDiffAt ℝ ∞ (fun z : V×(V×V) => splitNormalAction x t z.1 z.2) + (p,((0:V),p+(0:ℝ) • k)) := by simpa using splitNormalAction_contDiffAt hleft hright + have hBc := hp'.comp + (f := fun s : ℝ => (p,((0:V),p+s • k))) 0 (by fun_prop) + have hfc : ContinuousAt f 0 := by exact hBc.continuousAt + have H := localMin_second_deriv_nonneg hmin hfc + simpa only [splitTrialValue,smul_zero,iteratedDeriv_succ,iteratedDeriv_one,iteratedDeriv_zero,f] using H + +lemma splitTrialValue_conjugate_null {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 (p,q)) (0,p) (contDiffAt_const.prodMk contDiffAt_id) + have hB := hBc.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hle : ∀ᶠ z : V×V in 𝓝 (0,p), normalCost x p z.1 ≤ splitNormalAction x t p z := + Filter.Eventually.of_forall (fun z => normalCost_le_splitNormalAction x p z.1 z.2 ht ht1) + have heq := (splitNormalAction_contact (injectivityDomain_subset_minimizingVectors x hp) ht ht1).symm + have hmix := splitNormalAction_mixed_pairing ht.ne' hleft hright xi k + have hmixne : fderiv ℝ (fderiv ℝ (splitNormalAction x t p)) (0,p) (xi,0) (0,k)≠0 := by + rw [hmix]; exact neg_ne_zero.mpr hpair + constructor + · rw [splitTrialValue_eq_hessian hleft hright] + exact upper_contact_block_positive hf hB hle heq xi k hmixne + · rw [hessianValue_eq_normalHessian hp,splitTrialValue_eq_hessian hleft hright, + splitTrialValue_eq_hessian hleft hright] + have H := upper_contact_block_schur hf hB hle heq xi k hmixne + dsimp only [Function.comp_def] at H + rw [hmix,neg_sq] at H + exact H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/StrictDividedAction.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/StrictDividedAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..9422e307b9bcd5a5e4418fa9e49b6171888935a0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/StrictDividedAction.lean @@ -0,0 +1,319 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.SplitTrial + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma shifted_injectivityDomain_of_injectivityDomain {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ injectivityDomain x) + {t : ℝ} (ht : 0≤t) (ht1 : t<1) : + (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + obtain ⟨a,ha,hmin⟩ := hp + have hden : 0<1-t := sub_pos.mpr ht1 + let b := (a-t)/(1-t) + have hb : 1 TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma splitTrialValue_source (x : M) (p xi : TangentSpace 𝓘(ℝ,Model n) x) (t : ℝ) : + splitTrialValue x t xi 0 p=hessianValue x (t • p) xi/t := by + simp only [splitTrialValue,splitNormalAction,smul_zero,add_zero] + simp only [add_comm] + rw [iteratedDeriv_const_add (by norm_num : 0<(2:ℕ)),iteratedDeriv_div_const] + rfl + +lemma hessianValue_strict_radial_decrease {x : M} {p xi : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.contracted_transverse_concaveOn_set (hmtw : WeakMTW (n := n) (M := M)) + {x : M} {xi : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + {C : Set (TangentSpace 𝓘(ℝ,Model n) x)} (hC : Convex ℝ C) + (hID : ∀ p ∈ C, t • p ∈ injectivityDomain x) + (hortho : ∀ p ∈ C, ∀ q ∈ C, inner ℝ xi (q-p)=0) : + ConcaveOn ℝ C (fun p => hessianValue x (t • p) xi) := by + refine ⟨hC,?_⟩ + intro p hp q hq a b ha hb hab + have hline : ∀ s ∈ Icc (0:ℝ) 1, t • p+s • (t • (q-p)) ∈ injectivityDomain x := by + intro s hs + have heq : t • p+s • (t • (q-p))=t • ((1-s) • p+s • q) := by module + rw [heq] + exact hID _ (hC hp hq (sub_nonneg.mpr hs.2) hs.1 (by ring)) + have H := hmtw.transverse_concaveOn_injectivityDomain x (t • p) xi (t • (q-p)) + (convex_Icc 0 1) hline (by simp only [real_inner_smul_right,hortho p hp q hq,mul_zero]) + have hh := H.2 (show (0:ℝ) ∈ Icc 0 1 by constructor <;> norm_num) + (show (1:ℝ) ∈ Icc 0 1 by constructor <;> norm_num) ha hb hab + have heq : t • p+b • (t • (q-p))=t • (a • p+b • q) := by + rw [show a=1-b by linarith] + module + have heq1 : t • p+t • (q-p)=t • q := by module + simpa only [smul_eq_mul,mul_zero,mul_one,zero_add,zero_smul,add_zero,one_smul,heq1,heq] using hh + +lemma WeakMTW.finite_transverse_slack_strict (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 0 by rw [inner_sub_right,hsub hu,hsub hv,sub_self]) + have hj := hc.le_map_sum (t := Finset.univ) (w := w) (p := p) + (fun i _ => (hw i).le) hsum (fun i _ => subset_convexHull ℝ (range p) (mem_range_self i)) + simp only [smul_eq_mul] at hj + have hj' := div_le_div_of_nonneg_right hj ht.le + rw [Finset.sum_div] at hj' + have hlt : (∑ i, w i*(hessianValue x (s • p i) xi/s)) < + ∑ i, w i*hessianValue x (t • p i) xi/t := by + apply Finset.sum_lt_sum + · intro i _ + rw [mul_div_assoc] + exact (mul_lt_mul_of_pos_left (divided_hessian_strict_decrease (hmin i) ht hts hs hxi) (hw i)).le + · obtain ⟨i⟩ := ‹Nonempty ι› + refine ⟨i,Finset.mem_univ i,?_⟩ + rw [mul_div_assoc] + exact mul_lt_mul_of_pos_left (divided_hessian_strict_decrease (hmin i) ht hts hs hxi) (hw i) + exact hlt.trans_le hj' + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformFiniteRadialScale.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformFiniteRadialScale.lean new file mode 100644 index 0000000000000000000000000000000000000000..15f60c0d17d17910fdebdcd7ef1ae87fb27ef2f1 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformFiniteRadialScale.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiniteLogScaleAvoidance + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma uniform_finite_radial_scale {N : ℕ} {D η L : ℝ} + (hD : 0 < D) (hη : 0<η) (hL : 0 < L) : + ∃ c : ℝ, 0 < c ∧ ∀ (S : Finset ℝ), S.card ≤ N → ∀ s₀ s₁ : ℝ, + 0 < s₁ → s₁ ≤ D → s₀ < c*s₁ → + ∃ δ : ℝ, 0<δ ∧ δ ≤ η ∧ Real.exp L*s₀ ≤ δ ∧ δ*Real.exp L ≤ s₁ ∧ + ∀ s∈S, Real.exp L*s ≤ δ ∨ δ*Real.exp L ≤ s := by + classical + let T := min (η/D) (Real.exp (-L)) + let W := ((N:ℝ)+3)*(2*L+1) + have hT : 0 < T := lt_min (div_pos hη hD) (Real.exp_pos _) + have hTe : T ≤ Real.exp (-L) := min_le_right _ _ + have hTη : T*D ≤ η := by + have HH := min_le_left (η/D) (Real.exp (-L)) + change T ≤ η/D at HH + exact (le_div_iff₀ hD).mp HH + refine ⟨T*Real.exp (-W-L),mul_pos hT (Real.exp_pos _),?_⟩ + intro S hNS s₀ s₁ hs₁ hsD hs₀ + let Q := (S.filter (fun s => 0 < s)).image Real.log + have hQc : Q.card ≤ N := (Finset.card_image_le.trans (Finset.card_filter_le _ _)).trans hNS + have hlog : Real.exp (Real.log (s₁*T))=s₁*T := Real.exp_log (mul_pos hs₁ hT) + have hwide : (Real.log (s₁*T)-W)+((Q.card:ℝ)+2)*(2*L+1) < Real.log (s₁*T) := by + have hc : (Q.card:ℝ) ≤ N := by exact_mod_cast hQc + dsimp [W] + have HH := mul_nonneg (show 0 ≤ (N:ℝ)-Q.card by linarith) (show 0 ≤ 2*L+1 by linarith) + nlinarith only [HH,hL] + obtain ⟨u,hu,hsep⟩ := finite_log_scale_avoidance Q hL.le hwide + let δ := Real.exp u + have hδhi : δ ≤ s₁*T := by + have HH := (Real.exp_lt_exp.mpr hu.2).le + simpa only [hlog] using HH + have hδlo : s₁*T*Real.exp (-W) ≤ δ := by + have HH := (Real.exp_lt_exp.mpr hu.1).le + rw [sub_eq_add_neg,Real.exp_add,hlog] at HH + exact HH + have hexp : Real.exp (-L)*Real.exp L=1 := by rw [←Real.exp_add]; simp + have hexpW : Real.exp (-W-L)*Real.exp L=Real.exp (-W) := by + rw [←Real.exp_add] + congr 1 + ring + refine ⟨δ,Real.exp_pos _,?_,?_,?_,?_⟩ + · have HH := mul_le_mul_of_nonneg_right hsD hT.le + exact hδhi.trans (HH.trans (by simpa only [mul_comm T] using hTη)) + · have HH := mul_lt_mul_of_pos_right hs₀ (Real.exp_pos L) + have he : T*Real.exp (-W-L)*s₁*Real.exp L=s₁*T*Real.exp (-W) := by + calc + _ = (s₁*T)*(Real.exp (-W-L)*Real.exp L) := by ring + _ = _ := by rw [hexpW] + rw [he] at HH + have Hcenter : Real.exp L*s₀ ≤ s₁*T*Real.exp (-W) := by + simpa only [mul_comm (Real.exp L) s₀] using HH.le + exact Hcenter.trans hδlo + · have HH := mul_le_mul_of_nonneg_right hδhi (Real.exp_pos L).le + have H2 := mul_le_mul_of_nonneg_left hTe hs₁.le + have H3 := mul_le_mul_of_nonneg_right H2 (Real.exp_pos L).le + have he : s₁*Real.exp (-L)*Real.exp L=s₁ := by rw [mul_assoc,hexp,mul_one] + rw [he] at H3 + exact HH.trans H3 + · intro s hs + by_cases hspos : 0 < s + · have hlogs : Real.log s∈Q := Finset.mem_image.mpr + ⟨s,Finset.mem_filter.mpr ⟨hs,hspos⟩,rfl⟩ + rcases lt_abs.mp (hsep (Real.log s) hlogs) with HH|HH + · left + have Hexp := (Real.exp_lt_exp.mpr (show Real.log s+L < u by linarith)).le + rw [Real.exp_add,Real.exp_log hspos] at Hexp + simpa only [mul_comm s] using Hexp + · right + have Hexp := (Real.exp_lt_exp.mpr (show u+L < Real.log s by linarith)).le + rw [Real.exp_add,Real.exp_log hspos] at Hexp + exact Hexp + · exact Or.inl ((mul_nonpos_of_nonneg_of_nonpos (Real.exp_pos L).le (le_of_not_gt hspos)).trans + (Real.exp_pos u).le) +end WeakMTWTransport + +end + +end + +section + +noncomputable section +namespace WeakMTWTransport + +lemma radial_profile_small {s δ l b f R ε : ℝ} + (hs : 0 ≤ s) (hd : 0 < δ) (hl : 0 ≤ l) (hR : 1 ≤ R) + (hsmall : R*s ≤ δ) (hbg : b*δ ≤ ε) + (hf : l*δ/(s+δ)-b*δ ≤ f) : l/2-ε ≤ f := by + have hsδ : s ≤ δ := by nlinarith [mul_nonneg hs (sub_nonneg.mpr hR)] + have HH : l/2 ≤ l*δ/(s+δ) := by + rw [le_div_iff₀ (add_pos_of_nonneg_of_pos hs hd)] + nlinarith [mul_nonneg hl (sub_nonneg.mpr hsδ)] + linarith + +lemma radial_profile_large {s δ u b f R ε : ℝ} + (hs : 0 ≤ s) (hd : 0 < δ) (hu : 0 ≤ u) (hR : 0 < R) + (hlarge : δ*R ≤ s) (hbg : b*δ ≤ ε) + (hf : f ≤ u*δ/(s+δ)+b*δ) : f ≤ u/R+ε := by + have HH : u*δ/(s+δ) ≤ u/R := by + rw [div_le_div_iff₀ (add_pos_of_nonneg_of_pos hs hd) hR] + nlinarith [mul_nonneg hu (show 0 ≤ s+δ-δ*R by linarith)] + linarith +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformLocalGap.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformLocalGap.lean new file mode 100644 index 0000000000000000000000000000000000000000..ddafd4b41a43a55b9e58aa74fb5d3d71b279bc6e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformLocalGap.lean @@ -0,0 +1,159 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GraphProjection +import OAI.Analysis.BiholderTransport.Coordinates.ActiveHullUniform + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.uniform_local_scaled_gap + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {T : ℝ} (hT : T < 1) + (hID : ∀ x : M, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + ∀ t ∈ Icc (0:ℝ) T, t • p ∈ injectivityDomain x) : + ∃ δ > 0, ∀ x z : M, dist x z < δ → x ≠ z → + ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), ∀ t ∈ Icc (0:ℝ) T, + 0 < t * (cTransform v z-cTransform v x) + + cost z (riemannianExp x (t • p)) - cost x (riemannianExp x (t • p)) := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + let P := fun z : TangentBundle 𝓘(ℝ,Model n) M => + ∀ p ∈ convexHull ℝ (activeLogs (n := n) v z.1), ∀ t ∈ Icc (0:ℝ) T, + riemannianExp z.1 z.2 ≠ z.1 → + 0 < t * (cTransform v (riemannianExp z.1 z.2)-cTransform v z.1) + + cost (riemannianExp z.1 z.2) (riemannianExp z.1 (t • p)) - + cost z.1 (riemannianExp z.1 (t • p)) + have H : ∀ᶠ r : ℝ in 𝓝 0, ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2 ∈ minimizingVectors z.1 → ‖z.2‖=r → P z := by + apply compact_eventually_fiberwise (isCompact_total_minimizingVectors (n := n) (M := M)) + continuous_bundle_norm (continuousAt_id (x := (0:ℝ))) + rintro ⟨a,q⟩ _ he + have hq : q = 0 := norm_eq_zero.mp he + subst q + obtain ⟨K,hKn,hKa,hK⟩ := local_compact_nhds + ((isOpen_extChartAt_source (I := 𝓘(ℝ,Model n)) a).mem_nhds (mem_extChartAt_source a)) + have HG := hmtw.active_hull_uniform_strict_growth hv hK hKa hT + (fun x _ p hp t ht => hID x p hp t ht) + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hχ0 : (χ (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 = 0 := + map_zero (tangentCoordChange 𝓘(ℝ,Model n) a a a) + have hc : Tendsto (fun q : ℝ × TangentBundle 𝓘(ℝ,Model n) M => (χ q.2).2) + (𝓝 (0,⟨a,0⟩)) (𝓝 0) := by + have hχ : ContinuousAt χ (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) := continuousAt_extChartAt _ + have hh := hχ.snd.comp + (f := fun q : ℝ × TangentBundle 𝓘(ℝ,Model n) M => q.2) (x := (0,⟨a,0⟩)) continuousAt_snd + convert hh.tendsto using 1 <;> simp only [Function.comp_def,hχ0] + have hbase : ∀ᶠ q : ℝ × TangentBundle 𝓘(ℝ,Model n) M in 𝓝 (0,⟨a,0⟩), q.2.1 ∈ K := + ((FiberBundle.continuous_proj _ _).comp continuous_snd).continuousAt.preimage_mem_nhds hKn + filter_upwards [hc.eventually HG,hbase] with q hG hqK p hp t ht hne + have hm : movingNormal a (extChartAt 𝓘(ℝ,Model n) a q.2.1,(χ q.2).2) = + riemannianExp q.2.1 q.2.2 := movingNormal_chart (hKa hqK) q.2.2 + have hn : (χ q.2).2 ≠ 0 := by + intro hz + rw [hz,movingNormal_zero ((extChartAt 𝓘(ℝ,Model n) a).map_source (hKa hqK)), + (extChartAt 𝓘(ℝ,Model n) a).left_inv (hKa hqK)] at hm + exact hne hm.symm + have hh := hG q.2.1 hqK p hp t ht hn + simpa only [hm] using hh + obtain ⟨δ,hδ,Hδ⟩ := Metric.eventually_nhds_iff.mp H + refine ⟨δ,hδ,?_⟩ + intro x z hxz hne p hp t ht + obtain ⟨q,hq,hqz⟩ := exists_minimizing_vector (n := n) x z + have hnq : ‖q‖ = dist x z := by rw [←hq,hqz] + have hr : dist (dist x z) 0 < δ := by simpa only [Real.dist_eq,sub_zero,abs_of_nonneg dist_nonneg] using hxz + have hh := Hδ hr ⟨x,q⟩ hq hnq p hp t ht (by rw [hqz]; exact hne.symm) + simpa only [hqz] using hh + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.uniform_graph_fiber_separation + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {T : ℝ} (hT : T < 1) + (hID : ∀ x : M, ∀ p ∈ convexHull ℝ (activeLogs (n := n) v x), + ∀ t ∈ Icc (0:ℝ) T, t • p ∈ injectivityDomain x) : + ∃ δ > 0, ∀ t ∈ Ioc (0:ℝ) T, + ∀ z w : subgradientGraph (n := n) (cTransform v), + dist z.1.1 w.1.1 < δ → + graphProjection (cTransform v) t z = graphProjection (cTransform v) t w → z = w := by + obtain ⟨δ,hδ,Hδ⟩ := hmtw.uniform_local_scaled_gap hv hT hID + refine ⟨δ,hδ,?_⟩ + rintro t ht ⟨⟨x,p⟩,hp⟩ ⟨⟨z,q⟩,hq⟩ hdist he + have hpH := normalSubdifferential_subset_active_hull hv x hp + have hqH := normalSubdifferential_subset_active_hull hv z hq + change riemannianExp x (t • p) = riemannianExp z (t • q) at he + have hxz : x = z := by + by_contra hn + have h1 := Hδ x z hdist hn p hpH t ⟨ht.1.le,ht.2⟩ + have h2 := Hδ z x (by rwa [dist_comm]) (Ne.symm hn) q hqH t ⟨ht.1.le,ht.2⟩ + rw [he] at h1 + linarith + subst z + have hpq : t • p = t • q := riemannianExp_injOn_injectivityDomain x + (hID x p hpH t ⟨ht.1.le,ht.2⟩) (hID x q hqH t ⟨ht.1.le,ht.2⟩) he + have hpq' : p = q := (smul_right_injective _ ht.1.ne') hpq + subst q + rfl + +lemma graphProjection_base_dist {v : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0 ≤ t) (z : subgradientGraph (n := n) (cTransform v)) : + dist z.1.1 (graphProjection (cTransform v) t z) ≤ t * Metric.diam (univ : Set M) := by + apply (dist_riemannianExp_le z.1.1 (t • z.1.2)).trans + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg ht] + exact mul_le_mul_of_nonneg_left + (active_hull_norm_le_diam (normalSubdifferential_subset_active_hull hv z.1.1 z.2)) ht + +lemma WeakMTW.exists_short_injective_graphProjection + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} (hv : Continuous v) : + ∃ τ > 0, τ < 1 ∧ ∀ t ∈ Ioc (0:ℝ) τ, + Function.Injective (graphProjection (n := n) (cTransform v) t) := by + obtain ⟨T,hT,hT1,H⟩ := exists_uniform_short_active_hull_contraction (n := n) (M := M) + obtain ⟨δ,hδ,Hδ⟩ := hmtw.uniform_graph_fiber_separation hv hT1 + (fun x p hp t ht => H v x p hp t ht.1 ht.2) + let D := Metric.diam (univ : Set M) + have hD : 0 ≤ D := Metric.diam_nonneg + let τ := min T (δ/(4*(D+1))) + have hτ : 0 < τ := lt_min hT (div_pos hδ (by positivity)) + refine ⟨τ,hτ,(min_le_left _ _).trans_lt hT1,?_⟩ + intro t ht z w he + apply Hδ t ⟨ht.1,ht.2.trans (min_le_left _ _)⟩ z w _ he + have hz := graphProjection_base_dist hv ht.1.le z + have hw := graphProjection_base_dist hv ht.1.le w + rw [←he] at hw + have hd := dist_triangle z.1.1 (graphProjection (cTransform v) t z) w.1.1 + rw [dist_comm (graphProjection (cTransform v) t z) w.1.1] at hd + have htδ : t * (4*(D+1)) ≤ δ := + (le_div_iff₀ (by positivity : 0 < 4*(D+1))).mp (ht.2.trans (min_le_right _ _)) + change dist z.1.1 (graphProjection (cTransform v) t z) ≤ t*D at hz + change dist w.1.1 (graphProjection (cTransform v) t z) ≤ t*D at hw + nlinarith [mul_nonneg ht.1.le hD] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformRegularSplit.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformRegularSplit.lean new file mode 100644 index 0000000000000000000000000000000000000000..a53e10492a002ac1e1233a7de43592023621c662 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformRegularSplit.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TotalInjectivity +import OAI.Analysis.BiholderTransport.Coordinates.CompactEventuallyFiberwise + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma uniformly_shifted_injectivityDomain_near_one (R : ℝ) : + ∀ᶠ h in 𝓝 (1:ℝ), ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ‖p‖ ≤ R → (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + let Z : ℝ × TangentBundle 𝓘(ℝ,Model n) M → TangentBundle 𝓘(ℝ,Model n) M := + fun q => tangentScale (1-q.1) (sprayFlow q.1 q.2) + have hZ : ContMDiff (𝓘(ℝ,ℝ).prod (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n))) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Z := + contMDiff_tangentScale.comp ((contMDiff_const.sub contMDiff_fst).prodMk contMDiff_sprayFlow) + have H := compact_eventually_fiberwise + (isCompact_bundle_disk (B := M) (F := Model n) + (E := fun x => TangentSpace 𝓘(ℝ,Model n) x) R) + (f := fun _ => ()) continuous_const (g := fun _ : ℝ => ()) + (continuousAt_const (x := 1)) (P := fun h p => (Z (h,p)).2∈injectivityDomain (Z (h,p)).1) + (by + intro p _ _ + change ∀ᶠ q in 𝓝 (1,p), Z q ∈ {z : TangentBundle 𝓘(ℝ,Model n) M | z.2∈injectivityDomain z.1} + apply hZ.continuous.continuousAt.eventually + apply isOpen_total_injectivityDomain.mem_nhds + change (1-(1:ℝ)) • (sprayFlow 1 p).2∈injectivityDomain (sprayFlow 1 p).1 + rw [sub_self,zero_smul] + exact zero_mem_injectivityDomain _) + exact H.mono fun _ hshift base velocity hbound => + hshift ⟨base,velocity⟩ hbound rfl + +lemma exists_uniform_regular_split (R : ℝ) : + ∃ h : ℝ, 0 < h ∧ h < 1 ∧ ∀ x : M, + ∀ p : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖ ≤ R → p∈minimizingVectors x → + h • p∈injectivityDomain x ∧ + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + have H : ∀ᶠ h in 𝓝[<] (1:ℝ), 0 < h ∧ h < 1 ∧ ∀ x : M, + ∀ p : TangentSpace 𝓘(ℝ,Model n) x, ‖p‖ ≤ R → + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + filter_upwards [(uniformly_shifted_injectivityDomain_near_one (n := n) (M := M) R).filter_mono nhdsWithin_le_nhds, + (eventually_gt_nhds (show (0:ℝ)<1 by norm_num)).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with h hh h0 h1 + exact ⟨h0,h1,hh⟩ + obtain ⟨h,h0,h1,hh⟩ := H.exists + exact ⟨h,h0,h1,fun x p hp hm => + ⟨contracted_minimizer_mem_injectivityDomain hm h0 h1,hh x p hp⟩⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformReverseGain.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformReverseGain.lean new file mode 100644 index 0000000000000000000000000000000000000000..a1dd6ca082e3873b60afa7c8571b03d7c56fe840 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UniformReverseGain.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.UniformFixedCrossing +import OAI.Analysis.BiholderTransport.Regularity.UniformMixedBound +import OAI.Analysis.BiholderTransport.Regularity.UniformIntervalCrossing +import OAI.Analysis.BiholderTransport.Coordinates.ReverseIsotropicGain + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_uniform_reverse_divided_gain : + ∃ c>0, ∀ᶠ z : ℝ×ℝ in 𝓝 (1,1), z.1≤z.2 → z.2<1 → + ∀ x y : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ∀ q : TangentSpace 𝓘(ℝ,Model n) y, + p∈minimizingVectors x → q∈injectivityDomain y → + riemannianExp x (z.1 • p)=y → riemannianExp y q=x → + ∃ R : TangentSpace 𝓘(ℝ,Model n) y → TangentSpace 𝓘(ℝ,Model n) x, + ContDiffAt ℝ ∞ R q ∧ R q=0 ∧ + (∀ᶠ w in 𝓝 q, riemannianExp x (R w)=riemannianExp y w) ∧ + ∀ w : TangentSpace 𝓘(ℝ,Model n) y, + c*(z.2-z.1)*‖w‖^2 ≤ + hessianValue x (z.1 • p) (fderiv ℝ R q w)/z.1- + hessianValue x (z.2 • p) (fderiv ℝ R q w)/z.2 := by + obtain ⟨h,hh,hh1,Hsplit⟩ := exists_actual_uniform_regular_split (n := n) (M := M) + obtain ⟨c,hc,C,hC,HC⟩ := fixedJoinMiddle_uniform_interval_crossing hh hh1 Hsplit + obtain ⟨B,hB,HB⟩ := normalEndpointMixedOperator_uniform_bound hh hh1 Hsplit + have Hnear : Tendsto (fun z : ℝ×ℝ => h/z.1) (𝓝 (1,1)) (𝓝 h) := by + have H : ContinuousAt (fun z : ℝ×ℝ => h/z.1) (1,1) := + continuousAt_const.div continuousAt_fst (by norm_num) + simpa only [div_one] using H.tendsto + have Hpos : ∀ᶠ z : ℝ×ℝ in 𝓝 (1,1), h (hz hhs ht1 hst x p hp v).1) hbound + refine ⟨R,hR,hR0,hRi,?_⟩ + intro w + convert HR w using 1 + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/CostGeometry/UpperTest.lean b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UpperTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..24b88ceff502f048827f602ddb5429ea9e29339f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/CostGeometry/UpperTest.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.TrialBlowup +import OAI.Analysis.BiholderTransport.Contact.AEContacts +import OAI.Analysis.BiholderTransport.Contact.BranchContact + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section UpperTest +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [MeasurableSpace M] [BorelSpace M] in +lemma active_nonconjugate_of_smooth_upper_test {v : M → ℝ} (hv : Continuous v) + {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈activeLogs (n := n) v x) + {φ : TangentSpace 𝓘(ℝ,Model n) x → ℝ} + (hφ : ContDiffAt ℝ 2 φ 0) (hφ0 : φ 0=cTransform v x) + (hupper : ∀ᶠ h in 𝓝 0, cTransform v (riemannianExp x h)≤φ h) : + Function.Injective (fderiv ℝ (fun q => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x q)) p) := by + have hcoord := mfderiv_comp p (mdifferentiableAt_extChartAt + (I := 𝓘(ℝ,Model n)) (mem_chart_source (Model n) (riemannianExp x p))) + ((contMDiff_riemannianExp_fiber x p).mdifferentiableAt (by simp)) + rw [mfderiv_eq_fderiv,mfderiv_extChartAt_self] at hcoord + change fderiv ℝ _ p=mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) + 𝓘(ℝ,Model n) (riemannianExp x) p at hcoord + simp only [Function.comp_def] at hcoord + erw [hcoord] + apply (LinearMap.ker_eq_bot).mp + apply LinearMap.ker_eq_bot'.mpr + intro k hk + by_contra hk0 + have hpair : inner ℝ k k≠0 := by + rw [real_inner_self_eq_norm_sq] + exact (sq_pos_of_pos (norm_pos_iff.mpr hk0)).ne' + have hblow := conjugate_radial_hessian_tendsto_atBot hp.1 hk hpair + let B := fderiv ℝ (fderiv ℝ φ) 0 k k + have hlow : ∀ᶠ r : ℝ in 𝓝[<] 1, -|B|≤hessianValue x (r • p) k := by + filter_upwards [(eventually_gt_nhds (show (0:ℝ)<1 by norm_num)).filter_mono + nhdsWithin_le_nhds,self_mem_nhdsWithin] with r hr hr1 + have hID := contracted_minimizer_mem_injectivityDomain hp.1 hr hr1 + let F := fun h => (φ h-φ 0)-(-r⁻¹)*(normalCost x (r • p) h-normalCost x (r • p) 0) + have hC : ContDiffAt ℝ 2 (normalCost x (r • p)) 0 := + (normalCost_contDiffAt hID).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hF : ContDiffAt ℝ 2 F 0 := + (hφ.sub contDiffAt_const).sub (contDiffAt_const.mul (hC.sub contDiffAt_const)) + have hm : IsLocalMin F 0 := by + filter_upwards [hupper] with h hh + have hs := active_split_lower_support hv hp.1 hp.2 hr hr1 (riemannianExp x h) + change F 0≤F h + have he : F h=φ h-cTransform v x+ + (cost (riemannianExp x h) (riemannianExp x (r • p))- + cost x (riemannianExp x (r • p)))/r := by + simp only [F,normalCost,riemannianExp_zero,hφ0,div_eq_mul_inv] + ring + rw [show F 0=0 by simp [F],he] + rw [neg_div] at hs + linarith + have H := localMin_hessian_nonneg hF hm k + have He := second_fderiv_scaled_differences hφ hC 1 (-r⁻¹) k + simp only [one_mul] at He + change fderiv ℝ (fderiv ℝ F) 0 k k=_ at He + rw [He] at H + change 0≤B-(-r⁻¹)*normalHessian x (r • p) k k at H + rw [←hessianValue_eq_normalHessian hID] at H + have H' : 0≤B+hessianValue x (r • p) k/r := by + simpa only [B,normalHessian,neg_mul,sub_neg_eq_add,div_eq_mul_inv,mul_comm] using H + have Hb : r*B≤|B| := by + calc + r*B≤r*|B| := mul_le_mul_of_nonneg_left (le_abs_self _) hr.le + _≤1*|B| := mul_le_mul_of_nonneg_right hr1.le (abs_nonneg _) + _=|B| := one_mul _ + have H'' := (le_div_iff₀ hr).mp (show -B≤hessianValue x (r • p) k/r by linarith) + nlinarith + have hlt := hblow.eventually (eventually_lt_atBot (-|B|)) + obtain ⟨r,hr,hr'⟩ := (hlow.and hlt).exists + exact (not_lt_of_ge hr) hr' + +omit [MeasurableSpace M] [BorelSpace M] in +lemma active_before_cut_of_differentiable_upper_test {v : M → ℝ} (hv : Continuous v) + {x : M} + (hDiff : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {φ : TangentSpace 𝓘(ℝ,Model n) x → ℝ} + (hφ : ContDiffAt ℝ 2 φ 0) (hφ0 : φ 0=cTransform v x) + (hupper : ∀ᶠ h in 𝓝 0, cTransform v (riemannianExp x h)≤φ h) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈activeLogs (n := n) v x) : + p∈injectivityDomain x := by + apply mem_injectivityDomain_of_unique_nonconjugate _ + (active_nonconjugate_of_smooth_upper_test hv hp hφ hφ0 hupper) + intro q hq heq + have hqA : q∈activeLogs (n := n) v x := ⟨hq,by simpa only [heq] using hp.2⟩ + have H := (active_log_derivative hv hDiff hqA).unique (active_log_derivative hv hDiff hp) + apply ext_inner_right ℝ + intro h + exact congrArg (fun D : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => D h) H + +end UpperTest +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/AEDual.lean b/lean/OAI/Analysis/BiholderTransport/Duality/AEDual.lean new file mode 100644 index 0000000000000000000000000000000000000000..60693a92cbfa6b6b32de724e4d45ee71e512eae5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/AEDual.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.DualVariation + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Metric +open scoped Topology ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section AEDual +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + +omit [MeasurableSpace M] [BorelSpace M] in +lemma boundedCTransform_perturbation_lipschitz (v f : M →ᵇ ℝ) (x : M) : + LipschitzWith ‖f‖₊ (fun t : ℝ => boundedCTransform (v+t • f) x) := by + apply LipschitzWith.of_dist_le_mul + intro t s + have hp := BoundedContinuousFunction.dist_coe_le_dist + (f := boundedCTransform (v+t • f)) (g := boundedCTransform (v+s • f)) x + apply hp.trans + have H := boundedCTransform_nonexpansive.dist_le_mul (v+t • f) (v+s • f) + simp only [NNReal.coe_one,one_mul] at H + refine H.trans_eq ?_ + rw [dist_eq_norm,add_sub_add_left_eq_sub,← sub_smul t s f,norm_smul,Real.norm_eq_abs,Real.dist_eq] + exact mul_comm _ _ + +lemma dual_minimum_integral_eq_ae (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] (v : M →ᵇ ℝ) (T : M → M) + (hT : AEMeasurable T mu) + (hfib : ∀ᵐ x ∂mu, contactGap (boundedCTransform v) v x (T x)=0 ∧ + ∀ y, contactGap (boundedCTransform v) v x y=0 → y=T x) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0≤contactGap a b x y) → + dualObjective mu nu (boundedCTransform v,v)≤dualObjective mu nu (a,b)) + (f : M →ᵇ ℝ) : (∫ x, f (T x) ∂mu)=∫ y,f y ∂nu := by + have hmeas : AEStronglyMeasurable (fun x => -f (T x)) mu := + (f.continuous.measurable.comp_aemeasurable hT).aestronglyMeasurable.neg + have hdiff : ∀ᵐ x ∂mu, HasDerivAt + (fun t : ℝ => boundedCTransform (v+t • f) x) (-f (T x)) 0 := by + filter_upwards [hfib] with x hx + exact boundedCTransform_perturbation_hasDerivAt v f hx.1 hx.2 + have hlip : ∀ᵐ x ∂mu, LipschitzOnWith (Real.nnabs ‖f‖) + (fun t : ℝ => boundedCTransform (v+t • f) x) univ := by + filter_upwards [] with x + simpa only [show Real.nnabs ‖f‖ = ‖f‖₊ from by ext; simp] using (boundedCTransform_perturbation_lipschitz v f x).lipschitzOnWith + obtain ⟨_,hder⟩ := hasDerivAt_integral_of_dominated_loc_of_lip + (F := fun t x => boundedCTransform (v+t • f) x) + (F' := fun x => -f (T x)) (bound := fun _ => ‖f‖) + (s := univ) (mem_of_superset (Filter.univ_mem) (by simp)) + (Filter.Eventually.of_forall fun t => (boundedCTransform (v+t • f)).continuous.aestronglyMeasurable) + (by simpa only [zero_smul,add_zero] using (boundedCTransform v).integrable mu) + hmeas hlip (integrable_const _) hdiff + have hlin : HasDerivAt (fun t : ℝ => ∫ y, (v+t • f) y ∂nu) (∫ y,f y ∂nu) 0 := by + have H := (hasDerivAt_const (0:ℝ) (∫ y,v y ∂nu)).add + ((hasDerivAt_id (0:ℝ)).mul_const (∫ y,f y ∂nu)) + simpa only [Pi.add_def,Pi.add_apply,id_eq,zero_add,one_mul,BoundedContinuousFunction.add_apply, + BoundedContinuousFunction.smul_apply,smul_eq_mul,integral_add (v.integrable nu) + ((f.integrable nu).const_mul _),integral_const_mul] using H + have hsum := hder.add hlin + have hlocal : IsLocalMin (fun t : ℝ => (∫ x,boundedCTransform (v+t • f) x ∂mu)+ + ∫ y,(v+t • f) y ∂nu) 0 := by + filter_upwards [] with t + simpa only [zero_smul,add_zero,dualObjective] using + hmin (boundedCTransform (v+t • f)) (v+t • f) + (cTransform_gap_nonneg (v+t • f).continuous) + have H := hlocal.hasDerivAt_eq_zero hsum + rw [integral_neg] at H + linarith + +lemma dual_minimum_pushforward_ae (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] (v : M →ᵇ ℝ) (T : M → M) + (hT : AEMeasurable T mu) + (hfib : ∀ᵐ x ∂mu, contactGap (boundedCTransform v) v x (T x)=0 ∧ + ∀ y, contactGap (boundedCTransform v) v x y=0 → y=T x) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0≤contactGap a b x y) → + dualObjective mu nu (boundedCTransform v,v)≤dualObjective mu nu (a,b)) : + Measure.map T mu=nu := by + apply ext_of_forall_integral_eq_of_IsFiniteMeasure + intro f + rw [integral_map hT f.continuous.aestronglyMeasurable] + exact dual_minimum_integral_eq_ae mu nu v T hT hfib hmin f + +end AEDual +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/ActualLowerJet.lean b/lean/OAI/Analysis/BiholderTransport/Duality/ActualLowerJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..60111b026b95186cfafa59c01bca00d61ca5bc24 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/ActualLowerJet.lean @@ -0,0 +1,135 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ActualTransferInequality +import OAI.Analysis.BiholderTransport.CostGeometry.ActualPoleKernel +import OAI.Analysis.BiholderTransport.Calculus.WeightedDefect + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.actualPole_residual_taylor (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t : ℝ} (ht : 0 + hopfLax t u (riemannianExp x (t • (p+d)))-t*(‖p+d‖^2/2)) + 0 (-((innerSL ℝ).comp R)) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have H := (hmtw.actualPole_taylor hu hv hdual ht ht1 hp ha ha0 harep).1.sub + ((norm_square_hasSecondTaylor p).const_mul t) + have hlin : t • innerSL ℝ p-t • innerSL ℝ p=(0:V →L[ℝ] ℝ) := sub_self _ + have hbil : (t • (innerSL ℝ (E := V))-(innerSL ℝ).comp R)-t • innerSL ℝ = + -((innerSL ℝ).comp R) := by + apply ContinuousLinearMap.ext; intro d + apply ContinuousLinearMap.ext; intro e + change (t*inner ℝ d e-inner ℝ (R d) e)-t*inner ℝ d e = -inner ℝ (R d) e + ring + rw [hlin,hbil] at H + exact H + +lemma WeakMTW.actual_active_lower_jet (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t s : ℝ} (ht : 0 + v (riemannianExp x (pj i+d))+‖pj i+d‖^2/2) 0 + (w i • ((innerSL ℝ).comp R)) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let p : V := ∑ j,w j • pj j + have hs : 0 (hw j).le) hsum + (fun j _ => subset_convexHull ℝ _ (mem_range_self j)) + have hp := hID p hpH + have hkernel : ∀ j, R (pj j-p)=0 := fun j => + hmtw.actualPole_kernel hu hv hdual ht ht1 hs hs1 hp (hmin j) (hactive j) + (hleft j) (hright j) ha ha0 harep + have hsym := (hmtw.actualPole_taylor hu hv hdual ht ht1 hp ha ha0 harep).2.2 + obtain ⟨B,hB,hBdiag⟩ := prefixDefect_taylor ht.ne' hp + have HC := fun j => splitDefect_taylor hs hs1 (hleft j) (hright j) + choose C hC hCdiag using HC + obtain ⟨D,hD,hDdiag⟩ := weighted_defect_taylor w pj i hB hC hBdiag hCdiag + let J : V →L[ℝ] V := w i • ContinuousLinearMap.id ℝ V + have hres := (hmtw.actualPole_residual_taylor hu hv hdual ht ht1 hp ha ha0 harep).comp_linear J + have hq : HasFDerivAt (fun d:V => p+w i • d) J 0 := by + exact ((hasFDerivAt_id (𝕜 := ℝ) (0:V)).const_smul (w i)).const_add p + have hA : HasFDerivAt (fun d:V => (a (p+w i • d),d)) + ((R.comp J).prod (ContinuousLinearMap.id ℝ V)) 0 := by + have HA := (show HasFDerivAt a R (p+w i • (0:V)) from by + simpa only [smul_zero,add_zero] using ha).comp 0 hq + exact HA.prodMk (hasFDerivAt_id (𝕜 := ℝ) (0:V)) + have hA0 : (a (p+w i • (0:V)),(0:V))=0 := by + change (a (p+w i • (0:V)),(0:V))=(0,0) + rw [smul_zero,add_zero,show a p=0 from ha0] + have Hineq := hmtw.actual_transfer_inequality hu hv hdual ht ht1 hs hs1 pj w + (fun j => (hw j).le) hsum i hp hmin hactive hleft hright ha.continuousAt ha0 harep + have Hlow := lowerTaylor_of_stationary_transfer hD hA hA0 hres (hw i) + (by simpa only [ContinuousLinearMap.zero_comp,zero_apply,sub_zero,J, + smul_apply,ContinuousLinearMap.id_apply] using Hineq) + apply Hlow.mono_diagonal + intro d + let r : V := R (J d) + have horth : ∀ j,inner ℝ r (pj j-p)=0 := by + intro j + change inner ℝ (R (J d)) (pj j-p)=0 + rw [hsym,hkernel,inner_zero_right] + have hQ : 0≤hessianValue x (t • p) r/t-∑ j,w j*(hessianValue x (s • pj j) r/s) := by + by_cases hr : r=0 + · rw [hr] + simp only [hessianValue_eq_normalHessian hp,hessianValue_eq_normalHessian (hleft _), + map_zero,zero_div,mul_zero,Finset.sum_const_zero,sub_zero,le_refl] + · exact sub_nonneg.mpr (hmtw.finite_transverse_slack_strict pj w hw hsum hmin ht hts hs1 hID hr horth).le + change w i*inner ℝ (R d) d ≤ (w i)⁻¹ * + (D (R (J d),d) (R (J d),d)-(-((innerSL ℝ).comp R)) (J d) (J d)) + rw [hDdiag] + have hinner : (-((innerSL ℝ).comp R)) (J d) (J d) = -(w i)^2*inner ℝ (R d) d := by + change -inner ℝ (R (w i • d)) (w i • d)=_ + rw [map_smul,real_inner_smul_left,real_inner_smul_right] + ring + rw [hinner] + have H := mul_nonneg (inv_nonneg.mpr (hw i).le) hQ + have hid : (w i)⁻¹*((w i)^2*inner ℝ (R d) d)=w i*inner ℝ (R d) d := by + field_simp [(hw i).ne'] + dsimp only [r] at H + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/CompactDual.lean b/lean/OAI/Analysis/BiholderTransport/Duality/CompactDual.lean new file mode 100644 index 0000000000000000000000000000000000000000..96d9e16c868caed2f1cff61aa98b117b6f2ad0cd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/CompactDual.lean @@ -0,0 +1,272 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder +open scoped BoundedContinuousFunction + +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +lemma cTransform_le_iff {v : M → ℝ} (hv : Continuous v) (x : M) (a : ℝ) : + cTransform v x ≤ a ↔ ∀ y, -cost x y - v y ≤ a := by + obtain ⟨y, hy, hmax⟩ := exists_cTransform_contact hv x + constructor + · intro h z + exact (hmax z).trans h + · intro h + rw [hy] + exact h y + +lemma cTransform_antitone {v w : M → ℝ} (hv : Continuous v) (hw : Continuous w) + (h : ∀ x, v x ≤ w x) : ∀ x, cTransform w x ≤ cTransform v x := by + intro x + rw [cTransform_le_iff hw] + intro y + have hh := ((cTransform_le_iff hv x (cTransform v x)).mp le_rfl) y + linarith [h y] + +lemma cTransform_cTransform_le {v : M → ℝ} (hv : Continuous v) (x : M) : + cTransform (cTransform v) x ≤ v x := by + rw [cTransform_le_iff (continuous_cTransform hv)] + intro y + have hh := cTransform_gap_nonneg hv y x + rw [contactGap, cost_symm y x] at hh + linarith + +lemma cTransform_triple {v : M → ℝ} (hv : Continuous v) : + cTransform (cTransform (cTransform v)) = cTransform v := by + funext x + exact le_antisymm (cTransform_cTransform_le (continuous_cTransform hv) x) + (cTransform_antitone (continuous_cTransform (continuous_cTransform hv)) hv + (cTransform_cTransform_le hv) x) + +lemma cTransform_add_const {v : M → ℝ} (hv : Continuous v) (a : ℝ) : + cTransform (fun x => v x + a) = fun x => cTransform v x - a := by + funext x + apply le_antisymm + · rw [cTransform_le_iff (v := fun x => v x + a) (hv.add continuous_const)] + intro y + have hh := ((cTransform_le_iff hv x (cTransform v x)).mp le_rfl) y + linarith + · obtain ⟨y, hy, _⟩ := exists_cTransform_contact hv x + have hh := cTransform_gap_nonneg (v := fun x => v x + a) (hv.add continuous_const) x y + dsimp [contactGap] at hh + linarith + +lemma cTransform_zero : cTransform (fun _ : M => (0 : ℝ)) = fun _ => 0 := by + funext x + apply le_antisymm + · rw [cTransform_le_iff continuous_const] + intro y + linarith [cost_nonneg x y] + · have h := cTransform_gap_nonneg (v := fun _ : M => (0 : ℝ)) continuous_const x x + simpa [contactGap, cost] using h + +def boundedCTransform (v : M →ᵇ ℝ) : M →ᵇ ℝ := + BoundedContinuousFunction.mkOfCompact ⟨cTransform v, continuous_cTransform v.continuous⟩ + +lemma boundedCTransform_apply (v : M →ᵇ ℝ) (x : M) : + boundedCTransform v x = cTransform v x := rfl + +lemma boundedCTransform_nonexpansive : LipschitzWith 1 (boundedCTransform (M := M)) := by + apply LipschitzWith.of_dist_le_mul + intro v w + simp only [NNReal.coe_one, one_mul] + apply (BoundedContinuousFunction.dist_le dist_nonneg).mpr + intro x + rw [Real.dist_eq, abs_le] + have hbound (a b : M →ᵇ ℝ) : cTransform a x - cTransform b x ≤ dist a b := by + rw [sub_le_iff_le_add, cTransform_le_iff a.continuous] + intro y + have hg := cTransform_gap_nonneg b.continuous x y + have hd := BoundedContinuousFunction.dist_coe_le_dist (f := a) (g := b) y + rw [Real.dist_eq, abs_le] at hd + dsimp [contactGap] at hg + linarith [hd.1] + constructor + · have hh := hbound w v + rw [dist_comm w v] at hh + change -dist v w ≤ cTransform v x - cTransform w x + linarith + · exact hbound v w + +omit [Nonempty M] in + +lemma isCompact_bounded_lipschitz (D : ℝ≥0) (H : ℝ) : + IsCompact {f : M →ᵇ ℝ | LipschitzWith D f ∧ ∀ x, |f x| ≤ H} := by + let A : Set (M →ᵇ ℝ) := {f | LipschitzWith D f ∧ ∀ x, |f x| ≤ H} + have hclosed : IsClosed A := by + apply IsClosed.inter + · exact (isClosed_setOfPred_lipschitzWith (α := M) (β := ℝ) D).preimage + (BoundedContinuousFunction.continuous_coe : Continuous (fun f : M →ᵇ ℝ => (f : M → ℝ))) + · change IsClosed {f : M →ᵇ ℝ | ∀ x, |f x| ≤ H} + rw [Set.ofPred_forall] + apply isClosed_iInter + intro x + exact isClosed_le ((continuous_apply x).comp BoundedContinuousFunction.continuous_coe).abs + continuous_const + apply BoundedContinuousFunction.arzela_ascoli₂ (Icc (-H) H) isCompact_Icc A hclosed + · intro f x hf + exact abs_le.mp (hf.2 x) + · intro x + rw [Metric.equicontinuousAt_iff] + intro eps heps + refine ⟨eps / ((D : ℝ) + 1), by positivity, ?_⟩ + intro y hy f + have h := f.property.1.dist_le_mul y x + have hstrict : (D : ℝ) * dist y x < eps := by + have hy' := hy + have hD : 0 ≤ (D : ℝ) := D.coe_nonneg + have he := (lt_div_iff₀ (show 0 < (D : ℝ) + 1 by positivity)).mp hy' + nlinarith [dist_nonneg (x := y) (y := x)] + simpa only [dist_comm] using h.trans_lt hstrict + +def normalizedDualPairs (x0 : M) : Set ((M →ᵇ ℝ) × (M →ᵇ ℝ)) := + {uv | uv.1 x0 = 0 ∧ boundedCTransform uv.2 = uv.1 ∧ boundedCTransform uv.1 = uv.2} + +lemma isClosed_normalizedDualPairs (x0 : M) : IsClosed (normalizedDualPairs x0) := by + apply IsClosed.inter + · exact isClosed_eq (((continuous_apply x0).comp + BoundedContinuousFunction.continuous_coe).comp continuous_fst) continuous_const + · apply IsClosed.inter + · exact isClosed_eq (boundedCTransform_nonexpansive.continuous.comp continuous_snd) continuous_fst + · exact isClosed_eq (boundedCTransform_nonexpansive.continuous.comp continuous_fst) continuous_snd + +lemma normalizedDualPairs_nonempty (x0 : M) : (normalizedDualPairs x0).Nonempty := by + refine ⟨(0, 0), rfl, ?_, ?_⟩ <;> + apply BoundedContinuousFunction.ext <;> + intro x <;> + exact congrFun cTransform_zero x + +lemma normalizedDualPairs_bounds {D : ℝ≥0} (hD : ∀ x y : M, dist x y ≤ D) + {x0 : M} {uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)} (h : uv ∈ normalizedDualPairs x0) : + (LipschitzWith D uv.1 ∧ ∀ x, |uv.1 x| ≤ (D : ℝ) ^ 2) ∧ + (LipschitzWith D uv.2 ∧ ∀ x, |uv.2 x| ≤ (D : ℝ) ^ 2) := by + have hu : (uv.1 : M → ℝ) = cTransform uv.2 := congrArg (fun f : M →ᵇ ℝ => (f : M → ℝ)) h.2.1.symm + have hv : (uv.2 : M → ℝ) = cTransform uv.1 := congrArg (fun f : M →ᵇ ℝ => (f : M → ℝ)) h.2.2.symm + have hLu : LipschitzWith D uv.1 := by + rw [hu] + exact cTransform_lipschitz uv.2.continuous hD + have hLv : LipschitzWith D uv.2 := by + rw [hv] + exact cTransform_lipschitz uv.1.continuous hD + have hbu (x : M) : |uv.1 x| ≤ (D : ℝ) ^ 2 := by + have hh := hLu.dist_le_mul x x0 + rw [h.1, Real.dist_eq, sub_zero] at hh + exact hh.trans (by nlinarith [mul_le_mul_of_nonneg_left (hD x x0) D.coe_nonneg]) + refine ⟨⟨hLu, hbu⟩, hLv, ?_⟩ + intro x + rw [abs_le, hv] + constructor + · have hh := cTransform_gap_nonneg uv.1.continuous x x0 + rw [contactGap, h.1, cost] at hh + have hdist := hD x x0 + have hd0 : 0 ≤ dist x x0 := dist_nonneg + nlinarith [D.coe_nonneg, sq_nonneg ((D : ℝ) - dist x x0)] + · rw [cTransform_le_iff uv.1.continuous] + intro y + have hb := (abs_le.mp (hbu y)).1 + linarith [cost_nonneg x y] + +lemma isCompact_normalizedDualPairs (x0 : M) : IsCompact (normalizedDualPairs x0) := by + let D : ℝ≥0 := ⟨Metric.diam (univ : Set M), Metric.diam_nonneg⟩ + have hD (x y : M) : dist x y ≤ D := + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + refine ((isCompact_bounded_lipschitz D ((D : ℝ) ^ 2)).prod + (isCompact_bounded_lipschitz D ((D : ℝ) ^ 2))).of_isClosed_subset + (isClosed_normalizedDualPairs x0) ?_ + intro uv huv + exact normalizedDualPairs_bounds hD huv + +variable [MeasurableSpace M] [BorelSpace M] + +omit [CompactSpace M] [Nonempty M] in +lemma integral_boundedContinuous_lipschitz (mu : Measure M) [IsProbabilityMeasure mu] : + LipschitzWith 1 (fun f : M →ᵇ ℝ => ∫ x, f x ∂mu) := by + apply LipschitzWith.of_dist_le_mul + intro f g + simp only [NNReal.coe_one, one_mul, dist_eq_norm] + have heq : (∫ x, f x ∂mu) - (∫ x, g x ∂mu) = ∫ x, (f - g) x ∂mu := + (integral_sub (f.integrable mu) (g.integrable mu)).symm + rw [heq] + exact (f - g).norm_integral_le_norm mu + +def dualObjective (mu nu : Measure M) (uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)) : ℝ := + (∫ x, uv.1 x ∂mu) + ∫ y, uv.2 y ∂nu + +omit [CompactSpace M] [Nonempty M] in +lemma continuous_dualObjective (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] : Continuous (dualObjective mu nu) := + ((integral_boundedContinuous_lipschitz mu).continuous.comp continuous_fst).add + ((integral_boundedContinuous_lipschitz nu).continuous.comp continuous_snd) + +lemma exists_minimizing_normalizedDualPair (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] (x0 : M) : + ∃ uv ∈ normalizedDualPairs x0, IsMinOn (dualObjective mu nu) (normalizedDualPairs x0) uv := by + exact (isCompact_normalizedDualPairs x0).exists_isMinOn (normalizedDualPairs_nonempty x0) + (continuous_dualObjective mu nu).continuousOn + +def normalizeDualPair (x0 : M) (v : M →ᵇ ℝ) : (M →ᵇ ℝ) × (M →ᵇ ℝ) := + let a := boundedCTransform v + (a + BoundedContinuousFunction.const M (-a x0), + boundedCTransform a + BoundedContinuousFunction.const M (a x0)) + +omit [MeasurableSpace M] [BorelSpace M] in +lemma normalizeDualPair_mem (x0 : M) (v : M →ᵇ ℝ) : + normalizeDualPair x0 v ∈ normalizedDualPairs x0 := by + let a := boundedCTransform v + change (a x0 + -a x0 = 0) ∧ _ ∧ _ + refine ⟨add_neg_cancel _, ?_, ?_⟩ + · apply BoundedContinuousFunction.ext + intro x + change cTransform (fun y => cTransform a y + a x0) x = a x + -a x0 + rw [cTransform_add_const (continuous_cTransform a.continuous)] + have hh := congrFun (cTransform_triple v.continuous) x + change cTransform (cTransform a) x = a x at hh + exact (congrArg (fun t : ℝ => t - a x0) hh).trans (by ring) + · apply BoundedContinuousFunction.ext + intro x + change cTransform (fun y => a y + -a x0) x = cTransform a x + a x0 + rw [cTransform_add_const a.continuous] + ring + +omit [CompactSpace M] [Nonempty M] in +lemma dualObjective_add_constants (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] (a b : M →ᵇ ℝ) (k : ℝ) : + dualObjective mu nu (a + BoundedContinuousFunction.const M (-k), + b + BoundedContinuousFunction.const M k) = dualObjective mu nu (a,b) := by + change (∫ x, (a x + -k) ∂mu) + (∫ y, (b y + k) ∂nu) = _ + rw [integral_add (a.integrable mu) (integrable_const _), + integral_add (b.integrable nu) (integrable_const _)] + simp only [integral_const, Measure.real, measure_univ, ENNReal.toReal_one, one_smul] + dsimp [dualObjective] + ring + +lemma dualObjective_normalize_le (mu nu : Measure M) [IsProbabilityMeasure mu] + [IsProbabilityMeasure nu] (x0 : M) (u v : M →ᵇ ℝ) + (h : ∀ x y, 0 ≤ contactGap u v x y) : + dualObjective mu nu (normalizeDualPair x0 v) ≤ dualObjective mu nu (u,v) := by + rw [normalizeDualPair, dualObjective_add_constants] + apply add_le_add + · apply integral_mono (boundedCTransform v |>.integrable mu) (u.integrable mu) + intro x + rw [boundedCTransform_apply, cTransform_le_iff v.continuous] + intro y + have hh := h x y + dsimp [contactGap] at hh + linarith + · apply integral_mono (boundedCTransform (boundedCTransform v) |>.integrable nu) + (v.integrable nu) + exact cTransform_cTransform_le v.continuous + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/DualCompact.lean b/lean/OAI/Analysis/BiholderTransport/Duality/DualCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..11c60cc68ea24e8fe75a414f9a7d0e1abcea8685 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/DualCompact.lean @@ -0,0 +1,32 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section DualCompact +variable {E:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +local instance dualCompactGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance dualCompactSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +lemma exists_dual_limit [FiniteDimensional ℝ E] + {gj:ℕ → E →L[ℝ] ℝ} {C:ℝ} + (hb:∀ᶠ j in atTop,‖gj j‖≤C) : + ∃g:E →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ Tendsto (gj ∘ σ) atTop (𝓝 g) := by + let : FiniteDimensional ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.finiteDimensional + obtain ⟨N,hN⟩:=eventually_atTop.mp hb + have H : IsCompact (Metric.closedBall (0:E →L[ℝ] ℝ) C) := isCompact_closedBall _ _ + obtain ⟨g,hg,σ,hσ,hlim⟩:=H.tendsto_subseq (x := fun j => gj (j+N)) (fun j=>by + simpa only [Metric.mem_closedBall,dist_zero_right] using hN (j+N) (Nat.le_add_left _ _)) + exact ⟨g,fun j=>σ j+N,fun i j hij=>Nat.add_lt_add_right (hσ hij) N,hlim⟩ +end DualCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/DualFactor.lean b/lean/OAI/Analysis/BiholderTransport/Duality/DualFactor.lean new file mode 100644 index 0000000000000000000000000000000000000000..4176c4b86b8860afdbae929d0644508e42d75e2a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/DualFactor.lean @@ -0,0 +1,51 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +namespace WeakMTWTransport +section DualFactor +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [NormedAddCommGroup F] [InnerProductSpace ℝ F] + +lemma dual_factor_norm_comparison (Q : E →L[ℝ] E) (L A : E →L[ℝ] F) + {s c C : ℝ} (hs : 0 < s) (hc : 0 < c) (hC : 0 < C) + (hL : Function.Surjective L) + (hLn : ∀ k, c * ‖k‖ ≤ ‖L k‖ ∧ ‖L k‖ ≤ C * ‖k‖) + (h : ∀ a k, s * inner ℝ (Q a) k = inner ℝ (L k) (A a)) (a : E) : + c * ‖A a‖ ≤ s * ‖Q a‖ ∧ s * ‖Q a‖ ≤ C * ‖A a‖ := by + constructor + · obtain ⟨k,hk⟩ := hL (A a) + have H := h a k + rw [hk,real_inner_self_eq_norm_sq] at H + have H1 := real_inner_le_norm (Q a) k + have H2 := (hLn k).1 + rw [hk] at H2 + by_cases hz : ‖A a‖ = 0 + · rw [hz,mul_zero]; positivity + · have hp : 0 < ‖A a‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hz) + have H3 := mul_le_mul_of_nonneg_left H1 hs.le + have H4 := mul_le_mul_of_nonneg_left H2 (mul_nonneg hs.le (norm_nonneg (Q a))) + have H5 := mul_le_mul_of_nonneg_left H3 hc.le + nlinarith + · have H := h a (Q a) + rw [real_inner_self_eq_norm_sq] at H + have H1 := real_inner_le_norm (L (Q a)) (A a) + have H2 := mul_le_mul_of_nonneg_right (hLn (Q a)).2 (norm_nonneg (A a)) + by_cases hz : ‖Q a‖ = 0 + · rw [hz,mul_zero]; positivity + · have hp : 0 < ‖Q a‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hz) + nlinarith + +end DualFactor +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/DualVariation.lean b/lean/OAI/Analysis/BiholderTransport/Duality/DualVariation.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed853c6f3dae08fc7a23a7e0815ac97c4ab2b22f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/DualVariation.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.CompactDual + +namespace OAI + +section + +section + +noncomputable section +open Set Filter MeasureTheory Metric +open scoped Topology ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section DualVariation +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +lemma contact_gap_level_control {v : M → ℝ} (hv : Continuous v) {x y₀ : M} + (huniq : ∀ y, contactGap (cTransform v) v x y=0 → y=y₀) + (f : M →ᵇ ℝ) {ε : ℝ} (hε : 0<ε) : + ∃ δ>0, ∀ y, contactGap (cTransform v) v x y≤δ → |f y₀-f y|≤ε := by + let G := fun y => contactGap (cTransform v) v x y + have hG : Continuous G := (continuous_const.add (continuous_cost_right x)).add hv + let A := {y | ε≤|f y₀-f y|} + have hA : IsCompact A := (isClosed_le continuous_const + ((continuous_const.sub f.continuous).abs)).isCompact + by_cases hne : A.Nonempty + · obtain ⟨z,hz,hmin⟩ := hA.exists_isMinOn hne hG.continuousOn + have hpos : 0 ?_⟩ + by_contra hh + have hm := hmin (le_of_lt (lt_of_not_ge hh)) + change G z≤G y at hm + change G y≤G z/2 at hy + linarith + · refine ⟨1,by norm_num,fun y _ => ?_⟩ + by_contra hh + exact hne ⟨y,le_of_lt (lt_of_not_ge hh)⟩ + +lemma boundedCTransform_perturbation_bound (v f : M →ᵇ ℝ) (t : ℝ) (x : M) : + |boundedCTransform (v+t • f) x-boundedCTransform v x|≤|t| *‖f‖ := by + have H := boundedCTransform_nonexpansive.norm_sub_le (v+t • f) v + have hp := BoundedContinuousFunction.norm_coe_le_norm + (boundedCTransform (v+t • f)-boundedCTransform v) x + simp only [BoundedContinuousFunction.sub_apply,Real.norm_eq_abs] at hp + apply hp.trans + simpa only [NNReal.coe_one,one_mul,add_sub_cancel_left,norm_smul,Real.norm_eq_abs] using H + +lemma boundedCTransform_perturbation_hasDerivAt (v f : M →ᵇ ℝ) {x y₀ : M} + (hy₀ : contactGap (boundedCTransform v) v x y₀=0) + (huniq : ∀ y, contactGap (boundedCTransform v) v x y=0 → y=y₀) : + HasDerivAt (fun t : ℝ => boundedCTransform (v+t • f) x) (-f y₀) 0 := by + rw [hasDerivAt_iff_isLittleO,Asymptotics.isLittleO_iff] + intro ε hε + obtain ⟨δ,hδ,hcontrol⟩ := contact_gap_level_control v.continuous huniq f hε + have hden : 0<2*‖f‖+1 := by positivity + filter_upwards [Metric.ball_mem_nhds (0:ℝ) (div_pos hδ hden)] with t ht + have ht' : |t|<δ/(2*‖f‖+1) := by simpa only [mem_ball,Real.dist_eq,sub_zero] using ht + have htδ : |t| *(2*‖f‖+1)<δ := (lt_div_iff₀ hden).mp ht' + obtain ⟨y,hy⟩ := cTransform_gap_zero (v+t • f).continuous x + have hgap := cTransform_gap_nonneg v.continuous x y + have hbound := boundedCTransform_perturbation_bound v f t x + have hf := BoundedContinuousFunction.norm_coe_le_norm f y + rw [Real.norm_eq_abs] at hf + have htf : |t*f y|≤|t| *‖f‖ := by rw [abs_mul]; exact mul_le_mul_of_nonneg_left hf (abs_nonneg t) + have hy' : boundedCTransform (v+t • f) x + cost x y+v y+t*f y=0 := by + simpa only [contactGap,BoundedContinuousFunction.add_apply,BoundedContinuousFunction.smul_apply, + smul_eq_mul,add_assoc,boundedCTransform_apply] using hy + have hsmall : contactGap (boundedCTransform v) v x y≤δ := by + dsimp only [contactGap] + nlinarith [(abs_le.mp hbound).1,(abs_le.mp htf).1,abs_nonneg t] + have hc := hcontrol y hsmall + have hrem := cTransform_gap_nonneg (v+t • f).continuous x y₀ + change 0≤boundedCTransform (v+t • f) x+cost x y₀+(v+t • f) y₀ at hrem + simp only [BoundedContinuousFunction.add_apply,BoundedContinuousFunction.smul_apply,smul_eq_mul] at hrem + dsimp only [contactGap] at hy₀ hgap + change 0≤boundedCTransform v x+cost x y+v y at hgap + have hab : |t*(f y₀-f y)|≤|t| *ε := by + rw [abs_mul] + exact mul_le_mul_of_nonneg_left hc (abs_nonneg t) + simp only [sub_zero,zero_smul,add_zero,smul_eq_mul,Real.norm_eq_abs] + rw [abs_le] + constructor + · nlinarith [mul_nonneg hε.le (abs_nonneg t)] + · nlinarith [(abs_le.mp hab).2] + +end DualVariation +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Duality/GeometricEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/Duality/GeometricEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..fca7f18b55d2c13baf0bdf9421d16361d49c4b52 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Duality/GeometricEnvelope.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GlobalSupport +import OAI.Analysis.BiholderTransport.Regularity.EuclideanUpper + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.subgradient_dual_contact (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈normalSubdifferential (n := n) u x) : + p∈minimizingVectors x ∧ contactGap u v x (riemannianExp x p)=0 := by + have hs := hmtw.global_support hv (show p∈normalSubdifferential (cTransform v) x by rwa [←hdual.1]) + rw [←hdual.1] at hs + refine ⟨hs.1,le_antisymm ?_ (dualPair_gap_nonneg hv hdual _ _)⟩ + have hc : v (riemannianExp x p) ≤ -u x-cost x (riemannianExp x p) := by + rw [hdual.2] + apply (cTransform_le_iff hu _ _).mpr + intro a + have H := hs.2 a + rw [cost_symm (riemannianExp x p) a] + linarith + dsimp [contactGap] + linarith + +lemma WeakMTW.dual_hopfLax_identity (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {t : ℝ} (ht : 0 -hopfLax (1-t) v z := by + funext z + obtain ⟨q,hq⟩ := surjective_graphProjection (n := n) hu ht z + have hc := hmtw.subgradient_dual_contact hu hv hdual q.2 + let y := riemannianExp q.1.1 q.1.2 + have hsplit := splitNormalAction_contact hc.1 ht ht1 + change cost (riemannianExp q.1.1 0) (graphProjection u t q)/t+ + cost (graphProjection u t q) y/(1-t) = cost (riemannianExp q.1.1 0) y at hsplit + rw [riemannianExp_zero,hq] at hsplit + have hleft := hopfLax_le hu t z q.1.1 + have hright := hopfLax_le hv (1-t) z y + rw [cost_symm y z] at hright + have hcontact : u q.1.1+cost q.1.1 y+v y=0 := hc.2 + have hnonneg := dual_hopfLax_sum_nonneg hu hv hdual ht ht1 z + linarith + +lemma WeakMTW.hopfLax_graph_value (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma dual_minimizer_rough_transport {lam cap : ℝ} {rho0 rho1 : M → ℝ} + (hlam : 0 < lam) + (hrho0 : AdmissibleDensity (metricVolume n) lam cap rho0) + (hrho1 : AdmissibleDensity (metricVolume n) lam cap rho1) + {u v : M →ᵇ ℝ} (hdual : IsCostDualPair u v) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (u,v) ≤ + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (a,b)) : + ∃ T S : M → M, + (∀ x, contactGap u v x (T x) = 0) ∧ + (∀ y, contactGap u v (S y) y = 0) ∧ + (∀ᵐ x ∂(metricVolume n), ∀ y, contactGap u v x y = 0 → y = T x) ∧ + (∀ᵐ y ∂(metricVolume n), ∀ x, contactGap u v x y = 0 → x = S y) ∧ + AEMeasurable T (densityMeasure (metricVolume n) rho0) ∧ + AEMeasurable S (densityMeasure (metricVolume n) rho1) ∧ + Measure.map T (densityMeasure (metricVolume n) rho0) = densityMeasure (metricVolume n) rho1 ∧ + Measure.map S (densityMeasure (metricVolume n) rho1) = densityMeasure (metricVolume n) rho0 := by + have : IsProbabilityMeasure (densityMeasure (metricVolume n) rho0) := + densityMeasure_probability hlam hrho0 + have : IsProbabilityMeasure (densityMeasure (metricVolume n) rho1) := + densityMeasure_probability hlam hrho1 + have hcontactT : ∀ x : M, ∃ y : M, contactGap u v x y = 0 := by + intro x + obtain ⟨y,hy,_⟩ := exists_cTransform_contact v.continuous x + refine ⟨y,?_⟩ + simp only [contactGap,hdual.1,hy] + ring + have hcontactS : ∀ y : M, ∃ x : M, contactGap u v x y = 0 := by + intro y + obtain ⟨x,hx,_⟩ := exists_cTransform_contact u.continuous y + refine ⟨x,?_⟩ + rw [contactGap_symm] + simp only [contactGap,hdual.2,hx] + ring + choose T hT using hcontactT + choose S hS using hcontactS + have hsingleT : ∀ᵐ x ∂(metricVolume n), + ∀ y, contactGap u v x y = 0 → y = T x := by + filter_upwards [cTransform_ae_singleton_contacts (n := n) v.continuous] with x hx + intro y hy + exact hx y (T x) (by simpa only [← hdual.1] using hy) + (by simpa only [← hdual.1] using hT x) + have hsingleS : ∀ᵐ y ∂(metricVolume n), + ∀ x, contactGap u v x y = 0 → x = S y := by + filter_upwards [cTransform_ae_singleton_contacts (n := n) u.continuous] with y hy + intro x hx + apply hy x (S y) + · simpa only [← hdual.2,← contactGap_symm u v x y] using hx + · simpa only [← hdual.2,← contactGap_symm u v (S y) y] using hS y + have hmaybeT := dual_minimum_ae_pushforward + (densityMeasure (metricVolume n) rho0) (densityMeasure (metricVolume n) rho1) v T + (by simpa only [← hdual.1] using hT) + (by + have he := (withDensity_absolutelyContinuous (metricVolume n) + (fun x => ENNReal.ofReal (rho0 x))).ae_le hsingleT + filter_upwards [he] with x hx + intro y hy + exact hx y (by simpa only [← hdual.1] using hy)) + (by + have he : boundedCTransform v = u := by + ext x; exact congrFun hdual.1.symm x + simpa only [he] using hmin) + have hmaybeS := dual_minimum_ae_pushforward + (densityMeasure (metricVolume n) rho1) (densityMeasure (metricVolume n) rho0) u S + (by intro y; simpa only [← hdual.2,← contactGap_symm u v (S y) y] using hS y) + (by + filter_upwards [(withDensity_absolutelyContinuous (metricVolume n) _).ae_le hsingleS] with y hy + intro x hx + apply hy x + simpa only [← hdual.2,← contactGap_symm u v x y] using hx) + (by + have he : boundedCTransform u = v := by + ext x; exact congrFun hdual.2.symm x + simpa only [he] using dual_minimum_swap hmin) + exact ⟨T,S,hT,hS,hsingleT,hsingleS,hmaybeT.1,hmaybeS.1,hmaybeT.2,hmaybeS.2⟩ + +lemma dual_minimizer_contactImage_mass {lam cap : ℝ} {rho0 rho1 : M → ℝ} + (hlam : 0 < lam) + (hrho0 : AdmissibleDensity (metricVolume n) lam cap rho0) + (hrho1 : AdmissibleDensity (metricVolume n) lam cap rho1) + {u v : M →ᵇ ℝ} (hdual : IsCostDualPair u v) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (u,v) ≤ + dualObjective (densityMeasure (metricVolume n) rho0) + (densityMeasure (metricVolume n) rho1) (a,b)) + {A : Set M} (hA : MeasurableSet A) : + NullMeasurableSet (contactImage u v A) (metricVolume n) ∧ + densityMeasure (metricVolume n) rho1 (contactImage u v A) = + densityMeasure (metricVolume n) rho0 A ∧ + ENNReal.ofReal lam * metricVolume n A ≤ + ENNReal.ofReal cap * metricVolume n (contactImage u v A) ∧ + ENNReal.ofReal lam * metricVolume n (contactImage u v A) ≤ + ENNReal.ofReal cap * metricVolume n A := by + obtain ⟨T,S,_,hS,_,hsingleS,_,hSmeas,_,hpushS⟩ := + dual_minimizer_rough_transport hlam hrho0 hrho1 hdual hmin + have hs : ∀ᵐ y ∂(densityMeasure (metricVolume n) rho1), + ∀ x, contactGap u v x y = 0 → x = S y := + (withDensity_absolutelyContinuous (metricVolume n) _).ae_le hsingleS + have hm := contactImage_measure hS hs hSmeas hpushS hA + refine ⟨?_,hm.2,(contactImage_volume_comparison hrho0 hrho1 hm.2).1, + (contactImage_volume_comparison hrho0 hrho1 hm.2).2⟩ + exact hm.1.mono_ac (volume_absolutelyContinuous_densityMeasure hlam hrho1) + +end RiemannianTransport +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/BranchExtension.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/BranchExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..e4e8fd608acd5c5485fded813c6bf9e93e6111c4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/BranchExtension.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions +import OAI.Analysis.BiholderTransport.Coordinates.RadialIdentity + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cost_branch_agrees_on_minimizing + {z : TangentBundle 𝓘(ℝ,Model n) M} {G : M × M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (z.1,riemannianExp z.1 z.2)) + (hagree : ∀ᶠ r in 𝓝 z, r.2 ∈ injectivityDomain r.1 → + (fun q : M × M => cost q.1 q.2) =ᶠ[𝓝 (r.1,riemannianExp r.1 r.2)] G) : + ∀ᶠ r in 𝓝 z, r.2 ∈ minimizingVectors r.1 → + cost r.1 (riemannianExp r.1 r.2) = G (r.1,riemannianExp r.1 r.2) := by + let F := fun r : TangentBundle 𝓘(ℝ,Model n) M => (r.1, riemannianExp r.1 r.2) + have hF : Continuous F := (FiberBundle.continuous_proj _ _).prodMk contMDiff_riemannianExp.continuous + have hGc : ∀ᶠ q in 𝓝 (F z), ContinuousAt G q := by + have H := (contMDiffAt_iff_contMDiffAt_nhds + (by norm_num : (1 : WithTop ℕ∞) ≠ (↑(⊤:ℕ∞) : WithTop ℕ∞))).mp + (hG.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 1)) + exact H.mono (fun q hq => hq.continuousAt) + filter_upwards [eventually_eventually_nhds.mpr hagree,hF.continuousAt.eventually hGc] with r hr hc hmin + have hrcl : r.2 ∈ closure (injectivityDomain r.1) := by rwa [closure_injectivityDomain] + have : NeBot (𝓝[injectivityDomain r.1] r.2) := mem_closure_iff_nhdsWithin_neBot.mp hrcl + have hi : Continuous (fun p : TangentSpace 𝓘(ℝ,Model n) r.1 => + (⟨r.1,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)) := + FiberBundle.continuous_totalSpaceMk (Model n) _ r.1 + have heq : (fun p => cost r.1 (riemannianExp r.1 p)) =ᶠ[𝓝[injectivityDomain r.1] r.2] + (fun p => G (r.1,riemannianExp r.1 p)) := by + filter_upwards [(hi.continuousAt.eventually hr).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with p hp hpID + exact (hp hpID).self_of_nhds + have he : Continuous (fun p : TangentSpace 𝓘(ℝ,Model n) r.1 => (r.1,riemannianExp r.1 p)) := + continuous_const.prodMk (contMDiff_riemannianExp_fiber (n := n) r.1).continuous + change ContinuousAt G (r.1,riemannianExp r.1 r.2) at hc + have hg : ContinuousAt (fun p : TangentSpace 𝓘(ℝ,Model n) r.1 => + G (r.1,riemannianExp r.1 p)) r.2 := hc.comp (f := fun p : TangentSpace 𝓘(ℝ,Model n) r.1 => + (r.1,riemannianExp r.1 p)) (he.continuousAt (x := r.2)) + apply tendsto_nhds_unique_of_eventuallyEq (l := 𝓝[injectivityDomain r.1] r.2) + (((continuous_cost_right r.1).comp + (contMDiff_riemannianExp_fiber (n := n) r.1).continuous).continuousAt.tendsto.mono_left nhdsWithin_le_nhds) + (hg.tendsto.mono_left nhdsWithin_le_nhds) heq + +lemma smooth_branch_normal_family {x : M} {r : TangentSpace 𝓘(ℝ,Model n) x} + {T : ℝ} {G : M × M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (x,riemannianExp x (T • r))) : + ContDiffAt ℝ ∞ (fun q : ℝ × TangentSpace 𝓘(ℝ,Model n) x => + G (riemannianExp x q.2,riemannianExp x (q.1 • r))) (T,0) := by + have hG' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (riemannianExp (n := n) x 0,riemannianExp x (T • r)) := by simpa only [riemannianExp_zero] using hG + have hL : ContMDiffAt 𝓘(ℝ,ℝ × TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) ∞ + (fun q : ℝ × TangentSpace 𝓘(ℝ,Model n) x => riemannianExp x q.2) (T,0) := + (contMDiff_riemannianExp_fiber x _).comp (T,0) contDiffAt_snd.contMDiffAt + have hR : ContMDiffAt 𝓘(ℝ,ℝ × TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) ∞ + (fun q : ℝ × TangentSpace 𝓘(ℝ,Model n) x => riemannianExp x (q.1 • r)) (T,0) := + (contMDiff_riemannianExp_fiber x _).comp (T,0) + (contDiffAt_fst.smul contDiffAt_const).contMDiffAt + exact (hG'.comp (T,0) (hL.prodMk hR)).contDiffAt + +lemma cost_branch_normal_eventuallyEq {x : M} {r : TangentSpace 𝓘(ℝ,Model n) x} + {T : ℝ} {G : M × M → ℝ} + (hagree : ∀ᶠ z in 𝓝 (⟨x,T • r⟩ : TangentBundle 𝓘(ℝ,Model n) M), + z.2 ∈ injectivityDomain z.1 → + (fun q : M × M => cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) : + ∀ᶠ t in 𝓝 T, t • r ∈ injectivityDomain x → + normalCost x (t • r) =ᶠ[𝓝 0] (fun h => G (riemannianExp x h,riemannianExp x (t • r))) := by + have hi : Continuous (fun t : ℝ => (⟨x,t • r⟩ : TangentBundle 𝓘(ℝ,Model n) M)) := + (FiberBundle.continuous_totalSpaceMk (Model n) _ x).comp (continuous_id.smul continuous_const) + filter_upwards [hi.continuousAt.eventually hagree] with t ht htID + have hc : Tendsto (fun h : TangentSpace 𝓘(ℝ,Model n) x => + (riemannianExp x h,riemannianExp x (t • r))) (𝓝 0) (𝓝 (x,riemannianExp x (t • r))) := by + have hcurve : ContinuousAt (fun h : TangentSpace 𝓘(ℝ,Model n) x => + (riemannianExp x h,riemannianExp x (t • r))) 0 := + (contMDiff_riemannianExp_fiber x).continuous.continuousAt.prodMk continuousAt_const + simpa only [riemannianExp_zero] using hcurve.tendsto + exact (ht htID).comp_tendsto hc + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/ChartLipschitz.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/ChartLipschitz.lean new file mode 100644 index 0000000000000000000000000000000000000000..c01d6ce2afbcae8b4ab3ff2ee8e9acd290af411d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/ChartLipschitz.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingSubinterval +import OAI.Analysis.BiholderTransport.Geodesics.GlobalGauss + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace + normedSpaceTangentSpaceVectorSpace + +lemma chart_spray_hasDerivAt (a : M) (z : TangentBundle 𝓘(ℝ,Model n) M) {t : ℝ} + (ht : (sprayFlow t z).1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + HasDerivAt (fun s => extChartAt 𝓘(ℝ,Model n) a (sprayFlow s z).1) + (mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) (extChartAt 𝓘(ℝ,Model n) a) + (sprayFlow t z).1 (sprayFlow t z).2) t := by + have hsrc : (sprayFlow t z).1∈(chartAt (Model n) a).source := by + simpa only [extChartAt_source] using ht + have projectedDeriv := + (ContinuousLinearMap.fst ℝ (Model n) (Model n)).hasFDerivAt.comp_hasDerivAt t + (sprayFlow_chart_hasDerivAt (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) z ht) + change HasDerivAt (fun s => extChartAt 𝓘(ℝ,Model n) a (sprayFlow s z).1) + (tangentCoordChange 𝓘(ℝ,Model n) (sprayFlow t z).1 a + (sprayFlow t z).1 (sprayFlow t z).2) t at projectedDeriv + apply projectedDeriv.congr_deriv + symm + change (mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) (chartAt (Model n) a) + (sprayFlow t z).1) (sprayFlow t z).2 = _ + rw [mfderiv_chartAt_eq_tangentCoordChange hsrc] + rfl + +variable [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_lipschitzOn_chart (a : M) : + ∃ C : ℝ≥0, ∃ r>0, ball a r⊆(extChartAt 𝓘(ℝ,Model n) a).source ∧ + LipschitzOnWith C (extChartAt 𝓘(ℝ,Model n) a) (ball a r) := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨C,hC,H⟩ := eventually_norm_mfderiv_extChartAt_lt 𝓘(ℝ,Model n) a + obtain ⟨R,hR,hsub⟩ := Metric.mem_nhds_iff.mp + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) H) + let Cnn : ℝ≥0 := ⟨C,hC.le⟩ + refine ⟨Cnn,R/3,by positivity,?_,?_⟩ + · exact fun x hx => (hsub ((ball_subset_ball (by linarith : R/3≤R)) hx)).1 + apply LipschitzOnWith.of_dist_le_mul + intro x hx y hy + obtain ⟨p,hp,he⟩ := exists_minimizing_vector (n := n) x y + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + have hpN : ‖p‖=dist x y := by rw [←he]; exact hp.symm + have hpath : ∀ t∈Icc (0:ℝ) 1, (sprayFlow t z).1∈ball a R := by + intro t ht + have hD := dist_sprayFlow_le z 0 t + simp only [sprayFlow_zero,zero_sub,abs_neg,abs_of_nonneg ht.1] at hD + change dist x (sprayFlow t z).1≤t*‖p‖ at hD + have hD' : dist x (sprayFlow t z).1≤dist x y := + hD.trans (by rw [←hpN]; exact mul_le_of_le_one_left (norm_nonneg _) ht.2) + have hxy := dist_triangle x a y + have hax : dist x a extChartAt 𝓘(ℝ,Model n) a (sprayFlow t z).1 + let dγ : ℝ → Model n := fun t => mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) + (extChartAt 𝓘(ℝ,Model n) a) (sprayFlow t z).1 (sprayFlow t z).2 + have hd : ∀ t∈Icc (0:ℝ) 1, HasDerivWithinAt γ (dγ t) (Icc 0 1) t := by + intro t ht + exact (chart_spray_hasDerivAt a z (hsub (hpath t ht)).1).hasDerivWithinAt + have hb : ∀ t∈Icc (0:ℝ) 1, ‖dγ t‖≤C*‖p‖ := by + intro t ht + apply (ContinuousLinearMap.le_opNorm _ _).trans + rw [sprayFlow_speed] + exact mul_le_mul_of_nonneg_right (hsub (hpath t ht)).2.le (norm_nonneg _) + have hfin := norm_image_sub_le_of_norm_deriv_le_segment_01' hd (fun t ht => hb t ⟨ht.1,ht.2.le⟩) + have he1 : (sprayFlow 1 z).1=y := by + simpa only [z,←riemannianExp_eq_sprayFlow] using he + have he0 : (sprayFlow 0 z).1=x := by rw [sprayFlow_zero] + change dist (extChartAt 𝓘(ℝ,Model n) a x) (extChartAt 𝓘(ℝ,Model n) a y)≤C*dist x y + simpa only [γ,he1,he0,←dist_eq_norm,dist_comm,hpN] using hfin + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/CompleteSpray.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/CompleteSpray.lean new file mode 100644 index 0000000000000000000000000000000000000000..b67ff89d9d8c4b257d035c2f2d4bc5cea56ee9bd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/CompleteSpray.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CompactDisk +import OAI.Analysis.BiholderTransport.LocalFlow.CompactFlow +import OAI.Analysis.BiholderTransport.Geodesics.SprayEnergy +import OAI.Analysis.BiholderTransport.Regularity.BundleSeparation +import OAI.Analysis.BiholderTransport.Calculus.RiemannianContinuous + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] [T2Space M] [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma exists_complete_spray_curve (z : TangentBundle 𝓘(ℝ,E) M) : + ∃ γ : ℝ → TangentBundle 𝓘(ℝ,E) M, γ 0 = z ∧ + IsMIntegralCurve γ (geodesicSpray (E := E)) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + have : IsContinuousRiemannianBundle E (fun x : M => TangentSpace 𝓘(ℝ,E) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,E)) + apply exists_complete_curve_of_compact_invariant contMDiff_geodesicSpray + (isCompact_bundle_disk (F := E) (E := fun x : M => TangentSpace 𝓘(ℝ,E) x) ‖z.2‖) + _ z (Set.mem_ofPred.mpr le_rfl) + intro a γ hγ0 hγ t ht + have ha : 0 < a := by obtain ⟨h₁,h₂⟩ := ht; linarith + change ‖(γ t).2‖ ≤ ‖z.2‖ + rw [spray_speed_constant hγ ht ⟨neg_lt_zero.mpr ha,ha⟩] + exact hγ0 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/DoubleMountain.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/DoubleMountain.lean new file mode 100644 index 0000000000000000000000000000000000000000..f8a819a8c5f4cd332b0afec84d21925e92400c96 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/DoubleMountain.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GlobalSupport + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma minimizingVector_active_twoMountain_left {x : M} + {p₀ p₁ : TangentSpace 𝓘(ℝ,Model n) x} (hp₀ : p₀∈minimizingVectors x) : + p₀∈activeLogs (cTransform (twoMountain x (riemannianExp x p₀) (riemannianExp x p₁))) x := by + refine ⟨hp₀,?_⟩ + rw [contactGap,cTransform_cTransform_twoMountain,twoMountain_self,cTransform_twoMountain_left] + ring + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma minimizingVector_active_twoMountain_right {x : M} + {p₀ p₁ : TangentSpace 𝓘(ℝ,Model n) x} (hp₁ : p₁∈minimizingVectors x) : + p₁∈activeLogs (cTransform (twoMountain x (riemannianExp x p₀) (riemannianExp x p₁))) x := by + refine ⟨hp₁,?_⟩ + rw [contactGap,cTransform_cTransform_twoMountain,twoMountain_self,cTransform_twoMountain_right] + ring + +lemma WeakMTW.double_mountain (hmtw : WeakMTW (n := n) (M := M)) {x : M} + {p₀ p₁ : TangentSpace 𝓘(ℝ,Model n) x} + (hp₀ : p₀∈minimizingVectors x) (hp₁ : p₁∈minimizingVectors x) + {a b : ℝ} (ha : 0≤a) (hb : 0≤b) (hab : a+b=1) : + a • p₀+b • p₁∈minimizingVectors x ∧ ∀ z : M, + cost x (riemannianExp x (a • p₀+b • p₁))-cost z (riemannianExp x (a • p₀+b • p₁)) ≤ + max (cost x (riemannianExp x p₀)-cost z (riemannianExp x p₀)) + (cost x (riemannianExp x p₁)-cost z (riemannianExp x p₁)) := by + let f := twoMountain x (riemannianExp x p₀) (riemannianExp x p₁) + have hp : a • p₀+b • p₁∈convexHull ℝ (activeLogs (n := n) (cTransform f) x) := + (convex_convexHull _ _) + (subset_convexHull _ _ (minimizingVector_active_twoMountain_left hp₀)) + (subset_convexHull _ _ (minimizingVector_active_twoMountain_right hp₁)) ha hb hab + obtain ⟨hmin,hsup⟩ := hmtw.active_hull_global_support + (continuous_cTransform (continuous_twoMountain x _ _)) hp + refine ⟨hmin,?_⟩ + intro z + have hh := hsup z + rw [cTransform_cTransform_twoMountain,twoMountain_self] at hh + change 0+cost x (riemannianExp x (a • p₀+b • p₁))≤ + twoMountain x (riemannianExp x p₀) (riemannianExp x p₁) z+ + cost z (riemannianExp x (a • p₀+b • p₁)) at hh + exact sub_le_iff_le_add.mpr (by simpa only [zero_add,twoMountain] using hh) + +lemma WeakMTW.convex_minimizingVectors (hmtw : WeakMTW (n := n) (M := M)) (x : M) : + Convex ℝ (minimizingVectors (n := n) x) := by + intro p hp q hq a b ha hb hab + exact (hmtw.double_mountain hp hq ha hb hab).1 +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/EndpointIdentity.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/EndpointIdentity.lean new file mode 100644 index 0000000000000000000000000000000000000000..b81fc947a0dfbd68f27f73cc8b81f2a19a24aa85 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/EndpointIdentity.lean @@ -0,0 +1,167 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayScaling + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [T2Space M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +omit [FiniteDimensional ℝ E] [T2Space M] [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma tangent_chart_at_self_base (a : TangentBundle 𝓘(ℝ,E) M) (v : E) : + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a ⟨a.1,v⟩ = (extChartAt 𝓘(ℝ,E) a.1 a.1,v) := by + rw [tangent_chart_apply,tangentCoordChange_self (mem_extChartAt_source (I := 𝓘(ℝ,E)) a.1)] + +omit [FiniteDimensional ℝ E] [T2Space M] [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma tangent_chart_at_self_base_symm (a : TangentBundle 𝓘(ℝ,E) M) (v : E) : + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm (extChartAt 𝓘(ℝ,E) a.1 a.1,v) = ⟨a.1,v⟩ := by + rw [←tangent_chart_at_self_base a v] + exact (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).left_inv + ((tangent_chart_source_iff a _).mpr (mem_extChartAt_source (I := 𝓘(ℝ,E)) a.1)) + +lemma hasDerivAt_spray_coordinate_zero (a : M) (v : TangentSpace 𝓘(ℝ,E) a) : + HasDerivAt (fun t => extChartAt 𝓘(ℝ,E) a (sprayFlow t ⟨a,v⟩).1) v 0 := by + have hd := (ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt 0 + (spray_chart_hasDerivAt ((sprayFlow_curve (⟨a,v⟩ : TangentBundle 𝓘(ℝ,E) M)).isMIntegralCurveAt 0)) + simp only [sprayFlow_zero,tangent_chart_apply,coordinateGeodesicField, + Function.comp_def,ContinuousLinearMap.coe_fst'] at hd + have he : tangentCoordChange 𝓘(ℝ,E) a a a v = v := + tangentCoordChange_self (mem_extChartAt_source (I := 𝓘(ℝ,E)) a) + rw [he] at hd + exact hd + +lemma coordinate_flow_endpoint_derivative_zero (a : M) {r τ : ℝ} (hr : 0 < r) + {Φ : ℝ × (E × E) → E × E} + (hΦ : ContDiffOn ℝ ∞ Φ + (Ioo (-r) r ×ˢ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r)) + (hΦ0 : ∀ z ∈ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r, Φ (0,z) = z) + (hode : ∀ t ∈ Ioo (-r) r, ∀ z ∈ Metric.ball (extChartAt 𝓘(ℝ,E) a a,0) r, + (Φ (t,z)).1 ∈ (extChartAt 𝓘(ℝ,E) a).target ∧ + HasDerivAt (fun s => Φ (s,z)) (coordinateGeodesicField (riemannianCoordinateMetric a) (Φ (t,z))) t) + (hτ : τ ∈ Ioo (-r) r) : + fderiv ℝ (fun v : E => (Φ (τ,extChartAt 𝓘(ℝ,E) a a,v)).1) 0 = + τ • ContinuousLinearMap.id ℝ E := by + let x := extChartAt 𝓘(ℝ,E) a a + let ψ : E → E := fun v => (Φ (τ,x,v)).1 + have hψ : DifferentiableAt ℝ ψ 0 := + (((hΦ.contDiffAt ((isOpen_Ioo.prod Metric.isOpen_ball).mem_nhds + ⟨hτ,Metric.mem_ball_self hr⟩)).comp 0 + (contDiffAt_const.prodMk (contDiffAt_const.prodMk contDiffAt_id))).fst).differentiableAt (by simp) + have heq : ∀ v ∈ Metric.ball (0:E) r, + ψ v = extChartAt 𝓘(ℝ,E) a (sprayFlow τ ⟨a,v⟩).1 := by + intro v hv + have hz : (x,v) ∈ Metric.ball (x,0) r := by + simpa only [Metric.mem_ball,Prod.dist_eq,dist_self,max_lt_iff] using And.intro hr hv + let z : TangentBundle 𝓘(ℝ,E) M := ⟨a,0⟩ + have H := sprayFlow_eq_coordinate_curve z hr + (fun t ht => (hode t ht (x,v) hz).1) + (fun t ht => (hode t ht (x,v) hz).2) + (show (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z).symm (Φ (0,x,v)) = ⟨a,v⟩ by + rw [hΦ0 (x,v) hz]; exact tangent_chart_at_self_base_symm z v) hτ + have Hc := congrArg (fun p : TangentBundle 𝓘(ℝ,E) M => extChartAt 𝓘(ℝ,E) a p.1) H + rw [tangent_chart_symm_base,(extChartAt 𝓘(ℝ,E) a).right_inv (hode τ hτ (x,v) hz).1] at Hc + exact Hc.symm + ext w + have hn : ∀ᶠ s : ℝ in 𝓝 0, s • w ∈ Metric.ball (0:E) r := + ((continuousAt_id.smul continuousAt_const) : + ContinuousAt (fun s : ℝ => s • w) 0).preimage_mem_nhds + (by + change Metric.ball (0:E) r ∈ 𝓝 ((0:ℝ) • w) + simpa only [zero_smul] using Metric.ball_mem_nhds (0:E) hr) + have he : (fun s : ℝ => ψ (s • w)) =ᶠ[𝓝 0] + (fun s => extChartAt 𝓘(ℝ,E) a (sprayFlow (s*τ) ⟨a,w⟩).1) := by + filter_upwards [hn] with s hs + rw [heq (s • w) hs,show (⟨a,s • w⟩ : TangentBundle 𝓘(ℝ,E) M) = tangentScale s ⟨a,w⟩ from rfl, + sprayFlow_scale] + rfl + have hL := (show HasFDerivAt ψ (fderiv ℝ ψ 0) ((0:ℝ) • w) by + simpa only [zero_smul] using hψ.hasFDerivAt).comp_hasDerivAt 0 + (show HasDerivAt (fun s : ℝ => s • w) w 0 by + simpa only [one_smul,id_eq] using (hasDerivAt_id (0:ℝ)).smul_const w) + have hR := (show HasDerivAt (fun t => extChartAt 𝓘(ℝ,E) a + (sprayFlow t ⟨a,w⟩).1) w ((id (0:ℝ))*τ) by + simpa only [id_eq,zero_mul] using hasDerivAt_spray_coordinate_zero a w).scomp 0 + ((hasDerivAt_id (0:ℝ)).mul_const τ) + have H := (hL.congr_of_eventuallyEq he.symm).unique + (show HasDerivAt (fun s => extChartAt 𝓘(ℝ,E) a (sprayFlow (s*τ) ⟨a,w⟩).1) (τ • w) 0 by + simpa only [zero_mul,one_mul,id_eq,Function.comp_def,smul_eq_mul] using hR) + exact H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/ExpInteriorUnique.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/ExpInteriorUnique.lean new file mode 100644 index 0000000000000000000000000000000000000000..71cae7eb3fbec25409a716c0b051bee01d11cd8c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/ExpInteriorUnique.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayMinimizerUnique + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma riemannianExp_interior_unique {x : M} {p q : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (hq : q ∈ minimizingVectors x) + (he : riemannianExp x p = riemannianExp x q) : p=q := by + have hpmin := injectivityDomain_subset_minimizingVectors x hp + have hn : ‖p‖=‖q‖ := hpmin.symm.trans ((congrArg (dist x) he).trans hq) + by_cases hp0 : p=0 + · have hq0 : q=0 := norm_eq_zero.mp (by rw [←hn,hp0,norm_zero]) + exact hp0.trans hq0.symm + have ht : 0<‖p‖ := norm_pos_iff.mpr hp0 + obtain ⟨a,ha,hpa⟩ := hp + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,‖p‖⁻¹ • p⟩ + let w : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,‖p‖⁻¹ • q⟩ + have hzn : ‖z.2‖=1 := by + change ‖‖p‖⁻¹ • p‖=1 + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr ht),inv_mul_cancel₀ ht.ne'] + have hwn : ‖w.2‖=1 := by + change ‖‖p‖⁻¹ • q‖=1 + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr ht),←hn,inv_mul_cancel₀ ht.ne'] + have hflowz : (sprayFlow ‖p‖ z).1=riemannianExp x p := by + rw [←riemannianExp_smul,smul_smul,mul_inv_cancel₀ ht.ne',one_smul] + have hfloww : (sprayFlow ‖p‖ w).1=riemannianExp x q := by + rw [←riemannianExp_smul,smul_smul,mul_inv_cancel₀ ht.ne',one_smul] + have hflowa : (sprayFlow (a*‖p‖) z).1=riemannianExp x (a • p) := by + rw [←riemannianExp_smul,smul_smul,mul_assoc,mul_inv_cancel₀ ht.ne',mul_one] + have hzw := sprayFlow_unit_minimizer_unique z w rfl hzn hwn ht + (lt_mul_of_one_lt_left ht ha) + (by rw [hflowa]; exact hpa) + (by rw [hfloww,hn]; exact hq) + (by rw [hflowz,hfloww]; exact he) + have hvel : ‖p‖⁻¹ • p = ‖p‖⁻¹ • q := TotalSpace.mk_injective x hzw + exact (smul_right_inj (inv_ne_zero ht.ne')).mp hvel + +lemma riemannianExp_injOn_injectivityDomain (x : M) : + Set.InjOn (riemannianExp (n := n) x) (injectivityDomain x) := by + intro p hp q hq he + exact riemannianExp_interior_unique hp (injectivityDomain_subset_minimizingVectors x hq) he + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GaussLemma.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GaussLemma.lean new file mode 100644 index 0000000000000000000000000000000000000000..30b60baf1c812da02c400965c1f56f7acc7ec8ad --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GaussLemma.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Coordinates +import OAI.Analysis.BiholderTransport.Calculus.PartialCalculus + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +local instance gaussLemmaNormedSpace : NormedSpace ℝ E := InnerProductSpace.toNormedSpace +local instance gaussLemmaDualNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance gaussLemmaDualNormedSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance gaussLemmaBilinearNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance gaussLemmaBilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance gaussLemmaTrilinearNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance gaussLemmaTrilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] E →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace + +lemma metric_geodesic_variation_derivative {g : E → E →L[ℝ] E →L[ℝ] ℝ} + {γ V J : ℝ → E} {t : ℝ} {W : E} + (hg : DifferentiableAt ℝ g (γ t)) (hi : (g (γ t)).IsInvertible) + (hγ : HasDerivAt γ (V t) t) + (hV : HasDerivAt V (-coordinateChristoffel g (γ t) (V t) (V t)) t) + (hJ : HasDerivAt J W t) : + HasDerivAt (fun q => g (γ q) (V q) (J q)) + ((1/2:ℝ) * (fderiv ℝ g (γ t)) (J t) (V t) (V t) + g (γ t) (V t) W) t := by + have h := ((hg.hasFDerivAt.comp_hasDerivAt t hγ).clm_apply hV).clm_apply hJ + have hk := coordinateChristoffel_metric g (γ t) (V t) (V t) (J t) hi + convert h using 1 <;> try rfl + simp only [Function.comp_apply,add_apply,map_neg,neg_apply] + linarith + +lemma variation_mixed_derivative {A V : ℝ × ℝ → E} {U : Set (ℝ × ℝ)} + (hU : IsOpen U) (hA : ContDiffOn ℝ ∞ A U) + (hAV : ∀ z ∈ U, HasDerivAt (fun t => A (t,z.2)) (V z) z.1) + {t s : ℝ} (hz : (t,s) ∈ U) : + HasDerivAt (fun q => directionalDerivative A (0,1) (q,s)) + (directionalDerivative V (0,1) (t,s)) t := by + have hAt := hA.contDiffAt (hU.mem_nhds hz) + have heq : directionalDerivative A (1,0) =ᶠ[𝓝 (t,s)] V := by + filter_upwards [hU.mem_nhds hz] with z hz + exact (hasDerivAt_slice_left ((hA.contDiffAt (hU.mem_nhds hz)).differentiableAt + (by simp))).unique (hAV z hz) + have hm := directionalDerivative_commute hAt (0,1) (1,0) + have heval : directionalDerivative (directionalDerivative A (1,0)) (0,1) (t,s) = + directionalDerivative V (0,1) (t,s) := by + unfold directionalDerivative + exact congrArg (fun L : (ℝ × ℝ) →L[ℝ] E => L (0,1)) heq.fderiv_eq + rw [heval] at hm + exact hm ▸ hasDerivAt_slice_left + ((contDiffAt_directionalDerivative hAt (0,1)).differentiableAt (by simp)) + +lemma coordinate_gauss_variation + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hi : ∀ x ∈ S, (g x).IsInvertible) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {A V : ℝ × ℝ → E} {a b c d : ℝ} + (hA : ContDiffOn ℝ ∞ A (Ioo a b ×ˢ Ioo c d)) + (hV : ContDiffOn ℝ ∞ V (Ioo a b ×ˢ Ioo c d)) + (himg : ∀ t ∈ Ioo a b, ∀ s ∈ Ioo c d, A (t,s) ∈ S) + (hode : ∀ t ∈ Ioo a b, ∀ s ∈ Ioo c d, + HasDerivAt (fun q => A (q,s)) (V (t,s)) t ∧ + HasDerivAt (fun q => V (q,s)) + (-coordinateChristoffel g (A (t,s)) (V (t,s)) (V (t,s))) t) + {x : E} {ν : ℝ → E} + (h0 : 0 ∈ Ioo a b) (hA0 : ∀ s ∈ Ioo c d, A (0,s) = x) + (hV0 : ∀ s ∈ Ioo c d, V (0,s) = ν s) + {s t : ℝ} {w : E} (ht : t ∈ Ioo a b) (hs : s ∈ Ioo c d) + (hν : HasDerivAt ν w s) : + g (A (t,s)) (V (t,s)) (directionalDerivative A (0,1) (t,s)) = + t * g x (ν s) w := by + have hopen : IsOpen (Ioo a b ×ˢ Ioo c d) := isOpen_Ioo.prod isOpen_Ioo + have hgd : ∀ q ∈ Ioo a b, ∀ r ∈ Ioo c d, DifferentiableAt ℝ g (A (q,r)) := + fun q hq r hr => (hg.contDiffAt (hS.mem_nhds (himg q hq r hr))).differentiableAt + (by simp) + have he : ∀ q ∈ Ioo a b, ∀ r ∈ Ioo c d, + g (A (q,r)) (V (q,r)) (V (q,r)) = g x (ν r) (ν r) := by + intro q hq r hr + have hh := coordinate_geodesic_speed_constant + (fun p hp => hgd p hp r hr) (fun p hp => hi _ (himg p hp r hr)) + (fun p hp => hsym _ (himg p hp r hr)) (fun p hp => hode p hp r hr) hq h0 + simpa only [hA0 r hr,hV0 r hr] using hh + have hder : ∀ q ∈ Ioo a b, + HasDerivAt (fun p => g (A (p,s)) (V (p,s)) + (directionalDerivative A (0,1) (p,s))) (g x (ν s) w) q := by + intro q hq + let J := directionalDerivative A (0,1) (q,s) + let W := directionalDerivative V (0,1) (q,s) + have hAr := hasDerivAt_slice_right + ((hA.contDiffAt (hopen.mem_nhds ⟨hq,hs⟩)).differentiableAt (by simp)) + have hVr := hasDerivAt_slice_right + ((hV.contDiffAt (hopen.mem_nhds ⟨hq,hs⟩)).differentiableAt (by simp)) + have hE := (((hgd q hq s hs).hasFDerivAt.comp_hasDerivAt s hAr).clm_apply hVr).clm_apply hVr + have hE0 := ((hasDerivAt_const s (g x)).clm_apply hν).clm_apply hν + have heq : (fun r => g (A (q,r)) (V (q,r)) (V (q,r))) =ᶠ[𝓝 s] + (fun r => g x (ν r) (ν r)) := by + filter_upwards [isOpen_Ioo.mem_nhds hs] with r hr + exact he q hq r hr + have hval := (hE.congr_of_eventuallyEq heq.symm).unique hE0 + have hJ := variation_mixed_derivative hopen hA + (fun z hz => (hode z.1 hz.1 z.2 hz.2).1) (hz := ⟨hq,hs⟩) + have hG := metric_geodesic_variation_derivative + (γ := fun p => A (p,s)) (V := fun p => V (p,s)) + (J := fun p => directionalDerivative A (0,1) (p,s)) (hgd q hq s hs) + (hi _ (himg q hq s hs)) (hode q hq s hs).1 (hode q hq s hs).2 hJ + have hval' : (1/2:ℝ) * (fderiv ℝ g (A (q,s))) J (V (q,s)) (V (q,s)) + + g (A (q,s)) (V (q,s)) W = g x (ν s) w := by + simp only [Function.comp_apply,add_apply,zero_apply,zero_add] at hval + rw [hsym _ (himg q hq s hs) W (V (q,s)), + hsym x (hA0 s hs ▸ himg 0 h0 s hs) w (ν s)] at hval + linarith + exact hval' ▸ hG + have hJ0 : directionalDerivative A (0,1) (0,s) = 0 := by + have hAr := hasDerivAt_slice_right + ((hA.contDiffAt (hopen.mem_nhds ⟨h0,hs⟩)).differentiableAt (by simp)) + have heq : (fun r => A (0,r)) =ᶠ[𝓝 s] (fun _ => x) := by + filter_upwards [isOpen_Ioo.mem_nhds hs] with r hr + exact hA0 r hr + exact (hAr.congr_of_eventuallyEq heq.symm).unique (hasDerivAt_const s x) + have hd : ∀ q ∈ Ioo a b, + HasDerivAt (fun p => g (A (p,s)) (V (p,s)) + (directionalDerivative A (0,1) (p,s)) - p * g x (ν s) w) 0 q := by + intro q hq + convert (hder q hq).sub ((hasDerivAt_id q).mul_const (g x (ν s) w)) using 1 <;> + first | rfl | simp only [one_mul,sub_self] + have heq := isOpen_Ioo.is_const_of_deriv_eq_zero (convex_Ioo a b).isPreconnected + (fun q hq => (hd q hq).differentiableAt.differentiableWithinAt) + (fun q hq => (hd q hq).deriv) ht h0 + simpa only [hJ0,map_zero,zero_mul,sub_zero,sub_eq_zero] using heq + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicBasics.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicBasics.lean new file mode 100644 index 0000000000000000000000000000000000000000..e9eabf6868fcf521249bfc76b28443c8c3083112 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicBasics.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder +open scoped BoundedContinuousFunction + +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + [IsManifold 𝓘(ℝ, Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + +omit [IsManifold 𝓘(ℝ, Model n) ∞ M] in +lemma isGeodesic_zero (x : M) : IsGeodesicWithInitialData (n := n) x 0 (fun _ => x) := by + refine ⟨contMDiff_const, ?_, ?_⟩ + · simp only [mfderiv_const] + rfl + · intro t + refine ⟨1, by norm_num, ?_⟩ + intro s u _ _ + simp + +omit [IsManifold 𝓘(ℝ, Model n) ∞ M] in +lemma geodesic_initial_point {x : M} {v : TangentSpace 𝓘(ℝ, Model n) x} + {gamma : ℝ → M} (h : IsGeodesicWithInitialData x v gamma) : gamma 0 = x := by + exact congrArg (fun p : TangentBundle 𝓘(ℝ, Model n) M => p.proj) h.2.1 + +omit [IsManifold 𝓘(ℝ, Model n) ∞ M] in + +lemma geodesic_zero_eq_const {x : M} {gamma : ℝ → M} + (h : IsGeodesicWithInitialData (n := n) x 0 gamma) : gamma = fun _ => x := by + have hl : IsLocallyConstant gamma := by + rw [IsLocallyConstant.iff_exists_open] + intro t + obtain ⟨eps, heps, hh⟩ := h.2.2 t + refine ⟨Metric.ball t eps, Metric.isOpen_ball, Metric.mem_ball_self heps, ?_⟩ + intro s hs + apply dist_eq_zero.mp + simpa only [norm_zero, mul_zero] using + hh s t (by simpa only [Metric.mem_ball, Real.dist_eq] using hs) (by simpa using heps) + funext t + exact (hl.apply_eq_of_preconnectedSpace t 0).trans (geodesic_initial_point h) + +omit [IsManifold 𝓘(ℝ, Model n) ∞ M] in +@[simp] lemma riemannianExp_zero (x : M) : riemannianExp (n := n) x 0 = x := by + have hex : ∃ gamma, IsGeodesicWithInitialData (n := n) x 0 gamma := ⟨_, isGeodesic_zero (n := n) x⟩ + rw [riemannianExp, dite_eq_left hex] + exact congrFun (geodesic_zero_eq_const (Classical.choose_spec hex)) 1 + +omit [IsManifold 𝓘(ℝ, Model n) ∞ M] in +lemma zero_mem_injectivityDomain (x : M) : (0 : TangentSpace 𝓘(ℝ, Model n) x) ∈ injectivityDomain x := by + refine ⟨2, by norm_num, ?_⟩ + simp + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicExistence.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicExistence.lean new file mode 100644 index 0000000000000000000000000000000000000000..ef7ecf94d415dddf2d503824c4a41803680b7196 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicExistence.lean @@ -0,0 +1,181 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model +import OAI.Analysis.BiholderTransport.Geodesics.SprayMinimizing +import OAI.Analysis.BiholderTransport.Geodesics.EndpointIdentity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma sprayFlow_isGeodesicWithInitialData (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + IsGeodesicWithInitialData x v (fun t => (sprayFlow t ⟨x,v⟩).1) := by + have hsm : ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun t => sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)) := + contMDiff_sprayFlow.comp (contMDiff_id.prodMk contMDiff_const) + refine ⟨(Bundle.contMDiff_proj (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)).comp hsm,?_,?_⟩ + · rw [spray_velocity_eq_mfderiv ((sprayFlow_curve ⟨x,v⟩).isMIntegralCurveAt 0)] + exact sprayFlow_zero ⟨x,v⟩ + · exact sprayFlow_locally_minimizing ⟨x,v⟩ + +lemma exists_geodesicWithInitialData (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + ∃ γ : ℝ → M, IsGeodesicWithInitialData x v γ := + ⟨_,sprayFlow_isGeodesicWithInitialData x v⟩ + +lemma riemannianExp_eq_chosen_geodesic (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + riemannianExp x v = Classical.choose (exists_geodesicWithInitialData x v) 1 := by + rw [riemannianExp,dite_eq_left (exists_geodesicWithInitialData x v)] + +end +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [T2Space M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma coordinate_flow_eq_spray (a : M) {r : ℝ} (hr : 0 < r) + {Ψ W : ℝ × E → E} + (hinit : ∀ v ∈ Metric.ball (0:E) r, + Ψ (0,v) = extChartAt 𝓘(ℝ,E) a a ∧ W (0,v) = v) + (hode : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball (0:E) r, + Ψ (t,v) ∈ (extChartAt 𝓘(ℝ,E) a).target ∧ + HasDerivAt (fun s => Ψ (s,v)) (W (t,v)) t ∧ + HasDerivAt (fun s => W (s,v)) + (-coordinateChristoffel (riemannianCoordinateMetric a) (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {v : E} (hv : v ∈ Metric.ball (0:E) r) {t : ℝ} (ht : t ∈ Ioo (-r) r) : + Ψ (t,v) = extChartAt 𝓘(ℝ,E) a (sprayFlow t ⟨a,v⟩).1 := by + let z : TangentBundle 𝓘(ℝ,E) M := ⟨a,0⟩ + have H := sprayFlow_eq_coordinate_curve z hr + (fun s hs => (hode s hs v hv).1) + (fun s hs => (hode s hs v hv).2.1.prodMk (hode s hs v hv).2.2) + (show (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z).symm (Ψ (0,v), W (0,v)) = ⟨a,v⟩ by + rw [(hinit v hv).1,(hinit v hv).2] + exact tangent_chart_at_self_base_symm z v) ht + have Hc := congrArg (fun p : TangentBundle 𝓘(ℝ,E) M => extChartAt 𝓘(ℝ,E) a p.1) H + rw [tangent_chart_symm_base,(extChartAt 𝓘(ℝ,E) a).right_inv (hode t ht v hv).1] at Hc + exact Hc.symm + +lemma coordinate_endpoint_radial (a : M) {r : ℝ} (hr : 0 < r) + {Ψ W : ℝ × E → E} + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (hinit : ∀ v ∈ Metric.ball (0:E) r, + Ψ (0,v) = extChartAt 𝓘(ℝ,E) a a ∧ W (0,v) = v) + (hode : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball (0:E) r, + Ψ (t,v) ∈ (extChartAt 𝓘(ℝ,E) a).target ∧ + HasDerivAt (fun s => Ψ (s,v)) (W (t,v)) t ∧ + HasDerivAt (fun s => W (s,v)) + (-coordinateChristoffel (riemannianCoordinateMetric a) (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {v : E} (hv : v ∈ Metric.ball (0:E) r) {τ : ℝ} (hτ : τ ∈ Ioo (-r) r) : + fderiv ℝ (fun w => Ψ (τ,w)) v v = τ • W (τ,v) := by + have hn1 : ∀ᶠ s : ℝ in 𝓝 1, s • v ∈ Metric.ball (0:E) r := + ((continuousAt_id.smul continuousAt_const) : ContinuousAt (fun s : ℝ => s • v) 1) + (by change Metric.ball (0:E) r ∈ 𝓝 ((1:ℝ) • v) + simpa only [one_smul] using Metric.isOpen_ball.mem_nhds hv) + have hn2 : ∀ᶠ s : ℝ in 𝓝 1, s*τ ∈ Ioo (-r) r := + ((continuousAt_id.mul continuousAt_const) : + ContinuousAt (fun scalar : ℝ => scalar * τ) 1).preimage_mem_nhds + (by change Ioo (-r) r ∈ 𝓝 ((1:ℝ)*τ) + simpa only [one_mul] using isOpen_Ioo.mem_nhds hτ) + have heq : (fun s : ℝ => Ψ (τ,s • v)) =ᶠ[𝓝 1] (fun s => Ψ (s*τ,v)) := by + filter_upwards [hn1,hn2] with s hs ht + rw [coordinate_flow_eq_spray a hr hinit hode hs hτ, + coordinate_flow_eq_spray a hr hinit hode hv ht] + rw [show (⟨a,s • v⟩ : TangentBundle 𝓘(ℝ,E) M) = tangentScale s ⟨a,v⟩ from rfl, + sprayFlow_scale] + rfl + have hD : DifferentiableAt ℝ (fun w => Ψ (τ,w)) v := + ((hΨ.contDiffAt ((isOpen_Ioo.prod Metric.isOpen_ball).mem_nhds ⟨hτ,hv⟩)).comp v + (contDiffAt_const.prodMk contDiffAt_id)).differentiableAt (by simp) + have hleft : HasDerivAt (fun s : ℝ => Ψ (τ,s • v)) + (fderiv ℝ (fun w => Ψ (τ,w)) v v) 1 := by + have hs : HasDerivAt (fun s : ℝ => s • v) v 1 := by + simpa only [one_smul] using (hasDerivAt_id' (1:ℝ)).smul_const v + have hD' : HasFDerivAt (fun w => Ψ (τ,w)) + (fderiv ℝ (fun w => Ψ (τ,w)) v) ((1:ℝ) • v) := by + simpa only [one_smul] using hD.hasFDerivAt + exact hD'.comp_hasDerivAt 1 hs + have hright : HasDerivAt (fun s : ℝ => Ψ (s*τ,v)) (τ • W (τ,v)) 1 := by + have hs : HasDerivAt (fun s : ℝ => s*τ) τ 1 := hasDerivAt_mul_const τ + have hW : HasDerivAt (fun s => Ψ (s,v)) (W (τ,v)) ((1:ℝ)*τ) := by + simpa only [one_mul] using (hode τ hτ v hv).2.1 + exact hW.scomp 1 hs + exact (hleft.congr_of_eventuallyEq heq.symm).unique hright + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicSpray.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicSpray.lean new file mode 100644 index 0000000000000000000000000000000000000000..0e6f5642e9d00dfab5a87098d617a811b8906351 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GeodesicSpray.lean @@ -0,0 +1,237 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TangentLift +import OAI.Analysis.BiholderTransport.Coordinates.ChartTransition + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +namespace WeakMTWTransport +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + +lemma tangent_chart_source_iff (a z : TangentBundle 𝓘(ℝ,E) M) : + z ∈ (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).source ↔ + z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).source := by + rw [FiberBundle.extChartAt] + simp only [PartialEquiv.trans_source,PartialEquiv.prod_source,PartialEquiv.refl_source, + Trivialization.source_eq,mem_inter_iff,mem_preimage, + mem_prod,mem_univ,and_true,TangentBundle.trivializationAt_baseSet] + simp only [extChartAt_source] + constructor + · exact fun h => h.1 + · intro h + refine ⟨h,?_⟩ + change (trivializationAt E (TangentSpace 𝓘(ℝ,E)) a.1 z).1 ∈ (chartAt E a.1).source + rwa [TangentBundle.trivializationAt_apply] + +lemma tangent_chart_transition_eventually (a b : TangentBundle 𝓘(ℝ,E) M) + {z : E × E} (ha : z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target) + (hb : (extChartAt 𝓘(ℝ,E) a.1).symm z.1 ∈ (extChartAt 𝓘(ℝ,E) b.1).source) : + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) b ∘ + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm) =ᶠ[𝓝 z] + coordinateTangentLift (extChartAt 𝓘(ℝ,E) b.1 ∘ (extChartAt 𝓘(ℝ,E) a.1).symm) := by + have h1 : ∀ᶠ y in 𝓝 z, y.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target := + continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_target a.1).mem_nhds ha) + have h2 : ∀ᶠ y in 𝓝 z, + (extChartAt 𝓘(ℝ,E) a.1).symm y.1 ∈ (extChartAt 𝓘(ℝ,E) b.1).source := + ((continuousAt_extChartAt_symm'' ha).comp continuousAt_fst).preimage_mem_nhds + ((isOpen_extChartAt_source b.1).mem_nhds hb) + filter_upwards [h1,h2] with y hy1 hy2 + exact tangent_chart_transition_apply a b y hy1 hy2 + +lemma tangent_tangentCoordChange_apply (a b z : TangentBundle 𝓘(ℝ,E) M) + (ha : z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).source) + (hb : z.1 ∈ (extChartAt 𝓘(ℝ,E) b.1).source) (w : E × E) : + tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a b z w = + fderiv ℝ (coordinateTangentLift + (extChartAt 𝓘(ℝ,E) b.1 ∘ (extChartAt 𝓘(ℝ,E) a.1).symm)) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z) w := by + have heq := tangent_chart_transition_eventually a b + (z := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z) + ((extChartAt 𝓘(ℝ,E) a.1).map_source ha) + (by simpa only [tangent_chart_apply,(extChartAt 𝓘(ℝ,E) a.1).left_inv ha] using hb) + simp only [tangentCoordChange_def,ModelWithCorners.range_eq_univ,fderivWithin_univ] + exact congrArg (fun L : (E × E) →L[ℝ] (E × E) => L w) heq.fderiv_eq + +variable [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +omit [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma riemannianCoordinateMetric_isInvertible [FiniteDimensional ℝ E] {a : M} {z : E} + (hz : z ∈ (extChartAt 𝓘(ℝ,E) a).target) : + (riemannianCoordinateMetric a z).IsInvertible := + metricDual_isInvertible _ (fun _ hv => riemannianCoordinateMetric_positive hz hv) + +omit [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma riemannianMetric_transition_eventually {a b x : M} + (ha : x ∈ (extChartAt 𝓘(ℝ,E) a).source) + (hb : x ∈ (extChartAt 𝓘(ℝ,E) b).source) : + ∀ᶠ y in 𝓝 (extChartAt 𝓘(ℝ,E) a x), ∀ u v, + riemannianCoordinateMetric a y u v = + riemannianCoordinateMetric b + ((extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) y) + (fderiv ℝ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) y u) + (fderiv ℝ (extChartAt 𝓘(ℝ,E) b ∘ (extChartAt 𝓘(ℝ,E) a).symm) y v) := by + have ht := (extChartAt 𝓘(ℝ,E) a).map_source ha + have h1 := (isOpen_extChartAt_target a).mem_nhds ht + have h2 : ∀ᶠ y in 𝓝 (extChartAt 𝓘(ℝ,E) a x), + (extChartAt 𝓘(ℝ,E) a).symm y ∈ (extChartAt 𝓘(ℝ,E) b).source := + (continuousAt_extChartAt_symm'' ht).preimage_mem_nhds + (by simpa only [(extChartAt 𝓘(ℝ,E) a).left_inv ha] using + (isOpen_extChartAt_source b).mem_nhds hb) + filter_upwards [h1,h2] with y hy1 hy2 + have hy0 := (extChartAt 𝓘(ℝ,E) a).map_target hy1 + intro u v + have h := chart_metric_transition hy0 hy2 + (g := riemannianCoordinateMetric a) (h := riemannianCoordinateMetric b) + (fun u v => by rw [riemannianCoordinateMetric_apply,(extChartAt 𝓘(ℝ,E) a).left_inv hy0]) + (fun u v => by rw [riemannianCoordinateMetric_apply,(extChartAt 𝓘(ℝ,E) b).left_inv hy2]) u v + simpa only [(extChartAt 𝓘(ℝ,E) a).right_inv hy1,Function.comp_apply] using h + +def geodesicSpray (z : TangentBundle 𝓘(ℝ,E) M) : + TangentSpace (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z := + coordinateGeodesicField (riemannianCoordinateMetric z.1) + (extChartAt 𝓘(ℝ,E) z.1 z.1,z.2) + +lemma geodesicSpray_coordinates [FiniteDimensional ℝ E] (a z : TangentBundle 𝓘(ℝ,E) M) + (ha : z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).source) : + tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z a z (geodesicSpray z) = + coordinateGeodesicField (riemannianCoordinateMetric a.1) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z) := by + have hz := mem_extChartAt_source (I := 𝓘(ℝ,E)) z.1 + have htz := (extChartAt 𝓘(ℝ,E) z.1).map_source hz + have hta := (extChartAt 𝓘(ℝ,E) a.1).map_source ha + change tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z a z + (coordinateGeodesicField (riemannianCoordinateMetric z.1) + (extChartAt 𝓘(ℝ,E) z.1 z.1,z.2)) = _ + rw [tangent_tangentCoordChange_apply z a z hz ha] + have hφ := contDiffAt_chart_transition hz ha + have he := coordinateTangentLift_push_geodesicField (E := E) + ((contDiffOn_riemannianCoordinateMetric z.1).contDiffAt + ((isOpen_extChartAt_target z.1).mem_nhds htz) |>.differentiableAt (by simp)) + (g := riemannianCoordinateMetric z.1) (h := riemannianCoordinateMetric a.1) + (φ := extChartAt 𝓘(ℝ,E) a.1 ∘ (extChartAt 𝓘(ℝ,E) z.1).symm) + (v := z.2) + (by simpa only [Function.comp_apply,(extChartAt 𝓘(ℝ,E) z.1).left_inv hz] using + ((contDiffOn_riemannianCoordinateMetric a.1).contDiffAt + ((isOpen_extChartAt_target a.1).mem_nhds hta) |>.differentiableAt (by simp))) + hφ (chart_transition_derivative_surjective hz ha) + (riemannianMetric_transition_eventually hz ha) + (riemannianCoordinateMetric_isInvertible htz) + (by simpa only [Function.comp_apply,(extChartAt 𝓘(ℝ,E) z.1).left_inv hz] using + riemannianCoordinateMetric_isInvertible hta) + (riemannianCoordinateMetric_symm a.1 _) + have hcoord : extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z z = + (extChartAt 𝓘(ℝ,E) z.1 z.1,z.2) := by + rw [tangent_chart_apply] + exact congrArg (fun v : E => (extChartAt 𝓘(ℝ,E) z.1 z.1,v)) + (tangentCoordChange_self (I := 𝓘(ℝ,E)) (v := z.2) hz) + have hlift : coordinateTangentLift + (extChartAt 𝓘(ℝ,E) a.1 ∘ (extChartAt 𝓘(ℝ,E) z.1).symm) + (extChartAt 𝓘(ℝ,E) z.1 z.1,z.2) = + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z := by + rw [tangent_chart_apply] + simp only [coordinateTangentLift,Function.comp_apply, + (extChartAt 𝓘(ℝ,E) z.1).left_inv hz,(hasFDerivAt_chart_transition hz ha).fderiv] + rw [hcoord] + rw [hlift] at he + convert! he using 1 + +lemma contMDiff_geodesicSpray [FiniteDimensional ℝ E] : + ContMDiff (𝓘(ℝ,E).prod 𝓘(ℝ,E)) + ((𝓘(ℝ,E).prod 𝓘(ℝ,E)).prod 𝓘(ℝ,E × E)) ∞ + (fun z : TangentBundle 𝓘(ℝ,E) M => + (⟨z,geodesicSpray z⟩ : TangentBundle (𝓘(ℝ,E).prod 𝓘(ℝ,E)) _)) := by + intro a + apply (Bundle.contMDiffAt_section a).mpr + have ha := mem_extChartAt_source (I := 𝓘(ℝ,E)) a.1 + have hat := (extChartAt 𝓘(ℝ,E) a.1).map_source ha + have hg := (contDiffOn_riemannianCoordinateMetric a.1).contDiffAt + ((isOpen_extChartAt_target a.1).mem_nhds hat) + have hf := contDiffAt_coordinateGeodesicField (E := E) (v := a.2) hg + (riemannianCoordinateMetric_isInvertible hat) + have hself : extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a a = + (extChartAt 𝓘(ℝ,E) a.1 a.1,a.2) := by + rw [tangent_chart_apply] + exact congrArg (fun v : E => (extChartAt 𝓘(ℝ,E) a.1 a.1,v)) + (tangentCoordChange_self (I := 𝓘(ℝ,E)) (v := a.2) ha) + have hf' : ContMDiffAt 𝓘(ℝ,E × E) 𝓘(ℝ,E × E) ∞ + (coordinateGeodesicField (riemannianCoordinateMetric a.1)) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a a) := by + rw [hself] + exact hf.contMDiffAt + have hc := (contMDiffOn_extChartAt (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) + (n := ∞) (x := a)).contMDiffAt + (by simpa only [extChartAt_source] using + ((isOpen_extChartAt_source (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a))) + apply (hf'.comp a hc).congr_of_eventuallyEq + filter_upwards [(isOpen_extChartAt_source (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a)] with z hz + change tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z a z (geodesicSpray z) = _ + exact geodesicSpray_coordinates a z ((tangent_chart_source_iff a z).mp hz) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GlobalGauss.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GlobalGauss.lean new file mode 100644 index 0000000000000000000000000000000000000000..81933b498a1791508239d3386ebb5d4fa40c4ffb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GlobalGauss.lean @@ -0,0 +1,213 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayProjection +import OAI.Analysis.BiholderTransport.Coordinates.IntrinsicGradient +import OAI.Analysis.BiholderTransport.Coordinates.CoordinatePairingDerivative + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma sprayFlow_chart_hasDerivAt (a z : TangentBundle 𝓘(ℝ,E) M) {t : ℝ} + (hz : (sprayFlow t z).1 ∈ (extChartAt 𝓘(ℝ,E) a.1).source) : + HasDerivAt (fun r => extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a (sprayFlow r z)) + (coordinateGeodesicField (riemannianCoordinateMetric a.1) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a (sprayFlow t z))) t := by + have hsrc : sprayFlow t z ∈ (chartAt (ModelProd E E) a).source := by + simpa only [extChartAt_source] using (tangent_chart_source_iff a (sprayFlow t z)).mpr hz + have hD := (hasMFDerivAt_extChartAt (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) hsrc).comp t + (sprayFlow_curve z t) + rw [hasMFDerivAt_iff_hasFDerivAt] at hD + let L : ℝ →L[ℝ] E×E := + (tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (sprayFlow t z) a (sprayFlow t z)).comp + ((1 : ℝ →L[ℝ] ℝ).smulRight (geodesicSpray (sprayFlow t z))) + have hD' : HasFDerivAt (fun r => extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a (sprayFlow r z)) L t := by + convert! hD using 1 + rw [mfderiv_chartAt_eq_tangentCoordChange hsrc] + rfl + have hd := hD'.hasDerivAt + apply hd.congr_deriv + change tangentCoordChange (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (sprayFlow t z) a (sprayFlow t z) + ((1:ℝ) • geodesicSpray (sprayFlow t z)) = _ + rw [one_smul] + exact geodesicSpray_coordinates a (sprayFlow t z) hz + +omit [FiniteDimensional ℝ E] [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma contMDiff_fiber_line (x : M) (v w : TangentSpace 𝓘(ℝ,E) x) : + ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (fun s : ℝ => (⟨x,v+s • w⟩ : TangentBundle 𝓘(ℝ,E) M)) := by + intro s + rw [Bundle.contMDiffAt_totalSpace] + refine ⟨contMDiffAt_const,?_⟩ + let e := trivializationAt E (fun y : M => TangentSpace 𝓘(ℝ,E) y) x + let L : TangentSpace 𝓘(ℝ,E) x →L[ℝ] E := e.continuousLinearMapAt ℝ x + have heq : (fun r : ℝ => (e (⟨x,v+r • w⟩ : TangentBundle 𝓘(ℝ,E) M)).2) = + (fun r : ℝ => L (v+r • w)) := by + funext r + exact (e.continuousLinearMapAt_apply_of_mem ℝ (mem_baseSet_trivializationAt E _ x) _).symm + change ContMDiffAt 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ (fun r : ℝ => (e ⟨x,v+r • w⟩).2) s + rw [heq] + exact (L.contDiff.comp (contDiff_const.add (contDiff_id.smul contDiff_const))).contDiffAt.contMDiffAt + +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +local instance globalPairingNormedSpace : NormedSpace ℝ E := InnerProductSpace.toNormedSpace + +lemma spray_variation_pairing_hasDerivAt + {ν : ℝ → TangentBundle 𝓘(ℝ,E) M} + (hν : ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ ν) + {s e : ℝ} (he : HasDerivAt (fun r => ‖(ν r).2‖^2) e s) (t : ℝ) : + HasDerivAt (fun r => inner ℝ (sprayFlow r (ν s)).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (sprayFlow r (ν k)).1) s 1)) (e/2) t := by + let F : ℝ×ℝ → TangentBundle 𝓘(ℝ,E) M := fun z => sprayFlow z.1 (ν z.2) + let a := F (t,s) + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a + let c := extChartAt 𝓘(ℝ,E) a.1 + let g := riemannianCoordinateMetric (E := E) a.1 + let U := F ⁻¹' χ.source + let A : ℝ×ℝ → E := fun z => (χ (F z)).1 + let V : ℝ×ℝ → E := fun z => (χ (F z)).2 + have hF : ContMDiff 𝓘(ℝ,ℝ×ℝ) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ F := + contMDiff_sprayFlow.comp (contDiff_fst.contMDiff.prodMk (hν.comp contDiff_snd.contMDiff)) + have hU : IsOpen U := (isOpen_extChartAt_source (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).preimage hF.continuous + have hts : (t,s) ∈ U := mem_extChartAt_source a + have hχ : ContMDiffOn (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E×E) ∞ χ χ.source := by + simpa only [χ,extChartAt_source] using + (contMDiffOn_extChartAt (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) (n := ∞) (x := a)) + have hq : ContDiffOn ℝ ∞ (fun z => χ (F z)) U := + (hχ.comp hF.contMDiffOn (fun _ h => h)).contDiffOn + have hbase (z : ℝ×ℝ) (hz : z ∈ U) : (F z).1 ∈ c.source := + (tangent_chart_source_iff a (F z)).mp hz + have himg (z : ℝ×ℝ) (hz : z ∈ U) : A z ∈ c.target := c.map_source (hbase z hz) + have hode (z : ℝ×ℝ) (hz : z ∈ U) : + HasDerivAt (fun q => A (q,z.2)) (V z) z.1 ∧ + HasDerivAt (fun q => V (q,z.2)) (-coordinateChristoffel g (A z) (V z) (V z)) z.1 := by + have hd := sprayFlow_chart_hasDerivAt a (ν z.2) (hbase z hz) + exact ⟨(ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt z.1 hd, + (ContinuousLinearMap.snd ℝ E E).hasFDerivAt.comp_hasDerivAt z.1 hd⟩ + have henergy : HasDerivAt (fun r => g (A (t,r)) (V (t,r)) (V (t,r))) e s := by + apply he.congr_of_eventuallyEq + have hnear : ∀ᶠ r in 𝓝 s, (t,r) ∈ U := + (continuous_const.prodMk continuous_id).continuousAt.preimage_mem_nhds (hU.mem_nhds hts) + filter_upwards [hnear] with r hr + exact (coordinate_spray_energy a (F (t,r)) (hbase _ hr)).trans + (congrArg (fun a : ℝ => a^2) (sprayFlow_speed t (ν r))) + have hG := coordinate_pairing_hasDerivAt (isOpen_extChartAt_target a.1) + (contDiffOn_riemannianCoordinateMetric a.1) + (fun _ hz => riemannianCoordinateMetric_isInvertible hz) + (fun _ _ => riemannianCoordinateMetric_symm _ _) + hU hq.fst hq.snd himg hode hts henergy + apply hG.congr_of_eventuallyEq + have hnear : ∀ᶠ r in 𝓝 t, (r,s) ∈ U := + (continuous_id.prodMk continuous_const).continuousAt.preimage_mem_nhds (hU.mem_nhds hts) + filter_upwards [hnear] with r hr + have hp : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ (fun k => (F (r,k)).1) := + (Bundle.contMDiff_proj (fun x : M => TangentSpace 𝓘(ℝ,E) x)).comp + (hF.comp (contMDiff_const.prodMk_space contMDiff_id)) + have hsrc : (F (r,s)).1 ∈ (chartAt E a.1).source := by + simpa only [c,extChartAt_source] using hbase _ hr + have hDc := (hasMFDerivAt_extChartAt (I := 𝓘(ℝ,E)) hsrc).comp s + (hp.mdifferentiable (by simp) s).hasMFDerivAt + rw [hasMFDerivAt_iff_hasFDerivAt] at hDc + have hAr := hasDerivAt_slice_right ((hq.fst.contDiffAt (hU.mem_nhds hr)).differentiableAt (by simp)) + let L : ℝ →L[ℝ] E := (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c (F (r,s)).1).comp + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (F (r,k)).1) s) + have hDc' : HasFDerivAt (fun k => c (F (r,k)).1) L s := by convert! hDc using 1 + have hJ := hAr.unique hDc'.hasDerivAt + change directionalDerivative A (0,1) (r,s) = + (mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c (F (r,s)).1) + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (F (r,k)).1) s 1) at hJ + have hvel : V (r,s) = mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c (F (r,s)).1 (F (r,s)).2 := by + rw [mfderiv_extChartAt_eq_tangentCoordChange (hbase _ hr)] + rfl + change inner ℝ (F (r,s)).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (F (r,k)).1) s 1) = + g (A (r,s)) (V (r,s)) (directionalDerivative A (0,1) (r,s)) + apply (coordinate_metric_chart_pairing (hbase _ hr) _ _).symm.trans + convert! congrArg₂ (fun u v : E => g (A (r,s)) u v) hvel.symm hJ.symm using 1 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GoodContact.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GoodContact.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c3d507778bae6a88f1598ab691a6639cabc887b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GoodContact.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.OriginalMass +import OAI.Analysis.BiholderTransport.Volume.MeasurableFullSubset + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Metric Manifold Bundle +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section GoodContact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma minimizing_dualPair_good_contact_set {lam cap : ℝ} (hlam : 0 (hG x hx).1,?_⟩ + · intro x hx z hz he + apply (hG z hz).2 x + change T x=T z at he + rw [←he] + exact hT x + · intro A hA hAG + have he : contactImage u v A=T '' A := by + ext y + constructor + · rintro ⟨x,hx,hxy⟩ + refine ⟨x,hx,?_⟩ + apply contact_unique_of_mdifferentiable v.continuous (hG x (hAG hx)).1 + · exact contactSelection_mem v.continuous x + · rwa [←huv.1] + · rintro ⟨x,hx,rfl⟩ + exact ⟨x,hx,hT x⟩ + simpa only [he] using minimizing_dualPair_contact_volume hlam hcap h0 h1 huv hmin hA + +end GoodContact +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/GraphGlobalMinimal.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/GraphGlobalMinimal.lean new file mode 100644 index 0000000000000000000000000000000000000000..27c4fa53b5f0427889ff22bb64352940197c10f1 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/GraphGlobalMinimal.lean @@ -0,0 +1,308 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.GraphProjection + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_minimizing_graph_point {u : M → ℝ} (hu : Continuous u) + {t : ℝ} (ht : 0 hmin (mem_univ a)⟩ + · dsimp only [graphProjection] + rw [smul_smul,mul_inv_cancel₀ ht.ne',one_smul,hpy] + · simpa only [smul_smul,mul_inv_cancel₀ ht.ne',one_smul] using hp + +lemma global_min_of_injective_graphProjection {u : M → ℝ} (hu : Continuous u) + {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma interior_minimizingVectors_subset (x : M) : + interior (minimizingVectors (n := n) x) ⊆ injectivityDomain x := by + intro p hp + have h : {a : ℝ | a • p ∈ minimizingVectors (n := n) x} ∈ 𝓝 (1:ℝ) := by + have H := (continuous_id.smul continuous_const : Continuous (fun a : ℝ => a • p)) + apply H.continuousAt.preimage_mem_nhds + change minimizingVectors (n := n) x ∈ 𝓝 ((1:ℝ) • p) + simpa only [one_smul] using mem_interior_iff_mem_nhds.mp hp + obtain ⟨δ,hδ,hball⟩ := Metric.mem_nhds_iff.mp h + let a := 1+δ/2 + have ha : 1 TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma spray_variation_pairing_affine + {ν : ℝ → TangentBundle 𝓘(ℝ,E) M} + (hν : ContMDiff 𝓘(ℝ,ℝ) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ ν) + {s e : ℝ} (he : HasDerivAt (fun r => ‖(ν r).2‖^2) e s) (t : ℝ) : + inner ℝ (sprayFlow t (ν s)).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (sprayFlow t (ν k)).1) s 1) = + inner ℝ (ν s).2 (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (ν k).1) s 1) + t*(e/2) := by + let P : ℝ → ℝ := fun r => inner ℝ (sprayFlow r (ν s)).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (sprayFlow r (ν k)).1) s 1) + have hP (r : ℝ) : HasDerivAt P (e/2) r := spray_variation_pairing_hasDerivAt hν he r + have hd (r : ℝ) : HasDerivAt (fun q => P q-q*(e/2)) 0 r := by + convert! (hP r).sub ((hasDerivAt_id r).mul_const (e/2)) using 1; simp + have hc := is_const_of_deriv_eq_zero + (fun point => (hd point).differentiableAt) + (fun point => (hd point).deriv) t (0 : ℝ) + have hP0 : P 0 = inner ℝ (ν s).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (ν k).1) s 1) := by + have hflow0 : (fun k => sprayFlow 0 (ν k)) = ν := funext (fun k => sprayFlow_zero (ν k)) + exact congrArg (fun γ : ℝ → TangentBundle 𝓘(ℝ,E) M => + inner ℝ (γ s).2 (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun k => (γ k).1) s 1)) hflow0 + simp only [zero_mul,sub_zero,hP0] at hc + dsimp [P] at hc + linarith + +lemma sprayFlow_gauss (x : M) (v w : TangentSpace 𝓘(ℝ,E) x) (t : ℝ) : + inner ℝ (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).2 + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) + (fun s : ℝ => (sprayFlow t (⟨x,v+s • w⟩ : TangentBundle 𝓘(ℝ,E) M)).1) 0 1) = + t*inner ℝ v w := by + let ν : ℝ → TangentBundle 𝓘(ℝ,E) M := fun s => ⟨x,v+s • w⟩ + have he : HasDerivAt (fun s : ℝ => ‖(ν s).2‖^2) (2*inner ℝ v w) 0 := by + have hh := ((hasDerivAt_const (0:ℝ) v).add ((hasDerivAt_id (0:ℝ)).smul_const w)).norm_sq + simpa [ν] using hh + have hh := spray_variation_pairing_affine (ν := ν) (contMDiff_fiber_line x v w) he t + have hν0 : ν 0 = (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M) := by + dsimp [ν]; rw [zero_smul,add_zero] + rw [hν0] at hh + convert! hh using 1 + simp [ν] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveLocal.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveLocal.lean new file mode 100644 index 0000000000000000000000000000000000000000..33e71d7bb84842e1a020062fa4ffe6ba7bdb547b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveLocal.lean @@ -0,0 +1,199 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MetricCurveSpeed +import OAI.Analysis.BiholderTransport.Geodesics.GeodesicExistence +import OAI.Analysis.BiholderTransport.Coordinates.NormalRigidity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma metric_curve_eq_spray_local {γ : ℝ → M} {t k ε : ℝ} + (hγ : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ γ) (hε : 0 < ε) + (hd : ∀ s u : ℝ, |s-t| < ε → |u-t| < ε → dist (γ s) (γ u) = |s-u| * k) : + γ =ᶠ[𝓝 t] (fun s => + (sprayFlow (s-t) ⟨γ t,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)⟩).1) := by + let a := γ t + let c := extChartAt 𝓘(ℝ,E) a + let q := c ∘ γ + let g := riemannianCoordinateMetric (E := E) a + obtain ⟨δ,r,τ,hδ,hr,hτ,hτr,Ψ,W,e,hΨ,hW,hinit,hode,hef,hes,he0,hesub, + hed,hei,hball,hdist,hD⟩ := exists_metric_normal_flow (E := E) a + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨by linarith,hr⟩ + have htau : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have hnear : γ ⁻¹' Metric.ball a δ ∩ Metric.ball t ε ∈ 𝓝 t := + inter_mem (hγ.continuous.continuousAt.preimage_mem_nhds (Metric.ball_mem_nhds a hδ)) + (Metric.ball_mem_nhds t hε) + obtain ⟨η,hη,hsub⟩ := Metric.mem_nhds_iff.mp hnear + let J := Ioo (t-η) (t+η) + have hJ : ∀ s ∈ J, |s-t| < η := by intro s hs; exact abs_lt.mpr ⟨by linarith [hs.1],by linarith [hs.2]⟩ + have hJt : t ∈ J := ⟨by linarith,by linarith⟩ + have hclose : ∀ s ∈ J, γ s ∈ Metric.ball a δ ∧ |s-t| < ε := by + intro s hs + have H := hsub (show s ∈ Metric.ball t η by simpa only [Metric.mem_ball,Real.dist_eq] using hJ s hs) + exact ⟨H.1,by simpa only [Metric.mem_ball,Real.dist_eq] using H.2⟩ + have hqsrc : ∀ s ∈ J, γ s ∈ c.source := fun s hs => (hball (hclose s hs).1).1 + have hqt : ∀ s ∈ J, q s ∈ e.target := fun s hs => (hball (hclose s hs).1).2 + have hq : ∀ s ∈ J, ContDiffAt ℝ ∞ q s := by + intro s hs + exact ((contMDiffAt_extChartAt' (I := 𝓘(ℝ,E)) (x := a) (by simpa only [c,extChartAt_source] using hqsrc s hs)).comp s hγ.contMDiffAt).contDiffAt + let f : ℝ → E := e.symm ∘ q + have hf : ∀ s ∈ J, ContDiffAt ℝ ∞ f s := by + intro s hs + exact (hei.contDiffAt (e.open_target.mem_nhds (hqt s hs))).comp s (hq s hs) + have hfs : MapsTo f J e.source := fun s hs => e.map_target (hqt s hs) + have hf0 : f t = 0 := by change e.symm (c a) = 0; rw [←he0]; exact e.left_inv hes + have heq : ∀ s ∈ J, e (f s) = q s := fun s hs => e.right_inv (hqt s hs) + have heqnear : ∀ s ∈ J, (e ∘ f) =ᶠ[𝓝 s] q := by + intro s hs + filter_upwards [isOpen_Ioo.mem_nhds hs] with u hu + exact heq u hu + have hsquares : ∀ s ∈ J, τ^2*g (c a) (f s) (f s) = (s-t)^2*k^2 := by + intro s hs + calc + _ = (τ*Real.sqrt (g (c a) (f s) (f s)))^2 := by + rw [mul_pow,Real.sq_sqrt (positive_bilinear_nonneg _ + (fun v hv => riemannianCoordinateMetric_positive (mem_extChartAt_target a) hv) _)] + _ = dist (γ t) (γ s)^2 := by rw [hdist (γ s) (hclose s hs).1]; rfl + _ = _ := by rw [hd t s (by simpa only [sub_self,abs_zero] using hε) (hclose s hs).2, + mul_pow,sq_abs]; ring + have hlin : ∀ s ∈ J, f s = (s-t) • deriv f t := by + apply normal_chart_radial_rigidity e hed hei (g (c a)) + (riemannianCoordinateMetric_symm a (c a)) g (fun v => W (τ,v)) τ k + (fun v hv w hw => riemannianCoordinateMetric_positive (by rw [hef]; exact (hode τ htau v (hesub hv)).1) hw) + (fun v _ => riemannianCoordinateMetric_symm a (e v)) ?_ ?_ ?_ + (fun s hs => (hf s hs).contDiffWithinAt) hJt hfs ?_ hsquares + · intro v hv + have H := coordinate_geodesic_speed_constant + (fun s hs => ((contDiffOn_riemannianCoordinateMetric a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds (hode s hs v (hesub hv)).1)).differentiableAt (by simp)) + (fun s hs => riemannianCoordinateMetric_isInvertible (hode s hs v (hesub hv)).1) + (fun s _ => riemannianCoordinateMetric_symm a (Ψ (s,v))) + (fun s hs => (hode s hs v (hesub hv)).2) htau h0 + simpa only [hef,(hinit v (hesub hv)).1,(hinit v (hesub hv)).2] using H + · intro v hv w + have H := coordinate_endpoint_gauss (isOpen_extChartAt_target a) + (contDiffOn_riemannianCoordinateMetric a) + (fun x hx => riemannianCoordinateMetric_isInvertible hx) + (fun x _ => riemannianCoordinateMetric_symm a x) hΨ hW + (fun s hs v hv => (hode s hs v hv).1) (fun s hs v hv => (hode s hs v hv).2) + h0 (fun v hv => (hinit v hv).1) (fun v hv => (hinit v hv).2) htau (hesub hv) w + simpa only [hef] using H + · intro v hv + rw [hef] + exact coordinate_endpoint_radial a hr hΨ hinit hode (hesub hv) htau + · intro s hs + rw [heq s hs,(heqnear s hs).deriv_eq] + have Hspeed : g (q s) (deriv q s) (deriv q s) = + ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ s (1:ℝ)‖^2 := + coordinate_curve_speed_square (hγ.mdifferentiable (by simp) s) (hqsrc s hs) + rw [Hspeed] + apply metric_curve_speed_square hγ.contMDiffAt + filter_upwards [isOpen_Ioo.mem_nhds hs] with u hu + rw [hd s u (hclose s hs).2 (hclose u hu).2,abs_sub_comm s u] + have hqtder : deriv q t = τ • deriv f t := by + have heD := (hed.contDiffAt (e.open_source.mem_nhds hes)).differentiableAt (by simp) + have hD' : HasFDerivAt e (τ • ContinuousLinearMap.id ℝ E) (f t) := by + rw [hf0,←hD]; exact heD.hasFDerivAt + have H := hD'.comp_hasDerivAt t ((hf t hJt).differentiableAt (by simp)).hasDerivAt + simpa only [smul_apply,ContinuousLinearMap.id_apply] using + (H.congr_of_eventuallyEq (heqnear t hJt).symm).deriv + have hvel : τ • deriv f t = mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ) := + hqtder.symm.trans (coordinate_curve_derivative_at_center (hγ.mdifferentiable (by simp) t)) + filter_upwards [isOpen_Ioo.mem_nhds hJt] with s hs + have H := sprayFlow_eq_coordinate_curve (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) hr + (fun u hu => (hode u hu (f s) (hesub (hfs hs))).1) + (fun u hu => (hode u hu (f s) (hesub (hfs hs))).2.1.prodMk + (hode u hu (f s) (hesub (hfs hs))).2.2) + (show (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M)).symm + (Ψ (0,f s),W (0,f s)) = ⟨a,f s⟩ by + rw [(hinit (f s) (hesub (hfs hs))).1,(hinit (f s) (hesub (hfs hs))).2] + exact tangent_chart_at_self_base_symm (⟨a,0⟩ : TangentBundle 𝓘(ℝ,E) M) (f s)) htau + have Hb := congrArg (fun z : TangentBundle 𝓘(ℝ,E) M => z.1) H + rw [tangent_chart_symm_base,←congrFun hef (f s),heq s hs] at Hb + have hbase : γ s = (sprayFlow τ ⟨a,f s⟩).1 := by + rw [Hb]; exact (c.left_inv (hqsrc s hs)).symm + rw [hbase,hlin s hs,←hvel] + rw [show (⟨a,(s-t) • deriv f t⟩ : TangentBundle 𝓘(ℝ,E) M) = + tangentScale (s-t) ⟨a,deriv f t⟩ from rfl,sprayFlow_scale] + rw [show (⟨γ t,τ • deriv f t⟩ : TangentBundle 𝓘(ℝ,E) M) = + tangentScale τ ⟨a,deriv f t⟩ from rfl,sprayFlow_scale] + change (sprayFlow ((s-t)*τ) ⟨a,deriv f t⟩).1 = (sprayFlow (τ*(s-t)) ⟨a,deriv f t⟩).1 + rw [mul_comm] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveSpeed.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveSpeed.lean new file mode 100644 index 0000000000000000000000000000000000000000..db90d2f6fa43e67c2f64edb006de191d85e17867 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricCurveSpeed.lean @@ -0,0 +1,153 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearMetricSpeedSquare +import OAI.Analysis.BiholderTransport.LocalFlow.NormalFlow + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma metric_curve_speed_square {γ : ℝ → M} {t k : ℝ} + (hγ : ContMDiffAt 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ γ t) + (hd : ∀ᶠ s in 𝓝 t, dist (γ t) (γ s) = |s-t| * k) : + ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)‖^2 = k^2 := by + let a := γ t + let c := extChartAt 𝓘(ℝ,E) a + let q : ℝ → E := c ∘ γ + let g := riemannianCoordinateMetric (E := E) a (c a) + obtain ⟨δ,_,τ,hδ,_,hτ,_,_,_,e,_,_,_,_,_,hes,he0,_,hed,hei,_,hdist,hD⟩ := + exists_metric_normal_flow (E := E) a + have hqat : q t ∈ e.target := by change c a ∈ e.target; rw [←he0]; exact e.map_source hes + have hq : ContDiffAt ℝ ∞ q t := + ((contMDiffAt_extChartAt (I := 𝓘(ℝ,E)) (x := a)).comp t hγ).contDiffAt + let f : ℝ → E := e.symm ∘ q + have hf : ContDiffAt ℝ ∞ f t := + (hei.contDiffAt (e.open_target.mem_nhds hqat)).comp t hq + have hf0 : f t = 0 := by + change e.symm (c a) = 0 + rw [←he0]; exact e.left_inv hes + have hn : ∀ᶠ s in 𝓝 t, γ s ∈ Metric.ball a δ := + hγ.continuousAt.preimage_mem_nhds (Metric.ball_mem_nhds a hδ) + have hgs : ∀ᶠ s in 𝓝 t, g (f s) (f s) = (k^2/τ^2)*(s-t)^2 := by + filter_upwards [hn,hd] with s hs hds + have H : τ^2 * g (f s) (f s) = (s-t)^2*k^2 := by + calc + _ = (τ * Real.sqrt (g (f s) (f s)))^2 := by + rw [mul_pow,Real.sq_sqrt (positive_bilinear_nonneg g + (fun v hv => riemannianCoordinateMetric_positive (mem_extChartAt_target a) hv) _)] + _ = dist (γ t) (γ s)^2 := by rw [hdist (γ s) hs]; rfl + _ = _ := by rw [hds,mul_pow,sq_abs] + rw [div_mul_eq_mul_div] + apply (eq_div_iff (pow_ne_zero 2 hτ.ne')).mpr + nlinarith [H] + have hjet := bilinear_metric_speed_of_square hf hf0 hgs + have hedf : HasDerivAt (fun s => e (f s)) (τ • deriv f t) t := by + have H := (hed.contDiffAt (e.open_source.mem_nhds hes)).differentiableAt (by simp) + have H' : HasFDerivAt e (τ • ContinuousLinearMap.id ℝ E) (f t) := by + rw [hf0]; rw [←hD]; exact H.hasFDerivAt + simpa only [Function.comp_def,smul_apply,ContinuousLinearMap.id_apply] using + H'.comp_hasDerivAt t (hf.differentiableAt (by simp)).hasDerivAt + have heq : (fun s => e (f s)) =ᶠ[𝓝 t] q := by + filter_upwards [hq.continuousAt.preimage_mem_nhds (e.open_target.mem_nhds hqat)] with s hs + exact e.right_inv hs + have hqder : deriv q t = τ • deriv f t := + (hedf.congr_of_eventuallyEq heq.symm).deriv + have hspeed : g (deriv q t) (deriv q t) = k^2 := by + simp only [hqder,map_smul,smul_apply,smul_eq_mul,hjet] + field_simp [hτ.ne'] + have hm := mfderiv_comp t (mdifferentiableAt_extChartAt + (I := 𝓘(ℝ,E)) (mem_chart_source E a)) (hγ.mdifferentiableAt (by simp)) + rw [mfderiv_eq_fderiv] at hm + have hval : deriv q t = mfderiv 𝓘(ℝ,E) 𝓘(ℝ,E) c a + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) := + congrArg (fun L : ℝ →L[ℝ] E => L 1) hm + have hnorm := coordinate_metric_chart_derivative_norm (mem_extChartAt_source (I := 𝓘(ℝ,E)) a) + (g := g) (by + intro u v + change riemannianCoordinateMetric a (c a) u v = _ + rw [riemannianCoordinateMetric_apply,c.left_inv (mem_extChartAt_source (I := 𝓘(ℝ,E)) a)]) + (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t 1) + rw [←hval] at hnorm + calc + _ = (Real.sqrt (g (deriv q t) (deriv q t)))^2 := + congrArg (fun x : ℝ => x^2) hnorm.symm + _ = g (deriv q t) (deriv q t) := Real.sq_sqrt (positive_bilinear_nonneg g + (fun v hv => riemannianCoordinateMetric_positive (mem_extChartAt_target a) hv) _) + _ = k^2 := hspeed + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricGeodesicLift.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricGeodesicLift.lean new file mode 100644 index 0000000000000000000000000000000000000000..fafff826fed059188b7d55f2dc8760fcc54e031f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricGeodesicLift.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MetricCurveLocal + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [FiniteDimensional ℝ E] [CompactSpace M] [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma velocity_lift_eq_of_eventuallyEq {γ δ : ℝ → M} {t : ℝ} + (he : γ =ᶠ[𝓝 t] δ) : + (⟨γ t,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)⟩ : TangentBundle 𝓘(ℝ,E) M) = + ⟨δ t,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) δ t (1:ℝ)⟩ := by + refine TotalSpace.ext he.self_of_nhds ?_ + exact heq_of_eq (DFunLike.congr_fun he.mfderiv_eq (1 : ℝ)) + +lemma metric_curve_velocity_isMIntegralCurve {γ : ℝ → M} {k : ℝ} + (hγ : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ γ) + (hloc : ∀ t : ℝ, ∃ ε : ℝ, 0 < ε ∧ ∀ s u : ℝ, + |s-t| < ε → |u-t| < ε → dist (γ s) (γ u) = |s-u| * k) : + IsMIntegralCurve + (fun t => (⟨γ t,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)⟩ : TangentBundle 𝓘(ℝ,E) M)) + (geodesicSpray (E := E)) := by + intro t + obtain ⟨ε,hε,hd⟩ := hloc t + let δ : ℝ → TangentBundle 𝓘(ℝ,E) M := fun s => + sprayFlow (s-t) ⟨γ t,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ t (1:ℝ)⟩ + have hδ : IsMIntegralCurve δ (geodesicSpray (E := E)) := + isMIntegralCurve_comp_sub.mpr (sprayFlow_curve _) + have he : γ =ᶠ[𝓝 t] (fun s => (δ s).1) := metric_curve_eq_spray_local hγ hε hd + have hL : (fun s => (⟨γ s,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ s (1:ℝ)⟩ : TangentBundle 𝓘(ℝ,E) M)) + =ᶠ[𝓝 t] δ := by + filter_upwards [he.eventuallyEq_nhds] with s hs + rw [velocity_lift_eq_of_eventuallyEq hs, + spray_velocity_eq_mfderiv (hδ.isMIntegralCurveAt s)] + have H := (hδ t).congr_of_eventuallyEq hL + rw [←hL.self_of_nhds] at H + exact H + +lemma metric_curve_eq_spray {γ : ℝ → M} {k : ℝ} + (hγ : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ γ) + (hloc : ∀ t : ℝ, ∃ ε : ℝ, 0 < ε ∧ ∀ s u : ℝ, + |s-t| < ε → |u-t| < ε → dist (γ s) (γ u) = |s-u| * k) : + γ = (fun t => (sprayFlow t ⟨γ 0,mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) γ 0 (1:ℝ)⟩).1) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + have H := isMIntegralCurve_Ioo_eq_of_contMDiff_boundaryless (t₀ := 0) + (contMDiff_geodesicSpray.of_le (by simp)) + (metric_curve_velocity_isMIntegralCurve hγ hloc) (sprayFlow_curve _) + (sprayFlow_zero _).symm + funext t + exact congrArg (fun z : TangentBundle 𝓘(ℝ,E) M => z.1) (congrFun H t) + +end + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma geodesicWithInitialData_eq_spray {x : M} {v : TangentSpace 𝓘(ℝ,Model n) x} + {γ : ℝ → M} (hγ : IsGeodesicWithInitialData x v γ) : + γ = (fun t => (sprayFlow t ⟨x,v⟩).1) := by + have H := metric_curve_eq_spray hγ.1 hγ.2.2 + rwa [hγ.2.1] at H + +lemma riemannianExp_eq_sprayFlow (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + riemannianExp x v = (sprayFlow 1 ⟨x,v⟩).1 := by + rw [riemannianExp_eq_chosen_geodesic, + geodesicWithInitialData_eq_spray (Classical.choose_spec (exists_geodesicWithInitialData x v))] + +lemma riemannianExp_smul (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) (t : ℝ) : + riemannianExp x (t • v) = (sprayFlow t ⟨x,v⟩).1 := by + rw [riemannianExp_eq_sprayFlow] + change (sprayFlow 1 (tangentScale t ⟨x,v⟩)).1 = _ + rw [sprayFlow_scale,mul_one] + rfl + +lemma contMDiff_riemannianExp : + ContMDiff (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,Model n) ∞ + (fun z : TangentBundle 𝓘(ℝ,Model n) M => riemannianExp z.1 z.2) := by + have hF : ContMDiff (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun z : TangentBundle 𝓘(ℝ,Model n) M => sprayFlow 1 z) := + contMDiff_sprayFlow.comp (contMDiff_const.prodMk contMDiff_id) + have H := (Bundle.contMDiff_proj (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)).comp hF + apply H.congr + intro z + cases z + exact riemannianExp_eq_sprayFlow _ _ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricSegments.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricSegments.lean new file mode 100644 index 0000000000000000000000000000000000000000..75cff42ca62f09b0d1d2ddd71057c2967c556011 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MetricSegments.lean @@ -0,0 +1,200 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +namespace WeakMTWTransport +variable {M : Type*} [MetricSpace M] + +def IsMetricChain (x y : M) (A : Set (ℝ × M)) : Prop := + (0,x) ∈ A ∧ (dist x y,y) ∈ A ∧ + A ⊆ Icc 0 (dist x y) ×ˢ univ ∧ + ∀ u ∈ A, ∀ v ∈ A, dist u.2 v.2 = |u.1-v.1| + +lemma isMetricChain_initial (x y : M) : + IsMetricChain x y {(0,x),(dist x y,y)} := by + refine ⟨by simp,by simp,?_,?_⟩ + · intro u hu + rcases hu with hu|hu + · subst u; exact ⟨⟨le_rfl,dist_nonneg⟩,mem_univ _⟩ + · rcases hu with rfl + exact ⟨⟨dist_nonneg,le_rfl⟩,mem_univ _⟩ + · intro u hu v hv + rcases hu with rfl|hu <;> rcases hv with rfl|hv + · simp + · rcases hv with rfl + simp [abs_of_nonneg dist_nonneg] + · rcases hu with rfl + simp [dist_comm,abs_of_nonneg dist_nonneg] + · rcases hu with rfl; rcases hv with rfl + simp + +lemma IsMetricChain.closure {x y : M} {A : Set (ℝ × M)} + (hA : IsMetricChain x y A) : IsMetricChain x y (closure A) := by + refine ⟨subset_closure hA.1,subset_closure hA.2.1, + closure_minimal hA.2.2.1 (isClosed_Icc.prod isClosed_univ),?_⟩ + intro u hu v hv + have hvA (w : ℝ × M) (hw : w ∈ A) : dist w.2 v.2 = |w.1-v.1| := by + have hc : IsClosed {v : ℝ × M | dist w.2 v.2 = |w.1-v.1|} := + isClosed_eq (by fun_prop) (by fun_prop) + exact closure_minimal (fun z hz => hA.2.2.2 w hw z hz) hc hv + have hc : IsClosed {u : ℝ × M | dist u.2 v.2 = |u.1-v.1|} := + isClosed_eq (by fun_prop) (by fun_prop) + exact closure_minimal hvA hc hu + +lemma exists_maximal_metricChain (x y : M) : + ∃ A : Set (ℝ × M), Maximal (IsMetricChain x y) A := by + let S : Set (Set (ℝ × M)) := {A | IsMetricChain x y A} + have hchains : ∀ c ⊆ S, IsChain (fun a b => a ⊆ b) c → c.Nonempty → + ∃ ub ∈ S, ∀ s ∈ c, s ⊆ ub := by + intro c hc hchain hne + obtain ⟨B,hB⟩ := hne + refine ⟨⋃₀ c,?_,fun s hs => subset_sUnion_of_mem hs⟩ + refine ⟨mem_sUnion.mpr ⟨B,hB,(hc hB).1⟩, + mem_sUnion.mpr ⟨B,hB,(hc hB).2.1⟩,?_,?_⟩ + · intro u hu + obtain ⟨C,hC,huC⟩ := mem_sUnion.mp hu + exact (hc hC).2.2.1 huC + · intro u hu v hv + obtain ⟨C,hC,huC⟩ := mem_sUnion.mp hu + obtain ⟨D,hD,hvD⟩ := mem_sUnion.mp hv + obtain ⟨F,hF,hCF,hDF⟩ := hchain.directedOn C hC D hD + exact (hc hF).2.2.2 u (hCF huC) v (hDF hvD) + obtain ⟨A,_,hA⟩ := zorn_subset_nonempty S hchains + {(0,x),(dist x y,y)} (isMetricChain_initial x y) + exact ⟨A,hA⟩ + +lemma insert_midpoint_metricChain {x y : M} {A : Set (ℝ × M)} + (hA : IsMetricChain x y A) {u v : ℝ × M} (hu : u ∈ A) (hv : v ∈ A) + (huv : u.1 < v.1) + (hgap : ∀ w ∈ A, w.1 ≤ u.1 ∨ v.1 ≤ w.1) {z : M} + (huz : dist u.2 z = dist u.2 v.2/2) + (hzv : dist z v.2 = dist u.2 v.2/2) : + IsMetricChain x y (insert ((u.1+v.1)/2,z) A) := by + let m : ℝ := (u.1+v.1)/2 + have hadist : dist u.2 v.2 = v.1-u.1 := by + rw [hA.2.2.2 u hu v hv,abs_of_neg (sub_neg.mpr huv)] + ring + rw [hadist] at huz hzv + have hwm (w : ℝ × M) (hw : w ∈ A) : dist w.2 z = |w.1-m| := by + have hwu := hA.2.2.2 w hw u hu + have hwv := hA.2.2.2 w hw v hv + rcases hgap w hw with hleft|hright + · have habs1 : |w.1-u.1| = u.1-w.1 := by rw [abs_of_nonpos (sub_nonpos.mpr hleft)]; ring + have habs2 : |w.1-v.1| = v.1-w.1 := by rw [abs_of_nonpos (by linarith)]; ring + rw [habs1] at hwu + rw [habs2] at hwv + have hwmle : w.1 ≤ m := by dsimp [m]; linarith + rw [abs_of_nonpos (sub_nonpos.mpr hwmle)] + have hubound := dist_triangle w.2 u.2 z + have hlbound := dist_triangle w.2 z v.2 + dsimp [m] + linarith + · have habs1 : |w.1-u.1| = w.1-u.1 := abs_of_nonneg (by linarith) + have habs2 : |w.1-v.1| = w.1-v.1 := abs_of_nonneg (sub_nonneg.mpr hright) + rw [habs1] at hwu + rw [habs2] at hwv + have hwmle : m ≤ w.1 := by dsimp [m]; linarith + rw [abs_of_nonneg (sub_nonneg.mpr hwmle)] + have hubound := dist_triangle w.2 v.2 z + have hlbound := dist_triangle w.2 z u.2 + rw [dist_comm v.2 z] at hubound + rw [dist_comm z u.2] at hlbound + dsimp [m] + linarith + refine ⟨mem_insert_of_mem _ hA.1,mem_insert_of_mem _ hA.2.1,?_,?_⟩ + · intro w hw + rcases hw with rfl|hw + · have hux := (hA.2.2.1 hu).1 + have hvx := (hA.2.2.1 hv).1 + exact ⟨⟨by dsimp; linarith [hux.1,hvx.1],by dsimp; linarith [hux.2,hvx.2]⟩,mem_univ _⟩ + · exact hA.2.2.1 hw + · intro w hw q hq + rcases hw with rfl|hw <;> rcases hq with rfl|hq + · simp + · simpa only [dist_comm z q.2,abs_sub_comm] using hwm q hq + · exact hwm w hw + · exact hA.2.2.2 w hw q hq + +lemma maximal_metricChain_full_projection [CompactSpace M] (x y : M) + (hmid : ∀ u v : M, ∃ z, dist u z = dist u v/2 ∧ dist z v = dist u v/2) + {A : Set (ℝ × M)} (hA : Maximal (IsMetricChain x y) A) : + Prod.fst '' A = Icc 0 (dist x y) := by + have hAc : IsClosed A := by + have heq : closure A = A := subset_antisymm (hA.2 hA.1.closure subset_closure) subset_closure + rw [← heq] + exact isClosed_closure + have hAk : IsCompact A := (isCompact_Icc.prod isCompact_univ).of_isClosed_subset hAc hA.1.2.2.1 + let K : Set ℝ := Prod.fst '' A + have hK : IsCompact K := hAk.image continuous_fst + apply Subset.antisymm + · rintro t ⟨w,hw,rfl⟩ + exact (hA.1.2.2.1 hw).1 + · intro t ht + by_contra htn + have hK0 : 0 ∈ K := ⟨(0,x),hA.1.1,rfl⟩ + have hKL : dist x y ∈ K := ⟨(dist x y,y),hA.1.2.1,rfl⟩ + obtain ⟨a,ha,hamax⟩ := (hK.inter_right isClosed_Iic).exists_isMaxOn + ⟨0,hK0,ht.1⟩ continuousOn_id + obtain ⟨b,hb,hbmin⟩ := (hK.inter_right isClosed_Ici).exists_isMinOn + ⟨dist x y,hKL,ht.2⟩ continuousOn_id + have hat : a < t := lt_of_le_of_ne ha.2 (by intro heq; exact htn (heq ▸ ha.1)) + have htb : t < b := lt_of_le_of_ne hb.2 (by intro heq; exact htn (heq.symm ▸ hb.1)) + obtain ⟨u,hu,hua⟩ := ha.1 + obtain ⟨v,hv,hvb⟩ := hb.1 + have huv : u.1 < v.1 := by rw [hua,hvb]; exact hat.trans htb + have hgap : ∀ w ∈ A, w.1 ≤ u.1 ∨ v.1 ≤ w.1 := by + intro w hw + have hwK : w.1 ∈ K := ⟨w,hw,rfl⟩ + by_cases hwt : w.1 ≤ t + · exact Or.inl (by rw [hua]; exact hamax ⟨hwK,hwt⟩) + · exact Or.inr (by rw [hvb]; exact hbmin ⟨hwK,(lt_of_not_ge hwt).le⟩) + obtain ⟨z,huz,hzv⟩ := hmid u.2 v.2 + have hi := insert_midpoint_metricChain hA.1 hu hv huv hgap huz hzv + have himem : ((u.1+v.1)/2,z) ∈ A := hA.2 hi (subset_insert _ _) (mem_insert _ _) + rcases hgap _ himem with hl|hr + · dsimp at hl; linarith + · dsimp at hr; linarith + +lemma exists_metric_segment [CompactSpace M] (x y : M) + (hmid : ∀ u v : M, ∃ z, dist u z = dist u v/2 ∧ dist z v = dist u v/2) : + ∃ γ : Icc (0:ℝ) (dist x y) → M, Isometry γ ∧ + γ ⟨0,⟨le_rfl,dist_nonneg⟩⟩ = x ∧ + γ ⟨dist x y,⟨dist_nonneg,le_rfl⟩⟩ = y := by + obtain ⟨A,hA⟩ := exists_maximal_metricChain x y + have hfull := maximal_metricChain_full_projection x y hmid hA + have hex (t : Icc (0:ℝ) (dist x y)) : ∃ z : M, (t.1,z) ∈ A := by + have hm : t.1 ∈ Prod.fst '' A := by rw [hfull]; exact t.2 + obtain ⟨w,hw,hwf⟩ := hm + exact ⟨w.2,by simpa only [← hwf] using hw⟩ + choose γ hγ using hex + refine ⟨γ,?_,?_,?_⟩ + · apply Isometry.of_dist_eq + intro s t + simpa only [Subtype.dist_eq,Real.dist_eq] using hA.1.2.2.2 (s.1,γ s) (hγ s) (t.1,γ t) (hγ t) + · have hh := hA.1.2.2.2 _ (hγ ⟨0,⟨le_rfl,dist_nonneg⟩⟩) _ hA.1.1 + exact dist_eq_zero.mp (by simpa only [sub_self,abs_zero] using hh) + · have hh := hA.1.2.2.2 _ (hγ ⟨dist x y,⟨dist_nonneg,le_rfl⟩⟩) _ hA.1.2.1 + exact dist_eq_zero.mp (by simpa only [sub_self,abs_zero] using hh) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingChartParameters.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingChartParameters.lean new file mode 100644 index 0000000000000000000000000000000000000000..3fde5ca5d7887e1e7fc040253528f99892083569 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingChartParameters.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayDistanceBound + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + +lemma tangent_chart_trivialization {a x : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) (p : TangentSpace 𝓘(ℝ,Model n) x) : + extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) ⟨x,p⟩= + (extChartAt 𝓘(ℝ,Model n) a x, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p) := by + rw [tangent_chart_apply,TangentBundle.continuousLinearMapAt_trivializationAt_eq_core + (by simpa only [extChartAt_source] using hx)] + rfl + +lemma tangent_chart_symm_trivialization {a : M} {q : Model n×Model n} + (hq : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)).symm q= + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm q.1, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1) q.2⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + have hx : (extChartAt 𝓘(ℝ,Model n) a).symm q.1∈(chartAt (Model n) a).source := by + simpa only [extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hq + rw [TangentBundle.symmL_trivializationAt_eq_core hx] + rfl + +variable [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def minimizingChartParameters (a : M) (K : Set M) : Set (Model n×Model n) := + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)) '' + {z : TangentBundle 𝓘(ℝ,Model n) M | z.2∈minimizingVectors z.1 ∧ z.1∈K} + +section +variable [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma isCompact_minimizingChartParameters {a : M} {K : Set M} + (hK : IsCompact K) (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) : + IsCompact (minimizingChartParameters (n := n) a K) := by + have hc : IsCompact {z : TangentBundle 𝓘(ℝ,Model n) M | z.2∈minimizingVectors z.1 ∧ z.1∈K} := + (isCompact_total_minimizingVectors (n := n) (M := M)).inter_right + (hK.isClosed.preimage (FiberBundle.continuous_proj _ _)) + exact hc.image_of_continuousOn ((continuousOn_extChartAt _).mono (fun z hz => + (tangent_chart_source_iff _ z).mpr (hKs hz.2))) + +end + +lemma mem_minimizingChartParameters {a : M} {K : Set M} + (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) {q : Model n×Model n} + (hq : q∈minimizingChartParameters (n := n) a K) : + q.1∈(extChartAt 𝓘(ℝ,Model n) a).target ∧ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1∈K ∧ + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1) q.2∈ + minimizingVectors ((extChartAt 𝓘(ℝ,Model n) a).symm q.1)) := by + obtain ⟨z,hz,rfl⟩ := hq + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + have hzs : z∈χ.source := (tangent_chart_source_iff _ z).mpr (hKs hz.2) + have hb : (χ z).1∈(extChartAt 𝓘(ℝ,Model n) a).target := + (tangent_chart_target_iff _ _).mp (χ.map_source hzs) + refine ⟨hb,?_⟩ + have H : (χ.symm (χ z)).1∈K ∧ (χ.symm (χ z)).2∈minimizingVectors (χ.symm (χ z)).1 := by + rw [χ.left_inv hzs] + exact ⟨hz.2,hz.1⟩ + rw [tangent_chart_symm_trivialization hb] at H + exact H + +lemma trivialization_mem_minimizingChartParameters {a x : M} {K : Set M} + (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) (hx : x∈K) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) : + (extChartAt 𝓘(ℝ,Model n) a x, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p)∈ + minimizingChartParameters (n := n) a K := + ⟨⟨x,p⟩,⟨hp,hx⟩,tangent_chart_trivialization (hKs hx) p⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingCoordinateLimit.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingCoordinateLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..df759392af942d9f97c3a574ce7ae5bfc6044c5a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingCoordinateLimit.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ActiveGraphLimit +import OAI.Analysis.BiholderTransport.Coordinates.ChartActiveLimit + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma inverse_mem_minimizingChartParameters {a : M} {K : Set M} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hK : (extChartAt 𝓘(ℝ,Model n) a).symm b∈K) + (hp : chartFiberInverse a b p∈minimizingVectors ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + (b,p)∈minimizingChartParameters (n := n) a K := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) + refine ⟨χ.symm (b,p),?_,χ.right_inv ((tangent_chart_target_iff _ _).mpr hb)⟩ + rw [tangent_chart_symm_trivialization hb] + exact ⟨hp,hK⟩ + +omit [Nonempty M] in +lemma minimizing_coordinates_tail_subseq {a : M} {bj pj : ℕ → Model n} + (hb : Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hbt : ∀ i,bj i∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hpm : ∀ i,chartFiberInverse a (bj i) (pj i)∈ + minimizingVectors ((extChartAt 𝓘(ℝ,Model n) a).symm (bj i))) : + ∃ σ : ℕ → ℕ, StrictMono σ ∧ ∃ p : Model n, + (show TangentSpace 𝓘(ℝ,Model n) a from p)∈minimizingVectors a ∧ + Tendsto (pj ∘ σ) atTop (𝓝 p) := by + let χ := extChartAt 𝓘(ℝ,Model n) a + have ha := χ.map_source (mem_extChartAt_source a) + have hy : Tendsto (fun i=>χ.symm (bj i)) atTop (𝓝 a) := by + have H := (continuousAt_extChartAt_symm'' ha).tendsto.comp hb + rwa [χ.left_inv (mem_extChartAt_source a)] at H + obtain ⟨K,hK,hKs,N,hN⟩ := compact_in_chart_tail (n := n) (a := a) hy (mem_extChartAt_source a) + have hshift : Tendsto (fun k:ℕ=>k+N) atTop atTop := tendsto_add_atTop_nat N + have hin (k : ℕ) : (bj (k+N),pj (k+N))∈minimizingChartParameters (n := n) a K := + inverse_mem_minimizingChartParameters (hbt _) (hN k) (hpm _) + obtain ⟨q,hq,σ,hσ,hlim⟩ := + (isCompact_minimizingChartParameters hK hKs).isSeqCompact hin + have hbase : q.1=χ a := tendsto_nhds_unique hlim.fst_nhds ((hb.comp hshift).comp hσ.tendsto_atTop) + have hmin := (mem_minimizingChartParameters hKs hq).2.2 + change chartFiberInverse a q.1 q.2∈minimizingVectors (χ.symm q.1) at hmin + rw [hbase,chartFiberInverse_at_center,χ.left_inv (mem_extChartAt_source a)] at hmin + exact ⟨fun k=>σ k+N,fun i j hij=>Nat.add_lt_add_right (hσ hij) N,q.2,hmin,hlim.snd_nhds⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingSubinterval.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingSubinterval.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc7ea29421af8d9ceb51ae8f7299bec3a5417c0e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/MinimizingSubinterval.lean @@ -0,0 +1,220 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.GeodesicBasics +import OAI.Analysis.BiholderTransport.Regularity.RiemannianMetricSegment +import OAI.Analysis.BiholderTransport.Geodesics.NoCorner + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_minimizing_subinterval (z : TangentBundle 𝓘(ℝ,E) M) {s t : ℝ} + (hs : 0 ≤ s) (hst : s ≤ t) + (hmin : dist z.1 (sprayFlow t z).1 = t * ‖z.2‖) : + dist (sprayFlow s z).1 (sprayFlow t z).1 = (t-s) * ‖z.2‖ := by + have hle := dist_sprayFlow_le z s t + rw [abs_of_nonpos (sub_nonpos.mpr hst),neg_sub] at hle + apply le_antisymm hle + have hlow := dist_triangle z.1 (sprayFlow s z).1 (sprayFlow t z).1 + rw [hmin,sprayFlow_minimizing_prefix z hs hst hmin] at hlow + nlinarith + +end + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_local_minimizingVectors (x : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ y ∈ Metric.ball x δ, + ∃ p ∈ minimizingVectors (n := n) x, riemannianExp x p = y := by + obtain ⟨δ,hδ,H⟩ := exists_local_cost_gradient (E := Model n) x + refine ⟨δ,hδ,?_⟩ + intro y hy + obtain ⟨q,hqx,hqn,hqb,_⟩ := H y hy x (Metric.mem_ball_self hδ) + rcases q with ⟨a,u⟩ + change a=x at hqx + subst a + have he : riemannianExp x (-u) = y := by + rw [show -u = (-1:ℝ) • u by simp,riemannianExp_smul] + exact hqb + refine ⟨-u,?_,he⟩ + change dist x (riemannianExp x (-u)) = ‖-u‖ + rw [he,norm_neg,hqn,dist_comm] + +lemma exists_minimizing_vector (x y : M) : + ∃ p ∈ minimizingVectors (n := n) x, riemannianExp x p = y := by + classical + by_cases hxy : x=y + · subst y + exact ⟨0,by simp [minimizingVectors],riemannianExp_zero x⟩ + have hD : 0 < dist x y := dist_pos.mpr hxy + obtain ⟨γ,hγ,hγ0,hγD⟩ := riemannian_exists_metric_segment (I := 𝓘(ℝ,Model n)) x y + have hd (s : Icc (0:ℝ) (dist x y)) : dist x (γ s) = s.1 := by + have hh := hγ.dist_eq (⟨0,⟨le_rfl,dist_nonneg⟩⟩ : Icc (0:ℝ) (dist x y)) s + simpa only [hγ0,Subtype.dist_eq,Real.dist_eq,zero_sub,abs_neg,abs_of_nonneg s.2.1] using hh + let R : Set M := riemannianExp (n := n) x '' minimizingVectors x + have hR : IsCompact R := (isCompact_minimizingVectors x).image (continuous_riemannianExp x) + let U : Set (Icc (0:ℝ) (dist x y)) := γ ⁻¹' R + have hU : IsCompact U := (hR.isClosed.preimage hγ.continuous).isCompact + obtain ⟨δ,hδ,Hlocal⟩ := exists_local_minimizingVectors (n := n) x + let a : ℝ := min (dist x y/2) (δ/2) + have ha : 0 < a := lt_min (by positivity) (by positivity) + have haD : a ≤ dist x y := (min_le_left _ _).trans (by linarith) + have haδ : a < δ := (min_le_right _ _).trans_lt (by linarith) + let s₀ : Icc (0:ℝ) (dist x y) := ⟨a,ha.le,haD⟩ + have hs₀ : s₀ ∈ U := by + obtain ⟨p,hp,he⟩ := Hlocal (γ s₀) (by rw [Metric.mem_ball,dist_comm,hd]; exact haδ) + exact ⟨p,hp,he⟩ + obtain ⟨s,hs,hsmax⟩ := hU.exists_isMaxOn ⟨s₀,hs₀⟩ continuous_subtype_val.continuousOn + have hs0 : 0 < s.1 := ha.trans_le (hsmax hs₀) + have hsD : s.1 = dist x y := by + by_contra hsne + have hslt : s.1 < dist x y := lt_of_le_of_ne s.2.2 hsne + obtain ⟨p,hp,hps⟩ := hs + have hpn : ‖p‖ = s.1 := by + change dist x (riemannianExp x p) = ‖p‖ at hp + rw [hps,hd] at hp + exact hp.symm + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,s.1⁻¹ • p⟩ + have hzn : ‖z.2‖ = 1 := by + change ‖s.1⁻¹ • p‖ = 1 + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hs0),hpn,inv_mul_cancel₀ hs0.ne'] + have hzflow : (sprayFlow s.1 z).1 = γ s := by + rw [←riemannianExp_smul] + rw [smul_smul,mul_inv_cancel₀ hs0.ne',one_smul,hps] + have hzmin : dist z.1 (sprayFlow s.1 z).1 = s.1 * ‖z.2‖ := by + rw [hzflow,hzn,mul_one]; exact hd s + obtain ⟨η,hη,Hext⟩ := exists_spray_local_extension (E := Model n) (γ s) + let ε : ℝ := min (η/2) (min (s.1/2) ((dist x y-s.1)/2)) + have hε : 0 < ε := lt_min (by positivity) (lt_min (by positivity) (by linarith)) + have hεη : ε < η := (min_le_left _ _).trans_lt (by linarith) + have hεs : ε < s.1 := ((min_le_right _ _).trans (min_le_left _ _)).trans_lt (by linarith) + have hεD : s.1+ε < dist x y := by + have h := (min_le_right (η/2) (min (s.1/2) ((dist x y-s.1)/2))).trans (min_le_right _ _) + change ε ≤ (dist x y-s.1)/2 at h + linarith + let s' : Icc (0:ℝ) (dist x y) := ⟨s.1+ε,by linarith,hεD.le⟩ + let q := sprayFlow s.1 z + have hqn : ‖q.2‖ = 1 := by rw [sprayFlow_speed]; exact hzn + have hqback : sprayFlow (-ε) q = sprayFlow (s.1-ε) z := by + rw [←sprayFlow_add]; congr 1; ring + have hpre : dist (sprayFlow (-ε) q).1 q.1 = ε := by + rw [hqback] + have h := sprayFlow_minimizing_subinterval z (s := s.1-ε) (by linarith) (by linarith) hzmin + rw [hzn,mul_one] at h + simpa only [sub_sub_cancel] using h + have hnext : dist q.1 (γ s') = ε := by + change dist (sprayFlow s.1 z).1 _ = _ + rw [hzflow,hγ.dist_eq,Subtype.dist_eq,Real.dist_eq] + change |s.1-(s.1+ε)| = ε + rw [show s.1-(s.1+ε) = -ε by ring,abs_neg,abs_of_pos hε] + have hlong : dist (sprayFlow (-ε) q).1 (γ s') = 2*ε := by + apply le_antisymm + · exact (dist_triangle _ q.1 _).trans (by rw [hpre,hnext]; linarith) + · have h := dist_triangle x (sprayFlow (-ε) q).1 (γ s') + rw [hd,hqback] at h + have hpref := sprayFlow_minimizing_prefix z (s := s.1-ε) (by linarith) (by linarith) hzmin + rw [hzn,mul_one] at hpref + change dist x (sprayFlow (s.1-ε) z).1 = s.1-ε at hpref + rw [hpref] at h + change s.1+ε ≤ _ at h + rw [hqback] + linarith + have hext := Hext q hzflow hqn ε hε hεη (γ s') hpre hnext hlong + have hznext : (sprayFlow (s.1+ε) z).1 = γ s' := by + rw [add_comm,sprayFlow_add]; exact hext + have hs' : s' ∈ U := by + refine ⟨(s.1+ε) • z.2,?_,?_⟩ + · change dist x (riemannianExp x ((s.1+ε) • z.2)) = ‖(s.1+ε) • z.2‖ + rw [riemannianExp_smul,hznext,hd,norm_smul,Real.norm_eq_abs,abs_of_pos (by linarith : 0 < s.1+ε),hzn,mul_one] + · rw [riemannianExp_smul]; exact hznext + have hh := hsmax hs' + change s.1+ε ≤ s.1 at hh + linarith + obtain ⟨p,hp,he⟩ := hs + refine ⟨p,hp,he.trans ?_⟩ + have hsEq : s = ⟨dist x y,⟨dist_nonneg,le_rfl⟩⟩ := Subtype.ext hsD + rw [hsEq,hγD] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/NoCorner.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/NoCorner.lean new file mode 100644 index 0000000000000000000000000000000000000000..7227faf2ede627f86eda703145452c4c707e44e0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/NoCorner.lean @@ -0,0 +1,205 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayDistanceBound +import OAI.Analysis.BiholderTransport.Calculus.LocalCostGradient +import OAI.Analysis.BiholderTransport.Convexity.Fermat + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma cost_gradients_opposite {p y b : M} + (htri : dist p b = dist p y + dist b y) (heq : dist p y = dist b y) + (u v : TangentSpace 𝓘(ℝ,E) y) + (hp : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun w => dist p w^2/2) y (innerSL ℝ u)) + (hb : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun w => dist b w^2/2) y (innerSL ℝ v)) : + u + v = 0 := by + have hmin : IsLocalMin (fun w => dist p w^2/2 + dist b w^2/2) y := by + apply Filter.Eventually.of_forall + intro w + have h := dist_triangle p w b + rw [htri,dist_comm w b] at h + have h' : (dist p y+dist b y)^2 ≤ (dist p w+dist b w)^2 := + pow_le_pow_left₀ (add_nonneg dist_nonneg dist_nonneg) h 2 + nlinarith [sq_nonneg (dist p w-dist b w)] + have hzero := isLocalMin_hasMFDerivAt_eq_zero hmin (hp.add hb) + have hval := congrArg (fun L : TangentSpace 𝓘(ℝ,E) y →L[ℝ] ℝ => L (u+v)) hzero + have hsq : ‖u+v‖^2 = 0 := by + simpa only [_root_.add_apply,_root_.zero_apply, + innerSL_apply_apply,←inner_add_left,real_inner_self_eq_norm_sq] using hval + exact norm_eq_zero.mp (sq_eq_zero_iff.mp hsq) + +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_minimizing_prefix (z : TangentBundle 𝓘(ℝ,E) M) {s t : ℝ} + (hs : 0 ≤ s) (hst : s ≤ t) + (hmin : dist z.1 (sprayFlow t z).1 = t * ‖z.2‖) : + dist z.1 (sprayFlow s z).1 = s * ‖z.2‖ := by + have h0 := dist_sprayFlow_le z 0 s + rw [sprayFlow_zero,zero_sub,abs_neg,abs_of_nonneg hs] at h0 + apply le_antisymm h0 + have h1 := dist_sprayFlow_le z s t + rw [abs_of_nonpos (sub_nonpos.mpr hst)] at h1 + have h2 := dist_triangle z.1 (sprayFlow s z).1 (sprayFlow t z).1 + rw [hmin] at h2 + nlinarith + +lemma sprayFlow_minimizer_gradient (z : TangentBundle 𝓘(ℝ,E) M) {t : ℝ} (ht : 0 < t) + (hmin : dist z.1 (sprayFlow t z).1 = t * ‖z.2‖) + (W : TangentSpace 𝓘(ℝ,E) (sprayFlow t z).1) + (hW : ‖W‖ = dist z.1 (sprayFlow t z).1) + (hD : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) + (fun x => dist z.1 x ^ 2 / 2) (sprayFlow t z).1 (innerSL ℝ W)) : + W = t • (sprayFlow t z).2 := by + have hcomp := hD.comp t (hasMFDerivAt_spray_projection ((sprayFlow_curve z).isMIntegralCurveAt t)) + have hd : HasDerivAt (fun s => dist z.1 (sprayFlow s z).1 ^ 2 / 2) + (inner ℝ W (sprayFlow t z).2) t := by + have hh : HasFDerivAt (fun s => dist z.1 (sprayFlow s z).1 ^ 2 / 2) + ((innerSL ℝ W).comp ((1 : ℝ →L[ℝ] ℝ).smulRight (sprayFlow t z).2)) t := by + convert! hcomp.hasFDerivAt + convert! hh.hasDerivAt using 1 + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.smulRight_apply, + one_apply_eq_self,one_smul,innerSL_apply_apply] + have hp : HasDerivAt (fun s : ℝ => s^2 * (‖z.2‖^2 / 2)) (t * ‖z.2‖^2) t := by + convert! ((hasDerivAt_id t).pow 2).mul_const (‖z.2‖^2/2) using 1 + simp only [id_eq] + ring + have heq : ∀ s ∈ Icc 0 t, + dist z.1 (sprayFlow s z).1 ^ 2 / 2 = s^2 * (‖z.2‖^2 / 2) := by + intro s hs + rw [sprayFlow_minimizing_prefix z hs.1 hs.2 hmin,mul_pow] + ring + have hdin : HasDerivWithinAt (fun s => dist z.1 (sprayFlow s z).1 ^ 2 / 2) + (t * ‖z.2‖^2) (Icc 0 t) t := + hp.hasDerivWithinAt.congr_of_mem heq ⟨ht.le,le_rfl⟩ + have hi : inner ℝ W (sprayFlow t z).2 = t*‖z.2‖^2 := by + exact (hd.hasDerivWithinAt.derivWithin (uniqueDiffOn_Icc ht t ⟨ht.le,le_rfl⟩)).symm.trans + (hdin.derivWithin (uniqueDiffOn_Icc ht t ⟨ht.le,le_rfl⟩)) + have hn := norm_sub_sq_real W (t • (sprayFlow t z).2) + rw [norm_smul,Real.norm_eq_abs,abs_of_pos ht,sprayFlow_speed,real_inner_smul_right,hi,hW,hmin] at hn + have hzero : ‖W - t • (sprayFlow t z).2‖ = 0 := by nlinarith [sq_nonneg ‖W - t • (sprayFlow t z).2‖] + exact sub_eq_zero.mp (norm_eq_zero.mp hzero) + +lemma exists_spray_local_extension (a : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ z : TangentBundle 𝓘(ℝ,E) M, z.1 = a → ‖z.2‖ = 1 → + ∀ ε : ℝ, 0 < ε → ε < δ → ∀ b : M, + dist (sprayFlow (-ε) z).1 z.1 = ε → dist z.1 b = ε → + dist (sprayFlow (-ε) z).1 b = 2*ε → (sprayFlow ε z).1 = b := by + obtain ⟨δ,hδ,H⟩ := exists_local_cost_gradient (E := E) a + refine ⟨δ,hδ,?_⟩ + intro z hza hzn ε hε hεδ b hmin hzb hpb + have hzball : z.1 ∈ Metric.ball a δ := by rw [hza]; exact Metric.mem_ball_self hδ + have hpball : (sprayFlow (-ε) z).1 ∈ Metric.ball a δ := by + rw [←hza,Metric.mem_ball,hmin]; exact hεδ + have hbball : b ∈ Metric.ball a δ := by + rw [←hza,Metric.mem_ball,dist_comm,hzb]; exact hεδ + obtain ⟨q,hqy,hqn,_,hDq⟩ := H _ hpball _ hzball + rcases q with ⟨y,u⟩ + change y=z.1 at hqy + subst y + obtain ⟨r,hry,hrn,hrback,hDr⟩ := H b hbball _ hzball + rcases r with ⟨y,v⟩ + change y=z.1 at hry + subst y + have hflow : sprayFlow ε (sprayFlow (-ε) z) = z := by + rw [←sprayFlow_add,add_neg_cancel,sprayFlow_zero] + have hg := sprayFlow_minimizer_gradient (sprayFlow (-ε) z) hε + (show dist (sprayFlow (-ε) z).1 (sprayFlow ε (sprayFlow (-ε) z)).1 = + ε * ‖(sprayFlow (-ε) z).2‖ by rw [hflow,sprayFlow_speed,hzn,mul_one]; exact hmin) + rw [hflow] at hg + have hu : u = ε • z.2 := hg u hqn hDq + have hop := cost_gradients_opposite + (show dist (sprayFlow (-ε) z).1 b = dist (sprayFlow (-ε) z).1 z.1 + dist b z.1 by + rw [hpb,hmin,dist_comm b z.1,hzb]; ring) + (show dist (sprayFlow (-ε) z).1 z.1 = dist b z.1 by rw [hmin,dist_comm b z.1,hzb]) + u v hDq hDr + have hv : v = (-ε) • z.2 := by + rw [neg_smul,←hu] + exact eq_neg_of_add_eq_zero_right hop + have hr : (⟨z.1,v⟩ : TangentBundle 𝓘(ℝ,E) M) = tangentScale (-ε) z := by + rw [hv]; cases z; rfl + rw [hr,sprayFlow_scale,show (-ε)*(-1)=ε by ring] at hrback + exact hrback + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/NormalEndpointLog.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/NormalEndpointLog.lean new file mode 100644 index 0000000000000000000000000000000000000000..dd96afc6282849138cfc3c630390f960d97c4542 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/NormalEndpointLog.lean @@ -0,0 +1,127 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteNormalInjective (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def minimizingEndpointChartParameters (a c : M) (K L : Set M) : + Set (Model n×(Model n×Model n)) := + (fun z : TangentBundle 𝓘(ℝ,Model n) M => + ((extChartAt 𝓘(ℝ,Model n) a) z.1, + ((extChartAt 𝓘(ℝ,Model n) c) (riemannianExp z.1 z.2), + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) z).2))) '' + {z : TangentBundle 𝓘(ℝ,Model n) M | + z.2∈minimizingVectors z.1 ∧ z.1∈K ∧ riemannianExp z.1 z.2∈L} + +lemma isCompact_minimizingRays_between {K L : Set M} + (hK : IsCompact K) (hL : IsCompact L) : + IsCompact {z : TangentBundle 𝓘(ℝ,Model n) M | + z.2∈minimizingVectors z.1 ∧ z.1∈K ∧ riemannianExp z.1 z.2∈L} := by + exact (isCompact_total_minimizingVectors (n := n) (M := M)).inter_right + ((hK.isClosed.preimage (FiberBundle.continuous_proj _ _)).inter + (hL.isClosed.preimage contMDiff_riemannianExp.continuous)) + +lemma continuousOn_riemannianExp_chart (c : M) : + ContinuousOn (fun z : TangentBundle 𝓘(ℝ,Model n) M => + (extChartAt 𝓘(ℝ,Model n) c) (riemannianExp z.1 z.2)) + {z | riemannianExp z.1 z.2∈(extChartAt 𝓘(ℝ,Model n) c).source} := + (continuousOn_extChartAt c).comp contMDiff_riemannianExp.continuous.continuousOn + (fun _ hz => hz) + +lemma continuousOn_endpointChartParameters {a c : M} {K L : Set M} + (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hLs : L⊆(extChartAt 𝓘(ℝ,Model n) c).source) : + ContinuousOn (fun z : TangentBundle 𝓘(ℝ,Model n) M => + ((extChartAt 𝓘(ℝ,Model n) a) z.1, + ((extChartAt 𝓘(ℝ,Model n) c) (riemannianExp z.1 z.2), + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) z).2))) + {z : TangentBundle 𝓘(ℝ,Model n) M | + z.2∈minimizingVectors z.1 ∧ z.1∈K ∧ riemannianExp z.1 z.2∈L} := by + let S := {z : TangentBundle 𝓘(ℝ,Model n) M | + z.2∈minimizingVectors z.1 ∧ z.1∈K ∧ riemannianExp z.1 z.2∈L} + have hX : ContinuousOn (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)) S := + (continuousOn_extChartAt _).mono + (fun z hz => (tangent_chart_source_iff _ z).mpr (hKs hz.2.1)) + have hY : ContinuousOn (fun z : TangentBundle 𝓘(ℝ,Model n) M => + (extChartAt 𝓘(ℝ,Model n) c) (riemannianExp z.1 z.2)) S := + (continuousOn_riemannianExp_chart c).mono (fun z hz => hLs hz.2.2) + have H := hX.fst.prodMk (hY.prodMk hX.snd) + convert H using 1 + funext z + rw [tangent_chart_apply] + +lemma isCompact_minimizingEndpointChartParameters {a c : M} {K L : Set M} + (hK : IsCompact K) (hL : IsCompact L) + (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hLs : L⊆(extChartAt 𝓘(ℝ,Model n) c).source) : + IsCompact (minimizingEndpointChartParameters (n := n) a c K L) := + (isCompact_minimizingRays_between hK hL).image_of_continuousOn + (continuousOn_endpointChartParameters hKs hLs) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] in +lemma tangent_symmL_trivialization {a x : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (p : TangentSpace 𝓘(ℝ,Model n) x) : + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p)=p := + Trivialization.symmL_continuousLinearMapAt _ + (by simpa only [TangentBundle.trivializationAt_baseSet,extChartAt_source] using hx) p + +lemma trivialization_mem_minimizingEndpointChartParameters {a c x : M} {K L : Set M} + (hx : x∈K) (hxa : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + (hy : riemannianExp x p∈L) : + ((extChartAt 𝓘(ℝ,Model n) a) x, + ((extChartAt 𝓘(ℝ,Model n) c) (riemannianExp x p), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p))∈ + minimizingEndpointChartParameters a c K L := by + refine ⟨⟨x,p⟩,⟨hp,hx,hy⟩,?_⟩ + simp only [tangent_chart_trivialization hxa] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/OriginalMass.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/OriginalMass.lean new file mode 100644 index 0000000000000000000000000000000000000000..32975f7a7cbafd241f3a30647054961ab47977cd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/OriginalMass.lean @@ -0,0 +1,131 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.RadialNull +import OAI.Analysis.BiholderTransport.Volume.MeasureContacts +import OAI.Analysis.BiholderTransport.Duality.AEDual +import OAI.Analysis.BiholderTransport.Volume.AESelection +import OAI.Analysis.BiholderTransport.Contact.ContactImage + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Metric Manifold Bundle +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section OriginalMass +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma minimizing_dualPair_selection_pushforward {lam cap : ℝ} (hlam : 0 hx.unique hy (contactSelection_mem v.continuous x)⟩ + · simpa only [heq] using hmin + +lemma minimizing_dualPair_contact_mass {lam cap : ℝ} (hlam : 0 by rw [contactGap_swap]; exact hab y x) + simpa only [dualObjective,add_comm] using H + have hp := minimizing_dualPair_selection_pushforward hlam h1 h0 + ⟨huv.2,huv.1⟩ hrev + have habs : densityMeasure (metricVolume n) rho1 ≪ metricVolume n := + withDensity_absolutelyContinuous (metricVolume (M := M) n) _ + have hc : ∀ y,contactGap u v (contactSelection u.continuous y) y=0 := by + intro y + rw [contactGap_swap,huv.2] + exact contactSelection_mem u.continuous y + have hs : ∀ᵐ y ∂densityMeasure (metricVolume n) rho1, + ∀ x,contactGap u v x y=0 → x=contactSelection u.continuous y := by + filter_upwards [habs.ae_le (cTransform_ae_unique_contact (n := n) u.continuous)] with y hy + intro x hx + rw [contactGap_swap,huv.2] at hx + exact hy.unique hx (contactSelection_mem u.continuous y) + exact (contactImage_measure hc hs + ((contactSelection_aemeasurable (n := n) u.continuous).mono_ac habs) hp hA).2 + +lemma minimizing_dualPair_contact_volume {lam cap : ℝ} (hlam : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma lipschitz_spray_projection (z : TangentBundle 𝓘(ℝ,Model n) M) : + LipschitzWith ‖z.2‖₊ (fun t => (sprayFlow t z).1) := by + rw [lipschitzWith_iff_dist_le_mul] + intro s t + simpa only [Real.dist_eq,mul_comm,coe_nnnorm] using dist_sprayFlow_le z s t + +lemma cTransform_ray_lipschitz [Nonempty M] {v : M → ℝ} (hv : Continuous v) + (z : TangentBundle 𝓘(ℝ,Model n) M) : + ∃ L, LipschitzWith L (fun t => cTransform v (sprayFlow t z).1) := by + let C : ℝ≥0 := ⟨Metric.diam (univ:Set M),Metric.diam_nonneg⟩ + have hC : ∀ x y : M,dist x y ≤ C := fun x y => + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + exact ⟨C*‖z.2‖₊,(cTransform_lipschitz hv hC).comp (lipschitz_spray_projection z)⟩ + +lemma active_norm_deficit_deriv {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} {t d D : ℝ} + (ht : 0 ≤ t) (ht1 : t ≤ 1/2) (hD : 0 ≤ D) + (hd : HasDerivAt (fun s => cTransform v (sprayFlow s z).1) d t) + (hgap : ∀ p∈activeLogs (n := n) v (sprayFlow t z).1, + ‖p‖^2 ≤ (1-t)^2*‖z.2‖^2-D) : + d-(1-t)*‖z.2‖^2 ≤ -D/2 := by + obtain ⟨p,hp⟩ := nonempty_activeLogs (n := n) hv (sprayFlow t z).1 + have H := spray_deriv_le_active_norm hv hd hp + have Hg := norm_deficit_advance (norm_nonneg p) (norm_nonneg z.2) ht ht1 hD (hgap p hp) + linarith only [H,Hg] + +lemma cost_norm_surplus_deriv {z : TangentBundle 𝓘(ℝ,Model n) M} {t d D : ℝ} {y : M} + (ht : 0 ≤ t) (ht1 : t ≤ 1/2) (hD : 0 ≤ D) + (hd : HasDerivAt (fun s => -cost (sprayFlow s z).1 y) d t) + (hgap : dist (sprayFlow t z).1 y^2 ≤ (1-t)^2*‖z.2‖^2+D) : + d-(1-t)*‖z.2‖^2 ≤ 2*D := by + have H := spray_neg_cost_deriv_le hd + have Hg := norm_surplus_advance dist_nonneg (norm_nonneg z.2) ht ht1 hD hgap + linarith only [H,Hg] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/ReverseSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/ReverseSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..27542625d33130ec9f0f10a5268857d14807f1b2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/ReverseSpectrum.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.SpectralDeterminants + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ReverseSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma sprayFlow_reverseRay (z : TangentBundle 𝓘(ℝ,Model n) M) (t : ℝ) : + sprayFlow t (reverseRay z)=tangentScale (-1) (sprayFlow (1-t) z) := by + rw [reverseRay,sprayFlow_scale,←sprayFlow_add] + congr 2 + ring + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma middleHessian_reverse_half (z : TangentBundle 𝓘(ℝ,Model n) M) : + HEq (middleHessian (reverseRay z) (1/2) 1) (middleHessian z (1/2) 1) := by + unfold middleHessian + rw [sprayFlow_reverseRay] + rw [show (1:ℝ)-1/2=1/2 by norm_num] + change HEq + ((1/2:ℝ)⁻¹ • normalHessian (sprayFlow (1/2) z).1 + ((-(1/2:ℝ)) • ((-1:ℝ) • (sprayFlow (1/2) z).2))+ + (1/2:ℝ)⁻¹ • normalHessian (sprayFlow (1/2) z).1 + ((1/2:ℝ) • ((-1:ℝ) • (sprayFlow (1/2) z).2))) + ((1/2:ℝ)⁻¹ • normalHessian (sprayFlow (1/2) z).1 + ((-(1/2:ℝ)) • (sprayFlow (1/2) z).2)+ + (1/2:ℝ)⁻¹ • normalHessian (sprayFlow (1/2) z).1 + ((1/2:ℝ) • (sprayFlow (1/2) z).2)) + apply heq_of_eq + simp only [smul_smul] + norm_num only + ext v w + simp only [add_apply,smul_apply,smul_eq_mul] + ring + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma middleSingularValue_reverse_half (z : TangentBundle 𝓘(ℝ,Model n) M) (i : ℕ) : + middleSingularValue (reverseRay z) (1/2) 1 i=middleSingularValue z (1/2) 1 i := by + have hb : (sprayFlow (1/2:ℝ) (reverseRay z)).1=(sprayFlow (1/2:ℝ) z).1 := by + rw [sprayFlow_reverseRay] + norm_num only + rfl + exact intrinsicBilinearSingular_heq hb (middleHessian_reverse_half z) i + +lemma uniform_reverse_singular_comparison : + ∃ C : ℝ, 0 < C ∧ ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2∈minimizingVectors z.1 → ∀ i : Fin (Module.finrank ℝ (Model n)), + (endpointExpDifferential (reverseRay z).1 (reverseRay z).2).toLinearMap.singularValues i ≤ + C*(endpointExpDifferential z.1 z.2).toLinearMap.singularValues i := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_endpoint_middle_singular_comparison (n := n) (M := M) + refine ⟨C*c,mul_pos hC hc,?_⟩ + intro z hz i + have h0 := (H z.1 z.2 hz (1/2) (by constructor <;> norm_num) i).2 + have h1 := (H (reverseRay z).1 (reverseRay z).2 (reverseRay_minimizing hz) + (1/2) (by constructor <;> norm_num) i).1 + change _ ≤ C*middleSingularValue (reverseRay z) (1/2) 1 i at h1 + change middleSingularValue z (1/2) 1 i ≤ _ at h0 + rw [middleSingularValue_reverse_half] at h1 + exact h1.trans ((mul_le_mul_of_nonneg_left h0 hC.le).trans_eq (mul_assoc _ _ _).symm) + +lemma uniform_reverse_expJacobian_comparison : + ∃ C : ℝ, 0 < C ∧ ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + z.2∈minimizingVectors z.1 → expJacobian (reverseRay z).1 (reverseRay z).2 ≤ + C*expJacobian z.1 z.2 := by + obtain ⟨C,hC,H⟩ := uniform_reverse_singular_comparison (n := n) (M := M) + refine ⟨C ^ Module.finrank ℝ (Model n),pow_pos hC _,?_⟩ + intro z hz + rw [expJacobian_eq_prod_singularValues,expJacobian_eq_prod_singularValues] + have HH := Finset.prod_le_prod₀ (s := (Finset.univ : Finset (Fin (Module.finrank ℝ (Model n))))) + (fun i _ => (endpointExpDifferential (reverseRay z).1 (reverseRay z).2).toLinearMap.singularValues_nonneg i) + (fun i _ => H z hz i) + simpa only [Finset.prod_mul_distrib,Finset.prod_const,Finset.card_univ,Fintype.card_fin] using HH +end ReverseSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/ShortGradient.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/ShortGradient.lean new file mode 100644 index 0000000000000000000000000000000000000000..21b134fbf968f3e907343854ac0036cca42f9929 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/ShortGradient.lean @@ -0,0 +1,217 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.NoCorner +import OAI.Analysis.BiholderTransport.Geodesics.IntegratedGauss + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_local_spray_cost_gradient (a : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ z : TangentBundle 𝓘(ℝ,E) M, ∀ t : ℝ, 0 < t → + z.1 ∈ Metric.ball a δ → (sprayFlow t z).1 ∈ Metric.ball a δ → + dist z.1 (sprayFlow t z).1 = t*‖z.2‖ → + HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun y => dist z.1 y^2/2) + (sprayFlow t z).1 (innerSL ℝ (t • (sprayFlow t z).2)) := by + obtain ⟨δ,hδ,H⟩ := exists_local_cost_gradient (E := E) a + refine ⟨δ,hδ,?_⟩ + intro z t ht hz hy hmin + obtain ⟨⟨b,w⟩,hb,hn,_,hD⟩ := H z.1 hz (sprayFlow t z).1 hy + dsimp only at hb + subst b + have hw := sprayFlow_minimizer_gradient z ht hmin w hn hD + rwa [hw] at hD + +omit [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma sprayFlow_reverse (z : TangentBundle 𝓘(ℝ,E) M) (t : ℝ) : + sprayFlow t (tangentScale (-1) (sprayFlow t z)) = tangentScale (-1) z := by + rw [sprayFlow_scale,neg_one_mul,←sprayFlow_add,neg_add_cancel,sprayFlow_zero] + +lemma exists_local_spray_cost_start_gradient (a : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ z : TangentBundle 𝓘(ℝ,E) M, ∀ t : ℝ, 0 < t → + z.1 ∈ Metric.ball a δ → (sprayFlow t z).1 ∈ Metric.ball a δ → + dist z.1 (sprayFlow t z).1 = t*‖z.2‖ → + HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun y => dist y (sprayFlow t z).1^2/2) + z.1 (innerSL ℝ ((-t) • z.2)) := by + obtain ⟨δ,hδ,H⟩ := exists_local_spray_cost_gradient (E := E) a + refine ⟨δ,hδ,?_⟩ + intro z t ht hz hy hmin + let w := tangentScale (-1) (sprayFlow t z) + have hw : sprayFlow t w = tangentScale (-1) z := sprayFlow_reverse z t + have hb : (sprayFlow t w).1 ∈ Metric.ball a δ := by rw [hw]; exact hz + have hm : dist w.1 (sprayFlow t w).1 = t*‖w.2‖ := by + rw [hw] + change dist (sprayFlow t z).1 z.1 = t*‖(-1:ℝ) • (sprayFlow t z).2‖ + rw [neg_one_smul,norm_neg,sprayFlow_speed,dist_comm,hmin] + have hd := H w t ht hy hb hm + rw [hw] at hd + change HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun y => dist (sprayFlow t z).1 y^2/2) + z.1 (innerSL ℝ (t • ((-1:ℝ) • z.2))) at hd + rw [smul_smul,mul_neg_one] at hd + have hf : (fun y => dist y (sprayFlow t z).1^2/2) = + (fun y => dist (sprayFlow t z).1 y^2/2) := by + funext y; rw [dist_comm] + rw [hf] + exact hd + +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [FiniteDimensional ℝ E] [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma contMDiff_fiber_embedding (x : M) : + ContMDiff 𝓘(ℝ,TangentSpace 𝓘(ℝ,E) x) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (fun v : TangentSpace 𝓘(ℝ,E) x => (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)) := by + intro v + rw [Bundle.contMDiffAt_totalSpace] + refine ⟨contMDiffAt_const,?_⟩ + let e := trivializationAt E (fun y : M => TangentSpace 𝓘(ℝ,E) y) x + let L : TangentSpace 𝓘(ℝ,E) x →L[ℝ] E := e.continuousLinearMapAt ℝ x + have heq : (fun w : TangentSpace 𝓘(ℝ,E) x => (e (⟨x,w⟩ : TangentBundle 𝓘(ℝ,E) M)).2) = L := by + funext w + exact (e.continuousLinearMapAt_apply_of_mem ℝ (mem_baseSet_trivializationAt E _ x) _).symm + change ContMDiffAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,E) x) 𝓘(ℝ,E) ∞ + (fun w => (e ⟨x,w⟩).2) v + rw [heq] + exact L.contDiff.contDiffAt.contMDiffAt + +omit [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma contMDiff_spray_fiber (x : M) (t : ℝ) : + ContMDiff 𝓘(ℝ,TangentSpace 𝓘(ℝ,E) x) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (fun v : TangentSpace 𝓘(ℝ,E) x => sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)) := + contMDiff_sprayFlow.comp (contMDiff_const.prodMk (contMDiff_fiber_embedding x)) + +omit [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma spray_action_line_stationary (x : M) (p w : TangentSpace 𝓘(ℝ,E) x) + (L ε : ℝ) (hε : ε ≠ 0) (y : M) + (hD : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun b => dist b y^2/2) + (sprayFlow L (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 + (innerSL ℝ ((-ε) • (sprayFlow L (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).2))) : + HasDerivAt (fun s : ℝ => L*‖p+s • w‖^2/2 + + (dist (sprayFlow L (⟨x,p+s • w⟩ : TangentBundle 𝓘(ℝ,E) M)).1 y^2/2)/ε) 0 0 := by + let ν : ℝ → TangentBundle 𝓘(ℝ,E) M := fun s => sprayFlow L ⟨x,p+s • w⟩ + let ψ : ℝ → M := fun s => (ν s).1 + have hψ : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ ψ := + (Bundle.contMDiff_proj (fun b : M => TangentSpace 𝓘(ℝ,E) b)).comp + (contMDiff_sprayFlow.comp (contMDiff_const.prodMk (contMDiff_fiber_line x p w))) + have hν0 : ν 0 = sprayFlow L (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M) := by simp [ν] + have hD₀ : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) (fun b => dist b y^2/2) (ν 0).1 + (innerSL ℝ ((-ε) • (ν 0).2)) := by rw [hν0]; exact hD + have hDc := hD₀.comp 0 (hψ.mdifferentiable (by simp) 0).hasMFDerivAt + let J := mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ψ 0 (1:ℝ) + have hd : HasDerivAt (fun s => dist (ψ s) y^2/2) + ((-ε) * inner ℝ (ν 0).2 J) 0 := by + have hf : HasFDerivAt (fun s => dist (ψ s) y^2/2) + ((innerSL ℝ ((-ε) • (ν 0).2)).comp (mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ψ 0)) 0 := by + convert! hDc.hasFDerivAt using 1 + convert! hf.hasDerivAt using 1 + change (-ε) * inner ℝ (ν 0).2 J = inner ℝ ((-ε) • (ν 0).2) J + rw [real_inner_smul_left] + have hg : inner ℝ (ν 0).2 J = L*inner ℝ p w := by + have he : HasDerivAt (fun s : ℝ => ‖p+s • w‖^2) (2*inner ℝ p w) 0 := by + convert! ((hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const w)).norm_sq using 1 + simp + have H := spray_variation_pairing_affine (ν := fun s => (⟨x,p+s • w⟩ : TangentBundle 𝓘(ℝ,E) M)) + (contMDiff_fiber_line x p w) he L + convert! H using 1 + simp + have hn := ((hasDerivAt_const (0:ℝ) p).add ((hasDerivAt_id (0:ℝ)).smul_const w)).norm_sq + have he : HasDerivAt (fun s : ℝ => L*‖p+s • w‖^2/2) (L*inner ℝ p w) 0 := by + convert! (hn.const_mul L).div_const 2 using 1 + simp + ring + have H := he.add (hd.div_const ε) + apply H.congr_deriv + rw [hg] + field_simp + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SplitMinimizingAction.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SplitMinimizingAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..fbd7c683d0ec3d5ca5d31f1d70dfa18eafc40eea --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SplitMinimizingAction.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingSubinterval +import OAI.Analysis.BiholderTransport.CostGeometry.DividedAction + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma minimizing_split_upper_support {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) {s : ℝ} (hs : 0 TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma spray_split_action_contact (x : M) (p : TangentSpace 𝓘(ℝ,E) x) + {L ε : ℝ} (hL : 0 TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma coordinate_spray_fiber_immersion (x : M) (p : TangentSpace 𝓘(ℝ,E) x) (t : ℝ) : + Function.Injective (fderiv ℝ + (fun v : TangentSpace 𝓘(ℝ,E) x => + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (sprayFlow t ⟨x,p⟩) (sprayFlow t ⟨x,v⟩)) p) := by + let z : TangentBundle 𝓘(ℝ,E) M := ⟨x,p⟩ + let a := sprayFlow t z + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a + let χ₀ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) z + let Φ : TangentSpace 𝓘(ℝ,E) x → E×E := fun v => χ (sprayFlow t ⟨x,v⟩) + let K : E×E → E×E := fun y => χ₀ (sprayFlow (-t) (χ.symm y)) + let R : E×E → E := fun y => (K y).2 + have hΦp : Φ p = χ a := rfl + have hχinv : χ.symm (Φ p) = a := χ.left_inv (mem_extChartAt_source a) + have hback : sprayFlow (-t) (χ.symm (Φ p)) = z := by + rw [hχinv] + exact (sprayFlow_add (-t) t z).symm.trans (by rw [neg_add_cancel,sprayFlow_zero]) + have hΦ : ContDiffAt ℝ ∞ Φ p := + ((show ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E×E) ∞ χ a from + contMDiffAt_extChartAt).comp p (contMDiff_spray_fiber x t p)).contDiffAt + have hχ : ContMDiffAt 𝓘(ℝ,E×E) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ χ.symm (Φ p) := + (contMDiffOn_extChartAt_symm a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds (χ.map_source (mem_extChartAt_source a))) + have hf : ContMDiff (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (sprayFlow (-t) : TangentBundle 𝓘(ℝ,E) M → TangentBundle 𝓘(ℝ,E) M) := + contMDiff_sprayFlow.comp (contMDiff_const.prodMk contMDiff_id) + have hχ₀ : ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E×E) ∞ χ₀ + (sprayFlow (-t) (χ.symm (Φ p))) := by + rw [hback]; exact contMDiffAt_extChartAt + have hK : ContDiffAt ℝ ∞ K (Φ p) := + (hχ₀.comp (Φ p) ((hf (χ.symm (Φ p))).comp (Φ p) hχ)).contDiffAt + have hR : DifferentiableAt ℝ R (Φ p) := hK.snd.differentiableAt (by simp) + let e := trivializationAt E (fun b : M => TangentSpace 𝓘(ℝ,E) b) x + let L : TangentSpace 𝓘(ℝ,E) x ≃L[ℝ] E := + e.continuousLinearEquivAt ℝ x (mem_baseSet_trivializationAt E _ x) + have hnear : ∀ᶠ v : TangentSpace 𝓘(ℝ,E) x in 𝓝 p, sprayFlow t ⟨x,v⟩ ∈ χ.source := + (contMDiff_spray_fiber x t p).continuousAt.preimage_mem_nhds + ((isOpen_extChartAt_source a).mem_nhds (mem_extChartAt_source a)) + have heq : (fun v => R (Φ v)) =ᶠ[𝓝 p] L := by + filter_upwards [hnear] with v hv + dsimp [R,K,Φ] + rw [χ.left_inv hv,←sprayFlow_add,neg_add_cancel,sprayFlow_zero] + rfl + have hd := (hR.hasFDerivAt.comp p (hΦ.differentiableAt (by simp)).hasFDerivAt).fderiv + change fderiv ℝ (fun v => R (Φ v)) p = _ at hd + rw [heq.fderiv_eq,L.hasFDerivAt.fderiv] at hd + intro u v huv + change fderiv ℝ Φ p u = fderiv ℝ Φ p v at huv + apply L.injective + have hh := congrArg (fun A : TangentSpace 𝓘(ℝ,E) x →L[ℝ] E => A u-A v) hd + simp only [ContinuousLinearMap.comp_apply,huv,sub_self,sub_eq_zero] at hh + convert! hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayDistanceBound.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayDistanceBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..3b46d18165a553491e5146495e2c72c42bc9c11e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayDistanceBound.lean @@ -0,0 +1,214 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.MinimizingVectors +import OAI.Analysis.BiholderTransport.Geodesics.MetricGeodesicLift + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma sprayFlow_pathELength (z : TangentBundle 𝓘(ℝ,E) M) (s t : ℝ) : + pathELength 𝓘(ℝ,E) (fun u => (sprayFlow u z).1) s t = + ENNReal.ofReal ((t-s)*‖z.2‖) := by + rw [pathELength_eq_lintegral_mfderiv_Icc] + calc + _ = ∫⁻ _ in Icc s t, ENNReal.ofReal ‖z.2‖ := by + apply setLIntegral_congr_fun measurableSet_Icc + intro u _ + have H := congrArg (fun v : TangentSpace 𝓘(ℝ,E) (sprayFlow u z).1 => ENNReal.ofReal ‖v‖) + (spray_velocity_eq_mfderiv ((sprayFlow_curve z).isMIntegralCurveAt u)) + have H' := H.trans (congrArg ENNReal.ofReal (sprayFlow_speed u z)) + convert! H' using 1 + exact (ofReal_norm _).symm + _ = _ := by + rw [setLIntegral_const,Real.volume_Icc,ENNReal.ofReal_mul' (norm_nonneg _),mul_comm] + +lemma dist_sprayFlow_le (z : TangentBundle 𝓘(ℝ,E) M) (s t : ℝ) : + dist (sprayFlow s z).1 (sprayFlow t z).1 ≤ |s-t| * ‖z.2‖ := by + have hsm : ContMDiff 𝓘(ℝ,ℝ) 𝓘(ℝ,E) ∞ (fun u => (sprayFlow u z).1) := + (Bundle.contMDiff_proj (fun x : M => TangentSpace 𝓘(ℝ,E) x)).comp + (contMDiff_sprayFlow.comp (contMDiff_id.prodMk contMDiff_const)) + have H : ∀ s t : ℝ, s ≤ t → dist (sprayFlow s z).1 (sprayFlow t z).1 ≤ (t-s)*‖z.2‖ := by + intro s t hst + have he := riemannianEDist_le_pathELength (I := 𝓘(ℝ,E)) + (hsm.of_le (by simp)).contMDiffOn rfl rfl hst + rw [←IsRiemannianManifold.out,sprayFlow_pathELength,edist_dist] at he + exact (ENNReal.ofReal_le_ofReal_iff (mul_nonneg (sub_nonneg.mpr hst) (norm_nonneg _))).mp he + rcases le_total s t with hst | hts + · rw [abs_of_nonpos (sub_nonpos.mpr hst)] + simpa only [neg_sub] using H s t hst + · rw [dist_comm,abs_of_nonneg (sub_nonneg.mpr hts)] + exact H t s hts + +end + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma continuous_riemannianExp (x : M) : Continuous (riemannianExp (n := n) x) := + contMDiff_riemannianExp.continuous.comp (FiberBundle.continuous_totalSpaceMk _ _ x) + +lemma dist_riemannianExp_smul_le (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) (s t : ℝ) : + dist (riemannianExp x (s • v)) (riemannianExp x (t • v)) ≤ |s - t| * ‖v‖ := by + simp only [riemannianExp_smul] + exact dist_sprayFlow_le ⟨x,v⟩ s t + +lemma dist_riemannianExp_le (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + dist x (riemannianExp x v) ≤ ‖v‖ := by + have H := dist_sprayFlow_le (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M) 0 1 + simpa only [sprayFlow_zero,riemannianExp_eq_sprayFlow,zero_sub,abs_neg,abs_one,one_mul] using H + +lemma minimizingVectors_smul {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) {t : ℝ} (ht0 : 0 ≤ t) (ht1 : t ≤ 1) : + t • p ∈ minimizingVectors x := by + change dist x (riemannianExp x (t • p)) = ‖t • p‖ + apply le_antisymm (dist_riemannianExp_le _ _) + have H := dist_triangle x (riemannianExp x (t • p)) (riemannianExp x p) + have Hb := dist_riemannianExp_smul_le x p t 1 + rw [one_smul,abs_of_nonpos (sub_nonpos.mpr ht1)] at Hb + change dist x (riemannianExp x p) = ‖p‖ at hp + rw [hp] at H + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg ht0] + nlinarith + +lemma injectivityDomain_subset_minimizingVectors (x : M) : + injectivityDomain (n := n) x ⊆ minimizingVectors x := by + rintro p ⟨a,ha,he⟩ + have ha0 : 0 < a := lt_trans zero_lt_one ha + have hmin : a • p ∈ minimizingVectors x := by + change dist x (riemannianExp x (a • p)) = ‖a • p‖ + rw [he,norm_smul,Real.norm_eq_abs,abs_of_pos ha0] + have H := minimizingVectors_smul hmin (inv_nonneg.mpr ha0.le) + (inv_le_one_of_one_le₀ ha.le) + simpa only [smul_smul,inv_mul_cancel₀ ha0.ne',one_smul] using H + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma contracted_minimizer_mem_injectivityDomain {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p ∈ minimizingVectors x) + {t : ℝ} (ht0 : 0 < t) (ht1 : t < 1) : t • p ∈ injectivityDomain x := by + refine ⟨t⁻¹,(one_lt_inv₀ ht0).mpr ht1,?_⟩ + rw [smul_smul,inv_mul_cancel₀ ht0.ne',one_smul] + rw [hp,norm_smul,Real.norm_eq_abs,abs_of_pos ht0,←mul_assoc,inv_mul_cancel₀ ht0.ne',one_mul] + +lemma isClosed_minimizingVectors (x : M) : IsClosed (minimizingVectors (n := n) x) := + isClosed_eq (continuous_const.dist (continuous_riemannianExp x)) continuous_norm + +lemma isCompact_minimizingVectors (x : M) : IsCompact (minimizingVectors (n := n) x) := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + apply (isCompact_closedBall (0 : TangentSpace 𝓘(ℝ,Model n) x) (Metric.diam (univ : Set M))).of_isClosed_subset + (isClosed_minimizingVectors x) + intro p hp + rw [Metric.mem_closedBall,dist_zero_right,←hp] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ _) + +lemma closure_injectivityDomain (x : M) : + closure (injectivityDomain (n := n) x) = minimizingVectors x := by + apply subset_antisymm + · exact closure_minimal (injectivityDomain_subset_minimizingVectors x) (isClosed_minimizingVectors x) + · intro p hp + apply closure_mono (s := openSegment ℝ 0 p) ?_ (segment_subset_closure_openSegment (right_mem_segment ℝ 0 p)) + rintro q ⟨a,b,ha,hb,hab,rfl⟩ + rw [smul_zero,zero_add] + exact contracted_minimizer_mem_injectivityDomain hp hb (by linarith) + +lemma isCompact_total_minimizingVectors : + IsCompact {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ minimizingVectors z.1} := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + apply (isCompact_bundle_disk (F := Model n) + (E := fun x : M => TangentSpace 𝓘(ℝ,Model n) x) (Metric.diam (univ : Set M))).of_isClosed_subset + · exact isClosed_eq ((FiberBundle.continuous_proj _ _).dist contMDiff_riemannianExp.continuous) + continuous_bundle_norm + · intro z hz + change ‖z.2‖ ≤ _ + rw [←hz] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ _) (mem_univ _) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayEnergy.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..a3f30d4b6fd3cb59d75a5e8ef36711c4712d6ad6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayEnergy.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.GeodesicSpray + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma coordinate_spray_energy_symm (a : TangentBundle 𝓘(ℝ,E) M) (q : E × E) + (hq : q.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target) : + riemannianCoordinateMetric a.1 q.1 q.2 q.2 = + ‖((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm q).2‖ ^ 2 := by + rw [riemannianCoordinateMetric_apply] + have hbase : (extChartAt 𝓘(ℝ,E) a.1).symm q.1 ∈ + (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a.1).baseSet := by + simpa only [TangentBundle.trivializationAt_baseSet,← extChartAt_source 𝓘(ℝ,E)] using + (extChartAt 𝓘(ℝ,E) a.1).map_target hq + rw [Trivialization.symmL_apply _ hbase] + have he : (trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) a.1).symm + ((extChartAt 𝓘(ℝ,E) a.1).symm q.1) q.2 = + tangentCoordChange 𝓘(ℝ,E) a.1 ((extChartAt 𝓘(ℝ,E) a.1).symm q.1) + ((extChartAt 𝓘(ℝ,E) a.1).symm q.1) q.2 := + (tangentBundleCore 𝓘(ℝ,E) M).localTriv_symm_apply (i := achart E a.1) hbase q.2 + rw [he] + change inner ℝ ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm q).2 + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm q).2 = _ + exact real_inner_self_eq_norm_sq _ + +lemma coordinate_spray_energy (a z : TangentBundle 𝓘(ℝ,E) M) + (hz : z.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).source) : + riemannianCoordinateMetric a.1 + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z).1 + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z).2 + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z).2 = ‖z.2‖ ^ 2 := by + rw [coordinate_spray_energy_symm a _ ((extChartAt 𝓘(ℝ,E) a.1).map_source hz)] + rw [(extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).left_inv + ((tangent_chart_source_iff a z).mpr hz)] + +variable [FiniteDimensional ℝ E] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma spray_chart_hasDerivAt {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {t : ℝ} + (hγ : IsMIntegralCurveAt γ (geodesicSpray (E := E)) t) : + HasDerivAt (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) ∘ γ) + (coordinateGeodesicField (riemannianCoordinateMetric (γ t).1) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) (γ t))) t := by + have hd := Filter.Eventually.self_of_nhds hγ.eventually_hasDerivAt + rw [geodesicSpray_coordinates (γ t) (γ t) + (mem_extChartAt_source (I := 𝓘(ℝ,E)) (γ t).1)] at hd + exact hd + +lemma spray_coordinate_energy_hasDerivAt {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {t : ℝ} + (hγ : IsMIntegralCurveAt γ (geodesicSpray (E := E)) t) : + let q := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) ∘ γ + HasDerivAt (fun s => riemannianCoordinateMetric (γ t).1 (q s).1 (q s).2 (q s).2) 0 t := by + let q := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) ∘ γ + have hd := spray_chart_hasDerivAt hγ + have hqt : (q t).1 ∈ (extChartAt 𝓘(ℝ,E) (γ t).1).target := + (extChartAt 𝓘(ℝ,E) (γ t).1).map_source (mem_extChartAt_source (γ t).1) + have hg : DifferentiableAt ℝ (riemannianCoordinateMetric (γ t).1) (q t).1 := + ((contDiffOn_riemannianCoordinateMetric (γ t).1).contDiffAt + ((isOpen_extChartAt_target (γ t).1).mem_nhds hqt)).differentiableAt (by simp) + have hpos : HasDerivAt (fun s => (q s).1) (q t).2 t := + (ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt t hd + have hvel : HasDerivAt (fun s => (q s).2) + (-coordinateChristoffel (riemannianCoordinateMetric (γ t).1) (q t).1 (q t).2 (q t).2) t := + (ContinuousLinearMap.snd ℝ E E).hasFDerivAt.comp_hasDerivAt t hd + exact metric_speed_derivative (E := E) hg + (riemannianCoordinateMetric_isInvertible hqt) + (riemannianCoordinateMetric_symm _ _) hpos hvel + +lemma hasDerivAt_spray_energy {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {t : ℝ} + (hγ : IsMIntegralCurveAt γ (geodesicSpray (E := E)) t) : + HasDerivAt (fun s => ‖(γ s).2‖ ^ 2) 0 t := by + apply (spray_coordinate_energy_hasDerivAt hγ).congr_of_eventuallyEq + have hnear : ∀ᶠ s in 𝓝 t, (γ s).1 ∈ (extChartAt 𝓘(ℝ,E) (γ t).1).source := by + have h := hγ.continuousAt.preimage_mem_nhds + (extChartAt_source_mem_nhds (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t)) + filter_upwards [h] with s hs + exact (tangent_chart_source_iff (γ t) (γ s)).mp hs + filter_upwards [hnear] with s hs + exact (coordinate_spray_energy (γ t) (γ s) hs).symm + +lemma spray_speed_constant {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {a b s t : ℝ} + (hγ : IsMIntegralCurveOn γ (geodesicSpray (E := E)) (Ioo a b)) + (hs : s ∈ Ioo a b) (ht : t ∈ Ioo a b) : ‖(γ s).2‖ = ‖(γ t).2‖ := by + have hd (r : ℝ) (hr : r ∈ Ioo a b) := hasDerivAt_spray_energy + (hγ.isMIntegralCurveAt (isOpen_Ioo.mem_nhds hr)) + have he := isOpen_Ioo.is_const_of_deriv_eq_zero (convex_Ioo a b).isPreconnected + (fun r hr => (hd r hr).differentiableAt.differentiableWithinAt) + (fun r hr => (hd r hr).deriv) hs ht + nlinarith [norm_nonneg (γ s).2,norm_nonneg (γ t).2] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayMinimizerUnique.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayMinimizerUnique.lean new file mode 100644 index 0000000000000000000000000000000000000000..6b4df39d076692b0283df7ac82f1b8b16ba7a5b5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayMinimizerUnique.lean @@ -0,0 +1,227 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingSubinterval + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_minimizer_terminal_eq (z G : TangentBundle 𝓘(ℝ,E) M) + (hG : G.1 = (sprayFlow 1 z).1) + (hmin : dist z.1 (sprayFlow 1 z).1 = ‖z.2‖) + (hGn : ‖G.2‖ = dist z.1 G.1) + (hD : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) + (fun x => dist z.1 x^2/2) G.1 (innerSL ℝ G.2)) : sprayFlow 1 z = G := by + rcases G with ⟨b,W⟩ + change b = (sprayFlow 1 z).1 at hG + subst b + have hmin' : dist z.1 (sprayFlow 1 z).1 = 1 * ‖z.2‖ := by rw [one_mul]; exact hmin + have hh := sprayFlow_minimizer_gradient z zero_lt_one hmin' W hGn hD + rw [one_smul] at hh + rw [hh] + +lemma sprayFlow_minimizer_unique_of_gradient (z w G : TangentBundle 𝓘(ℝ,E) M) + (hbase : z.1=w.1) + (hGz : G.1=(sprayFlow 1 z).1) (hGw : G.1=(sprayFlow 1 w).1) + (hz : dist z.1 (sprayFlow 1 z).1 = ‖z.2‖) + (hw : dist w.1 (sprayFlow 1 w).1 = ‖w.2‖) + (hGn : ‖G.2‖ = dist z.1 G.1) + (hD : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) + (fun x => dist z.1 x^2/2) G.1 (innerSL ℝ G.2)) : z=w := by + have hez := sprayFlow_minimizer_terminal_eq z G hGz hz hGn hD + have hDw : HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) + (fun x => dist w.1 x^2/2) G.1 (innerSL ℝ G.2) := by rwa [←hbase] + have hnw : ‖G.2‖ = dist w.1 G.1 := by rw [←hbase]; exact hGn + have hew := sprayFlow_minimizer_terminal_eq w G hGw hw hnw hDw + have hh := congrArg (sprayFlow (-1)) (hez.trans hew.symm) + simpa only [←sprayFlow_add,neg_add_cancel,sprayFlow_zero] using hh + +lemma exists_local_spray_minimizer_unique (a : M) : + ∃ δ : ℝ, 0 < δ ∧ ∀ z w : TangentBundle 𝓘(ℝ,E) M, + z.1 ∈ Metric.ball a δ → (sprayFlow 1 z).1 ∈ Metric.ball a δ → + z.1=w.1 → (sprayFlow 1 z).1=(sprayFlow 1 w).1 → + dist z.1 (sprayFlow 1 z).1 = ‖z.2‖ → + dist w.1 (sprayFlow 1 w).1 = ‖w.2‖ → z=w := by + obtain ⟨δ,hδ,H⟩ := exists_local_cost_gradient (E := E) a + refine ⟨δ,hδ,?_⟩ + intro z w hz hf hbase hend hminz hminw + obtain ⟨G,hG,hGn,_,hD⟩ := H _ hz _ hf + apply sprayFlow_minimizer_unique_of_gradient z w G hbase hG (hG.trans hend) hminz hminw + · exact hGn.trans (congrArg (dist z.1) hG.symm) + · exact hD + +omit [FiniteDimensional ℝ E] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [CompactSpace M] [IsManifold 𝓘(ℝ,E) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma tangentScale_injective {c : ℝ} (hc : c ≠ 0) : + Function.Injective (tangentScale (M := M) (E := E) c) := by + have hinv : Function.LeftInverse (tangentScale (M := M) (E := E) c⁻¹) + (tangentScale c) := by + rintro ⟨base,velocity⟩ + dsimp only [tangentScale] + congr 1 + exact inv_smul_smul₀ hc velocity + exact hinv.injective + +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_unit_minimizer_unique (z w : TangentBundle 𝓘(ℝ,E) M) + (hbase : z.1=w.1) (hzn : ‖z.2‖=1) (hwn : ‖w.2‖=1) + {t T : ℝ} (ht : 0 ((q (s+c*w)).1,c • (q (s+c*w)).2)) + (coordinateGeodesicField g ((q (s+c*t)).1,c • (q (s+c*t)).2)) t := by + have hq₁ : HasDerivAt (fun w => (q w).1) (q (s+c*t)).2 (s+c*t) := + (ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt (s+c*t) hq + have hq₂ : HasDerivAt (fun w => (q w).2) + (-coordinateChristoffel g (q (s+c*t)).1 (q (s+c*t)).2 (q (s+c*t)).2) (s+c*t) := + (ContinuousLinearMap.snd ℝ E E).hasFDerivAt.comp_hasDerivAt (s+c*t) hq + have h₁ := hq₁.scomp t (((hasDerivAt_id t).const_mul c).const_add s) + have h₂ := (hq₂.scomp t (((hasDerivAt_id t).const_mul c).const_add s)).const_smul c + convert! h₁.prodMk h₂ using 1 + simp only [coordinateGeodesicField,coordinateChristoffel_smul_left, + coordinateChristoffel_smul_right,mul_one,smul_neg] + +variable [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_locally_minimizing (z : TangentBundle 𝓘(ℝ,E) M) (t₀ : ℝ) : + ∃ ε : ℝ, 0 < ε ∧ ∀ s u : ℝ, |s-t₀| < ε → |u-t₀| < ε → + dist (sprayFlow s z).1 (sprayFlow u z).1 = |s-u| * ‖z.2‖ := by + let γ := fun t => sprayFlow t z + let a := γ t₀ + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a + let cM := extChartAt 𝓘(ℝ,E) a.1 + let q := χ ∘ γ + have hγ := (sprayFlow_curve z).isMIntegralCurveAt t₀ + have hγc : ContinuousAt (fun t => (γ t).1) t₀ := + (FiberBundle.continuous_proj E (fun x : M => TangentSpace 𝓘(ℝ,E) x)).continuousAt.comp + hγ.continuousAt + obtain ⟨δ,r,τ,hδ,hr,hτ,hτr,Φ,e,_,hΦ0,hΦode,_,hesub,_,_,hδsrc,hediag,_,hdist⟩ := + exists_uniform_metric_normal_coordinates (E := E) a.1 + have hnear : ∀ᶠ s in 𝓝 t₀, (γ s).1 ∈ Metric.ball a.1 δ := + hγc.preimage_mem_nhds (Metric.ball_mem_nhds _ hδ) + have hode : ∀ᶠ s in 𝓝 t₀, + (γ s).1 ∈ Metric.ball a.1 δ ∧ + HasDerivAt q (coordinateGeodesicField (riemannianCoordinateMetric a.1) (q s)) s := by + filter_upwards [hnear,hγ.eventually_hasDerivAt] with s hs hd + rw [geodesicSpray_coordinates a (γ s) (hδsrc hs)] at hd + exact ⟨hs,hd⟩ + obtain ⟨h,hh,hN⟩ := Metric.mem_nhds_iff.mp hode + have hN' : ∀ s : ℝ, |s-t₀| < h → (γ s).1 ∈ Metric.ball a.1 δ ∧ + HasDerivAt q (coordinateGeodesicField (riemannianCoordinateMetric a.1) (q s)) s := by + intro s hs + exact hN (show s ∈ Metric.ball t₀ h by simpa only [Metric.mem_ball,Real.dist_eq] using hs) + have hqc : ContinuousAt q t₀ := (spray_chart_hasDerivAt hγ).continuousAt + let K : ℝ × ℝ → E × E := fun p => ((q p.1).1,((p.2-p.1)/τ) • (q p.1).2) + have hqp : ContinuousAt (fun p : ℝ × ℝ => q p.1) (t₀,t₀) := + ContinuousAt.comp (g := q) (f := (Prod.fst : ℝ × ℝ → ℝ)) hqc continuousAt_fst + have hscale : ContinuousAt (fun p : ℝ × ℝ => (p.2-p.1)/τ) (t₀,t₀) := + (continuousAt_snd.sub continuousAt_fst).div_const τ + have hK : ContinuousAt K (t₀,t₀) := hqp.fst.prodMk (hscale.smul hqp.snd) + have hKt : K (t₀,t₀) ∈ e.source := by + simpa only [K,sub_self,zero_div,zero_smul,q,χ,Function.comp_apply,tangent_chart_apply] + using hediag a.1 (Metric.mem_ball_self hδ) + obtain ⟨η,hη,hηK⟩ := Metric.mem_nhds_iff.mp + (hK.preimage_mem_nhds (e.open_source.mem_nhds hKt)) + obtain ⟨ε,hε,hεη,hεh,htube⟩ := exists_small_affine_time_tube t₀ hh hτ hr hη + refine ⟨ε,hε,?_⟩ + intro s u hs hu + have hsN := hN' s (hs.trans_le hεh) + have huN := hN' u (hu.trans_le hεh) + let c := (u-s)/τ + let v₀ : E × E := ((q s).1,c • (q s).2) + have hv : v₀ ∈ e.source := by + change K (s,u) ∈ e.source + apply hηK (a := (s,u)) + simpa only [Metric.mem_ball,Prod.dist_eq,Real.dist_eq] using + max_lt (hs.trans_le hεη) (hu.trans_le hεη) + have hvball := hesub hv + let P : ℝ → E × E := fun w => ((q (s+c*w)).1,c • (q (s+c*w)).2) + have hPimg : ∀ w ∈ Ioo (-r) r, (P w).1 ∈ cM.target := by + intro w hw + have hw' : |w| < r := abs_lt.mpr hw + have hNw := hN' (s+c*w) (htube s u w hs hu hw') + exact cM.map_source (hδsrc hNw.1) + have hPode : ∀ w ∈ Ioo (-r) r, + HasDerivAt P (coordinateGeodesicField (riemannianCoordinateMetric a.1) (P w)) w := by + intro w hw + exact coordinate_geodesic_affine (hN' (s+c*w) (htube s u w hs hu (abs_lt.mpr hw))).2 + have ht : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have h₁ := sprayFlow_eq_coordinate_curve a hr + (fun w hw => (hΦode w hw v₀ hvball).1) + (fun w hw => (hΦode w hw v₀ hvball).2) + (congrArg χ.symm (hΦ0 v₀ hvball)) ht + have h₂ := sprayFlow_eq_coordinate_curve a hr hPimg hPode + (show χ.symm (P 0) = χ.symm v₀ by simp only [P,v₀,mul_zero,add_zero]) ht + have hEq : Φ (τ,v₀) = P τ := by + have hh := congrArg χ (h₁.symm.trans h₂) + rw [χ.right_inv ((tangent_chart_target_iff a _).mpr (hΦode τ ht v₀ hvball).1), + χ.right_inv ((tangent_chart_target_iff a _).mpr (hPimg τ ht))] at hh + exact hh + have htime : s+c*τ = u := by + dsimp [c] + rw [div_mul_cancel₀ _ (ne_of_gt hτ)] + ring + have hend : (Φ (τ,v₀)).1 = cM (γ u).1 := by + rw [hEq] + change (q (s+c*τ)).1 = _ + rw [htime] + exact congrArg Prod.fst (tangent_chart_apply a (γ u)) + have hmet := hdist (γ s).1 hsN.1 (γ u).1 huN.1 (c • (q s).2) hv hend + have hen : riemannianCoordinateMetric a.1 (q s).1 (q s).2 (q s).2 = ‖(γ s).2‖^2 := + coordinate_spray_energy a (γ s) (hδsrc hsN.1) + have hsc : riemannianCoordinateMetric a.1 (q s).1 (c • (q s).2) (c • (q s).2) = + (c*‖(γ s).2‖)^2 := by + simp only [map_smul,smul_apply,smul_eq_mul,hen] + ring + change dist (γ s).1 (γ u).1 = τ * Real.sqrt + (riemannianCoordinateMetric a.1 (q s).1 (c • (q s).2) (c • (q s).2)) at hmet + rw [hsc,Real.sqrt_sq_eq_abs,abs_mul,abs_norm] at hmet + calc + dist (γ s).1 (γ u).1 = τ * (|c| * ‖(γ s).2‖) := hmet + _ = |s-u| * ‖(γ s).2‖ := by + dsimp [c] + rw [abs_div,abs_of_pos hτ,abs_sub_comm u s] + field_simp [ne_of_gt hτ] + _ = |s-u| * ‖z.2‖ := by rw [sprayFlow_speed] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayNonconjugacy.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayNonconjugacy.lean new file mode 100644 index 0000000000000000000000000000000000000000..2361afaf307635b88317e7a13c202427d6c50c6d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayNonconjugacy.lean @@ -0,0 +1,208 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.LocalCostSmooth +import OAI.Analysis.BiholderTransport.Geodesics.SprayActionMinimum +import OAI.Analysis.BiholderTransport.Regularity.ActionLocalData +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateGradient +import OAI.Analysis.BiholderTransport.Calculus.ActionCalculus + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma sprayFlow_interior_nonconjugate (x : M) (p : TangentSpace 𝓘(ℝ,E) x) + {t T : ℝ} (ht : 0 extChartAt 𝓘(ℝ,E) + (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 + (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1) p) := by + let a := sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M) + let c := extChartAt 𝓘(ℝ,E) a.1 + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a + let Q : TangentSpace 𝓘(ℝ,E) x → E := fun v => c (sprayFlow t ⟨x,v⟩).1 + let V : TangentSpace 𝓘(ℝ,E) x → E := fun v => (χ (sprayFlow t ⟨x,v⟩)).2 + let g := riemannianCoordinateMetric (E := E) a.1 + have hsrc : a.1 ∈ c.source := mem_extChartAt_source a.1 + have hQp : Q p = c a.1 := rfl + have htarget : Q p ∈ c.target := by + rw [hQp] + exact c.map_source hsrc + have hInv : c.symm (Q p)=a.1 := c.left_inv hsrc + have hΦ : ContDiffAt ℝ ∞ (fun v : TangentSpace 𝓘(ℝ,E) x => χ (sprayFlow t ⟨x,v⟩)) p := + ((show ContMDiffAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) 𝓘(ℝ,E×E) ∞ χ a from + contMDiffAt_extChartAt).comp p (contMDiff_spray_fiber x t p)).contDiffAt + have hΦeq : (fun v : TangentSpace 𝓘(ℝ,E) x => χ (sprayFlow t ⟨x,v⟩)) = fun v => (Q v,V v) := by + funext v + apply Prod.ext + · exact congrArg Prod.fst (tangent_chart_apply a (sprayFlow t ⟨x,v⟩)) + · rfl + rw [hΦeq] at hΦ + have hQ := hΦ.fst + have hV := hΦ.snd + obtain ⟨δ,hδ,hC⟩ := exists_local_cost_smooth (E := E) a.1 + obtain ⟨ε,hε,hεt,hεT,hy,hlocal⟩ := exists_two_short_legs x p ht hT hδ + let L := t-ε + let y := (sprayFlow (t+ε) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 + let b : TangentSpace 𝓘(ℝ,E) x → M := fun v => (sprayFlow L ⟨x,v⟩).1 + let K : E → ℝ := fun q => (dist (c.symm q) y^2/2)/ε + let B : TangentSpace 𝓘(ℝ,E) x × E → ℝ := fun z => + L*‖z.1‖^2/2 + (dist (b z.1) (c.symm z.2)^2/2)/ε + K z.2 + have hL : 0 TangentSpace 𝓘(ℝ,E) z)).comp (contMDiff_spray_fiber x L) + have hqδ : c.symm (Q p) ∈ Metric.ball a.1 δ := by rw [hInv]; exact Metric.mem_ball_self hδ + have hIC := coordinate_cost_contDiffAt hC (hb p) hlp.1 htarget hqδ + have hK : ContDiffAt ℝ ∞ K (Q p) := + (coordinate_outgoing_cost_contDiffAt hC hy htarget hqδ).div_const ε + have hB : ContDiffAt ℝ 2 B (p,Q p) := by + have hn : ContDiffAt ℝ ∞ (fun z : TangentSpace 𝓘(ℝ,E) x × E => L*‖z.1‖^2/2) (p,Q p) := + (contDiffAt_const.mul ((contDiff_norm_sq ℝ).contDiffAt.comp (p,Q p) contDiffAt_fst)).div_const 2 + exact ((hn.add (hIC.div_const ε)).add (hK.comp (p,Q p) contDiffAt_snd)).of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hm : dist x (sprayFlow (L+2*ε) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 = (L+2*ε)*‖p‖ := + sprayFlow_minimizing_prefix (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M) + (by positivity) (by dsimp [L]; linarith) hmin + have hBcontact : B (p,Q p)=(L+2*ε)*‖p‖^2/2 := by + dsimp [B,K] + rw [hInv] + have heq₁ : L+ε=t := by dsimp [L]; ring + have heq₂ : L+2*ε=t+ε := by dsimp [L]; ring + convert! spray_split_action_contact x p hL hε hm using 1; + simp only [heq₁,heq₂,div_div,b,y,a] + have hBmin : IsLocalMin B (p,Q p) := by + apply Filter.Eventually.of_forall + intro z + rw [hBcontact] + have heq : L+2*ε=t+ε := by dsimp [L]; ring + convert! spray_split_action_minimum x p hL hε hm z.1 (c.symm z.2) using 1; + simp only [B,K,b,y,heq,div_div] + have hnear : ∀ᶠ v : TangentSpace 𝓘(ℝ,E) x in 𝓝 p, + (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1 ∈ c.source := + ((Bundle.contMDiff_proj (fun z : M => TangentSpace 𝓘(ℝ,E) z)).comp + (contMDiff_spray_fiber x t) p).continuousAt.preimage_mem_nhds + ((isOpen_extChartAt_source a.1).mem_nhds hsrc) + have hBnear : ∀ᶠ v in 𝓝 p, DifferentiableAt ℝ B (v,Q v) := + (continuousAt_id.prodMk hQ.continuousAt).tendsto.eventually + ((hB.eventually (by norm_num)).mono (fun _ h => h.differentiableAt (by norm_num))) + have hKnear : ∀ᶠ v in 𝓝 p, DifferentiableAt ℝ K (Q v) := + hQ.continuousAt.tendsto.eventually + (((hK.of_le (m := 1) (by simp)).eventually (by norm_num)).mono + (fun _ h => h.differentiableAt (by norm_num))) + have hstat : ∀ᶠ v in 𝓝 p, ∀ w : TangentSpace 𝓘(ℝ,E) x, fderiv ℝ B (v,Q v) (w,0)=0 := by + filter_upwards [hlocal,hnear,hBnear] with v hv hvs hBd + intro w + apply fderiv_fst_eq_of_line_stationary hBd + have hd := (spray_action_line_stationary x v w L ε hε.ne' + (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1 hv.2.2.1).add_const (K (Q v)) + simpa only [B,b,Q,c.left_inv hvs,zero_add] using hd + have hcot : ∀ᶠ v in 𝓝 p, ∀ u : E, + fderiv ℝ B (v,Q v) (0,u) = g (Q v) (V v) u + fderiv ℝ K (Q v) u := by + filter_upwards [hlocal,hnear,hBnear,hKnear] with v hv hvs hBd hKd + intro u + have hd := (coordinate_gradient_of_hasMFDerivAt + (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)) hvs + (fun q => dist (b v) q^2/2) ε hv.2.2.2).mul_const ε⁻¹ + have hI : HasFDerivAt (fun q : E => (dist (b v) (c.symm q)^2/2)/ε) + (g (Q v) (V v)) (Q v) := by + convert! hd using 1 + simp only [smul_smul, inv_mul_cancel₀ hε.ne', one_smul] + rfl + have H := ((hasFDerivAt_const (L*‖v‖^2/2) (Q v)).add hI).add hKd.hasFDerivAt + have H' : HasFDerivAt (fun q : E => B (v,q)) (g (Q v) (V v)+fderiv ℝ K (Q v)) (Q v) := by + convert! H using 1 + ext z + simp only [_root_.add_apply, zero_add] + exact fderiv_snd_eq_of_partial hBd H' u + have hg : DifferentiableAt ℝ g (Q p) := + ((contDiffOn_riemannianCoordinateMetric a.1).contDiffAt + ((isOpen_extChartAt_target a.1).mem_nhds htarget)).differentiableAt (by simp) + have hR : DifferentiableAt ℝ (fderiv ℝ K) (Q p) := + (hK.fderiv_right (m := 1) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).differentiableAt (by norm_num) + have hpos : ∀ u : E, u≠0 → 0 riemannianCoordinateMetric_positive htarget hu + have himm : Function.Injective (fderiv ℝ (fun v => (Q v,V v)) p) := by + rw [←hΦeq] + exact coordinate_spray_fiber_immersion x p t + exact generating_graph_position_immersion hB hBmin + (hQ.differentiableAt (by simp)) (hV.differentiableAt (by simp)) hg hR hpos hstat hcot himm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayProjection.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc6fba2af17a9930deb850247980ff7c8c0cca6f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayProjection.lean @@ -0,0 +1,226 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateVariation +import OAI.Analysis.BiholderTransport.Geodesics.CompleteSpray +import OAI.Analysis.BiholderTransport.LocalFlow.SmoothIntegralCurve + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma hasMFDerivAt_spray_projection {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {t : ℝ} + (hγ : IsMIntegralCurveAt γ (geodesicSpray (E := E)) t) : + HasMFDerivAt 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun s => (γ s).1) t + ((1 : ℝ →L[ℝ] ℝ).smulRight (γ t).2) := by + have hd := (ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt t + (spray_chart_hasDerivAt hγ) + have ht := mem_extChartAt_source (I := 𝓘(ℝ,E)) (γ t).1 + have hself : (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) (γ t)).2 = + (γ t).2 := by + rw [tangent_chart_apply] + exact tangentCoordChange_self ht + change HasDerivAt (fun s => (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) (γ s)).1) + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) (γ t) (γ t)).2 t at hd + rw [hself] at hd + have hd' : HasDerivAt (extChartAt 𝓘(ℝ,E) (γ t).1 ∘ (fun s => (γ s).1)) + (γ t).2 t := by + simpa only [Function.comp_def,tangent_chart_apply] using hd + refine ⟨(FiberBundle.continuous_proj E (fun x : M => TangentSpace 𝓘(ℝ,E) x)).continuousAt.comp + hγ.continuousAt,?_⟩ + rw [writtenInExtChartAt,extChartAt_model_space_eq_id,ModelWithCorners.range_eq_univ] + change HasFDerivWithinAt (extChartAt 𝓘(ℝ,E) (γ t).1 ∘ (fun s => (γ s).1)) + ((1 : ℝ →L[ℝ] ℝ).smulRight (γ t).2) univ t + rw [hasFDerivWithinAt_univ] + convert! hd'.hasFDerivAt using 1 + +lemma spray_velocity_eq_mfderiv {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} {t : ℝ} + (hγ : IsMIntegralCurveAt γ (geodesicSpray (E := E)) t) : + mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun s => (γ s).1) t (1 : ℝ) = (γ t).2 := by + have h := congrArg (fun f : TangentSpace 𝓘(ℝ,ℝ) t →L[ℝ] + TangentSpace 𝓘(ℝ,E) (γ t).1 => f (1 : ℝ)) (hasMFDerivAt_spray_projection hγ).mfderiv + change mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,E) (fun s => (γ s).1) t (1 : ℝ) = + (1 : ℝ) • (γ t).2 at h + simpa only [one_smul] using h + +variable [T2Space M] [CompactSpace M] + +def sprayFlow (t : ℝ) (z : TangentBundle 𝓘(ℝ,E) M) : TangentBundle 𝓘(ℝ,E) M := + completeFlow exists_complete_spray_curve t z + +lemma sprayFlow_zero (z : TangentBundle 𝓘(ℝ,E) M) : sprayFlow 0 z = z := + completeFlow_zero exists_complete_spray_curve z + +lemma sprayFlow_curve (z : TangentBundle 𝓘(ℝ,E) M) : + IsMIntegralCurve (fun t => sprayFlow t z) (geodesicSpray (E := E)) := + completeFlow_curve exists_complete_spray_curve z + +lemma sprayFlow_add (s t : ℝ) (z : TangentBundle 𝓘(ℝ,E) M) : + sprayFlow (s+t) z = sprayFlow s (sprayFlow t z) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + exact completeFlow_add exists_complete_spray_curve contMDiff_geodesicSpray s t z + +lemma contMDiff_sprayFlow : + ContMDiff (𝓘(ℝ,ℝ).prod (𝓘(ℝ,E).prod 𝓘(ℝ,E))) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) ∞ + (fun z : ℝ × TangentBundle 𝓘(ℝ,E) M => sprayFlow z.1 z.2) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + exact contMDiff_completeFlow exists_complete_spray_curve contMDiff_geodesicSpray + +lemma sprayFlow_speed (t : ℝ) (z : TangentBundle 𝓘(ℝ,E) M) : + ‖(sprayFlow t z).2‖ = ‖z.2‖ := by + have he := spray_speed_constant ((sprayFlow_curve z).isMIntegralCurveOn (Ioo (min t 0-1) (max t 0+1))) + (show t ∈ Ioo (min t 0-1) (max t 0+1) from + ⟨by linarith [min_le_left t 0],by linarith [le_max_left t 0]⟩) + (show (0:ℝ) ∈ Ioo (min t 0-1) (max t 0+1) from + ⟨by linarith [min_le_right t 0],by linarith [le_max_right t 0]⟩) + exact he.trans (congrArg (fun w : TangentBundle 𝓘(ℝ,E) M => ‖w.2‖) (sprayFlow_zero z)) + +end +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + +omit [FiniteDimensional ℝ E] in +lemma tangent_chart_target_iff (a : TangentBundle 𝓘(ℝ,E) M) (q : E × E) : + q ∈ (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).target ↔ + q.1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target := by + rw [FiberBundle.extChartAt_target] + constructor + · exact fun h => h.1.1 + · intro h + refine ⟨⟨h,?_⟩,mem_univ _⟩ + simpa only [TangentBundle.trivializationAt_baseSet,← extChartAt_source 𝓘(ℝ,E),mem_preimage] using + (extChartAt 𝓘(ℝ,E) a.1).map_target h + +variable [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +lemma hasMFDerivAt_of_coordinate_spray (a : TangentBundle 𝓘(ℝ,E) M) + {q : ℝ → E × E} {t : ℝ} (hq : (q t).1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target) + (hd : HasDerivAt q (coordinateGeodesicField (riemannianCoordinateMetric a.1) (q t)) t) : + HasMFDerivAt 𝓘(ℝ,ℝ) (𝓘(ℝ,E).prod 𝓘(ℝ,E)) + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm ∘ q) t + ((1 : ℝ →L[ℝ] ℝ).smulRight + (geodesicSpray ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm (q t)))) := by + have hqt := (tangent_chart_target_iff a (q t)).mpr hq + apply hasMFDerivAt_of_chart_ode a hqt + rw [geodesicSpray_coordinates a _ ((tangent_chart_source_iff a _).mp + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).map_target hqt)), + (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).right_inv hqt] + exact hd + +omit [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [FiniteDimensional ℝ E] [IsManifold 𝓘(ℝ,E) ∞ M] in +lemma coordinate_geodesic_scale {g : E → E →L[ℝ] E →L[ℝ] ℝ} + {q : ℝ → E × E} {t c : ℝ} + (hq : HasDerivAt q (coordinateGeodesicField g (q (c*t))) (c*t)) : + HasDerivAt (fun s => ((q (c*s)).1,c • (q (c*s)).2)) + (coordinateGeodesicField g ((q (c*t)).1,c • (q (c*t)).2)) t := by + have hq₁ : HasDerivAt (fun s => (q s).1) (q (c*t)).2 (c*t) := + (ContinuousLinearMap.fst ℝ E E).hasFDerivAt.comp_hasDerivAt (c*t) hq + have hq₂ : HasDerivAt (fun s => (q s).2) + (-coordinateChristoffel g (q (c*t)).1 (q (c*t)).2 (q (c*t)).2) (c*t) := + (ContinuousLinearMap.snd ℝ E E).hasFDerivAt.comp_hasDerivAt (c*t) hq + have h₁ := hq₁.scomp t ((hasDerivAt_id t).const_mul c) + have h₂ := (hq₂.scomp t ((hasDerivAt_id t).const_mul c)).const_smul c + have h := h₁.prodMk h₂ + convert! h using 1 + simp only [coordinateGeodesicField,coordinateChristoffel_smul_left, + coordinateChristoffel_smul_right,mul_one,smul_neg] + +variable [T2Space M] [CompactSpace M] + +lemma sprayFlow_eq_coordinate_curve (a : TangentBundle 𝓘(ℝ,E) M) + {q : ℝ → E × E} {r : ℝ} (hr : 0 < r) + (himg : ∀ t ∈ Ioo (-r) r, (q t).1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target) + (hode : ∀ t ∈ Ioo (-r) r, + HasDerivAt q (coordinateGeodesicField (riemannianCoordinateMetric a.1) (q t)) t) + {z : TangentBundle 𝓘(ℝ,E) M} + (hq0 : (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm (q 0) = z) + {t : ℝ} (ht : t ∈ Ioo (-r) r) : + sprayFlow t z = (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm (q t) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + apply isMIntegralCurveOn_Ioo_eqOn_of_contMDiff_boundaryless + (t₀ := 0) ⟨neg_lt_zero.mpr hr,hr⟩ (contMDiff_geodesicSpray.of_le (by simp)) + ((sprayFlow_curve z).isMIntegralCurveOn _) _ _ ht + · intro s hs + exact (hasMFDerivAt_of_coordinate_spray a (himg s hs) (hode s hs)).hasMFDerivWithinAt + · exact (sprayFlow_zero z).trans hq0.symm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayScaling.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayScaling.lean new file mode 100644 index 0000000000000000000000000000000000000000..5dfc748e7e18fed6b55a3c3c9b41e9229f0e05f4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/SprayScaling.lean @@ -0,0 +1,140 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.SprayProjection + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [TopologicalSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + +def tangentScale (c : ℝ) (z : TangentBundle 𝓘(ℝ,E) M) : TangentBundle 𝓘(ℝ,E) M := + ⟨z.1,c • z.2⟩ + +omit [FiniteDimensional ℝ E] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] in +lemma tangent_chart_scale (a z : TangentBundle 𝓘(ℝ,E) M) (c : ℝ) : + extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a (tangentScale c z) = + ((extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z).1, + c • (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a z).2) := by + simp only [tangent_chart_apply,tangentScale] + congr 1 + exact (tangentCoordChange 𝓘(ℝ,E) z.1 a.1 z.1).map_smul c z.2 + +lemma isMIntegralCurve_spray_scaled {γ : ℝ → TangentBundle 𝓘(ℝ,E) M} + (hγ : IsMIntegralCurve γ (geodesicSpray (E := E))) (c : ℝ) : + IsMIntegralCurve (fun t => tangentScale c (γ (c*t))) (geodesicSpray (E := E)) := by + intro t + let a := γ (c*t) + let χ := extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a + let P : ℝ → E × E := fun s => ((χ (γ (c*s))).1,c • (χ (γ (c*s))).2) + have hd := coordinate_geodesic_scale (spray_chart_hasDerivAt (hγ.isMIntegralCurveAt (c*t))) + (c := c) + have hPt : (P t).1 ∈ (extChartAt 𝓘(ℝ,E) a.1).target := by + change (χ a).1 ∈ _ + rw [tangent_chart_apply] + exact mem_extChartAt_target a.1 + have hδ : (χ.symm ∘ P) =ᶠ[𝓝 t] (fun s => tangentScale c (γ (c*s))) := by + have hc : ContinuousAt (fun s => γ (c*s)) t := + (hγ.isMIntegralCurveAt (c*t)).continuousAt.comp (continuousAt_const.mul continuousAt_id) + have hn : ∀ᶠ s in 𝓝 t, γ (c*s) ∈ χ.source := + hc.preimage_mem_nhds (extChartAt_source_mem_nhds (I := 𝓘(ℝ,E).prod 𝓘(ℝ,E)) a) + filter_upwards [hn] with s hs + have hss : tangentScale c (γ (c*s)) ∈ χ.source := + (tangent_chart_source_iff a _).mpr ((tangent_chart_source_iff a _).mp hs) + change χ.symm (P s) = _ + rw [show P s = χ (tangentScale c (γ (c*s))) from (tangent_chart_scale a _ c).symm] + exact χ.left_inv hss + have scaledDeriv := + (hasMFDerivAt_of_coordinate_spray a hPt hd).congr_of_eventuallyEq_abuse hδ.symm + have scaledPoint : (extChartAt (𝓘(ℝ,E).prod 𝓘(ℝ,E)) a).symm (P t) = + tangentScale c (γ (c*t)) := hδ.self_of_nhds + apply scaledDeriv.congr_mfderiv + exact congrArg (fun point : TangentBundle 𝓘(ℝ,E) M => + (1 : ℝ →L[ℝ] ℝ).smulRight (show E × E from geodesicSpray point)) scaledPoint + +variable [T2Space M] [CompactSpace M] + +lemma sprayFlow_scale (z : TangentBundle 𝓘(ℝ,E) M) (c t : ℝ) : + sprayFlow t (tangentScale c z) = tangentScale c (sprayFlow (c*t) z) := by + have : T2Space (TangentBundle 𝓘(ℝ,E) M) := bundle_totalSpace_t2 + have he := isMIntegralCurve_Ioo_eq_of_contMDiff_boundaryless (t₀ := 0) + (contMDiff_geodesicSpray.of_le (by simp)) (sprayFlow_curve (tangentScale c z)) + (isMIntegralCurve_spray_scaled (sprayFlow_curve z) c) + (by simp only [sprayFlow_zero,mul_zero]) + exact congrFun he t + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Geodesics/UniformFixedCrossing.lean b/lean/OAI/Analysis/BiholderTransport/Geodesics/UniformFixedCrossing.lean new file mode 100644 index 0000000000000000000000000000000000000000..103f6146221e0ce806d8ffc798eaa749e902d558 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Geodesics/UniformFixedCrossing.lean @@ -0,0 +1,39 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.UniformRegularSplit + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma minimizing_norm_le_diam {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈minimizingVectors x) : ‖p‖ ≤ Metric.diam (univ : Set M) := by + rw [←hp] + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ _) (mem_univ _) + +lemma exists_actual_uniform_regular_split : + ∃ h : ℝ, 0 < h ∧ h < 1 ∧ ∀ x : M, + ∀ p : TangentSpace 𝓘(ℝ,Model n) x, p∈minimizingVectors x → + h • p∈injectivityDomain x ∧ + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + obtain ⟨h,hh,hh1,Hh⟩ := exists_uniform_regular_split (n := n) (M := M) (Metric.diam (univ : Set M)) + exact ⟨h,hh,hh1,fun x p hp => Hh x p (minimizing_norm_le_diam hp) hp⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRadial.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRadial.lean new file mode 100644 index 0000000000000000000000000000000000000000..4e70be8a887e126d1da3aee8f360342c157511e8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRadial.lean @@ -0,0 +1,164 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.RadialIdentity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def normalHessian (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ := + fderiv ℝ (fderiv ℝ (normalCost x p)) 0 + +lemma normalHessian_symm {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (v w : TangentSpace 𝓘(ℝ,Model n) x) : + normalHessian x p v w = normalHessian x p w v := + ((normalCost_contDiffAt hp).isSymmSndFDerivAt (by simp)).eq v w + +lemma hessianValue_eq_normalHessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (v : TangentSpace 𝓘(ℝ,Model n) x) : + hessianValue x p v=normalHessian x p v v := by + have H := iteratedDeriv_two_affine_line + ((normalCost_contDiffAt hp).of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) v + simpa only [zero_add,normalCost,hessianValue,normalHessian] using H + +lemma normalHessian_radial {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (v : TangentSpace 𝓘(ℝ,Model n) x) : + normalHessian x p p v=inner ℝ p v := normalCost_radial_hessian hp v + +lemma normalHessian_contracted_radial {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {r : ℝ} (hr : r≠0) (hp : r • p ∈ injectivityDomain x) + (v : TangentSpace 𝓘(ℝ,Model n) x) : normalHessian x (r • p) p v=inner ℝ p v := by + have H := normalHessian_radial hp v + simp only [map_smul,smul_apply,real_inner_smul_left,smul_eq_mul] at H + exact (mul_left_cancel₀ hr H) + +lemma hessianValue_contracted_radial {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {r : ℝ} (hr : r≠0) (hp : r • p ∈ injectivityDomain x) : + hessianValue x (r • p) p=‖p‖^2 := by + rw [hessianValue_eq_normalHessian hp,normalHessian_contracted_radial hr hp,real_inner_self_eq_norm_sq] + +lemma hessianValue_transverse_radial_identity {x : M} {p e : TangentSpace 𝓘(ℝ,Model n) x} + {r s : ℝ} (hr : r≠0) (hp : r • (p+s • e) ∈ injectivityDomain x) + (hortho : inner ℝ p e=0) : + hessianValue x (r • (p+s • e)) p = ‖p‖^2+s^2*(hessianValue x (r • (p+s • e)) e-‖e‖^2) := by + rw [hessianValue_eq_normalHessian hp,hessianValue_eq_normalHessian hp] + have H1 := normalHessian_contracted_radial hr hp p + have H2 := normalHessian_contracted_radial hr hp e + have hep : inner ℝ e p=0 := by rw [real_inner_comm,hortho] + simp only [map_add,map_smul,add_apply,smul_apply,smul_eq_mul, + inner_add_left,real_inner_smul_left,hortho,hep,real_inner_self_eq_norm_sq,mul_zero,zero_add,add_zero] at H1 H2 + rw [normalHessian_symm hp e p] at H1 + nlinarith [congrArg (fun a : ℝ => s*a) H2] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRelativeHessianBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRelativeHessianBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7ca1fad7c420a96d4ee8336a95207b476af689f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ActualRelativeHessianBound.lean @@ -0,0 +1,168 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.RelativeHessianBound +import OAI.Analysis.BiholderTransport.Regularity.CenteredQuadratic + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section ActualRelativeHessianBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_relative_hessian_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 0 ‖w-z‖^2/2 + let ψ : Model n → ℝ := fun w => φ w-(m/2)*q w + have hq : ContDiffAt ℝ 2 q z := (centered_half_norm_sq_c2 z).contDiffAt + have hψ : ContDiffAt ℝ 2 ψ z := hφ.sub (contDiffAt_const.mul hq) + have hψL : fderiv ℝ ψ z=L := by + rw [show ψ=(fun w => φ w-(m/2)*q w) from rfl, + fderiv_fun_sub (hφ.differentiableAt (by norm_num)) + ((hq.differentiableAt (by norm_num)).const_mul _)] + change fderiv ℝ φ z-fderiv ℝ ((m/2) • q) z=L + rw [fderiv_const_smul_field,Pi.smul_apply,centered_half_norm_sq_fderiv,smul_zero,sub_zero,hL] + have hψval : uv.1 a=ψ z := by simpa [ψ,q] using hval + have hgap : ∃ ε>0,∀ᶠ w in 𝓝 z, + ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-ψ w := by + refine ⟨m/4,by positivity,?_⟩ + filter_upwards [hlo] with w hw + dsimp only [ψ,q] + rw [dist_eq_norm] + nlinarith only [hw] + have hψH (e : Model n) : fderiv ℝ (fderiv ℝ ψ) z e e= + fderiv ℝ (fderiv ℝ φ) z e e-(m/2)*‖e‖^2 := by + rw [show ψ=(fun w => φ w-(m/2)*q w) from rfl, + second_fderiv_sub hφ (contDiffAt_const.mul hq),second_fderiv_const_mul, + centered_half_norm_sq_second] + have hpψ : ∀ e : Model n,(m/2)*‖e‖^2≤fderiv ℝ (fderiv ℝ ψ) z e e+ + fderiv ℝ (fderiv ℝ (chartCost a b)) z e e := by + intro e + rw [hψH] + linarith only [hpos e] + have HD := H x0 uv huv ψ hψ hψL hψval hgap hpψ d + rw [hψH] at HD + nlinarith only [HD] + +end ActualRelativeHessianBound +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section ActualRelativeHessianBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_relative_hessian_bound + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 0 ‖w-z‖^2/2 + let ψ : Model n → ℝ := fun w => φ w-(m/2)*q w + have hq : ContDiffAt ℝ 2 q z := (centered_half_norm_sq_c2 z).contDiffAt + have hψ : ContDiffAt ℝ 2 ψ z := hφ.sub (contDiffAt_const.mul hq) + have hψL : fderiv ℝ ψ z=fderiv ℝ φ z := by + rw [show ψ=(fun w => φ w-(m/2)*q w) from rfl, + fderiv_fun_sub (hφ.differentiableAt (by norm_num)) + ((hq.differentiableAt (by norm_num)).const_mul _)] + change fderiv ℝ φ z-fderiv ℝ ((m/2) • q) z=fderiv ℝ φ z + rw [fderiv_const_smul_field,Pi.smul_apply,centered_half_norm_sq_fderiv,smul_zero,sub_zero] + have hψval : uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)=ψ z := by simpa [ψ,q] using hval + have hgap : ∃ ε>0,∀ᶠ w in 𝓝 z, + ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-ψ w := by + refine ⟨m/4,by positivity,?_⟩ + filter_upwards [hlo] with w hw + dsimp only [ψ,q] + rw [dist_eq_norm] + nlinarith only [hw] + have hψH (e : Model n) : fderiv ℝ (fderiv ℝ ψ) z e e= + fderiv ℝ (fderiv ℝ φ) z e e-(m/2)*‖e‖^2 := by + rw [show ψ=(fun w => φ w-(m/2)*q w) from rfl, + second_fderiv_sub hφ (contDiffAt_const.mul hq),second_fderiv_const_mul, + centered_half_norm_sq_second] + have hpψ : ∀ e : Model n,(m/2)*‖e‖^2≤fderiv ℝ (fderiv ℝ ψ) z e e+ + fderiv ℝ (fderiv ℝ (chartCost a b)) z e e := by + intro e + rw [hψH] + linarith only [hpos e] + have HD := H x0 uv huv z ψ (by rw [hψL]; exact hz) hψ hψval hgap + (by simpa only [hψL] using hpψ) d + rw [hψH,hψL] at HD + nlinarith only [HD] + +end ActualRelativeHessianBound +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Aggregate.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Aggregate.lean new file mode 100644 index 0000000000000000000000000000000000000000..05d7a914141ecd68f0513501dad0b599e30148ee --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Aggregate.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ActualRadial +import OAI.Analysis.BiholderTransport.Coordinates.Prefix + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology BigOperators + +namespace WeakMTWTransport + +lemma symmetric_bilinear_eq_of_diagonal + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {A B : E →L[ℝ] E →L[ℝ] ℝ} + (hA : ∀ u v, A u v = A v u) (hB : ∀ u v, B u v = B v u) + (hd : ∀ u, A u u = B u u) : A = B := by + ext u v + have H := hd (u+v) + simp only [map_add,add_apply,hA v u,hB v u] at H + linarith [hd u,hd v] + +section GeometryJets +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma prefixNormalCost_source_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) + (u : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixNormalCost x t)) (0,p) (u,0) (u,0) = + normalHessian x (t • p) u u/t := by + have H := iteratedDeriv_two_affine_line + ((prefixNormalCost_contDiffAt hp).of_le (m := 2) + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) (u,0) + simp only [prefixNormalCost,Prod.fst_add,Prod.smul_fst,Prod.snd_add,Prod.smul_snd, + zero_add,smul_zero,add_zero,iteratedDeriv_div_const] at H + rw [← H,← hessianValue_eq_normalHessian hp] + rfl +end GeometryJets +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearAbsorption.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearAbsorption.lean new file mode 100644 index 0000000000000000000000000000000000000000..4de815e2ffe3c1759b49fb9f4cc65042b6a4fda2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearAbsorption.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section BilinearAbsorption +variable {E:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +local instance bilinearAbsorptionDualNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance bilinearAbsorptionDualNormedSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace +local instance bilinearAbsorptionBilinearNormedAddCommGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup +local instance bilinearAbsorptionBilinearNormedSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + +def covectorSquare (p:E →L[ℝ] ℝ) : E →L[ℝ] E →L[ℝ] ℝ := + p.smulRight p + +lemma covectorSquare_apply (p:E →L[ℝ] ℝ) (d e:E) : covectorSquare p d e=p d*p e := rfl + +lemma covectorSquare_continuous : Continuous (covectorSquare (E := E)) := by + exact isBoundedBilinearMap_smulRight.continuous.comp (continuous_id.prodMk continuous_id) + +lemma eventual_moving_rank_lower {ι:Type*} {l:Filter ι} + {G R H:ι → E →L[ℝ] E →L[ℝ] ℝ} {G₀ R₀:E →L[ℝ] E →L[ℝ] ℝ} + {A C δ:ℝ} (hA:0(A/2) • G k+C • R k) l (𝓝 ((A/2) • G₀+C • R₀)) := + (hG.const_smul _).add (hR.const_smul _) + have hn : ∀ᶠ k in l,‖((A/2) • G k+C • R k)-((A/2) • G₀+C • R₀)‖≤ε := by + have ht := (hlim.sub_const ((A/2) • G₀+C • R₀)).norm + simp only [sub_self,norm_zero] at ht + exact (ht.eventually (gt_mem_nhds he)).mono (fun _ h=>h.le) + filter_upwards [hn,hH ε he] with k hk hhk + intro d + have hb := bilinear_quadratic_close hk d + simp only [add_apply,smul_apply,smul_eq_mul] at hb + have hpos := mul_le_mul_of_nonneg_left (hG₀ d) (show 0≤A/2 by positivity) + dsimp only [ε] at hb hhk + nlinarith only [hb,hhk d,hpos] + +end BilinearAbsorption +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearClose.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearClose.lean new file mode 100644 index 0000000000000000000000000000000000000000..c2094a83cc49e1dbc5e968029365f7b0e3353317 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearClose.lean @@ -0,0 +1,30 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma bilinear_quadratic_norm_bound {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (A : E →L[ℝ] E →L[ℝ] ℝ) (d:E) : |A d d|≤‖A‖*‖d‖^2 := by + calc + |A d d| = ‖A d d‖ := (Real.norm_eq_abs _).symm + _ ≤ ‖A d‖*‖d‖ := (A d).le_opNorm d + _ ≤ (‖A‖*‖d‖)*‖d‖ := mul_le_mul_of_nonneg_right (A.le_opNorm d) (norm_nonneg d) + _ = ‖A‖*‖d‖^2 := by ring + +lemma bilinear_quadratic_close {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {A B : E →L[ℝ] E →L[ℝ] ℝ} {ε:ℝ} (h : ‖A-B‖≤ε) (d:E) : + A d d≤B d d+ε*‖d‖^2 := by + have H := (le_abs_self ((A-B) d d)).trans (bilinear_quadratic_norm_bound (A-B) d) + have HH := H.trans (mul_le_mul_of_nonneg_right h (sq_nonneg ‖d‖)) + simpa only [_root_.sub_apply,sub_le_iff_le_add,add_comm] using HH + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearCompact.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..f4675f2c557c18b08a9edfd2b5e670c1a99d02ca --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearCompact.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section BilinearCompact +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] [CompleteSpace E] + +lemma symmetric_bilinear_norm_bound {B:E →L[ℝ] E →L[ℝ] ℝ} + (hB:∀d e,B d e=B e d) {C:ℝ} (hC:0≤C) + (hbound:∀d,|B d d|≤C*‖d‖^2) : ‖B‖≤C := by + let T:=bilinearOperator B + have hT:T.IsSymmetric := bilinearOperator_symmetric hB + have hn:‖T‖≤C := by + rw [T.norm_eq_iSup_rayleighQuotient hT] + apply ciSup_le + intro d + by_cases hd:d=0 + · simpa [hd,ContinuousLinearMap.rayleighQuotient, + ContinuousLinearMap.reApplyInnerSelf_apply] using hC + · have hp:0<‖d‖^2 := sq_pos_of_pos (norm_pos_iff.mpr hd) + simp only [ContinuousLinearMap.rayleighQuotient, + ContinuousLinearMap.reApplyInnerSelf_apply] + simp only [T,bilinearOperator_inner,RCLike.re_to_real] + rw [abs_div,abs_of_pos hp] + apply (div_le_iff₀ hp).mpr + exact hbound d + apply B.opNorm_le_bound hC + intro d + apply (B d).opNorm_le_bound (mul_nonneg hC (norm_nonneg d)) + intro e + calc + ‖B d e‖ = ‖inner ℝ (T d) e‖ := by simp only [T,bilinearOperator_inner] + _ ≤ ‖T d‖*‖e‖ := norm_inner_le_norm _ _ + _ ≤ (‖T‖*‖d‖)*‖e‖ := mul_le_mul_of_nonneg_right (T.le_opNorm d) (norm_nonneg e) + _ ≤ (C*‖d‖)*‖e‖ := by gcongr + +lemma symmetric_bilinear_norm_of_two_bounds {B:E →L[ℝ] E →L[ℝ] ℝ} + (hB:∀d e,B d e=B e d) {C D:ℝ} (hC:0≤C) (hD:0≤D) + (hlo:∀d,-C*‖d‖^2≤B d d) (hhi:∀d,B d d≤D*‖d‖^2) : ‖B‖≤C+D := by + apply symmetric_bilinear_norm_bound hB (add_nonneg hC hD) + intro d + rw [abs_le] + constructor + · nlinarith only [hlo d,mul_nonneg hD (sq_nonneg ‖d‖)] + · nlinarith only [hhi d,mul_nonneg hC (sq_nonneg ‖d‖)] + +omit [CompleteSpace E] in +lemma rough_hessian_symmetric {f:E → ℝ} {x:E} + (hnear:∀ᶠ z in 𝓝 x,DifferentiableAt ℝ f z) + (hf:DifferentiableAt ℝ (fderiv ℝ f) x) : + ∀d e,fderiv ℝ (fderiv ℝ f) x d e=fderiv ℝ (fderiv ℝ f) x e d := + second_derivative_symmetric_of_eventually (hnear.mono (fun _ h=>h.hasFDerivAt)) hf.hasFDerivAt + +local instance bilinearCompactDualGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance bilinearCompactDualSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +local instance bilinearCompactGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance +local instance bilinearCompactSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance + +omit [CompleteSpace E] in +lemma exists_bilinear_limit [FiniteDimensional ℝ E] + {Bj:ℕ → E →L[ℝ] E →L[ℝ] ℝ} {C:ℝ} + (hb:∀ᶠ j in atTop,‖Bj j‖≤C) : + ∃B:E →L[ℝ] E →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ Tendsto (Bj ∘ σ) atTop (𝓝 B) := by + let : FiniteDimensional ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.finiteDimensional + let : FiniteDimensional ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.finiteDimensional + obtain ⟨N,hN⟩:=eventually_atTop.mp hb + have H : IsCompact (Metric.closedBall (0:E →L[ℝ] E →L[ℝ] ℝ) C) := isCompact_closedBall _ _ + obtain ⟨B,hB,σ,hσ,hlim⟩:=H.tendsto_subseq (x := fun j => Bj (j+N)) (fun j=>by + simpa only [Metric.mem_closedBall,dist_zero_right] using hN (j+N) (Nat.le_add_left _ _)) + exact ⟨B,fun j=>σ j+N,fun i j hij=>Nat.add_lt_add_right (hσ hij) N,hlim⟩ +end BilinearCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearDet.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..b1246424b9cce8961c372198e4c6bcb672e7a381 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearDet.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearMatrix +import OAI.Analysis.BiholderTransport.Regularity.FunctionalDet + +namespace OAI + +section + +noncomputable section +open Matrix +open scoped MatrixOrder + +namespace WeakMTWTransport +section BilinearDet +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma bilinearMatrix_apply (B:E →L[ℝ] E →L[ℝ] ℝ) (i j:Fin (Module.finrank ℝ E)) : + bilinearMatrix B i j=B (stdOrthonormalBasis ℝ E j) (stdOrthonormalBasis ℝ E i) := by + simp only [bilinearMatrix,LinearMap.toMatrix_apply,OrthonormalBasis.coe_toBasis_repr_apply, + OrthonormalBasis.coe_toBasis,OrthonormalBasis.repr_apply_apply] + change inner ℝ (stdOrthonormalBasis ℝ E i) (bilinearOperator B (stdOrthonormalBasis ℝ E j)) = _ + rw [real_inner_comm,bilinearOperator_inner] + +lemma functional_coords_dot (f:E →L[ℝ] ℝ) (d:E) : + (fun i=>f (stdOrthonormalBasis ℝ E i)) ⬝ᵥ (stdOrthonormalBasis ℝ E).toBasis.equivFun d=f d := by + have H:=congrArg f ((stdOrthonormalBasis ℝ E).toBasis.sum_repr d) + simpa only [map_sum,map_smul,smul_eq_mul,mul_comm,dotProduct,OrthonormalBasis.coe_toBasis, + Module.Basis.equivFun_apply] using H + +lemma bilinearMatrix_symmetric {B:E →L[ℝ] E →L[ℝ] ℝ} (hs:∀d e,B d e=B e d) : + (bilinearMatrix B).IsHermitian := by + ext i j + simp only [Matrix.conjTranspose_apply,star_trivial,bilinearMatrix_apply,hs] + +lemma bilinearMatrix_positive {B:E →L[ℝ] E →L[ℝ] ℝ} + (hs:∀d e,B d e=B e d) (hp:∀d,d≠0 → 0 < B d d) : + (bilinearMatrix B).PosDef := by + refine Matrix.posDef_iff_dotProduct_mulVec.mpr ⟨bilinearMatrix_symmetric hs,?_⟩ + intro v hv + simp only [star_trivial,bilinearMatrix_quad] + apply hp + intro H + apply hv + exact (stdOrthonormalBasis ℝ E).toBasis.equivFun.symm.injective (by simpa only [map_zero] using H) + +lemma bilinearMatrix_le {A B:E →L[ℝ] E →L[ℝ] ℝ} + (ha:∀d e,A d e=A e d) (hb:∀d e,B d e=B e d) + (h:∀d,A d d≤B d d) : bilinearMatrix A≤bilinearMatrix B := by + rw [Matrix.le_iff] + refine Matrix.posSemidef_iff_dotProduct_mulVec.mpr ⟨(bilinearMatrix_symmetric hb).sub + (bilinearMatrix_symmetric ha),?_⟩ + intro d + simpa only [star_trivial,Matrix.sub_mulVec,dotProduct_sub,bilinearMatrix_quad,sub_nonneg] using + h ((stdOrthonormalBasis ℝ E).toBasis.equivFun.symm d) + +lemma bilinearMatrix_rank_add (L:E →L[ℝ] E →L[ℝ] ℝ) (f:E →L[ℝ] ℝ) (m β:ℝ) : + bilinearMatrix (m • L+β • f.smulRight f)=m • bilinearMatrix L+ + β • Matrix.vecMulVec (fun i=>f (stdOrthonormalBasis ℝ E i)) (fun i=>f (stdOrthonormalBasis ℝ E i)) := by + ext i j + simp only [bilinearMatrix_apply,_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,Matrix.add_apply,Matrix.smul_apply,Matrix.vecMulVec_apply] + ring + +lemma bilinear_determinant_gain [Nontrivial E] + {L V W:E →L[ℝ] E →L[ℝ] ℝ} {f g:E →L[ℝ] ℝ} {e:E} {m β γ:ℝ} + (hLs:∀d e,L d e=L e d) (hVs:∀d e,V d e=V e d) (hWs:∀d e,W d e=W e d) + (hker:∀d,L e d=0) (hf:0 < f e) (hg:f e≤g e) + (hm:0 < m) (hβ:0 < β) (hγ:0 < γ) (hV:∀d,d≠0 → 0 < V d d) + (hVL:∀d,V d d≤L d d+β*(f d)^2) + (hLW:∀d,m*L d d+γ*(g d)^2≤W d d) : + γ*m^(Module.finrank ℝ E-1)*(bilinearOperator V).det≤β*(bilinearOperator W).det := by + classical + let b:=(stdOrthonormalBasis ℝ E).toBasis + let : Nonempty (Fin (Module.finrank ℝ E)) := Fin.pos_iff_nonempty.mp (Module.finrank_pos (R:=ℝ)) + have hLe:bilinearOperator L e=0:=by + apply ext_inner_right ℝ + intro d + simp only [bilinearOperator_inner,hker,inner_zero_left] + have hMe:bilinearMatrix L *ᵥ b.equivFun e=0:=by + change (bilinearOperator L).toLinearMap.toMatrix b b *ᵥ b.equivFun e=0 + rw [Module.Basis.equivFun_apply,(bilinearOperator L).toLinearMap.toMatrix_mulVec_repr b b e] + change (fun i => b.repr (bilinearOperator L e) i) = 0 + rw [hLe,map_zero] + rfl + have hfl:=functional_coords_dot f e + have hgl:=functional_coords_dot g e + have hF:∀d e,(L+β • f.smulRight f) d e=(L+β • f.smulRight f) e d:=by + intro d e + simp only [_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,hLs] + ring + have hG:∀d e,(m • L+γ • g.smulRight g) d e=(m • L+γ • g.smulRight g) e d:=by + intro d e + simp only [_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,hLs] + ring + have hVL':bilinearMatrix V≤bilinearMatrix L+β • Matrix.vecMulVec + (fun i=>f (stdOrthonormalBasis ℝ E i)) (fun i=>f (stdOrthonormalBasis ℝ E i)):=by + have H:=bilinearMatrix_le hVs hF (fun d=>by + simpa only [_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,pow_two] using hVL d) + have hr:=bilinearMatrix_rank_add L f 1 β + simp only [one_smul] at hr + rwa [hr] at H + have hLW':m • bilinearMatrix L+γ • Matrix.vecMulVec + (fun i=>g (stdOrthonormalBasis ℝ E i)) (fun i=>g (stdOrthonormalBasis ℝ E i))≤bilinearMatrix W:=by + rw [←bilinearMatrix_rank_add] + apply bilinearMatrix_le hG hWs + intro d + simpa only [_root_.add_apply,_root_.smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,pow_two] using hLW d + have H:=determinant_gain_of_functional_bounds (bilinearMatrix_symmetric hLs) hMe + (by rwa [hfl]) (by rwa [hfl,hgl]) hm hβ hγ (bilinearMatrix_positive hVs hV) hVL' hLW' + simpa only [Fintype.card_fin,bilinearMatrix_det] using H +end BilinearDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearGainLimit.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearGainLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..7350dd72f67ad2384a314760c33bcd0f004a1093 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearGainLimit.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CenterDetCompact + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section BilinearGainLimit +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +local instance gainDualGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance gainDualSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +local instance gainBilinearGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance +local instance gainBilinearSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance + +lemma rankForm_tendsto {f:ℕ → E →L[ℝ] ℝ} {g:E →L[ℝ] ℝ} + (hf:Tendsto f atTop (𝓝 g)) : + Tendsto (fun j=>(f j).smulRight (f j)) atTop (𝓝 (g.smulRight g)) := + (isBoundedBilinearMap_smulRight.continuous.continuousAt.tendsto).comp (hf.prodMk_nhds hf) + +variable [FiniteDimensional ℝ E] + +lemma exists_bilinear_gain_limit {V H G:ℕ → E →L[ℝ] E →L[ℝ] ℝ} + {H₀ G₀:E →L[ℝ] E →L[ℝ] ℝ} {f:ℕ → E →L[ℝ] ℝ} {f₀:E →L[ℝ] ℝ} + {a k b c:ℕ → ℝ} {a₀ k₀ b₀ c₀:ℝ} + (hH:Tendsto H atTop (𝓝 H₀)) (hG:Tendsto G atTop (𝓝 G₀)) + (hf:Tendsto f atTop (𝓝 f₀)) + (ha:Tendsto a atTop (𝓝 a₀)) (hk:Tendsto k atTop (𝓝 k₀)) + (hb:Tendsto b atTop (𝓝 b₀)) (hc:Tendsto c atTop (𝓝 c₀)) (hk0:0H j-b j • G j-c j • (f j).smulRight (f j) + let C₀:=H₀-b₀ • G₀-c₀ • f₀.smulRight f₀ + have hC:Tendsto C atTop (𝓝 C₀):=(hH.sub (hb.smul hG)).sub (hc.smul (rankForm_tendsto hf)) + have Hvc:∀ᶠ j in atTop,(∀d e,V j d e=V j e d) ∧ + (∀d,0≤V j d d) ∧ (∀d,V j d d≤C j d d) ∧ + 0≤a j ∧ k j≤a j*(bilinearOperator (V j)).det:=by + filter_upwards [hV] with j hj + refine ⟨hj.1,hj.2.1,?_,hj.2.2.2⟩ + intro d + have HH:=hj.2.2.1 d + simp only [C,sub_apply,smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul] + nlinarith only [HH] + obtain ⟨V₀,σ,hσ,HV,hVs,hVp,hVC,ha0,hdet⟩:= + exists_center_matrix_limit_variable hC ha hk hk0 Hvc + refine ⟨V₀,σ,hσ,HV,hVs,hVp,?_,ha0,hdet⟩ + intro d + have HH:=hVC d + simp only [C₀,sub_apply,smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul] at HH + nlinarith only [HH] +end BilinearGainLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..b040f9fc392f9c15014e09149493cb01c4258623 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMatrix.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder + +namespace OAI + +section + +noncomputable section +open Set Filter Matrix +open scoped Topology + +namespace WeakMTWTransport +section BilinearMatrix +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +def bilinearMatrix (B:E →L[ℝ] E →L[ℝ] ℝ) : + Matrix (Fin (Module.finrank ℝ E)) (Fin (Module.finrank ℝ E)) ℝ := + (bilinearOperator B).toLinearMap.toMatrix (stdOrthonormalBasis ℝ E).toBasis + (stdOrthonormalBasis ℝ E).toBasis + +lemma bilinearMatrix_det (B:E →L[ℝ] E →L[ℝ] ℝ) : + (bilinearMatrix B).det=(bilinearOperator B).det := by + exact LinearMap.det_toMatrix _ _ + +lemma bilinearMatrix_quad (B:E →L[ℝ] E →L[ℝ] ℝ) + (v:Fin (Module.finrank ℝ E) → ℝ) : + v ⬝ᵥ (bilinearMatrix B *ᵥ v)= + B ((stdOrthonormalBasis ℝ E).toBasis.equivFun.symm v) + ((stdOrthonormalBasis ℝ E).toBasis.equivFun.symm v) := by + let b:=stdOrthonormalBasis ℝ E + let w:=b.toBasis.equivFun.symm v + have hv: (fun i=>b.repr w i)=v:=by + change b.toBasis.equivFun (b.toBasis.equivFun.symm v)=v + exact b.toBasis.equivFun.apply_symm_apply v + have hm:bilinearMatrix B *ᵥ v=(fun i=>b.repr (bilinearOperator B w) i):=by + rw [←hv] + exact (bilinearOperator B).toLinearMap.toMatrix_mulVec_repr b.toBasis b.toBasis w + rw [hm] + nth_rw 1 [←hv] + have H:=b.repr.inner_map_map (bilinearOperator B w) w + rw [bilinearOperator_inner] at H + simpa only [EuclideanSpace.inner_eq_star_dotProduct,star_trivial,dotProduct_comm] using H + +lemma bilinearMatrix_nonneg {B:E →L[ℝ] E →L[ℝ] ℝ} + (hs:∀d e,B d e=B e d) (hp:∀d,0 ≤ B d d) : + (bilinearMatrix B).PosSemidef := by + apply (LinearMap.posSemidef_toMatrix_iff (stdOrthonormalBasis ℝ E)).2 + exact (LinearMap.isPositive_iff _).2 ⟨bilinearOperator_symmetric hs,by + intro d + change 0 ≤ inner ℝ (bilinearOperator B d) d + rw [bilinearOperator_inner] + exact hp d⟩ + +lemma bilinear_positive_of_det_ne_zero {B:E →L[ℝ] E →L[ℝ] ℝ} + (hs:∀d e,B d e=B e d) (hp:∀d,0 ≤ B d d) + (hd:(bilinearOperator B).det≠0) : ∀d,d≠0 → 0 < B d d := by + have HM: (bilinearMatrix B).PosDef:=(bilinearMatrix_nonneg hs hp).posDef_iff_det_ne_zero.mpr + (by rwa [bilinearMatrix_det]) + intro d hd0 + let b:=(stdOrthonormalBasis ℝ E).toBasis + have hv:b.equivFun d≠0:=by + intro H + apply hd0 + exact b.equivFun.injective (by simpa only [map_zero] using H) + have H:=HM.dotProduct_mulVec_pos hv + simpa only [star_trivial,bilinearMatrix_quad,b,LinearEquiv.symm_apply_apply] using H + +lemma bilinear_det_nonneg {B:E →L[ℝ] E →L[ℝ] ℝ} + (hs:∀d e,B d e=B e d) (hp:∀d,0 ≤ B d d) : + 0 ≤ (bilinearOperator B).det := by + rw [←bilinearMatrix_det] + exact (bilinearMatrix_nonneg hs hp).det_nonneg + +lemma bilinearOperator_tendsto {ι:Type*} {l:Filter ι} + {B:ι → E →L[ℝ] E →L[ℝ] ℝ} {B₀:E →L[ℝ] E →L[ℝ] ℝ} + (hB:Tendsto B l (𝓝 B₀)) : + Tendsto (fun i=>bilinearOperator (B i)) l (𝓝 (bilinearOperator B₀)) := by + have hc:Continuous (fun B:E →L[ℝ] E →L[ℝ] ℝ=>bilinearOperator B):= + continuous_const.clm_comp continuous_id + exact hc.continuousAt.tendsto.comp hB + +lemma bilinear_det_tendsto {ι:Type*} {l:Filter ι} + {B:ι → E →L[ℝ] E →L[ℝ] ℝ} {B₀:E →L[ℝ] E →L[ℝ] ℝ} + (hB:Tendsto B l (𝓝 B₀)) : + Tendsto (fun i=>(bilinearOperator (B i)).det) l (𝓝 (bilinearOperator B₀).det) := by + exact ContinuousLinearMap.continuous_det.continuousAt.tendsto.comp (bilinearOperator_tendsto hB) + +end BilinearMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMetricSpeedSquare.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMetricSpeedSquare.lean new file mode 100644 index 0000000000000000000000000000000000000000..a5372dd656dec7cb8aecc6213b748b9b95fbe47b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BilinearMetricSpeedSquare.lean @@ -0,0 +1,99 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +lemma bilinear_metric_speed_of_square {g : E →L[ℝ] E →L[ℝ] ℝ} + {f : ℝ → E} {a k : ℝ} (hf : ContDiffAt ℝ ∞ f a) (h0 : f a = 0) + (he : (fun t => g (f t) (f t)) =ᶠ[𝓝 a] (fun t => k*(t-a)^2)) : + g (deriv f a) (deriv f a) = k := by + have hfd : ∀ᶠ t in 𝓝 a, DifferentiableAt ℝ f t := ((hf.of_le (by simp : (1 : ℕ∞ω) ≤ (∞ : ℕ∞ω))).eventually (by simp)).mono + (fun _ ht => ht.differentiableAt (by norm_num)) + have hde : (fun t => g (f t) (deriv f t) + g (deriv f t) (f t)) =ᶠ[𝓝 a] + (fun t => 2*k*(t-a)) := by + filter_upwards [hfd,he.eventuallyEq_nhds] with t ht heq + have h₁ := ((g.hasFDerivAt.comp_hasDerivAt t ht.hasDerivAt).clm_apply ht.hasDerivAt) + have h₂ := ((((hasDerivAt_id t).sub_const a).pow 2).const_mul k) + have hh := (h₁.congr_of_eventuallyEq heq.symm).unique h₂ + norm_num only [Function.comp_apply, Nat.reduceSub, pow_one, id_eq, mul_one, Nat.cast_ofNat] at hh + linarith + have hd : HasDerivAt (deriv f) (deriv (deriv f) a) a := + ((hf.derivWithin (m := ∞) (by simp)).differentiableAt (by simp)).hasDerivAt + have hf' := (hf.differentiableAt (by simp)).hasDerivAt + have h₁ := ((g.hasFDerivAt.comp_hasDerivAt a hf').clm_apply hd).add + ((g.hasFDerivAt.comp_hasDerivAt a hd).clm_apply hf') + have h₂ := (((hasDerivAt_id a).sub_const a).const_mul (2*k)) + have hh := (h₁.congr_of_eventuallyEq hde.symm).unique h₂ + simp only [Function.comp_apply,h0,map_zero,zero_apply,add_zero,zero_add,mul_one] at hh + linarith +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchDividedBaseline.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchDividedBaseline.lean new file mode 100644 index 0000000000000000000000000000000000000000..d97d791e6401b9d5217aa74260a8b0a2a8d8bb53 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchDividedBaseline.lean @@ -0,0 +1,72 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.BranchJets +import OAI.Analysis.BiholderTransport.LinearAlgebra.PositiveBilinearBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section BranchDividedBaseline +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma cost_branch_hessian_inward_limit {a:M} {r : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈minimizingVectors a) {G : M×M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (a,riemannianExp a r)) + (hagree : ∀ᶠ z in 𝓝 (⟨a,r⟩ : TangentBundle 𝓘(ℝ,Model n) M), + z.2∈injectivityDomain z.1 → + (fun q:M×M => cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) + (ξ : TangentSpace 𝓘(ℝ,Model n) a) : + Tendsto (fun s:ℝ => hessianValue a (s • r) ξ/s) (𝓝[<] 1) + (𝓝 (fderiv ℝ (fderiv ℝ (fun w => G (riemannianExp a w,riemannianExp a r))) 0 ξ ξ)) := by + have H := cost_branch_normal_jets (r := r) (T := (1:ℝ)) (by norm_num) + (by simpa only [one_smul] using hG) (by simpa only [one_smul] using hagree) + (fun s hs => contracted_minimizer_mem_injectivityDomain hr hs.1 hs.2) + have HH := (H.2.2 ξ).div (tendsto_id.mono_left nhdsWithin_le_nhds) (by norm_num : (1:ℝ)≠0) + change Tendsto (fun s:ℝ => hessianValue a (s • r) ξ/s) (𝓝[<] 1) + (𝓝 ((fderiv ℝ (fderiv ℝ (fun w => G (riemannianExp a w,riemannianExp a ((1:ℝ) • r))))) 0 ξ ξ / 1)) at HH + simpa only [one_smul,div_one] using HH + +lemma exists_branch_divided_baseline {a:M} {r : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈minimizingVectors a) {t:ℝ} (ht : 0 < t) (ht1 : t < 1) + {G : M×M → ℝ} + (hG : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (a,riemannianExp a r)) + (hagree : ∀ᶠ z in 𝓝 (⟨a,r⟩ : TangentBundle 𝓘(ℝ,Model n) M), + z.2∈injectivityDomain z.1 → + (fun q:M×M => cost q.1 q.2) =ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) : + ∃ m>0,∀ ξ:TangentSpace 𝓘(ℝ,Model n) a, + m*‖ξ‖^2 ≤ hessianValue a (t • r) ξ/t- + fderiv ℝ (fderiv ℝ (fun w => G (riemannianExp a w,riemannianExp a r))) 0 ξ ξ := by + let s0 := (t+1)/2 + have hts : t < s0 := by dsimp [s0]; linarith + have hs0 : s0 < 1 := by dsimp [s0]; linarith + obtain ⟨m,hm,Hm⟩ := exists_divided_hessian_baseline hr ht hts hs0 + refine ⟨m,hm,?_⟩ + intro ξ + have H := ((tendsto_const_nhds (x := hessianValue a (t • r) ξ/t)).sub (cost_branch_hessian_inward_limit hr hG hagree ξ)) + apply ge_of_tendsto H + filter_upwards [(eventually_gt_nhds hs0).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with s hs hs1 + exact Hm s hs.le hs1 ξ + +end BranchDividedBaseline +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..718eef1bbae632f7b1639af9e1456467f67b269f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/BranchHessian.lean @@ -0,0 +1,214 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.TransverseConcavity +import OAI.Analysis.BiholderTransport.Regularity.ContDiffUncurryIterated +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_smooth_hessian_branch {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + ∃ A : TangentSpace 𝓘(ℝ,Model n) x → ℝ, ContDiffAt ℝ ∞ A p ∧ + ∀ᶠ w in 𝓝 p, w ∈ injectivityDomain x → hessianValue x w xi=A w := by + let V := TangentSpace 𝓘(ℝ,Model n) x + obtain ⟨G,hG,hagree⟩ := exists_smooth_cost_branch (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + let A : V → ℝ := fun w => iteratedDeriv 2 (fun s : ℝ => G (riemannianExp x (s • xi),riemannianExp x w)) 0 + have hG' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (riemannianExp x ((0:ℝ) • xi),riemannianExp x p) := by + simpa only [zero_smul,riemannianExp_zero] using hG + have hLs : ContMDiffAt 𝓘(ℝ,V×ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : V×ℝ => riemannianExp x (q.2 • xi)) (p,0) := + (contMDiff_riemannianExp_fiber x _).comp (p,0) (contDiffAt_snd.smul contDiffAt_const).contMDiffAt + have hLw : ContMDiffAt 𝓘(ℝ,V×ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : V×ℝ => riemannianExp x q.1) (p,0) := + (contMDiff_riemannianExp_fiber x _).comp (p,0) contDiffAt_fst.contMDiffAt + have hGA : ContDiffAt ℝ ∞ (fun q : V×ℝ => G (riemannianExp x (q.2 • xi),riemannianExp x q.1)) (p,0) := + (hG'.comp (p,0) (hLs.prodMk hLw)).contDiffAt + refine ⟨A,contDiffAt_iteratedDeriv_parameter hGA 2,?_⟩ + have hinc : Continuous (fun w : V => (⟨x,w⟩ : TangentBundle 𝓘(ℝ,Model n) M)) := + FiberBundle.continuous_totalSpaceMk (Model n) (fun y : M => TangentSpace 𝓘(ℝ,Model n) y) x + filter_upwards [hinc.continuousAt.eventually hagree] with w hw + intro hwID + have hcost := hw hwID + have hcurve : ContinuousAt (fun s : ℝ => (riemannianExp x (s • xi),riemannianExp x w)) 0 := + ((contMDiff_riemannianExp_fiber x).continuous.continuousAt.comp + (show ContinuousAt (fun s : ℝ => s • xi) 0 from by fun_prop)).prodMk continuousAt_const + have hcurve' : Tendsto (fun s : ℝ => (riemannianExp x (s • xi),riemannianExp x w)) (𝓝 0) + (𝓝 (x,riemannianExp x w)) := by simpa only [zero_smul,riemannianExp_zero] using hcurve.tendsto + exact Filter.EventuallyEq.iteratedDeriv_eq 2 (hcost.comp_tendsto hcurve') + +lemma nonconjugate_inward_hessian_bounded {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) + (hreg : Function.Injective (fderiv ℝ (fun v => extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p)) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + ∃ C : ℝ, ∀ᶠ r : ℝ in 𝓝[<] 1, |hessianValue x (r • p) xi|≤C := by + obtain ⟨A,hA,hagree⟩ := exists_smooth_hessian_branch hreg xi + have hline : Tendsto (fun r : ℝ => r • p) (𝓝[<] 1) (𝓝 p) := by + simpa only [one_smul] using + (show ContinuousAt (fun r : ℝ => r • p) 1 from by fun_prop).tendsto.mono_left nhdsWithin_le_nhds + have hb := ((hA.continuousAt.abs.tendsto).comp hline).eventually_lt_const (show |A p| < |A p|+1 by linarith) + refine ⟨|A p|+1,?_⟩ + filter_upwards [hline.eventually hagree,hb, + (eventually_gt_nhds (show (0:ℝ)<1 by norm_num)).filter_mono nhdsWithin_le_nhds, + self_mem_nhdsWithin] with r hr hrB hr0 hr1 + rw [hr (contracted_minimizer_mem_injectivityDomain hp hr0 hr1)] + exact hrB.le +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/C11HessianLimits.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/C11HessianLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..e732fb351bc62c77c8f57f6e22e4f687e87b7dba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/C11HessianLimits.lean @@ -0,0 +1,74 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Metric +open scoped Topology NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma exists_C11_hessian_limit_samples {f g : E → ℝ} {S : Set E} + (hS : IsOpen S) {x0 : E} {Lf Lg : ℝ≥0} + (hf : LipschitzOnWith Lf (fderiv ℝ f) S) + (hg : LipschitzOnWith Lg (fderiv ℝ g) S) {P : E → Prop} + (hselect : ∀ rho eta : ℝ, 0 < rho → 0 < eta → ∃ z∈S, + dist z x0 < rho ∧ P z ∧ ‖fderiv ℝ f z+fderiv ℝ g z‖≤eta ∧ + ∀ e:E, fderiv ℝ (fderiv ℝ f) z e e+fderiv ℝ (fderiv ℝ g) z e e≤eta*‖e‖^2) : + ∃ z : ℕ → E, ∃ A B : E →L[ℝ] E →L[ℝ] ℝ, + (∀ i,z i∈S ∧ P (z i)) ∧ Tendsto z atTop (𝓝 x0) ∧ + Tendsto (fun i => fderiv ℝ (fderiv ℝ f) (z i)) atTop (𝓝 A) ∧ + Tendsto (fun i => fderiv ℝ (fderiv ℝ g) (z i)) atTop (𝓝 B) ∧ + Tendsto (fun i => fderiv ℝ f (z i)+fderiv ℝ g (z i)) atTop (𝓝 0) ∧ + ∀ e:E,A e e+B e e≤0 := by + let : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let eps := fun i:ℕ => 1/((i:ℝ)+1) + have heps : ∀ i,0 < eps i := fun i => by dsimp [eps]; positivity + have heps0 : Tendsto eps atTop (𝓝 (0:ℝ)) := tendsto_one_div_add_atTop_nhds_zero_nat + choose z hzS hdist hzP hgrad hquad using fun i => hselect (eps i) (eps i) (heps i) (heps i) + let A := fun i => fderiv ℝ (fderiv ℝ f) (z i) + let B := fun i => fderiv ℝ (fderiv ℝ g) (z i) + have hA : ∀ i,‖A i‖≤Lf := fun i => norm_fderiv_le_of_lipschitzOn ℝ (hS.mem_nhds (hzS i)) hf + have hB : ∀ i,‖B i‖≤Lg := fun i => norm_fderiv_le_of_lipschitzOn ℝ (hS.mem_nhds (hzS i)) hg + have hcompact : IsCompact ((closedBall (0 : E →L[ℝ] E →L[ℝ] ℝ) (Lf:ℝ)).prod + (closedBall (0 : E →L[ℝ] E →L[ℝ] ℝ) (Lg:ℝ))) := (isCompact_closedBall (0 : E →L[ℝ] E →L[ℝ] ℝ) (Lf:ℝ)).prod + (isCompact_closedBall (0 : E →L[ℝ] E →L[ℝ] ℝ) (Lg:ℝ)) + obtain ⟨AB,hAB,σ,hσ,hlim⟩ := hcompact.tendsto_subseq (x := fun i => (A i,B i)) + (fun i => by + change dist (A i) 0≤(Lf:ℝ) ∧ dist (B i) 0≤(Lg:ℝ) + simpa only [dist_zero_right] using And.intro (hA i) (hB i)) + have hzlim : Tendsto z atTop (𝓝 x0) := by + apply Metric.tendsto_nhds.mpr + intro ε hε + filter_upwards [(tendsto_order.mp heps0).2 ε hε] with i hi + exact (hdist i).trans hi + have hgradlim : Tendsto (fun i => fderiv ℝ f (z i)+fderiv ℝ g (z i)) atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + exact squeeze_zero (fun _ => norm_nonneg _) hgrad heps0 + have hlimA : Tendsto (fun i => A (σ i)) atTop (𝓝 AB.1) := by + simpa only [Function.comp_def] using (continuous_fst.tendsto AB).comp hlim + have hlimB : Tendsto (fun i => B (σ i)) atTop (𝓝 AB.2) := by + simpa only [Function.comp_def] using (continuous_snd.tendsto AB).comp hlim + refine ⟨z ∘ σ,AB.1,AB.2,fun i => ⟨hzS (σ i),hzP (σ i)⟩, + hzlim.comp hσ.tendsto_atTop,hlimA,hlimB,hgradlim.comp hσ.tendsto_atTop,?_⟩ + intro e + have heval : Continuous (fun J : E →L[ℝ] E →L[ℝ] ℝ => J e e) := + (continuous_id.clm_apply (continuous_const (y := e))).clm_apply (continuous_const (y := e)) + have ha : Tendsto (fun i => A (σ i) e e) atTop (𝓝 (AB.1 e e)) := by + simpa only [Function.comp_def] using (heval.tendsto AB.1).comp hlimA + have hb : Tendsto (fun i => B (σ i) e e) atTop (𝓝 (AB.2 e e)) := by + simpa only [Function.comp_def] using (heval.tendsto AB.2).comp hlimB + have he : Tendsto (fun i => eps (σ i)*‖e‖^2) atTop (𝓝 (0:ℝ)) := by + simpa only [zero_mul,Function.comp_def] using (heps0.comp hσ.tendsto_atTop).mul_const (‖e‖^2) + exact le_of_tendsto_of_tendsto (ha.add hb) he (Filter.Eventually.of_forall (fun i => hquad (σ i) e)) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Calculus.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Calculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..c0c8d1e9649472bcca7da358ff9b194f68e19438 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Calculus.lean @@ -0,0 +1,69 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma first_order_remainder_le_of_hessian_bound {f : E → ℝ} {S : Set E} + (hS : Convex ℝ S) {B : ℝ} (hB : 0≤B) + (hf : ∀ z∈S, ContDiffAt ℝ 2 f z) + (hbound : ∀ z∈S, ‖fderiv ℝ (fderiv ℝ f) z‖≤B) + {x y : E} (hx : x∈S) (hy : y∈S) : + |f y-f x-fderiv ℝ f x (y-x)|≤B*‖y-x‖^2 := by + have hD : ∀ z∈S, HasFDerivAt (fderiv ℝ f) (fderiv ℝ (fderiv ℝ f) z) z := by + intro z hz + exact ((hf z hz).fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) |>.hasFDerivAt + have hLip : ∀ z∈S, ‖fderiv ℝ f z-fderiv ℝ f x‖≤B*‖z-x‖ := by + intro z hz + exact hS.norm_image_sub_le_of_norm_hasFDerivWithin_le + (fun w hw => (hD w hw).hasFDerivWithinAt) hbound hx hz + let R := fun z => f z-f x-fderiv ℝ f x (z-x) + have hR : ∀ z∈S, HasFDerivAt R (fderiv ℝ f z-fderiv ℝ f x) z := by + intro z hz + exact ((hf z hz).differentiableAt (by norm_num)).hasFDerivAt.sub_const (f x) |>.sub + ((fderiv ℝ f x).hasFDerivAt.comp z ((hasFDerivAt_id z).sub_const x)) + have hseg : segment ℝ x y ⊆ S := hS.segment_subset hx hy + have hn : ∀ z∈segment ℝ x y, ‖z-x‖≤‖y-x‖ := by + intro z hz + simpa only [Metric.mem_closedBall,dist_eq_norm] using + (show segment ℝ x y ⊆ Metric.closedBall x ‖y-x‖ from + (convex_closedBall x ‖y-x‖).segment_subset + (Metric.mem_closedBall_self (norm_nonneg _)) (by simp only [Metric.mem_closedBall,dist_eq_norm,le_refl])) hz + have H := (convex_segment x y).norm_image_sub_le_of_norm_hasFDerivWithin_le + (fun z hz => (hR z (hseg hz)).hasFDerivWithinAt) + (show ∀ z∈segment ℝ x y, ‖fderiv ℝ f z-fderiv ℝ f x‖≤B*‖y-x‖ from by + intro z hz + exact (hLip z (hseg hz)).trans (mul_le_mul_of_nonneg_left (hn z hz) hB)) + (left_mem_segment ℝ x y) (right_mem_segment ℝ x y) + simpa only [R,sub_self,map_zero,sub_zero,Real.norm_eq_abs,pow_two,mul_assoc] using H + +lemma convexOn_of_affine_lower_supports {f : E → ℝ} {S : Set E} + (hS : Convex ℝ S) + (hs : ∀ x∈S, ∃ L : E →L[ℝ] ℝ, ∀ y∈S, f x+L (y-x)≤f y) : + ConvexOn ℝ S f := by + refine ⟨hS,?_⟩ + intro x hx y hy a b ha hb hab + let z := a • x+b • y + obtain ⟨L,hL⟩ := hs z (hS hx hy ha hb hab) + have hx' := mul_le_mul_of_nonneg_left (hL x hx) ha + have hy' := mul_le_mul_of_nonneg_left (hL y hy) hb + have hzero : a*L (x-z)+b*L (y-z)=0 := by + rw [←smul_eq_mul a,←smul_eq_mul b,←map_smul,←map_smul,←map_add] + have he : a • (x-z)+b • (y-z)=0 := by + rw [smul_sub,smul_sub,←add_sub_add_comm,←add_smul,hab,one_smul] + exact sub_self z + rw [he,map_zero] + change f z≤a*f x+b*f y + have hc : a*f z+b*f z=f z := by rw [←add_mul,hab,one_mul] + nlinarith [hc] + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartFirstMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartFirstMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..9028bd85460fbbc3d1fd6d23440d1737bf675b4e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartFirstMatrix.lean @@ -0,0 +1,199 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.FirstMatrixLimit +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateMatrices +import OAI.Analysis.BiholderTransport.Coordinates.ChartActiveLimit + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure ChartFixedPrefixLimit (a : M) (v G : M → ℝ) (t : ℝ) + (q : ℕ → subgradientGraph (n := n) (cTransform v)) + (q₀ : subgradientGraph (n := n) (cTransform v)) where + σ : ℕ → ℕ + strictMono : StrictMono σ + pj : ℕ → Fin (Module.finrank ℝ (Model n)+1) → Model n + w : ℕ → Fin (Module.finrank ℝ (Model n)+1) → ℝ + pj₀ : Fin (Module.finrank ℝ (Model n)+1) → Model n + w₀ : Fin (Module.finrank ℝ (Model n)+1) → ℝ + H : Model n →L[ℝ] Model n →L[ℝ] ℝ + L : Model n →L[ℝ] Model n →L[ℝ] ℝ + activeLimit : ∀ i,chartFiberInverse a (graphBaseCoordinate a q₀.1) (pj₀ i)∈ + activeLogs v ((extChartAt 𝓘(ℝ,Model n) a).symm (graphBaseCoordinate a q₀.1)) + nonnegLimit : ∀ i,0≤w₀ i + totalLimit : ∑ i,w₀ i=1 + baryLimit : ∑ i,w₀ i • pj₀ i=graphVelocityCoordinate a q₀.1 + pjLimit : Tendsto pj atTop (𝓝 pj₀) + wLimit : Tendsto w atTop (𝓝 w₀) + HLimit : Tendsto (fun k=>coordinateCenterMatrix a t G + (graphBaseCoordinate a (q (σ k)).1) + (graphVelocityCoordinate a (q (σ k)).1)) atTop (𝓝 H) + LLimit : Tendsto (fun k=>coordinatePoleMatrix a t v + (graphBaseCoordinate a (q (σ k)).1) + (graphVelocityCoordinate a (q (σ k)).1)) atTop (𝓝 L) + positive : ∀ d:Model n,0≤L d d + symmetric : ∀ d e:Model n,L d e=L e d + kernel : ∀ i,∀ d:Model n,L (pj₀ i-graphVelocityCoordinate a q₀.1) d=0 + upper : ∀ d:Model n,H d d≤L d d + samples : ∀ᶠ k in atTop, + let b := graphBaseCoordinate a (q (σ k)).1 + let p := graphVelocityCoordinate a (q (σ k)).1 + let A := chartFiberInverse a b + (∀ i,0≤w k i) ∧ (∑ i,w k i=1) ∧ (∑ i,w k i • pj k i=p) ∧ + (∀ i,A (pj k i)∈activeLogs v ((extChartAt 𝓘(ℝ,Model n) a).symm b)) ∧ + (∀ i,0v (movingNormal a (b,pj k i+r))+‖A (pj k i+r)‖^2/2) 0 + (w k i • coordinatePoleMatrix a t v b p)) + +lemma WeakMTW.first_fixed_prefix_limit_in_chart + (hmtw : WeakMTW (n := n) (M := M)) {v G : M → ℝ} (hv : Continuous v) + {t : ℝ} (ht : 0graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀))) + {a c d : M} + (ha0 : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hc : graphProjection (cTransform v) t q₀∈(extChartAt 𝓘(ℝ,Model n) c).source) + (hd : q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) d).source) : + let χ := extChartAt 𝓘(ℝ,Model n) c + let F := fun z:Model n=>hopfLax t (cTransform v) (χ.symm z) + let C := fun z:Model n=>G (χ.symm z) + let z := fun k=>χ (graphProjection (cTransform v) t (q k)) + let z₀ := χ (graphProjection (cTransform v) t q₀) + ∀ Af Ac : Model n →L[ℝ] Model n →L[ℝ] ℝ, + ContinuousAt (fderiv ℝ F) z₀ → ContinuousAt (fderiv ℝ C) z₀ → + (∀ᶠ z in 𝓝 z₀,DifferentiableAt ℝ F z ∧ DifferentiableAt ℝ C z) → + Tendsto (fun k=>fderiv ℝ (fderiv ℝ F) (z k)) atTop (𝓝 Af) → + Tendsto (fun k=>fderiv ℝ (fderiv ℝ C) (z k)) atTop (𝓝 Ac) → + Tendsto (fun k=>fderiv ℝ F (z k)+fderiv ℝ C (z k)) atTop (𝓝 0) → + (∀ r:Model n,Af r r+Ac r r≤0) → + (∀ᶠ k in atTop,DifferentiableAt ℝ (fderiv ℝ F) (z k) ∧ + DifferentiableAt ℝ (fderiv ℝ C) (z k) ∧ DifferentiableAt ℝ + (fun w:Model n=>extChartAt 𝓘(ℝ,Model n) d + (hopfPole (n := n) t (cTransform v) (χ.symm w))) (z k)) → + Nonempty (ChartFixedPrefixLimit a v G t q q₀) := by + dsimp only + intro Af Ac hF hC hnear hAf hAc herr hquad hsample + let χ := extChartAt 𝓘(ℝ,Model n) c + let F := fun z:Model n=>hopfLax t (cTransform v) (χ.symm z) + let C := fun z:Model n=>G (χ.symm z) + let z := fun k=>χ (graphProjection (cTransform v) t (q k)) + let z₀ := χ (graphProjection (cTransform v) t q₀) + have hzCoord : Tendsto z atTop (𝓝 z₀) := + ((continuousOn_extChartAt _).continuousAt ((isOpen_extChartAt_source _).mem_nhds hc)).tendsto.comp hz + have hjF := hF.tendsto.comp hzCoord + have hjC := hC.tendsto.comp hzCoord + have hgrad : fderiv ℝ F z₀+fderiv ℝ C z₀=0 := tendsto_nhds_unique (hjF.add hjC) herr + obtain ⟨K,hK,hKs,pj,w,pj₀,w₀,σ,hσ,hs,hpj,hw,ha,hn,h1,hbar⟩ := + hmtw.active_barycentric_tail_limit_in_chart hv ht ht1 q q₀ hz ha0 + let b := fun k=>graphBaseCoordinate a (q (σ k)).1 + let p := fun k=>graphVelocityCoordinate a (q (σ k)).1 + let b₀ := graphBaseCoordinate a q₀.1 + let p₀ := graphVelocityCoordinate a q₀.1 + have hq := hmtw.graph_points_tendsto hv ht ht1 (hz.comp hσ.tendsto_atTop) + have hbase := (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto q₀.1 |>.comp hq + have hbsource : ∀ᶠ k in atTop,(q (σ k)).1.1∈(extChartAt 𝓘(ℝ,Model n) a).source := + hbase.eventually ((isOpen_extChartAt_source _).mem_nhds ha0) + have hdsource : ∀ᶠ k in atTop,(q (σ k)).1.1∈(extChartAt 𝓘(ℝ,Model n) d).source := + hbase.eventually ((isOpen_extChartAt_source _).mem_nhds hd) + have hzsource : ∀ᶠ k in atTop,graphProjection (cTransform v) t (q (σ k))∈χ.source := + (hz.comp hσ.tendsto_atTop).eventually ((isOpen_extChartAt_source _).mem_nhds hc) + obtain ⟨hb,hp⟩ := hmtw.graph_coordinate_limit_in_chart hv ht ht1 (hz.comp hσ.tendsto_atTop) ha0 + have hb₀ : b₀∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source ha0 + have hp₀ : t • chartFiberInverse a b₀ p₀∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b₀) := by + exact + hmtw.graphCoordinate_prefix_regular hv ht ht1 q₀ ha0 + have he₀ : movingPrefix a t b₀ p₀=graphProjection (cTransform v) t q₀ := by + exact + movingPrefix_graph_coordinates ha0 t (q := q₀.1) + have hg := movingPrefixChart_contDiffAt hb₀ (he₀ ▸ hc) + have henergy := movingPrefixEnergy_contDiffAt hb₀ hp₀ + have he : ∀ᶠ k in atTop,movingPrefix a t (b k) (p k)= + graphProjection (cTransform v) t (q (σ k)) := + hbsource.mono (fun k hk=>movingPrefix_graph_coordinates hk t) + have hzEq : ∀ᶠ k in atTop,movingPrefixChart a c t (b k) (p k)=z (σ k) := + he.mono (fun k hk=>congrArg χ hk) + have hM : ∀ᶠ k in atTop, + (∀ r:Model n,0≤coordinatePoleMatrix a t v (b k) (p k) r r) ∧ + (∀ r s:Model n,coordinatePoleMatrix a t v (b k) (p k) r s= + coordinatePoleMatrix a t v (b k) (p k) s r) ∧ + (∀ i,∀ r:Model n,coordinatePoleMatrix a t v (b k) (p k) (pj k i-p k) r=0) ∧ + (∀ i,chartFiberInverse a (b k) (pj k i)∈ + activeLogs v ((extChartAt 𝓘(ℝ,Model n) a).symm (b k))) ∧ + (∀ i,0v (movingNormal a (b k,pj k i+r))+ + ‖chartFiberInverse a (b k) (pj k i+r)‖^2/2) 0 + (w k i • coordinatePoleMatrix a t v (b k) (p k))) := by + filter_upwards [hbsource,hdsource,hzsource,he,hzEq,hσ.tendsto_atTop.eventually hsample] + with k hbk hdk hzk hek hzEk hsk + have hbtk := (extChartAt 𝓘(ℝ,Model n) a).map_source hbk + have hba : (extChartAt 𝓘(ℝ,Model n) a).symm (b k)=(q (σ k)).1.1 := + (extChartAt 𝓘(ℝ,Model n) a).left_inv hbk + have hact : ∀ i,chartFiberInverse a (b k) (pj k i)∈ + activeLogs v ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)) := + fun i=>(mem_active_coordinates hKs ((hs k).1 i)).2.1 + obtain ⟨hpos,hsym,hker,hjet⟩ := hmtw.coordinate_sample_pole_matrix hv ht ht1 hbtk + (graphCoordinate_normalSubdifferential (q (σ k)) hbk) (hek ▸ hzk) (hba ▸ hdk) + (show DifferentiableAt ℝ _ (movingPrefixChart a c t (b k) (p k)) from hzEk ▸ hsk.2.2) + exact ⟨hpos,hsym,fun i=>hker (pj k i) (hact i),hact, + fun i hi=>hjet _ (pj k) (w k) (hs k).2.1 (hs k).2.2.1 (hs k).2.2.2 hact i hi⟩ + have hL_eq : ∀ᶠ k in atTop,coordinatePoleMatrix a t v (b k) (p k)= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun r=>F (movingPrefixChart a c t (b k) r))) (p k) := by + filter_upwards [hbsource,hzsource,he] with k hbk hzk hek + exact coordinatePoleMatrix_chart ((extChartAt 𝓘(ℝ,Model n) a).map_source hbk) (hek ▸ hzk) + have hH_eq : ∀ᶠ k in atTop,coordinateCenterMatrix a t G (b k) (p k)= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t (b k))) (p k)+ + fderiv ℝ (fderiv ℝ (fun r=>C (movingPrefixChart a c t (b k) r))) (p k) := by + filter_upwards [hbsource,hzsource,he] with k hbk hzk hek + exact coordinateCenterMatrix_chart ((extChartAt 𝓘(ℝ,Model n) a).map_source hbk) (hek ▸ hzk) + have hDz : ∀ᶠ k in atTop, + (∀ᶠ y in 𝓝 (movingPrefixChart a c t (b k) (p k)),DifferentiableAt ℝ F y ∧ DifferentiableAt ℝ C y) ∧ + DifferentiableAt ℝ (fderiv ℝ F) (movingPrefixChart a c t (b k) (p k)) ∧ + DifferentiableAt ℝ (fderiv ℝ C) (movingPrefixChart a c t (b k) (p k)) := by + filter_upwards [(hzCoord.comp hσ.tendsto_atTop).eventually (eventually_eventually_nhds.mpr hnear), + hσ.tendsto_atTop.eventually hsample,hzEq] with k hnk hsk hek + rw [hek] + exact ⟨hnk,hsk.1,hsk.2.1⟩ + have hpos : ∀ᶠ k in atTop,∀ r:Model n, + 0≤(fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun r=>F (movingPrefixChart a c t (b k) r))) (p k)) r r := by + filter_upwards [hM,hL_eq] with k hk he; rw [←he]; exact hk.1 + have hker : ∀ᶠ k in atTop,∀ i,∀ r:Model n, + (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun r=>F (movingPrefixChart a c t (b k) r))) (p k)) (pj k i-p k) r=0 := by + filter_upwards [hM,hL_eq] with k hk he; rw [←he]; exact hk.2.2.1 + obtain ⟨H,L,hH,hL,hpositive,hkernel,hupper⟩ := first_fixed_prefix_matrix_limit + henergy hg hb hp (fun i=>tendsto_pi_nhds.mp hpj i) + ((hjF.comp hσ.tendsto_atTop).congr' (hzEq.mono (fun k hk=>congrArg (fderiv ℝ F) hk.symm))) + ((hjC.comp hσ.tendsto_atTop).congr' (hzEq.mono (fun k hk=>congrArg (fderiv ℝ C) hk.symm))) + ((hAf.comp hσ.tendsto_atTop).congr' (hzEq.mono (fun k hk=>congrArg (fderiv ℝ (fderiv ℝ F)) hk.symm))) + ((hAc.comp hσ.tendsto_atTop).congr' (hzEq.mono (fun k hk=>congrArg (fderiv ℝ (fderiv ℝ C)) hk.symm))) + (hDz.mono (fun k hk=>⟨hk.1.mono (fun y hy=>hy.1),hk.2.1⟩)) + (hDz.mono (fun k hk=>⟨hk.1.mono (fun y hy=>hy.2),hk.2.2⟩)) hgrad hquad hpos hker + have hH' := hH.congr' (hH_eq.mono (fun k hk=>hk.symm)) + have hL' := hL.congr' (hL_eq.mono (fun k hk=>hk.symm)) + refine ⟨⟨σ,hσ,pj,w,pj₀,w₀,H,L,(fun i=>(mem_active_coordinates hKs (ha i)).2.1),hn,h1,hbar,hpj,hw,hH',hL',hpositive, + fun r s=>bilinear_limit_symm hL' (hM.mono (fun k hk=>hk.2.1)) r s,?_,hupper,?_⟩⟩ + · exact hkernel + · filter_upwards [hM] with k hk + exact ⟨(hs k).2.1,(hs k).2.2.1,(hs k).2.2.2,hk.2.2.2.1,hk.2.2.2.2⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartOuterMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartOuterMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..33c7b9dfc6728f1b7fe27cbe22ea292fb9d741a6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartOuterMatrix.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FrameMetric +import OAI.Analysis.BiholderTransport.LinearAlgebra.OuterActiveMatrix + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section ChartOuterMatrix +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance chartOuterFinite (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance chartOuterComplete (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +lemma WeakMTW.exists_uniform_chart_outer_matrix + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) : + ∃K>0,∀ (x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)) (φ:ℝ → ℝ), + uv∈densityDualClass (metricVolume n) lam cap x0 → Continuous φ → StrictMono φ → + ∀ (a:M) (b p:Model n),b∈(extChartAt 𝓘(ℝ,Model n) a).target → + let z:TangentBundle 𝓘(ℝ,Model n) M:=⟨(extChartAt 𝓘(ℝ,Model n) a).symm b,chartFiberInverse a b p⟩ + ∀ l:ℝ,z.2∈activeLogs (φ ∘ uv.2) z.1 → + ContDiffAt ℝ 2 φ (uv.2 (riemannianExp z.1 z.2)) → + HasDerivAt φ l (uv.2 (riemannianExp z.1 z.2)) → 1 < l → + iteratedDeriv 2 φ (uv.2 (riemannianExp z.1 z.2)) ≤ 0 → + ∀ B:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,B d e=B e d) → (∀d,0 ≤ B d d) → + HasLowerSecondTaylor (fun d=>φ (uv.2 (movingNormal a (b,p+d)))+ + ‖chartFiberInverse a b (p+d)‖^2/2) 0 B → + ∃V:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,B d d-(iteratedDeriv 2 φ (uv.2 (riemannianExp z.1 z.2))/l^2)* + (frameMetric a b p d)^2 ≤ inner ℝ (V d) d) ∧ + 0 < expJacobian (n:=n) z.1 z.2 ∧ + 0 < expJacobian (n:=n) (reverseRay z).1 (l⁻¹ • (reverseRay z).2) ∧ + expJacobian (n:=n) (reverseRay z).1 (l⁻¹ • (reverseRay z).2)*V.det ≤ + (chartFiberInverse a b).toLinearMap.normDet^2*l^n*K*(expJacobian (n:=n) z.1 z.2)^2 := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_active_outer_matrix hlam hcap + refine ⟨K,hK,?_⟩ + intro x0 uv φ huv hφ hm a b p hb z l ha hφ2 hd hl hconc B hBs hB hjet + let x:M:=(extChartAt 𝓘(ℝ,Model n) a).symm b + let T:=trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + have hx:x∈T.baseSet:=by + simpa only [x,T,TangentBundle.trivializationAt_baseSet,extChartAt_source] using + (extChartAt 𝓘(ℝ,Model n) a).map_target hb + let e:=T.continuousLinearEquivAt ℝ x hx + let A:=chartFiberInverse a b + have hAe:(A:Model n → TangentSpace 𝓘(ℝ,Model n) x)=e.symm:= + (T.symm_continuousLinearEquivAt_eq hx).symm + have hEA (d:Model n):e (A d)=d:=by rw [hAe]; exact e.apply_symm_apply d + have hAE (d:TangentSpace 𝓘(ℝ,Model n) x):A (e d)=d:=by rw [hAe]; exact e.symm_apply_apply d + let C:=pullBilinear B e.toContinuousLinearMap + have hC:HasLowerSecondTaylor (fun d:TangentSpace 𝓘(ℝ,Model n) x=> + φ (uv.2 (riemannianExp x (A p+d)))+‖A p+d‖^2/2) 0 C:=by + convert hjet.comp_stationary e.hasFDerivAt e.map_zero using 1 + funext d + simp only [movingNormal_eq hb,map_add] + change φ (uv.2 (riemannianExp x (A p+d)))+‖A p+d‖^2/2= + φ (uv.2 (riemannianExp x (A p+A (e d))))+‖A p+A (e d)‖^2/2 + rw [hAE] + obtain ⟨V,hVs,hVp,hgain,hσ,hσs,hdet⟩:=HK x0 uv φ huv hφ hm z l ha hφ2 hd hl hconc + C (fun d f=>hBs _ _) (fun d=>hB _) hC + let W:=A.adjoint.comp (V.comp A) + have hdim:Module.finrank ℝ (Model n)=Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x):=by + rw [tangent_finrank,finrank_euclideanSpace_fin] + have hP:=det_positive_hessian_pullback (B:=A) (W:=V) hdim + (chartFiberInverse_injective hb) hVs hVp (show (0:ℝ)<1 by norm_num) + simp only [one_smul,one_pow,one_mul] at hP + refine ⟨W,?_,hP.1,?_,hσ,hσs,?_⟩ + · intro d f + simp only [W,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left, + ContinuousLinearMap.adjoint_inner_right,hVs] + · intro d + have H:=hgain (A d) + simpa only [C,pullBilinear_apply,ContinuousLinearEquiv.coe_coe,hEA, + frameMetric_apply hb,W,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] using H + · change _*(A.adjoint.comp (V.comp A)).det≤_ + rw [hP.2] + have H:=mul_le_mul_of_nonneg_left hdet (sq_nonneg A.toLinearMap.normDet) + nlinarith only [H] +end ChartOuterMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartTrueMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartTrueMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..f65f42ea3d2da9f19069672c164b56d9c339a180 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ChartTrueMatrix.lean @@ -0,0 +1,102 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FrameMetric +import OAI.Analysis.BiholderTransport.Coordinates.NormalFrameTaylor +import OAI.Analysis.BiholderTransport.Calculus.JetTranslation + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartTrueMatrix +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def chartJetMatrix (a c:M) (b q:Model n) (p:Model n →L[ℝ] ℝ) + (A:Model n →L[ℝ] Model n →L[ℝ] ℝ) : Model n →L[ℝ] Model n →L[ℝ] ℝ := + frameMetric a b+secondJetPullback p A (fderiv ℝ (movingPrefixChart a c 1 b) q) + (fderiv ℝ (fderiv ℝ (movingPrefixChart a c 1 b)) q) + +omit [Nonempty M] in +lemma chartJetMatrix_normal_identity {f:M → ℝ} {a c y:M} {b q:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hq:chartFiberInverse a b q∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hy:movingPrefix a 1 b q=y) (hc:y∈(extChartAt 𝓘(ℝ,Model n) c).source) + {r:TangentSpace 𝓘(ℝ,Model n) y} (hr:r∈injectivityDomain y) + (hrx:riemannianExp y r=(extChartAt 𝓘(ℝ,Model n) a).symm b) + {S:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hS:HasQuadraticExpansion (fun h=>f (riemannianExp y h)) r S) + {p:Model n} {A:Model n →L[ℝ] Model n} (hA:∀d e,inner ℝ (A d) e=inner ℝ d (A e)) + (hAe:HasQuadraticExpansion (fun h=>f ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c y+h))) p A) + {R:TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) → TangentSpace 𝓘(ℝ,Model n) y} + (hR:DifferentiableAt ℝ R (chartFiberInverse a b q)) (hR0:R (chartFiberInverse a b q)=0) + (hRe:∀ᶠ v in 𝓝 (chartFiberInverse a b q),riemannianExp y (R v)= + riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) v) : + ∀d,chartJetMatrix a c b q (innerSL ℝ p) ((innerSL ℝ).comp A) d d= + inner ℝ (S (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d))) + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d))+ + normalHessian y r (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d)) + (fderiv ℝ R (chartFiberInverse a b q) (chartFiberInverse a b d)) := by + let B:=chartFiberInverse a b + have he:riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) (B q)=y:=by + simpa only [movingPrefix_eq hb,one_smul,B,chartFiberInverse] using hy + have H:=chart_normal_pole_frame_identity B hr hq hrx he hc hS hA hAe hR hR0 hRe + have hg:ContDiffAt ℝ 2 (movingPrefixChart a c 1 b) q:=by + exact ((movingPrefixChart_contDiffAt hb (hy.symm ▸ hc)).comp q + (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have heq:(fun h=>movingPrefixChart a c 1 b (q+h)-extChartAt 𝓘(ℝ,Model n) c y)= + (fun h=>extChartAt 𝓘(ℝ,Model n) c (riemannianExp + ((extChartAt 𝓘(ℝ,Model n) a).symm b) (B q+B h))-extChartAt 𝓘(ℝ,Model n) c y):=by + funext h + simp only [movingPrefixChart,movingPrefix_eq hb,one_smul,map_add,B,chartFiberInverse] + rw [←heq] at H + dsimp only at H + rw [fderiv_translate_at_zero (hg.differentiableAt (by norm_num)), + second_fderiv_translate_at_zero hg] at H + intro d + rw [chartJetMatrix,add_apply,add_apply, + frameMetric_apply hb,real_inner_self_eq_norm_sq] + exact H d + +omit [Nonempty M] in +lemma chartJetMatrix_tendsto {a c:M} {b q:ℕ → Model n} {b0 q0:Model n} + {p:ℕ → Model n →L[ℝ] ℝ} {p0:Model n →L[ℝ] ℝ} + {A:ℕ → Model n →L[ℝ] Model n →L[ℝ] ℝ} {A0:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hb0:b0∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc:movingPrefix a 1 b0 q0∈(extChartAt 𝓘(ℝ,Model n) c).source) + (hb:Tendsto b atTop (𝓝 b0)) (hq:Tendsto q atTop (𝓝 q0)) + (hp:Tendsto p atTop (𝓝 p0)) (hA:Tendsto A atTop (𝓝 A0)) : + Tendsto (fun k=>chartJetMatrix a c (b k) (q k) (p k) (A k)) atTop + (𝓝 (chartJetMatrix a c b0 q0 p0 A0)) := by + let : NormedAddCommGroup (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + have hg:=movingPrefixChart_contDiffAt hb0 hc + have hbx:=hb.prodMk_nhds hq + have hD:=((ContDiffAt.partial_snd_fderiv hg).continuousAt.tendsto).comp hbx + have hD2:=((ContDiffAt.partial_snd_fderiv_two hg).continuousAt.tendsto).comp hbx + have hf : Tendsto (fun k=>frameMetric a (b k)) atTop (𝓝 (frameMetric a b0)) := + (frameMetric_continuousAt hb0).tendsto.comp hb + have hs : Tendsto (fun k=>secondJetPullback (p k) (A k) + (fderiv ℝ (movingPrefixChart a c 1 (b k)) (q k)) + (fderiv ℝ (fderiv ℝ (movingPrefixChart a c 1 (b k))) (q k))) atTop + (𝓝 (secondJetPullback p0 A0 (fderiv ℝ (movingPrefixChart a c 1 b0) q0) + (fderiv ℝ (fderiv ℝ (movingPrefixChart a c 1 b0)) q0))) := + secondJetPullback_tendsto hp hA hD hD2 + exact hf.add hs +end ChartTrueMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactConorm.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactConorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..53aa0c16bad49bd7135d88ebcd293bcedc79eba6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactConorm.lean @@ -0,0 +1,241 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ModelMixedConorm +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteModelMixed (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end ModelMixedConorm +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformMixedConorm +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteUniformConorm (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end UniformMixedConorm +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section UniformRadialProfile +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteUniformProfile (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end UniformRadialProfile +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section AffineMTW +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteAffine (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end AffineMTW +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section UniformJoinSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteJoinBound (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end UniformJoinSpectrum +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformAffineProfile +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteAffineProfile (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end UniformAffineProfile +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section AffineSpectrumComparison +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteAffineSpectrum (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end AffineSpectrumComparison +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FixedJoinDeterminant +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteJoinDet (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end FixedJoinDeterminant +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Module + +namespace WeakMTWTransport +section NormDetBound +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] + +lemma norm_eigenvector_image_eq_singularValue (A : E →ₗ[ℝ] F) + {n : ℕ} (hn : finrank ℝ E=n) (i : Fin n) : + ‖A (A.isSymmetric_adjoint_comp_self.eigenvectorBasis hn i)‖=A.singularValues i := by + let v := A.isSymmetric_adjoint_comp_self.eigenvectorBasis hn i + have hv : ‖v‖=1 := (A.isSymmetric_adjoint_comp_self.eigenvectorBasis hn).norm_eq_one i + have he : (A.adjoint.comp A) v=A.isSymmetric_adjoint_comp_self.eigenvalues hn i • v := + A.isSymmetric_adjoint_comp_self.apply_eigenvectorBasis hn i + have hsq : ‖A v‖^2=A.isSymmetric_adjoint_comp_self.eigenvalues hn i := by + rw [←real_inner_self_eq_norm_sq,←A.adjoint_inner_left v (A v)] + change inner ℝ ((A.adjoint.comp A) v) v=_ + rw [he,real_inner_smul_left,real_inner_self_eq_norm_sq,hv] + ring + apply (sq_eq_sq₀ (norm_nonneg _) (A.singularValues_nonneg i)).mp + rw [hsq,A.sq_singularValues_fin hn i] +end NormDetBound +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactCrossing.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactCrossing.lean new file mode 100644 index 0000000000000000000000000000000000000000..306161c1cba877aec53c79979b6f8a0869015a54 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactCrossing.lean @@ -0,0 +1,50 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {Q E : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma bilinear_lower_of_unit (L : E →L[ℝ] E →L[ℝ] ℝ) {c : ℝ} + (h : ∀ v:E, ‖v‖=1 → c ≤ L v v) (v:E) : c*‖v‖^2 ≤ L v v := by + by_cases hv : v=0 + · simp [hv] + have hn : 0 < ‖v‖ := norm_pos_iff.mpr hv + let w := ‖v‖⁻¹ • v + have hw : ‖w‖=1 := by simp only [w,norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hn),inv_mul_cancel₀ hn.ne'] + have he : v=‖v‖ • w := by dsimp [w]; rw [smul_smul,mul_inv_cancel₀ hn.ne',one_smul] + have H := mul_le_mul_of_nonneg_left (h w hw) (sq_nonneg ‖v‖) + calc + c*‖v‖^2 = ‖v‖^2*c := mul_comm _ _ + _ ≤ ‖v‖^2*L w w := H + _ = L (‖v‖ • w) (‖v‖ • w) := by simp only [map_smul,smul_apply,smul_eq_mul]; ring + _ = L v v := by rw [←he] + +lemma bilinear_diag_abs_le (L : E →L[ℝ] E →L[ℝ] ℝ) (v:E) : + |L v v| ≤ ‖L‖*‖v‖^2 := by + calc + |L v v| = ‖L v v‖ := (Real.norm_eq_abs _).symm + _ ≤ ‖L v‖*‖v‖ := (L v).le_opNorm _ + _ ≤ (‖L‖*‖v‖)*‖v‖ := mul_le_mul_of_nonneg_right (L.le_opNorm _) (norm_nonneg _) + _ = ‖L‖*‖v‖^2 := by ring + +lemma bilinear_time_hasDerivAt {H : ℝ×Q → E →L[ℝ] E →L[ℝ] ℝ} + {t:ℝ} {q:Q} (hH : DifferentiableAt ℝ H (t,q)) (v:E) : + HasDerivAt (fun s => H (s,q) v v) (fderiv ℝ H (t,q) (1,0) v v) t := by + have hp : HasDerivAt (fun s : ℝ => (s,q)) (1,0) t := + (hasDerivAt_id t).prodMk (hasDerivAt_const t q) + have HD : HasDerivAt (fun s : ℝ => H (s,q)) (fderiv ℝ H (t,q) (1,0)) t := + HasFDerivAt.comp_hasDerivAt (l := H) (l' := fderiv ℝ H (t,q)) + (f := fun s : ℝ => (s,q)) t hH.hasFDerivAt hp + have HV := (HD.clm_apply (hasDerivAt_const t v)).clm_apply (hasDerivAt_const t v) + simpa only [Function.comp_def,map_zero,add_zero,zero_add] using HV +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactLocalPositiveBounds.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactLocalPositiveBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..c334ad1c4403ddb8089f8cffe3922942fefca942 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactLocalPositiveBounds.lean @@ -0,0 +1,35 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ContDiffParametricQuadratic + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma compact_local_positive_bounds {A : Type*} [TopologicalSpace A] + {K : Set A} (hK : IsCompact K) {P : ℝ → ℝ → A → Prop} + (hmono : ∀ {r R b B : ℝ}, 0 P r b a) hK + (fun hr hR hB _ a ha => hmono hr hR hB a ha) (by + intro a ha + obtain ⟨r,b,hr,hb,H⟩ := hlocal a ha + exact ⟨r,hr,b,hb,continuousAt_snd.eventually H⟩) + exact ⟨r,b,hr,hb,H.self_of_nhds⟩ + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactQuadratic.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactQuadratic.lean new file mode 100644 index 0000000000000000000000000000000000000000..88dbd19317153008b41cbcd839b25a62d78eeb43 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CompactQuadratic.lean @@ -0,0 +1,176 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions +import OAI.Analysis.BiholderTransport.LinearAlgebra.ActualRadial +import OAI.Analysis.BiholderTransport.Coordinates.SplitAction +import OAI.Analysis.BiholderTransport.Regularity.SecondScaled +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.Coordinates.ProperPieces + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section Crossing +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end Crossing +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MiddleHessian +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma reverseRay_prefix (z : TangentBundle 𝓘(ℝ,Model n) M) (h : ℝ) : + reverseRay (tangentScale h z)=tangentScale (-h) (sprayFlow h z) := by + rw [reverseRay,sprayFlow_scale,mul_one,tangentScale_mul,neg_one_mul] + +lemma proper_prefix_reverse_in_injectivityDomain {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈minimizingVectors z.1) {h : ℝ} (hh : 0 simp only [cost,div_div,mul_comm] + rw [←middle_action_contact hz hh hh1] at H' + dsimp only [middleCenteredAction] + simp only [sub_self,mul_zero,neg_mul,sub_neg_eq_add,div_eq_mul_inv] at H' ⊢ + nlinarith + +lemma middleCenteredAction_contDiffAt {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈minimizingVectors z.1) {h : ℝ} (hh : 0 (hPn v).2) + (a := 1) (b := 0) (fun v => by simp [h]) hnE hnF i + simpa only [one_mul,add_zero] using H + · let e := LinearEquiv.ofBijective P hP + have hnorm : ∀ w, ‖e.symm w‖ ≤ (1/l)*‖w‖ := by + intro w + rw [one_div,mul_comm,←div_eq_mul_inv,le_div_iff₀ hl] + have H := (hPn (e.symm w)).1 + change l*‖e.symm w‖ ≤ ‖e (e.symm w)‖ at H + simpa only [e.apply_symm_apply,mul_comm] using H + have heq : ∀ w, inner ℝ (B w) w = inner ℝ (A (e.symm w)) (e.symm w) := by + intro w + have H := h (e.symm w) + change inner ℝ (A (e.symm w)) (e.symm w) = inner ℝ (B (e (e.symm w))) (e (e.symm w)) at H + simpa only [e.apply_symm_apply] using H.symm + have H := ordered_eigenvalue_pullback_comparison hB.isSymmetric hA e.symm.toLinearMap + (by norm_num : (0:ℝ) ≤ 1) (div_nonneg (by norm_num) hl.le) hnorm + (a := 1) (b := 0) (fun v => by simp [heq]) hnF hnE i + simpa only [one_mul,add_zero] using H + +end CongruenceSpectrum +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section EndpointMiddle +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma middleHessianOperator_positive_one {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2 ∈ minimizingVectors z.1) {h : ℝ} (hh : 0 < h) (hh1 : h < 1) : + (middleHessianOperator z h 1).toLinearMap.IsPositive := by + refine ⟨middleHessianOperator_symmetric hz hh hh1 hh1 le_rfl,?_⟩ + intro v + change 0 ≤ inner ℝ (middleHessianOperator z h 1 v) v + rw [inner_middleHessianOperator] + exact middleHessian_one_nonneg hz hh hh1 v + +lemma uniform_join_middle_ordered_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ∀ hp : p ∈ minimizingVectors x, ∀ t : ℝ, ∀ ht : t ∈ Icc (1/4:ℝ) (3/4), + ∀ i : Fin (Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x)), + (splitJoinHessianOperator_positive hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ≤ C * + (middleHessianOperator_positive_one (z := ⟨x,p⟩) hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ∧ + (middleHessianOperator_positive_one (z := ⟨x,p⟩) hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ≤ c * + (splitJoinHessianOperator_positive hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_split_join_hessian_congruence (n := n) (M := M) + refine ⟨(1 / c)^2, C ^ 2, sq_pos_of_pos (div_pos (by norm_num) hc),sq_pos_of_pos hC,?_⟩ + intro x p hp t ht i + obtain ⟨P,hP,hPn,h⟩ := H x p hp t ht + have hpQ := splitJoinHessianOperator_positive hp + (show 0 < t by linarith [ht.1]) (show t < 1 by linarith [ht.2]) + have hpD := middleHessianOperator_positive_one (z := ⟨x,p⟩) hp + (show 0 < t by linarith [ht.1]) (show t < 1 by linarith [ht.2]) + exact ordered_eigenvalues_bounded_congruence hpQ hpD P.toLinearMap hP hc hC.le hPn + (fun v => by + change inner ℝ (splitJoinHessianOperator x t p v) v = + inner ℝ (middleHessianOperator (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) t 1 (P v)) (P v) + rw [inner_splitJoinHessianOperator,inner_middleHessianOperator,h]) rfl rfl i + +lemma uniform_endpoint_middle_ordered_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ∀ hp : p ∈ minimizingVectors x, ∀ t : ℝ, ∀ ht : t ∈ Icc (1/4:ℝ) (3/4), + ∀ i : Fin (Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x)), + (endpointExpDifferential x p).toLinearMap.singularValues i ≤ C * + (middleHessianOperator_positive_one (z := ⟨x,p⟩) hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ∧ + (middleHessianOperator_positive_one (z := ⟨x,p⟩) hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ≤ c * + (endpointExpDifferential x p).toLinearMap.singularValues i := by + obtain ⟨a,b,ha,hb,H⟩ := uniform_join_middle_ordered_comparison (n := n) (M := M) + obtain ⟨d,e,hd,he,J⟩ := uniform_join_exp_ordered_comparison (n := n) (M := M) + refine ⟨a*e,d*b,mul_pos ha he,mul_pos hd hb,?_⟩ + intro x p hp t ht i + have H1 := H x p hp t ht i + have J1 := J x p hp t ht i + constructor + · simpa only [mul_assoc] using J1.2.trans (mul_le_mul_of_nonneg_left H1.1 hd.le) + · simpa only [mul_assoc] using H1.2.trans (mul_le_mul_of_nonneg_left J1.1 ha.le) + +end EndpointMiddle +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactDifferential.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..3f88b001765e2ac100bebcc715dab3da4e9ff024 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactDifferential.lean @@ -0,0 +1,203 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.AlexandrovDerivative +import OAI.Analysis.BiholderTransport.Contact.AEContacts +import OAI.Analysis.BiholderTransport.Contact.ContactSelection +import OAI.Analysis.BiholderTransport.Convexity.CoordinateSemiconvex +import OAI.Analysis.BiholderTransport.Calculus.Gradient +import OAI.Analysis.BiholderTransport.LinearAlgebra.Aggregate + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactDifferential +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma exists_normal_local_inverse_at {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : + ∃ κ : M → TangentSpace 𝓘(ℝ,Model n) x, + κ (riemannianExp x p)=p ∧ + ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) ∞ κ (riemannianExp x p) ∧ + ∀ᶠ y in 𝓝 (riemannianExp x p), riemannianExp x (κ y)=y := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + let d := extChartAt 𝓘(ℝ,Model n) y + obtain ⟨e,he,hp',hc⟩ := exists_coordinate_exp_inverse hp + let κ : M → V := fun z => e.symm (d z) + have hep : e p=d y := congrFun he p + have hκp : κ y=p := by change e.symm _=p; rw [←hep]; exact e.left_inv hp' + have hκ : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,V) ∞ κ y := by + apply ContMDiffAt.comp y _ contMDiffAt_extChartAt + rw [←hep] + exact hc.contMDiffAt + refine ⟨κ,hκp,hκ,?_⟩ + have hct : ∀ᶠ z in 𝓝 y, d z∈e.target := + (contMDiffAt_extChartAt (I := 𝓘(ℝ,Model n)) (n := ∞) (x := y)).continuousAt.preimage_mem_nhds + (by rw [←hep]; exact e.open_target.mem_nhds (e.map_source hp')) + have hcs : ∀ᶠ z in 𝓝 y, z∈d.source := extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) y + have hes : ∀ᶠ z in 𝓝 y, riemannianExp x (κ z)∈d.source := + (((contMDiff_riemannianExp_fiber x).continuous.continuousAt).comp hκ.continuousAt).preimage_mem_nhds + (by simp only [Function.comp_apply,hκp]; exact extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) y) + filter_upwards [hct,hcs,hes] with z hzt hzs hzes + apply d.injOn hzes hzs + change (fun q => d (riemannianExp x q)) (κ z)=_ + rw [←he] + exact e.right_inv hzt + +def normalHessianOperator (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x := + (InnerProductSpace.toDual ℝ _).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp + (normalHessian x p) + +omit [CompactSpace M] [Nonempty M] [MeasurableSpace M] [BorelSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma inner_normalHessianOperator (x : M) (p u v : TangentSpace 𝓘(ℝ,Model n) x) : + inner ℝ (normalHessianOperator x p u) v=normalHessian x p u v := by + exact InnerProductSpace.toDual_symm_apply + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma prefixNormalCost_source_hessian_full {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) (u v : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixNormalCost x 1)) (0,p) (u,0) (v,0)=normalHessian x p u v := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hp1 : (1:ℝ) • p∈injectivityDomain x := by simpa only [one_smul] using hp + have hsym := (prefixNormalCost_contDiffAt hp1).isSymmSndFDerivAt + (by simp) + have heq := symmetric_bilinear_eq_of_diagonal + (A := (fderiv ℝ (fderiv ℝ (prefixNormalCost x 1)) (0,p)).bilinearComp + (ContinuousLinearMap.inl ℝ V V) (ContinuousLinearMap.inl ℝ V V)) + (B := normalHessian x p) + (fun a b => hsym.eq (a,0) (b,0)) (normalHessian_symm hp) + (fun a => by simpa only [ContinuousLinearMap.bilinearComp_apply, + ContinuousLinearMap.inl_apply,one_smul,div_one] using prefixNormalCost_source_hessian hp1 a) + exact congrArg (fun D : V →L[ℝ] V →L[ℝ] ℝ => D u v) heq + +omit [MeasurableSpace M] [BorelSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma normal_contact_twist {v : M → ℝ} (hv : Continuous v) {x : M} + {a p : TangentSpace 𝓘(ℝ,Model n) x} + (hB : DifferentiableAt ℝ (prefixNormalCost x 1) (a,p)) + (hcontact : contactGap (cTransform v) v (riemannianExp x a) (riemannianExp x p)=0) + {g : TangentSpace 𝓘(ℝ,Model n) x} + (hg : HasFDerivAt (fun h => cTransform v (riemannianExp x h)) (innerSL ℝ g) a) : + (fderiv ℝ (prefixNormalCost x 1) (a,p)).comp + (ContinuousLinearMap.inl ℝ _ _)= -(innerSL ℝ g) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hmin : IsLocalMin (fun h : V => cTransform v (riemannianExp x h)+ + prefixNormalCost x 1 (h,p)) a := by + apply Filter.Eventually.of_forall + intro h + have H := cTransform_gap_nonneg hv (riemannianExp x h) (riemannianExp x p) + simp only [contactGap] at H hcontact + simp only [prefixNormalCost,one_smul,div_one] + linarith + have hd := hB.hasFDerivAt.comp (f := fun h : V => (h,p)) a + ((hasFDerivAt_id a).prodMk (hasFDerivAt_const p a)) + have hz := hmin.hasFDerivAt_eq_zero (hg.add hd) + have H : innerSL ℝ g+(fderiv ℝ (prefixNormalCost x 1) (a,p)).comp + (ContinuousLinearMap.inl ℝ V V)=0 := by simpa only [ContinuousLinearMap.inl] using hz + exact eq_neg_of_add_eq_zero_right H + +omit [MeasurableSpace M] [BorelSpace M] in +lemma contact_selection_normal_differential {v : M → ℝ} (hv : Continuous v) {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈activeLogs (n := n) v x) + (hpI : p∈injectivityDomain x) + (hDiff : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x) + {A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x} + (hA : ∀ u w, inner ℝ (A u) w=inner ℝ u (A w)) + (hexp : HasQuadraticExpansion (fun h => cTransform v (riemannianExp x h)) p A) + {T : M → M} (hT : ∀ z, contactGap (cTransform v) v z (T z)=0) : + ∃ r>0, ∃ q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) x, + q 0=p ∧ ContinuousAt q 0 ∧ + (∀ᶠ h in 𝓝 0, riemannianExp x (q h)=T (riemannianExp x h)) ∧ + HasFDerivWithinAt q (normalHessianOperator x p+A) + {h | h∈Metric.ball 0 r ∧ DifferentiableAt ℝ (fun z => cTransform v (riemannianExp x z)) h} 0 := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let f : V → ℝ := fun h => cTransform v (riemannianExp x h) + have hTx : T x=riemannianExp x p := contact_unique_of_mdifferentiable hv hDiff (hT x) hp.2 + have hTc : ContinuousAt T x := contact_selection_continuousAt (continuous_cTransform hv) hv hT + (fun y hy => contact_unique_of_mdifferentiable hv hDiff hy (hT x)) + obtain ⟨κ,hκ0,hκ,hκright⟩ := exists_normal_local_inverse_at hpI + let q : V → V := fun h => κ (T (riemannianExp x h)) + have hq0 : q 0=p := by simp only [q,riemannianExp_zero,hTx,hκ0] + have hTc' : ContinuousAt T (riemannianExp (n := n) x (0:V)) := by + simpa only [riemannianExp_zero] using hTc + have hcT : ContinuousAt (fun h : V => T (riemannianExp x h)) 0 := + hTc'.comp (contMDiff_riemannianExp_fiber x 0).continuousAt + have hκ' : ContinuousAt κ (T (riemannianExp (n := n) x (0:V))) := by + simpa only [riemannianExp_zero,hTx] using hκ.continuousAt + have hqc : ContinuousAt q 0 := hκ'.comp (f := fun h : V => T (riemannianExp x h)) hcT + have hqright : ∀ᶠ h in 𝓝 (0:V), riemannianExp x (q h)=T (riemannianExp x h) := + (show Tendsto (fun h : V => T (riemannianExp x h)) (𝓝 0) (𝓝 (riemannianExp x p)) from by + simpa only [ContinuousAt,riemannianExp_zero,hTx] using hcT).eventually hκright + obtain ⟨r,hr,K,hK,hconv⟩ := cTransform_uniform_smooth_coordinate_semiconvex + (contMDiff_riemannianExp_fiber (n := n) x 0) + let s : Set V := {h | h∈Metric.ball 0 r ∧ DifferentiableAt ℝ f h} + let g : V → V := fun h => (InnerProductSpace.toDual ℝ V).symm (fderiv ℝ f h) + have hg0 : g 0=p := by + change (InnerProductSpace.toDual ℝ V).symm (fderiv ℝ f 0)=p + rw [hexp.hasFDerivAt.fderiv] + exact (InnerProductSpace.toDual ℝ V).symm_apply_apply p + have hgD (h : V) (hh : h∈s) : HasFDerivAt f (innerSL ℝ (g h)) h := by + apply hh.2.hasFDerivAt.congr_fderiv + exact ((InnerProductSpace.toDual ℝ V).apply_symm_apply _).symm + have hg := semiconvex_gradient_hasFDerivWithinAt hA hexp hr (K := 2*K) + (by simpa only [mul_div_cancel_left₀ K (show (2:ℝ)≠0 by norm_num)] using hconv v hv) + have hp1 : (1:ℝ) • p∈injectivityDomain x := by simpa only [one_smul] using hpI + have hB := (prefixNormalCost_contDiffAt hp1).of_le (m := 2) + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hnearB : ∀ᶠ h in 𝓝 (0:V), DifferentiableAt ℝ (prefixNormalCost x 1) (h,q h) := by + have H := (hB.eventually (by norm_num)).mono + (fun z hz => hz.differentiableAt (by norm_num)) + apply (continuousAt_id.prodMk hqc).tendsto.eventually + simpa only [hq0,id_eq] using H + refine ⟨r,hr,q,hq0,hqc,hqright,?_⟩ + apply twist_hasFDerivWithinAt hB + · intro u w + rw [prefixNormalCost_source_hessian_full hpI,inner_normalHessianOperator] + · intro u w + rw [hB.isSymmSndFDerivAt (by norm_num) |>.eq] + simpa only [real_inner_comm] using (prefixNormalCost_hessian_blocks (show (0:ℝ)<1 by norm_num) hp1 w u).1 + · exact hq0 + · exact hqc + · exact hg + · filter_upwards [self_mem_nhdsWithin,mem_nhdsWithin_of_mem_nhds hqright, + mem_nhdsWithin_of_mem_nhds hnearB] with h hh he hB' + apply normal_contact_twist hv hB' _ (hgD h hh) + rw [he] + exact hT _ + · apply normal_contact_twist hv (hB.differentiableAt (by norm_num)) + · simpa only [riemannianExp_zero] using hp.2 + · change HasFDerivAt f (innerSL ℝ (g 0)) 0 + rw [hg0] + exact hexp.hasFDerivAt + +end ContactDifferential +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactStationarity.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactStationarity.lean new file mode 100644 index 0000000000000000000000000000000000000000..191829204d0346871bcbd48d23ca25b46698c92d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ContactStationarity.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ContactStationarity + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ContactStationarity +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma chartTestContact_relative_hessian_fixed {a b : M} {z : Model n} {φ : Model n → ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hp : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (hb : coordinateBackward a (-1,z,fderiv ℝ φ z)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + let c := coordinateBackward a (-1,z,fderiv ℝ φ z) + let y := extChartAt 𝓘(ℝ,Model n) b c + let D := fderiv ℝ (chartCostCovector a b) (z,y) + fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a c)) z = + -((D.comp (ContinuousLinearMap.inr ℝ (Model n) (Model n))).comp + (fderiv ℝ (chartTestContact a b φ) z)) := by + dsimp only + let c := coordinateBackward a (-1,z,fderiv ℝ φ z) + let y := extChartAt 𝓘(ℝ,Model n) b c + let G := chartCostCovector (n := n) a b + let T := chartTestContact a b φ + have hTy : T z=y := rfl + have hy : y∈(extChartAt 𝓘(ℝ,Model n) b).target := + (extChartAt 𝓘(ℝ,Model n) b).map_source hb + have hyb : (extChartAt 𝓘(ℝ,Model n) b).symm y=c := + (extChartAt 𝓘(ℝ,Model n) b).left_inv hb + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm z,chartGradientVector a z (fderiv ℝ φ z)⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) ((extChartAt 𝓘(ℝ,Model n) a).symm z, + (extChartAt 𝓘(ℝ,Model n) b).symm y) := by + rw [hyb,show c=riemannianExp _ (chartGradientVector a z (fderiv ℝ φ z)) from + coordinateBackward_eq_exp_chartGradient hz _] + exact hc + have hG : DifferentiableAt ℝ G (z,y) := + (chartCostCovector_contDiffAt hz hy hc').differentiableAt (by simp) + have hT : DifferentiableAt ℝ T z := + (chartTestContact_contDiffAt hz hφ hb).differentiableAt (by simp) + have hgraph : HasFDerivAt (fun w => (w,T w)) + ((ContinuousLinearMap.id ℝ (Model n)).prod (fderiv ℝ T z)) z := + (hasFDerivAt_id z).prodMk hT.hasFDerivAt + have hggraph := hG.hasFDerivAt.comp z hgraph + have he : (fun w => G (w,T w))=ᶠ[𝓝 z] (fun w => -fderiv ℝ φ w) := by + have hZ : ContinuousAt (fun w => (w,fderiv ℝ φ w)) z := + continuousAt_id.prodMk (hφ.fderiv_right (m := 1) (by norm_num)).continuousAt + exact hZ.eventually (contact_stationarity_eventually hz hp hb) + have heD := (hggraph.congr_of_eventuallyEq he.symm).unique + (((hφ.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)).hasFDerivAt.neg) + have hbaseMap : HasFDerivAt (fun w : Model n => (w,y)) + ((ContinuousLinearMap.id ℝ (Model n)).prod 0) z := + (hasFDerivAt_id z).prodMk (hasFDerivAt_const y z) + have hbase := hG.hasFDerivAt.comp (f := fun w : Model n => (w,y)) z hbaseMap + have hbaseEq : (fun w => G (w,y))=fderiv ℝ (chartCost a c) := by + funext w + change fderiv ℝ (chartCost a ((extChartAt 𝓘(ℝ,Model n) b).symm y)) w = _ + rw [hyb] + change HasFDerivAt (fun w => G (w,y)) _ z at hbase + rw [hbaseEq] at hbase + have hbaseD := hbase.fderiv + ext ξ η + have heV := congrArg (fun A : Model n →L[ℝ] Model n →L[ℝ] ℝ => A ξ η) heD + have hbV := congrArg (fun A : Model n →L[ℝ] Model n →L[ℝ] ℝ => A ξ η) hbaseD + dsimp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,zero_apply, + neg_apply,Pi.neg_apply] at heV hbV + have hsplit : (ξ,fderiv ℝ T z ξ)=(ξ,(0:Model n))+(0,fderiv ℝ T z ξ) := by simp + rw [hsplit,map_add,add_apply] at heV + change fderiv ℝ (fderiv ℝ φ) z ξ η+fderiv ℝ (fderiv ℝ (chartCost a c)) z ξ η = + -fderiv ℝ G (z,y) (0,fderiv ℝ T z ξ) η + simp only [neg_apply,zero_apply] at heV hbV + linarith only [heV,hbV] + +end ContactStationarity +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ConvexSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ConvexSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..541556d1cd89f55f6ce389d472d1c97022b8020f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ConvexSpectrum.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MinMax +import OAI.Analysis.BiholderTransport.Convexity.BoundedConvexSecant + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport +section ConvexSpectrum +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma bounded_matrix_convex_eigen_secant {A : ℝ → E →ₗ[ℝ] E} {a b C d x y : ℝ} + (hA : ∀ t∈Icc a b, (A t).IsSymmetric) + (hc : ∀ v, ConvexOn ℝ (Icc a b) (fun t => inner ℝ (A t v) v)) + (hC : 0≤C) (hd : 0 hb t ht v) hx hy + have H' (v : E) : |inner ℝ (A y v) v-inner ℝ (A x v) v|≤ + ((2*C/d)*|y-x|)*‖v‖^2 := by + convert H v using 1 + ring + have hup := ordered_eigenvalue_quadratic_comparison (hA y hyi) (hA x hxi) + (a := 1) (b := (2*C/d)*|y-x|) (by norm_num) + (fun v => by have := (abs_le.mp (H' v)).2; linarith) hn i + have hlo := ordered_eigenvalue_quadratic_comparison (hA x hxi) (hA y hyi) + (a := 1) (b := (2*C/d)*|y-x|) (by norm_num) + (fun v => by have := (abs_le.mp (H' v)).1; linarith) hn i + exact abs_le.mpr ⟨by linarith,by linarith⟩ + +lemma matrix_convex_eigen_endpoint {A : ℝ → E →ₗ[ℝ] E} {a C e : ℝ} + (ha : 0≤a) (he : e∈Icc (0:ℝ) 1) + (hA : ∀ t∈Icc (-a) 1, (A t).IsSymmetric) + (hc : ∀ v, ConvexOn ℝ (Icc (-a) 1) (fun t => inner ℝ (A t v) v)) + (hb : ∀ v, inner ℝ (A 0 v) v≤C*‖v‖^2) + (hm : 1-e∈Icc (-a) 1) (h1 : (1:ℝ)∈Icc (-a) 1) + {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) : + (hA (1-e) hm).eigenvalues hn i ≤ + (1-e)*(hA 1 h1).eigenvalues hn i+e*C := by + refine ordered_eigenvalue_quadratic_comparison (hA (1-e) hm) (hA 1 h1) + (show 0≤1-e by linarith [he.2]) ?_ hn i + intro v + have H := (hc v).2 (show (0:ℝ)∈Icc (-a) 1 by constructor <;> linarith) h1 + he.1 (show 0≤1-e by linarith [he.2]) (show e+(1-e)=1 by ring) + simp only [smul_eq_mul,mul_zero,mul_one,zero_add] at H + have H2 := mul_le_mul_of_nonneg_left (hb v) he.1 + nlinarith only [H,H2] +end ConvexSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CurvedBlowup.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CurvedBlowup.lean new file mode 100644 index 0000000000000000000000000000000000000000..20e8a72a3f34a9ba0b125d150cd85d23808c8d5f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/CurvedBlowup.lean @@ -0,0 +1,200 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.CurvedQuadratic +import OAI.Analysis.BiholderTransport.Regularity.TrialBlowup + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma conjugate_curved_hessian_upper {x : M} {p e xi k : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) + (hseg : ∀ᶠ s : ℝ in 𝓝 0, p+s • e ∈ minimizingVectors x) + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) + (hpair : inner ℝ k xi≠0) : + ∃ eps B c : ℝ, 0 p+s • e) (𝓝 0) (𝓝 p) := by + simpa only [zero_smul,add_zero] using + (show ContinuousAt (fun s : ℝ => p+s • e) 0 from by fun_prop).tendsto + have hQmin : ∀ᶠ s : ℝ in 𝓝 0, 0≤Q (p+s • e) := by + filter_upwards [hseg,hlinear.eventually (split_regular_legs_eventually hleft hright)] with s hs hh + exact splitTrialValue_nonneg ht ht1 hs hh.1 hh.2 + obtain ⟨eps,C,heps,hC,hquad⟩ := contDiffAt_curved_quadratic_upper hQ hQ0 hQmin + let W : ℝ → V := fun s => (1-s^2) • (p+s • e) + have hW0 : W 0=p := by simp [W] + have hW : Tendsto W (𝓝 0) (𝓝 p) := by + simpa only [hW0] using (show ContinuousAt W 0 from by dsimp [W]; fun_prop).tendsto + have ha : ∀ᶠ s : ℝ in 𝓝 0, a (W s) 1 + hA.isHermitian.eigenvalues i)) := by + rw [show Matrix.diagonal (fun i => 1 + hA.isHermitian.eigenvalues i) = + 1 + Matrix.diagonal hA.isHermitian.eigenvalues by + rw [← Matrix.diagonal_one, ← Matrix.diagonal_add]] + simp only [map_add, map_one] + congr 1 + rw [hconj, Unitary.conjStarAlgAut_apply] + have hu : (U : Matrix n n ℝ) * star (U : Matrix n n ℝ) = 1 := by + exact Unitary.coe_mul_star_self U + have hdetu : (U : Matrix n n ℝ).det * (star (U : Matrix n n ℝ)).det = 1 := by + rw [← Matrix.det_mul, hu, Matrix.det_one] + rw [Matrix.det_mul, Matrix.det_mul, mul_right_comm, hdetu, one_mul, + Matrix.det_diagonal] + exact Finset.one_le_prod₀ (fun eigenIndex _ => by + linarith [hA.eigenvalues_nonneg eigenIndex]) + +lemma det_le_of_posDef_le {A B : Matrix n n ℝ} (hA : A.PosDef) (hAB : A ≤ B) : + A.det ≤ B.det := by + obtain ⟨R, hR⟩ := CStarAlgebra.nonneg_iff_eq_star_mul_self.mp hA.posSemidef.nonneg + have hRdet : R.det ≠ 0 := by + have heq : A.det = R.det * R.det := by + rw [hR, Matrix.det_mul] + simp only [Matrix.star_eq_conjTranspose, Matrix.det_conjTranspose, star_trivial] + intro hz + rw [hz, zero_mul] at heq + exact hA.det_pos.ne' heq + have hRi : IsUnit R.det := isUnit_iff_ne_zero.mpr hRdet + let S := R⁻¹ + have hrs : R * S = 1 := R.mul_nonsing_inv hRi + have hnorm : star S * A * S = 1 := by + rw [hR] + calc + star S * (star R * R) * S = star (R * S) * (R * S) := by + simp only [star_mul]; noncomm_ring + _ = 1 := by rw [hrs]; simp + have hD : (star S * (B - A) * S).PosSemidef := + hAB.conjTranspose_mul_mul_same S + have hbound := det_one_add_posSemidef_ge_one hD + have heq : 1 + star S * (B - A) * S = star S * B * S := by + rw [← hnorm] + noncomm_ring + rw [heq] at hbound + have hanorm := congrArg Matrix.det hnorm + simp only [Matrix.det_mul, Matrix.star_eq_conjTranspose, + Matrix.det_conjTranspose, star_trivial, Matrix.det_one] at hanorm hbound + nlinarith [hA.det_pos] + +lemma det_one_add_vecMulVec (u v : n → ℝ) : + (1 + Matrix.vecMulVec u v).det = 1 + v ⬝ᵥ u := by + have heq : Matrix.vecMulVec u v = + Matrix.replicateCol Unit u * Matrix.replicateRow Unit v := by + ext i j + simp [Matrix.mul_apply, Matrix.vecMulVec_apply] + rw [heq, Matrix.det_one_add_replicateCol_mul_replicateRow] + +omit [DecidableEq n] in +lemma congruence_rank_one (S : Matrix n n ℝ) (p : n → ℝ) : + Sᵀ * Matrix.vecMulVec p p * S = + Matrix.vecMulVec (Sᵀ *ᵥ p) (Sᵀ *ᵥ p) := by + rw [Matrix.mul_vecMulVec, Matrix.vecMulVec_mul, Matrix.mulVec_transpose S p] + +lemma oblique_fixes_kernel_form {L : Matrix n n ℝ} (hL : L.IsHermitian) + {e : n → ℝ} (he : L *ᵥ e = 0) (a : n → ℝ) : + (1 + Matrix.vecMulVec e a)ᵀ * L * (1 + Matrix.vecMulVec e a) = L := by + have htr : Lᵀ = L := by simpa only [Matrix.conjTranspose_eq_transpose_of_trivial] using hL.eq + have hleft : (1 + Matrix.vecMulVec e a)ᵀ * L = L := by + rw [Matrix.transpose_add, Matrix.transpose_one, Matrix.transpose_vecMulVec, + Matrix.add_mul, Matrix.one_mul, Matrix.vecMulVec_mul, ← Matrix.mulVec_transpose, + htr, he, Matrix.vecMulVec_zero, add_zero] + rw [hleft, Matrix.mul_add, Matrix.mul_one, Matrix.mul_vecMulVec, he, + Matrix.zero_vecMulVec, add_zero] + +omit [DecidableEq n] in + +lemma transpose_congruence_mono {A B : Matrix n n ℝ} (hAB : A ≤ B) + (S : Matrix n n ℝ) : Sᵀ * A * S ≤ Sᵀ * B * S := by + have h := hAB.conjTranspose_mul_mul_same S + rw [Matrix.le_iff] + simpa only [Matrix.conjTranspose_eq_transpose_of_trivial, Matrix.mul_sub, + Matrix.sub_mul] using h +end DeterminantOrder + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Diagonal.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Diagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..4586735c6a4d41fdcafa702f89fb413482153d4d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Diagonal.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential +import OAI.Analysis.BiholderTransport.Regularity.Reversal + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section Diagonal +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma diagonal_stationary_hessian_identity {F : E×E → ℝ} {p : E} + (hF : ContDiffAt ℝ 2 F (p,p)) + (hstat : ∀ᶠ v in 𝓝 p, ∀ k, fderiv ℝ F (v,v) (0,k)=0) (a k : E) : + fderiv ℝ (fderiv ℝ F) (p,p) (0,a) (0,k)= + -fderiv ℝ (fderiv ℝ F) (p,p) (a,0) (0,k) := by + have hdf := (hF.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + let L : E →L[ℝ] E×E := (ContinuousLinearMap.id ℝ E).prod (ContinuousLinearMap.id ℝ E) + have hD := ((hdf.hasFDerivAt.comp (f := fun v : E => (v,v)) p L.hasFDerivAt).clm_apply + (hasFDerivAt_const ((0:E),k) p)).fderiv + have heq : (fun v : E => fderiv ℝ F (v,v) (0,k)) =ᶠ[𝓝 p] (fun _ => (0:ℝ)) := + hstat.mono (fun _ h => h k) + have hz : fderiv ℝ (fun v : E => fderiv ℝ F (v,v) (0,k)) p=0 := by + rw [heq.fderiv_eq] + exact (hasFDerivAt_const (0:ℝ) p).fderiv + have H := congrArg (fun A : E →L[ℝ] ℝ => A a) (hD.symm.trans hz) + simp only [add_apply,ContinuousLinearMap.comp_apply,zero_apply,map_zero,zero_add, + ContinuousLinearMap.flip_apply,L,ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply] at H + have hsplit : (a,a)=(a,0)+((0:E),a) := by ext <;> simp + rw [hsplit,map_add,add_apply] at H + linarith +end Diagonal +section SplitFactor +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma diagonalSplitAction_hessian_identity {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 diagonalSplitAction_stationary ht ht1 hv.1 hv.2 k)) a k + +lemma exists_suffix_log_in_prefix_coordinates {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ∃ q : TangentSpace 𝓘(ℝ,Model n) x → + TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p), + ContDiffAt ℝ ∞ q p ∧ + (∀ᶠ v in 𝓝 p, q v∈injectivityDomain (riemannianExp x p)) ∧ + (∀ᶠ v in 𝓝 p, riemannianExp (riemannianExp x p) (q v)=riemannianExp x (t • v)) := by + let : Nonempty M := ⟨x⟩ + let : MeasurableSpace M := borel M + let : BorelSpace M := ⟨rfl⟩ + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + let s := tangentScale (1-t) (sprayFlow t z) + have hs : s.2∈injectivityDomain s.1 := hright + have hr := reverseRay_injectivityDomain hs + have he : (reverseRay s).1=riemannianExp x p := by + change (sprayFlow 1 s).1=riemannianExp x p + rw [←riemannianExp_eq_sprayFlow] + exact shifted_exp_endpoint x p t + have he' := reverseRay_endpoint s + change riemannianExp (reverseRay s).1 (reverseRay s).2=(sprayFlow t z).1 at he' + rw [←riemannianExp_smul] at he' + generalize hrdef : reverseRay s=r at hr he he' + rcases r with ⟨y,r⟩ + dsimp only at he hr he' + subst y + obtain ⟨κ,hκ0,hκ,hκright⟩ := exists_normal_local_inverse_at hr + rw [he'] at hκ0 hκ hκright + let q := fun v : TangentSpace 𝓘(ℝ,Model n) x => κ (riemannianExp x (t • v)) + have hE : ContMDiffAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) ∞ + (fun v => riemannianExp x (t • v)) p := + (contMDiff_riemannianExp_fiber x _).comp p (show ContDiffAt ℝ ∞ (fun v : TangentSpace 𝓘(ℝ,Model n) x => t • v) p from + by fun_prop).contMDiffAt + have hq : ContDiffAt ℝ ∞ q p := (hκ.comp p hE).contDiffAt + refine ⟨q,hq,?_,hE.continuousAt.eventually hκright⟩ + apply hq.continuousAt.preimage_mem_nhds + apply (isOpen_injectivityDomain _).mem_nhds + change κ (riemannianExp x (t • p))∈_ + rw [hκ0] + exact hr + +end SplitFactor +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DiagonalCostConvexity.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DiagonalCostConvexity.lean new file mode 100644 index 0000000000000000000000000000000000000000..de4816fb839f87f74435557de9b50802d1be4474 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DiagonalCostConvexity.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.NormLower + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma chartCost_diagonal_coercive {a : M} {z : Model n} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ∃ m>0, ∀ d : Model n, m*‖d‖^2 ≤ + fderiv ℝ (fderiv ℝ (chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm z))) z d d := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let x := χ.symm z + have hx : x∈χ.source := χ.map_target hz + have hxz : χ x=z := χ.right_inv hz + change extChartAt 𝓘(ℝ,Model n) a x=z at hxz + have hp := zero_mem_injectivityDomain (n := n) x + obtain ⟨e,he,he0,hei,hinj⟩ := exists_smooth_chart_fiber_log hp + (show riemannianExp x 0∈χ.source from by rwa [riemannianExp_zero]) + simp only [riemannianExp_zero,hxz] at he he0 hei hinj + obtain ⟨m,hm,hbound⟩ := exists_norm_sq_lower_of_injective (fderiv ℝ e z) hinj + refine ⟨m,hm,fun d => ?_⟩ + have hC : ContDiffAt ℝ 2 (normalCost (n := n) x 0) 0 := + (normalCost_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hzero : fderiv ℝ (normalCost (n := n) x 0) 0=0 := by + rw [(normalCost_hasFDerivAt_zero hp).fderiv] + simp only [neg_zero,map_zero] + have heq : chartCost a x =ᶠ[𝓝 z] (fun w => normalCost (n := n) x 0 (e w)) := by + filter_upwards [hei] with w hw + simp only [normalCost,riemannianExp_zero,hw,chartCost] + rw [heq.fderiv.fderiv_eq] + have H := second_fderiv_comp_stationary (f := normalCost (n := n) x 0) (g := e) + (he0.symm ▸ hC) (he.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + (by rwa [he0]) d d + rw [H,he0] + change m*‖d‖^2 ≤ normalHessian x 0 (fderiv ℝ e z d) (fderiv ℝ e z d) + rw [←hessianValue_eq_normalHessian hp,hessianValue_zero] + exact hbound d + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DividedHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DividedHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..b124a0c10f64f460e687f21448a5919e68d6ec34 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/DividedHessian.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalEikonal + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section DividedHessian +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end DividedHessian +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CrossingValue +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma doubleNormalCost_self_contDiffAt {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈injectivityDomain x) : + ContDiffAt ℝ ∞ (doubleNormalCost (n := n) x x) (0,p) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + have hu : ContMDiffAt 𝓘(ℝ,X×X) 𝓘(ℝ,Model n) ∞ + (fun z : X×X => riemannianExp x z.1) (0,p) := + (contMDiff_riemannianExp_fiber x _).comp (0,p) contDiffAt_fst.contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,X×X) 𝓘(ℝ,Model n) ∞ + (fun z : X×X => riemannianExp x z.2) (0,p) := + (contMDiff_riemannianExp_fiber x _).comp (0,p) contDiffAt_snd.contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0:X),riemannianExp x p) := by + simpa only [riemannianExp_zero] using hc + exact (hc'.comp (0,p) (hu.prodMk hv)).contDiffAt + +def radialCrossingValue (x : M) (p v : TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + let B := doubleNormalCost x x + fderiv ℝ (fderiv ℝ B) (0,p) (v,0) (v,0) - + fderiv ℝ (fderiv ℝ (fderiv ℝ B)) (0,p) (0,p) (v,0) (v,0) +end CrossingValue +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EigenOrder.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EigenOrder.lean new file mode 100644 index 0000000000000000000000000000000000000000..7ccb5a5150d72b80947062a3249e50d08db0391c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EigenOrder.lean @@ -0,0 +1,47 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Module +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [CompleteSpace E] + +def bilinearOperator (B : E →L[ℝ] E →L[ℝ] ℝ) : E →L[ℝ] E := + (InnerProductSpace.toDual ℝ E).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp B + +@[simp] lemma bilinearOperator_inner (B : E →L[ℝ] E →L[ℝ] ℝ) (v w : E) : + inner ℝ (bilinearOperator B v) w=B v w := + InnerProductSpace.toDual_symm_apply + +lemma bilinearOperator_symmetric {B : E →L[ℝ] E →L[ℝ] ℝ} + (hB : ∀ v w:E, B v w=B w v) : (bilinearOperator B).toLinearMap.IsSymmetric := by + intro v w + change inner ℝ (bilinearOperator B v) w=inner ℝ v (bilinearOperator B w) + calc + _=B v w := bilinearOperator_inner B v w + _=B w v := hB v w + _=inner ℝ (bilinearOperator B w) v := (bilinearOperator_inner B w v).symm + _=inner ℝ v (bilinearOperator B w) := real_inner_comm _ _ + +lemma inverse_of_bilinear_pairing {B : E →L[ℝ] E →L[ℝ] ℝ} {R : E →L[ℝ] E} + (hR : ∀ v w:E, B (R v) w=inner ℝ v w) (v:E) : bilinearOperator B (R v)=v := by + exact ext_inner_right ℝ (fun w => by rw [bilinearOperator_inner,hR]) +variable [FiniteDimensional ℝ E] + +omit [CompleteSpace E] in +lemma left_inverse_of_right_inverse {D R : E →L[ℝ] E} + (hDR : ∀ v:E, D (R v)=v) (v:E) : R (D v)=v := by + have hsurj : Function.Surjective D := fun w => ⟨R w,hDR w⟩ + have hinj : Function.Injective D := D.toLinearMap.injective_iff_surjective.mpr hsurj + apply hinj + exact hDR (D v) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EndpointSpectrumBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EndpointSpectrumBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..feb09d1dbb0eb45e8eb9ac7298e1e2091e51707b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EndpointSpectrumBound.lean @@ -0,0 +1,166 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FiniteIntervalMesh +import OAI.Analysis.BiholderTransport.LinearAlgebra.ShearedSpectrum +import OAI.Analysis.BiholderTransport.LinearAlgebra.ConvexSpectrum +import OAI.Analysis.BiholderTransport.Regularity.SingularValuesBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section EndpointSpectrumBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_endpoint_singular_bound : + ∃ D : ℝ, 0 norm_num)).1 + have hj' : ∀ v : TangentSpace 𝓘(ℝ,Model n) x, + ‖endpointExpDifferential x ((1/2:ℝ) • p) v‖ ≤ u*‖v‖ := fun v => by + exact (hj v).2 + have hS := singularValues_le_of_bound (E := TangentSpace 𝓘(ℝ,Model n) x) + (F := TangentSpace 𝓘(ℝ,Model n) (riemannianExp x ((1/2:ℝ) • p))) (endpointExpDifferential x ((1/2:ℝ) • p)).toLinearMap + hu.le hj' rfl i + have hR := (H x p hp (1/2) (by constructor <;> norm_num) i).1 + rw [show (1:ℝ)-1/2=1/2 by norm_num] at hR + have HH := hR.trans hS + rw [le_div_iff₀ ha] + nlinarith only [HH,ha] +end EndpointSpectrumBound +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section AffineSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.uniform_extended_spectral_comparison + (hmtw : WeakMTW (n := n) (M := M)) {a₀ B : ℝ} (ha₀ : 0 (endpointExpDifferential x (p+t • q)).toLinearMap.singularValues i.rev + have hSym (δ : ℝ) (hd : δ∈Ioc (0:ℝ) (1/2)) (t : ℝ) (ht : t∈Icc (-a) 1) : + (shearedRadialOperator x p q δ t).toLinearMap.IsSymmetric := + shearedRadialOperator_symmetric (contracted_minimizer_mem_injectivityDomain (hline t ht) + (by linarith [hd.2]) (by linarith [hd.1])) + let f : ℝ → ℝ → ℝ := fun δ t => + if H : δ∈Ioc (0:ℝ) (1/2) ∧ t∈Icc (-a) 1 then (hSym δ H.1 t H.2).eigenvalues rfl i else 0 + have hf (δ : ℝ) (hd : δ∈Ioc (0:ℝ) (1/2)) (t : ℝ) (ht : t∈Icc (-a) 1) : + f δ t=(hSym δ hd t ht).eigenvalues rfl i := by + dsimp only [f] + rw [dite_eq_left (show δ∈Ioc (0:ℝ) (1/2) ∧ t∈Icc (-a) 1 from ⟨hd,ht⟩)] + have hI (t : ℝ) (ht : t∈Icc (0:ℝ) 1) : t∈Icc (-a) 1 := ⟨by linarith [ht.1],ht.2⟩ + have hSmall (t : ℝ) (ht : t∈Icc (0:ℝ) (1-e)) : t∈Icc (0:ℝ) 1 := + ⟨ht.1,by linarith [ht.2]⟩ + have hInt (t : ℝ) (ht : t∈Icc (0:ℝ) (1-e)) : t∈Icc (-a+d) (1-d) := by + have hda : d ≤ a := min_le_left _ _ + have hde : d ≤ e := min_le_right _ _ + constructor <;> linarith [ht.1,ht.2] + have h0 : (0:ℝ)∈Icc (-a) 1 := ⟨by linarith,by norm_num⟩ + have h1 : (1:ℝ)∈Icc (-a) 1 := ⟨by linarith,le_rfl⟩ + have hm : 1-e∈Icc (-a) 1 := ⟨by linarith,by linarith⟩ + have HS (t : ℝ) (ht : t∈Icc (0:ℝ) 1) : 0 ≤ s t := + (endpointExpDifferential x (p+t • q)).toLinearMap.singularValues_nonneg i.rev + have HD' : s 1 ≤ D := HD x (p+1 • q) (hline 1 h1) i.rev + have HP (δ : ℝ) (hd : δ∈Ioc (0:ℝ) (1/2)) (t : ℝ) (ht : t∈Icc (0:ℝ) 1) : + l*δ/(s t+δ)-b*δ ≤ f δ t ∧ f δ t ≤ u*δ/(s t+δ)+b*δ := by + obtain ⟨hF,H⟩ := HSp x p q hpq hβ hline δ hd t (hI t ht) + rw [hf δ hd t (hI t ht)] + exact H i + have HL (δ : ℝ) (hd : δ∈Ioc (0:ℝ) (1/2)) (r : ℝ) (hr : r∈Icc (0:ℝ) (1-e)) + (t : ℝ) (ht : t∈Icc (0:ℝ) (1-e)) : |f δ t-f δ r| ≤ K*|t-r| := by + rw [hf δ hd t (hI t (hSmall t ht)),hf δ hd r (hI r (hSmall r hr))] + exact bounded_matrix_convex_eigen_secant (hSym δ hd) + (hmtw.shearedRadialOperator_convexOn x p q hpq.ne' hd hline) hC.le hdpos + (fun t ht v => (HB x p q hpq hβ hline δ hd t ht v).2) + (hInt r hr) (hInt t ht) (hI r (hSmall r hr)) (hI t (hSmall t ht)) rfl i + have HE (δ : ℝ) (hd : δ∈Ioc (0:ℝ) (1/2)) : f δ (1-e) ≤ (1-e)*f δ 1+e*C := by + rw [hf δ hd (1-e) hm,hf δ hd 1 h1] + exact matrix_convex_eigen_endpoint ha.le ⟨he0.le,he1.le⟩ (hSym δ hd) + (hmtw.shearedRadialOperator_convexOn x p q hpq.ne' hd hline) + (fun v => (le_abs_self _).trans (HB x p q hpq hβ hline δ hd 0 h0 v).2) hm h1 rfl i + have result := HC s f HS HD' HP HL HE + have hz : p+(0:ℝ) • q=p := by simp + have ho : p+(1:ℝ) • q=p+q := by simp + have hsz : s 0=(endpointExpDifferential x p).toLinearMap.singularValues j := by + change (endpointExpDifferential x (p+(0:ℝ) • q)).toLinearMap.singularValues i.rev=_ + rw [hz,show i.rev=j from Fin.rev_rev j] + have hso : s 1=(endpointExpDifferential x (p+q)).toLinearMap.singularValues j := by + change (endpointExpDifferential x (p+(1:ℝ) • q)).toLinearMap.singularValues i.rev=_ + rw [ho,show i.rev=j from Fin.rev_rev j] + rwa [hsz,hso] at result +end AffineSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EnvelopeKernelHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EnvelopeKernelHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..5427e5649fb31c3a434de24e49fb305f60531d88 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/EnvelopeKernelHessian.lean @@ -0,0 +1,73 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.EnvelopePole + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma envelope_kernel_second_derivative {C : E×E → ℝ} {f : E → ℝ} + {a : E → E} {p : E} {R : E →L[ℝ] E} + (hC : ContDiffAt ℝ 2 C (a p,p)) + (ha : HasFDerivAt a R p) + (hf : ∀ᶠ q in 𝓝 p, DifferentiableAt ℝ f q) + (hsupport : ∀ᶠ q in 𝓝 p, ∀ᶠ v in 𝓝 q, + f v≤f q+C (a q,v)-C (a q,q)) : + ∀ d e:E, fderiv ℝ (fderiv ℝ f) p d e= + fderiv ℝ (fderiv ℝ C) (a p,p) (R d,d) (0,e) := by + let I : E →L[ℝ] E×E := (0 : E →L[ℝ] E).prod (ContinuousLinearMap.id ℝ E) + let G : E → E →L[ℝ] ℝ := fun q => (fderiv ℝ C (a q,q)).comp I + have hmap := ha.prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := ((hC.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun q => (a q,q)) p hmap + have hG := hd.clm_comp (hasFDerivAt_const I p) + have heq : fderiv ℝ f =ᶠ[𝓝 p] G := by + have hn := hmap.continuousAt.eventually (hC.eventually (by norm_num)) + filter_upwards [hf,hsupport,hn] with q hq hs hreg + let g : E → ℝ := fun v => f q+C (a q,v)-C (a q,q) + have hD := (hreg.differentiableAt (by norm_num)).hasFDerivAt.comp + (f := fun v : E => (a q,v)) q + ((hasFDerivAt_const (a q) q).prodMk (hasFDerivAt_id q)) + have hg : HasFDerivAt g (G q) q := by + convert! (hD.const_add (f q)).sub_const (C (a q,q)) using 1 + rw [upper_contact_fderiv hq hg.differentiableAt hs (by dsimp [g]; ring)] + exact hg.fderiv + intro d e + have H := congrArg (fun J : E →L[ℝ] E →L[ℝ] ℝ => J d e) + (hG.congr_of_eventuallyEq heq).fderiv + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,map_zero,ContinuousLinearMap.comp_zero, + add_zero,zero_add,add_apply,zero_apply,I] using H + +lemma envelope_selector_injective_of_hessian_gap {C : E×E → ℝ} {f : E → ℝ} + {a : E → E} {p : E} {R : E →L[ℝ] E} + (hC : ContDiffAt ℝ 2 C (a p,p)) (ha : HasFDerivAt a R p) + (hf : ∀ᶠ q in 𝓝 p,DifferentiableAt ℝ f q) + (hsupport : ∀ᶠ q in 𝓝 p, ∀ᶠ v in 𝓝 q, + f v≤f q+C (a q,v)-C (a q,q)) + {b k : ℝ} (hbk : b < k) + (hupper : ∀ d:E,fderiv ℝ (fderiv ℝ f) p d d≤b*‖d‖^2) + (hlower : ∀ d:E,k*‖d‖^2≤fderiv ℝ (fderiv ℝ C) (a p,p) (0,d) (0,d)) : + Function.Injective R := by + apply (LinearMap.ker_eq_bot).mp + apply LinearMap.ker_eq_bot'.mpr + intro d hd + change R d = 0 at hd + have H := envelope_kernel_second_derivative hC ha hf hsupport d d + rw [hd] at H + have hu := hupper d + have hl := hlower d + rw [H] at hu + have hz : ‖d‖^2=0 := by nlinarith only [hu,hl,hbk,sq_nonneg ‖d‖] + exact norm_eq_zero.mp (sq_eq_zero_iff.mp hz) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FinitePositiveWeight.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FinitePositiveWeight.lean new file mode 100644 index 0000000000000000000000000000000000000000..703cc2a88273bd46aea193e5dc8655a9ac00c275 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FinitePositiveWeight.lean @@ -0,0 +1,294 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma finite_positive_weight_exists_ge {ι : Type*} [Fintype ι] [Nonempty ι] + (w f : ι → ℝ) (hw : ∀ i, 00, ∀ᶠ h : E in 𝓝 0, ∃ i, b*‖h‖^2≤L i h+B i h h := by + let Q : E → ℝ := fun v => ∑ i, w i*B i v v + have hQ : Continuous Q := by + exact continuous_finsetSum _ (fun i _ => continuous_const.mul ((B i).continuous.clm_apply continuous_id)) + let K : Set E := {v | ‖v‖=1 ∧ ∀ i, L i v=0} + have hK : IsCompact K := by + have hc : IsClosed {v : E | ∀ i, L i v=0} := by + simpa only [Set.ofPred_forall] using + isClosed_iInter (fun i => isClosed_eq (L i).continuous (continuous_const (y := (0:ℝ)))) + exact (isCompact_sphere (0:E) 1).inter_right hc |>.of_isClosed_subset + (isClosed_eq continuous_norm continuous_const |>.inter hc) (by + intro v hv + exact ⟨by simpa [Metric.mem_sphere,dist_zero_right] using hv.1,hv.2⟩) + obtain ⟨b,hb,hbK⟩ : ∃ b>0, ∀ v ∈ K, b (hne ⟨v,hv⟩).elim⟩ + have hloc : ∀ u ∈ Metric.sphere (0:E) 1, ∀ᶠ z : ℝ × E in 𝓝 (0,u), + 0≤z.1 → ∃ i, z.1*b≤L i z.2+z.1*B i z.2 z.2 := by + intro u hu + by_cases hlin : ∃ i, 0 L i z.2+z.1*(B i z.2 z.2-b)) := by + exact ((L i).continuous.comp continuous_snd).add + (continuous_fst.mul (((B i).continuous.comp continuous_snd).clm_apply continuous_snd |>.sub continuous_const)) + have he : ∀ᶠ z : ℝ × E in 𝓝 (0,u), 0 L i u) hw + (by simpa only [not_exists,not_lt] using hlin) (hmean u) + have huK : u ∈ K := ⟨by simpa [Metric.mem_sphere,dist_zero_right] using hu,hall⟩ + have he : ∀ᶠ z : ℝ × E in 𝓝 (0,u), b L i z.2+z.1*B i z.2 z.2) hw hsum + have heq : (∑ i, w i*(L i z.2+z.1*B i z.2 z.2))=z.1*Q z.2 := by + simp only [mul_add,Finset.sum_add_distrib,hmean,zero_add,Q] + rw [Finset.mul_sum] + congr 1 + ext i + ring + rw [heq] + exact mul_le_mul_of_nonneg_left hz.le hr + have he : ∀ᶠ r : ℝ in 𝓝 0, ∀ u ∈ Metric.sphere (0:E) 1, + 0≤r → ∃ i, r*b≤L i u+r*B i u u := + (isCompact_sphere (0:E) 1).eventually_forall_of_forall_eventually hloc + have hnorm : Tendsto (fun h : E => ‖h‖) (𝓝 0) (𝓝 (0:ℝ)) := by simpa only [norm_zero] using (continuous_norm.tendsto (0:E)) + refine ⟨b,hb,?_⟩ + filter_upwards [hnorm.eventually he] with h hh + by_cases hz : h=0 + · obtain ⟨i⟩ := ‹Nonempty ι› + exact ⟨i,by simp [hz]⟩ + · let u := ‖h‖⁻¹ • h + have hn : 0<‖h‖ := norm_pos_iff.mpr hz + have hu : u ∈ Metric.sphere (0:E) 1 := by + simp only [Metric.mem_sphere,dist_zero_right,u,norm_smul,Real.norm_eq_abs,abs_inv,abs_norm] + exact inv_mul_cancel₀ hn.ne' + obtain ⟨i,hi⟩ := hh u hu hn.le + have hv : ‖h‖ • u=h := by simp [u,smul_smul,hn.ne'] + have hil := mul_le_mul_of_nonneg_left hi hn.le + refine ⟨i,?_⟩ + calc + b*‖h‖^2≤‖h‖*(L i u+‖h‖*B i u u) := by nlinarith [hil] + _ = L i h+B i h h := by + have hL : L i h=‖h‖*L i u := by + calc _ = L i (‖h‖ • u) := congrArg (L i) hv.symm + _ = _ := by simp only [map_smul,smul_eq_mul] + have hB : B i h h=‖h‖*(‖h‖*B i u u) := by + calc _ = B i (‖h‖ • u) (‖h‖ • u) := by rw [hv] + _ = _ := by simp only [map_smul,smul_apply,smul_eq_mul] + rw [hL,hB] + ring +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstMatrixLimit.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstMatrixLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..52b87bf8dedd8c5ba4b781dc619df0ebf8c4cd2e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstMatrixLimit.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingHessianLimit + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {Q E F : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma secondJetPullback_sum_nonpos + {j k : F →L[ℝ] ℝ} {A B : F →L[ℝ] F →L[ℝ] ℝ} + {m : E →L[ℝ] F} {r : E →L[ℝ] E →L[ℝ] F} + (hj : j+k=0) (hAB : ∀ d:F,A d d+B d d≤0) (e:E) : + secondJetPullback j A m r e e+secondJetPullback k B m r e e≤0 := by + have hs := congrArg (fun L:F →L[ℝ] ℝ=>L (r e e)) hj + simp only [add_apply,zero_apply] at hs + simp only [secondJetPullback_apply] + linarith only [hs,hAB (m e)] + +lemma first_fixed_prefix_matrix_limit {ι : Type*} + {W : Q → E → ℝ} {g : Q → E → F} {f h : F → ℝ} + {b : ℕ → Q} {p : ℕ → E} {b₀ : Q} {p₀ : E} + {v : ℕ → ι → E} {v₀ : ι → E} + {jf jh : F →L[ℝ] ℝ} {Af Ah : F →L[ℝ] F →L[ℝ] ℝ} + (hW : ContDiffAt ℝ ∞ (Function.uncurry W) (b₀,p₀)) + (hg : ContDiffAt ℝ ∞ (Function.uncurry g) (b₀,p₀)) + (hb : Tendsto b atTop (𝓝 b₀)) (hp : Tendsto p atTop (𝓝 p₀)) + (hv : ∀ i,Tendsto (fun k=>v k i) atTop (𝓝 (v₀ i))) + (hjf : Tendsto (fun k=>fderiv ℝ f (g (b k) (p k))) atTop (𝓝 jf)) + (hjh : Tendsto (fun k=>fderiv ℝ h (g (b k) (p k))) atTop (𝓝 jh)) + (hAf : Tendsto (fun k=>fderiv ℝ (fderiv ℝ f) (g (b k) (p k))) atTop (𝓝 Af)) + (hAh : Tendsto (fun k=>fderiv ℝ (fderiv ℝ h) (g (b k) (p k))) atTop (𝓝 Ah)) + (hDf : ∀ᶠ k in atTop,(∀ᶠ y in 𝓝 (g (b k) (p k)),DifferentiableAt ℝ f y) ∧ + DifferentiableAt ℝ (fderiv ℝ f) (g (b k) (p k))) + (hDh : ∀ᶠ k in atTop,(∀ᶠ y in 𝓝 (g (b k) (p k)),DifferentiableAt ℝ h y) ∧ + DifferentiableAt ℝ (fderiv ℝ h) (g (b k) (p k))) + (hgrad : jf+jh=0) (hquad : ∀ d:F,Af d d+Ah d d≤0) + (hpos : ∀ᶠ k in atTop,∀ d:E, + 0≤(fderiv ℝ (fderiv ℝ (W (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun q=>f (g (b k) q))) (p k)) d d) + (hker : ∀ᶠ k in atTop,∀ i:ι,∀ d:E, + (fderiv ℝ (fderiv ℝ (W (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun q=>f (g (b k) q))) (p k)) (v k i-p k) d=0) : + ∃ H L : E →L[ℝ] E →L[ℝ] ℝ, + Tendsto (fun k=>fderiv ℝ (fderiv ℝ (W (b k))) (p k)+ + fderiv ℝ (fderiv ℝ (fun q=>h (g (b k) q))) (p k)) atTop (𝓝 H) ∧ + Tendsto (fun k=>fderiv ℝ (fderiv ℝ (W (b k))) (p k)- + fderiv ℝ (fderiv ℝ (fun q=>f (g (b k) q))) (p k)) atTop (𝓝 L) ∧ + (∀ d:E,0≤L d d) ∧ (∀ i:ι,∀ d:E,L (v₀ i-p₀) d=0) ∧ + (∀ d:E,H d d≤L d d) := by + let T := fderiv ℝ (fderiv ℝ (W b₀)) p₀ + let m := fderiv ℝ (g b₀) p₀ + let r := fderiv ℝ (fderiv ℝ (g b₀)) p₀ + let F₀ := secondJetPullback jf Af m r + let G₀ := secondJetPullback jh Ah m r + have hT : Tendsto (fun k=>fderiv ℝ (fderiv ℝ (W (b k))) (p k)) atTop (𝓝 T) := + ((ContDiffAt.partial_snd_fderiv_two hW).continuousAt.tendsto).comp (hb.prodMk_nhds hp) + have hF := moving_rough_hessian_limit hg hb hp hjf hAf hDf + have hG := moving_rough_hessian_limit hg hb hp hjh hAh hDh + have hH := hT.add hG + have hL := hT.sub hF + refine ⟨T+G₀,T-F₀,hH,hL,fun d=>bilinear_limit_nonneg hL hpos d,?_,?_⟩ + · intro i d + exact bilinear_limit_kernel hL ((hv i).sub hp) (hker.mono (fun k hk=>hk i)) d + · intro d + have H := secondJetPullback_sum_nonpos (m := m) (r := r) hgrad hquad d + change T d d+G₀ d d≤T d d-F₀ d d + linarith only [H] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstRank.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstRank.lean new file mode 100644 index 0000000000000000000000000000000000000000..05e1fc8b338adc5f0c900038a116f49009a11bf0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FirstRank.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.UpperJacobianBarrier +import OAI.Analysis.BiholderTransport.Regularity.ActiveDifference +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartFirstMatrix + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FirstRank +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma ChartFixedPrefixLimit.positive_rank_direction + {a:M} {v G:M → ℝ} {t:ℝ} + {q:ℕ → subgradientGraph (n := n) (cTransform v)} + {q₀:subgradientGraph (n := n) (cTransform v)} + (J:ChartFixedPrefixLimit a v G t q q₀) + (hbase:q₀.1.1∈(extChartAt 𝓘(ℝ,Model n) a).source) : + let b:=graphBaseCoordinate a q₀.1 + let p:=graphVelocityCoordinate a q₀.1 + let E:=TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) + let κ:Type:={i:Fin (Module.finrank ℝ (Model n)+1) // 0chartFiberInverse a b (J.pj₀ i) + let P:E:=chartFiberInverse a b p + let S:=Submodule.span ℝ (range (fun i=>pj i-P)) + ∀ (A C:ℝ),0U (J.pj₀ i) + let P:E:=U p + let S:=Submodule.span ℝ (range (fun i=>pj i-P)) + have hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source hbase + have hx : x∈T.baseSet := by + simpa only [x,T,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hb + have hUV (d:E):U (V d)=d := T.symmL_continuousLinearMapAt (R := ℝ) hx d + have hVU (d:Model n):V (U d)=d := T.continuousLinearMapAt_symmL (R := ℝ) hx d + intro A C hA hbound level Bc Bo hprofiles hparameter + have hres:=positive_barycentric_restriction (fun i=>U (J.pj₀ i)) J.w₀ J.nonnegLimit J.totalLimit + let : Nonempty κ:=hres.1 + have hparam:0Bo (level (U (J.pj₀ i))))] + classical + have hS:S≠⊥:=active_difference_ne_bot hres.2.1 hprofiles hparam + let L:E →L[ℝ] E →L[ℝ] ℝ:=J.L.bilinearComp V V + have hk:S≤LinearMap.ker L.toLinearMap := by + apply Submodule.span_le.mpr + rintro _ ⟨i,rfl⟩ + change L (pj i-P)=0 + ext d + change J.L (V (U (J.pj₀ i)-U p)) (V d)=0 + rw [map_sub,hVU,hVU] + exact J.kernel i (V d) + apply unit_positive_direction_of_rank_one_semibound S hA hS + intro d hd + have hl:L d=0 := hk hd + have hzero:J.L (V d) (V d)=0 := congrArg (fun f:E →L[ℝ] ℝ=>f d) hl + have HH:=hbound (V d) + rw [hUV] at HH + have HU:=J.upper (V d) + rw [hzero] at HU + linarith only [HH,HU] + +end FirstRank +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FixedJoinSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FixedJoinSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..8cb691e54b71d56715b945e48983d8e379b3d6d7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FixedJoinSpectrum.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FixedJoinSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + +local instance tangentFiniteSpectrum (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma tangent_finrank (x : M) : finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x)=n := + finrank_euclideanSpace_fin +end FixedJoinSpectrum +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section EndpointJoinAction +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteEndpointJoin (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end EndpointJoinAction +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FrameDeterminantClosure.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FrameDeterminantClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..94fa5e7a787df9220eeecfe5b79388229849a4ab --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FrameDeterminantClosure.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ThreeDeterminantsClose +import OAI.Analysis.BiholderTransport.Regularity.FrameDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FrameDeterminantClosure +variable {n:ℕ} {M:Type*} [MetricSpace M] [CompactSpace M] [ConnectedSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.frame_determinant_closure (hmtw:WeakMTW (n:=n) (M:=M)) + {μ κ A χ K:ℝ} (hμ:0 < μ) (hκ:0 < κ) (hA:0 < A) (hχ:0 < χ) (hK:0 < K) : + ∃B:ℝ,0 < B ∧ ∀(ι:Type) [Fintype ι] (a c:M) + (r:ι → TangentSpace 𝓘(ℝ,Model n) a) (m:ι → ℝ) (q:TangentSpace 𝓘(ℝ,Model n) a), + (∀j,0 ≤ m j) → (∑j,m j=1) → (∀j,r j∈minimizingVectors a) → + (∑j,m j • r j=q) → ∀i (e:TangentSpace 𝓘(ℝ,Model n) a) (t D l lo:ℝ), + μ ≤ m i → ‖e‖=1 → 0 < t → 0 < D → 0 < inner ℝ q e → + κ*D ≤ (inner ℝ q e)^2 → ‖r i‖^2-‖q‖^2 ≤ A*D → r i=q+t • e → + l∈Icc (1/2:ℝ) 1 → l<1 → lo∈Icc (1:ℝ) 2 → 1 < lo → + ∀rc:TangentSpace 𝓘(ℝ,Model n) c,rc∈minimizingVectors c → + reverseRay (⟨c,l • rc⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩ → + ∀V W X:ℝ,0 < W → 0 < X → + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n* + (expJacobian a q)^2*χ ≤ expJacobian c rc*V → + expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (lo⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2)*W ≤ + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*lo^n*K* + (expJacobian a (r i))^2 → + X*V ≤ W → X ≤ B := by + have hc0:0 < (1/2:ℝ)^n*χ:=mul_pos (by positivity) hχ + have hC0:0 < (2:ℝ)^n*K:=mul_pos (by positivity) hK + obtain ⟨B,hB,HB⟩:=hmtw.uniform_three_determinant_closure hμ hκ hA hc0 + (show (0:ℝ)<1 by norm_num) hC0 + refine ⟨B,hB,?_⟩ + intro ι _ a c r m q hmn hmt hr hbar i e t D l lo hmi he ht hD hqe hqD hgap hri + hl hl1 hlo hlo1 rc hrc hrev V W X hW hX hdc hdo hXdet + have hl0:0 < l:=lt_of_lt_of_le (by norm_num) hl.1 + have hlo0:0 < lo:=zero_lt_one.trans hlo1 + have hrev':reverseRay (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨c,l • rc⟩:=by + rw [←hrev,reverseRay_reverseRay] + have hcontract:=contracted_minimizer_mem_injectivityDomain hrc hl0 hl1 + have hqID:q∈injectivityDomain a:=by + have H:=reverseRay_injectivityDomain (z:=⟨c,l • rc⟩) hcontract + rwa [hrev] at H + have hσ:=expJacobian_pos_of_injectivityDomain hqID + have hσti:0 < expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (lo⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2):=by + apply expJacobian_pos_of_injectivityDomain + exact contracted_minimizer_mem_injectivityDomain (reverseRay_minimizing (hr i)) + (inv_pos.mpr hlo0) ((inv_lt_one₀ hlo0).mpr hlo1) + let f:ℝ:=(chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2 + have hf:0 < f:=sq_pos_of_pos (frameNormDet_pos (mem_extChartAt_target a)) + have hlpow:(1/2:ℝ)^n ≤ l^n:=pow_le_pow_left₀ (by norm_num) hl.1 n + have hlopow:lo^n ≤ (2:ℝ)^n:=pow_le_pow_left₀ hlo0.le hlo.2 n + have hσc:0 < expJacobian c rc:=by + have hp:0 < f*l^n*(expJacobian a q)^2*χ:=by positivity + have hV:0 < expJacobian c rc*V:=hp.trans_le hdc + exact lt_of_le_of_ne (expJacobian_nonneg c rc) (by + intro hzero + rw [←hzero,zero_mul] at hV + exact (lt_irrefl (0:ℝ)) hV) + have hσi:0 < expJacobian a (r i):=by + have hp:0 < expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (lo⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2)*W:=mul_pos hσti hW + have H:=hp.trans_le hdo + exact lt_of_le_of_ne (expJacobian_nonneg a (r i)) (by + intro hz + rw [←hz,zero_pow (by decide),mul_zero] at H + exact (lt_irrefl (0:ℝ)) H) + have hlow:((1/2:ℝ)^n*χ)*(expJacobian a q)^2/expJacobian c rc ≤ V/f:=by + apply (div_le_div_iff₀ hσc hf).mpr + have H:=mul_le_mul_of_nonneg_right hlpow + (show 0 ≤ f*(expJacobian a q)^2*χ by positivity) + dsimp only [f] at H + nlinarith only [H,hdc] + have hupper:W/f≤((2:ℝ)^n*K)*(expJacobian a (r i))^2/ + expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (lo⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2):=by + apply (div_le_div_iff₀ hf hσti).mpr + have H:=mul_le_mul_of_nonneg_right hlopow + (show 0 ≤ f*K*(expJacobian a (r i))^2 by positivity) + dsimp only [f] at H + nlinarith only [H,hdo] + have hratio:(1:ℝ)*X*(V/f)≤W/f:=by + rw [one_mul,←mul_div_assoc] + exact (div_le_div_iff_of_pos_right hf).mpr hXdet + refine HB ι a r m q hmn hmt hr hbar.symm i e t D hmi he ht hD hqe hqD hgap hri l hl lo hlo + ?_ hσ hσi ?_ hσti (V/f) (W/f) X hX ?_ hupper hratio + · rw [hrev'] + simpa only [smul_smul,inv_mul_cancel₀ hl0.ne',one_smul] using hrc + · rw [hrev'] + simpa only [smul_smul,inv_mul_cancel₀ hl0.ne',one_smul] using hσc + · rw [hrev'] + simpa only [smul_smul,inv_mul_cancel₀ hl0.ne',one_smul] using hlow + +end FrameDeterminantClosure +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FunctionalCoercive.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FunctionalCoercive.lean new file mode 100644 index 0000000000000000000000000000000000000000..fbbf4d666fec3aeda80a9dd98c46902eb48684a6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/FunctionalCoercive.lean @@ -0,0 +1,59 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section FunctionalCoercive +variable {E:Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma functional_rank_one_positive + {L V:E →L[ℝ] E →L[ℝ] ℝ} {f g:E →L[ℝ] ℝ} {e:E} {β m γ:ℝ} + (hLs:∀d e,L d e=L e d) (hL:∀d,0 ≤ L d d) + (hV:∀d,d≠0 → 0 < V d d) + (hVL:∀d,V d d ≤ L d d+β*(f d)^2) + (hker:∀d,L e d=0) (hf:f e≠0) (hg:g e≠0) + (hm:0 < m) (hγ:0 < γ) : + ∀d:E,d≠0 → 0 < m*L d d+γ*(g d)^2 := by + intro d hd + have hnon:0 ≤ m*L d d+γ*(g d)^2:= + add_nonneg (mul_nonneg hm.le (hL d)) (mul_nonneg hγ.le (sq_nonneg _)) + by_contra H + have hz:m*L d d+γ*(g d)^2=0:=le_antisymm (not_lt.mp H) hnon + have hLd:L d d=0:=by + have :m*L d d=0:=by nlinarith only [hz,mul_nonneg hm.le (hL d),mul_nonneg hγ.le (sq_nonneg (g d))] + exact (mul_eq_zero.mp this).resolve_left hm.ne' + have hgd:g d=0:=by + have :γ*(g d)^2=0:=by rw [hLd,mul_zero,zero_add] at hz; exact hz + exact sq_eq_zero_iff.mp ((mul_eq_zero.mp this).resolve_left hγ.ne') + let a:=f d/f e + let w:=d-a • e + have hfw:f w=0:=by + dsimp only [w,a] + rw [map_sub,map_smul,smul_eq_mul,div_mul_cancel₀ _ hf,sub_self] + have hLw:L w w=0:=by + dsimp only [w] + simp only [map_sub,map_smul,sub_apply,smul_apply, + smul_eq_mul,hker,hLs d e,hLd,mul_zero,sub_zero] + have hw:w=0:=by + by_contra hw + have H:=hVL w + rw [hfw,hLw,pow_two,mul_zero,mul_zero,add_zero] at H + exact (not_lt_of_ge H) (hV w hw) + have hdw:d=a • e:=sub_eq_zero.mp hw + have ha:a=0:=by + rw [hdw,map_smul,smul_eq_mul] at hgd + exact (mul_eq_zero.mp hgd).resolve_right hg + exact hd (by rw [hdw,ha,zero_smul]) +end FunctionalCoercive +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HalfCostUniform.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HalfCostUniform.lean new file mode 100644 index 0000000000000000000000000000000000000000..82166f12f13e4a21296a97089a740f5bca601094 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HalfCostUniform.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.CostSmooth +import OAI.Analysis.BiholderTransport.Coordinates.ChartCostJets + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma uniform_half_cost_hessian (a : M) : + ∃ B>0, ∃ r>0, + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀ x∈ball (extChartAt 𝓘(ℝ,Model n) a a) r, + ∀ p : TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm x), + p∈minimizingVectors ((extChartAt 𝓘(ℝ,Model n) a).symm x) → + ∀ z∈ball (extChartAt 𝓘(ℝ,Model n) a a) r, + ContDiffAt ℝ 2 (chartCost a (riemannianExp _ ((1/2:ℝ) • p))) z ∧ + ‖fderiv ℝ (fderiv ℝ (chartCost a (riemannianExp _ ((1/2:ℝ) • p)))) z‖≤B := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let z₀ := χ a + let Y : TangentBundle 𝓘(ℝ,Model n) M → M := fun V => riemannianExp V.1 ((1/2:ℝ) • V.2) + have hY : Continuous Y := contMDiff_riemannianExp.continuous.comp + (contMDiff_tangentScale.continuous.comp (continuous_const.prodMk continuous_id)) + have haT : z₀∈χ.target := χ.map_source (mem_extChartAt_source a) + have hχ : ContinuousAt χ.symm z₀ := + (continuousOn_extChartAt_symm a z₀ haT).continuousAt ((isOpen_extChartAt_target a).mem_nhds haT) + have hproj : Continuous (fun V : TangentBundle 𝓘(ℝ,Model n) M => V.1) := + FiberBundle.continuous_proj _ _ + have hg : ContinuousAt (fun q : Model n×Model n => χ.symm q.1) (z₀,z₀) := + hχ.comp (x := (z₀,z₀)) (f := fun q : Model n×Model n => q.1) continuousAt_fst + have hloc : ∀ V : TangentBundle 𝓘(ℝ,Model n) M, + V.2∈minimizingVectors V.1 → V.1=χ.symm z₀ → + ContinuousAt (fun q : Model n×M => fderiv ℝ (fderiv ℝ (chartCost a q.2)) q.1) (z₀,Y V) ∧ + ∀ᶠ q : Model n×M in 𝓝 (z₀,Y V), ContDiffAt ℝ 2 (chartCost a q.2) q.1 := by + intro V hV he + apply chartCost_jet_continuous haT + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨V.1,(1/2:ℝ) • V.2⟩ : TangentBundle 𝓘(ℝ,Model n) M) + (contracted_minimizer_mem_injectivityDomain hV (by norm_num : (0:ℝ)<1/2) (by norm_num : (1/2:ℝ)<1)) + change ContMDiffAt _ _ ∞ (fun q : M×M => cost q.1 q.2) (χ.symm z₀,Y V) + rw [←he] + exact hc + let H := fun q : (Model n×Model n)×TangentBundle 𝓘(ℝ,Model n) M => + fderiv ℝ (fderiv ℝ (chartCost a (Y q.2))) q.1.2 + have hc : Continuous (fun q : (Model n×Model n)×TangentBundle 𝓘(ℝ,Model n) M => + (q.1.2,Y q.2)) := continuous_fst.snd.prodMk (hY.comp continuous_snd) + obtain ⟨B,hB,hBnear⟩ := compact_eventually_fiberwise_bound isCompact_total_minimizingVectors + hproj hg (h := H) (fun V hV he => by + convert (hloc V hV he).1.comp + (x := ((z₀,z₀),V)) (f := fun q : (Model n×Model n)×TangentBundle 𝓘(ℝ,Model n) M => (q.1.2,Y q.2)) hc.continuousAt using 1 + rfl) + have hSnear : ∀ᶠ q : Model n×Model n in 𝓝 (z₀,z₀), + ∀ V : TangentBundle 𝓘(ℝ,Model n) M, V.2∈minimizingVectors V.1 → V.1=χ.symm q.1 → + ContDiffAt ℝ 2 (chartCost a (Y V)) q.2 := by + apply compact_eventually_fiberwise isCompact_total_minimizingVectors hproj hg + intro V hV he + exact (hc.continuousAt (x := ((z₀,z₀),V))).tendsto.eventually (hloc V hV he).2 + obtain ⟨r₁,hr₁,hr⟩ := Metric.eventually_nhds_iff.mp (hSnear.and hBnear) + obtain ⟨r₂,hr₂,hrT⟩ := Metric.mem_nhds_iff.mp ((isOpen_extChartAt_target a).mem_nhds haT) + refine ⟨B,hB,min r₁ r₂,lt_min hr₁ hr₂,?_,?_⟩ + · exact fun x hx => hrT (ball_subset_ball (min_le_right _ _) hx) + · intro x hx p hp z hz + have hpair : dist (x,z) (z₀,z₀) x+t • v + have hL (t : ℝ) : HasDerivAt L v t := by + convert! (hasDerivAt_const t x).add ((hasDerivAt_id t).smul_const v) using 1 + simp + have hL0 : L 0 = x := by simp [L] + have hcont : ContinuousAt (fun t => f (L t)) 0 := by + apply ContinuousAt.comp _ (hL 0).continuousAt + simpa only [hL0] using hf.continuousAt + have hmin : IsLocalMin (fun t => f (L t)) 0 := + (show IsLocalMin f (L 0) by rwa [hL0]).comp_continuous (hL 0).continuousAt + have heq : deriv (fun t => f (L t)) =ᶠ[𝓝 (0:ℝ)] + fun t => fderiv ℝ f (L t) v := by + have hnear : ∀ᶠ t in 𝓝 (0:ℝ), ContDiffAt ℝ 2 f (L t) := by + apply (show Tendsto L (𝓝 0) (𝓝 x) by simpa only [ContinuousAt,hL0] using (hL 0).continuousAt).eventually + exact hf.eventually (by norm_num) + filter_upwards [hnear] with t ht + exact ((ht.differentiableAt (by norm_num)).hasFDerivAt.comp_hasDerivAt t (hL t)).deriv + have hdf : DifferentiableAt ℝ (fderiv ℝ f) x := + (hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hd : HasDerivAt (fun t => fderiv ℝ f (L t) v) + (fderiv ℝ (fderiv ℝ f) x v v) 0 := by + have hfd : HasFDerivAt (fderiv ℝ f) (fderiv ℝ (fderiv ℝ f) x) (L 0) := by + rw [hL0]; exact hdf.hasFDerivAt + have hd0 := (hfd.comp_hasDerivAt 0 (hL 0)).clm_apply (hasDerivAt_const 0 v) + convert! hd0 using 1 + simp + have hh := localMin_second_deriv_nonneg hmin hcont + rwa [heq.deriv_eq,hd.deriv] at hh + +lemma symmetric_nonneg_bilinear_null {B : E →L[ℝ] E →L[ℝ] ℝ} + (hs : ∀ u v, B u v = B v u) (hp : ∀ u, 0 ≤ B u u) + {v : E} (hv : B v v = 0) (w : E) : B v w = 0 := by + let f : ℝ → ℝ := fun t => B (v+t • w) (v+t • w) + have hmin : IsLocalMin f 0 := by + filter_upwards [] with t + simpa only [f,zero_smul,add_zero,hv] using hp (v+t • w) + have heq : f = fun t => 2*t*(B v w)+t^2*(B w w) := by + funext t + simp only [f,map_add,map_smul,add_apply,smul_apply,smul_eq_mul,hv,hs w v] + ring + have hd : HasDerivAt f (2*B v w) 0 := by + rw [heq] + convert! (((hasDerivAt_id (0:ℝ)).const_mul 2).mul_const (B v w)).add + (((hasDerivAt_id (0:ℝ)).pow 2).mul_const (B w w)) using 1 + norm_num + have hh := hmin.hasDerivAt_eq_zero hd + linarith + +lemma localMin_hessian_null {f : E → ℝ} {x v : E} + (hf : ContDiffAt ℝ 2 f x) (hm : IsLocalMin f x) + (hv : fderiv ℝ (fderiv ℝ f) x v v = 0) (w : E) : + fderiv ℝ (fderiv ℝ f) x v w = 0 := by + exact symmetric_nonneg_bilinear_null + (hf.isSymmSndFDerivAt (by simp)).eq (localMin_hessian_nonneg hf hm) hv w + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianBounds.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..e51ebba80e0708bce3912fe606d3eb9e018b9734 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianBounds.lean @@ -0,0 +1,126 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianCoordinates +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactLocalPositiveBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section HessianBounds +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma eventually_normalHessian_bounds {c : TangentBundle 𝓘(ℝ,Model n) M} + (hc : c.2∈injectivityDomain c.1) : + ∃ C : ℝ, 0 TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let U := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let V := (Model n×Model n)×Model n + let : NormedAddCommGroup V := inferInstanceAs (NormedAddCommGroup ((Model n×Model n)×Model n)) + let : NormedSpace ℝ V := inferInstanceAs (NormedSpace ℝ ((Model n×Model n)×Model n)) + let : NormedAddCommGroup (V →L[ℝ] ℝ) := inferInstance + let : NormedSpace ℝ (V →L[ℝ] ℝ) := inferInstance + let : NormedAddCommGroup (V →L[ℝ] V →L[ℝ] ℝ) := inferInstance + let : SeminormedAddGroup (V →L[ℝ] V →L[ℝ] ℝ) := inferInstance + let B : TangentBundle 𝓘(ℝ,Model n) M → (V →L[ℝ] V →L[ℝ] ℝ) := fun z => + fderiv ℝ (fderiv ℝ (coordinateNormalCost c)) (χ z,0) + have hG := (coordinateNormalCost_contDiffAt c c (mem_extChartAt_source c) hc).of_le + (m := 3) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 3) + have hD : ContinuousAt (fderiv ℝ (fderiv ℝ (coordinateNormalCost c))) (χ c,(0:Model n)) := + ((hG.fderiv_right (m := 2) (by norm_num)).fderiv_right + (m := 1) (by norm_num)).continuousAt + have hχ := (contMDiffAt_extChartAt (I := 𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (n := ∞) (x := c)).continuousAt + have hmap : ContinuousAt (fun z : TangentBundle 𝓘(ℝ,Model n) M => (χ z,(0:Model n))) c := + hχ.prodMk continuousAt_const + have hBc : ContinuousAt B c := ContinuousAt.comp + (f := fun z : TangentBundle 𝓘(ℝ,Model n) M => (χ z,(0:Model n))) + (g := fderiv ℝ (fderiv ℝ (coordinateNormalCost c))) hD hmap + have hBb : ∀ᶠ z in 𝓝 c, ‖B z‖<‖B c‖+1 := hBc.norm.eventually + (gt_mem_nhds (by linarith : ‖B c‖<‖B c‖+1)) + obtain ⟨CU,hCU,hUb⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + have hproj : Continuous (fun z : TangentBundle 𝓘(ℝ,Model n) M => z.1) := + (Bundle.contMDiff_proj (n := ∞) (IB := 𝓘(ℝ,Model n)) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)).continuous + refine ⟨(‖B c‖+1)*CU*CU,by positivity,?_⟩ + filter_upwards [hBb,hproj.continuousAt.eventually hUb, + extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c, + isOpen_total_injectivityDomain.mem_nhds hc] with z hz hU hzχ hzI + intro v w + rw [normalHessian_coordinate_form c z hzχ hzI v w] + change ‖B z (0,U.continuousLinearMapAt ℝ z.1 v) (0,U.continuousLinearMapAt ℝ z.1 w)‖≤_ + have hv : ‖(U.continuousLinearMapAt ℝ z.1) v‖≤CU*‖v‖ := + ((U.continuousLinearMapAt ℝ z.1).le_opNorm v).trans + (mul_le_mul_of_nonneg_right hU.le (norm_nonneg v)) + have hw : ‖(U.continuousLinearMapAt ℝ z.1) w‖≤CU*‖w‖ := + ((U.continuousLinearMapAt ℝ z.1).le_opNorm w).trans + (mul_le_mul_of_nonneg_right hU.le (norm_nonneg w)) + have hv' : ‖((0:Model n×Model n),U.continuousLinearMapAt ℝ z.1 v)‖≤CU*‖v‖ := by simpa using hv + have hw' : ‖((0:Model n×Model n),U.continuousLinearMapAt ℝ z.1 w)‖≤CU*‖w‖ := by simpa using hw + calc + _ ≤ ‖B z‖*‖(0,U.continuousLinearMapAt ℝ z.1 v)‖*‖(0,U.continuousLinearMapAt ℝ z.1 w)‖ := + ((B z _).le_opNorm _).trans (mul_le_mul_of_nonneg_right + ((B z).le_opNorm _) (norm_nonneg _)) + _ ≤ (‖B c‖+1)*(CU*‖v‖)*(CU*‖w‖) := + mul_le_mul (mul_le_mul hz.le hv' (norm_nonneg _) (by positivity)) hw' + (norm_nonneg _) (by positivity) + _ = _ := by ring + +lemma compact_normalHessian_bounds {K : Set (TangentBundle 𝓘(ℝ,Model n) M)} + (hK : IsCompact K) (hI : ∀ z∈K, z.2∈injectivityDomain z.1) : + ∃ C : ℝ, 0 ∀ v w : TangentSpace 𝓘(ℝ,Model n) z.1, + |normalHessian z.1 z.2 v w|≤C*‖v‖*‖w‖) hK (by + intro r R b B hr hrR hbB z hz v w + exact (hz v w).trans (mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_right hbB (norm_nonneg v)) (norm_nonneg w))) (by + intro z hz + obtain ⟨C,hC,H⟩ := eventually_normalHessian_bounds (hI z hz) + exact ⟨1,C,by norm_num,hC,H⟩) + exact ⟨C,hC,H⟩ + +lemma uniform_prefixHessian_bounds : + ∃ C : ℝ, 0 tangentScale q.1 q.2 + have hP : Continuous P := contMDiff_tangentScale.continuous + have hS : IsCompact S := isCompact_Icc.prod (isCompact_total_minimizingVectors (n := n) (M := M)) + obtain ⟨C,hC,H⟩ := compact_normalHessian_bounds (hS.image hP) (by + intro w hw + rcases hw with ⟨⟨t,z⟩,htz,rfl⟩ + exact contracted_minimizer_mem_injectivityDomain htz.2 (by linarith [htz.1.1]) + (by linarith [htz.1.2])) + refine ⟨C,hC,?_⟩ + intro x p hp t ht + exact H (P (t,⟨x,p⟩)) (mem_image_of_mem _ ⟨ht,hp⟩) + +end HessianBounds +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianCoordinates.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..d4341c0a6958e7f647d770ea52f629da99d1d7ac --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianCoordinates.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ActualRadial +import OAI.Analysis.BiholderTransport.Coordinates.SplitLogInjective +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeSlice + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section HessianCoordinates +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def coordinateNormalCost (c : TangentBundle 𝓘(ℝ,Model n) M) + (q : (Model n×Model n)×Model n) : ℝ := + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let a := χ.symm (q.1.1,q.2) + let b := χ.symm q.1 + cost (riemannianExp a.1 a.2) (riemannianExp b.1 b.2) + +lemma coordinateNormalCost_contDiffAt (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) + (hp : z.2∈injectivityDomain z.1) : + ContDiffAt ℝ ∞ (coordinateNormalCost c) + (extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c z,0) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let Q := (χ z,(0:Model n)) + let τ := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let L := τ.continuousLinearEquivAt ℝ z.1 (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz) + have hzero : χ.symm ((χ z).1,0)=(⟨z.1,0⟩ : TangentBundle 𝓘(ℝ,Model n) M) := by + simpa only [map_zero] using tangent_chart_fiber_inverse c z hz (0:Model n) + have hs0 : ((χ z).1,(0:Model n))∈χ.target := by + have hf : χ (⟨z.1,0⟩ : TangentBundle 𝓘(ℝ,Model n) M)=((χ z).1,0) := by + apply Prod.ext + · rfl + · change L 0=0 + exact map_zero _ + rw [←hf] + exact χ.map_source ((tangent_chart_source_iff c _).mpr ((tangent_chart_source_iff c z).mp hz)) + have hχ0 : ContMDiffAt 𝓘(ℝ,Model n×Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + χ.symm ((χ z).1,0) := + (contMDiffOn_extChartAt_symm c).contMDiffAt ((isOpen_extChartAt_target c).mem_nhds hs0) + have hχp : ContMDiffAt 𝓘(ℝ,Model n×Model n) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + χ.symm (χ z) := + (contMDiffOn_extChartAt_symm c).contMDiffAt ((isOpen_extChartAt_target c).mem_nhds (χ.map_source hz)) + have hA := (contMDiff_riemannianExp.contMDiffAt.comp ((χ z).1,0) hχ0).comp Q + ((contDiffAt_fst.fst.prodMk contDiffAt_snd).contMDiffAt) + have hB := (contMDiff_riemannianExp.contMDiffAt.comp (χ z) hχp).comp Q + contDiffAt_fst.contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain z hp + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) + (riemannianExp (χ.symm ((χ z).1,0)).1 (χ.symm ((χ z).1,0)).2, + riemannianExp (χ.symm (χ z)).1 (χ.symm (χ z)).2) := by + rw [hzero,χ.left_inv hz,riemannianExp_zero] + exact hC + exact (hC'.comp Q (hA.prodMk hB)).contDiffAt + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinateNormalCost_slice (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) : + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let τ := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + let L := τ.continuousLinearEquivAt ℝ z.1 (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz) + (fun a => coordinateNormalCost c (χ z,a))=normalCost z.1 z.2 ∘ L.symm := by + intro χ τ L + funext a + dsimp only [coordinateNormalCost] + rw [tangent_chart_fiber_inverse c z hz a,χ.left_inv hz] + rfl + +lemma normalHessian_coordinate_form (c z : TangentBundle 𝓘(ℝ,Model n) M) + (hz : z∈(extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c).source) + (hp : z.2∈injectivityDomain z.1) (v w : TangentSpace 𝓘(ℝ,Model n) z.1) : + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) c + let τ := trivializationAt (Model n) (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c.1 + normalHessian z.1 z.2 v w= + fderiv ℝ (fderiv ℝ (coordinateNormalCost c)) (χ z,0) + (0,τ.continuousLinearMapAt ℝ z.1 v) (0,τ.continuousLinearMapAt ℝ z.1 w) := by + intro χ τ + let L := τ.continuousLinearEquivAt ℝ z.1 (by simpa only [τ,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (tangent_chart_source_iff c z).mp hz) + have hB := (coordinateNormalCost_contDiffAt c z hz hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have H := second_derivative_target_slice hB (L v) (L w) + rw [coordinateNormalCost_slice c z hz] at H + have hs := (normalCost_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hs' : ContDiffAt ℝ 2 (normalCost z.1 z.2) (L.symm (0:Model n)) := by + simpa only [map_zero] using hs + have HH := second_derivative_linear_sandwich (L.symm : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) z.1) + (ContinuousLinearMap.id ℝ ℝ) hs' (L v) (L w) + simp only [id_apply,map_zero] at HH + change fderiv ℝ (fderiv ℝ (normalCost z.1 z.2 ∘ L.symm)) 0 (L v) (L w)= + normalHessian z.1 z.2 (L.symm (L v)) (L.symm (L w)) at HH + rw [L.symm_apply_apply,L.symm_apply_apply] at HH + have Hfinal := HH.symm.trans H + simpa only [L,Trivialization.coe_continuousLinearEquivAt_eq] using Hfinal + +end HessianCoordinates +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianMixedOperator.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianMixedOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..282e7e0891d2fda1c7bd12f5edfba9d2b677250a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/HessianMixedOperator.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.InverseProfile +import OAI.Analysis.BiholderTransport.LinearAlgebra.MixedOperator +import OAI.Analysis.BiholderTransport.Coordinates.ExpReciprocity +import OAI.Analysis.BiholderTransport.Coordinates.NormalEndpointJoin + +namespace OAI + +noncomputable section +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [NormedAddCommGroup F] [InnerProductSpace ℝ F] + +local instance productNormedSpace : NormedSpace ℝ (F×E) := Prod.normedSpace +local instance productNormedGroup : NormedAddCommGroup (F×E) := Prod.normedAddCommGroup +local instance productDualNormedGroup : NormedAddCommGroup ((F×E) →L[ℝ] ℝ) := inferInstance +local instance productDualNormedSpace : NormedSpace ℝ ((F×E) →L[ℝ] ℝ) := inferInstance + +def negativeMixedForm (H : (F×E) →L[ℝ] (F×E) →L[ℝ] ℝ) : F →L[ℝ] E →L[ℝ] ℝ := by + let I : F →L[ℝ] F×E := (ContinuousLinearMap.id ℝ F).prod 0 + let K : E →L[ℝ] F×E := (0:E →L[ℝ] F).prod (ContinuousLinearMap.id ℝ E) + exact -((H.comp I).flip.comp K).flip + +@[simp] lemma negativeMixedForm_apply (H : (F×E) →L[ℝ] (F×E) →L[ℝ] ℝ) + (v : F) (w : E) : negativeMixedForm H v w= -H (v,0) (0,w) := rfl +end WeakMTWTransport + + + + +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +local instance tangentFiniteNormalMixed (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +local instance endpointProductNormedGroup (x y : M) : + NormedAddCommGroup (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := + Prod.normedAddCommGroup +local instance endpointProductNormedSpace (x y : M) : + NormedSpace ℝ (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := + Prod.normedSpace +local instance endpointDualNormedGroup (x y : M) : + NormedAddCommGroup ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := + inferInstance +local instance endpointDualNormedSpace (x y : M) : + NormedSpace ℝ ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := + inferInstance + +def normalEndpointMixedOperator (x y : M) (h : ℝ) + (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x := + mixedOperator (negativeMixedForm + (fderiv ℝ (fderiv ℝ (normalEndpointJoinAction x y h)) (0,p))) + +@[simp] lemma normalEndpointMixedOperator_inner (x y : M) (h : ℝ) + (p k : TangentSpace 𝓘(ℝ,Model n) x) (d : TangentSpace 𝓘(ℝ,Model n) y) : + inner ℝ (normalEndpointMixedOperator x y h p d) k= + -fderiv ℝ (fderiv ℝ (normalEndpointJoinAction x y h)) (0,p) (d,0) (0,k) := by + rw [normalEndpointMixedOperator,mixedOperator_inner,negativeMixedForm_apply] + +variable [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma normalEndpoint_operator_adjoint_factor {x y : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + {L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hh : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma hessianValue_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ injectivityDomain x) (xi : TangentSpace 𝓘(ℝ,Model n) x) : + ContDiffAt ℝ ∞ (fun v => hessianValue x v xi) p := by + have exp_smooth := contMDiff_riemannianExp_fiber (n := n) x + have hA : ContMDiffAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x × ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : TangentSpace 𝓘(ℝ,Model n) x × ℝ => riemannianExp x (q.2 • xi)) (p,(0:ℝ)) := + (exp_smooth _).comp (p,(0:ℝ)) (contDiffAt_snd.smul contDiffAt_const).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x × ℝ) 𝓘(ℝ,Model n) ∞ + (fun q : TangentSpace 𝓘(ℝ,Model n) x × ℝ => riemannianExp x q.1) (p,(0:ℝ)) := + (exp_smooth _).comp (p,(0:ℝ)) contDiffAt_fst.contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x ((0:ℝ) • xi),riemannianExp x p) := by + simpa only [zero_smul,riemannianExp_zero] using hC + have hF : ContDiffAt ℝ ∞ (Function.uncurry + (fun v : TangentSpace 𝓘(ℝ,Model n) x => fun t : ℝ => + cost (riemannianExp x (t • xi)) (riemannianExp x v))) (p,(0:ℝ)) := + by + have H := (hC'.comp (p,(0:ℝ)) (hA.prodMk hB)).contDiffAt + apply H.congr_of_eventuallyEq + exact Filter.Eventually.of_forall (fun _ => rfl) + exact contDiffAt_iteratedDeriv_parameter hF 2 + +lemma WeakMTW.transverse_concaveOn_injectivityDomain + (hmtw : WeakMTW (n := n) (M := M)) + (x : M) (p xi eta : TangentSpace 𝓘(ℝ,Model n) x) + {D : Set ℝ} (hD : Convex ℝ D) + (hline : ∀ s ∈ D, p + s • eta ∈ injectivityDomain x) + (hortho : inner ℝ xi eta = 0) : + ConcaveOn ℝ D (fun t : ℝ => hessianValue x (p+t • eta) xi) := by + have hsmooth : ∀ s ∈ D, ContDiffAt ℝ ∞ (fun t : ℝ => hessianValue x (p+t • eta) xi) s := by + intro s hs + exact (hessianValue_contDiffAt (hline s hs) xi).comp s + (contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const)) + apply hmtw.transverse_concaveOn x p xi eta hD + (fun s hs => hline s (interior_subset hs)) hortho + · intro s hs + exact (hsmooth s hs).continuousAt.continuousWithinAt + · intro s hs + exact ((hsmooth s (interior_subset hs)).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffWithinAt + +end + +open Set Filter +open scoped ContDiff Topology + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma iteratedDeriv_two_affine_line {f : E → ℝ} {x : E} + (hf : ContDiffAt ℝ 2 f x) (v : E) : + iteratedDeriv 2 (fun t : ℝ => f (x+t • v)) 0 = + fderiv ℝ (fderiv ℝ f) x v v := by + let L : ℝ → E := fun t => x+t • v + have hL (t : ℝ) : HasDerivAt L v t := by + convert! (hasDerivAt_const t x).add ((hasDerivAt_id t).smul_const v) using 1 + simp + have hL0 : L 0=x := by simp [L] + have hLc : ContDiffAt ℝ 2 L 0 := contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const) + have hL2 : iteratedDeriv 2 L 0=0 := by + rw [iteratedDeriv_succ,iteratedDeriv_one] + have heq : deriv L=fun _ => v := funext (fun t => (hL t).deriv) + rw [heq,deriv_const] + have hf' : ContDiffAt ℝ 2 f (L 0) := by rwa [hL0] + have H := iteratedDeriv_vcomp_two hf' hLc + simpa only [Function.comp_def,hL0,(hL 0).deriv,hL2,map_zero,add_zero, + iteratedFDeriv_two_apply] using H + +lemma directional_fderiv_hasDerivAt {f : E → ℝ} {x : E} + (hf : ContDiffAt ℝ 2 f x) (v w : E) : + HasDerivAt (fun t : ℝ => fderiv ℝ f (x+t • v) w) + (fderiv ℝ (fderiv ℝ f) x v w) 0 := by + have hdf : DifferentiableAt ℝ (fderiv ℝ f) x := + (hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hline : HasDerivAt (fun t : ℝ => x+t • v) v 0 := by + convert! (hasDerivAt_const (0:ℝ) x).add ((hasDerivAt_id (0:ℝ)).smul_const v) using 1 + simp + have hd' : HasFDerivAt (fderiv ℝ f) (fderiv ℝ (fderiv ℝ f) x) (x+(0:ℝ) • v) := by + simpa only [zero_smul,add_zero] using hdf.hasFDerivAt + have hd := (hd'.comp_hasDerivAt (f := fun t : ℝ => x+t • v) 0 hline).clm_apply (hasDerivAt_const 0 w) + convert! hd using 1 + simp + +lemma positive_schur_test {a b q A : ℝ} (hq : 0Ring.inverse (Aj i)) atTop (𝓝 (Ring.inverse (u:E →L[ℝ] E))) := + (NormedRing.inverse_continuousAt u).tendsto.comp hlim + have hbound:=hi.norm.eventually (gt_mem_nhds (lt_add_one ‖Ring.inverse (u:E →L[ℝ] E)‖)) + have hunit:=hlim.eventually (Units.isOpen.mem_nhds u.isUnit) + refine ⟨‖Ring.inverse (u:E →L[ℝ] E)‖+1,by positivity,?_⟩ + filter_upwards [hbound,hunit] with i hbi hui + refine ⟨Ring.inverse (Aj i),?_,hbi.le⟩ + intro w + exact congrArg (fun B:E →L[ℝ] E=>B w) (Ring.mul_inverse_cancel (Aj i) hui) + +end HessianUpperTransfer +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/InverseProfile.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/InverseProfile.lean new file mode 100644 index 0000000000000000000000000000000000000000..3248caeb21e67ef936a6ebc32f36e2da976f12d8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/InverseProfile.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FixedJoinSmooth +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder +import OAI.Analysis.BiholderTransport.Regularity.FixedJoinMiddle + +namespace OAI + +noncomputable section +open Set Filter Module +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] {n : ℕ} + +lemma symmetric_eigenvalue_pos {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + (hn : finrank ℝ E=n) (hpos : ∀ x:E, x≠0 → 0 < inner ℝ (A x) x) (i:Fin n) : + 0 < hA.eigenvalues hn i := by + have H := hpos (hA.eigenvectorBasis hn i) ((hA.eigenvectorBasis hn).toBasis.ne_zero i) + rw [hA.apply_eigenvectorBasis,real_inner_smul_left,real_inner_self_eq_norm_sq, + (hA.eigenvectorBasis hn).norm_eq_one] at H + simpa using H +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +local instance tangentFiniteJoin (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def fixedJoinOperator (x : M) (h T : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + exact bilinearOperator (fixedJoinMiddle x h T p) + +@[simp] lemma fixedJoinOperator_inner (x : M) (h T : ℝ) + (p d k : TangentSpace 𝓘(ℝ,Model n) x) : + inner ℝ (fixedJoinOperator x h T p d) k=fixedJoinMiddle x h T p d k := + bilinearOperator_inner _ d k + +lemma fixedJoinOperator_symmetric {x:M} {h T:ℝ} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hB : ContDiffAt ℝ 2 (fixedJoinAction x h T p) (0,p)) : + (fixedJoinOperator x h T p).toLinearMap.IsSymmetric := + bilinearOperator_symmetric (fixedJoinMiddle_symmetric hB) + +variable [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma fixedJoinAction_shortened_contDiffAt {x : M} {h T:ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hh1 : h < 1) (hT : h < T) (hT1 : T < 1) + (hleft : h • p∈injectivityDomain x) + (hright : (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (fixedJoinAction x h T p) (0,p) := by + have hden : 0 < 1-h := sub_pos.mpr hh1 + have ht0 : 0 < (T-h)/(1-h) := div_pos (sub_pos.mpr hT) hden + have ht1 : (T-h)/(1-h) < 1 := (div_lt_one hden).mpr (by linarith) + have H := contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors _ hright) ht0 ht1 + rw [smul_smul,div_mul_cancel₀ _ hden.ne'] at H + exact fixedJoinAction_contDiffAt hT.ne' hleft H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JensenHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JensenHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..1137a3a85a0f8e7465be1932387c5eb6a54720ee --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JensenHessian.lean @@ -0,0 +1,79 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [MetricSpace M] [ChartedSpace H M] + [RiemannianBundle (fun x : M => TangentSpace I x)] + [IsRiemannianManifold I M] +include I + +lemma riemannian_approximate_midpoint (x y : M) {eps : ℝ} (heps : 0 < eps) : + ∃ z : M, dist x z = dist x y/2 ∧ dist z y < dist x y/2+eps := by + have hdist : riemannianEDist I x y < ENNReal.ofReal (dist x y+eps) := by + rw [← IsRiemannianManifold.out,edist_dist] + exact ENNReal.ofReal_lt_ofReal_iff (by positivity) |>.mpr (by linarith) + obtain ⟨γ,hγ0,hγ1,hγ,hlen⟩ := exists_lt_of_riemannianEDist_lt hdist + have hc : ContinuousOn (fun t : ℝ => dist x (γ t)) (Icc 0 1) := + continuous_dist.comp_continuousOn (continuousOn_const.prodMk hγ.continuousOn) + have hhalf : dist x y/2 ∈ Icc (dist x (γ 0)) (dist x (γ 1)) := by + rw [hγ0,hγ1,dist_self] + constructor <;> linarith [dist_nonneg (x := x) (y := y)] + obtain ⟨t,ht,htt⟩ := intermediate_value_Icc (by norm_num : (0:ℝ) ≤ 1) hc hhalf + change dist x (γ t) = dist x y/2 at htt + refine ⟨γ t,htt,?_⟩ + have hpre := riemannianEDist_le_pathELength (I := I) + (hγ.mono (Icc_subset_Icc le_rfl ht.2)) hγ0 rfl ht.1 + have hpost := riemannianEDist_le_pathELength (I := I) + (hγ.mono (Icc_subset_Icc ht.1 le_rfl)) rfl hγ1 ht.2 + have hsum : ENNReal.ofReal (dist x (γ t)+dist (γ t) y) < + ENNReal.ofReal (dist x y+eps) := by + rw [ENNReal.ofReal_add dist_nonneg dist_nonneg] + rw [← IsRiemannianManifold.out,edist_dist] at hpre hpost + exact (add_le_add hpre hpost).trans_lt ((pathELength_add ht.1 ht.2).trans_lt hlen) + have hsumR : dist x (γ t)+dist (γ t) y < dist x y+eps := + (ENNReal.ofReal_lt_ofReal_iff (by positivity)).mp hsum + rw [htt] at hsumR + linarith + +lemma riemannian_exists_midpoint [CompactSpace M] (x y : M) : + ∃ z : M, dist x z = dist x y/2 ∧ dist z y = dist x y/2 := by + let F : M → ℝ := fun z => max (dist x z) (dist z y) + have hc : Continuous F := by fun_prop + obtain ⟨z,_,hz⟩ := isCompact_univ.exists_isMinOn ⟨x,mem_univ x⟩ hc.continuousOn + have hF : F z ≤ dist x y/2 := by + by_contra hn + have hp : 0 < F z-dist x y/2 := sub_pos.mpr (lt_of_not_ge hn) + obtain ⟨w,hwx,hwy⟩ := riemannian_approximate_midpoint (I := I) x y (half_pos hp) + have hw : F w < F z := by + dsimp [F] + apply max_lt + · rw [hwx]; linarith + · linarith + exact (not_lt_of_ge (hz (mem_univ w))) hw + have hx := (le_max_left (dist x z) (dist z y)).trans hF + have hy := (le_max_right (dist x z) (dist z y)).trans hF + have htri := dist_triangle x z y + exact ⟨z,by linarith,by linarith⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinCongruence.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinCongruence.lean new file mode 100644 index 0000000000000000000000000000000000000000..a405927e3c9736d4c742558a1680d2d2f755a383 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinCongruence.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeSlice +import OAI.Analysis.BiholderTransport.Regularity.CriticalChain +import OAI.Analysis.BiholderTransport.Coordinates.JoinCoordinates + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section JoinCongruence +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma split_join_hessian_congruence {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + {h : ℝ} (hh : 0 diagonalSplitAction x h (p,a)-cost x (riemannianExp x p))) p at heDD + have hsub : fderiv ℝ (fun a => diagonalSplitAction x h (p,a)-cost x (riemannianExp x p))= + fderiv ℝ (fun a => diagonalSplitAction x h (p,a)) := by + funext a; exact fderiv_sub_const _ + rw [hsub] at heDD + refine ⟨fderiv ℝ q p,hqinj,?_⟩ + intro a + have H := second_fderiv_comp_at_critical hf' (hq.of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) hz a a + rw [heDD,hqp,second_derivative_target_slice hF] at H + exact H.trans (middleCenteredAction_hessian (z := z) hp hh hh1 _) + +end JoinCongruence +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinOperator.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..2244f7255f0996298e7df6aaebe723655125a878 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/JoinOperator.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Diagonal +import OAI.Analysis.BiholderTransport.CostGeometry.SplitEndpoint +import OAI.Analysis.BiholderTransport.LinearAlgebra.JoinCongruence +import OAI.Analysis.BiholderTransport.Coordinates.UniformLog + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section JoinOperator +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def splitJoinHessianOperator (x : M) (t : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x := + (InnerProductSpace.toDual ℝ _).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp + ((fderiv ℝ (fderiv ℝ (diagonalSplitAction x t)) (p,p)).bilinearComp + (inr ℝ _ _) (inr ℝ _ _)) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma inner_splitJoinHessianOperator (x : M) (t : ℝ) + (p a k : TangentSpace 𝓘(ℝ,Model n) x) : + inner ℝ (splitJoinHessianOperator x t p a) k= + fderiv ℝ (fderiv ℝ (diagonalSplitAction x t)) (p,p) (0,a) (0,k) := + InnerProductSpace.toDual_symm_apply + +lemma splitJoinHessianOperator_positive {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def endpointExpDifferential (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p) := + mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p + +lemma uniform_join_exp_norm_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + p ∈ minimizingVectors x → ∀ t ∈ Icc (1/4:ℝ) (3/4), ∀ v, + ‖splitJoinHessianOperator x t p v‖ ≤ C * ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) + 𝓘(ℝ,Model n) (riemannianExp x) p v‖ ∧ + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p v‖ ≤ + c * ‖splitJoinHessianOperator x t p v‖ := by + obtain ⟨l,u,hl,hu,H⟩ := uniform_join_endpoint_factorization (n := n) (M := M) + refine ⟨1/l,4*u,div_pos (by norm_num) hl,mul_pos (by norm_num) hu,?_⟩ + intro x p hp t ht v + obtain ⟨L,hL,hLn,hfac⟩ := H x p hp t ht + have hs : 0 < 1-t := by linarith [ht.2] + have hn := dual_factor_norm_comparison (splitJoinHessianOperator x t p) L + (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p) + hs hl hu hL.2 hLn (fun a k => by rw [hfac]; field_simp [hs.ne']; rfl) v + change l * ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) p v‖ ≤ (1-t)*‖splitJoinHessianOperator x t p v‖ ∧ + (1-t)*‖splitJoinHessianOperator x t p v‖ ≤ u*‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) + 𝓘(ℝ,Model n) (riemannianExp x) p v‖ at hn + constructor + · have hm := mul_le_mul_of_nonneg_right (show (1/4:ℝ) ≤ 1-t by linarith [ht.2]) + (norm_nonneg (splitJoinHessianOperator x t p v)) + have hh := hm.trans hn.2 + linarith only [hh] + · rw [one_div,mul_comm,←div_eq_mul_inv,le_div_iff₀ hl] + have hm := mul_le_mul_of_nonneg_right (show 1-t ≤ 1 by linarith [ht.1]) + (norm_nonneg (splitJoinHessianOperator x t p v)) + have hh := hn.1.trans hm + nlinarith only [hh] + +lemma uniform_join_exp_ordered_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + ∀ hp : p ∈ minimizingVectors x, ∀ t : ℝ, ∀ ht : t ∈ Icc (1/4:ℝ) (3/4), + ∀ i : Fin (Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) x)), + (splitJoinHessianOperator_positive hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i ≤ C * + (endpointExpDifferential x p).toLinearMap.singularValues i ∧ + (endpointExpDifferential x p).toLinearMap.singularValues i ≤ c * + (splitJoinHessianOperator_positive hp (by linarith [ht.1]) + (by linarith [ht.2])).isSymmetric.eigenvalues rfl i := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_join_exp_norm_comparison (n := n) (M := M) + refine ⟨c,C,hc,hC,?_⟩ + intro x p hp t ht i + let Q := splitJoinHessianOperator x t p + let E := endpointExpDifferential x p + have hQ := splitJoinHessianOperator_positive hp + (show 0 < t by linarith [ht.1]) (show t < 1 by linarith [ht.2]) + have h1 := ordered_singularValues_pullback (A := Q.toLinearMap) (B := E.toLinearMap) + (LinearMap.id) hC.le (by norm_num : (0:ℝ) ≤ 1) + (fun v => by change ‖v‖ ≤ 1 * ‖v‖; simp) (fun v => (H x p hp t ht v).1) rfl rfl i + have h2 := ordered_singularValues_pullback (A := E.toLinearMap) (B := Q.toLinearMap) + (LinearMap.id) hc.le (by norm_num : (0:ℝ) ≤ 1) + (fun v => by change ‖v‖ ≤ 1 * ‖v‖; simp) (fun v => (H x p hp t ht v).2) rfl rfl i + rw [positive_singularValues_eq_eigenvalues hQ rfl i] at h1 h2 + simpa only [mul_one] using And.intro h1 h2 + +end JoinSpectrum +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformCongruence +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_split_join_hessian_congruence : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + p ∈ minimizingVectors x → ∀ h ∈ Icc (1/4:ℝ) (3/4), + ∃ P : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + Function.Bijective P ∧ (∀ v, c*‖v‖ ≤ ‖P v‖ ∧ ‖P v‖ ≤ C*‖v‖) ∧ ∀ a, + fderiv ℝ (fderiv ℝ (diagonalSplitAction x h)) (p,p) (0,a) (0,a)= + middleHessian (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M) h 1 (P a) (P a) := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_prefix_log_derivative_bounds (n := n) (M := M) + refine ⟨c,C,hc,hC,?_⟩ + intro x p hp h ht + have hh : 0 < h := by linarith [ht.1] + have hh1 : h < 1 := by linarith [ht.2] + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,p⟩ + have hleft := contracted_minimizer_mem_injectivityDomain hp hh hh1 + obtain ⟨q,hqp,hq,hqinj,hqr⟩ := exists_join_normal_coordinates hh.ne' hleft + have hf := middleCenteredAction_contDiffAt (z := z) hp hh hh1 + have hf' : ContDiffAt ℝ 2 (middleCenteredAction z h) (q p) := by rwa [hqp] + have hz : fderiv ℝ (middleCenteredAction z h) (q p)=0 := by + rw [hqp] + exact (middleCenteredAction_minimum (z := z) hp hh hh1).fderiv_eq_zero + have hF : ContDiffAt ℝ 2 (diagonalSplitAction x h) (p,p) := + (diagonalSplitAction_contDiffAt hleft (proper_suffix_in_injectivityDomain + (z := z) hp hh hh1 le_rfl)).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have he := middle_action_in_join_coordinates hp hh hh1 hqr + have heD := he.fderiv (𝕜 := ℝ) + have heDD := heD.fderiv_eq (𝕜 := ℝ) + change fderiv ℝ (fderiv ℝ (middleCenteredAction z h ∘ q)) p = + fderiv ℝ (fderiv ℝ (fun a => diagonalSplitAction x h (p,a)-cost x (riemannianExp x p))) p at heDD + have hsub : fderiv ℝ (fun a => diagonalSplitAction x h (p,a)-cost x (riemannianExp x p))= + fderiv ℝ (fun a => diagonalSplitAction x h (p,a)) := by + funext a; exact fderiv_sub_const _ + rw [hsub] at heDD + have hqs : Function.Surjective (fderiv ℝ q p) := + (LinearMap.injective_iff_surjective_of_finrank_eq_finrank + (f := (fderiv ℝ q p).toLinearMap) rfl).mp hqinj + refine ⟨fderiv ℝ q p,⟨hqinj,hqs⟩, + H x p hp h ht _ q (hq.differentiableAt (by simp)) hqp hqr,?_⟩ + intro a + have H := second_fderiv_comp_at_critical hf' (hq.of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) hz a a + rw [heDD,hqp,second_derivative_target_slice hF] at H + exact H.trans (middleCenteredAction_hessian (z := z) hp hh hh1 _) + +end UniformCongruence +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalMountains.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalMountains.lean new file mode 100644 index 0000000000000000000000000000000000000000..62e7d9447027be921c14ae8b71e7926239b9d79b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalMountains.lean @@ -0,0 +1,88 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E Y : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [TopologicalSpace Y] + +lemma lower_support_of_nonnegative_hessian {f : E → ℝ} {S : Set E} + (hS : Convex ℝ S) (hf : ∀ z∈S, ContDiffAt ℝ 2 f z) + (hH : ∀ z∈S, ∀ d : E, 0 ≤ fderiv ℝ (fderiv ℝ f) z d d) + {x y : E} (hx : x∈S) (hy : y∈S) : + f x+fderiv ℝ f x (y-x) ≤ f y := by + let d := y-x + let l : ℝ → E := fun t => x+t • d + let g : ℝ → ℝ := fun t => f (l t) + let g' : ℝ → ℝ := fun t => fderiv ℝ f (l t) d + let g'' : ℝ → ℝ := fun t => fderiv ℝ (fderiv ℝ f) (l t) d d + have hl : ∀ t∈Icc (0:ℝ) 1, l t∈S := by + intro t ht + have H := hS hx hy (sub_nonneg.mpr ht.2) ht.1 (by ring : (1-t)+t=1) + convert H using 1 + dsimp [l,d] + module + have hld (t : ℝ) : HasDerivAt l d t := by + simpa only [l,id_eq,one_smul] using (((hasDerivAt_id t).smul_const d).const_add x) + have hg (t : ℝ) (ht : t∈Icc (0:ℝ) 1) : HasDerivAt g (g' t) t := + ((hf (l t) (hl t ht)).differentiableAt (by norm_num)).hasFDerivAt.comp_hasDerivAt t (hld t) + have hg' (t : ℝ) (ht : t∈Icc (0:ℝ) 1) : HasDerivAt g' (g'' t) t := by + have H := (((hf (l t) (hl t ht)).fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp_hasDerivAt t (hld t) + simpa only [g',g'',Function.comp_apply,map_zero,add_zero] using H.clm_apply (hasDerivAt_const t d) + have hconv : ConvexOn ℝ (Icc (0:ℝ) 1) g := + convexOn_of_hasDerivWithinAt2_nonneg (convex_Icc _ _) + (fun t ht => (hg t ht).continuousAt.continuousWithinAt) + (fun t ht => (hg t (interior_subset ht)).hasDerivWithinAt) + (fun t ht => (hg' t (interior_subset ht)).hasDerivWithinAt) + (fun t ht => hH _ (hl t (interior_subset ht)) d) + have H := hconv.deriv_le_slope (left_mem_Icc.mpr zero_le_one) + (right_mem_Icc.mpr zero_le_one) zero_lt_one (hg 0 (by constructor <;> norm_num)).differentiableAt + rw [(hg 0 (by constructor <;> norm_num)).deriv] at H + simp only [g,g',l,d,zero_smul,add_zero,one_smul,add_sub_cancel,slope, + sub_zero,inv_one,one_smul,vsub_eq_sub] at H + linarith + +lemma bilinear_nonnegative_of_norm_sub_le {B H : E →L[ℝ] E →L[ℝ] ℝ} {m : ℝ} + (hB : ∀ d, m*‖d‖^2 ≤ B d d) (hH : ‖H-B‖≤ m) (d : E) : 0≤H d d := by + have hn := (H-B).le_opNorm₂ d d + have hmul := mul_le_mul_of_nonneg_right hH (sq_nonneg ‖d‖) + have hdiff : H d d-B d d ≤ ‖(H-B) d d‖ := le_abs_self _ + have hdiff' : -(H d d-B d d) ≤ ‖(H-B) d d‖ := neg_le_abs _ + have he : ‖H-B‖*‖d‖*‖d‖=‖H-B‖*‖d‖^2 := by ring + rw [he] at hn + have H' := hB d + nlinarith + +lemma exists_local_mountains {F : Y → E → ℝ} {x : E} {y : Y} {m : ℝ} + (hm : 0< m) + (hC : ContinuousAt (fun q : E×Y => fderiv ℝ (fderiv ℝ (F q.2)) q.1) (x,y)) + (hD : ∀ᶠ q : E×Y in 𝓝 (x,y), ContDiffAt ℝ 2 (F q.2) q.1) + (hpos : ∀ d:E, m*‖d‖^2 ≤ fderiv ℝ (fderiv ℝ (F y)) x d d) : + ∃ r>0, ∃ V∈𝓝 y, ∀ y'∈V, ∀ z∈Metric.closedBall x r, + fderiv ℝ (F y') z=0 → ∀ w∈Metric.closedBall x r, F y' z≤F y' w := by + have H := @ContinuousAt.norm (E×Y) (E →L[ℝ] E →L[ℝ] ℝ) _ _ _ _ + (hC.sub (continuousAt_const (y := fderiv ℝ (fderiv ℝ (F y)) x))) + have Hn : ∀ᶠ q : E×Y in 𝓝 (x,y), + ‖fderiv ℝ (fderiv ℝ (F q.2)) q.1-fderiv ℝ (fderiv ℝ (F y)) x‖< m := by + apply H.eventually_lt continuousAt_const + simpa only [Pi.sub_apply,Prod.fst,Prod.snd,sub_self,ContinuousLinearMap.opNorm_zero] using hm + obtain ⟨U,hU,V,hV,hUV⟩ := mem_nhds_prod_iff.mp (Hn.and hD) + obtain ⟨r,hr,hrU⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hU + refine ⟨r,hr,V,hV,?_⟩ + intro y' hy' z hz hs w hw + have Hlow := lower_support_of_nonnegative_hessian (f := F y') (convex_closedBall x r) + (fun u hu => (hUV (a := (u,y')) ⟨hrU hu,hy'⟩).2) + (fun u hu d => bilinear_nonnegative_of_norm_sub_le hpos + (hUV (a := (u,y')) ⟨hrU hu,hy'⟩).1.le d) hz hw + simpa only [hs,zero_apply,add_zero] using Hlow + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalNormalChart.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalNormalChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..3c8f68051d4013d744000bc8395486b1988dd228 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LocalNormalChart.lean @@ -0,0 +1,86 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma positive_bilinear_nonneg (g : E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ v : E, v ≠ 0 → 0 < g v v) (v : E) : 0 ≤ g v v := by + by_cases hv : v = 0 + · simp only [hv,map_zero,le_refl] + · exact (hg v hv).le + +lemma positive_bilinear_cauchy_schwarz (g : E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ v : E, v ≠ 0 → 0 < g v v) + (hsym : ∀ u v, g u v = g v u) (u v : E) : + (g u v)^2 ≤ g u u * g v v := by + by_cases hv : v = 0 + · simp only [hv,map_zero,mul_zero,zero_pow,le_refl,ne_eq,OfNat.ofNat_ne_zero,not_false_eq_true] + have hgv : 0 < g v v := hg v hv + have h := positive_bilinear_nonneg g hg ((g v v) • u - (g u v) • v) + simp only [map_sub,map_smul,sub_apply,smul_apply,smul_eq_mul] at h + rw [hsym v u] at h + have hmul : 0 ≤ g v v * (g u u * g v v - (g u v)^2) := by nlinarith [h] + have hsub : 0 ≤ g u u * g v v - (g u v)^2 := (mul_nonneg_iff_of_pos_left hgv).mp hmul + linarith + +lemma positive_bilinear_abs_le (g : E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ v : E, v ≠ 0 → 0 < g v v) + (hsym : ∀ u v, g u v = g v u) (u v : E) : + |g u v| ≤ Real.sqrt (g u u) * Real.sqrt (g v v) := by + have hu := positive_bilinear_nonneg g hg u + have hv := positive_bilinear_nonneg g hg v + have h := positive_bilinear_cauchy_schwarz g hg hsym u v + have hsq : (Real.sqrt (g u u) * Real.sqrt (g v v))^2 = g u u * g v v := by + rw [mul_pow,Real.sq_sqrt hu,Real.sq_sqrt hv] + have hn : 0 ≤ Real.sqrt (g u u) * Real.sqrt (g v v) := mul_nonneg (Real.sqrt_nonneg _) (Real.sqrt_nonneg _) + nlinarith [sq_abs (g u v)] + +end WeakMTWTransport + +open MeasureTheory +open scoped ContDiff ENNReal + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LowerTaylor.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LowerTaylor.lean new file mode 100644 index 0000000000000000000000000000000000000000..d1ff200dc256f6f25c0f23eb51218ece3596d0e9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/LowerTaylor.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.FullSet + +namespace OAI + +noncomputable section +open Set Filter Asymptotics +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +def pullBilinear (B : F →L[ℝ] F →L[ℝ] ℝ) (A : E →L[ℝ] F) : + E →L[ℝ] E →L[ℝ] ℝ := + ((ContinuousLinearMap.compL ℝ E F ℝ).flip A).comp (B.comp A) + +@[simp] lemma pullBilinear_apply (B : F →L[ℝ] F →L[ℝ] ℝ) (A : E →L[ℝ] F) + (u v : E) : pullBilinear B A u v=B (A u) (A v) := rfl + +lemma HasSecondTaylor.comp_linear {f : F → ℝ} {l : F →L[ℝ] ℝ} + {B : F →L[ℝ] F →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) (A : E →L[ℝ] F) : + HasSecondTaylor (fun h => f (A h)) (l.comp A) (pullBilinear B A) := by + have H := (hf.comp_tendsto (show Tendsto A (𝓝 0) (𝓝 0) by + simpa only [ContinuousAt,map_zero] using (A.continuous.continuousAt (x := (0:E))))).trans_isBigO + ((A.isBigO_id (𝓝 0)).norm_left.norm_right.pow 2) + simpa only [HasSecondTaylor,map_zero,Function.comp_def,ContinuousLinearMap.comp_apply, + pullBilinear_apply] using H + +lemma HasSecondTaylor.sub_linear {f : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasSecondTaylor f l B) : + HasSecondTaylor (fun h => f h-l h) 0 B := by + unfold HasSecondTaylor at * + have heq : (fun h => f h-l h-(f 0-l 0)-(0 : E →L[ℝ] ℝ) h-B h h/2) = + (fun h => f h-f 0-l h-B h h/2) := by + funext h; simp only [map_zero,sub_zero,zero_apply]; ring + rw [heq]; exact hf + +def HasLowerSecondTaylor (f : E → ℝ) (l : E →L[ℝ] ℝ) + (B : E →L[ℝ] E →L[ℝ] ℝ) : Prop := + ∀ ε : ℝ, 0 < ε → ∀ᶠ h in 𝓝 (0:E), f 0+l h+B h h/2-ε*‖h‖^2≤f h + +lemma HasLowerSecondTaylor.mono {f g : E → ℝ} {l : E →L[ℝ] ℝ} + {B : E →L[ℝ] E →L[ℝ] ℝ} (hf : HasLowerSecondTaylor f l B) + (he : f 0=g 0) (hle : f≤ᶠ[𝓝 0] g) : HasLowerSecondTaylor g l B := by + intro ε hε + filter_upwards [hf ε hε,hle] with h hh hfg + rw [←he] + exact hh.trans hfg + +lemma HasLowerSecondTaylor.of_positive_mul {f : E → ℝ} {m : ℝ} (hm : 0 < m) + {l : E →L[ℝ] ℝ} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasLowerSecondTaylor (fun h => m * f h) l B) : + HasLowerSecondTaylor f (m⁻¹ • l) (m⁻¹ • B) := by + intro ε hε + filter_upwards [hf (m*ε) (mul_pos hm hε)] with h hh + apply (mul_le_mul_iff_right₀ hm).mp + simpa only [smul_apply,smul_eq_mul,mul_sub,mul_add, + mul_div_assoc,←mul_assoc,mul_inv_cancel₀ hm.ne',one_mul] using hh + +lemma lowerTaylor_of_stationary_transfer {S : F → ℝ} + {B : F →L[ℝ] F →L[ℝ] ℝ} (hS : HasSecondTaylor S 0 B) + {a : E → F} {A : E →L[ℝ] F} (ha : HasFDerivAt a A 0) (ha0 : a 0=0) + {f : E → ℝ} {l : E →L[ℝ] ℝ} {C : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasSecondTaylor f l C) + {ψ : E → ℝ} {m : ℝ} (hm : 0 < m) + (hle : ∀ᶠ h in 𝓝 (0:E), + S (a h)-S 0-(f h-f 0-l h)≤ m * (ψ h-ψ 0)) : + HasLowerSecondTaylor ψ 0 (m⁻¹ • (pullBilinear B A-C)) := by + have hcomp := (hS.comp_stationary ha ha0).sub hf.sub_linear + have hE : ∀ h:E, (S (a h)-(f h-l h))-(S (a 0)-(f 0-l 0)) = + S (a h)-S 0-(f h-f 0-l h) := by + intro h; rw [ha0,map_zero]; ring + have hlow : HasLowerSecondTaylor (fun h => m * ψ h) 0 (pullBilinear B A-C) := by + intro ε hε + filter_upwards [hcomp.eventually hε,hle] with h hh hbound + have hh' : |(S (a h)-(f h-l h))-(S (a 0)-(f 0-l 0))- + (pullBilinear B A-C) h h/2|≤ε*‖h‖^2 := by + simpa only [zero_sub,sub_zero,zero_apply,pullBilinear] using hh + rw [hE] at hh' + simp only [zero_apply,add_zero] + have H := (abs_le.mp hh').1 + nlinarith + simpa only [smul_zero] using hlow.of_positive_mul hm + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MatrixNormDetFactorial.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MatrixNormDetFactorial.lean new file mode 100644 index 0000000000000000000000000000000000000000..af59c67f5e75e14b9952ff72687948206c44239e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MatrixNormDetFactorial.lean @@ -0,0 +1,73 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Module Set +open scoped BigOperators + +namespace WeakMTWTransport + +lemma matrix_norm_det_le_factorial {ι : Type*} [Fintype ι] [DecidableEq ι] + (A : Matrix ι ι ℝ) {R : ℝ} (hR : 0≤R) (hA : ∀ i j, ‖A i j‖≤R) : + ‖A.det‖≤(Fintype.card ι).factorial*R^(Fintype.card ι) := by + rw [Matrix.det_apply] + calc + _ ≤ ∑ σ : Equiv.Perm ι, ‖Equiv.Perm.sign σ • ∏ i, A (σ i) i‖ := norm_sum_le _ _ + _ ≤ ∑ _σ : Equiv.Perm ι, R^(Fintype.card ι) := by + apply Finset.sum_le_sum + intro σ hσ + rw [norm_units_zsmul,norm_prod] + calc + _ ≤ ∏ _i : ι, |R| := Finset.prod_le_prod₀ (fun _ _ => norm_nonneg _) + (fun index _ => (hA (σ index) index).trans (le_abs_self R)) + _ = _ := by simp [abs_of_nonneg hR] + _ = _ := by simp [Fintype.card_perm] + +lemma normDet_le_factorial_opNorm {U V : Type*} + [NormedAddCommGroup U] [InnerProductSpace ℝ U] [FiniteDimensional ℝ U] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [FiniteDimensional ℝ V] + (F : U →L[ℝ] V) (hd : Module.finrank ℝ U=Module.finrank ℝ V) : + F.toLinearMap.normDet≤(Module.finrank ℝ U).factorial*‖F‖^(Module.finrank ℝ U) := by + classical + let b := stdOrthonormalBasis ℝ U + let d : OrthonormalBasis (Fin (finrank ℝ U)) ℝ V := + (stdOrthonormalBasis ℝ V).reindex (finCongr hd).symm + rw [LinearMap.normDet_eq_norm_det_toMatrix F.toLinearMap b d] + have hA : ∀ i j, ‖(F.toLinearMap.toMatrix b.toBasis d.toBasis) i j‖≤‖F‖ := by + intro i j + rw [LinearMap.toMatrix_apply,d.coe_toBasis_repr_apply] + change ‖d.repr (F (b j)) i‖≤‖F‖ + rw [d.repr_apply_apply] + calc + _ ≤ ‖d i‖*‖F (b j)‖ := norm_inner_le_norm _ _ + _ = ‖F (b j)‖ := by rw [d.orthonormal.norm_eq_one i,one_mul] + _ ≤ ‖F‖*‖b j‖ := F.le_opNorm _ + _ = ‖F‖ := by rw [b.orthonormal.norm_eq_one,mul_one] + simpa only [Fintype.card_fin] using matrix_norm_det_le_factorial + (F.toLinearMap.toMatrix b.toBasis d.toBasis) (norm_nonneg F) hA + +lemma normDet_comp_three {U V W Z : Type*} + [NormedAddCommGroup U] [InnerProductSpace ℝ U] [FiniteDimensional ℝ U] + [NormedAddCommGroup V] [InnerProductSpace ℝ V] [FiniteDimensional ℝ V] + [NormedAddCommGroup W] [InnerProductSpace ℝ W] [FiniteDimensional ℝ W] + [NormedAddCommGroup Z] [InnerProductSpace ℝ Z] [FiniteDimensional ℝ Z] + (R : U →L[ℝ] V) (A : V →L[ℝ] W) (S : W →L[ℝ] Z) + (hUV : finrank ℝ U=finrank ℝ V) (hVW : finrank ℝ V=finrank ℝ W) : + (S.comp (A.comp R)).toLinearMap.normDet= + S.toLinearMap.normDet*A.toLinearMap.normDet*R.toLinearMap.normDet := by + change (S.toLinearMap ∘ₗ (A.toLinearMap ∘ₗ R.toLinearMap)).normDet=_ + rw [LinearMap.normDet_comp_of_finrank_eq _ _ (hUV.trans hVW), + LinearMap.normDet_comp_of_finrank_eq _ _ hUV,mul_assoc] + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumPolePositive.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumPolePositive.lean new file mode 100644 index 0000000000000000000000000000000000000000..c96716a6e45aa3d4ab0ae63cc5ab26e40b46ad5f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumPolePositive.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily +import OAI.Analysis.BiholderTransport.Regularity.MaximumReindex +import OAI.Analysis.BiholderTransport.Regularity.MaximumSample + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumPolePositive +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumJensenFamily.sample_pole_positive (J:MaximumJensenFamily hmtw hv ho F a c N) + (k:ℕ) : ∀ᶠ j in atTop,∀d:Model n,0 ≤ J.sampleL k j d d := by + let χ:=extChartAt 𝓘(ℝ,Model n) c + let v0:=modifiedDatum v α D (F.b k) Bo + have hv0:=continuous_modifiedDatum hv α D (F.b k) ho + have ht:=(F.prefixTime k).1 + have ht1:=(F.prefixTime k).2 + have hσ:=(J.first k).strictMono.tendsto_atTop + obtain ⟨hQ,hb,hp⟩:=(F.row k).jensen_graph_limit hmtw hv ho ht ht1 + (J.sample k) (J.endpointSource k) (J.poleSource k) + have hbase: Tendsto (fun j=>(J.samplePoint k j).1.1) atTop (𝓝 (F.row k).q.1.1) := + (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto (F.row k).q.1 + |>.comp (hQ.comp hσ) + have ha:=hbase.eventually ((isOpen_extChartAt_source _).mem_nhds (J.poleSource k)) + have hd:=hbase.eventually ((isOpen_extChartAt_source (F.row k).q.1.1).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) (F.row k).q.1.1)) + have hz:=((J.sample k).points.comp hσ).eventually ((isOpen_extChartAt_target c).mem_nhds + (χ.map_source (J.endpointSource k))) + have hpole:chartActualPole v0 (F.t k) c (χ (F.z k))=(F.row k).q.1.1 := by + dsimp only [chartActualPole] + rw [χ.left_inv (J.endpointSource k)] + rw [←hmtw.graphHomeomorph_inverse_pole hv0 ht ht1 (F.z k)] + exact congrArg (fun q=>q.1.1) ((F.row k).graph_inverse hmtw hv ho ht ht1) + filter_upwards [ha,hd,hz] with j haj hdj hzj + let q:=J.samplePoint k j + let b:=graphBaseCoordinate a q.1 + let p:=graphVelocityCoordinate a q.1 + have hbt:b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source haj + have he:movingPrefix a (F.t k) b p=graphProjection (cTransform v0) (F.t k) q := + movingPrefix_graph_coordinates haj (F.t k) + have hec:χ (movingPrefix a (F.t k) b p)=(J.sample k).z (J.sampleIndex k j) := by + rw [he,J.sampleProjection] + exact χ.right_inv hzj + have hs:movingPrefix a (F.t k) b p∈χ.source := by + rw [he,J.sampleProjection] + exact χ.map_target hzj + have hbd:(extChartAt 𝓘(ℝ,Model n) a).symm b∈ + (extChartAt 𝓘(ℝ,Model n) (F.row k).q.1.1).source := by + change (extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a q.1.1)∈_ + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv haj] + exact hdj + have hD: DifferentiableAt ℝ (fun w:Model n=>extChartAt 𝓘(ℝ,Model n) (F.row k).q.1.1 + (hopfPole (n := n) (F.t k) (cTransform v0) (χ.symm w))) + (χ (movingPrefix a (F.t k) b p)) := by + rw [hec,←hpole] + exact ((J.sample k).samples (J.sampleIndex k j)).2.2.2.2.2.1.differentiableAt + exact (hmtw.coordinate_sample_pole_matrix hv0 ht ht1 hbt + (graphCoordinate_normalSubdifferential q haj) hs hbd hD).1 + +end MaximumPolePositive +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumRank.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumRank.lean new file mode 100644 index 0000000000000000000000000000000000000000..99d5d6c5bbfb29d25799d51b45a4eb246f75c1ec --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MaximumRank.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily +import OAI.Analysis.BiholderTransport.Regularity.FrameAbsorption +import OAI.Analysis.BiholderTransport.LinearAlgebra.FirstRank +import OAI.Analysis.BiholderTransport.Coordinates.ChartParameter + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumRank +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumJensenFamily.eventual_rank_of_center_lower + {hmtw:WeakMTW (n := n) (M := M)} {v:M → ℝ} {hv:Continuous v} + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n := n) v α D bminus bplus Bc Bo} + (hm:0 ≤ bminus) (hp:0 < bplus) (hprofiles:∀s,Bc s ≤ Bo s) + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + {q:Model n} (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {A C:ℝ} (hA:0 < A) + (hH:∀ ε:ℝ,0 < ε → ∀ᶠ k in atTop,∀d:Model n, + A*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + C*(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2-ε*‖d‖^2 ≤ + (J.first k).H d d) : + ∀ᶠ k in atTop, + let b:=graphBaseCoordinate a (F.row k).q.1 + let p:=graphVelocityCoordinate a (F.row k).q.1 + let E:=TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) + let κ:Type:={i:Fin (Module.finrank ℝ (Model n)+1) // 0 < (J.first k).w₀ i} + let pj:κ → E:=fun i=>chartFiberInverse a b ((J.first k).pj₀ i) + let P:E:=chartFiberInverse a b p + let S:=Submodule.span ℝ (range (fun i=>pj i-P)) + ∃ e∈S,‖e‖=1 ∧ 0 < inner ℝ P e ∧ S=Submodule.span ℝ {e} ∧ + A/2 ≤ (-C)*(inner ℝ P e)^2 := by + obtain ⟨hb,hpcoord,_,_⟩:=F.limit_coordinates hQ + have H:=eventual_frame_rank_lower hA hb hpcoord hH + filter_upwards [H] with k hk + let b:=graphBaseCoordinate a (F.row k).q.1 + let E:=TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) + let level:E → ℝ:=fun r=>(v (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) r)-α)/D + have hbt:b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (J.poleSource k) + have Hb:0 ≤ F.b k:=hm.trans (F.parameter k).1.le + have Hpos:0 < (1:ℝ)/4096+4*F.b k/bplus := by positivity + have HP:0 < Bc (level (chartFiberInverse a b (graphVelocityCoordinate a (F.row k).q.1)))- + ∑ i,(J.first k).w₀ i*Bo (level (chartFiberInverse a b ((J.first k).pj₀ i))) := by + have HP:=(F.row k).chart_first_limit_parameter (J.poleSource k) (J.first k) + change 1/4096+4*F.b k/bplus ≤ + Bc ((v (movingNormal a (b,graphVelocityCoordinate a (F.row k).q.1))-α)/D)- + ∑ i,(J.first k).w₀ i*Bo ((v (movingNormal a (b,(J.first k).pj₀ i))-α)/D) at HP + simp only [movingNormal_eq hbt] at HP + exact Hpos.trans_le HP + exact (J.first k).positive_rank_direction (J.poleSource k) (A/2) C (half_pos hA) hk + level Bc Bo (hprofiles _) HP + +end MaximumRank +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MiddleScaling.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MiddleScaling.lean new file mode 100644 index 0000000000000000000000000000000000000000..40dba9dbc379a7194a388c5183fe794ca85fff79 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MiddleScaling.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactQuadratic +import OAI.Analysis.BiholderTransport.Regularity.NormMinMax + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MiddleScaling +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma middleHessian_scaled_ray (z : TangentBundle 𝓘(ℝ,Model n) M) + (h T : ℝ) (hT : T ≠ 0) : + HEq (middleHessian (tangentScale T z) (h/T) 1) (T • middleHessian z h T) := by + unfold middleHessian + rw [sprayFlow_scale,mul_div_cancel₀ _ hT] + change HEq + ((h/T)⁻¹ • normalHessian (sprayFlow h z).1 (-(h/T) • (T • (sprayFlow h z).2)) + + (1-h/T)⁻¹ • normalHessian (sprayFlow h z).1 ((1-h/T) • (T • (sprayFlow h z).2))) + (T • (h⁻¹ • normalHessian (sprayFlow h z).1 ((-h) • (sprayFlow h z).2) + + (T-h)⁻¹ • normalHessian (sprayFlow h z).1 ((T-h) • (sprayFlow h z).2))) + simp only [smul_smul] + have h1 : -(h/T)*T = -h := by field_simp + have h2 : (1-h/T)*T = T-h := by field_simp + rw [h1,h2] + apply heq_of_eq + ext v w + simp only [add_apply,smul_apply,smul_eq_mul] + have h3 : (h/T)⁻¹ = T*h⁻¹ := by simp [div_eq_mul_inv] + have h4 : (1-h/T)⁻¹ = T*(T-h)⁻¹ := by + rw [show 1-h/T=(T-h)/T by field_simp] + simp [div_eq_mul_inv] + rw [h3,h4] + ring + +end MiddleScaling +end WeakMTWTransport + +end + +end + +section + +noncomputable section +namespace WeakMTWTransport +section SpectralScaling +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] + +lemma ordered_singularValues_positive_smul (A : E →ₗ[ℝ] F) {t : ℝ} (ht : 0 < t) + {n : ℕ} (hn : Module.finrank ℝ E = n) (i : Fin n) : + (t • A).singularValues i = t * A.singularValues i := by + have h1 := ordered_singularValues_pullback (A := t • A) (B := A) + (LinearMap.id) ht.le (by norm_num : (0:ℝ) ≤ 1) + (fun v => by change ‖v‖ ≤ 1*‖v‖; simp) + (fun v => by simp only [LinearMap.smul_apply,norm_smul,Real.norm_eq_abs, + abs_of_pos ht,LinearMap.id_apply]; exact le_rfl) hn hn i + have h2 := ordered_singularValues_pullback (A := A) (B := t • A) + (LinearMap.id) (inv_nonneg.mpr ht.le) (by norm_num : (0:ℝ) ≤ 1) + (fun v => by change ‖v‖ ≤ 1*‖v‖; simp) + (fun v => by simp only [LinearMap.smul_apply,norm_smul,Real.norm_eq_abs, + abs_of_pos ht,LinearMap.id_apply]; rw [←mul_assoc,inv_mul_cancel₀ ht.ne',one_mul]) hn hn i + simp only [mul_one] at h1 h2 + apply le_antisymm h1 + have H := mul_le_mul_of_nonneg_left h2 ht.le + simpa only [←mul_assoc,mul_inv_cancel₀ ht.ne',one_mul] using H +end SpectralScaling +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MiddleSingular +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def intrinsicBilinearOperator (y : M) + (B : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ) : + TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y := + (InnerProductSpace.toDual ℝ _).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp B + +def intrinsicBilinearSingular (y : M) + (B : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ) + (i : ℕ) : ℝ := (intrinsicBilinearOperator y B).toLinearMap.singularValues i + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma intrinsicBilinearSingular_heq {x y : M} (hxy : x=y) + {B : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ} + {C : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ} + (hBC : HEq B C) (i : ℕ) : + intrinsicBilinearSingular x B i=intrinsicBilinearSingular y C i := by + subst y + cases hBC + rfl + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma intrinsicBilinearOperator_smul (y : M) + (B : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ) + (t : ℝ) : intrinsicBilinearOperator y (t • B)=t • intrinsicBilinearOperator y B := by + ext v + simp only [intrinsicBilinearOperator,comp_apply,smul_apply,map_smul] + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma intrinsicBilinearSingular_pos_smul (y : M) + (B : TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] ℝ) + {t : ℝ} (ht : 0 < t) (i : Fin (Module.finrank ℝ (Model n))) : + intrinsicBilinearSingular y (t • B) i=t*intrinsicBilinearSingular y B i := by + unfold intrinsicBilinearSingular + rw [intrinsicBilinearOperator_smul] + exact ordered_singularValues_positive_smul (intrinsicBilinearOperator y B).toLinearMap ht rfl i + +def middleSingularValue (z : TangentBundle 𝓘(ℝ,Model n) M) (h T : ℝ) (i : ℕ) : ℝ := + intrinsicBilinearSingular (sprayFlow h z).1 (middleHessian z h T) i + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma middleSingularValue_scaled_ray (z : TangentBundle 𝓘(ℝ,Model n) M) + (h T : ℝ) (hT : 0 < T) (i : Fin (Module.finrank ℝ (Model n))) : + middleSingularValue (tangentScale T z) (h/T) 1 i = T*middleSingularValue z h T i := by + have hbase : (sprayFlow (h/T) (tangentScale T z)).1=(sprayFlow h z).1 := by + rw [sprayFlow_scale,mul_div_cancel₀ _ hT.ne'] + rfl + have H := intrinsicBilinearSingular_heq hbase (middleHessian_scaled_ray z h T hT.ne') i + change middleSingularValue (tangentScale T z) (h/T) 1 i = _ at H + rw [H,intrinsicBilinearSingular_pos_smul _ _ hT] + rfl + +end MiddleSingular +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedOperator.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..94041a96e6b19479736622b3db4596f9794eb83e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedOperator.lean @@ -0,0 +1,70 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Module + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [CompleteSpace E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [CompleteSpace F] + +def mixedOperator (B : F →L[ℝ] E →L[ℝ] ℝ) : F →L[ℝ] E := + (InnerProductSpace.toDual ℝ E).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp B + +omit [CompleteSpace F] in +@[simp] lemma mixedOperator_inner (B : F →L[ℝ] E →L[ℝ] ℝ) (v : F) (w : E) : + inner ℝ (mixedOperator B v) w=B v w := + InnerProductSpace.toDual_symm_apply + +omit [CompleteSpace F] in +lemma mixedOperator_norm_le (B : F →L[ℝ] E →L[ℝ] ℝ) {a : ℝ} + (ha : 0≤a) (hB : ∀ v w, |B v w|≤a*‖v‖*‖w‖) : + ‖mixedOperator B‖≤a := by + apply ContinuousLinearMap.opNorm_le_bound _ ha + intro v + have he : ‖mixedOperator B v‖=‖B v‖ := + (InnerProductSpace.toDual ℝ E).symm.norm_map (B v) + rw [he] + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg ha (norm_nonneg v)) + intro w + simpa only [Real.norm_eq_abs] using hB v w + +lemma mixed_factor_adjoint {D : E →L[ℝ] E} {J : E →L[ℝ] F} + {P : F →L[ℝ] E} (hD : D.toLinearMap.IsSymmetric) + (hfactor : ∀ v w, inner ℝ (D v) w=inner ℝ (P (J v)) w) : + D=J.adjoint.comp P.adjoint := by + ext v + apply ext_inner_right ℝ + intro w + calc + inner ℝ (D v) w=inner ℝ v (D w) := hD _ _ + _=inner ℝ (D w) v := real_inner_comm _ _ + _=inner ℝ (P (J w)) v := hfactor _ _ + _=inner ℝ (J w) (P.adjoint v) := by + rw [P.adjoint_inner_right] + _=inner ℝ (J.adjoint (P.adjoint v)) w := by + rw [J.adjoint_inner_left,real_inner_comm] + _=inner ℝ ((J.adjoint.comp P.adjoint) v) w := rfl + +omit [CompleteSpace E] [CompleteSpace F] in +lemma factor_surjective_of_right_inverse [FiniteDimensional ℝ E] [FiniteDimensional ℝ F] + {D S : E →L[ℝ] E} {J : F →L[ℝ] E} {C : E →L[ℝ] F} + (hdim : finrank ℝ E=finrank ℝ F) + (hDS : ∀ v, D (S v)=v) (hD : ∀ v, D v=J (C v)) : + Function.Surjective C := by + have hDin : Function.Injective D := D.toLinearMap.injective_iff_surjective.mpr + (fun v => ⟨S v,hDS v⟩) + have hCin : Function.Injective C := by + intro v w hvw + apply hDin + rw [hD,hD,hvw] + exact (LinearMap.injective_iff_surjective_of_finrank_eq_finrank hdim + (f := C.toLinearMap)).mp hCin + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedTrivializationBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedTrivializationBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..1248f9167fe3458baf17baffcfa9d68a38226841 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MixedTrivializationBound.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianMixedOperator +import OAI.Analysis.BiholderTransport.Coordinates.MovingNormalEndpointJoin + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] +local instance tangentFiniteTrivBound (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance endpointProductNormedGroupTriv (x y : M) : + NormedAddCommGroup (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := + Prod.normedAddCommGroup +local instance endpointProductNormedSpaceTriv (x y : M) : + NormedSpace ℝ (TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) := + Prod.normedSpace +local instance endpointDualNormedGroupTriv (x y : M) : + NormedAddCommGroup ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := + inferInstance +local instance endpointDualNormedSpaceTriv (x y : M) : + NormedSpace ℝ ((TangentSpace 𝓘(ℝ,Model n) y × TangentSpace 𝓘(ℝ,Model n) x) →L[ℝ] ℝ) := + inferInstance + +lemma normalEndpointMixedOperator_norm_trivialization_le {a c x y : M} {h B D : ℝ} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hy : y∈(extChartAt 𝓘(ℝ,Model n) c).source) + (hB : 0≤B) (hD : 0≤D) + (hAx : ‖(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x‖≤B) + (hAy : ‖(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) c).continuousLinearMapAt ℝ y‖≤D) + (p : TangentSpace 𝓘(ℝ,Model n) x) + (hF : ContDiffAt ℝ 2 + (movingNormalEndpointJoinAction a c + (h,((extChartAt 𝓘(ℝ,Model n) a) x,(extChartAt 𝓘(ℝ,Model n) c) y))) + (0,(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p)) : + ‖normalEndpointMixedOperator x y h p‖≤ + ‖fderiv ℝ (fderiv ℝ (movingNormalEndpointJoinAction a c + (h,((extChartAt 𝓘(ℝ,Model n) a) x,(extChartAt 𝓘(ℝ,Model n) c) y)))) + (0,(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p)‖*D*B := by + let Ax := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x + let Ay := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) c).continuousLinearMapAt ℝ y + let L := Ay.prodMap Ax + let F := movingNormalEndpointJoinAction a c + (h,((extChartAt 𝓘(ℝ,Model n) a) x,(extChartAt 𝓘(ℝ,Model n) c) y)) + let J := fderiv ℝ (fderiv ℝ F) (0,Ax p) + have he : normalEndpointJoinAction x y h=fun z => F (L z) := by + funext z + exact (movingNormalEndpointJoinAction_trivialization hx hy h z.1 z.2).symm + change ‖mixedOperator _‖≤‖J‖*D*B + apply mixedOperator_norm_le _ (by positivity) + intro v w + rw [negativeMixedForm_apply,abs_neg,he] + have H := second_fderiv_comp_affine (f := F) L 0 (0,p) + (by simpa only [zero_add,L,ContinuousLinearMap.coe_prodMap',Prod.map_apply,map_zero] using hF) (v,0) (0,w) + have H' : fderiv ℝ (fderiv ℝ (fun z => F (L z))) (0,p) (v,0) (0,w)= + J (Ay v,0) (0,Ax w) := by + simpa only [zero_add,L,ContinuousLinearMap.coe_prodMap',Prod.map_apply,map_zero,J] using H + rw [H',←Real.norm_eq_abs] + have hv : ‖Ay v‖≤D*‖v‖ := (Ay.le_opNorm v).trans (mul_le_mul_of_nonneg_right hAy (norm_nonneg _)) + have hw : ‖Ax w‖≤B*‖w‖ := (Ax.le_opNorm w).trans (mul_le_mul_of_nonneg_right hAx (norm_nonneg _)) + calc + ‖J (Ay v,0) (0,Ax w)‖≤‖J (Ay v,0)‖*‖((0:Model n),Ax w)‖ := (J _).le_opNorm _ + _≤(‖J‖*‖(Ay v,(0:Model n))‖)*‖((0:Model n),Ax w)‖ := by gcongr; exact J.le_opNorm _ + _=(‖J‖*‖Ay v‖)*‖Ax w‖ := by simp + _≤(‖J‖*(D*‖v‖))*(B*‖w‖) := by gcongr + _=(‖J‖*D*B)*‖v‖*‖w‖ := by ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingFamilyHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingFamilyHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..b28ad9dcc04ce0e88dac31bbd631483e9db8bc7f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingFamilyHessian.lean @@ -0,0 +1,49 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeJetTest + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MovingFamilyHessian +variable {Q E F : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma moving_family_rough_hessian_limit {ι : Type*} {l : Filter ι} + {f : ι → F → ℝ} {g : Q → E → F} {b : ι → Q} {x : ι → E} + {b₀ : Q} {x₀ : E} {j : F →L[ℝ] ℝ} {H : F →L[ℝ] F →L[ℝ] ℝ} + (hg : ContDiffAt ℝ ∞ (Function.uncurry g) (b₀,x₀)) + (hb : Tendsto b l (𝓝 b₀)) (hx : Tendsto x l (𝓝 x₀)) + (hj : Tendsto (fun i=>fderiv ℝ (f i) (g (b i) (x i))) l (𝓝 j)) + (hH : Tendsto (fun i=>fderiv ℝ (fderiv ℝ (f i)) (g (b i) (x i))) l (𝓝 H)) + (hD : ∀ᶠ i in l,(∀ᶠ y in 𝓝 (g (b i) (x i)),DifferentiableAt ℝ (f i) y) ∧ + DifferentiableAt ℝ (fderiv ℝ (f i)) (g (b i) (x i))) : + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (fun q=>f i (g (b i) q))) (x i)) l + (𝓝 (secondJetPullback j H (fderiv ℝ (g b₀) x₀) + (fderiv ℝ (fderiv ℝ (g b₀)) x₀))) := by + have hbx := hb.prodMk_nhds hx + have hm := ((ContDiffAt.partial_snd_fderiv hg).continuousAt.tendsto).comp hbx + have hr := ((ContDiffAt.partial_snd_fderiv_two hg).continuousAt.tendsto).comp hbx + have ht := secondJetPullback_tendsto hj hH hm hr + apply ht.congr' + have hg2 := hg.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + filter_upwards [hD,hbx.eventually (hg2.eventually (by norm_num))] with i hi hgi + have hgi' : ContDiffAt ℝ 2 (g (b i)) (x i) := + (hgi.comp (x i) (contDiffAt_const.prodMk contDiffAt_id)) + ext d e + exact (second_fderiv_comp_at hi.1 hi.2 hgi' d e).symm + +end MovingFamilyHessian +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingHessianLimit.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingHessianLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..1ad7d3f659f5361dcf57f7947ae1b3d5f3263448 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingHessianLimit.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeJetTest + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {Q E F : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma tendsto_clm_apply {ι : Type*} {l : Filter ι} + {A : ι → E →L[ℝ] F} {v : ι → E} {A₀ : E →L[ℝ] F} {v₀ : E} + (hA : Tendsto A l (𝓝 A₀)) (hv : Tendsto v l (𝓝 v₀)) : + Tendsto (fun i=>A i (v i)) l (𝓝 (A₀ v₀)) := by + have hc : Continuous (fun q:(E →L[ℝ] F)×E => q.1 q.2) := + continuous_fst.clm_apply continuous_snd + exact (hc.tendsto (A₀,v₀)).comp (hA.prodMk_nhds hv) + +lemma moving_rough_hessian_limit {ι : Type*} {l : Filter ι} + {f : F → ℝ} {g : Q → E → F} {b : ι → Q} {x : ι → E} + {b₀ : Q} {x₀ : E} {j : F →L[ℝ] ℝ} {H : F →L[ℝ] F →L[ℝ] ℝ} + (hg : ContDiffAt ℝ ∞ (Function.uncurry g) (b₀,x₀)) + (hb : Tendsto b l (𝓝 b₀)) (hx : Tendsto x l (𝓝 x₀)) + (hj : Tendsto (fun i=>fderiv ℝ f (g (b i) (x i))) l (𝓝 j)) + (hH : Tendsto (fun i=>fderiv ℝ (fderiv ℝ f) (g (b i) (x i))) l (𝓝 H)) + (hD : ∀ᶠ i in l,(∀ᶠ y in 𝓝 (g (b i) (x i)),DifferentiableAt ℝ f y) ∧ + DifferentiableAt ℝ (fderiv ℝ f) (g (b i) (x i))) : + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (fun q=>f (g (b i) q))) (x i)) l + (𝓝 (secondJetPullback j H (fderiv ℝ (g b₀) x₀) + (fderiv ℝ (fderiv ℝ (g b₀)) x₀))) := by + have hbx := hb.prodMk_nhds hx + have hm := ((ContDiffAt.partial_snd_fderiv hg).continuousAt.tendsto).comp hbx + have hr := ((ContDiffAt.partial_snd_fderiv_two hg).continuousAt.tendsto).comp hbx + have ht := secondJetPullback_tendsto hj hH hm hr + apply ht.congr' + have hg2 := hg.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + filter_upwards [hD,hbx.eventually (hg2.eventually (by norm_num))] with i hi hgi + have hgi' : ContDiffAt ℝ 2 (g (b i)) (x i) := + (hgi.comp (x i) (contDiffAt_const.prodMk contDiffAt_id)) + ext d e + exact (second_fderiv_comp_at hi.1 hi.2 hgi' d e).symm + +lemma bilinear_limit_nonneg {ι : Type*} {l : Filter ι} [NeBot l] + {B : ι → E →L[ℝ] E →L[ℝ] ℝ} {B₀ : E →L[ℝ] E →L[ℝ] ℝ} + (hB : Tendsto B l (𝓝 B₀)) (hp : ∀ᶠ i in l,∀ d:E,0≤B i d d) (d:E) : + 0≤B₀ d d := by + exact ge_of_tendsto (tendsto_clm_apply (tendsto_clm_apply hB tendsto_const_nhds) tendsto_const_nhds) + (hp.mono (fun i hi=>hi d)) + +lemma bilinear_limit_symm {ι : Type*} {l : Filter ι} [NeBot l] + {B : ι → E →L[ℝ] E →L[ℝ] ℝ} {B₀ : E →L[ℝ] E →L[ℝ] ℝ} + (hB : Tendsto B l (𝓝 B₀)) (hp : ∀ᶠ i in l,∀ d e:E,B i d e=B i e d) (d e:E) : + B₀ d e=B₀ e d := by + exact tendsto_nhds_unique_of_eventuallyEq + (tendsto_clm_apply (tendsto_clm_apply hB tendsto_const_nhds) tendsto_const_nhds) + (tendsto_clm_apply (tendsto_clm_apply hB tendsto_const_nhds) tendsto_const_nhds) + (hp.mono (fun i hi=>hi d e)) + +lemma bilinear_limit_kernel {ι : Type*} {l : Filter ι} [NeBot l] + {B : ι → E →L[ℝ] E →L[ℝ] ℝ} {B₀ : E →L[ℝ] E →L[ℝ] ℝ} + {v : ι → E} {v₀ : E} (hB : Tendsto B l (𝓝 B₀)) (hv : Tendsto v l (𝓝 v₀)) + (hk : ∀ᶠ i in l,∀ d:E,B i (v i) d=0) (d:E) : B₀ v₀ d=0 := by + exact tendsto_nhds_unique_of_eventuallyEq + (tendsto_clm_apply (tendsto_clm_apply hB hv) tendsto_const_nhds) tendsto_const_nhds + (hk.mono (fun i hi=>hi d)) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingSplit.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingSplit.lean new file mode 100644 index 0000000000000000000000000000000000000000..bd7659869db3a1943fe49ec5a9211018e64f4487 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/MovingSplit.lean @@ -0,0 +1,39 @@ +import Mathlib + +namespace OAI + +section + +section + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport + +lemma pair_hessian_snd_from_gradient + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {B : E × E → ℝ} {p : E} (hB : ContDiffAt ℝ 2 B (0,p)) + (u : E × E) {g : E → ℝ} {D : E →L[ℝ] ℝ} + (heq : (fun v : E => fderiv ℝ B (0,v) u) =ᶠ[𝓝 p] g) + (hg : HasFDerivAt g D p) (k : E) : + fderiv ℝ (fderiv ℝ B) (0,p) (0,k) u = D k := by + have hdf := (hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hL : HasFDerivAt (fun v : E => ((0:E),v)) + ((0 : E →L[ℝ] E).prod (ContinuousLinearMap.id ℝ E)) p := + (hasFDerivAt_const (0:E) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := ((hdf.hasFDerivAt.comp (f := fun v : E => ((0:E),v)) p hL).clm_apply + (hasFDerivAt_const u p)).fderiv + have H := congrArg (fun A : E →L[ℝ] ℝ => A k) + (hd.symm.trans (heq.fderiv_eq.trans hg.fderiv)) + simpa only [add_apply,ContinuousLinearMap.comp_apply,zero_apply,map_zero,zero_add, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply] using H + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetAdjoint.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetAdjoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..6a18b08a36563e6dd1fba1cd8ef91ef6110d09f0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetAdjoint.lean @@ -0,0 +1,26 @@ +import Mathlib + +namespace OAI + +section +noncomputable section +namespace WeakMTWTransport +lemma normDet_adjoint_of_pos {E F:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] [CompleteSpace E] [CompleteSpace F] + (T:E →L[ℝ] F) (hd:Module.finrank ℝ E=Module.finrank ℝ F) + (hT:0 < T.toLinearMap.normDet) : + T.adjoint.toLinearMap.normDet=T.toLinearMap.normDet := by + have hm:=LinearMap.normDet_comp_of_finrank_eq T.toLinearMap T.adjoint.toLinearMap hd + have hs:(T.adjoint.comp T).det=T.toLinearMap.normDet^2:=by + simpa only [RCLike.ofReal_real_eq_id,id_eq] using T.normDet_sq.symm + rw [LinearMap.normDet_eq_abs_det] at hm + change |(T.adjoint.comp T).det|=T.adjoint.toLinearMap.normDet*T.toLinearMap.normDet at hm + rw [hs,abs_of_nonneg (sq_nonneg _),pow_two] at hm + exact (mul_right_cancel₀ hT.ne' hm).symm +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetCoercivity.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetCoercivity.lean new file mode 100644 index 0000000000000000000000000000000000000000..b020db2f948e476f09ce2e3a5e21afec5517af1f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/NormDetCoercivity.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactConorm + +namespace OAI + +section +section +noncomputable section +open Module + +namespace WeakMTWTransport +section NormDetCoercivity +variable {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] + +lemma singularValue_le_of_conorm_det (A : E →ₗ[ℝ] F) {b K : ℝ} (hb : 0 hb.le) (fun index _ => H index) + have hp' : b^(finrank ℝ E-1)≤∏ j∈Finset.univ.erase i,A.singularValues j := by + simpa only [Finset.prod_const,Finset.card_erase_of_mem (Finset.mem_univ i), + Finset.card_univ,Fintype.card_fin] using hp + apply (le_div_iff₀ (pow_pos hb _)).mpr + calc + A.singularValues i*b^(finrank ℝ E-1) ≤ + A.singularValues i*(∏ j∈Finset.univ.erase i,A.singularValues j) := + mul_le_mul_of_nonneg_left hp' (A.singularValues_nonneg i) + _ = A.normDet := by + rw [A.normDet_eq_prod_singularValues,←Fin.prod_univ_eq_prod_range] + exact Finset.mul_prod_erase Finset.univ (fun j : Fin (finrank ℝ E) => A.singularValues j) (Finset.mem_univ i) + _ ≤ K := hK + +lemma norm_le_of_conorm_det (A : E →ₗ[ℝ] F) {b K : ℝ} (hb : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_normal_relative_hessian_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 0 < lam) (hcap : 0 ≤ cap) {a : M} + {p : TangentSpace 𝓘(ℝ,Model n) a} (hp : p∈injectivityDomain a) + {m : ℝ} (hm : 0 < m) : + ∃ C≥0, ∀ (x0 : M) (uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ φ : TangentSpace 𝓘(ℝ,Model n) a → ℝ, + ContDiffAt ℝ 2 φ 0 → fderiv ℝ φ 0=innerSL ℝ p → uv.1 a=φ 0 → + (∀ᶠ w in 𝓝 0,φ w≤uv.1 (riemannianExp a w)) → + (∀ d,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) 0 d d+hessianValue a p d) → + ∀ d,fderiv ℝ (fderiv ℝ φ) 0 d d+hessianValue a p d≤C*‖d‖^2 := by + let z := extChartAt 𝓘(ℝ,Model n) a a + let V := TangentSpace 𝓘(ℝ,Model n) a + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) a) := inferInstanceAs (FiniteDimensional ℝ (Model n)) + let c := normalCost a p + obtain ⟨L,hLreg,hLb,hLD⟩ := exists_chart_covector_for_log hp + obtain ⟨e,he,he0,hei,hi⟩ := exists_smooth_chart_fiber_log (a := a) + (zero_mem_injectivityDomain (n := n) a) + (by simpa only [riemannianExp_zero] using mem_extChartAt_source (I := 𝓘(ℝ,Model n)) a) + simp only [riemannianExp_zero] at he he0 hei hi + change ContDiffAt ℝ ∞ e z at he + change e z=0 at he0 + change Function.Injective (fderiv ℝ e z) at hi + have he2 : ContDiffAt ℝ 2 e z := he.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + obtain ⟨k,hk,Hk⟩ := exists_norm_sq_lower_of_injective (fderiv ℝ e z) hi + have hsur : Function.Surjective (fderiv ℝ e z) := + (LinearMap.injective_iff_surjective_of_finrank_eq_finrank (by rfl)).mp hi + obtain ⟨C,hC,HC⟩ := hmtw.exists_relative_hessian_bound hlam hcap a L hLreg (mul_pos hm hk) + refine ⟨C/k,div_nonneg hC hk.le,?_⟩ + intro x0 uv huv φ hφ hφD hval hlo hpos d + let ψ : Model n → ℝ := fun w => φ (e w) + have hψ : ContDiffAt ℝ 2 ψ z := (he0.symm ▸ hφ).comp z he2 + have hc : ContDiffAt ℝ 2 c 0 := + (normalCost_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hce : chartCost a (riemannianExp a p) =ᶠ[𝓝 z] (fun w => c (e w)) := by + filter_upwards [hei] with w hw + simp only [c,normalCost,chartCost,hw] + have hcc : ContDiffAt ℝ 2 (chartCost a (riemannianExp a p)) z := + ((he0.symm ▸ hc).comp z he2).congr_of_eventuallyEq hce + have hψD : fderiv ℝ ψ z=L := by + have Hc := hce.fderiv_eq (𝕜 := ℝ) + rw [hLD.fderiv,fderiv_fun_comp z + (by simpa only [he0] using hc.differentiableAt (by norm_num)) + (he2.differentiableAt (by norm_num)),he0,(normalCost_hasFDerivAt_zero hp).fderiv] at Hc + rw [show ψ=(fun w => φ (e w)) from rfl,fderiv_fun_comp z + (by simpa only [he0] using hφ.differentiableAt (by norm_num)) + (he2.differentiableAt (by norm_num)),he0,hφD] + apply ContinuousLinearMap.ext + intro d + have H := congrArg (fun A : Model n →L[ℝ] ℝ => A d) Hc + simpa only [neg_apply,ContinuousLinearMap.comp_apply, + innerSL_apply_apply,inner_neg_left,neg_inj] using H.symm + have hψval : uv.1 a=ψ z := by simpa only [ψ,he0] using hval + have hψlo : ∀ᶠ w in 𝓝 z,ψ w≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w) := by + have H := he.continuousAt.eventually (show ∀ᶠ v in 𝓝 (e z),φ v≤uv.1 (riemannianExp a v) by rwa [he0]) + filter_upwards [H,hei] with w hw hwi + simpa only [ψ,hwi] using hw + have Hpull (d : Model n) : fderiv ℝ (fderiv ℝ ψ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (riemannianExp a p))) z d d = + fderiv ℝ (fderiv ℝ φ) 0 (fderiv ℝ e z d) (fderiv ℝ e z d)+ + hessianValue a p (fderiv ℝ e z d) := by + have hzF : fderiv ℝ (fun v => φ v+c v) 0=0 := by + rw [fderiv_fun_add (hφ.differentiableAt (by norm_num)) (hc.differentiableAt (by norm_num)), + hφD,(normalCost_hasFDerivAt_zero hp).fderiv] + simp only [map_neg,add_neg_cancel] + have HF := second_fderiv_comp_stationary (f := fun v => φ v+c v) (g := e) + (he0.symm ▸ hφ.add hc) he2 (by rwa [he0]) d d + rw [he0,second_fderiv_add_eq hφ hc] at HF + rw [hessianValue_eq_normalHessian hp] + have Heq : (fun w => ψ w+chartCost a (riemannianExp a p) w) =ᶠ[𝓝 z] + (fun w => φ (e w)+c (e w)) := by + filter_upwards [hce] with w hw + rw [hw] + have HH := congrArg (fun A : Model n →L[ℝ] Model n →L[ℝ] ℝ => A d d) Heq.fderiv.fderiv_eq + rw [second_fderiv_add_eq hψ hcc] at HH + exact HH.trans HF + have hψpos (d : Model n) : (m*k)*‖d‖^2≤fderiv ℝ (fderiv ℝ ψ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,L)))) z d d := by + rw [hLb,Hpull] + calc + _ = m*(k*‖d‖^2) := by ring + _ ≤ m*‖fderiv ℝ e z d‖^2 := mul_le_mul_of_nonneg_left (Hk d) hm.le + _ ≤ _ := hpos _ + obtain ⟨w,hw⟩ := hsur d + have HB := HC x0 uv huv ψ hψ hψD hψval hψlo hψpos w + rw [hLb,Hpull,hw] at HB + have Hb := Hk w + rw [hw] at Hb + calc + _ ≤ C*‖w‖^2 := HB + _ ≤ (C/k)*‖d‖^2 := by + have HH : ‖w‖^2≤‖d‖^2/k := (le_div_iff₀ hk).mpr (by nlinarith only [Hb]) + convert! mul_le_mul_of_nonneg_left HH hC using 1; ring + +end NormalRelativeHessianBound +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OperatorBounds.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OperatorBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..3fbd4a34b908c15356e0c86c67520996c0a63af0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OperatorBounds.lean @@ -0,0 +1,122 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology + +namespace WeakMTWTransport +section OperatorBounds +variable {A E F : Type*} [TopologicalSpace A] + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma eventually_injective_operator_bounds {f : A → E →L[ℝ] F} {a : A} + (hf : ContinuousAt f a) (hi : Function.Injective (f a)) : + ∃ c C : ℝ, 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance oamFinite (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance oamComplete (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +lemma WeakMTW.exists_uniform_active_outer_matrix + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) : + ∃K>0,∀ (x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)) (φ:ℝ → ℝ), + uv∈densityDualClass (metricVolume n) lam cap x0 → Continuous φ → StrictMono φ → + ∀ (z:TangentBundle 𝓘(ℝ,Model n) M) (l:ℝ),z.2∈activeLogs (φ ∘ uv.2) z.1 → + ContDiffAt ℝ 2 φ (uv.2 (riemannianExp z.1 z.2)) → + HasDerivAt φ l (uv.2 (riemannianExp z.1 z.2)) → 1 < l → + iteratedDeriv 2 φ (uv.2 (riemannianExp z.1 z.2)) ≤ 0 → + ∀ B:TangentSpace 𝓘(ℝ,Model n) z.1 →L[ℝ] TangentSpace 𝓘(ℝ,Model n) z.1 →L[ℝ] ℝ, + (∀d e,B d e=B e d) → (∀d,0 ≤ B d d) → + HasLowerSecondTaylor (fun d=>φ (uv.2 (riemannianExp z.1 (z.2+d)))+‖z.2+d‖^2/2) 0 B → + ∃V:TangentSpace 𝓘(ℝ,Model n) z.1 →L[ℝ] TangentSpace 𝓘(ℝ,Model n) z.1, + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,B d d-(iteratedDeriv 2 φ (uv.2 (riemannianExp z.1 z.2))/l^2)* + (inner ℝ z.2 d)^2 ≤ inner ℝ (V d) d) ∧ + 0 < expJacobian (n:=n) z.1 z.2 ∧ + 0 < expJacobian (n:=n) (reverseRay z).1 (l⁻¹ • (reverseRay z).2) ∧ + expJacobian (n:=n) (reverseRay z).1 (l⁻¹ • (reverseRay z).2)*V.det ≤ + l^n*K*(expJacobian (n:=n) z.1 z.2)^2 := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_outer_true_matrix hlam hcap + refine ⟨K,hK,?_⟩ + intro x0 uv φ huv hφc hm z l ha hφ hd hl hconc B hBs hB hjet + have hnc:=hmtw.active_outer_nonconjugate hlam hcap huv hφc hm ha hφ hd hl hconc + obtain ⟨G,hG,hact,hagree⟩:=exists_reverse_branch_with_forward_action z hnc + have hy:riemannianExp z.1 z.2=(reverseRay z).1:=(reverseRay_base z).symm + have hx:riemannianExp (reverseRay z).1 (reverseRay z).2=z.1:=reverseRay_endpoint z + have hr:=(reverseRay_minimizing ha.1) + have hact':∀ᶠ q in 𝓝 z.2,G (riemannianExp z.1 q,z.1)=‖q‖^2/2:= + (FiberBundle.continuous_totalSpaceMk (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x) z.1).continuousAt.eventually hact + obtain ⟨C,V,hCI,hCd,hpair,hVs,hVp,hVeq,hVdet⟩:=HK z.1 (reverseRay z).1 z.2 + (reverseRay z).2 G l hy hx hr hnc (by simpa only [hx] using hG) hact' hagree hl + x0 uv φ huv hm (by simpa only [reverseRay_base] using hφ) + (by simpa only [reverseRay_base] using hd) (by simpa only [reverseRay_base] using hconc) + B hBs hB hjet + have hl0:0 < l:=zero_lt_one.trans hl + obtain ⟨m,hm',HM⟩:=exists_branch_divided_baseline hr (inv_pos.mpr hl0) + (inv_lt_one_of_one_lt₀ hl) hG hagree + have hJac:0 < expJacobian (n:=n) z.1 z.2:=by + rw [←hCd] + apply lt_of_le_of_ne (LinearMap.normDet_nonneg _) + apply Ne.symm + rw [ne_eq,LinearMap.normDet_eq_zero_iff_ker_ne_bot,not_not,LinearMap.ker_eq_bot] + exact hCI + refine ⟨V,hVs,hVp,?_,hJac,?_,hVdet⟩ + · intro d + have HH:=HM (C d) + rw [div_inv_eq_mul,mul_comm (hessianValue _ _ _) l,hx] at HH + have H0:0 ≤ l*hessianValue (reverseRay z).1 (l⁻¹ • (reverseRay z).2) (C d)- + fderiv ℝ (fderiv ℝ (fun w=>G (riemannianExp (reverseRay z).1 w,z.1))) 0 (C d) (C d):= + (mul_nonneg hm'.le (sq_nonneg _)).trans HH + rw [hVeq,hy] + linarith only [H0] + · exact expJacobian_pos_of_injectivityDomain + (contracted_minimizer_mem_injectivityDomain hr (inv_pos.mpr hl0) (inv_lt_one_of_one_lt₀ hl)) +end OuterActiveMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterDisplacementJetBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterDisplacementJetBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..a7aec04aa63a3b65a611e751d3d50726e05f8783 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterDisplacementJetBound.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Calculus +import OAI.Analysis.BiholderTransport.Regularity.StationaryPullback +import OAI.Analysis.BiholderTransport.LinearAlgebra.LocalMountains + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +lemma convexOn_of_nonnegative_hessian {f : E → ℝ} {S : Set E} + (hS : Convex ℝ S) (hf : ∀ z∈S,ContDiffAt ℝ 2 f z) + (hH : ∀ z∈S,∀ d:E,0≤fderiv ℝ (fderiv ℝ f) z d d) : ConvexOn ℝ S f := by + apply convexOn_of_affine_lower_supports hS + intro x hx + exact ⟨fderiv ℝ f x,fun y hy => lower_support_of_nonnegative_hessian hS hf hH hx hy⟩ + +lemma strongConvexOn_of_hessian_lower {f : E → ℝ} {S : Set E} {m : ℝ} + (hS : Convex ℝ S) (hf : ∀ z∈S,ContDiffAt ℝ 2 f z) + (hH : ∀ z∈S,∀ d:E,m*‖d‖^2≤fderiv ℝ (fderiv ℝ f) z d d) : + StrongConvexOn S m f := by + rw [strongConvexOn_iff_convex] + have hN (z:E) : ContDiffAt ℝ 2 (fun w:E => ‖w‖^2/2) z := + (half_norm_sq_contDiff.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + have he : (fun z => f z-m/2*‖z‖^2)=(fun z => f z-m*(‖z‖^2/2)) := by + ext z; ring + rw [he] + apply convexOn_of_nonnegative_hessian hS + (fun z hz => (hf z hz).sub (contDiffAt_const.mul (hN z))) + intro z hz d + rw [second_fderiv_sub (hf z hz) (contDiffAt_const.mul (hN z)), + second_fderiv_const_mul,half_norm_sq_second_fderiv,real_inner_self_eq_norm_sq] + exact sub_nonneg.mpr (hH z hz d) + +lemma StrongConvexOn.quadratic_growth_half {f : E → ℝ} {S : Set E} {m : ℝ} + (hf : StrongConvexOn S m f) {x y:E} (hx:x∈S) (hy:y∈S) + (hmin : IsMinOn f S x) : f x+(m/4)*‖y-x‖^2≤f y := by + have H := hf.2 hx hy (by norm_num : (0:ℝ)≤1/2) (by norm_num : (0:ℝ)≤1/2) + (by norm_num : (1/2:ℝ)+1/2=1) + have HM := hmin (hf.1 hx hy (by norm_num : (0:ℝ)≤1/2) + (by norm_num : (0:ℝ)≤1/2) (by norm_num : (1/2:ℝ)+1/2=1)) + change f ((1/2:ℝ) • x+(1/2:ℝ) • y)≤ + (1/2:ℝ)*f x+(1/2:ℝ)*f y-(1/2:ℝ)*(1/2:ℝ)*(m/2*‖x-y‖^2) at H + rw [norm_sub_rev] at H + change f x≤f ((1/2:ℝ) • x+(1/2:ℝ) • y) at HM + linarith only [H,HM] + +lemma strongConvexOn_add_semiconvex {f g : E → ℝ} {S : Set E} {m K t : ℝ} + (hf : StrongConvexOn S m f) (hg : ConvexOn ℝ S (fun x => g x+K/2*‖x‖^2)) + (ht : 0≤t) : StrongConvexOn S (m-t*K) (fun x => f x+t*g x) := by + rw [strongConvexOn_iff_convex] at hf ⊢ + have HF : ConvexOn ℝ S (fun x => (f x-m/2*‖x‖^2)+t*(g x+K/2*‖x‖^2)) := + hf.add (hg.smul ht) + convert HF using 1 + ext x + ring + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterTrueMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterTrueMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ea052f7ee40cb2d7c611fb3431a835870bbb63a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/OuterTrueMatrix.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.LowerTaylorComposition +import OAI.Analysis.BiholderTransport.Regularity.OuterIntrinsicSecond +import OAI.Analysis.BiholderTransport.Coordinates.NormalEndpointInverse + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OuterTrueMatrix +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance otFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +local instance otComplete (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +lemma WeakMTW.exists_uniform_outer_true_matrix + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:00,∀ (x y:M) (p:TangentSpace 𝓘(ℝ,Model n) x) + (r:TangentSpace 𝓘(ℝ,Model n) y) (G:M×M → ℝ) (l:ℝ), + riemannianExp x p=y → riemannianExp y r=x → r∈minimizingVectors y → + Function.Injective (fderiv ℝ (fun v=>extChartAt 𝓘(ℝ,Model n) + (riemannianExp x p) (riemannianExp x v)) p) → + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G (y,x) → + (∀ᶠ q in 𝓝 p,G (riemannianExp x q,x)=‖q‖^2/2) → + (∀ᶠ z in 𝓝 (⟨y,r⟩:TangentBundle 𝓘(ℝ,Model n) M),z.2∈injectivityDomain z.1 → + (fun q:M×M=>cost q.1 q.2)=ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) → 1φ (uv.2 (riemannianExp x (p+d)))+‖p+d‖^2/2) 0 B → + ∃ (C:TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y) + (V:TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x), + Function.Injective C ∧ C.toLinearMap.normDet=expJacobian (n:=n) x p ∧ + (∀d,inner ℝ r (C d)=-inner ℝ p d) ∧ + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,inner ℝ (V d) d=B d d+(l*hessianValue y (l⁻¹ • r) (C d)- + fderiv ℝ (fderiv ℝ (fun w=>G (riemannianExp y w,x))) 0 (C d) (C d))- + (iteratedDeriv 2 φ (uv.2 y)/l^2)*(inner ℝ p d)^2) ∧ + expJacobian (n:=n) y (l⁻¹ • r)*V.det≤l^n*K*(expJacobian (n:=n) x p)^2 := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_outer_normal_det_bound_second hlam hcap + refine ⟨K,hK,?_⟩ + intro x y p r G l hxy hyx hr hp hG hact hagree hl x0 uv φ huv hmono hφ hd hconc B hBs hB hjet + subst y + let y:=riemannianExp x p + let E:=TangentSpace 𝓘(ℝ,Model n) x + let F:=TangentSpace 𝓘(ℝ,Model n) y + obtain ⟨e,C,he,he0,hei,hCI,hCJ,hJC,hCd⟩:=exists_normal_endpoint_inverse hp + let J:F →L[ℝ] E:=fderiv ℝ e 0 + let H:=pullBilinear B J + have hHs:∀d e,H d e=H e d:=by intro d e; exact hBs (J d) (J e) + have hHp:∀d,0≤H d d:=fun d=>hB (J d) + have hJcomp (d:E):J (C d)=d:=congrArg (fun A:E →L[ℝ] E=>A d) hJC + have hjet2:HasLowerSecondTaylor + (fun w:F=>φ (uv.2 (riemannianExp y w))+G (riemannianExp y w,x)) 0 H:=by + have ha:HasFDerivAt (fun w:F=>e w-p) J 0:= + (he.differentiableAt (by simp)).hasFDerivAt.sub_const p + have Z:=HasLowerSecondTaylor.comp_stationary hjet ha (by rw [he0,sub_self]) + have ha':=he.continuousAt.eventually (show ∀ᶠ q in 𝓝 (e 0),G (riemannianExp x q,x)=‖q‖^2/2 + from by rw [he0]; exact hact) + have hEq:(fun w:F=>φ (uv.2 (riemannianExp x (p+(e w-p))))+‖p+(e w-p)‖^2/2) =ᶠ[𝓝 0] + (fun w:F=>φ (uv.2 (riemannianExp y w))+G (riemannianExp y w,x)):=by + filter_upwards [hei,ha'] with w hw ha + have hh:p+(e w-p)=e w:=by abel + rw [hh,←hw,ha] + exact Z.mono hEq.eq_of_nhds hEq.le + have hG':ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ G + (y,riemannianExp y r):=by rw [hyx]; exact hG + obtain ⟨N,hNs,hNp,hNd,hNdet⟩:=HK y r G l hr hG' hagree hl x0 uv φ huv hmono hφ hd hconc H hHs hHp + (by simpa only [y,hyx] using hjet2) + have hcD:HasFDerivAt (fun w:F=>G (riemannianExp y w,x)) (innerSL ℝ (-r)) 0:=by + have HH:=cost_branch_normal_jets (r:=r) (T:=(1:ℝ)) (by norm_num) + (by simpa only [one_smul] using hG') (by simpa only [one_smul] using hagree) + (fun s hs=>contracted_minimizer_mem_injectivityDomain hr hs.1 hs.2) + simpa only [one_smul,hyx] using HH.2.1 + have heq:(fun w:F=>G (riemannianExp y w,x)) =ᶠ[𝓝 0] (fun w:F=>‖e w‖^2/2):=by + have ha':=he.continuousAt.eventually (show ∀ᶠ q in 𝓝 (e 0),G (riemannianExp x q,x)=‖q‖^2/2 + from by rw [he0]; exact hact) + filter_upwards [hei,ha'] with w hw ha + rw [←hw,ha] + have henergy:HasFDerivAt (fun v:E=>‖v‖^2/2) (innerSL ℝ p) p:=by + convert! ((hasStrictFDerivAt_norm_sq p).hasFDerivAt.const_mul (1/2:ℝ)) using 1 + · ext v; ring + · ext v; simp only [smul_apply,smul_eq_mul]; ring + have henergy2:HasFDerivAt (fun w:F=>‖e w‖^2/2) ((innerSL ℝ p).comp J) 0:= + (show HasFDerivAt (fun v:E=>‖v‖^2/2) (innerSL ℝ p) (e 0) from by rw [he0]; exact henergy).comp + 0 (he.differentiableAt (by simp)).hasFDerivAt + have hpair:∀d,inner ℝ r (C d)=-inner ℝ p d:=by + intro d + have HH:innerSL ℝ (-r)=(innerSL ℝ p).comp J:= + (hcD.congr_of_eventuallyEq heq.symm).unique henergy2 + have hh:=congrArg (fun A:F →L[ℝ] ℝ=>A (C d)) HH + simp only [ContinuousLinearMap.comp_apply,innerSL_apply_apply,inner_neg_left,hJcomp] at hh + linarith only [hh] + let V:=C.adjoint.comp (N.comp C) + have hVs:∀d e,inner ℝ (V d) e=inner ℝ d (V e):=by + intro d e + simp only [V,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left, + ContinuousLinearMap.adjoint_inner_right,hNs] + have hpos:=det_positive_hessian_pullback (B:=C) (W:=N) + ((tangent_finrank x).trans (tangent_finrank y).symm) hCI hNs hNp (l:=1) (by norm_num) + simp only [one_smul,one_pow,one_mul] at hpos + refine ⟨C,V,hCI,hCd.symm,hpair,hVs,hpos.1,?_,?_⟩ + · intro d + simp only [V,ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] + rw [hNd,hyx] + change B (J (C d)) (J (C d))+_ -_ =_ + rw [hJcomp,hpair,neg_sq] + · have HV:V.det=expJacobian (n:=n) x p^2*N.det:=by rw [hpos.2,←hCd] + rw [HV] + nlinarith only [mul_le_mul_of_nonneg_right hNdet (sq_nonneg (expJacobian (n:=n) x p))] +end OuterTrueMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Pole.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Pole.lean new file mode 100644 index 0000000000000000000000000000000000000000..9bd86f3fd9a4dc62bbcfdca84aa7e755d1516a3f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/Pole.lean @@ -0,0 +1,57 @@ +import Mathlib + +namespace OAI + + + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma bilinear_differentiable_substitution + (K : F →L[ℝ] F →L[ℝ] ℝ) {r : E → F} {R : E →L[ℝ] F} + (hr0 : r 0 = 0) (hr : HasFDerivAt r R 0) : + (fun h => K (r h) (r h) - K (R h) (R h)) =o[𝓝 0] (fun h : E => ‖h‖^2) := by + have he : (fun h => r h-R h) =o[𝓝 0] (fun h : E => h) := by + simpa only [hr0,sub_zero] using hr.isLittleO + have hro : r =O[𝓝 0] (fun h : E => h) := by + simpa only [hr0,sub_zero] using hr.isBigO_sub + have hRo : (fun h => R h) =O[𝓝 0] (fun h : E => h) := R.isBigO_comp _ _ + have h₁ : (fun h => K (r h-R h) (r h)) =o[𝓝 0] (fun h : E => ‖h‖*‖h‖) := + K.isBoundedBilinearMap.isBigO_comp.trans_isLittleO (he.norm_norm.mul_isBigO hro.norm_norm) + have h₂ : (fun h => K (R h) (r h-R h)) =o[𝓝 0] (fun h : E => ‖h‖*‖h‖) := + K.isBoundedBilinearMap.isBigO_comp.trans_isLittleO (hRo.norm_norm.mul_isLittleO he.norm_norm) + convert! h₁.add h₂ using 1 + · funext h + simp only [map_sub,sub_apply] + ring + · funext h + ring + +lemma second_order_substitution_exact_linear + {f : F → ℝ} {D : F →L[ℝ] ℝ} {K : F →L[ℝ] F →L[ℝ] ℝ} + (hf : (fun z => f z-f 0-D z-K z z/2) =o[𝓝 0] (fun z : F => ‖z‖^2)) + {r : E → F} {R : E →L[ℝ] F} (hr0 : r 0 = 0) (hr : HasFDerivAt r R 0) : + (fun h => f (r h)-f 0-D (r h)-K (R h) (R h)/2) + =o[𝓝 0] (fun h : E => ‖h‖^2) := by + have hro : r =O[𝓝 0] (fun h : E => h) := by + simpa only [hr0,sub_zero] using hr.isBigO_sub + have hn : (fun h => ‖r h‖^2) =O[𝓝 0] (fun h : E => ‖h‖^2) := by + simpa only [← sq] using hro.norm_norm.mul hro.norm_norm + have hc : Tendsto r (𝓝 0) (𝓝 0) := by simpa only [ContinuousAt,hr0] using hr.continuousAt + have H := (hf.comp_tendsto hc).trans_isBigO hn + have HQ := (bilinear_differentiable_substitution K hr0 hr).const_mul_left (1/2:ℝ) + convert! H.add HQ using 1 + funext h + simp only [Function.comp_def] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveBilinearBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveBilinearBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..7145ffdf36ef3e6579aaff57d2db985925d934bd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveBilinearBound.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.StrictDividedAction +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactCrossing + +namespace OAI + +section +section +noncomputable section +open Set Metric + +namespace WeakMTWTransport +section PositiveBilinearBound +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma exists_bilinear_positive_baseline (B : E →L[ℝ] E →L[ℝ] ℝ) + (hB : ∀ v : E,v≠0 → 0 < B v v) : + ∃ m>0,∀ v : E,m*‖v‖^2≤B v v := by + let S := sphere (0:E) 1 + have hS : IsCompact S := isCompact_sphere _ _ + have hc : ContinuousOn (fun v:E => B v v) S := + (B.continuous.clm_apply continuous_id).continuousOn + obtain ⟨m,hm,Hm⟩ : ∃ m>0,∀ v∈S,m≤B v v := by + by_cases hne : S.Nonempty + · obtain ⟨v,hv,Hv⟩ := hS.exists_isMinOn hne hc + have hn : ‖v‖=1 := by simpa only [S,mem_sphere,dist_zero_right] using hv + have hp : 0 < B v v := hB v (by intro he; simp [he] at hn) + exact ⟨B v v,hp,fun w hw => Hv hw⟩ + · exact ⟨1,zero_lt_one,fun v hv => (hne ⟨v,hv⟩).elim⟩ + exact ⟨m,hm,bilinear_lower_of_unit B (fun v hv => Hm v (by simpa only [S,mem_sphere,dist_zero_right] using hv))⟩ + +end PositiveBilinearBound +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section DividedBaseline +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma divided_hessian_decrease {a : M} {r ξ : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈minimizingVectors a) {t s : ℝ} (ht : 0 < t) (hts : t ≤ s) (hs : s<1) : + hessianValue a (s • r) ξ/s ≤ hessianValue a (t • r) ξ/t := by + rcases eq_or_lt_of_le hts with h | h + · simp only [h,le_refl] + by_cases hξ : ξ=0 + · subst ξ + rw [hessianValue_eq_normalHessian (contracted_minimizer_mem_injectivityDomain hr (ht.trans h) hs), + hessianValue_eq_normalHessian (contracted_minimizer_mem_injectivityDomain hr ht (h.trans hs))] + simp only [map_zero,zero_div,le_refl] + exact (divided_hessian_strict_decrease hr ht h hs hξ).le + +lemma exists_divided_hessian_baseline {a : M} {r : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈minimizingVectors a) {t s0 : ℝ} (ht : 0 < t) (hts : t0,∀ s : ℝ,s0 ≤ s → s<1 → ∀ ξ : TangentSpace 𝓘(ℝ,Model n) a, + m*‖ξ‖^2 ≤ hessianValue a (t • r) ξ/t-hessianValue a (s • r) ξ/s := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) a) := inferInstanceAs (FiniteDimensional ℝ (Model n)) + let B := t⁻¹ • normalHessian a (t • r)-s0⁻¹ • normalHessian a (s0 • r) + have hIDt := contracted_minimizer_mem_injectivityDomain hr ht (hts.trans hs0) + have hIDs := contracted_minimizer_mem_injectivityDomain hr (ht.trans hts) hs0 + have hB (ξ : TangentSpace 𝓘(ℝ,Model n) a) : B ξ ξ= + hessianValue a (t • r) ξ/t-hessianValue a (s0 • r) ξ/s0 := by + rw [hessianValue_eq_normalHessian hIDt,hessianValue_eq_normalHessian hIDs] + simp only [B,sub_apply,smul_apply,smul_eq_mul] + ring + obtain ⟨m,hm,Hm⟩ := exists_bilinear_positive_baseline B (fun ξ hξ => by + rw [hB] + exact sub_pos.mpr (divided_hessian_strict_decrease hr ht hts hs0 hξ)) + refine ⟨m,hm,?_⟩ + intro s hss hs1 ξ + have H := Hm ξ + rw [hB] at H + have Hd := divided_hessian_decrease (ξ := ξ) hr (ht.trans hts) hss hs1 + linarith only [H,Hd] + +end DividedBaseline +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveDetCompact.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveDetCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..d23dc7fdce3db128300a2918ae113d45a693c868 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveDetCompact.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.NormDetCoercivity +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingHessianLimit +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearCompact +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose +import OAI.Analysis.BiholderTransport.LinearAlgebra.RankOneCoercive + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section PositiveDetCompact +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +local instance positiveCompactDualGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance positiveCompactDualSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +local instance positiveCompactBilinearGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance +local instance positiveCompactBilinearSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance + +lemma bilinear_eventual_coercivity + {B:ℕ → E →L[ℝ] E →L[ℝ] ℝ} {B₀:E →L[ℝ] E →L[ℝ] ℝ} + (hB:Tendsto B atTop (𝓝 B₀)) (hpos:∀d,d≠0 → 0 < B₀ d d) : + ∃m>0,∀ᶠ k in atTop,∀d:E,m*‖d‖^2 ≤ B k d d := by + obtain ⟨c,hc,HC⟩:=positive_bilinear_uniform_lower hpos + have hn:Tendsto (fun k=>‖B₀-B k‖) atTop (𝓝 0):=by + simpa only [sub_self,norm_zero] using (show Tendsto (fun k=>B₀-B k) atTop (𝓝 (B₀-B₀)) from tendsto_const_nhds.sub hB).norm + refine ⟨c/2,half_pos hc,?_⟩ + filter_upwards [hn.eventually (gt_mem_nhds (half_pos hc))] with k hk + intro d + have H:=bilinear_quadratic_close hk.le d + nlinarith only [H,HC d] + +lemma exists_bilinear_limit_of_det_lower + {B V:ℕ → E →L[ℝ] E →L[ℝ] ℝ} {B₀:E →L[ℝ] E →L[ℝ] ℝ} + (hB:Tendsto B atTop (𝓝 B₀)) (hpos:∀d,d≠0 → 0 < B₀ d d) + (hV:∀ᶠ k in atTop,(∀d e,V k d e=V k e d) ∧ ∀d,B k d d ≤ V k d d) + {K:ℝ} (hK:0 ≤ K) (hdet:∀ᶠ k in atTop,|(bilinearOperator (V k)).det| ≤ K) : + ∃V₀:E →L[ℝ] E →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ + Tendsto (V ∘ σ) atTop (𝓝 V₀) ∧ + (∀d e,V₀ d e=V₀ e d) ∧ (∀d,B₀ d d ≤ V₀ d d) ∧ + (∀d,d≠0 → 0 < V₀ d d) := by + obtain ⟨m,hm,Hm⟩:=bilinear_eventual_coercivity hB hpos + let C:ℝ:=(Module.finrank ℝ E:ℝ)*K/m^(Module.finrank ℝ E-1) + have hC:0 ≤ C:=by dsimp only [C]; positivity + have Hbound:∀ᶠ k in atTop,‖V k‖ ≤ C:=by + filter_upwards [Hm,hV,hdet] with k hk hv hd + have hlo:∀d:E,m*‖d‖^2 ≤ V k d d:=fun d=>(hk d).trans (hv.2 d) + apply symmetric_bilinear_norm_bound hv.1 hC + intro d + rw [abs_of_nonneg ((mul_nonneg hm.le (sq_nonneg _)).trans (hlo d))] + exact bilinear_quadratic_bound_of_det hm hlo hd d + obtain ⟨V₀,σ,hσ,HV⟩:=exists_bilinear_limit Hbound + have Hlower:∀d,B₀ d d ≤ V₀ d d:=by + intro d + exact le_of_tendsto_of_tendsto + (tendsto_clm_apply (tendsto_clm_apply (hB.comp hσ.tendsto_atTop) tendsto_const_nhds) tendsto_const_nhds) + (tendsto_clm_apply (tendsto_clm_apply HV tendsto_const_nhds) tendsto_const_nhds) + (hσ.tendsto_atTop.eventually (hV.mono (fun k hk=>hk.2 d))) + refine ⟨V₀,σ,hσ,HV,?_,Hlower,fun d hd=>(hpos d hd).trans_le (Hlower d)⟩ + exact bilinear_limit_symm HV (hσ.tendsto_atTop.eventually (hV.mono (fun k hk=>hk.1))) + +end PositiveDetCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveSingular.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveSingular.lean new file mode 100644 index 0000000000000000000000000000000000000000..fba1949dd734694425ed6626bc919841ef3e51ab --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PositiveSingular.lean @@ -0,0 +1,162 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeSlice +import OAI.Analysis.BiholderTransport.LinearAlgebra.DividedHessian +import OAI.Analysis.BiholderTransport.Regularity.NormMinMax + +namespace OAI + +section +section +noncomputable section +open scoped BigOperators + +namespace WeakMTWTransport +section PositiveSingular +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma eigenbasis_operator_norm_expansion {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (hn : Module.finrank ℝ E=n) (v : E) : + ‖A v‖^2 = ∑ j, (hA.eigenvalues hn j)^2*((hA.eigenvectorBasis hn).repr v j)^2 := by + rw [eigenbasis_norm_expansion (hA.eigenvectorBasis hn)] + apply Finset.sum_congr rfl + intro j hj + rw [hA.eigenvectorBasis_apply_self_apply] + simp only [RCLike.ofReal_real_eq_id,id_eq,mul_pow] + +lemma positive_norm_lower_spectral_slice {A : E →ₗ[ℝ] E} (hA : A.IsPositive) + {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) (v : E) + (hv : ∀ j : Fin n, i < j → (hA.isSymmetric.eigenvectorBasis hn).repr v j=0) : + (hA.isSymmetric.eigenvalues hn i)^2*‖v‖^2≤‖A v‖^2 := by + rw [eigenbasis_operator_norm_expansion hA.isSymmetric hn, + eigenbasis_norm_expansion (hA.isSymmetric.eigenvectorBasis hn),Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hji : j ≤ i + · apply mul_le_mul_of_nonneg_right _ (sq_nonneg _) + exact pow_le_pow_left₀ (hA.nonneg_eigenvalues hn i) + (hA.isSymmetric.eigenvalues_antitone hn hji) 2 + · rw [hv j (lt_of_not_ge hji)]; simp + +lemma positive_norm_upper_spectral_slice {A : E →ₗ[ℝ] E} (hA : A.IsPositive) + {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) (v : E) + (hv : ∀ j : Fin n, j < i → (hA.isSymmetric.eigenvectorBasis hn).repr v j=0) : + ‖A v‖^2≤(hA.isSymmetric.eigenvalues hn i)^2*‖v‖^2 := by + rw [eigenbasis_operator_norm_expansion hA.isSymmetric hn, + eigenbasis_norm_expansion (hA.isSymmetric.eigenvectorBasis hn),Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hij : i ≤ j + · apply mul_le_mul_of_nonneg_right _ (sq_nonneg _) + exact pow_le_pow_left₀ (hA.nonneg_eigenvalues hn j) + (hA.isSymmetric.eigenvalues_antitone hn hij) 2 + · rw [hv j (lt_of_not_ge hij)]; simp + +lemma positive_singularValues_eq_eigenvalues {A : E →ₗ[ℝ] E} (hA : A.IsPositive) + {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) : + A.singularValues i=hA.isSymmetric.eigenvalues hn i := by + have hG := A.isSymmetric_adjoint_comp_self + have hApos := hA.nonneg_eigenvalues hn i + have hspos := A.singularValues_nonneg i + apply le_antisymm + · obtain ⟨v,hv,hgv,hav⟩ := paired_basis_slice (hG.eigenvectorBasis hn) + (hA.isSymmetric.eigenvectorBasis hn) i + have h1 := quadratic_lower_spectral_slice hG hn i v hgv + have h2 := positive_norm_upper_spectral_slice hA hn i v hav + simp only [LinearMap.comp_apply,LinearMap.adjoint_inner_left, + real_inner_self_eq_norm_sq] at h1 + rw [←A.sq_singularValues_fin hn] at h1 + have hp : 0<‖v‖^2 := sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv) + have hsq := (mul_le_mul_iff_left₀ hp).mp (h1.trans h2) + nlinarith + · obtain ⟨v,hv,hav,hgv⟩ := paired_basis_slice (hA.isSymmetric.eigenvectorBasis hn) + (hG.eigenvectorBasis hn) i + have h1 := positive_norm_lower_spectral_slice hA hn i v hav + have h2 := quadratic_upper_spectral_slice hG hn i v hgv + simp only [LinearMap.comp_apply,LinearMap.adjoint_inner_left, + real_inner_self_eq_norm_sq] at h2 + rw [←A.sq_singularValues_fin hn] at h2 + have hp : 0<‖v‖^2 := sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv) + have hsq := (mul_le_mul_iff_left₀ hp).mp (h1.trans h2) + nlinarith + +end PositiveSingular +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CrossingDerivative +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma normalHessian_radial_derivative_value {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈injectivityDomain x) + (v : TangentSpace 𝓘(ℝ,Model n) x) : + HasDerivAt (fun s : ℝ => normalHessian x (s • p) v v) + (normalHessian x p v v-radialCrossingValue x p v) 1 := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let B := doubleNormalCost (n := n) x x + have hB : ContDiffAt ℝ 3 B (0,p) := + (doubleNormalCost_self_contDiffAt hp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 3) + have hD := hasDerivAt_source_hessian_line (a := (0:X)) (b := p) + (w := p) (t := 1) (v := v) hB + have heq : (fun s : ℝ => fderiv ℝ (fderiv ℝ (fun a : X => B (a,p+(s-1) • p))) 0 v v)= + (fun s : ℝ => normalHessian x (s • p) v v) := by + funext s + have hs : p+(s-1) • p=s • p := by module + rw [hs] + rfl + rw [heq] at hD + have hS := second_derivative_source_slice (a := (0:X)) (b := p) + (hB.of_le (by norm_num)) v v + change normalHessian x p v v = _ at hS + convert hD using 1 + dsimp only [radialCrossingValue] + rw [←hS] + ring + +lemma divided_normalHessian_derivative_value {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} (ht : t≠0) + (hp : t • p∈injectivityDomain x) (v : TangentSpace 𝓘(ℝ,Model n) x) : + HasDerivAt (fun s : ℝ => normalHessian x (s • p) v v / s) + (-(radialCrossingValue x (t • p) v/t^2)) t := by + have hlin : HasDerivAt (fun s : ℝ => s/t) (1/t) t := (hasDerivAt_id t).div_const t + have hder' : HasDerivAt (fun r : ℝ => normalHessian x (r • (t • p)) v v) + (normalHessian x (t • p) v v-radialCrossingValue x (t • p) v) (t/t) := by + simpa only [div_self ht] using normalHessian_radial_derivative_value hp v + have hcomp := hder'.comp (h := fun s : ℝ => s/t) t hlin + have heq : (fun s : ℝ => normalHessian x ((s/t) • (t • p)) v v)= + (fun s : ℝ => normalHessian x (s • p) v v) := by + funext s + rw [smul_smul,div_mul_cancel₀ s ht] + simp only [Function.comp_def] at hcomp + rw [heq] at hcomp + have H := hcomp.div (hasDerivAt_id t) ht + simp only [id_eq] at H + convert H using 1 + all_goals first | rfl | (field_simp [ht]; ring) +end CrossingDerivative +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PrefixActionJets.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PrefixActionJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..a863d5587484c59756990b6f7cac184b5f6875a2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/PrefixActionJets.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.JetPullback +import OAI.Analysis.BiholderTransport.Regularity.PrefixAction + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma prefixAction_source_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) + (a : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) (a,0) (a,0) = + hessianValue x (t • p) a/t := by + have hC := (prefixAction_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + rw [←iteratedDeriv_two_affine_line hC (a,0)] + simp only [prefixAction,Prod.fst_add,Prod.snd_add,Prod.smul_fst,Prod.smul_snd, + smul_zero,zero_add,add_zero] + change iteratedDeriv 2 (fun r : ℝ => + cost (riemannianExp x (r • a)) (riemannianExp x (t • p))/t) 0 = _ + rw [iteratedDeriv_div_const] + rfl + +lemma prefixAction_endpoint_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) + (d : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (prefixAction x t) (0,p) (0,d) = t*inner ℝ p d := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hD := (prefixAction_contDiffAt hp).differentiableAt (by simp) + have hL := (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have H := (hD.hasFDerivAt.comp (f := fun v : V => ((0:V),v)) p hL).congr_of_eventuallyEq + (prefixAction_axis_near hp).symm + have he := congrArg (fun A : V →L[ℝ] ℝ => A d) + (H.unique ((half_norm_sq_hasFDerivAt p).const_smul t)) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + zero_apply,smul_apply,smul_eq_mul,innerSL_apply_apply] at he + exact he + +lemma prefixAction_endpoint_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) + (d e : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) (0,d) (0,e) = t*inner ℝ d e := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hC := (prefixAction_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have he := ((prefixAction_axis_near hp).fderiv (𝕜 := ℝ)).fderiv_eq (𝕜 := ℝ) + let L : V →L[ℝ] V×V := (0:V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V) + have H := second_fderiv_comp_affine L 0 p + (by simpa only [L,ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,zero_add] using hC) d e + simp only [L,ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,zero_add] at H + rw [←H,he] + have hg : fderiv ℝ (fun v : V => t*(‖v‖^2/2)) = + (fun v => t • innerSL ℝ v) := by + funext v + exact ((half_norm_sq_hasFDerivAt v).const_smul t).fderiv + rw [hg] + have hD : HasFDerivAt (fun v : V => t • innerSL ℝ v) (t • innerSL ℝ) p := by + convert! ((innerSL ℝ).hasFDerivAt (x := p)).const_smul t using 1 + rw [hD.fderiv] + rfl + +lemma prefixAction_hessian_diag {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t≠0) (hp : t • p ∈ injectivityDomain x) + (a d : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) (a,d) (a,d) = + hessianValue x (t • p) a/t-2*inner ℝ a d+t*‖d‖^2 := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hsplit : (a,d)=((a,0):V×V)+(0,d) := by simp + have hsym := (prefixAction_contDiffAt hp).isSymmSndFDerivAt + (by simp) + rw [hsplit] + simp only [map_add,add_apply] + rw [prefixAction_source_hessian hp,hsym.eq (a,0) (0,d), + prefixAction_mixed ht hp,prefixAction_endpoint_hessian hp] + rw [real_inner_self_eq_norm_sq,real_inner_comm d a] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/QuadraticTest.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/QuadraticTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..468482c3304c124e747399f149153a36ad754840 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/QuadraticTest.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LowerTaylor +import OAI.Analysis.BiholderTransport.Regularity.SecondFderivAdd +import OAI.Analysis.BiholderTransport.Regularity.CenteredQuadratic + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +section QuadraticTest +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma diag_bilinear_c2 (B : E →L[ℝ] E →L[ℝ] ℝ) : + ContDiff ℝ 2 (fun h : E => B h h/2) := by + convert! ((B.contDiff.clm_apply contDiff_id).const_smul (1/2:ℝ)) using 1 + ext h + simp only [smul_eq_mul,id_eq] + ring + +lemma diag_bilinear_fderiv (B : E →L[ℝ] E →L[ℝ] ℝ) : + fderiv ℝ (fun h:E => B h h/2) = fun h => (1/2:ℝ) • (B+B.flip) h := by + funext h + have H := (B.hasFDerivAt.clm_apply (hasFDerivAt_id h)).const_smul (1/2:ℝ) + have hfun : ((1/2:ℝ) • (fun y:E => B y (id y)))=(fun y:E => B y y/2) := by + ext y + simp only [Pi.smul_apply,smul_eq_mul,id_eq] + ring + rw [hfun] at H + rw [H.fderiv] + ext d + simp only [smul_apply,add_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.id_apply,id_eq] + +lemma diag_bilinear_second (B : E →L[ℝ] E →L[ℝ] ℝ) (d : E) : + fderiv ℝ (fderiv ℝ (fun h:E => B h h/2)) 0 d d=B d d := by + rw [diag_bilinear_fderiv] + change fderiv ℝ ((1/2:ℝ) • (B+B.flip)) 0 d d=B d d + rw [ContinuousLinearMap.fderiv] + simp only [smul_apply,add_apply, + ContinuousLinearMap.flip_apply,smul_eq_mul] + ring + +lemma HasLowerSecondTaylor.exists_smooth_minorant {f : E → ℝ} + {l : E →L[ℝ] ℝ} {B : E →L[ℝ] E →L[ℝ] ℝ} + (hf : HasLowerSecondTaylor f l B) {ε : ℝ} (hε : 0 < ε) : + ∃ q : E → ℝ, ContDiffAt ℝ 2 q 0 ∧ q 0=f 0 ∧ fderiv ℝ q 0=l ∧ + (∀ᶠ h in 𝓝 0,q h≤f h) ∧ + ∀ d:E,fderiv ℝ (fderiv ℝ q) 0 d d = B d d-ε*‖d‖^2 := by + let q : E → ℝ := fun h => f 0+l h+B h h/2-ε*(‖h‖^2/2) + have hB : ContDiffAt ℝ 2 (fun h:E => B h h/2) 0 := (diag_bilinear_c2 B).contDiffAt + have hn : ContDiffAt ℝ 2 (fun h:E => ‖h‖^2/2) 0 := by + simpa only [sub_zero] using (centered_half_norm_sq_c2 (0:E)).contDiffAt + have hc : ContDiffAt ℝ 2 (fun h:E => f 0+l h) 0 := contDiffAt_const.add l.contDiff.contDiffAt + refine ⟨q,(hc.add hB).sub (contDiffAt_const.mul hn),by simp [q],?_,?_,?_⟩ + · rw [show q=(fun h => (f 0+l h+B h h/2)-ε*(‖h‖^2/2)) from rfl, + fderiv_fun_sub ((hc.add hB).differentiableAt (by norm_num)) + ((contDiffAt_const.mul hn).differentiableAt (by norm_num)), + fderiv_fun_add (hc.differentiableAt (by norm_num)) (hB.differentiableAt (by norm_num)), + (l.hasFDerivAt.const_add (f 0)).fderiv,diag_bilinear_fderiv] + have Hn := ((half_norm_sq_hasFDerivAt (0:E)).const_mul ε).fderiv + rw [Hn] + simp only [map_zero,smul_zero,add_zero,sub_zero] + + · filter_upwards [hf (ε/2) (by positivity)] with h hh + dsimp only [q] + convert! hh using 1 + ring + · intro d + rw [show q=(fun h => (f 0+l h+B h h/2)-ε*(‖h‖^2/2)) from rfl, + second_fderiv_sub (hc.add hB) (contDiffAt_const.mul hn), + second_fderiv_add_eq hc hB,add_apply,add_apply,second_fderiv_const_mul,diag_bilinear_second, + half_norm_sq_second_fderiv,real_inner_self_eq_norm_sq] + have hlin : fderiv ℝ (fun h:E => f 0+l h)=fun _ => l := by + funext h + exact (l.hasFDerivAt.const_add (f 0)).fderiv + rw [hlin,(hasFDerivAt_const l (0:E)).fderiv] + simp only [zero_apply,zero_add] + +end QuadraticTest +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RadialHessian.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RadialHessian.lean new file mode 100644 index 0000000000000000000000000000000000000000..62f36dce785cd550d4b0fbc6717e162e19eeb415 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RadialHessian.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ReverseRegular +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition +import OAI.Analysis.BiholderTransport.Volume.ExponentialJacobian + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section RadialHessian +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma exp_reverseRay_line (z : TangentBundle 𝓘(ℝ,Model n) M) (s : ℝ) : + riemannianExp (reverseRay z).1 ((1-s) • (reverseRay z).2)= + riemannianExp z.1 (s • z.2) := by + rw [riemannianExp_smul,riemannianExp_smul] + change (sprayFlow (1-s) (tangentScale (-1) (sprayFlow 1 z))).1=(sprayFlow s z).1 + rw [sprayFlow_scale,←sprayFlow_add] + change (sprayFlow ((-1)*(1-s)+1) z).1=(sprayFlow s z).1 + congr 2 + ring + +lemma normal_log_fderiv_injective {x y : M} + {q : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hq : DifferentiableAt ℝ q 0) + (hqr : ∀ᶠ a in 𝓝 0, riemannianExp y (q a)=riemannianExp x a) : + Function.Injective (fderiv ℝ q 0) := by + let X := TangentSpace 𝓘(ℝ,Model n) x + let Y := TangentSpace 𝓘(ℝ,Model n) y + apply (injective_iff_map_eq_zero (fderiv ℝ q 0)).mpr + intro v hv + have he := (contMDiff_riemannianExp_fiber y (q 0)).mdifferentiableAt (by simp) + have hD := (he.hasMFDerivAt.comp 0 hq.hasFDerivAt.hasMFDerivAt) + have hqr' : (riemannianExp y ∘ q) =ᶠ[𝓝 0] riemannianExp x := hqr + have hD' := hD.congr_of_eventuallyEq hqr'.symm + have hE := hD'.mfderiv + have hV : mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) 0 v=0 := by + rw [hE] + change mfderiv 𝓘(ℝ,Y) 𝓘(ℝ,Model n) (riemannianExp (n := n) y) + (q 0) (fderiv ℝ q 0 v)=0 + rw [hv] + exact (mfderiv 𝓘(ℝ,Y) 𝓘(ℝ,Model n) (riemannianExp (n := n) y) (q 0)).map_zero + have hN : ‖mfderiv 𝓘(ℝ,X) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) 0 v‖=0 := by + rw [hV,norm_zero] + rw [mfderiv_exp_zero_norm] at hN + exact norm_eq_zero.mp hN +end RadialHessian +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RankOneCoercive.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RankOneCoercive.lean new file mode 100644 index 0000000000000000000000000000000000000000..28d4719e626720001329298e75cf14e89452ccba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RankOneCoercive.lean @@ -0,0 +1,52 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section RankOneCoercive +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma positive_bilinear_uniform_lower [FiniteDimensional ℝ E] + {B:E →L[ℝ] E →L[ℝ] ℝ} (hB:∀d,d≠0 → 0 < B d d) : + ∃c>0,∀d:E,c*‖d‖^2 ≤ B d d := by + cases subsingleton_or_nontrivial E with + | inl h => + let := h + refine ⟨1,zero_lt_one,?_⟩ + intro d + have :d=0:=Subsingleton.elim _ _ + simp [this] + | inr h => + let := h + have hs:(Metric.sphere (0:E) 1).Nonempty:=NormedSpace.sphere_nonempty.mpr (by norm_num) + have hc:Continuous (fun d:E=>B d d):=B.continuous.clm_apply continuous_id + obtain ⟨v,hv,hmin⟩:=(isCompact_sphere (0:E) 1).exists_isMinOn hs hc.continuousOn + have hvn:‖v‖=1:=by simpa only [Metric.mem_sphere,dist_zero_right] using hv + have hv0:v≠0:=by intro H; simp [H] at hvn + refine ⟨B v v,hB v hv0,?_⟩ + intro d + by_cases hd:d=0 + · simp [hd] + have hn:0 < ‖d‖:=norm_pos_iff.mpr hd + have hdmem:‖d‖⁻¹ • d∈Metric.sphere (0:E) 1:=by + simp only [Metric.mem_sphere,dist_zero_right,norm_smul,Real.norm_eq_abs, + abs_inv,abs_of_pos hn,inv_mul_cancel₀ hn.ne'] + have H:B v v ≤ B (‖d‖⁻¹ • d) (‖d‖⁻¹ • d):=hmin hdmem + simp only [map_smul,_root_.smul_apply,smul_eq_mul] at H + have H':B v v*‖d‖^2 ≤ (‖d‖⁻¹*(‖d‖⁻¹*B d d))*‖d‖^2:= + mul_le_mul_of_nonneg_right H (sq_nonneg _) + convert H' using 1; field_simp + +end RankOneCoercive +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RelativeHessianBound.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RelativeHessianBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..a3091533448bba233092209ba7cad544a325ef77 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RelativeHessianBound.lean @@ -0,0 +1,232 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactStationarity +import OAI.Analysis.BiholderTransport.Contact.LocalUniformTestPDE +import OAI.Analysis.BiholderTransport.LinearAlgebra.NormDetCoercivity + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section RelativeHessianBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def mixedCostOperator (a b : M) (z y : Model n) : Model n →L[ℝ] Model n := + bilinearOperator (-((fderiv ℝ (chartCostCovector a b) (z,y)).comp + (ContinuousLinearMap.inr ℝ (Model n) (Model n)))) + +omit [Nonempty M] in +lemma relative_hessian_operator_factor {a : M} {z : Model n} {φ : Model n → ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hp : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) : + let b := coordinateBackward a (-1,z,fderiv ℝ φ z) + bilinearOperator (fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a b)) z) = + (mixedCostOperator a b z (extChartAt 𝓘(ℝ,Model n) b b)).comp + (fderiv ℝ (chartTestContact a b φ) z) := by + dsimp only + rw [chartTestContact_relative_hessian hz hφ hp] + apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro e + simp only [ContinuousLinearMap.comp_apply,bilinearOperator_inner,mixedCostOperator, + neg_apply] + +variable [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_strict_relative_hessian_bound (hmtw : WeakMTW (n := n) (M := M)) + {lam cap : ℝ} (hlam : 00,∀ᶠ w in 𝓝 z,ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) → + (∀ d : Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a b)) z d d) → + ∀ d : Model n,fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a b)) z d d≤C*‖d‖^2 := by + dsimp only + let z := extChartAt 𝓘(ℝ,Model n) a a + let b := coordinateBackward a (-1,z,L) + let B := mixedCostOperator (n := n) a b z (extChartAt 𝓘(ℝ,Model n) b b) + obtain ⟨K,hK0,hK⟩ := hmtw.exists_strict_test_det_bound hlam hcap a L hp + let C := (finrank ℝ (Model n):ℝ)*(|B.det| *K)/m^(finrank ℝ (Model n)-1) + refine ⟨C,by dsimp [C]; positivity,?_⟩ + intro x0 uv huv φ hφ hL hval hgap hpos d + have hdet := hK x0 uv huv φ hφ hL hval hgap ⟨m,hm,hpos⟩ + let W := fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a b)) z + have hfactor : bilinearOperator W=B.comp (fderiv ℝ (chartTestContact a b φ) z) := by + have H := relative_hessian_operator_factor + ((extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a)) hφ + (show chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z) from by rwa [hL]) + simpa only [hL] using H + have hWdet : |(bilinearOperator W).det|≤|B.det| *K := by + rw [hfactor] + change |(B.toLinearMap.comp (fderiv ℝ (chartTestContact a b φ) z).toLinearMap).det|≤_ + rw [LinearMap.det_comp,abs_mul] + exact mul_le_mul_of_nonneg_left hdet (abs_nonneg _) + exact bilinear_quadratic_bound_of_det hm hpos hWdet d + +end RelativeHessianBound +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section LocalUniformRelativeHessian +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma relative_hessian_operator_factor_fixed {a b : M} {z : Model n} {φ : Model n → ℝ} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ : ContDiffAt ℝ 2 φ z) + (hp : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (hb : coordinateBackward a (-1,z,fderiv ℝ φ z)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + let c := coordinateBackward a (-1,z,fderiv ℝ φ z) + bilinearOperator (fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a c)) z) = + (mixedCostOperator a b z (extChartAt 𝓘(ℝ,Model n) b c)).comp + (fderiv ℝ (chartTestContact a b φ) z) := by + dsimp only + rw [chartTestContact_relative_hessian_fixed hz hφ hp hb] + apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro e + simp only [ContinuousLinearMap.comp_apply,bilinearOperator_inner,mixedCostOperator, + neg_apply] + +omit [CompactSpace M] [Nonempty M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma mixedCostOperator_continuousAt {a b : M} {q : Model n×Model n} + (ha : q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hb : q.2∈(extChartAt 𝓘(ℝ,Model n) b).target) + (hc : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1,(extChartAt 𝓘(ℝ,Model n) b).symm q.2)) : + ContinuousAt (fun q : Model n×Model n => mixedCostOperator a b q.1 q.2) q := by + have H := ((chartCostCovector_contDiffAt ha hb hc).fderiv_right + (m := 0) (by simp)).continuousAt + exact continuousAt_const.clm_comp ((H.clm_comp continuousAt_const).neg) + +variable [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.exists_local_strict_relative_hessian_bound + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 00,∀ᶠ w in 𝓝 z,ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) → + (∀ d : Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d) → + ∀ d : Model n,fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d≤C*‖d‖^2 := by + dsimp only + let za := extChartAt 𝓘(ℝ,Model n) a a + let b := coordinateBackward a (-1,za,L) + let yb := extChartAt 𝓘(ℝ,Model n) b b + let Y := fun q : Model n×(Model n →L[ℝ] ℝ) => coordinateBackward a (-1,q.1,q.2) + let J := fun q : Model n×(Model n →L[ℝ] ℝ) => (q.1,extChartAt 𝓘(ℝ,Model n) b (Y q)) + have ha : za∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hb : yb∈(extChartAt 𝓘(ℝ,Model n) b).target := + (extChartAt 𝓘(ℝ,Model n) b).map_source (mem_extChartAt_source b) + have hY : ContinuousAt Y (za,L) := + (coordinateBackward_contMDiffAt (q := (-1,za,L)) ha).continuousAt.comp + (x := (za,L)) (continuousAt_const.prodMk continuousAt_id) + have hJ : ContinuousAt J (za,L) := continuousAt_fst.prodMk + ((show ContinuousAt (extChartAt 𝓘(ℝ,Model n) b) (Y (za,L)) from continuousAt_extChartAt b).comp (x := (za,L)) (f := Y) hY) + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm za,chartGradientVector a za L⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z:M×M => cost z.1 z.2) + ((extChartAt 𝓘(ℝ,Model n) a).symm za,(extChartAt 𝓘(ℝ,Model n) b).symm yb) := by + rw [(extChartAt 𝓘(ℝ,Model n) b).left_inv (mem_extChartAt_source b)] + rw [show b=riemannianExp _ (chartGradientVector a za L) from coordinateBackward_eq_exp_chartGradient ha _] + exact hc + let F := fun q : Model n×(Model n →L[ℝ] ℝ) => + |(mixedCostOperator a b (J q).1 (J q).2).det| + have hF : ContinuousAt F (za,L) := + (ContinuousLinearMap.continuous_det.continuousAt.comp + ((mixedCostOperator_continuousAt ha hb hc').comp hJ)).abs + let B := F (za,L)+1 + have hB : 0≤B := by dsimp [B,F]; positivity + have hFn : ∀ᶠ q in 𝓝 (za,L),F q≤B := + (hF.eventually (gt_mem_nhds (show F (za,L) h.le) + obtain ⟨U,hU,haU,V,hV,hbV,K,hK,HK⟩ := hmtw.exists_locally_uniform_test_det_bound hlam hcap a b + let N := {q : Model n×(Model n →L[ℝ] ℝ) | q.1∈U ∧ + q.1∈(extChartAt 𝓘(ℝ,Model n) a).target ∧ Y q∈V ∧ + Y q∈(extChartAt 𝓘(ℝ,Model n) b).source ∧ + chartGradientVector a q.1 q.2∈injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.1) ∧ F q≤B} + have hN : N∈𝓝 (za,L) := by + filter_upwards [continuousAt_fst.preimage_mem_nhds (hU.mem_nhds haU), + continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_target a).mem_nhds ha), + hY.preimage_mem_nhds (hV.mem_nhds hbV), + hY.preimage_mem_nhds (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) b), + chartGradientVector_regular_near ha hp,hFn] with q h₁ h₂ h₃ h₄ h₅ h₆ + exact ⟨h₁,h₂,h₃,h₄,h₅,h₆⟩ + let C := (finrank ℝ (Model n):ℝ)*(B*K)/m^(finrank ℝ (Model n)-1) + refine ⟨N,hN,C,by dsimp [C]; positivity,?_⟩ + intro x0 uv huv z φ hz hφ hval hgap hpos d + obtain ⟨hzU,hzT,hYV,hYS,hpφ,hBφ⟩ := hz + have hdet := HK z hzU x0 uv huv φ hφ hYV hpφ hval hgap ⟨m,hm,hpos⟩ + let c := coordinateBackward a (-1,z,fderiv ℝ φ z) + let W := fderiv ℝ (fderiv ℝ φ) z+fderiv ℝ (fderiv ℝ (chartCost a c)) z + have hfactor := relative_hessian_operator_factor_fixed hzT hφ hpφ hYS + have hWdet : |(bilinearOperator W).det|≤B*K := by + rw [hfactor] + change |((mixedCostOperator a b z (extChartAt 𝓘(ℝ,Model n) b c)).toLinearMap.comp + (fderiv ℝ (chartTestContact a b φ) z).toLinearMap).det|≤_ + rw [LinearMap.det_comp,abs_mul] + exact mul_le_mul hBφ hdet (abs_nonneg _) hB + exact bilinear_quadratic_bound_of_det hm hpos hWdet d + +end LocalUniformRelativeHessian +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RescaledJoinOperator.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RescaledJoinOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..46366c90ae357877970c63f42a5506e7e216cc56 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/RescaledJoinOperator.lean @@ -0,0 +1,97 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.InverseProfile + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteRescaled (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma fixedJoinAction_regular_contDiffAt {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : T • p∈injectivityDomain x) (hh : 0 (T • p,z)) + (0,T • p) (contDiffAt_const.prodMk contDiffAt_id) + change ContDiffAt ℝ ∞ (splitNormalAction x (h/T) (T • p)) (0,T • p) at hBc + have H := hBc.comp (f := fun z : V×V => (z.1,T • z.2)) (0,p) + (contDiffAt_fst.prodMk ((contDiffAt_const (c := T)).smul contDiffAt_snd)) + have heq : fixedJoinAction x h T p=(fun z : V×V => + T⁻¹*splitNormalAction x (h/T) (T • p) (z.1,T • z.2)) := + funext (fixedJoinAction_rescale x hT.ne' p) + rw [heq] + exact contDiffAt_const.mul H + +lemma fixedJoinOperator_regular_rescale {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : T • p∈injectivityDomain x) (hh : 0 (T • p,z)) + (0,T • p) (contDiffAt_const.prodMk contDiffAt_id) + have hB := hBc.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + ext d + apply ext_inner_right ℝ + intro k + simp only [smul_apply,real_inner_smul_left,fixedJoinOperator_inner] + rw [fixedJoinMiddle_rescale hT.ne' hB] + have H := fixedJoinMiddle_rescale (x := x) (h := h/T) (p := T • p) (T := 1) + (by norm_num) (by simpa only [Function.comp_def,div_one,one_smul] using hB) d k + simpa only [div_one,one_smul,one_mul] using congrArg (fun r : ℝ => T*r) H.symm + +lemma fixedJoinOperator_regular_nonneg {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : T • p∈injectivityDomain x) (hh : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.finite_scaled_transverse_positive + (hmtw : WeakMTW (n := n) (M := M)) + {ι : Type*} [Fintype ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (w : ι → ℝ) + (hw : ∀ i, 0 ≤ w i) (hsum : ∑ i, w i = 1) + (hmin : ∀ i, p i ∈ minimizingVectors x) + {t s : ℝ} (ht : 0 ≤ t) (hts : t < s) (hs : s < 1) + (hID : ∀ q ∈ convexHull ℝ (range p), t • q ∈ injectivityDomain x) + {xi : TangentSpace 𝓘(ℝ,Model n) x} (hxi : xi ≠ 0) + (hle : ∀ i, t * inner ℝ (p i - ∑ j, w j • p j) xi ≤ 0) : + 0 < ∑ i, w i * (hessianValue x (t • ∑ j, w j • p j) xi - + (t / s) * hessianValue x (s • p i) xi) := by + rcases eq_or_lt_of_le ht with ht0 | ht0 + · subst t + simp only [zero_smul,hessianValue_zero,zero_div,zero_mul,sub_zero,←Finset.sum_mul,hsum,one_mul] + exact sq_pos_of_pos (norm_pos_iff.mpr hxi) + · let r := ∑ j, w j • p j + have hneg : ∀ i, inner ℝ (p i-r) xi ≤ 0 := by + intro i + exact nonpos_of_mul_nonpos_right (hle i) ht0 + have hmean : ∑ i, w i * inner ℝ (p i-r) xi = 0 := by + simp only [inner_sub_left,mul_sub,Finset.sum_sub_distrib,←Finset.sum_mul,hsum,one_mul] + have he : (∑ i, w i * inner ℝ (p i) xi) = inner ℝ r xi := by + simp only [r,sum_inner,real_inner_smul_left] + rw [he,sub_self] + have horth : ∀ i, 0 < w i → inner ℝ xi (p i-r) = 0 := by + intro i hi + rw [real_inner_comm] + exact finite_nonnegative_weight_zero_on_pos w (fun i => inner ℝ (p i-r) xi) hw hneg hmean i hi + have H := hmtw.finite_nonnegative_transverse_slack_strict p w hw hsum hmin ht0 hts hs hID hxi horth + have H' := (mul_lt_mul_of_pos_left H ht0) + have he : t * (hessianValue x (t • r) xi / t) = hessianValue x (t • r) xi := by + field_simp + rw [he] at H' + have heq : (∑ i, w i * (hessianValue x (t • r) xi - + (t/s)*hessianValue x (s • p i) xi)) = + hessianValue x (t • r) xi - t * ∑ i, w i * (hessianValue x (s • p i) xi / s) := by + simp only [mul_sub,Finset.sum_sub_distrib,←Finset.sum_mul,hsum,one_mul] + rw [Finset.mul_sum] + congr 1 + apply Finset.sum_congr rfl + intro i _ + ring + rw [heq] + exact sub_pos.mpr H' + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ScaledSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ScaledSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..59863cd51b589c933f3d5334fda43c6e099f6e0e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ScaledSpectrum.lean @@ -0,0 +1,122 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.RadialSingular +import OAI.Analysis.BiholderTransport.LinearAlgebra.SchurBackground + +namespace OAI + +section +section +noncomputable section +namespace WeakMTWTransport +section ScaledSpectrum +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma ordered_eigenvalues_nonneg_smul {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {c : ℝ} (hc : 0 ≤ c) {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) : + (hA.smul (show starRingEnd ℝ c=c by simp)).eigenvalues hn i= + c*hA.eigenvalues hn i := by + apply ordered_eigenvalues_of_diagonal_basis _ hn (hA.eigenvectorBasis hn) + (fun j => c*hA.eigenvalues hn j) + · intro j + simp only [LinearMap.smul_apply,hA.apply_eigenvectorBasis hn, + RCLike.ofReal_real_eq_id,id_eq,smul_smul] + · intro j k hjk + exact mul_le_mul_of_nonneg_left (hA.eigenvalues_antitone hn hjk) hc + +lemma reciprocal_spectrum_bounds {a b c C δ S L : ℝ} + (ha : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_radial_inverse_profile : + ∃ l u B : ℝ, 0 ⟨K v,hInv v⟩) + have heig := ordered_eigenvalues_inverse hA hK.isSymmetric hAi hInv rfl i + rw [heig] + have hR := H x p hp δ ⟨hd.1.le,hd.2⟩ i.rev + have hJ := J x ((1-δ) • p) hmin (1/2) (by constructor <;> norm_num) i.rev + let S := (endpointExpDifferential x p).toLinearMap.singularValues i.rev+δ + let R := (endpointExpDifferential x ((1-δ) • p)).toLinearMap.singularValues i.rev + let L := hA.isSymmetric.eigenvalues rfl i.rev + change a*S ≤ R ∧ R ≤ b*S at hR + change L ≤ C*R ∧ R ≤ c*L at hJ + have hS : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma splitJoinHessianOperator_pairing_fixed {x : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + {t : ℝ} (ht : 0 linarith [hd.1,hd.2]) v v + have htri := abs_sub (‖v‖^2) (2*normalHessian x (((1-δ)/2) • p) v v) + rw [abs_of_nonneg (sq_nonneg ‖v‖),abs_mul,abs_of_pos (by norm_num : (0:ℝ)<2)] at htri + have hB' : |‖v‖^2-2*normalHessian x (((1-δ)/2) • p) v v|≤(1+2*C)*‖v‖^2 := by + nlinarith + have HH := mul_le_mul_of_nonneg_left hB' hd.1.le + nlinarith only [HH] + +end SchurBackground +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open scoped BigOperators + +namespace WeakMTWTransport +section InverseSpectrum +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +omit [FiniteDimensional ℝ E] in +lemma diagonal_quadratic_expansion {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (b : OrthonormalBasis (Fin n) ℝ E) (μ : Fin n → ℝ) + (hμ : ∀ j, A (b j)=μ j • b j) (v : E) : + inner ℝ (A v) v=∑ j, μ j*(b.repr v j)^2 := by + have hcoord (j : Fin n) : b.repr (A v) j=μ j*b.repr v j := by + rw [b.repr_apply_apply,b.repr_apply_apply,←hA _ _,hμ,real_inner_smul_left] + have H := b.repr.inner_map_map (A v) v + rw [←H,PiLp.inner_apply] + apply Finset.sum_congr rfl + intro j hj + rw [hcoord] + simp only [RCLike.inner_apply,conj_trivial] + ring + +lemma ordered_eigenvalues_of_diagonal_basis {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (hn : Module.finrank ℝ E=n) (b : OrthonormalBasis (Fin n) ℝ E) + (μ : Fin n → ℝ) (hμ : ∀ j, A (b j)=μ j • b j) (hm : Antitone μ) (i : Fin n) : + hA.eigenvalues hn i=μ i := by + apply le_antisymm + · obtain ⟨v,hv,hav,hbv⟩ := paired_basis_slice (hA.eigenvectorBasis hn) b i + have h1 := quadratic_lower_spectral_slice hA hn i v hav + have h2 : inner ℝ (A v) v≤μ i*‖v‖^2 := by + rw [diagonal_quadratic_expansion hA b μ hμ,eigenbasis_norm_expansion b,Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hij : i≤j + · exact mul_le_mul_of_nonneg_right (hm hij) (sq_nonneg _) + · rw [hbv j (lt_of_not_ge hij)]; simp + exact (mul_le_mul_iff_left₀ (sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv))).mp (h1.trans h2) + · obtain ⟨v,hv,hbv,hav⟩ := paired_basis_slice b (hA.eigenvectorBasis hn) i + have h1 : μ i*‖v‖^2≤ inner ℝ (A v) v := by + rw [diagonal_quadratic_expansion hA b μ hμ,eigenbasis_norm_expansion b,Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hji : j ≤ i + · exact mul_le_mul_of_nonneg_right (hm hji) (sq_nonneg _) + · rw [hbv j (lt_of_not_ge hji)]; simp + have h2 := quadratic_upper_spectral_slice hA hn i v hav + exact (mul_le_mul_iff_left₀ (sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv))).mp (h1.trans h2) + +lemma positive_eigenvalues_of_injective {A : E →ₗ[ℝ] E} (hA : A.IsPositive) + (hi : Function.Injective A) {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) : + 0 (hA.isSymmetric.eigenvalues hn j.rev)⁻¹ + have hμ (j : Fin n) : K (b j)=μ j • b j := by + apply hi + rw [hAK,map_smul] + have he : A (b j)=hA.isSymmetric.eigenvalues hn j.rev • b j := by + simpa only [b,OrthonormalBasis.reindex_apply,Fin.revPerm_symm,Fin.revPerm_apply, + RCLike.ofReal_real_eq_id,id_eq] + using hA.isSymmetric.apply_eigenvectorBasis hn j.rev + rw [he,smul_smul] + dsimp only [μ] + rw [inv_mul_cancel₀ (positive_eigenvalues_of_injective hA hi hn j.rev).ne',one_smul] + apply ordered_eigenvalues_of_diagonal_basis hK hn b μ hμ _ i + intro j k hjk + exact inv_le_inv₀ (positive_eigenvalues_of_injective hA hi hn k.rev) + (positive_eigenvalues_of_injective hA hi hn j.rev) |>.mpr + (hA.isSymmetric.eigenvalues_antitone hn (Fin.rev_le_rev.mpr hjk)) + +end InverseSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurCalculus.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurCalculus.lean new file mode 100644 index 0000000000000000000000000000000000000000..58ec0ca192a2f318da160b137d904c5445ce3926 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurCalculus.lean @@ -0,0 +1,214 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ProperPieces +import OAI.Analysis.BiholderTransport.Calculus.SecondDerivativeSlice +import OAI.Analysis.BiholderTransport.Regularity.SplitSelection + +namespace OAI + +section +section +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SchurCalculus +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma stationary_graph_hessian_identity {B : E×F → ℝ} {q : E → F} {p : E} + (hB : ContDiffAt ℝ 2 B (p,q p)) (hq : DifferentiableAt ℝ q p) + (hstat : ∀ᶠ a in 𝓝 p, ∀ k, fderiv ℝ B (a,q a) (0,k)=0) + (v : E) (k : F) : + fderiv ℝ (fderiv ℝ B) (p,q p) (0,fderiv ℝ q p v) (0,k)= + -fderiv ℝ (fderiv ℝ B) (p,q p) (v,0) (0,k) := by + have hdf := (hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hG := (hasFDerivAt_id (𝕜 := ℝ) p).prodMk hq.hasFDerivAt + have hD := ((hdf.hasFDerivAt.comp (f := fun a => (a,q a)) p hG).clm_apply + (hasFDerivAt_const ((0:E),k) p)).fderiv + have heq : (fun a => fderiv ℝ B (a,q a) (0,k)) =ᶠ[𝓝 p] (fun _ => (0:ℝ)) := + hstat.mono (fun _ h => h k) + have hz : fderiv ℝ (fun a => fderiv ℝ B (a,q a) (0,k)) p=0 := by + rw [heq.fderiv_eq] + exact (hasFDerivAt_const (0:ℝ) p).fderiv + have H := congrArg (fun A : E →L[ℝ] ℝ => A v) (hD.symm.trans hz) + simp only [add_apply,comp_apply,zero_apply,map_zero,zero_add, + flip_apply,prod_apply,id_apply] at H + rw [show (v,fderiv ℝ q p v)=(v,0)+((0:E),fderiv ℝ q p v) by ext <;> simp, + map_add,add_apply] at H + linarith + +lemma stationary_graph_envelope_fderiv {B : E×F → ℝ} {q : E → F} {p : E} + (hB : DifferentiableAt ℝ B (p,q p)) (hq : DifferentiableAt ℝ q p) + (hstat : ∀ k, fderiv ℝ B (p,q p) (0,k)=0) : + HasFDerivAt (fun a => B (a,q a)) ((fderiv ℝ B (p,q p)).comp (inl ℝ E F)) p := by + apply (hB.hasFDerivAt.comp (f := fun a => (a,q a)) p + ((hasFDerivAt_id (𝕜 := ℝ) p).prodMk hq.hasFDerivAt)).congr_fderiv + ext v + simp only [comp_apply,prod_apply,id_apply,inl_apply] + rw [show (v,fderiv ℝ q p v)=(v,0)+((0:E),fderiv ℝ q p v) by ext <;> simp, + map_add,hstat,add_zero] + +lemma stationary_graph_schur_hessian {B : E×F → ℝ} {q : E → F} {p : E} + (hB : ContDiffAt ℝ 2 B (p,q p)) (hq : ContDiffAt ℝ 1 q p) + (hstat : ∀ᶠ a in 𝓝 p, ∀ k, fderiv ℝ B (a,q a) (0,k)=0) + (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => B (a,q a))) p v w= + fderiv ℝ (fderiv ℝ B) (p,q p) (v,0) (w,0)- + fderiv ℝ (fderiv ℝ B) (p,q p) (0,fderiv ℝ q p v) (0,fderiv ℝ q p w) := by + have hdq := hq.differentiableAt (by norm_num) + have hdf := (hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hG := (hasFDerivAt_id (𝕜 := ℝ) p).prodMk hdq.hasFDerivAt + have hBn := hG.continuousAt.eventually ((hB.of_le (m := 1) (by norm_num)).eventually (by norm_num)) + have hqn := hq.eventually (by norm_num) + have heq : fderiv ℝ (fun a => B (a,q a)) =ᶠ[𝓝 p] + (fun a => (fderiv ℝ B (a,q a)).comp (inl ℝ E F)) := by + filter_upwards [hBn,hqn,hstat] with a ha hb hc + exact (stationary_graph_envelope_fderiv (ha.differentiableAt (by norm_num)) + (hb.differentiableAt (by norm_num)) hc).fderiv + have hD := (hdf.hasFDerivAt.comp (f := fun a => (a,q a)) p hG).clm_comp + (hasFDerivAt_const (inl ℝ E F) p) + have H := congrArg (fun A : E →L[ℝ] E →L[ℝ] ℝ => A v w) + (heq.fderiv_eq.trans hD.fderiv) + simp only [add_apply,comp_apply,zero_apply,map_zero,zero_add, + flip_apply,prod_apply,id_apply,inl_apply,compL_apply] at H + rw [show (v,fderiv ℝ q p v)=(v,0)+((0:E),fderiv ℝ q p v) by ext <;> simp, + map_add,add_apply] at H + have HS := stationary_graph_hessian_identity hB hdq hstat w (fderiv ℝ q p v) + have hsym := (hB.isSymmSndFDerivAt (by norm_num)).eq + rw [hsym (w,0) (0,fderiv ℝ q p v), + hsym (0,fderiv ℝ q p w) (0,fderiv ℝ q p v)] at HS + linarith + +end SchurCalculus +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SchurAction +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma fixedSplitAction_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈minimizingVectors x) {t : ℝ} (ht : 0 (p,q)) (0,p) + (contDiffAt_const.prodMk contDiffAt_id) + +lemma fixedSplitAction_source_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈minimizingVectors x) {t : ℝ} (ht : 0 arg 2; ext r; rw [add_comm] + rw [iteratedDeriv_const_add (by norm_num : 0<(2:ℕ)),iteratedDeriv_div_const] at H + rw [←H,←hessianValue_eq_normalHessian (contracted_minimizer_mem_injectivityDomain hp ht ht1)] + rfl + +lemma exists_splitAction_schur_operator {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) {t : ℝ} (ht : 0 (u,a u)) (0:X) := continuousAt_id.prodMk ha.continuousAt + have hBn : ∀ᶠ u in 𝓝 (0:X), DifferentiableAt ℝ B (u,a u) := by + apply (hG.eventually (show ∀ᶠ z in 𝓝 ((0:X),a 0), ContDiffAt ℝ 2 B z from by + rw [ha0]; exact hB.eventually (by norm_num))).mono + exact fun u hu => hu.differentiableAt (by norm_num) + have hstat : ∀ᶠ u in 𝓝 (0:X), ∀ k, fderiv ℝ B (u,a u) (0,k)=0 := by + filter_upwards [he,hBn] with u hu hbu + have hmin : IsLocalMin (fun v => B (u,v)) (a u) := by + filter_upwards [] with v + change splitNormalAction x t p (u,a u)≤ splitNormalAction x t p (u,v) + rw [hu] + exact normalCost_le_splitNormalAction x p u v ht ht1 + have hD := hbu.hasFDerivAt.comp (f := fun v => (u,v)) (a u) + ((hasFDerivAt_const u (a u)).prodMk (hasFDerivAt_id (𝕜 := ℝ) (a u))) + have hz := hmin.hasFDerivAt_eq_zero hD + intro k + exact congrArg (fun L : X →L[ℝ] ℝ => L k) hz + let K := fderiv ℝ a 0 + have hBa : ContDiffAt ℝ 2 B (0,a 0) := by rwa [ha0] + have hInv (v k : X) : fderiv ℝ (fderiv ℝ B) (0,p) (0,K v) (0,k)=inner ℝ k v := by + have H := stationary_graph_hessian_identity hBa (ha.differentiableAt (by simp)) hstat v k + rw [ha0,splitNormalAction_mixed_pairing ht.ne' hleft hright] at H + simpa only [neg_neg] using H + have hKinj : Function.Injective K := by + apply (injective_iff_map_eq_zero K).mpr + intro v hv + have H := hInv v v + rw [hv,show ((0:X),(0:X))=0 from rfl,map_zero,zero_apply] at H + exact inner_self_eq_zero.mp H.symm + have hKsurj : Function.Surjective K := + (LinearMap.injective_iff_surjective (f := K.toLinearMap)).mp hKinj + have hsym := (hB.isSymmSndFDerivAt (by norm_num)).eq + have hKs (v w : X) : inner ℝ (K v) w=inner ℝ v (K w) := by + have H := hsym (0,K v) (0,K w) + rw [hInv,hInv] at H + exact H.symm.trans (real_inner_comm _ _) + have hKn (v : X) : 0≤ inner ℝ (K v) v := by + have hmin : IsLocalMin (fun k : X => B (0,k)) p := by + filter_upwards [] with k + change splitNormalAction x t p (0,p)≤ splitNormalAction x t p (0,k) + rw [splitNormalAction_contact hpG ht ht1] + exact normalCost_le_splitNormalAction x p 0 k ht ht1 + have HC := hB.comp p (contDiffAt_const.prodMk contDiffAt_id) + have H := localMin_hessian_nonneg HC hmin (K v) + change 0 ≤ fderiv ℝ (fderiv ℝ (fun k : X => B (0,k))) p (K v) (K v) at H + rw [second_derivative_target_slice hB,hInv] at H + exact H + refine ⟨K,⟨hKinj,hKsurj⟩,hKs,hKn,hInv,?_⟩ + intro v + have H := stationary_graph_schur_hessian hBa + (ha.of_le (m := 1) (by simp)) hstat v v + rw [ha0,fixedSplitAction_source_hessian hpG ht ht1,hInv] at H + have heq : (fun u => B (u,a u)) =ᶠ[𝓝 (0:X)] normalCost x p := he + have heDD := (heq.fderiv (𝕜 := ℝ)).fderiv_eq (𝕜 := ℝ) + rw [heDD] at H + exact H + +end SchurAction +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurEnvelope.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurEnvelope.lean new file mode 100644 index 0000000000000000000000000000000000000000..8da6e7033235e5055bd974269ecde93aa61d6f17 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SchurEnvelope.lean @@ -0,0 +1,178 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSmooth +import OAI.Analysis.BiholderTransport.Contact.UpperContactIteratedDeriv + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma upper_contact_block_trial {f : E → ℝ} {B : E×F → ℝ} {x : E} {q : F} + (hf : ContDiffAt ℝ 2 f x) (hB : ContDiffAt ℝ 2 B (x,q)) + (hle : ∀ᶠ z in 𝓝 (x,q), f z.1≤B z) (heq : f x=B (x,q)) + (v : E) (k : F) (t : ℝ) : + fderiv ℝ (fderiv ℝ f) x v v ≤ + fderiv ℝ (fderiv ℝ B) (x,q) (v,0) (v,0) + + 2*t*fderiv ℝ (fderiv ℝ B) (x,q) (v,0) (0,k) + + t^2*fderiv ℝ (fderiv ℝ B) (x,q) (0,k) (0,k) := by + let L : ℝ → E×F := fun s => (x,q)+s • (v,t • k) + have hLc : ContDiffAt ℝ 2 L 0 := contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const) + have hL0 : L 0=(x,q) := by simp [L] + have hLlim : Tendsto L (𝓝 0) (𝓝 (x,q)) := by + simpa only [hL0] using hLc.continuousAt.tendsto + have hBc : ContDiffAt ℝ 2 (B ∘ L) 0 := by + have hB' : ContDiffAt ℝ 2 B (L 0) := by rwa [hL0] + exact hB'.comp 0 hLc + have hfc : ContDiffAt ℝ 2 (fun s : ℝ => f (x+s • v)) 0 := by + have hf' : ContDiffAt ℝ 2 f (x+(0:ℝ) • v) := by simpa only [zero_smul,add_zero] using hf + exact hf'.comp 0 (contDiffAt_const.add (contDiffAt_id.smul contDiffAt_const)) + have hle' : ∀ᶠ s : ℝ in 𝓝 0, f (x+s • v) ≤ (B ∘ L) s := + hLlim.eventually hle + have heq' : f (x+(0:ℝ) • v)=(B ∘ L) 0 := by simpa only [Function.comp_apply,hL0,zero_smul,add_zero] using heq + have H := upper_contact_iteratedDeriv_two hfc hBc hle' heq' + change iteratedDeriv 2 (fun s : ℝ => f (x+s • v)) 0 ≤ + iteratedDeriv 2 (fun s : ℝ => B ((x,q)+s • (v,t • k))) 0 at H + rw [iteratedDeriv_two_affine_line hf,iteratedDeriv_two_affine_line hB] at H + have hv : (v,t • k)=(v,0)+t • ((0:E),k) := by ext <;> simp + have hs := (hB.isSymmSndFDerivAt (by simp)).eq ((0:E),k) (v,(0:F)) + rw [hv] at H + simp only [map_add,map_smul,add_apply,smul_apply,smul_eq_mul] at H + rw [hs] at H + nlinarith + +lemma upper_contact_block_nonneg {f : E → ℝ} {B : E×F → ℝ} {x : E} {q : F} + (hf : ContDiffAt ℝ 2 f x) (hB : ContDiffAt ℝ 2 B (x,q)) + (hle : ∀ᶠ z in 𝓝 (x,q), f z.1≤B z) (heq : f x=B (x,q)) (k : F) : + 0≤fderiv ℝ (fderiv ℝ B) (x,q) (0,k) (0,k) := by + simpa only [show ((0:E),(0:F))=(0:E×F) from rfl, map_zero, zero_apply, one_mul, + zero_add, one_pow, mul_zero] using upper_contact_block_trial hf hB hle heq 0 k 1 + +lemma upper_contact_block_positive {f : E → ℝ} {B : E×F → ℝ} {x : E} {q : F} + (hf : ContDiffAt ℝ 2 f x) (hB : ContDiffAt ℝ 2 B (x,q)) + (hle : ∀ᶠ z in 𝓝 (x,q), f z.1≤B z) (heq : f x=B (x,q)) (v : E) (k : F) + (hk : fderiv ℝ (fderiv ℝ B) (x,q) (v,0) (0,k)≠0) : + 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def radialHessianDefectBilinear (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) (δ : ℝ) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ := + (-δ) • (normalHessian x ((1-δ) • p) - + (innerSL ℝ (E := TangentSpace 𝓘(ℝ,Model n) x)).restrictScalars ℝ) + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma radialHessianDefect_apply (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) + (δ : ℝ) (u v : TangentSpace 𝓘(ℝ,Model n) x) : + radialHessianDefectBilinear x p δ u v = + -δ*(normalHessian x ((1-δ) • p) u v-inner ℝ u v) := rfl + +lemma radialHessianDefect_symm {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} {δ : ℝ} + (hp : (1-δ) • p∈injectivityDomain x) (u v : TangentSpace 𝓘(ℝ,Model n) x) : + radialHessianDefectBilinear x p δ u v=radialHessianDefectBilinear x p δ v u := by + simp only [radialHessianDefect_apply,normalHessian_symm hp u v,real_inner_comm u v] + +lemma radialHessianDefect_radial {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} {δ : ℝ} + (hδ : δ≠1) (hp : (1-δ) • p∈injectivityDomain x) + (v : TangentSpace 𝓘(ℝ,Model n) x) : radialHessianDefectBilinear x p δ p v=0 := by + rw [radialHessianDefect_apply,normalHessian_contracted_radial (sub_ne_zero.mpr hδ.symm) hp] + ring + +lemma radialHessianDefect_add_radial {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} {δ : ℝ} + (hδ : δ≠1) (hp : (1-δ) • p∈injectivityDomain x) + (z : TangentSpace 𝓘(ℝ,Model n) x) (a : ℝ) : + radialHessianDefectBilinear x p δ (z+a • p) (z+a • p)=radialHessianDefectBilinear x p δ z z := by + simp only [map_add,map_smul,add_apply,smul_apply, + smul_eq_mul,radialHessianDefect_radial hδ hp] + rw [radialHessianDefect_symm hp z p,radialHessianDefect_radial hδ hp] + ring + +def spectralShear {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (p q : E) (t : ℝ) : E →L[ℝ] E := + ContinuousLinearMap.id ℝ E + (t / inner ℝ p q) • (innerSL ℝ q).smulRight q + +lemma spectralShear_apply {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (p q z : E) (t : ℝ) : spectralShear p q t z=z+(t*(inner ℝ z q/inner ℝ p q)) • q := by + simp only [spectralShear,add_apply,ContinuousLinearMap.id_apply, + smul_apply,ContinuousLinearMap.smulRight_apply,innerSL_apply_apply, + smul_smul,real_inner_comm q z] + congr 2 + ring + +lemma spectralShear_transverse_representative {E : Type*} [NormedAddCommGroup E] + [InnerProductSpace ℝ E] (p q z : E) (t : ℝ) : + z-(inner ℝ z q/inner ℝ p q) • p= + spectralShear p q t z+(-(inner ℝ z q/inner ℝ p q)) • (p+t • q) := by + rw [spectralShear_apply,smul_add,smul_smul] + module + +lemma spectralShear_transverse {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + (p q z : E) (hpq : inner ℝ p q≠0) : + inner ℝ (z-(inner ℝ z q/inner ℝ p q) • p) q=0 := by + simp only [inner_sub_left,real_inner_smul_left,div_mul_cancel₀ _ hpq,sub_self] + +lemma radialHessianDefect_shear {x : M} {p q : TangentSpace 𝓘(ℝ,Model n) x} {δ t : ℝ} + (hδ : δ≠1) (hp : (1-δ) • (p+t • q)∈injectivityDomain x) + (z : TangentSpace 𝓘(ℝ,Model n) x) : + radialHessianDefectBilinear x (p+t • q) δ (spectralShear p q t z) (spectralShear p q t z)= + radialHessianDefectBilinear x (p+t • q) δ + (z-(inner ℝ z q/inner ℝ p q) • p) (z-(inner ℝ z q/inner ℝ p q) • p) := by + rw [spectralShear_transverse_representative p q z t] + exact (radialHessianDefect_add_radial hδ hp _ _).symm + +lemma WeakMTW.spectralShear_convexOn (hmtw : WeakMTW (n := n) (M := M)) + (x : M) (p q : TangentSpace 𝓘(ℝ,Model n) x) (hpq : inner ℝ p q≠0) + {δ : ℝ} (hδ0 : 0≤δ) (hδ1 : δ≠1) {D : Set ℝ} (hD : Convex ℝ D) + (hline : ∀ t∈D, (1-δ) • (p+t • q)∈injectivityDomain x) + (z : TangentSpace 𝓘(ℝ,Model n) x) : + ConvexOn ℝ D (fun t => radialHessianDefectBilinear x (p+t • q) δ + (spectralShear p q t z) (spectralShear p q t z)) := by + let ξ := z-(inner ℝ z q/inner ℝ p q) • p + have hξ : inner ℝ ξ ((1-δ) • q)=0 := by + rw [real_inner_smul_right,spectralShear_transverse p q z hpq,mul_zero] + have hlin : ∀ t∈D, (1-δ) • p+t • ((1-δ) • q)∈injectivityDomain x := by + intro t ht + convert hline t ht using 1 + module + have H := hmtw.transverse_concaveOn_injectivityDomain x ((1-δ) • p) ξ + ((1-δ) • q) hD hlin hξ + refine ⟨hD,?_⟩ + intro a ha b hb u v hu hv huv + have hc := hD ha hb hu hv huv + have HA := H.2 ha hb hu hv huv + simp only [smul_eq_mul] at HA + have heq (t : ℝ) (ht : t∈D) : + radialHessianDefectBilinear x (p+t • q) δ (spectralShear p q t z) (spectralShear p q t z)= + -δ*(hessianValue x ((1-δ) • p+t • ((1-δ) • q)) ξ-inner ℝ ξ ξ) := by + rw [radialHessianDefect_shear hδ1 (hline t ht),radialHessianDefect_apply] + rw [hessianValue_eq_normalHessian (hlin t ht)] + have hr : (1-δ) • (p+t • q)=(1-δ) • p+t • ((1-δ) • q) := by module + rw [hr] + dsimp only + rw [heq _ hc,heq a ha,heq b hb] + simp only [smul_eq_mul] + have hcst := congrArg (fun r : ℝ => r*(δ*inner ℝ ξ ξ)) huv + nlinarith [mul_le_mul_of_nonneg_left HA hδ0] + +end ShearConvexity +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedOperator.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedOperator.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6484b56913ccfe06ebc723304b0a32f0672869b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedOperator.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.RadialBounds +import OAI.Analysis.BiholderTransport.LinearAlgebra.ShearBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ShearedOperator +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def shearedRadialOperator (x : M) (p q : TangentSpace 𝓘(ℝ,Model n) x) (δ t : ℝ) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x := + (InnerProductSpace.toDual ℝ _).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp + ((radialHessianDefectBilinear x (p+t • q) δ).bilinearComp (spectralShear p q t) (spectralShear p q t)) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma inner_shearedRadialOperator (x : M) (p q : TangentSpace 𝓘(ℝ,Model n) x) (δ t : ℝ) + (v w : TangentSpace 𝓘(ℝ,Model n) x) : + inner ℝ (shearedRadialOperator x p q δ t v) w = + radialHessianDefectBilinear x (p+t • q) δ (spectralShear p q t v) (spectralShear p q t w) := + InnerProductSpace.toDual_symm_apply + +lemma shearedRadialOperator_symmetric {x : M} {p q : TangentSpace 𝓘(ℝ,Model n) x} + {δ t : ℝ} (hp : (1-δ) • (p+t • q)∈injectivityDomain x) : + (shearedRadialOperator x p q δ t).toLinearMap.IsSymmetric := by + intro v w + change inner ℝ (shearedRadialOperator x p q δ t v) w = + inner ℝ v (shearedRadialOperator x p q δ t w) + rw [real_inner_comm (shearedRadialOperator x p q δ t w) v,inner_shearedRadialOperator,inner_shearedRadialOperator] + exact radialHessianDefect_symm hp _ _ + +lemma uniform_sheared_radial_quadratic_bounds {a B : ℝ} (ha : 0 inner ℝ (shearedRadialOperator x p q δ t v) v) := by + simpa only [inner_shearedRadialOperator] using hmtw.spectralShear_convexOn x p q hpq hd.1.le + (show δ≠1 by linarith [hd.2]) (convex_Icc _ _) + (fun t ht => contracted_minimizer_mem_injectivityDomain (hline t ht) + (show 0<1-δ by linarith [hd.2]) (show 1-δ<1 by linarith [hd.1])) v +end ShearedOperator +end WeakMTWTransport + +end + +end + +section + +noncomputable section +namespace WeakMTWTransport +section BackgroundSpectrum +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma ordered_sheared_background_spectrum {F K : E →ₗ[ℝ] E} + (hF : F.IsSymmetric) (hK : K.IsPositive) (L : E →ₗ[ℝ] E) + (hL : Function.Bijective L) {l u δ b : ℝ} (hl : 0 by have H := (abs_le.mp (hbg v)).2; rw [←hw] at H; linarith) hn i + have hδW := hW.isSymmetric.smul (show starRingEnd ℝ δ=δ by simp) + have hlo := ordered_eigenvalue_quadratic_comparison hδW hF (a := 1) (b := b) + (by norm_num) (fun v => by + have H := (abs_le.mp (hbg v)).1 + change inner ℝ (δ • W v) v ≤ 1*inner ℝ (F v) v+b*‖v‖^2 + rw [real_inner_smul_left,hw] + linarith) hn i + rw [ordered_eigenvalues_nonneg_smul hW.isSymmetric hd hn i] at hlo + have hcl : l^2*hK.isSymmetric.eigenvalues hn i ≤ hW.isSymmetric.eigenvalues hn i := by + have H := mul_le_mul_of_nonneg_left hcong.2 (sq_nonneg l) + have he : l^2*(1/l)^2=1 := by field_simp + rw [←mul_assoc,he,one_mul] at H + exact H + constructor + · have H := mul_le_mul_of_nonneg_left hcl hd + nlinarith only [H,hlo] + · have H := mul_le_mul_of_nonneg_left hcong.1 hd + nlinarith only [H,hup] +end BackgroundSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..5840ee9231b603c05752c25e33125a9be706a956 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ShearedSpectrum.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ShearedOperator + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ShearedSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_sheared_radial_spectrum {a B : ℝ} (ha : 0 by have := (h v).1; change inner ℝ (A v) v ≤ 1*inner ℝ (B v) v+(-c)*‖v‖^2; linarith) hn i + have H2 := ordered_eigenvalue_quadratic_comparison hB hA (a := 1) (b := C) + (by norm_num) (fun v => by have := (h v).2; change inner ℝ (B v) v ≤ 1*inner ℝ (A v) v+C*‖v‖^2; linarith) hn i + constructor <;> linarith + +end SpectralContinuity +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MiddleSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def middleHessianOperator (z : TangentBundle 𝓘(ℝ,Model n) M) (h T : ℝ) : + TangentSpace 𝓘(ℝ,Model n) (sprayFlow h z).1 →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) (sprayFlow h z).1 := + (InnerProductSpace.toDual ℝ _).symm.toContinuousLinearEquiv.toContinuousLinearMap.comp + (middleHessian z h T) + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma inner_middleHessianOperator (z : TangentBundle 𝓘(ℝ,Model n) M) (h T : ℝ) + (v w : TangentSpace 𝓘(ℝ,Model n) (sprayFlow h z).1) : + inner ℝ (middleHessianOperator z h T v) w = middleHessian z h T v w := + InnerProductSpace.toDual_symm_apply + +lemma middleHessianOperator_symmetric {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2 ∈ minimizingVectors z.1) {h T : ℝ} + (hh : 0 < h) (hh1 : h < 1) (hT : h < T) (hT1 : T ≤ 1) : + (middleHessianOperator z h T).toLinearMap.IsSymmetric := by + intro v w + change inner ℝ (middleHessianOperator z h T v) w = inner ℝ v (middleHessianOperator z h T w) + rw [real_inner_comm (middleHessianOperator z h T w) v,inner_middleHessianOperator,inner_middleHessianOperator, + middleHessian_apply,middleHessian_apply, + normalHessian_symm (proper_prefix_reverse_in_injectivityDomain hz hh hh1), + normalHessian_symm (proper_suffix_in_injectivityDomain hz hh hT hT1)] + +lemma shortened_middle_operator_positive {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2 ∈ minimizingVectors z.1) {δ : ℝ} (hd : 0 ≤ δ) (hdhalf : δ ≤ 1/2) : + (middleHessianOperator z (1/4) (1-δ)).toLinearMap.IsPositive := by + refine ⟨middleHessianOperator_symmetric hz (by norm_num) (by norm_num) + (by linarith) (by linarith),?_⟩ + intro v + change 0 ≤ inner ℝ (middleHessianOperator z (1/4) (1-δ) v) v + rw [inner_middleHessianOperator] + obtain ⟨c,C,hc,hC,H⟩ := uniform_middleHessian_crossing (n := n) (M := M) + have H1 := (H z hz δ hd hdhalf v).1 + have H0 := middleHessian_one_nonneg hz (show (0:ℝ) < 1/4 by norm_num) + (show (1/4:ℝ) < 1 by norm_num) v + have Hpos := mul_nonneg (mul_nonneg hc.le hd) (sq_nonneg ‖v‖) + linarith + +lemma uniform_middle_ordered_crossing : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ ∀ z : TangentBundle 𝓘(ℝ,Model n) M, + ∀ hz : z.2 ∈ minimizingVectors z.1, ∀ δ : ℝ, ∀ hd : 0 ≤ δ, ∀ hdhalf : δ ≤ 1/2, + ∀ i : Fin (Module.finrank ℝ (TangentSpace 𝓘(ℝ,Model n) (sprayFlow (1/4) z).1)), + (shortened_middle_operator_positive hz (show (0:ℝ) ≤ 0 by norm_num) + (show (0:ℝ) ≤ 1/2 by norm_num)).isSymmetric.eigenvalues rfl i + c*δ ≤ + (shortened_middle_operator_positive hz hd hdhalf).isSymmetric.eigenvalues rfl i ∧ + (shortened_middle_operator_positive hz hd hdhalf).isSymmetric.eigenvalues rfl i ≤ + (shortened_middle_operator_positive hz (show (0:ℝ) ≤ 0 by norm_num) + (show (0:ℝ) ≤ 1/2 by norm_num)).isSymmetric.eigenvalues rfl i + C*δ := by + obtain ⟨c,C,hc,hC,H⟩ := uniform_middleHessian_crossing (n := n) (M := M) + refine ⟨c,C,hc,hC,?_⟩ + intro z hz δ hd hdhalf i + apply ordered_eigenvalues_positive_crossing + intro v + simpa only [inner_middleHessianOperator,sub_zero,mul_assoc] using H z hz δ hd hdhalf v + +end MiddleSpectrum +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitActionSchur.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitActionSchur.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f3558c7b5a0d0e7c480cb6aa4dd7e178765eed6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitActionSchur.lean @@ -0,0 +1,79 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.StrictDividedAction +import OAI.Analysis.BiholderTransport.LinearAlgebra.StationarySchur +import OAI.Analysis.BiholderTransport.Calculus.SliceDerivatives + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma splitNormalAction_schur_equality {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : p∈injectivityDomain x) (ht : 0 < t) (ht1 : t < 1) : + ∃ R : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x, + (∀ d k, fderiv ℝ (fderiv ℝ (splitNormalAction x t p)) (0,p) + (0,R d) (0,k)=inner ℝ d k) ∧ + (∀ d, hessianValue x p d=hessianValue x (t • p) d/t-inner ℝ (R d) d) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let B := splitNormalAction x t p + obtain ⟨b,hb,hb0,hcontact⟩ := exists_smooth_joining_selector hp ht ht1 + let R := fderiv ℝ b 0 + have hbd : HasFDerivAt b R 0 := (hb.differentiableAt (by simp)).hasFDerivAt + have hleft := contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors x hp) ht ht1 + have hright := shifted_injectivityDomain_of_injectivityDomain hp ht.le ht1 + have hBc : ContDiffAt ℝ ∞ B (0,p) := + (splitNormalAction_contDiffAt hleft hright).comp (f := fun z : V×V => (p,z)) + (0,p) (contDiffAt_const.prodMk contDiffAt_id) + have hB := hBc.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hf : ∀ᶠ a in 𝓝 (0:V), DifferentiableAt ℝ (normalCost x p) a := + ((normalCost_contDiffAt hp).of_le (m := 1) (by simp)).eventually (by norm_num) |>.mono + (fun _ h => h.differentiableAt (by norm_num)) + have hle : ∀ᶠ z in 𝓝 ((0:V),p), normalCost x p z.1 ≤ B z := + Eventually.of_forall (fun z => normalCost_le_splitNormalAction x p z.1 z.2 ht ht1) + have hstat : ∀ᶠ a in 𝓝 (0:V), ∀ k : V, fderiv ℝ B (a,b a) (0,k)=0 := by + have hmap := (hasFDerivAt_id (𝕜 := ℝ) (0:V)).prodMk hbd + have hBnear : ∀ᶠ a in 𝓝 (0:V), DifferentiableAt ℝ B (a,b a) := by + have HC : ContDiffAt ℝ 1 B (0,b 0) := by rw [hb0]; exact hBc.of_le (by simp) + exact (hmap.continuousAt.eventually (HC.eventually (by norm_num))).mono + (fun _ h => h.differentiableAt (by norm_num)) + filter_upwards [hBnear,hcontact] with a ha hc + intro k + have hlocal : IsLocalMin (fun v : V => B (a,v)) (b a) := by + apply Filter.Eventually.of_forall + intro v + change splitNormalAction x t p (a,b a) ≤ splitNormalAction x t p (a,v) + rw [←hc] + exact normalCost_le_splitNormalAction x p a v ht ht1 + have hd := ha.hasFDerivAt.comp (f := fun v : V => (a,v)) (b a) + ((hasFDerivAt_const a (b a)).prodMk (hasFDerivAt_id (𝕜 := ℝ) (b a))) + have H := congrArg (fun A : V →L[ℝ] ℝ => A k) (hd.fderiv.symm.trans hlocal.fderiv_eq_zero) + change fderiv ℝ B (a,b a) (0,k)=0 at H + exact H + have hmix (d k : V) : fderiv ℝ (fderiv ℝ B) (0,p) (d,0) (0,k)= -inner ℝ d k := by + rw [splitNormalAction_mixed_pairing ht.ne' hleft hright,real_inner_comm] + refine ⟨R,stationary_graph_middle_equation hB hbd hb0 hstat hmix,?_⟩ + intro d + have HH := stationary_contact_hessian hB hbd hb0 hf hle hcontact + have HE := congrArg (fun A : V →L[ℝ] V →L[ℝ] ℝ => A d d) HH.fderiv + change normalHessian x p d d = fderiv ℝ (fderiv ℝ B) (0,p) (d,R d) (d,0) at HE + have hsplit : (d,R d)=((d,0):V×V)+(0,R d) := by simp + rw [hsplit,map_add,add_apply,(hB.isSymmSndFDerivAt (by norm_num)).eq (0,R d) (d,0),hmix] at HE + rw [←splitTrialValue_eq_hessian hleft hright,splitTrialValue_source] at HE + rw [hessianValue_eq_normalHessian hp,HE,real_inner_comm d (R d)] + ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitEndpointJets.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitEndpointJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..8fe8341b3ee4683adb9bdc737958ecacc81b376f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/SplitEndpointJets.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.SplitEndpointCost +import OAI.Analysis.BiholderTransport.Calculus.JetPullback + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma splitEndpointCost_source_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (a : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (splitEndpointCost x s)) (0,p) (a,0) (a,0) = + hessianValue x (s • p) a / s := by + have hC := (splitEndpointCost_contDiffAt hleft hright).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have H := iteratedDeriv_two_affine_line hC (a,0) + rw [← H] + have he : (fun r : ℝ => splitEndpointCost x s ((0,p)+r • (a,0))) = + (fun r => cost (riemannianExp x (s • p)) (riemannianExp x p)/(1-s) + + cost (riemannianExp x (r • a)) (riemannianExp x (s • p))/s) := by + funext r + simp only [splitEndpointCost, splitNormalAction, Prod.fst_add,Prod.snd_add, + Prod.smul_fst,Prod.smul_snd,smul_zero,zero_add,add_zero] + exact add_comm _ _ + rw [he,iteratedDeriv_const_add (by norm_num : 0<2),iteratedDeriv_div_const] + rfl + +lemma splitEndpointCost_endpoint_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : 0 ((0:V),v)) + ((0 : V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V)) p := + (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := (hC.hasFDerivAt.comp (f := fun v : V => ((0:V),v)) p hL).congr_of_eventuallyEq + (splitEndpointCost_axis_near hs hs1 hleft hright).symm + have he := congrArg (fun A : V →L[ℝ] ℝ => A d) (hd.unique (half_norm_sq_hasFDerivAt p)) + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,innerSL_apply_apply] using he + +lemma splitEndpointCost_endpoint_hessian {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : 0 A d e) heq + have H := second_fderiv_comp_affine L (0:V×V) p + (by simpa only [L,ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,zero_add] using hC) d e + simp only [L,ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,zero_add] at H + rw [← H,he,half_norm_sq_second_fderiv] + +lemma splitEndpointCost_hessian_diag {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : 0.flip |>.comp + ((ContinuousLinearMap.id ℝ E).prod 0) |>.flip) x := by + let I : E →L[ℝ] E×E := (ContinuousLinearMap.id ℝ E).prod 0 + let L : E →L[ℝ] E×E := (ContinuousLinearMap.id ℝ E).prod R + let G : E → E →L[ℝ] ℝ := fun a => (fderiv ℝ B (a,b a)).comp I + have hmap := (hasFDerivAt_id (𝕜 := ℝ) x).prodMk hb + have hB' : ContDiffAt ℝ 2 B (x,b x) := by rwa [hb0] + have hG := (((hB'.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun a => (a,b a)) x hmap).clm_comp + (hasFDerivAt_const I x) + have he : fderiv ℝ f =ᶠ[𝓝 x] G := by + have hn := hmap.continuousAt.eventually (hB'.eventually (by norm_num)) + have hln : ∀ᶠ a in 𝓝 x, ∀ᶠ z in 𝓝 (a,b a), f z.1 ≤ B z := + hmap.continuousAt.eventually (eventually_eventually_nhds.mpr (by simpa [hb0] using hle)) + filter_upwards [hf,heq,hn,hln] with a hfa hea hBa hla + have ha : ContinuousAt (fun v : E => (v,b a)) a := by fun_prop + have hlocal : ∀ᶠ v in 𝓝 a, f v ≤ B (v,b a) := ha.eventually hla + have hd := (hBa.differentiableAt (by norm_num)).hasFDerivAt.comp + (f := fun v : E => (v,b a)) a + ((hasFDerivAt_id a).prodMk (hasFDerivAt_const (b a) a)) + exact (upper_contact_fderiv hfa hd.differentiableAt hlocal hea).trans hd.fderiv + apply (hG.congr_of_eventuallyEq he).congr_fderiv + ext d e + simp only [hb0,ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,ContinuousLinearMap.comp_zero, + zero_apply,zero_add,I] + +lemma stationary_graph_middle_equation {B : E×E → ℝ} + {b : E → E} {x q : E} {R : E →L[ℝ] E} + (hB : ContDiffAt ℝ 2 B (x,q)) (hb : HasFDerivAt b R x) (hb0 : b x=q) + (hstat : ∀ᶠ a in 𝓝 x, ∀ k : E, fderiv ℝ B (a,b a) (0,k)=0) + (hmix : ∀ d k:E, fderiv ℝ (fderiv ℝ B) (x,q) (d,0) (0,k)= -inner ℝ d k) + (d k:E) : fderiv ℝ (fderiv ℝ B) (x,q) (0,R d) (0,k)=inner ℝ d k := by + have hB' : ContDiffAt ℝ 2 B (x,b x) := by rwa [hb0] + have hd := (((hB'.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun a => (a,b a)) x + ((hasFDerivAt_id (𝕜 := ℝ) x).prodMk hb)).clm_apply + (hasFDerivAt_const ((0:E),k) x) + have he : (fun a => fderiv ℝ B (a,b a) (0,k)) =ᶠ[𝓝 x] (fun _ => (0:ℝ)) := + hstat.mono (fun _ h => h k) + have H := congrArg (fun A : E →L[ℝ] ℝ => A d) + ((hd.congr_of_eventuallyEq he.symm).unique (hasFDerivAt_const (0:ℝ) x)) + simp only [hb0,ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply,map_zero, + zero_apply,zero_add,add_apply] at H + have hdR : (d,R d)=((d,0):E×E)+(0,R d) := by simp + rw [hdR,map_add,add_apply,hmix] at H + linarith + +lemma diagonal_stationary_factorization {B : F×E → ℝ} {e : E → F} + {p : E} {J : E →L[ℝ] F} + (hB : ContDiffAt ℝ 2 B (e p,p)) (he : HasFDerivAt e J p) + (hstat : ∀ᶠ v in 𝓝 p, ∀ k:E, fderiv ℝ B (e v,v) (0,k)=0) + (d k:E) : + fderiv ℝ (fderiv ℝ B) (e p,p) (0,d) (0,k)= + -fderiv ℝ (fderiv ℝ B) (e p,p) (J d,0) (0,k) := by + have hd := (((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun v => (e v,v)) p + (he.prodMk (hasFDerivAt_id (𝕜 := ℝ) p))).clm_apply + (hasFDerivAt_const ((0:F),k) p) + have hzero : (fun v => fderiv ℝ B (e v,v) (0,k)) =ᶠ[𝓝 p] (fun _ => (0:ℝ)) := + hstat.mono (fun _ h => h k) + have H := congrArg (fun A : E →L[ℝ] ℝ => A d) + ((hd.congr_of_eventuallyEq hzero.symm).unique (hasFDerivAt_const (0:ℝ) p)) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply,map_zero, + zero_apply,zero_add,add_apply] at H + have hdJ : (J d,d)=((J d,0):F×E)+(0,d) := by simp + rw [hdJ,map_add,add_apply] at H + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ThreeDeterminantsClose.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ThreeDeterminantsClose.lean new file mode 100644 index 0000000000000000000000000000000000000000..e36152d99a69394e4a1edc6f570ac70a46558aff --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/ThreeDeterminantsClose.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.ReversedRadial +import OAI.Analysis.BiholderTransport.Volume.OutwardSpectrum + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma three_determinants_close {σ σi σt σti V W K c C d c₀ c₁ C₀ : ℝ} + (hσ : 0<σ) (hσi : 0<σi) (hσt : 0<σt) (hσti : 0<σti) + (hK : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance threeDeterminantsCloseFiniteDimensionalTangentSpace (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.uniform_three_determinant_closure + (hmtw : WeakMTW (n := n) (M := M)) {μ κ A c₀ c₁ C₀ : ℝ} + (hμ : 0<μ) (hκ : 0<κ) (hA : 0 hw j) hs (fun j _ => hv j) + exact three_determinants_close hσ hσi hσt hσti hK hc hC hd hc₀ hc₁ hC₀ + (HR ⟨x,p⟩ hpG l hl hr) (HRi ⟨x,v i⟩ (hv i) li hli) + (HO ι x v w p hw hs hv hp i e t D hi he ht hD hh hhD hgap hvi) hV hW hVW +end DeterminantClosure +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TransverseConcavity.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TransverseConcavity.lean new file mode 100644 index 0000000000000000000000000000000000000000..25ce6db2264e6801b2122ba30fce3ca7ceaa9e1b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TransverseConcavity.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder + +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + +def hessianValue (x : M) (p xi : TangentSpace 𝓘(ℝ, Model n) x) : ℝ := + iteratedDeriv 2 (fun t : ℝ => + cost (riemannianExp x (t • xi)) (riemannianExp x p)) 0 + +lemma mtw_affine_line (x : M) (p xi eta : TangentSpace 𝓘(ℝ, Model n) x) + (s : ℝ) : + mtw x (p + s • eta) xi eta = -(3 / 2 : ℝ) * + iteratedDeriv 2 (fun t : ℝ => hessianValue x (p + t • eta) xi) s := by + have hshift : (fun r : ℝ => hessianValue x ((p + s • eta) + r • eta) xi) = + (fun r : ℝ => hessianValue x (p + (s + r) • eta) xi) := by + ext r + rw [add_smul, add_assoc] + change -(3 / 2 : ℝ) * iteratedDeriv 2 + (fun r : ℝ => hessianValue x ((p + s • eta) + r • eta) xi) 0 = _ + rw [hshift, iteratedDeriv_comp_const_add 2 + (fun t : ℝ => hessianValue x (p + t • eta) xi) s] + simp only [add_zero] + +lemma WeakMTW.transverse_second_nonpos (hmtw : WeakMTW (n := n) (M := M)) + (x : M) (p xi eta : TangentSpace 𝓘(ℝ, Model n) x) (s : ℝ) + (hs : p + s • eta ∈ injectivityDomain x) (hortho : inner ℝ xi eta = 0) : + iteratedDeriv 2 (fun t : ℝ => hessianValue x (p + t • eta) xi) s ≤ 0 := by + have hh := hmtw x (p + s • eta) hs xi eta hortho + rw [mtw_affine_line] at hh + linarith + +lemma WeakMTW.transverse_concaveOn (hmtw : WeakMTW (n := n) (M := M)) + (x : M) (p xi eta : TangentSpace 𝓘(ℝ, Model n) x) + {D : Set ℝ} (hD : Convex ℝ D) + (hline : ∀ s ∈ interior D, p + s • eta ∈ injectivityDomain x) + (hortho : inner ℝ xi eta = 0) + (hcont : ContinuousOn (fun t : ℝ => hessianValue x (p + t • eta) xi) D) + (hsmooth : ContDiffOn ℝ 2 (fun t : ℝ => hessianValue x (p + t • eta) xi) + (interior D)) : + ConcaveOn ℝ D (fun t : ℝ => hessianValue x (p + t • eta) xi) := by + apply concaveOn_of_deriv2_nonpos hD hcont (hsmooth.differentiableOn (by norm_num)) + · exact (hsmooth.deriv_of_isOpen isOpen_interior (m := 1) (by norm_num)).differentiableOn + (by norm_num) + · intro s hs + rw [← iteratedDeriv_eq_iterate] + exact hmtw.transverse_second_nonpos x p xi eta s (hline s hs) hortho + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TrueCenterMatrix.lean b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TrueCenterMatrix.lean new file mode 100644 index 0000000000000000000000000000000000000000..2d6be8048ebe3749f696128297c1e4a35a4759ec --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LinearAlgebra/TrueCenterMatrix.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.FixedJoinSpectrum +import OAI.Analysis.BiholderTransport.Coordinates.NormalLowerTaylorBound +import OAI.Analysis.BiholderTransport.LinearAlgebra.ContactDifferential +import OAI.Analysis.BiholderTransport.Contact.LocalCEMS +import OAI.Analysis.BiholderTransport.Volume.ExponentialJacobian +import OAI.Analysis.BiholderTransport.Regularity.PullbackDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section TrueCenterMatrix +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteTrue (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance tangentCompleteTrue (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma normal_contact_matrix_symmetric {u:M → ℝ} {y:M} + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) : + ∀d e,inner ℝ ((normalHessianOperator y p+A) d) e= + inner ℝ d ((normalHessianOperator y p+A) e) := by + intro d e + simp only [add_apply,inner_add_left,inner_add_right, + inner_normalHessianOperator,hA.2.2.1] + rw [←real_inner_comm d (normalHessianOperator y p e),inner_normalHessianOperator, + normalHessian_symm hA.2.1 d e] + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma normal_endpoint_derivative_injective {x y:M} + {q:TangentSpace 𝓘(ℝ,Model n) x} (hq:q∈injectivityDomain x) + {R:TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hR:DifferentiableAt ℝ R q) (hR0:R q=0) + (hRe:∀ᶠ v in 𝓝 q,riemannianExp y (R v)=riemannianExp x v) : + Function.Injective (fderiv ℝ R q) := by + have hy:y=riemannianExp x q:=by + have H:=hRe.self_of_nhds + simpa only [hR0,riemannianExp_zero] using H + subst y + have hi:Function.Injective (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) q):=(expJacobian_ne_zero_iff x q).mp + (expJacobian_pos_of_injectivityDomain hq).ne' + intro a b hab + apply hi + simpa only [←normal_endpoint_derivative_eq hR hR0 hRe] using hab + +omit [CompactSpace M] [Nonempty M] [MeasurableSpace M] [BorelSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma normal_scalar_chain_pullback {x y:M} + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A S:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + {l dd:ℝ} (hl:0z^2) (hg d) + simp only [mul_pow,neg_sq] at hh + simpa only [mul_comm] using hh + dsimp only [V] + rw [hS] + simp only [smul_apply,ContinuousLinearMap.comp_apply, + real_inner_smul_left,ContinuousLinearMap.adjoint_inner_left, + add_apply,inner_add_left,inner_normalHessianOperator] + rw [hsquare] + ring + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma true_center_matrix {u:M → ℝ} {x y:M} + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) + (hp:∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d) + {q:TangentSpace 𝓘(ℝ,Model n) x} (hq:q∈injectivityDomain x) + (hxy:riemannianExp x q=y) {l:ℝ} (hl:0φ (cTransform u (riemannianExp y h))) s S ∧ + let B:=fderiv ℝ R q + let V:=l • B.adjoint.comp ((normalHessianOperator y p+A).comp B) + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + V.det=l^n*(expJacobian x q)^2*(normalHessianOperator y p+A).det ∧ + ∀d,inner ℝ (S (B d)) (B d)+normalHessian y (l • p) (B d) (B d)= + inner ℝ (V d) d+ + (normalHessian y (l • p) (B d) (B d)-l*normalHessian y p (B d) (B d))+ + (iteratedDeriv 2 φ (cTransform u y)/l^2)*(inner ℝ q d)^2 := by + subst y + let y:=riemannianExp x q + obtain ⟨R,hR,hR0,hRe⟩:=exists_normal_endpoint_coordinates x q + let B:=fderiv ℝ R q + have hBd:DifferentiableAt ℝ R q:=hR.differentiableAt (by simp) + have hBi:Function.Injective B:=normal_endpoint_derivative_injective hq hBd hR0 hRe + have hWs:=normal_contact_matrix_symmetric hA + have hdet:=det_positive_hessian_pullback (B:=B) (W:=normalHessianOperator y p+A) (l:=l) + ((tangent_finrank x).trans (tangent_finrank y).symm) hBi hWs hp hl + have hscalar:=quadratic_expansion_scalar_formula (φ:=φ) hA.2.2.2 hA.2.2.1 + (by simpa only [riemannianExp_zero] using hφ) + obtain ⟨s,S,hS,hSe,hSf⟩:=hscalar + refine ⟨R,s,S,hR,hR0,hRe,hS,hSe,hdet.1,?_,?_⟩ + · rw [hdet.2,tangent_finrank x] + rw [expJacobian_eq_normal_endpoint hBd hR0 hRe] + · apply normal_scalar_chain_pullback hl + · intro d + have hpr:l • p∈injectivityDomain y:=contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors y hA.2.1) hl hl1 + simpa only [real_inner_smul_left] using + reverse_normal_pairing hpr hq hyx hBd hR0 hRe d + · simpa only [riemannianExp_zero,hφd] using hSf +end TrueCenterMatrix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/CompactFlow.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/CompactFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..3989d7e54d6e784ec50c726f0ea484651e3679a4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/CompactFlow.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.MIntegralCurveUniformInvariant + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [CompleteSpace E] [HasContDiffBump E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [TopologicalSpace M] [ChartedSpace H M] [IsManifold I ∞ M] + [I.Boundaryless] + +lemma exists_uniform_time_on_compact {v : (x : M) → TangentSpace I x} + (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ (fun x => (⟨x,v x⟩ : TangentBundle I M))) + {K : Set M} (hK : IsCompact K) : + ∃ ε : ℝ, 0 < ε ∧ ∀ x ∈ K, + ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurveOn γ v (Ioo (-ε) ε) := by + classical + choose r hr U hU hflow using exists_uniform_local_manifold_curves hv + obtain ⟨t,_,ht⟩ := hK.elim_nhds_subcover U (fun x _ => hU x) + have hfin : ∀ t : Finset M, ∃ ε : ℝ, 0 < ε ∧ ∀ a ∈ t, ε ≤ r a := by + intro s + induction s using Finset.induction with + | empty => exact ⟨1,by norm_num,by simp⟩ + | @insert a s ha ih => + obtain ⟨ε,hε,hle⟩ := ih + refine ⟨min ε (r a),lt_min hε (hr a),?_⟩ + intro b hb + rcases Finset.mem_insert.mp hb with rfl | hb + · exact min_le_right _ _ + · exact (min_le_left _ _).trans (hle b hb) + obtain ⟨ε,hε,hle⟩ := hfin t + refine ⟨ε,hε,?_⟩ + intro x hx + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp (ht hx) + obtain ⟨γ,hγ0,hγ⟩ := hflow a x hxa + exact ⟨γ,hγ0,hγ.mono (Ioo_subset_Ioo (neg_le_neg (hle a ha)) (hle a ha))⟩ + +lemma exists_complete_curve_of_compact_invariant [T2Space M] + {v : (x : M) → TangentSpace I x} + (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ (fun x => (⟨x,v x⟩ : TangentBundle I M))) + {K : Set M} (hK : IsCompact K) + (hinv : ∀ (a : ℝ) (γ : ℝ → M), γ 0 ∈ K → + IsMIntegralCurveOn γ v (Ioo (-a) a) → MapsTo γ (Ioo (-a) a) K) + (x : M) (hx : x ∈ K) : ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurve γ v := by + obtain ⟨ε,hε,hflow⟩ := exists_uniform_time_on_compact hv hK + exact exists_isMIntegralCurve_of_uniform_invariant_set (hv.of_le (by simp)) + hε hflow hinv x hx + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/CotangentFlow.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/CotangentFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..695d9a300e98edfeb52a8a1485fb14d370c4d3e2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/CotangentFlow.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.ChartGradientMap + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +abbrev Phase (n:ℕ) := Model n × (Model n →L[ℝ] ℝ) + +def phaseRaise (a:M) (q:Phase n) : Model n × Model n := + (q.1,(riemannianCoordinateMetric a q.1).inverse q.2) + +def phaseLower (a:M) (q:Model n × Model n) : Phase n := + (q.1,riemannianCoordinateMetric a q.1 q.2) + +def coordinatePhaseFlow (a:M) (q:ℝ×Phase n) : Phase n := + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + phaseLower a (χ (sprayFlow (-q.1) (χ.symm (phaseRaise a q.2)))) + +omit [CompactSpace M] [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma phaseLower_contDiffAt {a:M} {q:Model n × Model n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContDiffAt ℝ ∞ (phaseLower a) q := by + have hg := (contDiffOn_riemannianCoordinateMetric (E := Model n) a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds hq) + exact contDiffAt_fst.prodMk ((hg.comp q contDiffAt_fst).clm_apply contDiffAt_snd) + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma phaseLower_raise {a:M} {q:Phase n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : phaseLower a (phaseRaise a q)=q := by + exact Prod.ext rfl ((riemannianCoordinateMetric_isInvertible hq).self_apply_inverse q.2) + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinatePhaseFlow_zero {a:M} {q:Phase n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : coordinatePhaseFlow a (0,q)=q := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have ht:phaseRaise a q∈χ.target := (tangent_chart_target_iff _ _).mpr hq + dsimp only [coordinatePhaseFlow] + rw [neg_zero,sprayFlow_zero,χ.right_inv ht] + exact phaseLower_raise hq + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinatePhaseFlow_contDiffAt {a:M} {q:Phase n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContDiffAt ℝ ∞ (coordinatePhaseFlow a) (0,q) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have ht:phaseRaise a q∈χ.target := (tangent_chart_target_iff _ _).mpr hq + have hi := (contMDiffOn_extChartAt_symm (n := ∞) (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M)).contMDiffAt + ((isOpen_extChartAt_target _).mem_nhds ht) + have hr:ContDiffAt ℝ ∞ (phaseRaise a) q := coordinateRaise_contDiffAt hq + have hinput := hi.comp (f:=fun p:ℝ×Phase n=>phaseRaise a p.2) (0,q) + (hr.comp (0,q) contDiffAt_snd).contMDiffAt + have hf := contMDiff_sprayFlow.contMDiffAt.comp (f:=fun p:ℝ×Phase n=> + (-p.1,χ.symm (phaseRaise a p.2))) (0,q) + (contDiffAt_fst.neg.contMDiffAt.prodMk hinput) + have he:sprayFlow (-(0:ℝ)) (χ.symm (phaseRaise a q))=χ.symm (phaseRaise a q) := by + rw [neg_zero,sprayFlow_zero] + have hc:ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + 𝓘(ℝ,Model n × Model n) ∞ χ (sprayFlow (-(0:ℝ)) (χ.symm (phaseRaise a q))) := by + rw [he] + exact contMDiffAt_extChartAt' (by simpa only [χ,extChartAt_source] using χ.map_target ht) + have hout := (hc.comp (f:=fun p:ℝ×Phase n=> + sprayFlow (-p.1) (χ.symm (phaseRaise a p.2))) (0,q) hf).contDiffAt + have hbase:(χ (sprayFlow (-(0:ℝ)) (χ.symm (phaseRaise a q)))).1∈ + (extChartAt 𝓘(ℝ,Model n) a).target := by + rw [he,χ.right_inv ht]; exact hq + exact (phaseLower_contDiffAt hbase).comp (0,q) hout + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinatePhaseFlow_derivative_limit {a:M} {q:Phase n} + (hq:q.1∈(extChartAt 𝓘(ℝ,Model n) a).target) : + Tendsto (fun p:ℝ×Phase n=>fderiv ℝ (fun v=>coordinatePhaseFlow a (p.1,v)) p.2) + (𝓝 (0,q)) (𝓝 (ContinuousLinearMap.id ℝ (Phase n))) := by + have hd := ContDiffAt.partial_snd_fderiv (f:=fun t v=>coordinatePhaseFlow a (t,v)) (coordinatePhaseFlow_contDiffAt hq) + have he:(fun v:Phase n=>coordinatePhaseFlow a (0,v))=ᶠ[𝓝 q] id := by + filter_upwards [continuousAt_fst.preimage_mem_nhds ((isOpen_extChartAt_target a).mem_nhds hq)] with v hv + exact coordinatePhaseFlow_zero hv + have hev:fderiv ℝ (fun v=>coordinatePhaseFlow a (0,v)) q=ContinuousLinearMap.id ℝ (Phase n) := by + rw [he.fderiv_eq,fderiv_id] + simpa only [hev] using hd.continuousAt.tendsto + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/ForwardChart.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ForwardChart.lean new file mode 100644 index 0000000000000000000000000000000000000000..ffece28cc626f8ec6fdf8932316104dd27ed0499 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ForwardChart.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section ForwardChart +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace normedSpaceTangentSpaceVectorSpace +end ForwardChart +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport + +lemma metricVolume_model (n : ℕ) : metricVolume (M := Model n) n=volume := by + let μ : Measure (Model n) := Measure.hausdorffMeasure (n:ℝ) + have hdim : Module.finrank ℝ (Model n)=n := by simp [Model] + have : μ.IsAddHaarMeasure := by + dsimp only [μ] + rw [←hdim] + infer_instance + change _ • μ=volume + exact (measure_eq_sub_vadd volume μ + (measure_ball_pos μ (0:Model n) zero_lt_one).ne' measure_ball_lt_top.ne).symm + +lemma metricVolume_lipschitz_image_le {n : ℕ} {X Y : Type*} + [MetricSpace X] [MetricSpace Y] [MeasurableSpace X] [MeasurableSpace Y] + [BorelSpace X] [BorelSpace Y] {f : X → Y} {s : Set X} {C : ℝ≥0} + (hf : LipschitzOnWith C f s) : + metricVolume n (f '' s)≤(C:ℝ≥0∞)^(n:ℝ)*metricVolume n s := by + have H := hf.hausdorffMeasure_image_le (d := (n:ℝ)) (by positivity) + change euclideanVolumeFactor n*(Measure.hausdorffMeasure (n:ℝ) (f '' s))≤ + (C:ℝ≥0∞)^(n:ℝ)*(euclideanVolumeFactor n*(Measure.hausdorffMeasure (n:ℝ) s)) + calc + _ ≤ euclideanVolumeFactor n*((C:ℝ≥0∞)^(n:ℝ)*(Measure.hausdorffMeasure (n:ℝ) s)) := mul_le_mul_right H _ + _ = _ := by ac_rfl + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/ImplicitODE.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ImplicitODE.lean new file mode 100644 index 0000000000000000000000000000000000000000..72e69c3c37c402531cdc437e47278175781863fa --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ImplicitODE.lean @@ -0,0 +1,181 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PathCalculus +import OAI.Analysis.BiholderTransport.Regularity.UnitTime +import OAI.Analysis.BiholderTransport.Calculus.ImplicitNeighborhood + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +section ImplicitODE +variable {E P : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +lemma exists_smooth_rescaled_equation_on (N : P → P) (hN : ContDiff ℝ ∞ N) + (c : E →L[ℝ] P) (A : P →L[ℝ] P) (a : E) : + ∃ U : (ℝ × E) → P, ∃ S : Set (ℝ × E), IsOpen S ∧ (0,a) ∈ S ∧ + ContDiffOn ℝ ∞ U S ∧ U (0,a) = c a ∧ + ∀ z ∈ S, U z = c z.2 + z.1 • A (N (U z)) := by + let F : (ℝ × E) × P → P := fun z => z.2 - c z.1.2 - z.1.1 • A (N z.2) + let b : P := c a + have hF : ContDiff ℝ ∞ F := + (contDiff_snd.sub (c.contDiff.comp (contDiff_snd.comp contDiff_fst))).sub + ((contDiff_fst.comp contDiff_fst).smul (A.contDiff.comp (hN.comp contDiff_snd))) + have hpart : fderiv ℝ F ((0,a),b) ∘L inr ℝ (ℝ × E) P = ContinuousLinearMap.id ℝ P := by + have hpair : HasFDerivAt (fun p : P => ((0,a),p)) (inr ℝ (ℝ × E) P) b := + (hasFDerivAt_const ((0:ℝ),a) b).prodMk (hasFDerivAt_id b) + have hc := (hF.differentiable (by simp) ((0,a),b)).hasFDerivAt.comp b hpair + have hd : HasFDerivAt (fun p : P => F ((0,a),p)) (ContinuousLinearMap.id ℝ P) b := by + simpa only [F,zero_smul,sub_zero,id_eq] using (hasFDerivAt_id b).sub_const (c a) + exact hc.unique hd + have hi : (fderiv ℝ F ((0,a),b) ∘L inr ℝ (ℝ × E) P).IsInvertible := by + rw [hpart] + exact ⟨ContinuousLinearEquiv.refl ℝ P,rfl⟩ + obtain ⟨U,S,hS,ha,hU,hb,hEq⟩ := exists_smooth_implicit_neighborhood F hF (0,a) b hi + refine ⟨U,S,hS,ha,hU,hb,?_⟩ + intro z hz + have hz' : U z - c z.2 - z.1 • A (N (U z)) = 0 := by + simpa only [F,b,zero_smul,sub_self,sub_zero] using hEq z hz + simpa only [add_comm] using eq_add_of_sub_eq (sub_eq_zero.mp hz') + +end ImplicitODE +universe u +variable {E : Type u} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +lemma exists_smooth_rescaled_ode_family_on (f : E → E) (hf : ContDiff ℝ ∞ f) (a : E) : + ∃ U : (ℝ × E) → C(UnitTime,E), ∃ S : Set (ℝ × E), IsOpen S ∧ (0,a) ∈ S ∧ + ContDiffOn ℝ ∞ U S ∧ U (0,a) = ContinuousMap.const UnitTime a ∧ + ∀ z ∈ S, U z = ContinuousMap.const UnitTime z.2 + + z.1 • unitPathIntegral ((⟨f,hf.continuous⟩ : C(E,E)).comp (U z)) := by + let fC : C(E,E) := ⟨f,hf.continuous⟩ + exact exists_smooth_rescaled_equation_on (fun p => fC.comp p) (contDiff_path_comp fC hf) + (ContinuousLinearMap.const ℝ UnitTime) unitPathIntegral a + +end + +open scoped NNReal + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +def rescaledIntegralCurve (f : C(E,E)) (t : ℝ) (x : E) (u : C(UnitTime,E)) (s : ℝ) : E := + x + t • ∫ r in (0:ℝ)..s, extendUnitPath (f.comp u) r + +omit [CompleteSpace E] in +@[simp] lemma rescaledIntegralCurve_zero (f : C(E,E)) (t : ℝ) (x : E) (u : C(UnitTime,E)) : + rescaledIntegralCurve f t x u 0 = x := by simp [rescaledIntegralCurve] + +omit [CompleteSpace E] in +lemma rescaledIntegralCurve_eq (f : C(E,E)) (t : ℝ) (x : E) (u : C(UnitTime,E)) + (hu : u = ContinuousMap.const UnitTime x + t • unitPathIntegral (f.comp u)) (s : UnitTime) : + rescaledIntegralCurve f t x u s = u s := by + have h := congrArg (fun v : C(UnitTime,E) => v s) hu + exact h.symm + +lemma hasDerivAt_rescaledIntegralCurve (f : C(E,E)) (t : ℝ) (x : E) (u : C(UnitTime,E)) + (hu : u = ContinuousMap.const UnitTime x + t • unitPathIntegral (f.comp u)) + (s : ℝ) (hs : s ∈ Icc (0:ℝ) 1) : + HasDerivAt (rescaledIntegralCurve f t x u) (t • f (rescaledIntegralCurve f t x u s)) s := by + have hd := ((hasDerivAt_unitPathPrimitive (f.comp u) s).const_smul t).const_add x + have hc := rescaledIntegralCurve_eq f t x u hu ⟨s,hs⟩ + have he : extendUnitPath (f.comp u) s = f (rescaledIntegralCurve f t x u s) := by + rw [hc] + exact extendUnitPath_coe (f.comp u) ⟨s,hs⟩ + change HasDerivAt (rescaledIntegralCurve f t x u) + (t • extendUnitPath (f.comp u) s) s at hd + rw [he] at hd + exact hd + +omit [CompleteSpace E] in +lemma lipschitzOnWith_const_smul {f : E → E} {K : ℝ≥0} {B : Set E} + (hf : LipschitzOnWith K f B) (t : ℝ) : + LipschitzOnWith (‖t‖₊ * K) (fun x => t • f x) B := by + apply LipschitzOnWith.of_dist_le_mul + intro x hx y hy + rw [dist_eq_norm,←smul_sub,norm_smul,NNReal.coe_mul,coe_nnnorm,mul_assoc] + simpa only [dist_eq_norm] using + mul_le_mul_of_nonneg_left (hf.dist_le_mul x hx y hy) (norm_nonneg t) + +lemma rescaled_ode_path_time_scaling (f : C(E,E)) (t : ℝ) (x : E) + (u v : C(UnitTime,E)) (s : UnitTime) (K : ℝ≥0) (B : Set E) + (hf : LipschitzOnWith K f B) + (hu : u = ContinuousMap.const UnitTime x + t • unitPathIntegral (f.comp u)) + (hv : v = ContinuousMap.const UnitTime x + (t * s.val) • unitPathIntegral (f.comp v)) + (huB : ∀ r, u r ∈ B) (hvB : ∀ r, v r ∈ B) : + u s = v ⟨1,by simp⟩ := by + let U := rescaledIntegralCurve f t x u + let V := rescaledIntegralCurve f (t*s.val) x v + have hsr : ∀ r ∈ Icc (0:ℝ) 1, s.val * r ∈ Icc (0:ℝ) 1 := by + intro r hr + exact ⟨mul_nonneg s.property.1 hr.1, + (mul_le_of_le_one_left hr.1 s.property.2).trans hr.2⟩ + have hU : ∀ r ∈ Icc (0:ℝ) 1, + HasDerivAt (fun q => U (s.val*q)) ((t*s.val) • f (U (s.val*r))) r := by + intro r hr + have h := (hasDerivAt_rescaledIntegralCurve f t x u hu (s.val*r) (hsr r hr)).scomp r + ((hasDerivAt_id r).const_mul s.val) + simpa only [mul_one,smul_smul,mul_comm,Function.comp_def,U] using h + have hV : ∀ r ∈ Icc (0:ℝ) 1, HasDerivAt V ((t*s.val) • f (V r)) r := + hasDerivAt_rescaledIntegralCurve f (t*s.val) x v hv + have hEq : EqOn (fun q => U (s.val*q)) V (Icc (0:ℝ) 1) := by + apply ODE_solution_unique_of_mem_Icc_right + (v := fun (_ : ℝ) z => (t*s.val) • f z) (s := fun _ => B) (K := ‖t*s.val‖₊ * K) + · intro r hr; exact lipschitzOnWith_const_smul hf (t*s.val) + · exact HasDerivAt.continuousOn hU + · intro r hr; exact (hU r (Ico_subset_Icc_self hr)).hasDerivWithinAt + · intro r hr + dsimp only [U] + rw [rescaledIntegralCurve_eq f t x u hu ⟨s.val*r,hsr r (Ico_subset_Icc_self hr)⟩] + exact huB _ + · exact HasDerivAt.continuousOn hV + · intro r hr; exact (hV r (Ico_subset_Icc_self hr)).hasDerivWithinAt + · intro r hr + dsimp only [V] + rw [rescaledIntegralCurve_eq f (t*s.val) x v hv ⟨r,Ico_subset_Icc_self hr⟩] + exact hvB _ + · simp only [U,V,mul_zero,rescaledIntegralCurve_zero] + have h := hEq (by simp : (1:ℝ) ∈ Icc (0:ℝ) 1) + change U (s.val*1) = V 1 at h + simpa only [mul_one,U,V,rescaledIntegralCurve_eq f t x u hu s, + rescaledIntegralCurve_eq f (t*s.val) x v hv ⟨1,by simp⟩] using h + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalDomainFlow.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalDomainFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..4e01359828b46b9e1a4aef7ee0bb9098db035e86 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalDomainFlow.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.SmoothFlowEndpoint +import OAI.Analysis.BiholderTransport.Calculus.SmoothExtensionNear + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [CompleteSpace E] [HasContDiffBump E] + +lemma exists_smooth_local_flow_on {f : E → E} {S : Set E} + (hS : IsOpen S) (hf : ContDiffOn ℝ ∞ f S) {a : E} (ha : a ∈ S) : + ∃ r : ℝ, 0 < r ∧ Metric.ball a r ⊆ S ∧ ∃ Φ : (ℝ × E) → E, + ContDiffOn ℝ ∞ Φ (Ioo (-r) r ×ˢ Metric.ball a r) ∧ + (∀ x ∈ Metric.ball a r, Φ (0,x) = x) ∧ + ∀ t ∈ Ioo (-r) r, ∀ x ∈ Metric.ball a r, + Φ (t,x) ∈ S ∧ HasDerivAt (fun s => Φ (s,x)) (f (Φ (t,x))) t := by + obtain ⟨g,hg,hgf⟩ := exists_smooth_extension_near hS hf ha + obtain ⟨r,hr,Φ,hΦ,hΦ0,hΦder⟩ := exists_smooth_local_flow g hg a + have hcenter : ((0:ℝ),a) ∈ Ioo (-r) r ×ˢ Metric.ball a r := + ⟨⟨neg_neg_of_pos hr,hr⟩,Metric.mem_ball_self hr⟩ + have hcont : ContinuousAt Φ (0,a) := + (hΦ.contDiffAt ((isOpen_Ioo.prod Metric.isOpen_ball).mem_nhds hcenter)).continuousAt + have hΦa : Φ (0,a) = a := hΦ0 a (Metric.mem_ball_self hr) + have hnear : ∀ᶠ z in 𝓝 ((0:ℝ),a), Φ z ∈ S ∧ g (Φ z) = f (Φ z) := by + have h := hcont.eventually (show ∀ᶠ y in 𝓝 (Φ (0,a)), y ∈ S ∧ g y = f y from by + rw [hΦa] + exact (show ∀ᶠ y in 𝓝 a, y ∈ S from hS.mem_nhds ha).and hgf) + exact h + obtain ⟨ε,hε,hεsub⟩ := Metric.mem_nhds_iff.mp hnear + let δ := min (r/2) (ε/2) + have hδ : 0 < δ := lt_min (by positivity) (by positivity) + have hδr : δ < r := (min_le_left _ _).trans_lt (by linarith) + have hδε : δ < ε := (min_le_right _ _).trans_lt (by linarith) + have hdom : Ioo (-δ) δ ×ˢ Metric.ball a δ ⊆ Ioo (-r) r ×ˢ Metric.ball a r := by + intro z hz + exact ⟨⟨by linarith [hz.1.1],hz.1.2.trans hδr⟩,lt_trans hz.2 hδr⟩ + have himg : ∀ t ∈ Ioo (-δ) δ, ∀ x ∈ Metric.ball a δ, + Φ (t,x) ∈ S ∧ g (Φ (t,x)) = f (Φ (t,x)) := by + intro t ht x hx + apply hεsub + change dist (t,x) (0,a) < ε + rw [Prod.dist_eq,max_lt_iff,Real.dist_eq,sub_zero] + exact ⟨(abs_lt.mpr ht).trans hδε,lt_trans hx hδε⟩ + refine ⟨δ,hδ,?_,Φ,hΦ.mono hdom,?_,?_⟩ + · intro x hx + have h0 : Φ (0,x) = x := hΦ0 x (lt_trans hx hδr) + exact h0 ▸ (himg 0 ⟨neg_neg_of_pos hδ,hδ⟩ x hx).1 + · intro x hx + exact hΦ0 x (lt_trans hx hδr) + · intro t ht x hx + refine ⟨(himg t ht x hx).1,?_⟩ + rw [←(himg t ht x hx).2] + have hz := hdom (show (t,x) ∈ Ioo (-δ) δ ×ˢ Metric.ball a δ from ⟨ht,hx⟩) + exact hΦder t hz.1 x hz.2 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalMetricNormal.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalMetricNormal.lean new file mode 100644 index 0000000000000000000000000000000000000000..55cb89c01248e5a6593e4c5b301faf41ed76492e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/LocalMetricNormal.lean @@ -0,0 +1,229 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CoordinateMetricNorm +import OAI.Analysis.BiholderTransport.Volume.RiemannianCalibration + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [ChartedSpace E M] [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +omit [IsRiemannianManifold 𝓘(ℝ,E) M] in +lemma coordinate_flow_path_length + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {c : M} (hSto : S ⊆ (extChartAt 𝓘(ℝ,E) c).target) + (hmetric : ∀ z ∈ S, ∀ u v : E, g z u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) v)) + {η V : ℝ → E} {r : ℝ} (hη : ContDiffOn ℝ ∞ η (Ioo (-r) r)) + (himg : MapsTo η (Ioo (-r) r) S) + (hode : ∀ t ∈ Ioo (-r) r, HasDerivAt η (V t) t ∧ + HasDerivAt V (-coordinateChristoffel g (η t) (V t) (V t)) t) + {τ : ℝ} (hτ : 0 ≤ τ) (hτr : τ < r) : + pathELength 𝓘(ℝ,E) ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) 0 τ = + ENNReal.ofReal (τ * Real.sqrt (g (η 0) (V 0) (V 0))) := by + have hr : 0 < r := hτ.trans_lt hτr + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨by linarith,hr⟩ + have hsub : Icc 0 τ ⊆ Ioo (-r) r := fun t ht => ⟨by linarith [ht.1],ht.2.trans_lt hτr⟩ + rw [inverse_coordinate_path_length ((hη.mono hsub).of_le (by simp)) + (fun t ht => hSto (himg (hsub ht))) g (fun t ht => hmetric _ (himg (hsub ht)))] + have hi : ∀ y ∈ S, (g y).IsInvertible := fun y hy => metricDual_isInvertible (g y) (hpos y hy) + have hc : ∀ t ∈ Icc 0 τ, g (η t) (deriv η t) (deriv η t) = g (η 0) (V 0) (V 0) := by + intro t ht + rw [(hode t (hsub ht)).1.deriv] + exact coordinate_geodesic_speed_constant + (fun s hs => (hg.contDiffAt (hS.mem_nhds (himg hs))).differentiableAt (by simp)) + (fun s hs => hi _ (himg hs)) (fun s hs => hsym _ (himg hs)) hode (hsub ht) h0 + calc + _ = ∫⁻ t in Icc (0:ℝ) τ, ENNReal.ofReal (Real.sqrt (g (η 0) (V 0) (V 0))) := by + apply setLIntegral_congr_fun measurableSet_Icc + intro t ht + dsimp only + rw [hc t ht] + _ = _ := by rw [setLIntegral_const,Real.volume_Icc,sub_zero,ENNReal.ofReal_mul hτ,mul_comm] + +lemma riemannian_normal_chart_dist_lower + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {c : M} + (hmetric : ∀ z ∈ S, ∀ u v : E, g z u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) v)) + {Ψ W : ℝ × E → E} {r : ℝ} + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (hW : ContDiffOn ℝ ∞ W (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (himg : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, Ψ (t,v) ∈ S) + (hode : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, + HasDerivAt (fun q => Ψ (q,v)) (W (t,v)) t ∧ + HasDerivAt (fun q => W (q,v)) + (-coordinateChristoffel g (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {x : E} (h0 : 0 ∈ Ioo (-r) r) + (hΨ0 : ∀ v ∈ Metric.ball 0 r, Ψ (0,v) = x) + (hW0 : ∀ v ∈ Metric.ball 0 r, W (0,v) = v) + {τ : ℝ} (hτ : τ ∈ Ioo (-r) r) (hτnonneg : 0 ≤ τ) + (e : OpenPartialHomeomorph E E) (hef : (e : E → E) = fun v => Ψ (τ,v)) + (hes : 0 ∈ e.source) (hesub : e.source ⊆ Metric.ball 0 r) + (hed : ContDiffOn ℝ ∞ e e.source) (hei : ContDiffOn ℝ ∞ e.symm e.target) + {a y : M} (he0 : e 0 = extChartAt 𝓘(ℝ,E) c a) + {δ : ℝ} (hball : Metric.ball a δ ⊆ + (extChartAt 𝓘(ℝ,E) c).source ∩ (extChartAt 𝓘(ℝ,E) c) ⁻¹' e.target) + (hdist : dist a y < δ) : + τ * Real.sqrt (g x (e.symm (extChartAt 𝓘(ℝ,E) c y)) + (e.symm (extChartAt 𝓘(ℝ,E) c y))) ≤ dist a y := by + apply riemannian_local_dist_lower_bound (I := 𝓘(ℝ,E)) hball hdist + intro γ hγ hγ0 hγ1 hγimg + let η : ℝ → E := (extChartAt 𝓘(ℝ,E) c) ∘ γ + have hη : ContDiffOn ℝ 1 η (Icc 0 1) := + contMDiffOn_iff_contDiffOn.mp + ((contMDiffOn_extChartAt (I := 𝓘(ℝ,E)) (n := 1) (x := c)).comp hγ (fun t ht => by + change γ t ∈ (chartAt E c).source + simpa only [extChartAt_source] using (hγimg ht).1)) + have hηimg : MapsTo η (Icc 0 1) e.target := fun t ht => (hγimg ht).2 + have hηS : ∀ t ∈ Icc 0 1, η t ∈ S := by + intro t ht + have hh := himg τ hτ (e.symm (η t)) (hesub (e.map_target (hηimg ht))) + have hval := congrFun hef (e.symm (η t)) + rw [←hval,e.right_inv (hηimg ht)] at hh + exact hh + have hb := coordinate_normal_chart_radial_bound hS hg hpos hsym hΨ hW himg hode + h0 hΨ0 hW0 hτ hτnonneg e hef hes hesub hed hei (by norm_num : (0:ℝ) ≤ 1) + hη hηimg (by simp only [η,Function.comp_apply,hγ0,he0]) + have hlen := coordinate_path_length hγ (fun t ht => (hγimg ht).1) g (by + intro t ht u v + have hh := hmetric (η t) (hηS t ht) u v + have hinner := congrArg (fun z : M => + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ z u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ z v)) + ((extChartAt 𝓘(ℝ,E) c).left_inv (hγimg ht).1) + exact hh.trans hinner) + rw [hlen] + simpa only [η,Function.comp_apply,hγ1] using hb + +lemma riemannian_coordinate_normal_chart_dist + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {c : M} (hSto : S ⊆ (extChartAt 𝓘(ℝ,E) c).target) + (hmetric : ∀ z ∈ S, ∀ u v : E, g z u v = + inner ℝ ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) u) + ((trivializationAt E (fun x : M => TangentSpace 𝓘(ℝ,E) x) c).symmL ℝ + ((extChartAt 𝓘(ℝ,E) c).symm z) v)) + {Ψ W : ℝ × E → E} {r : ℝ} + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (hW : ContDiffOn ℝ ∞ W (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (himg : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, Ψ (t,v) ∈ S) + (hode : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, + HasDerivAt (fun q => Ψ (q,v)) (W (t,v)) t ∧ + HasDerivAt (fun q => W (q,v)) + (-coordinateChristoffel g (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {a y : M} (h0 : 0 ∈ Ioo (-r) r) + (hΨ0 : ∀ v ∈ Metric.ball 0 r, Ψ (0,v) = extChartAt 𝓘(ℝ,E) c a) + (hW0 : ∀ v ∈ Metric.ball 0 r, W (0,v) = v) + {τ : ℝ} (hτ : τ ∈ Ioo (-r) r) (hτnonneg : 0 ≤ τ) + (e : OpenPartialHomeomorph E E) (hef : (e : E → E) = fun v => Ψ (τ,v)) + (he0 : e 0 = extChartAt 𝓘(ℝ,E) c a) + (hes : 0 ∈ e.source) (hesub : e.source ⊆ Metric.ball 0 r) + (hed : ContDiffOn ℝ ∞ e e.source) (hei : ContDiffOn ℝ ∞ e.symm e.target) + {δ : ℝ} (hball : Metric.ball a δ ⊆ + (extChartAt 𝓘(ℝ,E) c).source ∩ (extChartAt 𝓘(ℝ,E) c) ⁻¹' e.target) + (hdist : dist a y < δ) : + dist a y = τ * Real.sqrt (g (extChartAt 𝓘(ℝ,E) c a) + (e.symm (extChartAt 𝓘(ℝ,E) c y)) (e.symm (extChartAt 𝓘(ℝ,E) c y))) := by + apply le_antisymm _ (riemannian_normal_chart_dist_lower hS hg hpos hsym hmetric + hΨ hW himg hode h0 hΨ0 hW0 hτ hτnonneg e hef hes hesub hed hei he0 hball hdist) + have hδ : 0 < δ := dist_nonneg.trans_lt hdist + have ha := hball (Metric.mem_ball_self hδ) + have hy := hball (show y ∈ Metric.ball a δ by simpa only [Metric.mem_ball,dist_comm] using hdist) + let v := e.symm (extChartAt 𝓘(ℝ,E) c y) + have hv : v ∈ Metric.ball 0 r := hesub (e.map_target hy.2) + let η : ℝ → E := fun t => Ψ (t,v) + have hη : ContDiffOn ℝ ∞ η (Ioo (-r) r) := + hΨ.comp (contDiffOn_id.prodMk contDiffOn_const) (fun t ht => ⟨ht,hv⟩) + have hsub : Icc 0 τ ⊆ Ioo (-r) r := fun t ht => ⟨h0.1.trans_le ht.1,ht.2.trans_lt hτ.2⟩ + have hγ : ContMDiffOn 𝓘(ℝ,ℝ) 𝓘(ℝ,E) 1 + ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) (Icc 0 τ) := + (contMDiffOn_extChartAt_symm (n := 1) c).comp + (contMDiffOn_iff_contDiffOn.mpr ((hη.mono hsub).of_le (by simp))) + (fun t ht => hSto (himg t (hsub ht) v hv)) + have hγ0 : ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) 0 = a := by + simp only [Function.comp_apply,η,hΨ0 v hv,(extChartAt 𝓘(ℝ,E) c).left_inv ha.1] + have hγτ : ((extChartAt 𝓘(ℝ,E) c).symm ∘ η) τ = y := by + have heq := congrFun hef v + simp only [Function.comp_apply,η,←heq,v,e.right_inv hy.2, + (extChartAt 𝓘(ℝ,E) c).left_inv hy.1] + have hh := riemannianEDist_le_pathELength (I := 𝓘(ℝ,E)) hγ hγ0 hγτ hτnonneg + rw [←IsRiemannianManifold.out,edist_dist] at hh + have hlen := coordinate_flow_path_length hS hg hpos hsym hSto hmetric hη + (fun t ht => himg t ht v hv) (fun t ht => hode t ht v hv) hτnonneg hτ.2 + rw [hlen] at hh + have hc : 0 ≤ τ * Real.sqrt (g (extChartAt 𝓘(ℝ,E) c a) v v) := mul_nonneg hτnonneg (Real.sqrt_nonneg _) + have hh' : ENNReal.ofReal (dist a y) ≤ + ENNReal.ofReal (τ * Real.sqrt (g (extChartAt 𝓘(ℝ,E) c a) v v)) := by + simpa only [η,hΨ0 v hv,hW0 v hv] using hh + exact (ENNReal.ofReal_le_ofReal_iff hc).mp hh' + +variable [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E + (fun x : M => TangentSpace 𝓘(ℝ,E) x)] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/MIntegralCurveUniformInvariant.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/MIntegralCurveUniformInvariant.lean new file mode 100644 index 0000000000000000000000000000000000000000..2879f5d3cd8164cfb457c33bd47f2a65ea5b8283 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/MIntegralCurveUniformInvariant.lean @@ -0,0 +1,214 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.LocalDomainFlow + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set + +section +variable + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [TopologicalSpace M] [ChartedSpace H M] [IsManifold I 1 M] + [T2Space M] + +lemma exists_isMIntegralCurve_of_uniform_invariant_set [BoundarylessManifold I M] + {v : (x : M) → TangentSpace I x} + (hv : CMDiff 1 (fun x ↦ (⟨x, v x⟩ : TangentBundle I M))) + {ε : ℝ} (hε : 0 < ε) {K : Set M} + (h : ∀ x ∈ K, ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurveOn γ v (Ioo (-ε) ε)) + (hinv : ∀ (a : ℝ) (γ : ℝ → M), γ 0 ∈ K → + IsMIntegralCurveOn γ v (Ioo (-a) a) → MapsTo γ (Ioo (-a) a) K) + (x : M) (hx : x ∈ K) : ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurve γ v := by + let s := { a | ∃ γ, γ 0 = x ∧ IsMIntegralCurveOn γ v (Ioo (-a) a) } + suffices hbdd : ¬BddAbove s by + rw [not_bddAbove_iff] at hbdd + rw [exists_isMIntegralCurve_iff_exists_isMIntegralCurveOn_Ioo hv] + intro a + obtain ⟨y, ⟨γ, hγ1, hγ2⟩, hlt⟩ := hbdd a + exact ⟨γ, hγ1, hγ2.mono <| Ioo_subset_Ioo (neg_le_neg hlt.le) hlt.le⟩ + intro hbdd + set asup := sSup s with hasup + + obtain ⟨a, ha, hlt⟩ := Real.add_neg_lt_sSup (⟨ε, h x hx⟩ : Set.Nonempty s) (ε := - (ε / 2)) + (by rw [neg_lt, neg_zero]; exact half_pos hε) + rw [mem_ofPred] at ha + rw [← hasup, ← sub_eq_add_neg] at hlt + + obtain ⟨γ, h0, hγ⟩ := ha + have hεle : ε ≤ asup := le_csSup hbdd (h x hx) + + obtain ⟨γ1_aux, h1_aux, hγ1⟩ := h (γ (-(asup - ε / 2))) + (hinv a γ (h0 ▸ hx) hγ ⟨by linarith, by linarith⟩) + rw [← isMIntegralCurveOn_comp_add (dt := asup - ε / 2)] at hγ1 + set γ1 := γ1_aux ∘ (· + (asup - ε / 2)) with γ1_def + have heq1 : γ1 (-(asup - ε / 2)) = γ (-(asup - ε / 2)) := by simp [γ1_def, h1_aux] + + obtain ⟨γ2_aux, h2_aux, hγ2⟩ := h (γ (asup - ε / 2)) + (hinv a γ (h0 ▸ hx) hγ ⟨by linarith, hlt⟩) + rw [← isMIntegralCurveOn_comp_sub (dt := asup - ε / 2)] at hγ2 + set γ2 := γ2_aux ∘ (· - (asup - ε / 2)) with γ2_def + have heq2 : γ2 (asup - ε / 2) = γ (asup - ε / 2) := by simp [γ2_def, h2_aux] + + simp_rw [Set.mem_Ioo, ← sub_lt_iff_lt_add, ← lt_sub_iff_add_lt, ← Set.mem_Ioo] at hγ1 + simp_rw [Set.mem_Ioo, lt_sub_iff_add_lt, sub_lt_iff_lt_add, ← Set.mem_Ioo] at hγ2 + + set γ_ext : ℝ → M := piecewise (Ioo (-(asup + ε / 2)) a) + (piecewise (Ioo (-a) a) γ γ1) γ2 with γ_ext_def + have heq_ext : γ_ext 0 = x := by + rw [γ_ext_def, piecewise, ite_eq_left ⟨by linarith, by linarith⟩, piecewise, + ite_eq_left ⟨by linarith, by linarith⟩, h0] + + suffices hext : IsMIntegralCurveOn γ_ext v (Ioo (-(asup + ε / 2)) (asup + ε / 2)) from + (not_lt.mpr <| le_csSup hbdd ⟨γ_ext, heq_ext, hext⟩) <| lt_add_of_pos_right asup (half_pos hε) + apply (isMIntegralCurveOn_piecewise (t₀ := asup - ε / 2) hv _ hγ2 + ⟨⟨by linarith, hlt⟩, ⟨by linarith, by linarith⟩⟩ + (by rw [piecewise, ite_eq_left ⟨by linarith, hlt⟩, ← heq2])).mono + (Ioo_subset_Ioo_union_Ioo le_rfl (by linarith) (by linarith)) + exact (isMIntegralCurveOn_piecewise (t₀ := -(asup - ε / 2)) hv hγ hγ1 + ⟨⟨neg_lt_neg hlt, by linarith⟩, ⟨by linarith, by linarith⟩⟩ heq1.symm).mono + (union_comm _ _ ▸ Ioo_subset_Ioo_union_Ioo (by linarith) (by linarith) le_rfl) + +end +open Manifold Bundle +open scoped Manifold Bundle + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [TopologicalSpace M] [ChartedSpace H M] [IsManifold I ∞ M] + [I.Boundaryless] + +lemma hasMFDerivAt_of_chart_ode {v : (x : M) → TangentSpace I x} + (a : M) {f : ℝ → E} {t : ℝ} + (ht : f t ∈ (extChartAt I a).target) + (hf : HasDerivAt f + (tangentCoordChange I ((extChartAt I a).symm (f t)) a + ((extChartAt I a).symm (f t)) (v ((extChartAt I a).symm (f t)))) t) : + HasMFDerivAt 𝓘(ℝ,ℝ) I ((extChartAt I a).symm ∘ f) t + ((1 : ℝ →L[ℝ] ℝ).smulRight (v ((extChartAt I a).symm (f t)))) := by + let xₜ := (extChartAt I a).symm (f t) + have hft1 := (extChartAt I a).map_target ht + have hft2 := mem_extChartAt_source (I := I) xₜ + let w : E := v xₜ + change HasDerivAt f (tangentCoordChange I xₜ a xₜ w) t at hf + have hder : HasDerivAt ((extChartAt I xₜ ∘ (extChartAt I a).symm) ∘ f) + w t := by + have he : tangentCoordChange I a xₜ xₜ (tangentCoordChange I xₜ a xₜ w) = w := by + rw [tangentCoordChange_comp ⟨⟨hft2,hft1⟩,hft2⟩,tangentCoordChange_self hft2] + rw [← he] + apply HasFDerivAt.comp_hasDerivAt _ _ hf + apply HasFDerivWithinAt.hasFDerivAt (s := range I) _ + (by simp only [ModelWithCorners.range_eq_univ,univ_mem]) + rw [← (extChartAt I a).right_inv ht] + exact hasFDerivWithinAt_tangentCoordChange ⟨hft1,hft2⟩ + refine ⟨(continuousAt_extChartAt_symm'' ht).comp hf.continuousAt,?_⟩ + rw [writtenInExtChartAt,extChartAt_model_space_eq_id,ModelWithCorners.range_eq_univ] + change HasFDerivWithinAt ((extChartAt I xₜ ∘ (extChartAt I a).symm) ∘ f) + ((1 : ℝ →L[ℝ] ℝ).smulRight w) univ t + rw [hasFDerivWithinAt_univ] + convert! hder.hasFDerivAt using 1 + +omit [I.Boundaryless] in +lemma contDiffOn_coordinate_vectorField {v : (x : M) → TangentSpace I x} + (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ + (fun x => (⟨x,v x⟩ : TangentBundle I M))) (a : M) : + ContDiffOn ℝ ∞ (fun y => tangentCoordChange I ((extChartAt I a).symm y) a + ((extChartAt I a).symm y) (v ((extChartAt I a).symm y))) (extChartAt I a).target := by + let e := trivializationAt E (fun x : M => TangentSpace I x) a + have hc : ContMDiffOn I 𝓘(ℝ,E) ∞ (fun x => (e ⟨x,v x⟩).2) e.baseSet := by + intro x hx + exact ((e.contMDiffAt_section_iff hx).mp (hv x)).contMDiffWithinAt + have hmaps : MapsTo (extChartAt I a).symm (extChartAt I a).target e.baseSet := by + intro y hy + change (extChartAt I a).symm y ∈ (chartAt H a).source + simpa only [extChartAt_source] using (extChartAt I a).map_target hy + exact contMDiffOn_iff_contDiffOn.mp (hc.comp (contMDiffOn_extChartAt_symm a) hmaps) + +lemma exists_uniform_local_manifold_curves [CompleteSpace E] [HasContDiffBump E] + {v : (x : M) → TangentSpace I x} + (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ + (fun x => (⟨x,v x⟩ : TangentBundle I M))) (a : M) : + ∃ ε : ℝ, 0 < ε ∧ ∃ U : Set M, U ∈ 𝓝 a ∧ + ∀ x ∈ U, ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurveOn γ v (Ioo (-ε) ε) := by + let c := extChartAt I a + obtain ⟨r,hr,_,Φ,_,hΦ0,hΦder⟩ := exists_smooth_local_flow_on + (isOpen_extChartAt_target a) (contDiffOn_coordinate_vectorField hv a) + (c.map_source (mem_extChartAt_source a)) + let U := c.source ∩ c ⁻¹' Metric.ball (c a) r + have hUa : U ∈ 𝓝 a := inter_mem (extChartAt_source_mem_nhds a) + ((continuousAt_extChartAt (I := I) (x := a)).preimage_mem_nhds (Metric.ball_mem_nhds _ hr)) + refine ⟨r,hr,U,hUa,?_⟩ + intro x hx + refine ⟨c.symm ∘ (fun t => Φ (t,c x)),?_,?_⟩ + · simp only [Function.comp_apply,hΦ0 _ hx.2,c.left_inv hx.1] + · intro t ht + exact (hasMFDerivAt_of_chart_ode a (hΦder t ht (c x) hx.2).1 + (hΦder t ht (c x) hx.2).2).hasMFDerivWithinAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/ModelTangentJet.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ModelTangentJet.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf6e1c69eab1a90522025ae5a04b2e2aa249d358 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/ModelTangentJet.lean @@ -0,0 +1,154 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CoordinateScalarSupport +import OAI.Analysis.BiholderTransport.Regularity.CenterFullPullback + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ModelTangentJet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma center_frame_identity (a : M) (d : Model n) : + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ a d=d := by + rw [TangentBundle.symmL_trivializationAt_eq_core (mem_chart_source (Model n) a)] + exact tangentCoordChange_self (I := 𝓘(ℝ,Model n)) (mem_extChartAt_source a) + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma model_tangent_second_fderiv {a : M} {f : TangentSpace 𝓘(ℝ,Model n) a → ℝ} + {q : Model n} (hf : ContDiffAt ℝ 2 f q) (d e : Model n) : + fderiv ℝ (fderiv ℝ (fun r : Model n=>f r)) q d e= + fderiv ℝ (fderiv ℝ f) q d e := by + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ a + have hA (r : Model n) : A r=r := center_frame_identity a r + have hz (r : Model n) : (0 : TangentSpace 𝓘(ℝ,Model n) a)+A r=r := + (zero_add (A r)).trans (hA r) + have H := second_fderiv_comp_affine (E := Model n) (F := TangentSpace 𝓘(ℝ,Model n) a) (f := f) A 0 q + (by simpa only [hz] using hf) d e + have he : (fun h : Model n => f ((0 : TangentSpace 𝓘(ℝ,Model n) a)+A h))= + (fun h : Model n => f h) := by funext h; rw [hz h] + rw [he,hz q,hA d,hA e] at H + exact H + +omit [Nonempty M] in +lemma scalarCostSupport_endpoint_contDiffAt {a c : M} + {q : TangentSpace 𝓘(ℝ,Model n) a} {r : TangentSpace 𝓘(ℝ,Model n) c} + {v s : ℝ} {φ : ℝ → ℝ} (hr : s • r∈injectivityDomain c) + (he : riemannianExp a q=c) (hφ : ContDiffAt ℝ 2 φ v) : + ContDiffAt ℝ 2 (fun w=>scalarCostSupport φ v c r s (riemannianExp a w)) q := by + have hC := cost_contMDiffAt_of_injectivityDomain + (⟨c,s • r⟩ : TangentBundle 𝓘(ℝ,Model n) M) hr + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z:M×M=>cost z.1 z.2) (riemannianExp a q,riemannianExp c (s • r)) := by + rwa [he] + have hpair : ContMDiffAt 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) a) + (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ + (fun w : TangentSpace 𝓘(ℝ,Model n) a => (riemannianExp a w,riemannianExp c (s • r))) q := + (contMDiff_riemannianExp_fiber a q).prodMk contMDiffAt_const + have hcost : ContDiffAt ℝ ∞ (fun w : TangentSpace 𝓘(ℝ,Model n) a => + cost (riemannianExp a w) (riemannianExp c (s • r))) q := + (hC'.comp (g := fun z:M×M=>cost z.1 z.2) q hpair).contDiffAt + have hf : ContDiffAt ℝ ∞ (fun w=>v+cost c (riemannianExp c (s • r))/s- + cost (riemannianExp a w) (riemannianExp c (s • r))/s) q := + contDiffAt_const.sub (hcost.div_const s) + have hval : v+cost c (riemannianExp c (s • r))/s-cost (riemannianExp a q) (riemannianExp c (s • r))/s=v := by + rw [he,add_sub_cancel_right] + exact (hval.symm ▸ hφ).comp q (hf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)) + +omit [Nonempty M] in +lemma model_riemannianExp_continuous (a : M) : + Continuous (fun w : Model n=>riemannianExp a w) := by + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ a + have H := (continuous_riemannianExp a).comp A.continuous + have he : riemannianExp a ∘ A=(fun w : Model n=>riemannianExp a w) := by + funext w + exact congrArg (riemannianExp a) (center_frame_identity a w) + rwa [he] at H + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma coordinateScalarSupport_center_value (c : M) (v s : ℝ) (φ : ℝ → ℝ) + (r z : Model n) : + coordinateScalarSupport c φ (((v,s),(extChartAt 𝓘(ℝ,Model n) c c,r)),z)= + scalarCostSupport φ v c r s ((extChartAt 𝓘(ℝ,Model n) c).symm z) := by + have hx := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hb := (extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c) + rw [coordinateScalarSupport_eq hx,hb,center_frame_identity] + +omit [Nonempty M] in +lemma coordinate_support_endpoint_germ {a c : M} {q r : Model n} + (v s : ℝ) (φ : ℝ → ℝ) (he : riemannianExp a q=c) : + (fun w : Model n=>coordinateScalarSupport c φ + (((v,s),(extChartAt 𝓘(ℝ,Model n) c c,r)),extChartAt 𝓘(ℝ,Model n) c (riemannianExp a w)))=ᶠ[𝓝 q] + (fun w : Model n=>scalarCostSupport φ v c r s (riemannianExp a w)) := by + have hx := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hb := (extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c) + have hExp := (model_riemannianExp_continuous a).continuousAt (x := q) + have hqc : riemannianExp a q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + rw [he] + exact mem_extChartAt_source c + have hsource := hExp.eventually ((isOpen_extChartAt_source c).mem_nhds hqc) + filter_upwards [hsource] with w hw + rw [coordinateScalarSupport_center_value,(extChartAt 𝓘(ℝ,Model n) c).left_inv hw] + +omit [Nonempty M] in +lemma coordinate_support_endpoint_hessian {a c : M} {q r : Model n} + {v s : ℝ} {φ : ℝ → ℝ} + (hr : s • (show TangentSpace 𝓘(ℝ,Model n) c from r)∈injectivityDomain c) + (he : riemannianExp a q=c) (hφ : ContDiffAt ℝ 2 φ v) (d e : Model n) : + fderiv ℝ (fderiv ℝ (fun w : Model n=>coordinateScalarSupport c φ + (((v,s),(extChartAt 𝓘(ℝ,Model n) c c,r)),extChartAt 𝓘(ℝ,Model n) c (riemannianExp a w)))) q d e= + fderiv ℝ (fderiv ℝ (fun w : TangentSpace 𝓘(ℝ,Model n) a=> + scalarCostSupport φ v c r s (riemannianExp a w))) q d e := by + rw [(coordinate_support_endpoint_germ v s φ he).fderiv.fderiv_eq] + exact model_tangent_second_fderiv (scalarCostSupport_endpoint_contDiffAt hr he hφ) d e + +omit [Nonempty M] in +lemma exists_uniform_coordinate_center_full_pullback : + ∃ c0>0,∀ᶠ l : ℝ in 𝓝 1, 0coordinateScalarSupport c φ + (((v,(1+l)/2),(extChartAt 𝓘(ℝ,Model n) c c,r)), + extChartAt 𝓘(ℝ,Model n) c (riemannianExp a w)))) q d d := by + obtain ⟨c0,hc0,H⟩ := exists_uniform_center_full_pullback (n := n) (M := M) + refine ⟨c0,hc0,?_⟩ + filter_upwards [H] with l hl + intro hl0 hl1 a c r q hr hq hac hca φ v hφ hd d + rw [coordinate_support_endpoint_hessian + (contracted_minimizer_mem_injectivityDomain hr (by linarith) (by linarith)) hca hφ, + real_inner_self_eq_norm_sq] + exact hl hl0 hl1 c a r q hr hq hac hca φ v hφ hd d + +end ModelTangentJet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/NormalFlow.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/NormalFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..543e932684473fc2472b807286be24734c6938fd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/NormalFlow.lean @@ -0,0 +1,158 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.JointNormalChart +import OAI.Analysis.BiholderTransport.Geodesics.EndpointIdentity + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace E M] + [IsManifold 𝓘(ℝ,E) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_metric_normal_flow (a : M) : + ∃ δ r τ : ℝ, 0 < δ ∧ 0 < r ∧ 0 < τ ∧ τ < r ∧ + ∃ Ψ W : ℝ × E → E, ∃ e : OpenPartialHomeomorph E E, + ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r) ∧ + ContDiffOn ℝ ∞ W (Ioo (-r) r ×ˢ Metric.ball 0 r) ∧ + (∀ v ∈ Metric.ball (0:E) r, Ψ (0,v) = extChartAt 𝓘(ℝ,E) a a ∧ W (0,v) = v) ∧ + (∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball (0:E) r, + Ψ (t,v) ∈ (extChartAt 𝓘(ℝ,E) a).target ∧ + HasDerivAt (fun s => Ψ (s,v)) (W (t,v)) t ∧ + HasDerivAt (fun s => W (s,v)) + (-coordinateChristoffel (riemannianCoordinateMetric a) (Ψ (t,v)) (W (t,v)) (W (t,v))) t) ∧ + (e : E → E) = (fun v => Ψ (τ,v)) ∧ + 0 ∈ e.source ∧ e 0 = extChartAt 𝓘(ℝ,E) a a ∧ e.source ⊆ Metric.ball (0:E) r ∧ + ContDiffOn ℝ ∞ e e.source ∧ ContDiffOn ℝ ∞ e.symm e.target ∧ + (Metric.ball a δ ⊆ (extChartAt 𝓘(ℝ,E) a).source ∩ + (extChartAt 𝓘(ℝ,E) a) ⁻¹' e.target) ∧ + (∀ y ∈ Metric.ball a δ, dist a y = τ * + Real.sqrt (riemannianCoordinateMetric a (extChartAt 𝓘(ℝ,E) a a) + (e.symm (extChartAt 𝓘(ℝ,E) a y)) (e.symm (extChartAt 𝓘(ℝ,E) a y)))) ∧ + fderiv ℝ e 0 = τ • ContinuousLinearMap.id ℝ E := by + obtain ⟨δ,r,τ,hδ,hr,hτ,hτr,Φ,e,hΦ,hΦ0,hode,he,hesub,hed,hei,hsrc,hdiag,htarget,hdist⟩ := + exists_uniform_metric_normal_coordinates (E := E) a + let c := extChartAt 𝓘(ℝ,E) a + let x := c a + let Ψ : ℝ × E → E := fun z => (Φ (z.1,(x,z.2))).1 + let W : ℝ × E → E := fun z => (Φ (z.1,(x,z.2))).2 + have hball : ∀ v ∈ Metric.ball (0:E) r, (x,v) ∈ Metric.ball (x,0) r := by + intro v hv + simpa only [Metric.mem_ball,Prod.dist_eq,dist_self,max_lt_iff] using And.intro hr hv + have hΦc := hΦ.comp (contDiffOn_fst.prodMk (contDiffOn_const.prodMk contDiffOn_snd)) + (show MapsTo (fun z : ℝ × E => (z.1,(x,z.2))) + (Ioo (-r) r ×ˢ Metric.ball 0 r) (Ioo (-r) r ×ˢ Metric.ball (x,0) r) from + fun z hz => ⟨hz.1,hball z.2 hz.2⟩) + have hp : ∀ z : E × E, (e z).1 = z.1 := by intro z; rw [he] + let f := fiberwiseHomeomorph e hp x + have hf : (f : E → E) = fun v => Ψ (τ,v) := by funext v; change (e (x,v)).2 = _; rw [he] + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨by linarith,hr⟩ + have ht : τ ∈ Ioo (-r) r := ⟨by linarith,hτr⟩ + have haz : a ∈ Metric.ball a δ := Metric.mem_ball_self hδ + have hzero := coordinate_geodesic_zero_velocity + (fun t ht' => ((contDiffOn_riemannianCoordinateMetric a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds + (hode t ht' (x,0) (Metric.mem_ball_self hr)).1)).differentiableAt (by simp)) + (fun t ht' => riemannianCoordinateMetric_isInvertible + (hode t ht' (x,0) (Metric.mem_ball_self hr)).1) + (fun t ht' _ hv => riemannianCoordinateMetric_positive + (hode t ht' (x,0) (Metric.mem_ball_self hr)).1 hv) + (fun t _ u v => riemannianCoordinateMetric_symm a _ u v) + (fun t ht' => ⟨((hode t ht' (x,0) (Metric.mem_ball_self hr)).2).fst, + ((hode t ht' (x,0) (Metric.mem_ball_self hr)).2).snd⟩) h0 + (show (Φ (0,(x,0))).2 = 0 from congrArg Prod.snd (hΦ0 (x,0) (Metric.mem_ball_self hr))) ht + have hf0 : f 0 = x := by + rw [hf] + exact hzero.1.trans (congrArg Prod.fst (hΦ0 (x,0) (Metric.mem_ball_self hr))) + refine ⟨δ,r,τ,hδ,hr,hτ,hτr,Ψ,W,f,hΦc.fst,hΦc.snd,?_,?_,hf,hdiag a haz,hf0,?_, + fiberwiseHomeomorph_contDiffOn hp x hed,fiberwiseHomeomorph_symm_contDiffOn hp x hei,?_,?_,?_⟩ + · intro v hv + exact ⟨congrArg Prod.fst (hΦ0 (x,v) (hball v hv)),congrArg Prod.snd (hΦ0 (x,v) (hball v hv))⟩ + · intro t ht' v hv + exact ⟨(hode t ht' (x,v) (hball v hv)).1, + ((hode t ht' (x,v) (hball v hv)).2).fst,((hode t ht' (x,v) (hball v hv)).2).snd⟩ + · intro v hv + exact (max_lt_iff.mp (show max (dist x x) (dist v 0) < r from hesub hv)).2 + · intro y hy + exact ⟨hsrc hy,htarget a haz y hy⟩ + · intro y hy + apply hdist a haz y hy (f.symm (c y)) + · exact f.map_target (htarget a haz y hy) + · change Ψ (τ,f.symm (c y)) = c y + exact (congrFun hf _).symm.trans (f.right_inv (htarget a haz y hy)) + · rw [hf] + exact coordinate_flow_endpoint_derivative_zero a hr hΦ hΦ0 hode ht + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothCoordinateFlow.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothCoordinateFlow.lean new file mode 100644 index 0000000000000000000000000000000000000000..03cdab45069e29a57f3834b9bcc8c5c8f6521514 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothCoordinateFlow.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Coordinates +import OAI.Analysis.BiholderTransport.LocalFlow.LocalDomainFlow + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma exists_smooth_coordinate_flow + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hi : ∀ x ∈ S, (g x).IsInvertible) + (x v : E) (hx : x ∈ S) : + ∃ r : ℝ, 0 < r ∧ ∃ Φ : (ℝ × (E × E)) → E × E, + ContDiffOn ℝ ∞ Φ (Ioo (-r) r ×ˢ Metric.ball (x,v) r) ∧ + (∀ z ∈ Metric.ball (x,v) r, Φ (0,z) = z) ∧ + ∀ t ∈ Ioo (-r) r, ∀ z ∈ Metric.ball (x,v) r, + (Φ (t,z)).1 ∈ S ∧ + HasDerivAt (fun q => (Φ (q,z)).1) (Φ (t,z)).2 t ∧ + HasDerivAt (fun q => (Φ (q,z)).2) + (-coordinateChristoffel g (Φ (t,z)).1 (Φ (t,z)).2 (Φ (t,z)).2) t := by + have hf : ContDiffOn ℝ ∞ (coordinateGeodesicField g) (S ×ˢ (univ : Set E)) := by + intro z hz + exact (contDiffAt_coordinateGeodesicField ((hg z.1 hz.1).contDiffAt + (hS.mem_nhds hz.1)) (hi z.1 hz.1)).contDiffWithinAt + obtain ⟨r,hr,_,Φ,hΦ,hΦ0,hder⟩ := exists_smooth_local_flow_on + (hS.prod isOpen_univ) hf (a := (x,v)) ⟨hx,mem_univ _⟩ + refine ⟨r,hr,Φ,hΦ,hΦ0,?_⟩ + intro t ht z hz + have h := hder t ht z hz + exact ⟨h.1.1,h.2.fst,h.2.snd⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothFlowEndpoint.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothFlowEndpoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..45deaf737d7715bce2b03a1f7472869e2ab32ec4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothFlowEndpoint.lean @@ -0,0 +1,179 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.ImplicitODE + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +omit [CompleteSpace E] in +lemma ode_family_initial {f : C(E,E)} {U : (ℝ × E) → C(UnitTime,E)} {x : E} + (h : U (0,x) = ContinuousMap.const UnitTime x + + (0:ℝ) • unitPathIntegral (f.comp (U (0,x)))) : + U (0,x) = ContinuousMap.const UnitTime x := by simpa using h + +lemma ode_family_endpoint_deriv_zero (f : C(E,E)) (hf : ContDiff ℝ ∞ f) + (U : (ℝ × E) → C(UnitTime,E)) (x : E) + (hU : ContDiffAt ℝ ∞ U (0,x)) + (hEq : ∀ᶠ z in 𝓝 ((0:ℝ),x), U z = ContinuousMap.const UnitTime z.2 + + z.1 • unitPathIntegral (f.comp (U z))) : + HasDerivAt (fun t => U (t,x) ⟨1,by simp⟩) (f x) 0 := by + let e : UnitTime := ⟨1,by simp⟩ + let W : ℝ → E := fun t => unitPathIntegral (f.comp (U (t,x))) e + have hW : ContDiffAt ℝ ∞ W 0 := + (ContinuousMap.evalCLM ℝ e).contDiff.contDiffAt.comp 0 + (unitPathIntegral.contDiff.contDiffAt.comp 0 + ((contDiff_path_comp f hf).contDiffAt.comp 0 + (hU.comp 0 (contDiffAt_id.prodMk contDiffAt_const)))) + have hUx : U (0,x) = ContinuousMap.const UnitTime x := ode_family_initial hEq.self_of_nhds + have hW0 : W 0 = f x := by + simp [W,unitPathIntegral_apply,hUx,extendUnitPath,ContinuousMap.comp_apply,e] + have heq : (fun t : ℝ => U (t,x) e) =ᶠ[𝓝 0] (fun t => x + t • W t) := by + filter_upwards [(continuousAt_id.prodMk continuousAt_const).eventually hEq] with t ht + exact congrArg (fun u : C(UnitTime,E) => u e) ht + have hd := ((hasDerivAt_id (0:ℝ)).smul (hW.differentiableAt (by simp)).hasDerivAt).const_add x + change HasDerivAt (fun t => x + t • W t) + ((0:ℝ) • deriv W 0 + (1:ℝ) • W 0) 0 at hd + have hd' : HasDerivAt (fun t => x + t • W t) (f x) 0 := by + simpa only [id_eq,Pi.smul_apply,one_smul,zero_smul,add_zero,zero_add,hW0] using hd + exact hd'.congr_of_eventuallyEq heq + +lemma ode_family_endpoint_deriv_ne_zero (f : C(E,E)) + (U : (ℝ × E) → C(UnitTime,E)) (S : Set (ℝ × E)) (hS : IsOpen S) + (hEq : ∀ z ∈ S, U z = ContinuousMap.const UnitTime z.2 + + z.1 • unitPathIntegral (f.comp (U z))) + (K : ℝ≥0) (B : Set E) (hf : LipschitzOnWith K f B) + (hB : ∀ z ∈ S, ∀ s, U z s ∈ B) + (t : ℝ) (x : E) (ht : t ≠ 0) (htS : (t,x) ∈ S) (h2tS : (2*t,x) ∈ S) : + HasDerivAt (fun q => U (q,x) ⟨1,by simp⟩) + (f (U (t,x) ⟨1,by simp⟩)) t := by + let a : ℝ := 2*t + have ha : a ≠ 0 := mul_ne_zero (by norm_num) ht + have hratio : t/a = 1/2 := by dsimp [a]; field_simp + have hmem : t/a ∈ Ioo (0:ℝ) 1 := by rw [hratio]; norm_num + have hnear : ∀ᶠ q in 𝓝 t, (q,x) ∈ S ∧ q/a ∈ Ioo (0:ℝ) 1 := + ((continuousAt_id.prodMk continuousAt_const).eventually (hS.mem_nhds htS)).and + ((continuousAt_id.div_const a).eventually (isOpen_Ioo.mem_nhds hmem)) + let γ := rescaledIntegralCurve f a x (U (a,x)) + have heq : (fun q => U (q,x) ⟨1,by simp⟩) =ᶠ[𝓝 t] (fun q => γ (q/a)) := by + filter_upwards [hnear] with q hq + have hqa : a * (q/a) = q := by field_simp + have hs := rescaled_ode_path_time_scaling f a x (U (a,x)) (U (q,x)) + ⟨q/a,Ioo_subset_Icc_self hq.2⟩ K B hf (hEq (a,x) h2tS) + (by simpa only [hqa] using hEq (q,x) hq.1) + (hB (a,x) h2tS) (hB (q,x) hq.1) + exact hs.symm.trans (rescaledIntegralCurve_eq f a x (U (a,x)) + (hEq (a,x) h2tS) ⟨q/a,Ioo_subset_Icc_self hq.2⟩).symm + have hd := (hasDerivAt_rescaledIntegralCurve f a x (U (a,x)) + (hEq (a,x) h2tS) (t/a) (Ioo_subset_Icc_self hmem)).scomp t + ((hasDerivAt_id t).div_const a) + have hd' : HasDerivAt (fun q => γ (q/a)) (f (γ (t/a))) t := by + simpa only [one_div,smul_smul,inv_mul_cancel₀ ha,one_smul,Function.comp_def,id_eq,γ] using hd + have hpoint : U (t,x) ⟨1,by simp⟩ = γ (t/a) := heq.self_of_nhds + rw [←hpoint] at hd' + exact hd'.congr_of_eventuallyEq heq + +end + +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] [CompleteSpace E] + +lemma exists_smooth_local_flow (f : E → E) (hf : ContDiff ℝ ∞ f) (a : E) : + ∃ r : ℝ, 0 < r ∧ ∃ Φ : (ℝ × E) → E, + ContDiffOn ℝ ∞ Φ (Ioo (-r) r ×ˢ Metric.ball a r) ∧ + (∀ x ∈ Metric.ball a r, Φ (0,x) = x) ∧ + ∀ t ∈ Ioo (-r) r, ∀ x ∈ Metric.ball a r, + HasDerivAt (fun s => Φ (s,x)) (f (Φ (t,x))) t := by + obtain ⟨U,S,hS,ha,hU,hUa,hEq⟩ := exists_smooth_rescaled_ode_family_on f hf a + let fC : C(E,E) := ⟨f,hf.continuous⟩ + obtain ⟨K,B,hBa,hLip⟩ := (hf.contDiffAt.of_le (by simp : (1:ℕ∞ω) ≤ (∞:ℕ∞ω))).exists_lipschitzOnWith + obtain ⟨b,hb,hbB⟩ := Metric.mem_nhds_iff.mp hBa + have hcont : ContinuousAt U (0,a) := (hU.contDiffAt (hS.mem_nhds ha)).continuousAt + have hn : ∀ᶠ z in 𝓝 ((0:ℝ),a), z ∈ S ∧ dist (U z) (ContinuousMap.const UnitTime a) < b := by + have h := hcont.eventually (Metric.ball_mem_nhds (U (0,a)) hb) + rw [hUa] at h + exact (show ∀ᶠ z in 𝓝 ((0:ℝ),a), z ∈ S from hS.mem_nhds ha).and h + obtain ⟨ε,hε,hεsub⟩ := Metric.mem_nhds_iff.mp hn + let R := Metric.ball ((0:ℝ),a) ε + have hRS : R ⊆ S := fun z hz => (hεsub hz).1 + have hRB : ∀ z ∈ R, ∀ s, U z s ∈ B := by + intro z hz s + apply hbB + exact lt_of_le_of_lt (ContinuousMap.dist_apply_le_dist (f := U z) + (g := ContinuousMap.const UnitTime a) s) (hεsub hz).2 + let r := ε/3 + have hr : 0 < r := div_pos hε (by norm_num) + have htr : ∀ t ∈ Ioo (-r) r, ∀ x ∈ Metric.ball a r, (t,x) ∈ R ∧ (2*t,x) ∈ R := by + intro t ht x hx + have habs : |t| < r := abs_lt.mpr ht + have hx' : dist x a < r := hx + have hre : r < ε := by dsimp [r]; linarith + have ht2 : |2*t| < ε := by rw [abs_mul,abs_of_pos (by norm_num : (0:ℝ)<2)]; dsimp [r] at habs; linarith + constructor + · change dist (t,x) (0,a) < ε + rw [Prod.dist_eq,max_lt_iff,Real.dist_eq,sub_zero] + exact ⟨habs.trans hre,hx'.trans hre⟩ + · change dist (2*t,x) (0,a) < ε + rw [Prod.dist_eq,max_lt_iff,Real.dist_eq,sub_zero] + exact ⟨ht2,hx'.trans hre⟩ + let Φ : (ℝ × E) → E := fun z => U z ⟨1,by simp⟩ + refine ⟨r,hr,Φ,?_,?_,?_⟩ + · have hUSub : ContDiffOn ℝ ∞ U (Ioo (-r) r ×ˢ Metric.ball a r) := + hU.mono (fun z hz => hRS (htr z.1 hz.1 z.2 hz.2).1) + exact (ContinuousMap.evalCLM ℝ (⟨1,by simp⟩ : UnitTime)).contDiff.comp_contDiffOn hUSub + · intro x hx + have h0 : (0:ℝ) ∈ Ioo (-r) r := ⟨neg_neg_of_pos hr,hr⟩ + have hi := ode_family_initial (hEq (0,x) (hRS (htr 0 h0 x hx).1)) + exact congrArg (fun u : C(UnitTime,E) => u ⟨1,by simp⟩) hi + · intro t ht x hx + by_cases ht0 : t = 0 + · subst t + have hi : Φ (0,x) = x := congrArg (fun u : C(UnitTime,E) => u ⟨1,by simp⟩) + (ode_family_initial (hEq (0,x) (hRS (htr 0 ht x hx).1))) + rw [hi] + exact ode_family_endpoint_deriv_zero fC hf U x + (hU.contDiffAt (hS.mem_nhds (hRS (htr 0 ht x hx).1))) + (Filter.eventually_of_mem (hS.mem_nhds (hRS (htr 0 ht x hx).1)) hEq) + · exact ode_family_endpoint_deriv_ne_zero fC U R Metric.isOpen_ball + (fun z hz => hEq z (hRS hz)) K B hLip hRB t x ht0 + (htr t ht x hx).1 (htr t ht x hx).2 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothIntegralCurve.lean b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothIntegralCurve.lean new file mode 100644 index 0000000000000000000000000000000000000000..68df084eb71c8e9312ac743a0236088b0fdf5b34 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/LocalFlow/SmoothIntegralCurve.lean @@ -0,0 +1,240 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.MIntegralCurveUniformInvariant + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [CompleteSpace E] [HasContDiffBump E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [TopologicalSpace M] [ChartedSpace H M] [IsManifold I ∞ M] + [I.Boundaryless] + +lemma exists_smooth_local_manifold_flow {v : (x : M) → TangentSpace I x} + (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ + (fun x => (⟨x,v x⟩ : TangentBundle I M))) (a : M) : + ∃ r : ℝ, 0 < r ∧ ∃ U : Set M, IsOpen U ∧ a ∈ U ∧ + ∃ Φ : ℝ × M → M, + ContMDiffOn (𝓘(ℝ,ℝ).prod I) I ∞ Φ (Ioo (-r) r ×ˢ U) ∧ + (∀ x ∈ U, Φ (0,x) = x) ∧ + (∀ x ∈ U, IsMIntegralCurveOn (fun t => Φ (t,x)) v (Ioo (-r) r)) := by + let c := extChartAt I a + obtain ⟨r,hr,_,Ψ,hΨ,hΨ0,hΨder⟩ := exists_smooth_local_flow_on + (isOpen_extChartAt_target a) (contDiffOn_coordinate_vectorField hv a) + (c.map_source (mem_extChartAt_source a)) + let U := c.source ∩ c ⁻¹' Metric.ball (c a) r + have hU : IsOpen U := isOpen_extChartAt_preimage' a Metric.isOpen_ball + have ha : a ∈ U := ⟨mem_extChartAt_source a,Metric.mem_ball_self hr⟩ + let Φ : ℝ × M → M := fun z => c.symm (Ψ (z.1,c z.2)) + refine ⟨r,hr,U,hU,ha,Φ,?_,?_,?_⟩ + · intro z hz + have hc : ContMDiffAt I 𝓘(ℝ,E) ∞ c z.2 := + (contMDiffOn_extChartAt (I := I) (n := ∞) (x := a)).contMDiffAt + (by simpa only [extChartAt_source] using + (isOpen_extChartAt_source (I := I) a).mem_nhds hz.2.1) + have hg : ContDiffAt ℝ ∞ Ψ (z.1,c z.2) := + hΨ.contDiffAt ((isOpen_Ioo.prod Metric.isOpen_ball).mem_nhds ⟨hz.1,hz.2.2⟩) + have hsym : ContMDiffAt 𝓘(ℝ,E) I ∞ c.symm (Ψ (z.1,c z.2)) := + (contMDiffOn_extChartAt_symm a).contMDiffAt + ((isOpen_extChartAt_target a).mem_nhds (hΨder z.1 hz.1 (c z.2) hz.2.2).1) + have hpair : ContMDiffAt (𝓘(ℝ,ℝ).prod I) 𝓘(ℝ,ℝ × E) ∞ + (fun w : ℝ × M => (w.1,c w.2)) z := + contMDiffAt_prod_module_iff _ |>.mpr ⟨contMDiffAt_fst,hc.comp z contMDiffAt_snd⟩ + exact (hsym.comp z (hg.contMDiffAt.comp z hpair)).contMDiffWithinAt + · intro x hx + simp only [Φ,hΨ0 _ hx.2,c.left_inv hx.1] + · intro x hx t ht + exact (hasMFDerivAt_of_chart_ode a (hΨder t ht (c x) hx.2).1 + (hΨder t ht (c x) hx.2).2).hasMFDerivWithinAt + +end +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [CompleteSpace E] [HasContDiffBump E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [TopologicalSpace M] [ChartedSpace H M] [IsManifold I ∞ M] + [I.Boundaryless] [T2Space M] + {v : (x : M) → TangentSpace I x} + +variable (hc : ∀ x : M, ∃ γ : ℝ → M, γ 0 = x ∧ IsMIntegralCurve γ v) + +omit [CompleteSpace E] [HasContDiffBump E] [IsManifold I ∞ M] [I.Boundaryless] [T2Space M] in +noncomputable def completeFlow (t : ℝ) (x : M) : M := Classical.choose (hc x) t + +omit [CompleteSpace E] [HasContDiffBump E] [IsManifold I ∞ M] [I.Boundaryless] [T2Space M] in +lemma completeFlow_zero (x : M) : completeFlow hc 0 x = x := (Classical.choose_spec (hc x)).1 + +omit [CompleteSpace E] [HasContDiffBump E] [IsManifold I ∞ M] [I.Boundaryless] [T2Space M] in +lemma completeFlow_curve (x : M) : IsMIntegralCurve (fun t => completeFlow hc t x) v := + (Classical.choose_spec (hc x)).2 + +variable (hv : ContMDiff I (I.prod 𝓘(ℝ,E)) ∞ (fun x => (⟨x,v x⟩ : TangentBundle I M))) +include hv + +omit [CompleteSpace E] [HasContDiffBump E] in +lemma completeFlow_add (s t : ℝ) (x : M) : + completeFlow hc (s+t) x = completeFlow hc s (completeFlow hc t x) := by + have he := isMIntegralCurve_Ioo_eq_of_contMDiff_boundaryless (t₀ := 0) + (hv.of_le (by simp)) ((completeFlow_curve hc x).comp_add t) + (completeFlow_curve hc (completeFlow hc t x)) + (by simpa only [Function.comp_apply,zero_add] using + (completeFlow_zero hc (completeFlow hc t x)).symm) + exact congrFun he s + +omit [CompleteSpace E] [HasContDiffBump E] in +lemma completeFlow_eq_local {r : ℝ} (hr : 0 < r) {U : Set M} {Φ : ℝ × M → M} + (hΦ0 : ∀ x ∈ U, Φ (0,x) = x) + (hΦode : ∀ x ∈ U, IsMIntegralCurveOn (fun t => Φ (t,x)) v (Ioo (-r) r)) + {x : M} (hx : x ∈ U) {t : ℝ} (ht : t ∈ Ioo (-r) r) : + completeFlow hc t x = Φ (t,x) := by + apply isMIntegralCurveOn_Ioo_eqOn_of_contMDiff_boundaryless + (t₀ := 0) ⟨neg_lt_zero.mpr hr,hr⟩ (hv.of_le (by simp)) + ((completeFlow_curve hc x).isMIntegralCurveOn _) (hΦode x hx) _ ht + exact (completeFlow_zero hc x).trans (hΦ0 x hx).symm + +omit [CompleteSpace E] [HasContDiffBump E] in +lemma completeFlow_smooth_step {r : ℝ} (hr : 0 < r) {U : Set M} (hU : IsOpen U) + {Φ : ℝ × M → M} + (hΦ : ContMDiffOn (𝓘(ℝ,ℝ).prod I) I ∞ Φ (Ioo (-r) r ×ˢ U)) + (hΦ0 : ∀ x ∈ U, Φ (0,x) = x) + (hΦode : ∀ x ∈ U, IsMIntegralCurveOn (fun t => Φ (t,x)) v (Ioo (-r) r)) + {s t : ℝ} {a : M} (hs : ContMDiffAt I I ∞ (completeFlow hc s) a) + (ha : completeFlow hc s a ∈ U) (ht : t-s ∈ Ioo (-r) r) : + ContMDiffAt I I ∞ (completeFlow hc t) a := by + have hsm := (hΦ.contMDiffAt ((isOpen_Ioo.prod hU).mem_nhds ⟨ht,ha⟩)).comp a + (contMDiffAt_const.prodMk hs) + apply hsm.congr_of_eventuallyEq + have hnear := hs.continuousAt.preimage_mem_nhds (hU.mem_nhds ha) + filter_upwards [hnear] with x hx + change completeFlow hc t x = Φ (t-s,completeFlow hc s x) + rw [← completeFlow_eq_local hc hv hr hΦ0 hΦode hx ht,← completeFlow_add hc hv,sub_add_cancel] + +lemma contMDiff_completeFlow_time_slice (t : ℝ) : ContMDiff I I ∞ (completeFlow hc t) := by + intro a + let T : Set ℝ := {s | ContMDiffAt I I ∞ (completeFlow hc s) a} + have hT0 : 0 ∈ T := by + change ContMDiffAt I I ∞ (completeFlow hc 0) a + have hzero : completeFlow hc 0 = id := funext (completeFlow_zero hc) + rw [hzero] + exact contMDiffAt_id + have hopen : IsOpen T := by + apply Metric.isOpen_iff.mpr + intro s hs + obtain ⟨r,hr,U,hU,hUa,Φ,hΦ,hΦ0,hΦode⟩ := + exists_smooth_local_manifold_flow hv (completeFlow hc s a) + refine ⟨r,hr,?_⟩ + intro t ht + exact completeFlow_smooth_step hc hv hr hU hΦ hΦ0 hΦode hs hUa + (by simpa only [Metric.mem_ball,Real.dist_eq,abs_lt,mem_Ioo] using ht) + have hcompl : IsOpen Tᶜ := by + apply Metric.isOpen_iff.mpr + intro t ht + obtain ⟨r,hr,U,hU,hUa,Φ,hΦ,hΦ0,hΦode⟩ := + exists_smooth_local_manifold_flow hv (completeFlow hc t a) + have hnear := (completeFlow_curve hc a).continuous.continuousAt.preimage_mem_nhds + (hU.mem_nhds hUa) + obtain ⟨δ,hδ,hδU⟩ := Metric.mem_nhds_iff.mp hnear + refine ⟨min r δ,lt_min hr hδ,?_⟩ + intro s hs hsm + have hsr : dist s t < r := lt_of_lt_of_le hs (min_le_left _ _) + have hsδ : dist s t < δ := lt_of_lt_of_le hs (min_le_right _ _) + apply ht + exact completeFlow_smooth_step hc hv hr hU hΦ hΦ0 hΦode hsm (hδU hsδ) + (by simpa only [Real.dist_eq,abs_sub_comm,abs_lt,mem_Ioo] using hsr) + have hTuniv : T = univ := (IsClopen.eq_univ ⟨isOpen_compl_iff.mp hcompl,hopen⟩ ⟨0,hT0⟩) + change t ∈ T + rw [hTuniv] + exact mem_univ t + +lemma contMDiff_completeFlow : + ContMDiff (𝓘(ℝ,ℝ).prod I) I ∞ (fun z : ℝ × M => completeFlow hc z.1 z.2) := by + intro z + obtain ⟨r,hr,U,hU,hUa,Φ,hΦ,hΦ0,hΦode⟩ := + exists_smooth_local_manifold_flow hv (completeFlow hc z.1 z.2) + have hs := (contMDiff_completeFlow_time_slice hc hv z.1) z.2 + have hpair : ContMDiffAt (𝓘(ℝ,ℝ).prod I) (𝓘(ℝ,ℝ).prod I) ∞ + (fun w : ℝ × M => (w.1-z.1,completeFlow hc z.1 w.2)) z := + (contMDiffAt_fst.sub contMDiffAt_const).prodMk (hs.comp z contMDiffAt_snd) + have hsm := (hΦ.contMDiffAt ((isOpen_Ioo.prod hU).mem_nhds + (show (z.1-z.1,completeFlow hc z.1 z.2) ∈ Ioo (-r) r ×ˢ U from + ⟨by simp only [sub_self,mem_Ioo]; exact ⟨neg_lt_zero.mpr hr,hr⟩,hUa⟩))).comp z hpair + apply hsm.congr_of_eventuallyEq + have hnear := hpair.continuousAt.preimage_mem_nhds + ((isOpen_Ioo.prod hU).mem_nhds + (show (z.1-z.1,completeFlow hc z.1 z.2) ∈ Ioo (-r) r ×ˢ U from + ⟨by simp only [sub_self,mem_Ioo]; exact ⟨neg_lt_zero.mpr hr,hr⟩,hUa⟩)) + filter_upwards [hnear] with w hw + change completeFlow hc w.1 w.2 = Φ (w.1-z.1,completeFlow hc z.1 w.2) + rw [← completeFlow_eq_local hc hv hr hΦ0 hΦode hw.2 hw.1, + ← completeFlow_add hc hv,sub_add_cancel] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Main.lean b/lean/OAI/Analysis/BiholderTransport/Main.lean new file mode 100644 index 0000000000000000000000000000000000000000..158c989788d426391320bf2ef17853ccafc4f787 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Main.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.AECertificates +import OAI.Analysis.BiholderTransport.Calculus.TaylorPositivity +import OAI.Analysis.BiholderTransport.Calculus.LowerTaylorComposition +import OAI.Analysis.BiholderTransport.Coordinates.Endpoint +import OAI.Analysis.BiholderTransport.Calculus.TaylorAlgebra +import OAI.Analysis.BiholderTransport.Coordinates.Stationary +import OAI.Analysis.BiholderTransport.Coordinates.Add +import OAI.Analysis.BiholderTransport.Regularity.FirstActiveLimit +import OAI.Analysis.BiholderTransport.Regularity.CenterPoleStationary +import OAI.Analysis.BiholderTransport.Coordinates.ExpNonconjugateLimit +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceRegular +import OAI.Analysis.BiholderTransport.Regularity.MaximumReindex +import OAI.Analysis.BiholderTransport.Convexity.ChartJensenFirstLimit +import OAI.Analysis.BiholderTransport.Oscillation.ClassPower + +namespace OAI + +section + +noncomputable section +open MeasureTheory Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +theorem uniform_biHolder_transport + {n : ℕ} (hn : 2 ≤ n) {M : Type*} + [MetricSpace M] [CompactSpace M] [ConnectedSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ, Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ, Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + [IsRiemannianManifold 𝓘(ℝ, Model n) M] + [MeasurableSpace M] [BorelSpace M] + (hmtw : WeakMTW (n := n) (M := M)) + (lam cap : ℝ) (hlam : 0 < lam) (hcap : lam ≤ cap) + (hclass : ∃ rho : M → ℝ, AdmissibleDensity (metricVolume n) lam cap rho) : + ∃ alpha C : ℝ, 0 < alpha ∧ alpha ≤ 1 ∧ 0 ≤ C ∧ + ∀ rho0 rho1 : M → ℝ, + AdmissibleDensity (metricVolume n) lam cap rho0 → + AdmissibleDensity (metricVolume n) lam cap rho1 → + ∃ T : M ≃ₜ M, + IsOptimalMap (metricVolume n) rho0 rho1 T ∧ + (∀ S : M → M, IsOptimalMap (metricVolume n) rho0 rho1 S → + S =ᵐ[densityMeasure (metricVolume n) rho0] T) ∧ + BiHolderEstimate alpha C T := by + classical + let x0:M:=Classical.choice (inferInstance:Nonempty M) + exact hmtw.transport_endpoint_of_class_power hlam x0 + (hmtw.class_power (by omega) hlam hcap x0 (densityDualClass_nonempty hlam hclass x0)) + +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/MinimizingVectors.lean b/lean/OAI/Analysis/BiholderTransport/MinimizingVectors.lean new file mode 100644 index 0000000000000000000000000000000000000000..bdd02eaec9ebaecffb8fc602978b5efd3773d466 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/MinimizingVectors.lean @@ -0,0 +1,21 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + [IsManifold 𝓘(ℝ, Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + +def minimizingVectors (x : M) : Set (TangentSpace 𝓘(ℝ, Model n) x) := + {p | dist x (riemannianExp x p) = ‖p‖} + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Model.lean b/lean/OAI/Analysis/BiholderTransport/Model.lean new file mode 100644 index 0000000000000000000000000000000000000000..c056d863d1adb401df60b5d113908909d0a9505e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Model.lean @@ -0,0 +1,98 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport + +abbrev Model (n : ℕ) := EuclideanSpace ℝ (Fin n) + +section MetricDefinitions + +variable {M : Type*} [MetricSpace M] + +/-- Squared-distance cost with factor one half. -/ +def cost (x y : M) : ℝ := dist x y ^ 2 / 2 + +/-- Calibration of Hausdorff measure to Euclidean volume. -/ +def euclideanVolumeFactor (n : ℕ) : ℝ≥0∞ := + volume (Metric.ball (0 : Model n) 1) / + (Measure.hausdorffMeasure (n : ℝ) : Measure (Model n)) + (Metric.ball (0 : Model n) 1) + +variable [MeasurableSpace M] + +/-- Riemannian volume calibrated to Lebesgue measure in Euclidean space. -/ +def metricVolume [BorelSpace M] (n : ℕ) : Measure M := + euclideanVolumeFactor n • Measure.hausdorffMeasure (n : ℝ) + +/-- Almost-everywhere measurable probability densities between fixed bounds. -/ +def AdmissibleDensity (vol : Measure M) (lam cap : ℝ) (rho : M → ℝ) : Prop := + AEMeasurable rho vol ∧ Integrable rho vol ∧ + (∫ x, rho x ∂vol) = 1 ∧ (∀ᵐ x ∂vol, lam ≤ rho x ∧ rho x ≤ cap) + +/-- Multiplication by a density, ignoring exceptional negative values on null sets. -/ +def densityMeasure (vol : Measure M) (rho : M → ℝ) : Measure M := + vol.withDensity (fun x => ENNReal.ofReal (rho x)) + +/-- Optimality for the Monge minimization problem. -/ +def IsOptimalMap (vol : Measure M) (rho0 rho1 : M → ℝ) (T : M → M) : Prop := + Measurable T ∧ Measure.map T (densityMeasure vol rho0) = densityMeasure vol rho1 ∧ + ∀ S : M → M, Measurable S → + Measure.map S (densityMeasure vol rho0) = densityMeasure vol rho1 → + (∫ x, cost x (T x) * rho0 x ∂vol) ≤ + (∫ x, cost x (S x) * rho0 x ∂vol) + +/-- The two global estimates have the very same exponent and constant. -/ +def BiHolderEstimate (alpha C : ℝ) (T : M ≃ₜ M) : Prop := + (∀ x x', dist (T x) (T x') ≤ C * (dist x x') ^ alpha) ∧ + (∀ y y', dist (T.symm y) (T.symm y') ≤ C * (dist y y') ^ alpha) + +end MetricDefinitions + +variable {n : ℕ} {M : Type*} [MetricSpace M] [ChartedSpace (Model n) M] + [IsManifold 𝓘(ℝ, Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ, Model n) x)] + +/-- Complete affinely parametrized geodesic with prescribed initial tangent. +Local metric minimization is an intrinsic definition of Riemannian geodesics. -/ +def IsGeodesicWithInitialData (x : M) (v : TangentSpace 𝓘(ℝ, Model n) x) + (gamma : ℝ → M) : Prop := + ContMDiff 𝓘(ℝ, ℝ) 𝓘(ℝ, Model n) ∞ gamma ∧ + (⟨gamma 0, mfderiv 𝓘(ℝ, ℝ) 𝓘(ℝ, Model n) gamma 0 (1 : ℝ)⟩ : + TangentBundle 𝓘(ℝ, Model n) M) = ⟨x, v⟩ ∧ + ∀ t : ℝ, ∃ eps : ℝ, 0 < eps ∧ + ∀ s u : ℝ, |s - t| < eps → |u - t| < eps → + dist (gamma s) (gamma u) = |s - u| * ‖v‖ + +/-- Evaluation at time one of the geodesic determined by initial data. -/ +def riemannianExp (x : M) (v : TangentSpace 𝓘(ℝ, Model n) x) : M := by + classical + exact if h : ∃ gamma, IsGeodesicWithInitialData x v gamma then (Classical.choose h) 1 else x + +/-- The open injectivity domain, defined by extendible minimizing vectors. -/ +def injectivityDomain (x : M) : Set (TangentSpace 𝓘(ℝ, Model n) x) := + {p | ∃ a : ℝ, 1 < a ∧ dist x (riemannianExp x (a • p)) = a * ‖p‖} + +/-- The Ma–Trudinger–Wang fourth derivative with factor -3/2. -/ +def mtw (x : M) (p xi eta : TangentSpace 𝓘(ℝ, Model n) x) : ℝ := + -(3 / 2 : ℝ) * + iteratedDeriv 2 (fun s : ℝ => + iteratedDeriv 2 (fun t : ℝ => + cost (riemannianExp x (t • xi)) (riemannianExp x (p + s • eta))) 0) 0 + +/-- Weak MTW only at interior velocities and only for orthogonal test vectors. -/ +def WeakMTW : Prop := + ∀ (x : M) (p : TangentSpace 𝓘(ℝ, Model n) x), p ∈ injectivityDomain x → + ∀ xi eta : TangentSpace 𝓘(ℝ, Model n) x, + inner ℝ xi eta = 0 → 0 ≤ mtw x p xi eta + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/ActualPlateaus.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/ActualPlateaus.lean new file mode 100644 index 0000000000000000000000000000000000000000..27e9c9c5eb5d738f9eac046f06114c40840d2aa7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/ActualPlateaus.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.SectionOscillation + +namespace OAI + +section +section +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder +open scoped BoundedContinuousFunction +open Filter + +section ActualPlateaus +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + +omit [BorelSpace M] in + +lemma exists_actual_plateau_section {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hc : (densityDualClass vol lam cap x0).Nonempty) + (hno : ¬ HasPowerUpperBound (classOscillation vol lam cap x0)) + {J : ℝ} (hJ : 1 ≤ J) : + ∃ A : ℝ, ∃ uv ∈ densityDualClass vol lam cap x0, ∃ x y0 y1 : M, + J ^ 2 ≤ A ∧ + y0 ∈ gapSection uv.1 uv.2 x (Real.exp (-(A + J))) ∧ + y1 ∈ gapSection uv.1 uv.2 x (Real.exp (-(A + J))) ∧ + (∀ y ∈ gapSection uv.1 uv.2 x (Real.exp (-(A + J))), uv.2 y0 ≤ uv.2 y) ∧ + (∀ y ∈ gapSection uv.1 uv.2 x (Real.exp (-(A + J))), uv.2 y ≤ uv.2 y1) ∧ + sectionOscillation uv.1 uv.2 x (Real.exp (-(A + J))) = uv.2 y1 - uv.2 y0 ∧ + 0 < uv.2 y1 - uv.2 y0 ∧ + classOscillation vol lam cap x0 (Real.exp (-A)) ≤ + Real.exp (2 / J) * (uv.2 y1 - uv.2 y0) ∧ + |Real.log (uv.2 y1 - uv.2 y0)| ≤ + |Real.log (1 + Metric.diam (univ : Set M) ^ 2)| + A / J ^ 2 + J⁻¹ := by + let F := classOscillation vol lam cap x0 + let CF : ℝ := 1 + Metric.diam (univ : Set M) ^ 2 + have hCF : 0 < CF := by dsimp [CF]; positivity + have hJ0 : 0 < J := zero_lt_one.trans_le hJ + have hJi : 0 < J⁻¹ := inv_pos.mpr hJ0 + have hmono : MonotoneOn F (Ioi 0) := + (classOscillation_monotone hc).mono Ioi_subset_Ici_self + have hbound : ∀ r : ℝ, 0 < r → F r ≤ CF := by + intro r hr + exact (classOscillation_bounds hc hr.le).2.trans (by dsimp [CF]; linarith) + obtain ⟨A, hA, hplateau, hlog⟩ := no_power_gap_scale_plateau hCF hbound hmono hno hJ + have hp : 0 < F (Real.exp (-(A + J))) := positive_of_no_power hmono hno (Real.exp_pos _) + have hq : Real.exp (-J⁻¹) * F (Real.exp (-(A + J))) < F (Real.exp (-(A + J))) := by + have hh := mul_lt_mul_of_pos_right (Real.exp_lt_one_iff.mpr (neg_neg_of_pos hJi)) hp + simpa only [one_mul] using hh + obtain ⟨uv, huv, x, y0, y1, hy0, hy1, hmin, hmax, heq, hlarge⟩ := + exists_section_with_large_oscillation hc (Real.exp_pos _).le hq + have hDpos : 0 < uv.2 y1 - uv.2 y0 := (mul_pos (Real.exp_pos _) hp).trans hlarge + have hDle : uv.2 y1 - uv.2 y0 ≤ F (Real.exp (-(A + J))) := by + rw [← heq] + exact sectionOscillation_le_classOscillation huv x (Real.exp_pos _).le + refine ⟨A, uv, huv, x, y0, y1, hA, hy0, hy1, hmin, hmax, heq, hDpos, ?_, ?_⟩ + · have hFle : F (Real.exp (-(A + J))) ≤ Real.exp J⁻¹ * (uv.2 y1 - uv.2 y0) := by + calc + F (Real.exp (-(A + J))) = + Real.exp J⁻¹ * (Real.exp (-J⁻¹) * F (Real.exp (-(A + J)))) := by + rw [← mul_assoc, ← Real.exp_add, add_neg_cancel, Real.exp_zero, one_mul] + _ ≤ Real.exp J⁻¹ * (uv.2 y1 - uv.2 y0) := + mul_le_mul_of_nonneg_left hlarge.le (Real.exp_pos _).le + calc + F (Real.exp (-A)) ≤ Real.exp J⁻¹ * F (Real.exp (-(A + J))) := hplateau + _ ≤ Real.exp J⁻¹ * (Real.exp J⁻¹ * (uv.2 y1 - uv.2 y0)) := + mul_le_mul_of_nonneg_left hFle (Real.exp_pos _).le + _ = Real.exp (2 / J) * (uv.2 y1 - uv.2 y0) := by + rw [← mul_assoc, ← Real.exp_add] + congr 2 + ring + · have hupper := Real.log_le_log hDpos hDle + have hlower := Real.log_lt_log (mul_pos (Real.exp_pos _) hp) hlarge + rw [Real.log_mul (Real.exp_pos _).ne' hp.ne', Real.log_exp] at hlower + apply abs_le.mpr + constructor + · have hh := neg_le_abs (Real.log (F (Real.exp (-(A + J))))) + linarith + · have hh := le_abs_self (Real.log (F (Real.exp (-(A + J))))) + linarith + +end ActualPlateaus + +end WeakMTWTransport + +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/ClassPower.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/ClassPower.lean new file mode 100644 index 0000000000000000000000000000000000000000..fb0d10de6e0c6ee12b6259753165705c955086e8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/ClassPower.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumTemplateBound +import OAI.Analysis.BiholderTransport.Calculus.OuterDerivativeBound +import OAI.Analysis.BiholderTransport.Oscillation.NonpowerMaximum + +namespace OAI + +section + +noncomputable section +open Set Filter MeasureTheory Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section ClassPower +variable {n:ℕ} {M:Type*} [MetricSpace M] [CompactSpace M] [ConnectedSpace M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.class_power (hmtw:WeakMTW (n:=n) (M:=M)) (hn:0 < n) + {lam cap:ℝ} (hlam:0 < lam) (hcap:lam ≤ cap) (x0:M) + (hc:(densityDualClass (metricVolume n) lam cap x0).Nonempty) : + HasPowerUpperBound (classOscillation (metricVolume n) lam cap x0) := by + classical + by_contra hno + obtain ⟨B,hB,eps,heps,HB⟩:=hmtw.maximum_template_bound hn hlam hcap + let M0:ℝ:=12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) + let μ:ℝ:=(1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)) + have hM:2 ≤ M0:=by dsimp [M0]; have h:=Nat.cast_nonneg (α:=ℝ) (Module.finrank ℝ (Model n)); linarith + have hμ:0 < μ:=by dsimp [μ]; positivity + have hγ:=centerGamma_pos + let K:ℝ:=1+8*centerGamma^2*(B+1)/μ^(n-1) + have hK:1 ≤ K:=by dsimp [K]; exact le_add_of_nonneg_right (by positivity) + let eta:ℝ:=min (1/128) (templateEps/(24*(128*(M0+3)*(K+1)))) + have heta:0 < eta:=by dsimp [eta]; rw [templateEps_eq]; positivity + have heta1:eta ≤ 1/128:=min_le_left _ _ + have hetasmall:eta ≤ templateEps/(24*(128*(M0+3)*(K+1))):=min_le_right _ _ + obtain ⟨C,hC,hder⟩:=exists_outerTemplate_deriv_bound (M0:=M0) (K:=K) heta heta1 + let θ:ℝ:=eps/centerGamma + have hθ:0 < θ:=by dsimp [θ]; positivity + obtain ⟨uv,huv,α,D,bm,bp,hD,hbm,hbp,hsmall,hcent,hout,hosc,herror,⟨F⟩⟩:= + hmtw.nonpower_maximum hc hno hM hK heta heta1 hetasmall hC hder hθ + have hclose:bp/D*centerGamma/2 < eps:=by + have hh:bp/D ≤ θ:=(div_le_iff₀ hD).mpr hsmall + have HH:=mul_le_mul_of_nonneg_right hh hγ.le + have he:θ*centerGamma=eps:=by dsimp [θ]; field_simp + rw [he] at HH + linarith only [HH,heps] + have H:=HB K eta hK heta heta1 hetasmall x0 uv huv α D bm bp hD hbm hbp hcent hclose + C hC hder hout hosc herror F + change μ^(n-1)*K/(8*centerGamma^2) ≤ B at H + have he:μ^(n-1)*K/(8*centerGamma^2)=μ^(n-1)/(8*centerGamma^2)+(B+1):=by + dsimp only [K] + field_simp + rw [he] at H + have hh:0 ≤ μ^(n-1)/(8*centerGamma^2):=by positivity + linarith only [H,hh] + +end ClassPower +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/LowerSwitch.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/LowerSwitch.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d2fa1ac28dfd8083b3a0996c235eb3f2978620b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/LowerSwitch.lean @@ -0,0 +1,92 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.MiddleExclusion + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology NNReal ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def rayBenchmarkGap (z : TangentBundle 𝓘(ℝ,Model n) M) (y : M) + (a vy b By D r C : ℝ) (t : ℝ) : ℝ := + -cost (sprayFlow t z).1 y-vy-b*By+‖z.2‖^2/2+a+r- + (‖z.2‖^2-6*D)*t+C*t^2 + +omit [Nonempty M] in +lemma rayBenchmarkGap_lipschitzOn (z : TangentBundle 𝓘(ℝ,Model n) M) (y : M) + (a vy b By D r C T : ℝ) : + ∃ K, LipschitzOnWith K (fun t => rayBenchmarkGap z y a vy b By D r C t-10*D*t) + (Icc 0 T) := by + obtain ⟨K,hK⟩ := neg_cost_ray_lipschitz z y + have hc : ContDiff ℝ 1 (fun t : ℝ => + -vy-b*By+‖z.2‖^2/2+a+r-(‖z.2‖^2-6*D)*t+C*t^2-10*D*t) := by fun_prop + obtain ⟨L,hL⟩ := hc.contDiffOn.exists_lipschitzOnWith (by norm_num) (convex_Icc 0 T) isCompact_Icc + refine ⟨K+L,?_⟩ + have he : (fun t => rayBenchmarkGap z y a vy b By D r C t-10*D*t) = + (fun t => -cost (sprayFlow t z).1 y + + (-vy-b*By+‖z.2‖^2/2+a+r-(‖z.2‖^2-6*D)*t+C*t^2-10*D*t)) := by + funext t + dsimp only [rayBenchmarkGap] + ring + rw [he] + exact hK.lipschitzOnWith.add hL + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma rayBenchmarkGap_hasDerivAt {z : TangentBundle 𝓘(ℝ,Model n) M} {y : M} + (a vy b By D r C : ℝ) {t d : ℝ} + (hd : HasDerivAt (fun s => -cost (sprayFlow s z).1 y) d t) : + HasDerivAt (fun s => rayBenchmarkGap z y a vy b By D r C s-10*D*s) + (d-‖z.2‖^2-4*D+2*C*t) t := by + have H0 := ((((hd.sub_const vy).sub_const (b*By)).add_const (‖z.2‖^2/2)).add_const a).add_const r + have H := ((H0.sub ((hasDerivAt_id t).const_mul (‖z.2‖^2-6*D))).add + (((hasDerivAt_id t).pow 2).const_mul C)).sub ((hasDerivAt_id t).const_mul (10*D)) + convert H using 1 <;> norm_num [id_eq] <;> first | rfl | ring + +omit [Nonempty M] in +lemma benchmark_lower_switch_time {z : TangentBundle 𝓘(ℝ,Model n) M} {y : M} + {a vy b By D r C η T : ℝ} (hb : 0≤b) (hD : 0 rayBenchmarkGap z y a vy b By D r C s-10*D*s) t≤0 := by + obtain ⟨L,hL⟩ := neg_cost_ray_lipschitz z y + filter_upwards [hL.ae_differentiableAt] with t ht htI hval + have hDt : 0≤10*D*t := mul_nonneg (by positivity) htI.1 + have hval' : -b/2≤rayBenchmarkGap z y a vy b By D r C t := by linarith only [hval,hDt] + have htime : 12*D*t≤12*D*T := mul_le_mul_of_nonneg_left htI.2 (by positivity) + have hsquare : t^2≤T^2 := pow_le_pow_left₀ htI.1 htI.2 2 + have hquad : 2*C*t^2≤2*C*T^2 := mul_le_mul_of_nonneg_left hsquare (by positivity) + have hcost : dist (sprayFlow t z).1 y^2≤(1-t)^2*‖z.2‖^2+D := by + dsimp only [rayBenchmarkGap,cost] at hval' + have hbB := mul_nonneg hb hBy + have htP := mul_nonneg (sq_nonneg t) (sq_nonneg ‖z.2‖) + nlinarith only [hval',hlevel,hsmall,htime,hquad,hbB,htP] + have Hn := cost_norm_surplus_deriv htI.1 (htI.2.trans hT1) hD.le ht.hasDerivAt hcost + have hlin : 2*C*t≤2*C*T := mul_le_mul_of_nonneg_left htI.2 (by positivity) + rw [(rayBenchmarkGap_hasDerivAt a vy b By D r C ht.hasDerivAt).deriv] + have htP := mul_nonneg htI.1 (sq_nonneg ‖z.2‖) + nlinarith only [Hn,hlin,hsmall',htP] + have HT := H hd T ⟨hT,le_rfl⟩ + apply (div_le_iff₀ (by positivity : 0<20*D)).mpr + nlinarith only [HT,hfinish] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/NonpowerMaximum.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/NonpowerMaximum.lean new file mode 100644 index 0000000000000000000000000000000000000000..0369a81c0420531063170c71992332884c39476f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/NonpowerMaximum.lean @@ -0,0 +1,205 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.UniformFixedCrossing +import OAI.Analysis.BiholderTransport.Regularity.MaximumFamily +import OAI.Analysis.BiholderTransport.Regularity.OuterTemplatePrimitive +import OAI.Analysis.BiholderTransport.Calculus.UniformCostTaylor +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamilyBounds +import OAI.Analysis.BiholderTransport.Regularity.ActualSmallPlateau +import OAI.Analysis.BiholderTransport.Oscillation.SwitchToExcess +import OAI.Analysis.BiholderTransport.Oscillation.SwitchNumerics +import OAI.Analysis.BiholderTransport.Regularity.FamilyGlobal +import OAI.Analysis.BiholderTransport.Regularity.SmallEpsilon + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle Metric MeasureTheory +open scoped Topology ContDiff NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section NonpowerMaximum +variable {n:ℕ} {M:Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.nonpower_maximum (hmtw:WeakMTW (n:=n) (M:=M)) + {lam cap:ℝ} {x0:M} (hc:(densityDualClass (metricVolume n) lam cap x0).Nonempty) + (hno:¬HasPowerUpperBound (classOscillation (metricVolume n) lam cap x0)) + {M0 K eta C θ:ℝ} (hM:2 ≤ M0) (hK:1 ≤ K) (heta:0 < eta) (heta1:eta ≤ 1/128) + (hetasmall:eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) + (hC:0 ≤ C) (hder:∀s,|deriv (outerTemplate M0 K eta) s| ≤ C) (hθ:0 < θ) : + ∃uv∈densityDualClass (metricVolume n) lam cap x0,∃α D bm bp:ℝ, + 0 < D ∧ 0 < bm ∧ 0 < bp ∧ bp ≤ θ*D ∧ bp/D*centerGamma ≤ 1 ∧ bp/D*C ≤ 1/2 ∧ + (∀z:M,sectionOscillation uv.1 uv.2 z ((2*M0+10)*bp) ≤ (1+eta)*D) ∧ + 2*(2*M0+10)*bp ≤ eta*D ∧ + Nonempty (MaximumFamily (n:=n) uv.2 α D bm bp centerTemplate (outerTemplate M0 K eta)) := by + classical + let H:ℝ:=2*M0+8 + have hH:0 ≤ H:=by dsimp [H]; linarith only [hM] + let P:ℝ:=Metric.diam (univ:Set M) + have hP:0 ≤ P:=Metric.diam_nonneg + have hγ:=centerGamma_pos + obtain ⟨Cg,hCg,d,hd,hTaylor⟩:=exists_uniform_cost_upper_taylor (n:=n) (M:=M) + let S:Finset ℝ:={eta,1/(2^40),1/(H+100),1/(16*H+1000), + 1/(1048576*(Cg+1)*(P^2+1)),d/(16*(P+1)),eta/(2*(H+2)),1/(H+2),θ, + 1/centerGamma,1/(2*(C+1))} + have hS:∀a∈S,0 < a:=by + intro a ha + simp only [S,Finset.mem_insert,Finset.mem_singleton] at ha + rcases ha with rfl|rfl|rfl|rfl|rfl|rfl|rfl|rfl|rfl|rfl|rfl <;> positivity + obtain ⟨e,he,hse⟩:=exists_small_positive S hS + have heeta:e ≤ eta:=hse _ (by simp [S]) + have he40:e ≤ 1/(2^40):=hse _ (by simp [S]) + have heR:e*(H+100) ≤ 1:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have heD:e*(16*H+1000) ≤ 1:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have heQ:e*(1048576*(Cg+1)*(P^2+1)) ≤ 1:= + (le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have hed:e*(16*(P+1)) ≤ d:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have heη:e*(2*(H+2)) ≤ eta:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have heHR:e*(H+2) ≤ 1:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have heθ:e ≤ θ:=hse _ (by simp [S]) + have heγ:e*centerGamma ≤ 1:=(le_div_iff₀ hγ).mp (hse _ (by simp [S])) + have heC:e*(2*(C+1)) ≤ 1:=(le_div_iff₀ (by positivity)).mp (hse _ (by simp [S])) + have he1:e ≤ 1:=by norm_num at he40; linarith only [he40] + obtain ⟨r,R,bm,bp,hr,hR,hbm,hbp,uv,huv,x,y0,y1,hy0,hy1,hlo,hhi,hsec,hD,hglobal, + hrbm,hbmbp,hbpR,hbpPow⟩:=exists_actual_small_plateau hc hno he + let D:=uv.2 y1-uv.2 y0 + change 0 < D at hD + change sectionOscillation uv.1 uv.2 x r = D at hsec + let α:=uv.2 y0 + let b:ℝ:=bp/8192 + have hb:0 < b:=div_pos hbp (by norm_num) + have hbbp:b ≤ bp:=by dsimp [b]; linarith only [hbp] + have hbpD:bp ≤ e*D:=by simpa only [pow_one] using hbpPow 1 (by norm_num) + have hbD':b ≤ e*D:=hbbp.trans hbpD + have hbpD2:bp ≤ e*D^2:=hbpPow 2 le_rfl + have hbmle:bm ≤ bp:=hbmbp.trans (by nlinarith only [he1,hbp]) + have hrbp:r ≤ e*bp:=hrbm.trans (mul_le_mul_of_nonneg_left hbmle he.le) + have hrb:r ≤ b/2048:=by + have HH:=mul_le_mul_of_nonneg_right he40 hbp.le + dsimp [b] + norm_num at HH + linarith only [hrbp,HH,hbp] + have hsmallbm:bm ≤ bp/(64*1024^2):=by + have HH:=mul_le_mul_of_nonneg_right he40 hbp.le + norm_num at HH ⊢ + linarith only [hbmbp,HH,hbp] + have hbR:b*(H+100) ≤ R:=by + simpa only [one_mul] using ratio_mul_le (hbbp.trans hbpR) (by positivity) hR.le heR + have hbDb:b*(16*H+1000) ≤ D:=by + simpa only [one_mul] using ratio_mul_le hbD' (by positivity) hD.le heD + obtain ⟨p,hp,hep⟩:=exists_minimizing_vector (n:=n) x y0 + obtain ⟨q,hq,heq⟩:=exists_minimizing_vector (n:=n) x y1 + have hpP:‖p‖ ≤ P:=minimizing_norm_le_diam hp + have hpP2:‖p‖^2 ≤ P^2:=sq_le_sq₀ (norm_nonneg _) hP |>.mpr hpP + have hbQuad:b*(Cg+1)*(‖p‖^2+1) ≤ D^2/1048576:=by + have hh:=ratio_mul_le (hbbp.trans hbpD2) (by positivity) (sq_nonneg D) heQ + rw [one_mul] at hh + have hmul:=mul_le_mul_of_nonneg_left (add_le_add_right hpP2 1) (show 0 ≤ b*(Cg+1) by positivity) + nlinarith only [hh,hmul] + obtain ⟨hrb4,hbD16,hanchor,hlower,hlower',hnorm,herror⟩:=switch_numerical_errors hb hD hr.le hCg.le hH + (sq_nonneg ‖p‖) heta1 hrb hbR hbDb hbQuad + have hsdisp:‖(8*b/D:ℝ) • p‖ < d:=by + rw [norm_smul,Real.norm_eq_abs,abs_of_nonneg (by positivity : 0 ≤ 8*b/D)] + have hratio:b/D ≤ e:=(div_le_iff₀ hD).mpr hbD' + have hh:=mul_le_mul_of_nonneg_right hratio (show 0 ≤ 8*‖p‖ by positivity) + have hhP:=mul_le_mul_of_nonneg_left hpP (show 0 ≤ 8*e by positivity) + calc + (8*b/D)*‖p‖ = (b/D)*(8*‖p‖) := by ring + _ ≤ e*(8*‖p‖) := hh + _ = 8*e*‖p‖ := by ring + _ ≤ 8*e*P := hhP + _ < d := by nlinarith only [hed,he,mul_nonneg he.le hP] + have hdual:=densityDualClass_isDual huv + have ha:uv.2 (riemannianExp x p)=α:=by rw [hep] + have ha1:uv.2 (riemannianExp x q)=α+D:=by rw [heq]; dsimp [α,D]; ring + have hpsec:p∈liftedGapSection uv.1 uv.2 x r:=mem_liftedGapSection_iff.mpr ⟨hp,by rwa [hep]⟩ + have hqsec:q∈liftedGapSection uv.1 uv.2 x r:=mem_liftedGapSection_iff.mpr ⟨hq,by rwa [heq]⟩ + have hangle:‖p‖^2-inner ℝ p q ≤ 6*D:= + (hmtw.section_initial_logs uv.1.continuous uv.2.continuous hdual hr.le + (by linarith only [hrb4,hbD16,hD]) hpsec hqsec ha ha1 hsec.le).2.2.1 + have hosc (z:M):sectionOscillation uv.1 uv.2 z R ≤ (1+eta)*D:=by + apply (sectionOscillation_le_classOscillation huv z hR.le).trans + exact hglobal.trans (mul_le_mul_of_nonneg_right (add_le_add_right heeta 1) hD.le) + let Bo:=outerTemplate M0 K eta + have hBo:ContDiff ℝ ∞ Bo:=outerTemplate_smooth _ _ _ + have hob (s):0 ≤ Bo s ∧ Bo s ≤ H:=⟨outerTemplate_nonneg hM hK heta heta1 hetasmall, + outerTemplate_upper hM hK heta heta1 hetasmall⟩ + obtain ⟨y,hy⟩:=hmtw.switch_to_positive_excess uv.1.continuous uv.2.continuous hdual hp hq hBo.continuous + ha ha1 hb hD hr.le hR.le hCg.le (mem_liftedGapSection_iff.mp hpsec).2 (mem_liftedGapSection_iff.mp hqsec).2 hangle heta.le heta1 hrb4 hbD16 hob + (by dsimp [Bo]; rw [outerTemplate_zero_level heta heta1,templateEps_eq]; norm_num) + (outerTemplate_zero heta le_rfl) + (fun s hs=>outerTemplate_lower hM hK heta heta1 hetasmall (by linarith only [hs,heta1])) + (fun s hs=>outerTemplate_barrier hM hK heta heta1 hs.1 hs.2) + (fun s=>(centerTemplate_bounds s).1.le) (fun s hs=>by simpa only [templateEps_eq] using centerTemplate_left hs) + hsdisp hanchor hosc hlower hlower' hnorm herror hTaylor + have hγsmall:bp/D*centerGamma ≤ 1:=by + have hh:=ratio_mul_le hbpD hγ.le hD.le heγ + rw [one_mul] at hh + calc bp/D*centerGamma = (bp*centerGamma)/D := by ring + _ ≤ 1 := (div_le_iff₀ hD).mpr (by simpa only [one_mul] using hh) + have hCsmall:bp/D*C ≤ 1/2:=by + have heC':e*C ≤ 1/2:=by nlinarith only [heC,he] + have hh:=ratio_mul_le hbpD hC hD.le heC' + calc bp/D*C = (bp*C)/D := by ring + _ ≤ 1/2 := (div_le_iff₀ hD).mpr hh + have hsCenter (s:ℝ) (hs:s∈Icc bm bp):s/D*(centerGamma/2) ≤ 1/2:=by + have hh:=mul_le_mul_of_nonneg_right ((div_le_div_iff_of_pos_right hD).mpr hs.2) hγ.le + nlinarith only [hh,hγsmall] + have hmono (s:ℝ) (hs:s∈Icc bm bp):Monotone (fun t=>modifiedScalar α D centerTemplate (s,t)):= + (modifiedScalar_strictMono centerTemplate_smooth (by positivity) hD (hbm.le.trans hs.1) + (hsCenter s hs) exact_center_deriv_abs α).monotone + have hLipφ (s:ℝ) (hs:s∈Icc bm bp):LipschitzWith 2 (fun t=>modifiedScalar α D centerTemplate (s,t)):= + modifiedScalar_lipschitz centerTemplate_smooth (by positivity) hD (hbm.le.trans hs.1) + (hsCenter s hs) exact_center_deriv_abs α + let Lv:ℝ≥0:=⟨P,hP⟩ + have hvL:LipschitzWith Lv (uv.2:M → ℝ):=by + rw [hdual.2] + exact cTransform_lipschitz uv.1.continuous (fun x y=>Metric.dist_le_diam_of_mem + isCompact_univ.isBounded (mem_univ x) (mem_univ y)) + obtain ⟨A,hA⟩:=isCompact_univ.exists_bound_of_continuousOn uv.2.continuous.continuousOn + have hrange:∀y:M,cTransform uv.1 y∈Icc (-A) A:=by + intro y + rw [←hdual.2] + exact abs_le.mp (hA y (mem_univ y)) + obtain ⟨δ,hδ,hreg⟩:=uniform_family_short_mdifferentiable (n:=n) (M:=M) + (modifiedScalar_contDiff centerTemplate_smooth α D) isCompact_Icc hmono hLipφ (-A) A + have hL:∀s∈Icc bm bp,LipschitzWith (2*Lv) (modifiedDatum uv.2 α D s centerTemplate):= + fun s hs=>(hLipφ s hs).comp hvL + have hreg':∀s∈Icc bm bp,∀τ:ℝ,0 < τ → τ < δ → + MDifferentiable 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (hopfLax τ (modifiedDatum uv.2 α D s centerTemplate)):=by + intro s hs τ hτ hτδ + change MDifferentiable _ _ (hopfLax τ (fun y=>uv.2 y+s*centerTemplate ((uv.2 y-α)/D))) + simpa only [←hdual.2,modifiedScalar] using hreg s hs uv.1 uv.1.continuous hrange τ hτ hτδ + have hF:=hmtw.exists_maximum_family uv.2.continuous centerTemplate_smooth.continuous hBo.continuous hob + hbp hbm.le hsmallbm + (fun s hs z=>modified_excess_upper uv.1.continuous uv.2.continuous hdual hBo.continuous + (hbm.le.trans hs.1) (fun t=>(hob t).1) (fun t=>(centerTemplate_bounds t).2.le) z) + (show ∃y,bp/(8*1024^2) ≤ modifiedExcess uv.2 α D (bp/(8*1024)) centerTemplate Bo y from by + refine ⟨y,?_⟩ + simpa only [b,show (8192:ℝ)=8*1024 by norm_num,div_div,pow_two,mul_assoc] using hy) + hL hδ hreg' + refine ⟨uv,huv,α,D,bm,bp,hD,hbm,hbp,hbpD.trans (mul_le_mul_of_nonneg_right heθ hD.le), + hγsmall,hCsmall,?_,?_,hF⟩ + · intro z + apply le_trans (sectionOscillation_mono uv.2.continuous hdual z (by positivity) ?_) (hosc z) + have hh:=ratio_mul_le hbpR (show 0 ≤ H+2 by positivity) hR.le heHR + dsimp [H] at hh + nlinarith only [hh] + · have hh:=ratio_mul_le hbpD (show 0 ≤ 2*(H+2) by positivity) hD.le heη + dsimp [H] at hh + nlinarith only [hh] + +end NonpowerMaximum +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/ScalarFirstSwitch.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/ScalarFirstSwitch.lean new file mode 100644 index 0000000000000000000000000000000000000000..5b414b83f78e5508b6e51fa84ca66a5c0f3d2e9c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/ScalarFirstSwitch.lean @@ -0,0 +1,254 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.MiddleExclusion +import OAI.Analysis.BiholderTransport.Regularity.RayAnchor +import OAI.Analysis.BiholderTransport.Regularity.RestrictedTransform + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory +open scoped Topology NNReal + +namespace WeakMTWTransport + +lemma scalar_first_switch {f h : ℝ → ℝ} {K : ℝ≥0} {b D r : ℝ} + (hb : 0ht.1) + have hZn : Z.Nonempty := by obtain ⟨t,ht,he⟩:=hex; exact ⟨t,ht,he⟩ + obtain ⟨τ,hτ,hτmin⟩ := hZ.exists_isLeast hZn + have hτ0 : 0<τ := lt_of_le_of_ne hτ.1.1 (by intro H; subst τ; linarith only [h0,hτ.2]) + refine ⟨τ,⟨hτ0,hτ.1.2⟩,hτ.2,?_⟩ + intro t ht + by_contra ht' + obtain ⟨s,hs,hse⟩ := intermediate_value_Icc' ht.1 hh.continuousOn + (show (0:ℝ)∈Icc (h t) (h 0) from ⟨le_of_not_gt ht',h0.le⟩) + have hsZ : s∈Z := ⟨⟨hs.1,hs.2.trans (ht.2.le.trans hτ.1.2)⟩,hse⟩ + exact (not_le_of_gt (hs.2.trans_lt ht.2)) (hτmin hsZ) + +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology NNReal ContDiff + +namespace WeakMTWTransport +section FirstSwitch +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma modified_middle_not_contact {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} (hz : z.2∈minimizingVectors z.1) + {a D b r eta t : ℝ} {B : ℝ → ℝ} (hB : Continuous B) + (ha : v (riemannianExp z.1 z.2)=a) (hb : 0 restrictedTransform w S (sprayFlow t z).1 + let U : ℝ → ℝ := fun t => restrictedTransform w R (sprayFlow t z).1 + have hL : Continuous L := (continuous_restrictedTransform hw hS hSn).comp + (lipschitz_spray_projection z).continuous + have hU : Continuous U := (continuous_restrictedTransform hw hR hRn).comp + (lipschitz_spray_projection z).continuous + let T := 8*b/D + have hT : 0H (Or.inl h)) + have hr' : (v y-a)/D<1-eta := lt_of_not_ge (fun h=>H (Or.inr h)) + exact modified_middle_not_contact hv hz hB ha hb hD hr ht.1 (ht.2.trans hT1) + hgap0 hbar ⟨hs.le,hr'.le⟩ hc + have heq : ∀ t∈Icc 0 T,cTransform w (sprayFlow t z).1=max (L t) (U t) := by + intro t ht + exact cTransform_eq_max_restricted hw hS hSn hR hRn (hcover t ht) + have hL0 : L 0≤cTransform v z.1-b := by + obtain ⟨y,hy,he,H⟩ := exists_restrictedTransform_contact hw hS hSn z.1 + have Hg := cTransform_gap_nonneg hv z.1 y + have HB := mul_le_mul_of_nonneg_left (hBl ((v y-a)/D) hy) hb.le + dsimp only [L] + rw [sprayFlow_zero,he] + dsimp only [w,modifiedDatum,contactGap] at * + linarith only [Hg,HB] + have hU0 : cTransform v z.1-r≤U 0 := by + obtain ⟨y,hy,he,H⟩ := exists_restrictedTransform_contact hw hR hRn z.1 + have hy1 : y1∈R := by dsimp [R]; simp only [ha1,add_sub_cancel_left,div_self hD.ne']; linarith only [heta0] + have H1 := H y1 hy1 + have he1 : (v y1-a)/D=1 := by simp only [ha1,add_sub_cancel_left,div_self hD.ne'] + dsimp only [w,modifiedDatum] at H1 + rw [he1,hB1,mul_zero,add_zero] at H1 + dsimp only [U] + rw [sprayFlow_zero] + dsimp only [contactGap] at hgap1 + linarith only [H1,hgap1] + have h0 : 0by + dsimp only [w,modifiedDatum]; exact le_add_of_nonneg_right (mul_nonneg hb.le (hBn _))) z.1 + have Hcost : cost z.1 (riemannianExp z.1 z.2)=‖z.2‖^2/2 := by rw [cost,show dist z.1 (riemannianExp z.1 z.2)=‖z.2‖ from hz] + rw [contactGap,Hcost,ha] at hgap0 + dsimp only [f,transformRayDifference] + rw [sprayFlow_zero] + norm_num only [sub_zero,one_pow,one_mul] + linarith only [HG,hgap0] + have hfT : -2*b≤f T := by + have H := modified_ray_difference_lower (D := D) (b := b) hv hz hB ha hT.le (by linarith only [hT1]) + have HB := mul_le_mul_of_nonneg_left hB0 hb.le + linarith only [H,HB] + have hdrop : ∀ᵐ t : ℝ,t∈Icc 0 T → 0 linarith only [heta] + exact modified_middle_not_contact hv hz hB ha hb hD hr hτI.1 (hτI.2.trans hT1) + hgap0 hbar hm hcm + · intro t ht + refine ⟨modified_ray_difference_lower hv hz hB ha ht.1 + (by linarith only [ht.2,hτI.2,hT1]),?_⟩ + have hsmall : Icc 0 t⊆Icc 0 T := Icc_subset_Icc_right (ht.2.trans hτI.2) + have hne : ∀ᵐ s : ℝ,s≠τ := by rw [ae_iff]; simp + have hd : ∀ᵐ s : ℝ,s∈Icc 0 t → deriv f s≤-D/2 := by + filter_upwards [hdrop,hne] with s hs hne hsI + exact hs (hsmall hsI) (hpre s ⟨hsI.1,lt_of_le_of_ne (hsI.2.trans ht.2) hne⟩) + have H := lipschitzOn_sub_le_of_ae_deriv_le ht.1 (hK.mono hsmall) hd + have Hn : (-D/2)*(t-0)≤0 := mul_nonpos_of_nonpos_of_nonneg (by linarith only [hD]) + (by linarith only [ht.1]) + change f t≤r + linarith only [H,Hn,hf0] + +end FirstSwitch +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/SectionOscillation.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/SectionOscillation.lean new file mode 100644 index 0000000000000000000000000000000000000000..1bad21186fb27d79fa32716dc3814b039a6b9010 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/SectionOscillation.lean @@ -0,0 +1,412 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.RadialNull +import OAI.Analysis.BiholderTransport.Duality.CompactDual + +namespace OAI + +section +section +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder +open scoped BoundedContinuousFunction + +section SectionOscillation +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +def sectionOscillation (u v : M → ℝ) (x : M) (r : ℝ) : ℝ := + sSup (v '' gapSection u v x r) - sInf (v '' gapSection u v x r) + +omit [Nonempty M] in +lemma isCompact_gapSection {u v : M → ℝ} (hv : Continuous v) (x : M) (r : ℝ) : + IsCompact (gapSection u v x r) := by + apply IsClosed.isCompact + exact isClosed_le ((continuous_const.add (continuous_cost_right x)).add hv) continuous_const + +lemma gapSection_nonempty {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x : M) {r : ℝ} (hr : 0 ≤ r) : + (gapSection u v x r).Nonempty := by + obtain ⟨y, hy⟩ := dualPair_contact_left hv huv x + exact ⟨y, by simpa only [gapSection, mem_ofPred_eq, hy] using hr⟩ + +lemma sectionOscillation_extrema {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x : M) {r : ℝ} (hr : 0 ≤ r) : + ∃ y0 ∈ gapSection u v x r, ∃ y1 ∈ gapSection u v x r, + (∀ y ∈ gapSection u v x r, v y0 ≤ v y) ∧ + (∀ y ∈ gapSection u v x r, v y ≤ v y1) ∧ + sectionOscillation u v x r = v y1 - v y0 := by + have hc := isCompact_gapSection (u := u) hv x r + have hn := gapSection_nonempty hv huv x hr + obtain ⟨y0, hy0, hmin⟩ := hc.exists_isMinOn hn hv.continuousOn + obtain ⟨y1, hy1, hmax⟩ := hc.exists_isMaxOn hn hv.continuousOn + have hleast : IsLeast (v '' gapSection u v x r) (v y0) := by + refine ⟨mem_image_of_mem v hy0, ?_⟩ + rintro _ ⟨y, hy, rfl⟩ + exact hmin hy + have hgreatest : IsGreatest (v '' gapSection u v x r) (v y1) := by + refine ⟨mem_image_of_mem v hy1, ?_⟩ + rintro _ ⟨y, hy, rfl⟩ + exact hmax hy + exact ⟨y0, hy0, y1, hy1, fun _ hy => hmin hy, fun _ hy => hmax hy, + by rw [sectionOscillation, hleast.csInf_eq, hgreatest.csSup_eq]⟩ + +lemma sectionOscillation_nonneg {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x : M) {r : ℝ} (hr : 0 ≤ r) : + 0 ≤ sectionOscillation u v x r := by + obtain ⟨y0, _, y1, hy1, hmin, _, heq⟩ := sectionOscillation_extrema hv huv x hr + rw [heq] + exact sub_nonneg.mpr (hmin y1 hy1) + +lemma sectionOscillation_mono {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x : M) {r R : ℝ} (hr : 0 ≤ r) (hrR : r ≤ R) : + sectionOscillation u v x r ≤ sectionOscillation u v x R := by + obtain ⟨y0, hy0, y1, hy1, _, _, heq⟩ := sectionOscillation_extrema hv huv x hr + obtain ⟨z0, _, z1, _, hmin, hmax, heq'⟩ := + sectionOscillation_extrema hv huv x (hr.trans hrR) + have h0 := hmin y0 (hy0.trans hrR) + have h1 := hmax y1 (hy1.trans hrR) + rw [heq, heq'] + linarith + +lemma sectionOscillation_le_diam_sq {u v : M → ℝ} (hu : Continuous u) + (hv : Continuous v) (huv : IsCostDualPair u v) (x : M) {r : ℝ} (hr : 0 ≤ r) : + sectionOscillation u v x r ≤ Metric.diam (univ : Set M) ^ 2 := by + let D : ℝ≥0 := ⟨Metric.diam (univ : Set M), Metric.diam_nonneg⟩ + have hD (x y : M) : dist x y ≤ D := + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + have hLip : LipschitzWith D v := by + rw [huv.2] + exact cTransform_lipschitz hu hD + obtain ⟨y0, _, y1, _, _, _, heq⟩ := sectionOscillation_extrema hv huv x hr + have hh := hLip.dist_le_mul y1 y0 + rw [Real.dist_eq] at hh + rw [heq] + calc + v y1 - v y0 ≤ |v y1 - v y0| := le_abs_self _ + _ ≤ (D : ℝ) * dist y1 y0 := hh + _ ≤ (D : ℝ) ^ 2 := by nlinarith [mul_le_mul_of_nonneg_left (hD y1 y0) D.coe_nonneg] + +variable [MeasurableSpace M] [BorelSpace M] + +def densityDualClass (vol : Measure M) (lam cap : ℝ) (x0 : M) : + Set ((M →ᵇ ℝ) × (M →ᵇ ℝ)) := + {uv | uv ∈ normalizedDualPairs x0 ∧ + ∃ rho0 rho1 : M → ℝ, AdmissibleDensity vol lam cap rho0 ∧ + AdmissibleDensity vol lam cap rho1 ∧ + ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective (densityMeasure vol rho0) (densityMeasure vol rho1) uv ≤ + dualObjective (densityMeasure vol rho0) (densityMeasure vol rho1) (a,b)} + +lemma densityDualClass_nonempty {vol : Measure M} {lam cap : ℝ} (hlam : 0 < lam) + (hclass : ∃ rho : M → ℝ, AdmissibleDensity vol lam cap rho) (x0 : M) : + (densityDualClass vol lam cap x0).Nonempty := by + obtain ⟨rho, hrho⟩ := hclass + have := densityMeasure_probability hlam hrho + let mu := densityMeasure vol rho + obtain ⟨uv, huv, hmin⟩ := exists_minimizing_normalizedDualPair mu mu x0 + refine ⟨uv, huv, rho, rho, hrho, hrho, ?_⟩ + intro a b hab + exact (hmin (normalizeDualPair_mem x0 b)).trans + (dualObjective_normalize_le mu mu x0 a b hab) + +omit [BorelSpace M] in +lemma densityDualClass_isDual {vol : Measure M} {lam cap : ℝ} {x0 : M} + {uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)} (h : uv ∈ densityDualClass vol lam cap x0) : + IsCostDualPair uv.1 uv.2 := by + constructor + · exact congrArg (fun f : M →ᵇ ℝ => (f : M → ℝ)) h.1.2.1.symm + · exact congrArg (fun f : M →ᵇ ℝ => (f : M → ℝ)) h.1.2.2.symm + +def classSectionOscillations (vol : Measure M) (lam cap : ℝ) (x0 : M) (r : ℝ) : Set ℝ := + {a | ∃ uv ∈ densityDualClass vol lam cap x0, ∃ x : M, + a = sectionOscillation uv.1 uv.2 x r} + +def classOscillation (vol : Measure M) (lam cap : ℝ) (x0 : M) (r : ℝ) : ℝ := + sSup (classSectionOscillations vol lam cap x0 r) + +omit [BorelSpace M] in +lemma classSectionOscillations_nonempty {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hc : (densityDualClass vol lam cap x0).Nonempty) (r : ℝ) : + (classSectionOscillations vol lam cap x0 r).Nonempty := by + obtain ⟨uv, huv⟩ := hc + exact ⟨_, uv, huv, x0, rfl⟩ + +omit [BorelSpace M] in +lemma classSectionOscillations_bddAbove {vol : Measure M} {lam cap : ℝ} {x0 : M} + {r : ℝ} (hr : 0 ≤ r) : BddAbove (classSectionOscillations vol lam cap x0 r) := by + refine ⟨Metric.diam (univ : Set M) ^ 2, ?_⟩ + rintro _ ⟨uv, huv, x, rfl⟩ + exact sectionOscillation_le_diam_sq uv.1.continuous uv.2.continuous + (densityDualClass_isDual huv) x hr + +omit [BorelSpace M] in +lemma sectionOscillation_le_classOscillation {vol : Measure M} {lam cap : ℝ} {x0 : M} + {uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)} (huv : uv ∈ densityDualClass vol lam cap x0) + (x : M) {r : ℝ} (hr : 0 ≤ r) : + sectionOscillation uv.1 uv.2 x r ≤ classOscillation vol lam cap x0 r := by + exact le_csSup (classSectionOscillations_bddAbove hr) ⟨uv, huv, x, rfl⟩ + +omit [BorelSpace M] in +lemma classOscillation_bounds {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hc : (densityDualClass vol lam cap x0).Nonempty) {r : ℝ} (hr : 0 ≤ r) : + 0 ≤ classOscillation vol lam cap x0 r ∧ + classOscillation vol lam cap x0 r ≤ Metric.diam (univ : Set M) ^ 2 := by + constructor + · obtain ⟨uv, huv⟩ := hc + exact (sectionOscillation_nonneg uv.2.continuous (densityDualClass_isDual huv) x0 hr).trans + (sectionOscillation_le_classOscillation huv x0 hr) + · apply csSup_le (classSectionOscillations_nonempty hc r) + rintro _ ⟨uv, huv, x, rfl⟩ + exact sectionOscillation_le_diam_sq uv.1.continuous uv.2.continuous + (densityDualClass_isDual huv) x hr + +omit [BorelSpace M] in +lemma classOscillation_monotone {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hc : (densityDualClass vol lam cap x0).Nonempty) : + MonotoneOn (classOscillation vol lam cap x0) (Ici 0) := by + intro r hr R hR hrR + apply csSup_le (classSectionOscillations_nonempty hc r) + rintro _ ⟨uv, huv, x, rfl⟩ + exact (sectionOscillation_mono uv.2.continuous (densityDualClass_isDual huv) x hr hrR).trans + (sectionOscillation_le_classOscillation huv x hR) + +omit [BorelSpace M] in + +lemma exists_section_with_large_oscillation {vol : Measure M} {lam cap : ℝ} {x0 : M} + (hc : (densityDualClass vol lam cap x0).Nonempty) {r q : ℝ} + (hr : 0 ≤ r) (hq : q < classOscillation vol lam cap x0 r) : + ∃ uv ∈ densityDualClass vol lam cap x0, ∃ x y0 y1 : M, + y0 ∈ gapSection uv.1 uv.2 x r ∧ y1 ∈ gapSection uv.1 uv.2 x r ∧ + (∀ y ∈ gapSection uv.1 uv.2 x r, uv.2 y0 ≤ uv.2 y) ∧ + (∀ y ∈ gapSection uv.1 uv.2 x r, uv.2 y ≤ uv.2 y1) ∧ + sectionOscillation uv.1 uv.2 x r = uv.2 y1 - uv.2 y0 ∧ + q < uv.2 y1 - uv.2 y0 := by + obtain ⟨a, ⟨uv, huv, x, rfl⟩, ha⟩ := exists_lt_of_lt_csSup + (classSectionOscillations_nonempty hc r) hq + obtain ⟨y0, hy0, y1, hy1, hmin, hmax, heq⟩ := + sectionOscillation_extrema uv.2.continuous (densityDualClass_isDual huv) x hr + exact ⟨uv, huv, x, y0, y1, hy0, hy1, hmin, hmax, heq, heq ▸ ha⟩ + +def reverseNormalizedPair (x0 : M) (uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)) : + (M →ᵇ ℝ) × (M →ᵇ ℝ) := + (uv.2 + BoundedContinuousFunction.const M (-uv.2 x0), + uv.1 + BoundedContinuousFunction.const M (uv.2 x0)) + +omit [MeasurableSpace M] [BorelSpace M] in +lemma reverseNormalizedPair_mem {x0 : M} {uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)} + (huv : uv ∈ normalizedDualPairs x0) : + reverseNormalizedPair x0 uv ∈ normalizedDualPairs x0 := by + change (uv.2 x0 + -uv.2 x0 = 0) ∧ _ ∧ _ + refine ⟨add_neg_cancel _, ?_, ?_⟩ + · apply BoundedContinuousFunction.ext + intro x + change cTransform (fun y => uv.1 y + uv.2 x0) x = uv.2 x + -uv.2 x0 + rw [cTransform_add_const uv.1.continuous] + have hh := congrArg (fun f : M →ᵇ ℝ => f x) huv.2.2 + change cTransform uv.1 x = uv.2 x at hh + change cTransform uv.1 x - uv.2 x0 = uv.2 x + -uv.2 x0 + rw [hh] + ring + · apply BoundedContinuousFunction.ext + intro x + change cTransform (fun y => uv.2 y + -uv.2 x0) x = uv.1 x + uv.2 x0 + rw [cTransform_add_const uv.2.continuous] + have hh := congrArg (fun f : M →ᵇ ℝ => f x) huv.2.1 + change cTransform uv.2 x = uv.1 x at hh + change cTransform uv.2 x - -uv.2 x0 = uv.1 x + uv.2 x0 + rw [hh] + ring + +lemma densityDualClass_reverse {vol : Measure M} {lam cap : ℝ} (hlam : 0 < lam) + {x0 : M} {uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)} + (huv : uv ∈ densityDualClass vol lam cap x0) : + reverseNormalizedPair x0 uv ∈ densityDualClass vol lam cap x0 := by + obtain ⟨hnorm, rho0, rho1, hrho0, hrho1, hmin⟩ := huv + let := densityMeasure_probability hlam hrho0 + let := densityMeasure_probability hlam hrho1 + refine ⟨reverseNormalizedPair_mem hnorm, rho1, rho0, hrho1, hrho0, ?_⟩ + intro a b hab + have hba : ∀ x y, 0 ≤ contactGap b a x y := by + intro x y + have hh := hab y x + dsimp [contactGap] at hh ⊢ + rw [cost_symm y x] at hh + linarith + have hh := hmin b a hba + rw [reverseNormalizedPair, dualObjective_add_constants] + dsimp [dualObjective] at hh ⊢ + linarith + +omit [CompactSpace M] [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma reverseNormalizedPair_gap (x0 : M) (uv : (M →ᵇ ℝ) × (M →ᵇ ℝ)) (x y : M) : + contactGap (reverseNormalizedPair x0 uv).1 (reverseNormalizedPair x0 uv).2 x y = + contactGap uv.1 uv.2 y x := by + change (uv.2 x + -uv.2 x0) + cost x y + (uv.1 y + uv.2 x0) = _ + rw [contactGap, cost_symm y x] + ring + +end SectionOscillation + +open Filter + +lemma exists_small_step (f : ℝ → ℝ) (a h q : ℝ) {m : ℕ} (hm : 0 < m) + (hbound : f (a + m * h) - f a ≤ m * q) : + ∃ i : ℕ, i < m ∧ f (a + (i + 1) * h) - f (a + i * h) ≤ q := by + have hsum : (∑ i ∈ Finset.range m, (f (a + (i + 1) * h) - f (a + i * h))) ≤ + ∑ _i ∈ Finset.range m, q := by + have ht := Finset.sum_range_sub (fun i : ℕ => f (a + i * h)) m + simp only [Nat.cast_add, Nat.cast_one, Nat.cast_zero, zero_mul, add_zero] at ht + rw [ht] + simpa only [Finset.sum_const, Finset.card_range, nsmul_eq_mul] using hbound + obtain ⟨i, hi, hb⟩ := Finset.exists_le_of_sum_le ⟨0, Finset.mem_range.mpr hm⟩ hsum + exact ⟨i, Finset.mem_range.mp hi, hb⟩ + +lemma logarithmic_plateau_quantitative {f : ℝ → ℝ} (hmono : Monotone f) + (hzero : ∀ s, 0 ≤ f s) + (hsub : ∀ eps : ℝ, 0 < eps → ∀ L : ℝ, ∃ N : ℝ, L ≤ N ∧ f N ≤ eps * N) + {J : ℝ} (hJ : 1 ≤ J) : + ∃ A B : ℝ, J ^ 2 ≤ A ∧ B = A + J ∧ + f B - f A ≤ J⁻¹ ∧ f B ≤ A / J ^ 2 := by + have hJ0 : 0 < J := lt_of_lt_of_le zero_lt_one hJ + have hden : 0 < 4 * J ^ 2 := by positivity + obtain ⟨N, hN, hfN⟩ := hsub (4 * J ^ 2)⁻¹ (inv_pos.mpr hden) (4 * J ^ 2) + have hN0 : 0 ≤ N := (le_of_lt hden).trans hN + let m : ℕ := ⌊N / (2 * J)⌋₊ + have hmle : (m : ℝ) ≤ N / (2 * J) := Nat.floor_le (by positivity) + have hmlt : N / (2 * J) < (m : ℝ) + 1 := Nat.lt_floor_add_one _ + have hmle' : 2 * J * m ≤ N := by + have hh := (le_div_iff₀ (show 0 < 2 * J by positivity)).mp hmle + nlinarith + have hmlt' : N < 2 * J * (m + 1) := by + have hh := (div_lt_iff₀ (show 0 < 2 * J by positivity)).mp hmlt + nlinarith + have hmJ : J ≤ (m : ℝ) := by nlinarith + have hm1 : (1 : ℝ) ≤ m := hJ.trans hmJ + have hmpos : 0 < m := by exact_mod_cast (lt_of_lt_of_le zero_lt_one hm1) + have hNupper : N ≤ 4 * J * m := by nlinarith + have hfNm : f N ≤ (m : ℝ) / J := by + have hh : f N * (4 * J ^ 2) ≤ N := by + calc + f N * (4 * J ^ 2) ≤ ((4 * J ^ 2)⁻¹ * N) * (4 * J ^ 2) := + mul_le_mul_of_nonneg_right hfN hden.le + _ = N := by field_simp + apply (le_div_iff₀ hJ0).mpr + nlinarith [mul_nonneg (sub_nonneg.mpr hNupper) (show 0 ≤ J by positivity)] + have hsum : f (J * m + (m : ℝ) * J) - f (J * m) ≤ (m : ℝ) * J⁻¹ := by + have htop := hmono (show J * m + (m : ℝ) * J ≤ N by nlinarith) + have hbot := hzero (J * m) + rw [div_eq_mul_inv] at hfNm + linarith + obtain ⟨i, hi, hstep⟩ := exists_small_step f (J * m) J J⁻¹ hmpos hsum + let A := J * m + (i : ℝ) * J + let B := J * m + ((i : ℝ) + 1) * J + have hA : J ^ 2 ≤ A := by + dsimp [A] + nlinarith [Nat.cast_nonneg (α := ℝ) i] + have hB : B ≤ N := by + have hi' : (i : ℝ) + 1 ≤ m := by exact_mod_cast hi + dsimp [B] + nlinarith + refine ⟨A, B, hA, by dsimp [A, B]; ring, hstep, ?_⟩ + calc + f B ≤ f N := hmono hB + _ ≤ (m : ℝ) / J := hfNm + _ ≤ A / J ^ 2 := by + apply (div_le_div_iff₀ hJ0 (sq_pos_of_pos hJ0)).mpr + dsimp [A] + nlinarith [mul_nonneg (Nat.cast_nonneg (α := ℝ) i) (sq_nonneg J)] + +def HasPowerUpperBound (F : ℝ → ℝ) : Prop := + ∃ beta C r0 : ℝ, 0 < beta ∧ 0 < C ∧ 0 < r0 ∧ + ∀ r : ℝ, 0 < r → r < r0 → F r ≤ C * r ^ beta + +lemma log_sublinear_of_no_power {F : ℝ → ℝ} {CF : ℝ} (hCF : 0 < CF) + (hFpos : ∀ r : ℝ, 0 < r → 0 < F r) (hno : ¬ HasPowerUpperBound F) : + ∀ eps : ℝ, 0 < eps → ∀ L : ℝ, ∃ N : ℝ, L ≤ N ∧ + Real.log (CF / F (Real.exp (-N))) ≤ eps * N := by + intro eps heps L + have hbad : ∃ r : ℝ, 0 < r ∧ r < Real.exp (-L) ∧ CF * r ^ eps < F r := by + by_contra! hgood + exact hno ⟨eps, CF, Real.exp (-L), heps, hCF, Real.exp_pos _, + fun r hr hr0 => hgood r hr hr0⟩ + obtain ⟨r, hr, hr0, hbad⟩ := hbad + refine ⟨-Real.log r, ?_, ?_⟩ + · have hh := Real.log_lt_log hr hr0 + rw [Real.log_exp] at hh + linarith + · have hh := Real.log_lt_log (mul_pos hCF (Real.rpow_pos_of_pos hr eps)) hbad + rw [Real.log_mul hCF.ne' (Real.rpow_pos_of_pos hr eps).ne', Real.log_rpow hr] at hh + rw [neg_neg, Real.exp_log hr, Real.log_div hCF.ne' (hFpos r hr).ne'] + linarith + +lemma logarithmic_profile_nonneg {F : ℝ → ℝ} {CF : ℝ} + (hFpos : ∀ r : ℝ, 0 < r → 0 < F r) + (hbound : ∀ r : ℝ, 0 < r → F r ≤ CF) (s : ℝ) : + 0 ≤ Real.log (CF / F (Real.exp (-s))) := by + apply Real.log_nonneg + exact (one_le_div (hFpos _ (Real.exp_pos _))).mpr (hbound _ (Real.exp_pos _)) + +lemma logarithmic_profile_monotone {F : ℝ → ℝ} {CF : ℝ} (hCF : 0 < CF) + (hFpos : ∀ r : ℝ, 0 < r → 0 < F r) (hmono : MonotoneOn F (Ioi 0)) : + Monotone (fun s : ℝ => Real.log (CF / F (Real.exp (-s)))) := by + intro a b hab + apply Real.log_le_log (div_pos hCF (hFpos _ (Real.exp_pos _))) + exact div_le_div_of_nonneg_left hCF.le (hFpos _ (Real.exp_pos _)) + (hmono (Real.exp_pos _) (Real.exp_pos _) (Real.exp_le_exp.mpr (neg_le_neg hab))) + +lemma no_power_logarithmic_plateau {F : ℝ → ℝ} {CF : ℝ} (hCF : 0 < CF) + (hFpos : ∀ r : ℝ, 0 < r → 0 < F r) + (hbound : ∀ r : ℝ, 0 < r → F r ≤ CF) (hmono : MonotoneOn F (Ioi 0)) + (hno : ¬ HasPowerUpperBound F) {J : ℝ} (hJ : 1 ≤ J) : + ∃ A B : ℝ, J ^ 2 ≤ A ∧ B = A + J ∧ + Real.log (CF / F (Real.exp (-B))) - Real.log (CF / F (Real.exp (-A))) ≤ J⁻¹ ∧ + Real.log (CF / F (Real.exp (-B))) ≤ A / J ^ 2 := by + exact logarithmic_plateau_quantitative + (logarithmic_profile_monotone hCF hFpos hmono) + (logarithmic_profile_nonneg hFpos hbound) + (log_sublinear_of_no_power hCF hFpos hno) hJ + +lemma positive_of_no_power {F : ℝ → ℝ} (hmono : MonotoneOn F (Ioi 0)) + (hno : ¬ HasPowerUpperBound F) {r : ℝ} (hr : 0 < r) : 0 < F r := by + by_contra! hF + apply hno + refine ⟨1, 1, r, by norm_num, by norm_num, hr, ?_⟩ + intro t ht htr + have hh := hmono ht hr htr.le + simpa only [Real.rpow_one, one_mul] using hh.trans (hF.trans ht.le) + +lemma no_power_gap_scale_plateau {F : ℝ → ℝ} {CF : ℝ} (hCF : 0 < CF) + (hbound : ∀ r : ℝ, 0 < r → F r ≤ CF) (hmono : MonotoneOn F (Ioi 0)) + (hno : ¬ HasPowerUpperBound F) {J : ℝ} (hJ : 1 ≤ J) : + ∃ A : ℝ, J ^ 2 ≤ A ∧ + F (Real.exp (-A)) ≤ Real.exp J⁻¹ * F (Real.exp (-(A + J))) ∧ + |Real.log (F (Real.exp (-(A + J))))| ≤ |Real.log CF| + A / J ^ 2 := by + have hpos : ∀ r : ℝ, 0 < r → 0 < F r := fun _ hr => positive_of_no_power hmono hno hr + obtain ⟨A, B, hA, rfl, hinc, hval⟩ := + no_power_logarithmic_plateau hCF hpos hbound hmono hno hJ + have hpA := hpos (Real.exp (-A)) (Real.exp_pos _) + have hpB := hpos (Real.exp (-(A+J))) (Real.exp_pos _) + have hfnonneg := logarithmic_profile_nonneg hpos hbound (A + J) + rw [Real.log_div hCF.ne' hpB.ne', Real.log_div hCF.ne' hpA.ne'] at hinc + rw [Real.log_div hCF.ne' hpB.ne'] at hval hfnonneg + refine ⟨A, hA, ?_, ?_⟩ + · have hlog : Real.log (F (Real.exp (-A))) ≤ J⁻¹ + Real.log (F (Real.exp (-(A+J)))) := by + linarith + have hh := Real.exp_le_exp.mpr hlog + simpa only [Real.exp_add, Real.exp_log hpA, Real.exp_log hpB] using hh + · calc + |Real.log (F (Real.exp (-(A+J))))| = + |Real.log CF - (Real.log CF - Real.log (F (Real.exp (-(A+J)))))| := by ring_nf + _ ≤ |Real.log CF| + |Real.log CF - Real.log (F (Real.exp (-(A+J))))| := abs_sub _ _ + _ ≤ |Real.log CF| + A / J ^ 2 := by rw [abs_of_nonneg hfnonneg]; linarith + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Oscillation/SwitchNorms.lean b/lean/OAI/Analysis/BiholderTransport/Oscillation/SwitchNorms.lean new file mode 100644 index 0000000000000000000000000000000000000000..ef5d0e52954f15e619e24bb664d5b125de666037 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Oscillation/SwitchNorms.lean @@ -0,0 +1,184 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.LiftedSections +import OAI.Analysis.BiholderTransport.Regularity.ModifiedData +import OAI.Analysis.BiholderTransport.Regularity.RayAnchor + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section SwitchNorms +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma active_switch_norm_identity {v : M → ℝ} + {z : TangentBundle 𝓘(ℝ,Model n) M} {a D b t : ℝ} {B : ℝ → ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) (sprayFlow t z).1} + (hp : p∈activeLogs (modifiedDatum v a D b B) (sprayFlow t z).1) : + ‖p‖^2=(1-t)^2*‖z.2‖^2-2*(v (riemannianExp (sprayFlow t z).1 p)-a)- + 2*b*B ((v (riemannianExp (sprayFlow t z).1 p)-a)/D)- + 2*transformRayDifference (modifiedDatum v a D b B) z a t := by + have hc := hp.2 + rw [contactGap,cost_minimizingVector hp.1] at hc + dsimp only [modifiedDatum] at hc + dsimp only [transformRayDifference] + linarith only [hc] + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma active_switch_norm_brackets {v : M → ℝ} + {z : TangentBundle 𝓘(ℝ,Model n) M} {a D b r H t : ℝ} {B : ℝ → ℝ} + {pm pp : TangentSpace 𝓘(ℝ,Model n) (sprayFlow t z).1} + (hm : pm∈activeLogs (modifiedDatum v a D b B) (sprayFlow t z).1) + (hp : pp∈activeLogs (modifiedDatum v a D b B) (sprayFlow t z).1) + (hD : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma positive_modified_excess_at_midnorm {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} (hz : z.2∈minimizingVectors z.1) + {a D b r C d t : ℝ} {Bc Bo : ℝ → ℝ} (ho : Continuous Bo) + (ha : v (riemannianExp z.1 z.2)=a) + (hb : 0≤b) (hD : 0TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.switch_to_positive_excess (hmtw:WeakMTW (n:=n) (M:=M)) + {u v:M → ℝ} (hu:Continuous u) (hv:Continuous v) (hd:IsCostDualPair u v) + {x:M} {p q:TangentSpace 𝓘(ℝ,Model n) x} (hp:p∈minimizingVectors x) (hq:q∈minimizingVectors x) + {α D b r R H eta C d:ℝ} {Bc Bo:ℝ → ℝ} (ho:Continuous Bo) + (ha:v (riemannianExp x p)=α) (ha1:v (riemannianExp x q)=α+D) + (hb:0 < b) (hD:0 < D) (hr:0 ≤ r) (hR:0 ≤ R) (hC:0 ≤ C) + (hg0:contactGap u v x (riemannianExp x p)≤r) + (hg1:contactGap u v x (riemannianExp x q)≤r) + (hangle:‖p‖^2-inner ℝ p q≤6*D) + (heta:0 ≤ eta) (heta1:eta≤1/128) (hrb:r≤b/4) (hbD:b≤D/16) + (hob:∀s,0 ≤ Bo s ∧ Bo s≤H) (ho0:Bo 0≤1+1/1024) (ho1:Bo 1=0) + (hol:∀s≤1/16,1≤Bo s) (hbar:∀s∈Icc (1/16) (1-eta),Bo 0+1≤Bo s) + (hc0:∀s,-1≤Bc s) (hc1:∀s≤1/2,1-1/1024≤Bc s) + (hsmall:‖((8*b/D):ℝ) • p‖(hob s).1) ho02 ho1 hol hbar hg0' hg1' + have ht0:0 ≤ t:=ht.1.le + have ht1:t≤1/2:=ht.2.trans hT1 + have htt:t^2≤T^2:=sq_le_sq₀ ht0 hT.le |>.mpr ht.2 + have hTp:‖t • p‖ TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma lipschitz_ae_mdifferentiableAt {f : M → ℝ} {K : ℝ≥0} + (hf : LipschitzWith K f) : + ∀ᵐ x ∂metricVolume (M := M) n, MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x := by + have hlocal : ∀ x∈(univ : Set M), ∃ U : Set M, IsOpen U ∧ x∈U ∧ + (∀ᵐ z ∂metricVolume (M := M) n, z∈U → MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f z) := by + intro x _ + obtain ⟨C,r,hr,htarget,hLip⟩ := exists_lipschitz_inverse_chart (n := n) x + let d := extChartAt 𝓘(ℝ,Model n) x + let B := ball (d x) r + let U := d.source ∩ d ⁻¹' B + have hU : IsOpen U := (continuousOn_extChartAt x).isOpen_inter_preimage + (isOpen_extChartAt_source x) isOpen_ball + refine ⟨U,hU,⟨mem_extChartAt_source x,mem_ball_self hr⟩,?_⟩ + let μ : Measure (Model n) := Measure.hausdorffMeasure (n:ℝ) + have hdim : Module.finrank ℝ (Model n)=n := by simp [Model] + have : μ.IsAddHaarMeasure := by + dsimp only [μ] + rw [←hdim] + infer_instance + have hR := (hf.comp_lipschitzOnWith hLip).ae_differentiableWithinAt_of_mem (μ := μ) + let N := {q : Model n | q∈B ∧ ¬DifferentiableAt ℝ (f ∘ d.symm) q} + have hN : μ N=0 := by + apply measure_mono_null _ (ae_iff.mp hR) + intro q hq + change ¬(q∈B → DifferentiableWithinAt ℝ (f ∘ d.symm) B q) + intro hh + exact hq.2 ((hh hq.1).differentiableAt (isOpen_ball.mem_nhds hq.1)) + have hNsub : N⊆B := fun _ h => h.1 + have hImage : (Measure.hausdorffMeasure (n:ℝ) : Measure M) (d.symm '' N)=0 := by + apply le_antisymm _ (show (0:ℝ≥0∞)≤_ from zero_le) + have H := (hLip.mono hNsub).hausdorffMeasure_image_le (d := (n:ℝ)) (by positivity) + change _ ≤ (C : ℝ≥0∞)^(n:ℝ)*μ N at H + simpa only [d,hN,mul_zero] using H + have hImageVol : metricVolume (M := M) n (d.symm '' N)=0 := by + simp only [metricVolume,Measure.smul_apply,smul_eq_mul,hImage,mul_zero] + apply ae_iff.mpr + apply measure_mono_null _ hImageVol + intro z hz + have hz' : z∈U ∧ ¬MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f z := by + simpa only [mem_ofPred_eq,Classical.not_imp] using hz + refine ⟨d z,⟨hz'.1.2,?_⟩,d.left_inv hz'.1.1⟩ + intro hD + have hChart := mdifferentiableAt_extChartAt (I := 𝓘(ℝ,Model n)) + (show z∈(chartAt (Model n) x).source by simpa only [d,extChartAt_source] using hz'.1.1) + have H := hD.hasFDerivAt.hasMFDerivAt.comp z hChart.hasMFDerivAt + apply hz'.2 + apply (H.congr_of_eventuallyEq _).mdifferentiableAt + filter_upwards [(isOpen_extChartAt_source x).mem_nhds hz'.1.1] with w hw + change f w=f (d.symm (d w)) + rw [d.left_inv hw] + simpa only [mem_univ,true_implies] using ae_of_locally_ae (metricVolume (M := M) n) hlocal + +variable [CompactSpace M] [Nonempty M] +lemma cTransform_ae_mdifferentiableAt {v : M → ℝ} (hv : Continuous v) : + ∀ᵐ x ∂metricVolume (M := M) n, + MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (cTransform v) x := by + exact lipschitz_ae_mdifferentiableAt (cTransform_lipschitz hv + (D := ⟨Metric.diam (univ : Set M),Metric.diam_nonneg⟩) (fun x y => + Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y))) + +end AERademacher +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActionKernel.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActionKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..55ff61882d882a9e05d8a358fb0fd8efc4fb1ae6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActionKernel.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.GeneratingKernel + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +section +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +local instance actionKernelDualNormedAddCommGroup : NormedAddCommGroup (F →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance actionKernelDualNormedSpace : NormedSpace ℝ (F →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace +local instance actionKernelBilinearNormedAddCommGroup : NormedAddCommGroup (F →L[ℝ] F →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup +local instance actionKernelBilinearNormedSpace : NormedSpace ℝ (F →L[ℝ] F →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedSpace + +lemma generating_kernel_velocity_zero {B : E×F → ℝ} {Q V : E → F} + {g : F → F →L[ℝ] F →L[ℝ] ℝ} {R : F → F →L[ℝ] ℝ} {p w : E} + (hB : ContDiffAt ℝ 2 B (p,Q p)) (hmin : IsLocalMin B (p,Q p)) + (hQ : DifferentiableAt ℝ Q p) (hV : DifferentiableAt ℝ V p) + (hg : DifferentiableAt ℝ g (Q p)) (hR : DifferentiableAt ℝ R (Q p)) + (hpos : ∀ u : F, u ≠ 0 → 0 < g (Q p) u u) + (hstat : ∀ᶠ v in 𝓝 p, ∀ a : E, fderiv ℝ B (v,Q v) (a,0) = 0) + (hcot : ∀ᶠ v in 𝓝 p, ∀ u : F, + fderiv ℝ B (v,Q v) (0,u) = g (Q v) (V v) u + R (Q v) u) + (hker : fderiv ℝ Q p w = 0) : fderiv ℝ V p w = 0 := by + have hz (u : F) : g (Q p) (fderiv ℝ V p w) u = 0 := by + have heq : (fun v => fderiv ℝ B (v,Q v) (0,u)) =ᶠ[𝓝 p] + fun v => g (Q v) (V v) u + R (Q v) u := hcot.mono (fun _ hv => hv u) + have hd := ((((hg.hasFDerivAt.comp p hQ.hasFDerivAt).clm_apply hV.hasFDerivAt).clm_apply + (hasFDerivAt_const u p)).add + ((hR.hasFDerivAt.comp p hQ.hasFDerivAt).clm_apply (hasFDerivAt_const u p))).fderiv + change fderiv ℝ (fun v => g (Q v) (V v) u + R (Q v) u) p = _ at hd + have hh := localMin_generating_cotangent_kernel hB hmin hQ hstat hker u + rw [heq.fderiv_eq,hd] at hh + simpa [hker] using hh + by_contra hn + exact (hpos _ hn).ne' (hz _) + +lemma generating_graph_position_immersion {B : E×F → ℝ} {Q V : E → F} + {g : F → F →L[ℝ] F →L[ℝ] ℝ} {R : F → F →L[ℝ] ℝ} {p : E} + (hB : ContDiffAt ℝ 2 B (p,Q p)) (hmin : IsLocalMin B (p,Q p)) + (hQ : DifferentiableAt ℝ Q p) (hV : DifferentiableAt ℝ V p) + (hg : DifferentiableAt ℝ g (Q p)) (hR : DifferentiableAt ℝ R (Q p)) + (hpos : ∀ u : F, u ≠ 0 → 0 < g (Q p) u u) + (hstat : ∀ᶠ v in 𝓝 p, ∀ a : E, fderiv ℝ B (v,Q v) (a,0) = 0) + (hcot : ∀ᶠ v in 𝓝 p, ∀ u : F, + fderiv ℝ B (v,Q v) (0,u) = g (Q v) (V v) u + R (Q v) u) + (himm : Function.Injective (fderiv ℝ (fun v => (Q v,V v)) p)) : + Function.Injective (fderiv ℝ Q p) := by + intro u v huv + have hw : fderiv ℝ Q p (u-v) = 0 := by rw [map_sub,huv,sub_self] + have hv := generating_kernel_velocity_zero hB hmin hQ hV hg hR hpos hstat hcot hw + apply sub_eq_zero.mp + apply himm + rw [(hQ.hasFDerivAt.prodMk hV.hasFDerivAt).fderiv] + simp [hw,hv] + +end + +lemma weighted_square_le (a b : ℝ) {s t : ℝ} (hs : 0 TangentSpace 𝓘(ℝ,E) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,E) ∞ E (fun x : M => TangentSpace 𝓘(ℝ,E) x)] + [IsRiemannianManifold 𝓘(ℝ,E) M] + +lemma exists_two_short_legs (x : M) (p : TangentSpace 𝓘(ℝ,E) x) + {t T δ : ℝ} (ht : 0 dist b (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1^2/2) + (sprayFlow (t-ε) (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1 + (innerSL ℝ ((-ε) • (sprayFlow (t-ε) (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).2)) ∧ + HasMFDerivAt 𝓘(ℝ,E) 𝓘(ℝ,ℝ) + (fun q => dist (sprayFlow (t-ε) (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1 q^2/2) + (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).1 + (innerSL ℝ (ε • (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,E) M)).2)) := by + let a := sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M) + obtain ⟨δs,hδs,Hs⟩ := exists_local_spray_cost_start_gradient (E := E) a.1 + obtain ⟨δe,hδe,He⟩ := exists_local_spray_cost_gradient (E := E) a.1 + let r := min δ (min δs δe) + have hr : 0 + (⟨x,u.2⟩ : TangentBundle 𝓘(ℝ,E) M)) := + (contMDiff_fiber_embedding x).continuous.comp continuous_snd + let F : ℝ × TangentSpace 𝓘(ℝ,E) x → TangentBundle 𝓘(ℝ,E) M := + fun u => sprayFlow (t-u.1) ⟨x,u.2⟩ + have hF : Continuous F := contMDiff_sprayFlow.continuous.comp + ((continuous_const.sub continuous_fst).prodMk hι) + have hF₀ : F (0,p)=a := by simp [F,a] + have hpr : Continuous (fun z : TangentBundle 𝓘(ℝ,E) M => z.1) := + FiberBundle.continuous_proj E (fun b : M => TangentSpace 𝓘(ℝ,E) b) + have hFin := (hpr.comp hF).continuousAt.preimage_mem_nhds + (show Metric.ball a.1 r ∈ 𝓝 (F (0,p)).1 by rw [hF₀]; exact Metric.ball_mem_nhds _ hr) + have hQ : Continuous (fun u : ℝ × TangentSpace 𝓘(ℝ,E) x => + (sprayFlow t (⟨x,u.2⟩ : TangentBundle 𝓘(ℝ,E) M)).1) := + hpr.comp ((contMDiff_spray_fiber x t).continuous.comp continuous_snd) + have hQin := (hQ.continuousAt (x := (0,p))).preimage_mem_nhds (Metric.ball_mem_nhds a.1 hr) + have hY : Continuous (fun u : ℝ × TangentSpace 𝓘(ℝ,E) x => + (sprayFlow (t+u.1) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1) := + hpr.comp (contMDiff_sprayFlow.continuous.comp + ((continuous_const.add continuous_fst).prodMk continuous_const)) + have hYin := (hY.continuousAt (x := (0,p))).preimage_mem_nhds + (show Metric.ball a.1 r ∈ 𝓝 (sprayFlow (t+(0:ℝ)) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 by + simpa only [add_zero] using Metric.ball_mem_nhds a.1 hr) + have htend : Tendsto (fun u : ℝ × TangentSpace 𝓘(ℝ,E) x => (u.1,F u)) (𝓝 (0,p)) (𝓝 (0,a)) := by + simpa only [ContinuousAt,hF₀] using (continuous_fst.prodMk hF).continuousAt (x := (0,p)) + have hmin := htend.eventually (sprayFlow_uniformly_short_minimizing a) + have hAll : ∀ᶠ u : ℝ × TangentSpace 𝓘(ℝ,E) x in 𝓝 (0,p), + (F u).1 ∈ Metric.ball a.1 r ∧ + (sprayFlow t (⟨x,u.2⟩ : TangentBundle 𝓘(ℝ,E) M)).1 ∈ Metric.ball a.1 r ∧ + (sprayFlow (t+u.1) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,E) M)).1 ∈ Metric.ball a.1 r ∧ + dist (F u).1 (sprayFlow u.1 (F u)).1 = |u.1| *‖(F u).2‖ := by + filter_upwards [hFin,hQin,hYin,hmin] with u h₁ h₂ h₃ h₄ + exact ⟨h₁,h₂,h₃,h₄⟩ + obtain ⟨A,hA,B,hB,hAB⟩ := mem_nhds_prod_iff.mp hAll + obtain ⟨η,hη,hηA⟩ := Metric.mem_nhds_iff.mp hA + let ε := min η (min t (T-t))/2 + have hε : 0<ε := div_pos (lt_min hη (lt_min ht (sub_pos.mpr hT))) (by norm_num) + have hεη : ε<η := lt_of_lt_of_le (half_lt_self (lt_min hη (lt_min ht (sub_pos.mpr hT)))) (min_le_left _ _) + have hεt : ε pj i-p))≠⊥ := by + intro H + have hpj : ∀ i,pj i=p := by + intro i + have HH := (Submodule.subset_span (mem_range_self i) : + pj i-p∈Submodule.span ℝ (range (fun i => pj i-p))) + rw [H] at HH + exact sub_eq_zero.mp HH + simp_rw [hpj] at hparameter + rw [←Finset.sum_mul,hsum,one_mul] at hparameter + linarith + +omit [DecidableEq ι] in +lemma line_active_displacements {pj : ι → E} {p e : E} {m : ι → ℝ} + (hline : Submodule.span ℝ (range (fun i => pj i-p))=Submodule.span ℝ {e}) + (he : e≠0) (hsum : ∑ i,m i=1) (hbar : ∑ i,m i • pj i=p) : + ∃ d : ι → ℝ, (∀ i,pj i=p+d i • e) ∧ ∑ i,m i*d i=0 := by + have H : ∀ i,∃ r:ℝ,r • e=pj i-p := by + intro i + apply Submodule.mem_span_singleton.mp + rw [←hline] + exact Submodule.subset_span (mem_range_self i) + choose d hd using H + have hd' : ∀ i,pj i=p+d i • e := by + intro i + rw [hd i,add_sub_cancel] + refine ⟨d,hd',?_⟩ + have Hbar : (∑ i,m i*d i) • e=0 := by + rw [Finset.sum_smul] + simp_rw [mul_smul,hd,smul_sub] + rw [Finset.sum_sub_distrib,←Finset.sum_smul,hsum,one_smul,hbar,sub_self] + exact (smul_eq_zero.mp Hbar).resolve_right he + +end ActiveDifference +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set +open scoped BigOperators + +namespace WeakMTWTransport +section OutwardGeometry +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma norm_increment_unit_line {p e : E} (he : ‖e‖=1) (d : ℝ) : + ‖p+d • e‖^2-‖p‖^2=2*(inner ℝ p e)*d+d^2 := by + have hee : inner ℝ e e=1 := by rw [real_inner_self_eq_norm_sq,he]; norm_num + rw [←real_inner_self_eq_norm_sq] + simp only [inner_add_left,inner_add_right,real_inner_smul_left,inner_smul_right, + real_inner_comm e p,hee,real_inner_self_eq_norm_sq] + ring + +lemma outward_active_endpoint {ι : Type*} [Fintype ι] [DecidableEq ι] + {n : ℕ} (hn : Fintype.card ι ≤ n+1) {pj : ι → E} {p e : E} + {m B si : ι → ℝ} {D c eta delta zeta s center a0 : ℝ} + (hm : ∀ i,0 < m i) (hsum : ∑ i,m i=1) (hbar : ∑ i,m i • pj i=p) + (he : ‖e‖=1) (hq : 0 < inner ℝ p e) + (hline : Submodule.span ℝ (range (fun i => pj i-p))=Submodule.span ℝ {e}) + (hD : 0 < D) (hc : 0 < c) (ha0 : 0 < a0) (hqa : a0*D ≤ (inner ℝ p e)^2) + (heta : eta ≤ 1/128) (hdelta : delta ≤ zeta) (hzeta : zeta ≤ 1/16) + (hs : s < 3/4) (hlow : ∀ i,-2*eta ≤ si i) + (hrange : ∀ i,|si i-s| ≤ 1+delta) + (hnorm : ∀ i,|‖pj i‖^2-‖p‖^2+2*D*(si i-s)| ≤ zeta*D) + (hB : ∀ i,0 ≤ B i) (hleft : ∀ i,si i < 1-eta → 1 ≤ B i) + (hcenter : center ≤ 1) (hparameter : c ≤ center-∑ i,m i*B i) : + let mstar := c/(12*(n+1:ℝ)) + let theta0 := min (mstar/2) (a0/3) + ∃ i d, 0 < d ∧ pj i=p+d • e ∧ mstar ≤ m i ∧ + c*D/(8*(n+1:ℝ)*(inner ℝ p e)) ≤ m i*d ∧ + d ≤ 3*D/(2*(inner ℝ p e)) ∧ -2*eta ≤ si i ∧ si i < 1-eta ∧ + B i ≤ 12*(n+1:ℝ)/c ∧ 0 < theta0 ∧ + ∀ theta∈Icc (-theta0) 1, + p+theta • (pj i-p)∈convexHull ℝ (range pj) ∧ + (inner ℝ p e)/2 ≤ inner ℝ (p+theta • (pj i-p)) e ∧ + ‖pj i-p‖^2/(inner ℝ (p+theta • (pj i-p)) (pj i-p)) ≤ 3/a0 := by + intro mstar theta0 + have he0 : e≠0 := by intro H; rw [H,norm_zero] at he; norm_num at he + obtain ⟨d,hd,hbard⟩ := line_active_displacements hline he0 hsum hbar + have hnorm' : ∀ i,|2*(inner ℝ p e)*d i+d i^2+2*D*(si i-s)| ≤ zeta*D := by + intro i + have H := hnorm i + rwa [hd i,norm_increment_unit_line he (d i)] at H + obtain ⟨i,hdi,hmi,hprod,hdub,hli,hri,hBi⟩ := outward_from_levels hn hm hsum hbard hq hD hc + heta hdelta hzeta hs hlow hrange hnorm' hB hleft hcenter hparameter + have hmstar : 0 < mstar := by dsimp [mstar]; positivity + have ht0 : 0 < theta0 := lt_min (half_pos hmstar) (by positivity) + refine ⟨i,d i,hdi,hd i,hmi,hprod,hdub,hli,hri,hBi,ht0,?_⟩ + intro theta htheta + have hlowtheta : -m i/2 ≤ theta := by + have HH : theta0 ≤ mstar/2 := min_le_left _ _ + linarith only [htheta.1,HH,hmi] + have hthetaa : -a0/3 ≤ theta := by + have HH : theta0 ≤ a0/3 := min_le_right _ _ + linarith only [htheta.1,HH] + have Hconv := barycenter_opposite_extension pj m (fun j => (hm j).le) hsum i hlowtheta htheta.2 + rw [hbar] at Hconv + have hpie : pj i-p=d i • e := by rw [hd i]; module + have hee : inner ℝ e e=1 := by rw [real_inner_self_eq_norm_sq,he]; norm_num + have Hrad := outward_radial_ratio hq ha0 hdi hqa hdub hthetaa + refine ⟨Hconv,?_,?_⟩ + · simpa only [hpie,inner_add_left,real_inner_smul_left,hee,mul_one] using Hrad.1 + · have Hn : ‖pj i-p‖^2=d i^2 := by + rw [hpie,norm_smul,he,mul_one,Real.norm_eq_abs,sq_abs] + have Hi : inner ℝ (p+theta • (pj i-p)) (pj i-p)= + (inner ℝ p e+theta*d i)*d i := by + rw [hpie] + simp only [inner_add_left,inner_smul_right,real_inner_smul_left,hee] + ring + rw [Hn,Hi] + exact Hrad.2 + +end OutwardGeometry +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveGraphLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveGraphLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9c8b42fbf57335624f46a0e244d2a3b446e3127 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveGraphLimit.lean @@ -0,0 +1,25 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.UniformEnvelope + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + +lemma chartFiberInverse_at_center (a : M) (p : Model n) : + chartFiberInverse a ((extChartAt 𝓘(ℝ,Model n) a) a) p=p := by + dsimp only [chartFiberInverse] + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] + rw [TangentBundle.symmL_trivializationAt_eq_core (mem_chart_source (Model n) a)] + exact tangentCoordChange_self (I := 𝓘(ℝ,Model n)) (mem_extChartAt_source a) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..7a8a0741189c09679fc3b6ea945150103b5dd15d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActiveLimit.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.CompactConfigurations +import OAI.Analysis.BiholderTransport.Regularity.FiniteSimplexRepresentation + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma fixed_simplex_representation {E : Type*} [AddCommGroup E] [Module ℝ E] + [FiniteDimensional ℝ E] {S : Set E} {x : E} (hx : x∈convexHull ℝ S) : + ∃ z : Fin (Module.finrank ℝ E+1) → E, ∃ w : Fin (Module.finrank ℝ E+1) → ℝ, + (∀ i,z i∈S) ∧ (∀ i,0≤w i) ∧ ∑ i,w i=1 ∧ ∑ i,w i • z i=x := by + classical + obtain ⟨m,hm,hN,z,w,hz,hw,hs,hb⟩ := finite_simplex_representation hx + obtain ⟨r,he⟩ := Nat.exists_eq_add_of_le hN + rw [he] + refine ⟨Fin.addCases z (fun _ : Fin r => z ⟨0,hm⟩), + Fin.addCases w (fun _ : Fin r => 0),?_,?_,?_,?_⟩ + · intro i + refine Fin.addCases (fun j=>?_) (fun j=>?_) i + · simpa only [Fin.addCases_left] using hz j + · simpa only [Fin.addCases_right] using hz ⟨0,hm⟩ + · intro i + refine Fin.addCases (fun j=>?_) (fun j=>?_) i + · simpa only [Fin.addCases_left] using hw j + · simp only [Fin.addCases_right,le_refl] + · simpa only [Fin.sum_univ_add,Fin.addCases_left,Fin.addCases_right,Finset.sum_const_zero, + add_zero] using hs + · simpa only [Fin.sum_univ_add,Fin.addCases_left,Fin.addCases_right,zero_smul, + Finset.sum_const_zero,add_zero] using hb + +lemma compact_barycentric_limit {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] [FiniteDimensional ℝ E] {C : Set (E×E)} (hC : IsCompact C) + {a v : ℕ → E} {a₀ v₀ : E} (ha : Tendsto a atTop (𝓝 a₀)) + (hv : Tendsto v atTop (𝓝 v₀)) + (hrep : ∀ k,v k∈convexHull ℝ {p | (a k,p)∈C}) : + ∃ z : ℕ → Fin (Module.finrank ℝ E+1) → E, + ∃ w : ℕ → Fin (Module.finrank ℝ E+1) → ℝ, + ∃ z₀ : Fin (Module.finrank ℝ E+1) → E, + ∃ w₀ : Fin (Module.finrank ℝ E+1) → ℝ, + ∃ σ : ℕ → ℕ, StrictMono σ ∧ + (∀ k,(∀ i,(a k,z k i)∈C) ∧ (∀ i,0≤w k i) ∧ + ∑ i,w k i=1 ∧ ∑ i,w k i • z k i=v k) ∧ + Tendsto (z ∘ σ) atTop (𝓝 z₀) ∧ Tendsto (w ∘ σ) atTop (𝓝 w₀) ∧ + (∀ i,(a₀,z₀ i)∈C) ∧ (∀ i,0≤w₀ i) ∧ ∑ i,w₀ i=1 ∧ ∑ i,w₀ i • z₀ i=v₀ := by + classical + choose z w hz hw hs hb using (fun k=>fixed_simplex_representation (hrep k)) + let d : ℕ → EnvelopeData E (Fin (Module.finrank ℝ E+1)) := + fun k=>((a k,z k),(w k,0)) + have hcompact := compact_common_base_configurations + (ι := Fin (Module.finrank ℝ E+1)) hC 0 + have hd : ∀ k,d k∈{q : EnvelopeData E (Fin (Module.finrank ℝ E+1)) | + (∀ i,(q.1.1,q.1.2 i)∈C) ∧ (∀ i,0≤q.2.1 i) ∧ ∑ i,q.2.1 i=1 ∧ q.2.2∈Icc 0 0} := + fun k=>⟨hz k,hw k,hs k,le_refl _,le_refl _⟩ + obtain ⟨q,hq,σ,hσ,hlim⟩ := hcompact.tendsto_subseq hd + have ha' : Tendsto (a ∘ σ) atTop (𝓝 q.1.1) := hlim.fst_nhds.fst_nhds + have hae : q.1.1=a₀ := tendsto_nhds_unique ha' (ha.comp hσ.tendsto_atTop) + refine ⟨z,w,q.1.2,q.2.1,σ,hσ,(fun k=>⟨hz k,hw k,hs k,hb k⟩), + hlim.fst_nhds.snd_nhds,hlim.snd_nhds.fst_nhds,?_,hq.2.1,hq.2.2.1,?_⟩ + · simpa only [hae] using hq.1 + · have hsum : Tendsto (fun k=>∑ i,w (σ k) i • z (σ k) i) atTop + (𝓝 (∑ i,q.2.1 i • q.1.2 i)) := by + apply tendsto_finsetSum + intro i _ + exact ((tendsto_pi_nhds.mp hlim.snd_nhds.fst_nhds) i).smul + ((tendsto_pi_nhds.mp hlim.fst_nhds.snd_nhds) i) + simp only [hb] at hsum + exact tendsto_nhds_unique hsum (hv.comp hσ.tendsto_atTop) + +lemma positive_barycentric_restriction {E : Type*} [AddCommGroup E] [Module ℝ E] + {ι : Type*} [Fintype ι] (p : ι → E) (w : ι → ℝ) + (hw : ∀ i,0≤w i) (hs : ∑ i,w i=1) : + let κ := {i : ι // 000w i • f i)] + exact Finset.sum_subset (Finset.filter_subset _ _) (by + intro i hi hn + have hi0 : w i=0 := le_antisymm (not_lt.mp (by simpa using hn)) (hw i) + simp only [hi0,zero_smul]) + have hr (f : ι → ℝ) : (∑ i:{i : ι // 000w i*f i)] + exact Finset.sum_subset (Finset.filter_subset _ _) (by + intro i hi hn + have hi0 : w i=0 := le_antisymm (not_lt.mp (by simpa using hn)) (hw i) + simp only [hi0,zero_mul]) + have hsum : (∑ i:{i : ι // 01)).trans (by simpa only [mul_one] using hs) + refine ⟨?_,hsum,he p,hr⟩ + by_contra hn + have : IsEmpty {i : ι // 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.active_outer_nonconjugate (hmtw:WeakMTW (n := n) (M := M)) + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {x0:M} + {uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)} (huv:uv∈densityDualClass (metricVolume n) lam cap x0) + {φ:ℝ → ℝ} (hφc:Continuous φ) (hmono:StrictMono φ) + {z:TangentBundle 𝓘(ℝ,Model n) M} + (ha:z.2∈activeLogs (φ ∘ uv.2) z.1) + (hφ:ContDiffAt ℝ 2 φ (uv.2 (riemannianExp z.1 z.2))) + {l:ℝ} (hd:HasDerivAt φ l (uv.2 (riemannianExp z.1 z.2))) (hl:1 < l) + (hconc:iteratedDeriv 2 φ (uv.2 (riemannianExp z.1 z.2)) ≤ 0) : + Function.Injective (fderiv ℝ (fun v=>extChartAt 𝓘(ℝ,Model n) + (riemannianExp z.1 z.2) (riemannianExp z.1 v)) z.2) := by + let w:=reverseRay z + let vu:=reverseNormalizedPair x0 uv + let ψ:=fun s:ℝ=>φ (uv.2 x0+s) + have hnorm (y:M):uv.2 x0+vu.1 y=uv.2 y := by + change uv.2 x0+(uv.2 y+-uv.2 x0)=uv.2 y + ring + have hbase:uv.2 x0+vu.1 w.1=uv.2 (riemannianExp z.1 z.2) := by + rw [hnorm,show w.1=riemannianExp z.1 z.2 from reverseRay_base z] + have hψ:ContDiffAt ℝ 2 ψ (vu.1 w.1) := by + exact (hbase.symm ▸ hφ).comp _ (contDiffAt_const.add contDiffAt_id) + have hψD:HasDerivAt ψ l (vu.1 w.1) := by + have hd':HasDerivAt φ l (uv.2 x0+vu.1 w.1) := hbase.symm ▸ hd + have H:=hd'.comp (vu.1 w.1) ((hasDerivAt_id (vu.1 w.1)).const_add (uv.2 x0)) + simpa only [mul_one,Function.comp_def,ψ] using H + have hψC:iteratedDeriv 2 ψ (vu.1 w.1) ≤ 0 := by + dsimp only [ψ] + rw [iteratedDeriv_comp_const_add] + dsimp only + rw [hbase] + exact hconc + have hψmono:StrictMono ψ := fun _ _ h=>hmono (by linarith) + have hm:∀y:M,ψ (vu.1 w.1)+cost w.1 (riemannianExp w.1 w.2)- + cost y (riemannianExp w.1 w.2) ≤ ψ (vu.1 y) := by + intro y + have H:=((activeLogs_iff_minimum (hφc.comp uv.2.continuous)).mp ha).2 y + dsimp only [Function.comp_apply] at H + dsimp only [ψ] + rw [hnorm,hnorm,show riemannianExp w.1 w.2=z.1 from reverseRay_endpoint z, + show w.1=riemannianExp z.1 z.2 from reverseRay_base z,cost_symm _ z.1,cost_symm y z.1] + linarith only [H] + have H:=hmtw.modified_outer_nonconjugate hlam hcap (densityDualClass_reverse hlam huv) + (reverseRay_minimizing ha.1) hψmono hψ hψD hl hψC hm + have H':=reverseRay_nonconjugate w H + have hw:reverseRay w=z := reverseRay_involutive z + rw [hw] at H' + exact H' + +end ActiveOuter +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualCenterRay.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualCenterRay.lean new file mode 100644 index 0000000000000000000000000000000000000000..0be0070bf2f41b2c6eaa3b85d5167b23ca0b860f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualCenterRay.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CoordinateSupportGradient + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.exists_center_ray_of_minimizer (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) {L : ℝ≥0} (hv : LipschitzWith L v) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hφc : Continuous φ) + {y z : M} {l τ : ℝ} (hφ : HasDerivAt φ l (v y)) (hl : 0φ (v a)) z=φ (v y)+cost y z/τ) : + ∃ r : TangentSpace 𝓘(ℝ,Model n) y, + τ • r∈injectivityDomain y ∧ riemannianExp y (τ • r)=z ∧ + l⁻¹ • r∈minimizingVectors y ∧ + contactGap v u y (riemannianExp y (l⁻¹ • r))=0 ∧ r∈injectivityDomain y := by + obtain ⟨q,hq,hqz⟩ := exists_minimizing_vector (n := n) y z + let r := τ⁻¹ • q + have hsub : r∈normalSubdifferential (fun a=>φ (v a)) y := by + apply global_min_divided_cost_subgradient hq hτ + intro a + rw [hqz,←hval] + exact hopfLax_le (hφc.comp hv.continuous) τ z a + have H := hmtw.subgradient_dual_contact hv.continuous hu ⟨hdual.2,hdual.1⟩ + (scalar_normalSubdifferential_inv hv hφ hl hsub) + have hr : r∈injectivityDomain y := by + have HR := contracted_minimizer_mem_injectivityDomain H.1 hl hl1 + simpa only [smul_smul,mul_inv_cancel₀ hl.ne',one_smul] using HR + refine ⟨r,contracted_minimizer_mem_injectivityDomain + (injectivityDomain_subset_minimizingVectors y hr) hτ hτ1,?_,H.1,H.2,hr⟩ + simpa only [r,smul_smul,mul_inv_cancel₀ hτ.ne',one_smul] using hqz + +lemma WeakMTW.exists_center_coordinate_support (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) {L : ℝ≥0} (hv : LipschitzWith L v) + (hdual : IsCostDualPair u v) {φ : ℝ → ℝ} (hφc : Continuous φ) (hmono : Monotone φ) + {a : M} {b : Model n} (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + {z : M} {l τ : ℝ} (hφ : HasDerivAt φ l (v ((extChartAt 𝓘(ℝ,Model n) a).symm b))) + (hl : 0φ (v y)) z=φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm b))+ + cost ((extChartAt 𝓘(ℝ,Model n) a).symm b) z/τ) : + ∃ p : Model n, + let y := (extChartAt 𝓘(ℝ,Model n) a).symm b + let A := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ y + let ψ := fun w=>coordinateScalarSupport a φ (((v y,(1+l)/2),(b,p)),w) + A p∈minimizingVectors y ∧ contactGap v u y (movingNormal a (b,p))=0 ∧ + l • A p∈injectivityDomain y ∧ riemannianExp y ((τ*l) • A p)=z ∧ + (∀ w,ψ w≤φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm w))) ∧ + ψ b=φ (v y) ∧ shortForward a ψ (τ,b)=extChartAt 𝓘(ℝ,Model n) a z := by + obtain ⟨r,hr,hrz,hpm,hpc,hrreg⟩ := + hmtw.exists_center_ray_of_minimizer hu hv hdual hφc hφ hl hl1 hτ hτ1 hval + have hmin : IsLocalMin (fun y=>φ (v y)+cost y + (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) (τ • r))/τ) + ((extChartAt 𝓘(ℝ,Model n) a).symm b) := by + apply Filter.Eventually.of_forall + intro y + dsimp only + rw [hrz,←hval] + exact hopfLax_le (hφc.comp hv.continuous) τ z y + obtain ⟨p,hs,hs1,hp,hpm,hpc,hbelow,htouch,hZ⟩ := + hmtw.exists_actual_center_support hu hv hdual hmono hb hφ hl hl1 hτ.ne' hr hmin + refine ⟨p,?_,hpc,?_,?_,hbelow,htouch,?_⟩ + · rwa [hp] + · simpa only [hp,smul_smul,mul_inv_cancel₀ hl.ne',one_smul] using hrreg + · rw [hp,smul_smul,show τ*l*l⁻¹=τ by field_simp] + exact hrz + · rwa [hrz] at hZ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualLevels.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualLevels.lean new file mode 100644 index 0000000000000000000000000000000000000000..f533b5f02b3c51bfbea4b766b7b9a4d7fae7f6f4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualLevels.lean @@ -0,0 +1,129 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.SectionOscillation +import OAI.Analysis.BiholderTransport.Regularity.TemplateRightWeight +import OAI.Analysis.BiholderTransport.Regularity.ModifiedData + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ActualLevels +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma contact_of_global_support {g : M → ℝ} (hg : Continuous g) {x y : M} + (hs : ∀ a,g x+cost x y ≤ g a+cost a y) : + contactGap g (cTransform g) x y=0 := by + have hupper : cTransform g y ≤ -g x-cost x y := by + rw [cTransform_le_iff hg] + intro a + rw [cost_symm y a] + linarith only [hs a] + have hlower := cTransform_gap_nonneg hg y x + rw [contactGap,cost_symm y x] at hlower + dsimp only [contactGap] + linarith only [hupper,hlower] + +lemma WeakMTW.modified_aligned_levels (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {a D b H : ℝ} {Bc Bo : ℝ → ℝ} (ho : Continuous Bo) (hb : 0 ≤ b) + (hob : ∀ s,0 ≤ Bo s ∧ Bo s ≤ H) (hcb : ∀ s,-1 ≤ Bc s ∧ Bc s ≤ 1) + {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ convexHull ℝ (activeLogs (modifiedDatum v a D b Bo) x)) : + let y := riemannianExp x p + y ∈ gapSection u v x ((H+2)*b) ∧ + ∀ pi ∈ activeLogs (n := n) (modifiedDatum v a D b Bo) x, + riemannianExp x pi ∈ gapSection u v x ((H+2)*b) ∧ + v (riemannianExp x pi)-v y=(‖p‖^2-‖pi‖^2)/2+ + b*(Bc ((v y-a)/D)-Bo ((v (riemannianExp x pi)-a)/D))- + modifiedExcess v a D b Bc Bo y := by + dsimp only + have hw := continuous_modifiedDatum hv a D b ho + obtain ⟨hpm,hs⟩ := hmtw.active_hull_global_support hw hp + have hcontact := contact_of_global_support (continuous_cTransform hw) hs + have he := modified_excess_at_contact (Bc := Bc) hcontact + have hupp := modified_excess_upper (a := a) (D := D) hu hv hdual ho hb (fun s=>(hob s).1) + (fun s=>(hcb s).2) (riemannianExp x p) + have hg := (modified_transform_bounds (a := a) (D := D) hu hv hdual ho hb hob x).1 + have hc := mul_le_mul_of_nonneg_left (hcb ((v (riemannianExp x p)-a)/D)).1 hb + refine ⟨?_,?_⟩ + · change contactGap u v x (riemannianExp x p) ≤ (H+2)*b + dsimp only [contactGap] + linarith only [he,hupp,hg,hc] + · intro pi hi + refine ⟨?_,?_⟩ + · have HA := modified_contact_original_section hu hv hdual ho hb hob hi.2 + change contactGap u v x (riemannianExp x pi) ≤ (H+2)*b + linarith only [HA,hb] + · have hai := hi.2 + change cTransform (modifiedDatum v a D b Bo) x+cost x (riemannianExp x pi)+ + (v (riemannianExp x pi)+b*Bo ((v (riemannianExp x pi)-a)/D))=0 at hai + have hpn : cost x (riemannianExp x p)=‖p‖^2/2 := by rw [cost,hpm] + have hin : cost x (riemannianExp x pi)=‖pi‖^2/2 := by rw [cost,hi.1] + rw [hpn] at he + rw [hin] at hai + linarith only [he,hai] + +lemma modified_positive_excess_center_level {u v : M → ℝ} + (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {a D b : ℝ} {Bc Bo : ℝ → ℝ} (ho : Continuous Bo) (hb : 0 ≤ b) + (hob : ∀ s,0 ≤ Bo s) (hright : ∀ s,3/4 ≤ s → Bc s ≤ 0) {y : M} + (he : 0 < modifiedExcess v a D b Bc Bo y) : (v y-a)/D < 3/4 := by + have hl := (modified_double_bounds (a := a) (D := D) hu hv hdual ho hb hob y).1 + by_contra h + have hh := mul_nonpos_of_nonneg_of_nonpos hb (hright _ (le_of_not_gt h)) + dsimp only [modifiedExcess,modifiedDatum] at he + linarith only [he,hl,hh] + +lemma section_level_range {u v : M → ℝ} (hv : Continuous v) (hdual : IsCostDualPair u v) + {x y z : M} {r a D delta : ℝ} (hr : 0 ≤ r) (hD : 0 < D) + (hy : y ∈ gapSection u v x r) (hz : z ∈ gapSection u v x r) + (hosc : sectionOscillation u v x r ≤ (1+delta)*D) : + |(v y-a)/D-(v z-a)/D| ≤ 1+delta := by + obtain ⟨y0,_,y1,_,hl,hu,he⟩ := sectionOscillation_extrema hv hdual x hr + have hyy0 := hl y hy + have hyy1 := hu y hy + have hzz0 := hl z hz + have hzz1 := hu z hz + rw [he] at hosc + rw [←sub_div,abs_div,abs_of_pos hD] + apply (div_le_iff₀ hD).mpr + apply abs_le.mpr + constructor <;> linarith only [hyy0,hyy1,hzz0,hzz1,hosc] + +lemma limiting_levels_lower {ι : Type*} [Fintype ι] {m si : ι → ℝ} + {Bc Bo : ℝ → ℝ} {s eta delta c : ℝ} + (hm : ∀ i,0 ≤ m i) (hsum : ∑ i,m i=1) + (hBo : ∀ r,0 ≤ Bo r) (hleft : ∀ r,r < 1-eta → 1 ≤ Bo r) + (hBc : Bc s ≤ 1) (hc : 0 < c) (hparameter : c ≤ Bc s-∑ i,m i*Bo (si i)) + (hrange : ∀ i j,|si i-si j| ≤ 1+delta) (hcenter : ∀ i,|s-si i| ≤ 1+delta) + (hdelta : delta ≤ eta) : + -2*eta ≤ s ∧ ∀ i,-2*eta ≤ si i := by + classical + have H := template_right_weight hm hsum (fun i=>hBo (si i)) + (fun i=>hleft (si i)) hBc hparameter + obtain ⟨j,hj,_⟩ := Finset.sum_pos_iff_of_nonneg (fun i _=>hm i) |>.mp (hc.trans_le H) + have hright := (Finset.mem_filter.mp hj).2 + refine ⟨?_,?_⟩ + · have hsc := (abs_le.mp (hcenter j)).1 + linarith only [hsc,hright,hdelta] + · intro i + have hsi := (abs_le.mp (hrange i j)).1 + linarith only [hsi,hright,hdelta] + +end ActualLevels +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualOutward.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualOutward.lean new file mode 100644 index 0000000000000000000000000000000000000000..5d071b1daf0b73ea1621c99780e57f64a2283d72 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualOutward.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ActiveDifference +import OAI.Analysis.BiholderTransport.Regularity.ActualLevels + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ActualOutward +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.actual_outward_endpoint (hmtw:WeakMTW (n := n) (M := M)) + {u v:M → ℝ} (hu:Continuous u) (hv:Continuous v) (hdual:IsCostDualPair u v) + {α D b H:ℝ} {Bc Bo:ℝ → ℝ} (ho:Continuous Bo) (hb:0 ≤ b) + (hob:∀s,0 ≤ Bo s ∧ Bo s ≤ H) (hcb:∀s,-1 ≤ Bc s ∧ Bc s ≤ 1) + (hright:∀s,3/4 ≤ s → Bc s ≤ 0) + {ι:Type} [Fintype ι] [DecidableEq ι] {N:ℕ} (hN:Fintype.card ι ≤ N+1) + {x:M} {p e:TangentSpace 𝓘(ℝ,Model n) x} + {pj:ι → TangentSpace 𝓘(ℝ,Model n) x} {m:ι → ℝ} + (hm:∀i,0 < m i) (hsum:∑ i,m i=1) (hbar:∑ i,m i • pj i=p) + (hactive:∀i,pj i∈activeLogs (modifiedDatum v α D b Bo) x) + (he:‖e‖=1) (hq:0 < inner ℝ p e) + (hline:Submodule.span ℝ (range (fun i=>pj i-p))=Submodule.span ℝ {e}) + {c eta delta zeta a0:ℝ} (hD:0 < D) (hc:0 < c) (ha0:0 < a0) + (hqa:a0*D ≤ (inner ℝ p e)^2) (heta:eta ≤ 1/128) (hdelta:delta ≤ zeta) + (hdeltaEta:delta ≤ eta) (hzeta:zeta ≤ 1/16) + (hleft:∀s,s < 1-eta → 1 ≤ Bo s) + (hexcess:0 < modifiedExcess v α D b Bc Bo (riemannianExp x p)) + (herror:2*(H+2)*b ≤ zeta*D) + (hosc:sectionOscillation u v x ((H+2)*b) ≤ (1+delta)*D) + (hparameter:c ≤ Bc ((v (riemannianExp x p)-α)/D)- + ∑ i,m i*Bo ((v (riemannianExp x (pj i))-α)/D)) : + let si:=fun i=>(v (riemannianExp x (pj i))-α)/D + let mstar:=c/(12*(N+1:ℝ)) + let theta0:=min (mstar/2) (a0/3) + ∃ i d,0 < d ∧ pj i=p+d • e ∧ mstar ≤ m i ∧ + c*D/(8*(N+1:ℝ)*(inner ℝ p e)) ≤ m i*d ∧ + d ≤ 3*D/(2*(inner ℝ p e)) ∧ -2*eta ≤ si i ∧ si i < 1-eta ∧ + Bo (si i) ≤ 12*(N+1:ℝ)/c ∧ 0 < theta0 ∧ + ∀ theta∈Icc (-theta0) 1, + p+theta • (pj i-p)∈convexHull ℝ (range pj) ∧ + (inner ℝ p e)/2 ≤ inner ℝ (p+theta • (pj i-p)) e ∧ + ‖pj i-p‖^2/(inner ℝ (p+theta • (pj i-p)) (pj i-p)) ≤ 3/a0 := by + dsimp only + let y:=riemannianExp x p + let si:=fun i=>(v (riemannianExp x (pj i))-α)/D + let s:=(v y-α)/D + have hp:p∈convexHull ℝ (activeLogs (modifiedDatum v α D b Bo) x) := by + rw [←hbar] + exact (convex_convexHull ℝ _).sum_mem (fun i _=>(hm i).le) hsum + (fun i _=>subset_convexHull ℝ _ (hactive i)) + obtain ⟨hy,Hlevels⟩:=hmtw.modified_aligned_levels hu hv hdual ho hb hob hcb hp + have hH:0 ≤ H:=(hob 0).1.trans (hob 0).2 + have hr:0 ≤ (H+2)*b:=mul_nonneg (by linarith) hb + have hrange:∀i j,|si i-si j| ≤ 1+delta := fun i j=> + section_level_range hv hdual hr hD (Hlevels (pj i) (hactive i)).1 + (Hlevels (pj j) (hactive j)).1 hosc + have hcenter:∀i,|s-si i| ≤ 1+delta := fun i=> + section_level_range hv hdual hr hD hy (Hlevels (pj i) (hactive i)).1 hosc + have hlow:=limiting_levels_lower (fun i=>(hm i).le) hsum (fun r=>(hob r).1) hleft + (hcb s).2 hc hparameter hrange hcenter hdeltaEta + have hs:s < 3/4:=modified_positive_excess_center_level hu hv hdual ho hb + (fun r=>(hob r).1) hright hexcess + have herr:∀i,|‖pj i‖^2-‖p‖^2+2*D*(si i-s)| ≤ zeta*D := by + intro i + have Hlev: v (riemannianExp x (pj i))-v y=(‖p‖^2-‖pj i‖^2)/2+ + b*(Bc s-Bo (si i))-modifiedExcess v α D b Bc Bo y := + (Hlevels (pj i) (hactive i)).2 + have Hdiv:D*(si i-s)=v (riemannianExp x (pj i))-v y := by + dsimp only [si,s] + field_simp + ring + have Hup:=modified_excess_upper (a := α) (D := D) hu hv hdual ho hb (fun r=>(hob r).1) + (fun r=>(hcb r).2) y + have Hcb:=mul_le_mul_of_nonneg_left (hcb s).1 hb + have Hct:=mul_le_mul_of_nonneg_left (hcb s).2 hb + have Hob:=mul_le_mul_of_nonneg_left (hob (si i)).2 hb + have Hoz:=mul_nonneg hb (hob (si i)).1 + have hHb:=mul_nonneg hH hb + apply abs_le.mpr + constructor <;> nlinarith only [Hlev,Hdiv,Hup,hexcess,Hcb,Hct,Hob,Hoz,herror,hHb,hb] + apply outward_active_endpoint hN hm hsum hbar he hq hline hD hc ha0 hqa heta hdelta hzeta + hs hlow.2 ?_ herr (fun i=>(hob (si i)).1) (fun i=>hleft (si i)) (hcb s).2 hparameter + intro i + simpa only [abs_sub_comm] using hcenter i + +end ActualOutward +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualParameter.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualParameter.lean new file mode 100644 index 0000000000000000000000000000000000000000..6d7bcabab50e25075edf785bcbd229d99a1da5a4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualParameter.lean @@ -0,0 +1,751 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.GeometricEnvelope +import OAI.Analysis.BiholderTransport.Coordinates.FiberLog + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +namespace ParameterVariation + +section +open Set Filter +open scoped Topology BigOperators + +lemma abs_le_of_positive_barycentric {ι : Type*} [Fintype ι] [DecidableEq ι] + {m L : ι → ℝ} {U : ℝ} (hm : ∀ i, 0 < m i) + (hs : ∑ i, m i = 1) (hcancel : ∑ i, m i * L i = 0) + (hU : 0 ≤ U) (hupper : ∀ i, L i ≤ U) (i : ι) : + |L i| ≤ U / m i := by + have hmi : m i ≤ 1 := by + rw [← hs] + exact Finset.single_le_sum (fun j _ => (hm j).le) (Finset.mem_univ i) + have hdef : ∑ j, m j * (U - L j) = U := by + simp_rw [mul_sub] + rw [Finset.sum_sub_distrib, ← Finset.sum_mul, hs, hcancel] + ring + have hsingle : m i * (U - L i) ≤ U := by + exact (Finset.single_le_sum (fun j _ => mul_nonneg (hm j).le (sub_nonneg.mpr (hupper j))) + (Finset.mem_univ i)).trans_eq hdef + apply (le_div_iff₀ (hm i)).mpr + rw [mul_comm, ← abs_of_pos (hm i), ← abs_mul, abs_le] + constructor + · nlinarith [mul_nonneg (hm i).le hU] + · exact (mul_le_mul_of_nonneg_left (hupper i) (hm i).le).trans + (by nlinarith) + +variable {ι E : Type*} [Fintype ι] + [NormedAddCommGroup E] [InnerProductSpace ℝ E] [FiniteDimensional ℝ E] + +lemma exists_span_projection_bound (a : ι → E) : + ∃ K : ℝ, 0 < K ∧ ∀ x : E, ∀ R : ℝ, 0 ≤ R → + (∀ i, |inner ℝ (a i) x| ≤ R) → + ‖(Submodule.span ℝ (range a)).starProjection x‖ ≤ K * R := by + let S := Submodule.span ℝ (range a) + let A : S →ₗ[ℝ] (ι → ℝ) := LinearMap.pi fun i => + (innerSL ℝ (a i)).toLinearMap.comp S.subtype + have hinj : Function.Injective A := by + apply LinearMap.ker_eq_bot.mp + apply LinearMap.ker_eq_bot'.mpr + intro x hx + have horth : ∀ z ∈ S, inner ℝ z (x : E) = 0 := by + intro z hz + induction hz using Submodule.span_induction with + | mem z hz => + obtain ⟨i,rfl⟩ := hz + exact congrFun hx i + | zero => simp + | add x y hx hy hix hiy => simp [inner_add_left, hix, hiy] + | smul r x hx hix => simp [inner_smul_left, hix] + apply Subtype.ext + exact inner_self_eq_zero.mp (horth x x.property) + obtain ⟨K,hK,hA⟩ := A.injective_iff_antilipschitz.mp hinj + refine ⟨K,by exact_mod_cast hK,?_⟩ + intro x R hR hx + have heval (i : ι) : A (S.orthogonalProjectionOnto x) i = inner ℝ (a i) x := by + change inner ℝ (a i) ((S.orthogonalProjectionOnto x : S) : E) = _ + exact S.inner_orthogonalProjectionOnto_eq_of_mem_left + ⟨a i,Submodule.subset_span (mem_range_self i)⟩ x + have hn : ‖A (S.orthogonalProjectionOnto x)‖ ≤ R := by + apply (pi_norm_le_iff_of_nonneg hR).mpr + intro i + simpa only [heval i, Real.norm_eq_abs] using hx i + have H := hA.le_mul_dist (S.orthogonalProjectionOnto x) 0 + simp only [map_zero, dist_zero_right] at H + simpa only [Submodule.norm_coe, Submodule.starProjection_apply] using + H.trans (mul_le_mul_of_nonneg_left hn K.coe_nonneg) + +lemma exists_eventual_active_projection_bound {T : Type*} {l : Filter T} + (a : ι → E) {m : ι → ℝ} (hm : ∀ i, 0 < m i) + (hs : ∑ i, m i = 1) (hbar : ∑ i, m i • a i = 0) + {h : T → ℝ} {d : T → E} {C : ℝ} (hC : 0 ≤ C) + (hh : ∀ᶠ k in l, 0 ≤ h k) + (ha : ∀ᶠ k in l, ∀ i, inner ℝ (a i) (d k) ≤ C*h k) : + ∃ K : ℝ, 0 < K ∧ ∀ᶠ k in l, + ‖(Submodule.span ℝ (range a)).starProjection (d k)‖ ≤ K*h k := by + classical + let R := ∑ i, C/m i + have hR : 0 ≤ R := Finset.sum_nonneg (fun i _ => div_nonneg hC (hm i).le) + obtain ⟨K,hK,hproj⟩ := exists_span_projection_bound a + refine ⟨K*R+1,by positivity,?_⟩ + filter_upwards [hh,ha] with k hhk hak + have hcancel : ∑ i, m i * inner ℝ (a i) (d k) = 0 := by + simpa only [sum_inner,real_inner_smul_left,inner_zero_left] using + congrArg (fun x => inner ℝ x (d k)) hbar + have hforms : ∀ i, |inner ℝ (a i) (d k)| ≤ R*h k := by + intro i + have H := abs_le_of_positive_barycentric hm hs hcancel (mul_nonneg hC hhk) hak i + calc + |inner ℝ (a i) (d k)| ≤ C*h k/m i := H + _ = (C/m i)*h k := by ring + _ ≤ R*h k := mul_le_mul_of_nonneg_right + (Finset.single_le_sum (fun j _ => div_nonneg hC (hm j).le) (Finset.mem_univ i)) hhk + calc + ‖(Submodule.span ℝ (range a)).starProjection (d k)‖ ≤ K*(R*h k) := + hproj (d k) (R*h k) (mul_nonneg hR hhk) hforms + _ ≤ (K*R+1)*h k := by nlinarith only [hhk] + +omit [FiniteDimensional ℝ E] in +lemma exists_eventual_active_linear_bound {T : Type*} {l : Filter T} + (a : ι → E) (B : ι → ℝ) (Q : ι → E →L[ℝ] E →L[ℝ] ℝ) + {h U : T → ℝ} {d : T → E} {e : ι → T → ℝ} {H K : ℝ} + (hH : 0 ≤ H) (hK : 0 ≤ K) + (hh : ∀ᶠ k in l, 0 < h k) + (hd : ∀ᶠ k in l, ‖d k‖^2 ≤ K*h k) + (hU : ∀ᶠ k in l, U k ≤ H*h k) + (he : ∀ i, Tendsto (fun k => e i k/h k) l (𝓝 0)) + (hcontact : ∀ᶠ k in l, ∀ i, + h k*B i+inner ℝ (a i) (d k)+Q i (d k) (d k)/2+e i k ≤ U k) : + ∃ C : ℝ, 0 ≤ C ∧ ∀ᶠ k in l, ∀ i, inner ℝ (a i) (d k) ≤ C*h k := by + classical + let X := ∑ i, |B i| + let Y := ∑ i, ‖Q i‖ + have hX : 0 ≤ X := Finset.sum_nonneg (fun i _ => abs_nonneg (B i)) + have hY : 0 ≤ Y := Finset.sum_nonneg (fun i _ => norm_nonneg (Q i)) + refine ⟨H+X+Y*K/2+1,by positivity,?_⟩ + have he' : ∀ᶠ k in l, ∀ i, -1 < e i k/h k := + eventually_all.mpr (fun i => (he i).eventually (lt_mem_nhds (by norm_num : (-1:ℝ)<0))) + filter_upwards [hh,hd,hU,he',hcontact] with k hhk hdk hUk hek hck i + have hiX : |B i| ≤ X := Finset.single_le_sum + (fun j _ => abs_nonneg (B j)) (Finset.mem_univ i) + have hiY : ‖Q i‖ ≤ Y := Finset.single_le_sum + (fun j _ => norm_nonneg (Q j)) (Finset.mem_univ i) + have hBi := mul_le_mul_of_nonneg_left ((neg_le_neg hiX).trans (neg_abs_le (B i))) hhk.le + have hQi : |Q i (d k) (d k)| ≤ Y*K*h k := by + calc + |Q i (d k) (d k)| ≤ ‖Q i‖*‖d k‖*‖d k‖ := (Q i).le_opNorm₂ (d k) (d k) + _ = ‖Q i‖*‖d k‖^2 := by ring + _ ≤ ‖Q i‖*(K*h k) := mul_le_mul_of_nonneg_left hdk (norm_nonneg (Q i)) + _ ≤ Y*(K*h k) := mul_le_mul_of_nonneg_right hiY (mul_nonneg hK hhk.le) + _ = Y*K*h k := by ring + have hei : -h k ≤ e i k := by + have HT := (lt_div_iff₀ hhk).mp (hek i) + linarith only [HT] + have hQi' := (abs_le.mp hQi).1 + nlinarith only [hck i,hUk,hBi,hQi',hei] + +lemma projected_quadratic_lower (S : Submodule ℝ E) + (Q : E →L[ℝ] E →L[ℝ] ℝ) (hQ : ∀ v ∈ Sᗮ, 0 ≤ Q v v) (x : E) : + -‖Q‖ * (2 * ‖S.starProjection x‖ * ‖x‖ + ‖S.starProjection x‖ ^ 2) ≤ Q x x := by + let e := S.starProjection x + have hp := hQ (x-e) (S.sub_starProjection_mem_orthogonal x) + simp only [map_sub, sub_apply] at hp + have h1 := (abs_le.mp (show |Q x e| ≤ ‖Q‖*‖x‖*‖e‖ from Q.le_opNorm₂ x e)).1 + have h2 := (abs_le.mp (show |Q e x| ≤ ‖Q‖*‖e‖*‖x‖ from Q.le_opNorm₂ e x)).1 + have h3 := (abs_le.mp (show |Q e e| ≤ ‖Q‖*‖e‖*‖e‖ from Q.le_opNorm₂ e e)).2 + change -‖Q‖ * (2*‖e‖*‖x‖+‖e‖^2) ≤ Q x x + nlinarith only [hp,h1,h2,h3] + +omit [InnerProductSpace ℝ E] [FiniteDimensional ℝ E] in +lemma norm_tendsto_zero_of_sq_bound {T : Type*} {l : Filter T} + {h : T → ℝ} {d : T → E} {K : ℝ} + (hh : Tendsto h l (𝓝 0)) + (hb : ∀ᶠ k in l, ‖d k‖^2 ≤ K*h k) : + Tendsto (fun k => ‖d k‖) l (𝓝 0) := by + have H := squeeze_zero' (Eventually.of_forall (fun k => sq_nonneg ‖d k‖)) hb + (show Tendsto (fun k => K*h k) l (𝓝 0) by simpa using hh.const_mul K) + simpa only [Real.sqrt_sq_eq_abs,abs_norm,Real.sqrt_zero] using H.sqrt + +lemma weighted_parameter_bound {T : Type*} {l : Filter T} [l.NeBot] + (a : ι → E) (B : ι → ℝ) (Q : ι → E →L[ℝ] E →L[ℝ] ℝ) + {m : ι → ℝ} (hm : ∀ i, 0 < m i) (hs : ∑ i, m i = 1) + (hbar : ∑ i, m i • a i = 0) + {h U e0 : T → ℝ} {d : T → E} {e : ι → T → ℝ} {K D : ℝ} + (hK : 0 ≤ K) (hh : ∀ᶠ k in l, 0 < h k) (hh0 : Tendsto h l (𝓝 0)) + (hd : ∀ᶠ k in l, ‖d k‖^2 ≤ K*h k) + (he : ∀ i, Tendsto (fun k => e i k/h k) l (𝓝 0)) + (he0 : Tendsto (fun k => e0 k/h k) l (𝓝 0)) + (hupper : ∀ᶠ k in l, U k ≤ h k*D+e0 k) + (hcontact : ∀ᶠ k in l, ∀ i, + h k*B i+inner ℝ (a i) (d k)+Q i (d k) (d k)/2+e i k ≤ U k) + (hQ : ∀ v ∈ (Submodule.span ℝ (range a))ᗮ, 0 ≤ (∑ i, m i • Q i) v v) : + ∑ i, m i*B i ≤ D := by + classical + let S := Submodule.span ℝ (range a) + let Qt := ∑ i, m i • Q i + have hU : ∀ᶠ k in l, U k ≤ (|D|+1)*h k := by + filter_upwards [hh,hupper,he0.eventually (gt_mem_nhds (by norm_num : (0:ℝ)<1))] + with k hhk huk hek + have he' := (div_lt_iff₀ hhk).mp hek + have hD := mul_le_mul_of_nonneg_left (le_abs_self D) hhk.le + nlinarith only [huk,he',hD] + obtain ⟨C,hC,hlinear⟩ := exists_eventual_active_linear_bound a B Q + (by positivity : 0 ≤ |D|+1) hK hh hd hU he hcontact + obtain ⟨Kp,hKp,hproj⟩ := exists_eventual_active_projection_bound a hm hs hbar hC + (hh.mono fun _ hk => hk.le) hlinear + let δ := fun k => ‖Qt‖*(2*Kp*‖d k‖+Kp^2*h k) + have hd0 := norm_tendsto_zero_of_sq_bound hh0 hd + have hδ0 : Tendsto δ l (𝓝 0) := by + simpa only [mul_zero,add_zero,δ] using + ((hd0.const_mul (2*Kp)).add (hh0.const_mul (Kp^2))).const_mul ‖Qt‖ + let err := fun k => ∑ i, m i*(e i k/h k) + have herr0 : Tendsto err l (𝓝 0) := by + simpa only [mul_zero,Finset.sum_const_zero,err] using + tendsto_finsetSum Finset.univ (fun i _ => (he i).const_mul (m i)) + have hlim : Tendsto (fun k => D+e0 k/h k-err k+δ k/2) l (𝓝 D) := by + simpa using ((he0.const_add D).sub herr0).add (hδ0.div_const 2) + apply ge_of_tendsto hlim + filter_upwards [hh,hproj,hcontact,hupper] with k hhk hpk hck huk + have hform : -δ k*h k ≤ Qt (d k) (d k) := by + have hq := projected_quadratic_lower S Qt hQ (d k) + have hP : 0 ≤ ‖S.starProjection (d k)‖ := norm_nonneg _ + have hPN : 0 ≤ Kp*h k := mul_nonneg hKp.le hhk.le + have hPsq := mul_self_le_mul_self hP hpk + have hcross := mul_le_mul_of_nonneg_right hpk (norm_nonneg (d k)) + have hb : 2*‖S.starProjection (d k)‖*‖d k‖+‖S.starProjection (d k)‖^2 ≤ + (2*Kp*‖d k‖+Kp^2*h k)*h k := by + change ‖S.starProjection (d k)‖ ≤ Kp*h k at hpk + nlinarith only [hPsq,hcross] + have H := neg_le_neg (mul_le_mul_of_nonneg_left hb (norm_nonneg Qt)) + calc + -δ k*h k = -(‖Qt‖*((2*Kp*‖d k‖+Kp^2*h k)*h k)) := by dsimp [δ]; ring + _ ≤ -‖Qt‖*(2*‖S.starProjection (d k)‖*‖d k‖+‖S.starProjection (d k)‖^2) := by + simpa only [neg_mul] using H + _ ≤ Qt (d k) (d k) := hq + have hcancel : ∑ i, m i*inner ℝ (a i) (d k) = 0 := by + simpa only [sum_inner,real_inner_smul_left,inner_zero_left] using + congrArg (fun x => inner ℝ x (d k)) hbar + have hQt : Qt (d k) (d k) = ∑ i, m i*Q i (d k) (d k) := by + simp only [Qt,sum_apply,smul_apply,smul_eq_mul] + have havg : h k*(∑ i, m i*B i)+Qt (d k) (d k)/2+∑ i, m i*e i k ≤ U k := by + have H := Finset.sum_le_sum (fun i (_ : i ∈ (Finset.univ : Finset ι)) => + mul_le_mul_of_nonneg_left (hck i) (hm i).le) + have heq : (∑ i, m i*(h k*B i+inner ℝ (a i) (d k)+Q i (d k) (d k)/2+e i k)) = + h k*(∑ i, m i*B i)+Qt (d k) (d k)/2+∑ i, m i*e i k := by + calc + _ = ∑ i, (h k*(m i*B i)+m i*inner ℝ (a i) (d k)+ + (m i*Q i (d k) (d k))/2+m i*e i k) := by + apply Finset.sum_congr rfl; intro i _; ring + _ = _ := by + simp only [Finset.sum_add_distrib,←Finset.mul_sum,←Finset.sum_div,hcancel,add_zero,hQt] + rw [heq,←Finset.sum_mul,hs,one_mul] at H + exact H + have herr : err k*h k = ∑ i, m i*e i k := by + dsimp only [err] + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro i _ + rw [mul_assoc,div_mul_cancel₀ _ hhk.ne'] + apply (mul_le_mul_iff_left₀ hhk).mp + have hrem : h k*(D+e0 k/h k-err k+δ k/2) = + h k*D+e0 k-∑ i, m i*e i k+δ k*h k/2 := by + rw [mul_add,mul_sub,mul_add,mul_div_cancel₀ _ hhk.ne',mul_comm (h k) (err k),herr] + ring + rw [mul_comm (∑ i, m i * B i) (h k), + mul_comm (D + e0 k / h k - err k + δ k / 2) (h k), hrem] + nlinarith only [havg,hform,huk] + +end + +open Set Filter +open scoped Topology + +lemma compact_minimizers_tendsto {M T : Type*} [TopologicalSpace M] [CompactSpace M] + {l : Filter T} {f : M → ℝ} (hf : Continuous f) {x : M} + (hmin : ∀ y, f x ≤ f y) (hunique : ∀ y, f y = f x → y = x) + {u : T → M} (hval : Tendsto (fun k => f (u k)) l (𝓝 (f x))) : + Tendsto u l (𝓝 x) := by + rw [tendsto_nhds] + intro s hs hxs + by_cases he : sᶜ.Nonempty + · obtain ⟨y,hy,hym⟩ := hs.isClosed_compl.isCompact.exists_isMinOn he hf.continuousOn + have hstrict : f x < f y := lt_of_le_of_ne (hmin y) (by + intro h + have hyx := hunique y h.symm + exact hy (hyx ▸ hxs)) + filter_upwards [hval.eventually (gt_mem_nhds hstrict)] with k hk + by_contra hn + exact (not_le_of_gt hk) (hym hn) + · filter_upwards [] with k + by_contra hn + exact he ⟨u k,hn⟩ + +lemma perturbed_compact_minimizers_tendsto {M T : Type*} + [TopologicalSpace M] [CompactSpace M] {l : Filter T} + {f : M → ℝ} (hf : Continuous f) {x : M} + (hmin : ∀ y, f x ≤ f y) (hunique : ∀ y, f y = f x → y = x) + {u : T → M} {h : T → ℝ} {K : ℝ} + (hh0 : Tendsto h l (𝓝 0)) + (hbound : ∀ᶠ k in l, f (u k) ≤ f x + K*h k) : + Tendsto u l (𝓝 x) := by + apply compact_minimizers_tendsto hf hmin hunique + apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds + (by simpa using tendsto_const_nhds.add (tendsto_const_nhds.mul hh0)) + (Eventually.of_forall (fun k => hmin (u k))) hbound + +lemma affine_minimum_derivative {M T : Type*} + [TopologicalSpace M] [CompactSpace M] {l : Filter T} + {f B : M → ℝ} (hf : Continuous f) (hB : Continuous B) {x : M} + (hmin : ∀ y, f x ≤ f y) (hunique : ∀ y, f y = f x → y = x) + {u : T → M} {h : T → ℝ} + (hh : ∀ᶠ k in l, 0 < h k) (hh0 : Tendsto h l (𝓝 0)) + (hu : ∀ᶠ k in l, ∀ y, f (u k)-h k*B (u k) ≤ f y-h k*B y) : + Tendsto (fun k => (f (u k)-h k*B (u k)-f x)/h k) l (𝓝 (-B x)) := by + obtain ⟨K,hK⟩ := (isCompact_univ.image hB).bddAbove + have hbound : ∀ᶠ k in l, f (u k) ≤ f x+(K-B x)*h k := by + filter_upwards [hh,hu] with k hhk huk + have HK := hK (mem_image_of_mem B (mem_univ (u k))) + have H := huk x + nlinarith only [H,mul_le_mul_of_nonneg_left HK hhk.le] + have hconv := perturbed_compact_minimizers_tendsto hf hmin hunique hh0 hbound + have hlim : Tendsto (fun k => -B (u k)) l (𝓝 (-B x)) := + (hB.continuousAt.tendsto.comp hconv).neg + apply tendsto_of_tendsto_of_tendsto_of_le_of_le' hlim tendsto_const_nhds + · filter_upwards [hh] with k hhk + apply (le_div_iff₀ hhk).mpr + have H := hmin (u k) + nlinarith only [H] + · filter_upwards [hh,hu] with k hhk huk + apply (div_le_iff₀ hhk).mpr + have H := huk x + nlinarith only [H] + +lemma second_remainder_along_sqrt {E T : Type*} [NormedAddCommGroup E] + {l : Filter T} {R : E → ℝ} {d : T → E} {h : T → ℝ} {K : ℝ} + (hR : R =o[𝓝 0] (fun v : E => ‖v‖^2)) + (hd0 : Tendsto d l (𝓝 0)) (hh : ∀ᶠ k in l, 0 ≤ h k) + (hd : ∀ᶠ k in l, ‖d k‖^2 ≤ K*h k) : + Tendsto (fun k => R (d k)/h k) l (𝓝 0) := by + have HO : (fun k => ‖d k‖^2) =O[l] h := by + apply Asymptotics.isBigO_iff.mpr + refine ⟨K,?_⟩ + filter_upwards [hh,hd] with k hk hd' + simpa only [Real.norm_eq_abs,abs_of_nonneg (sq_nonneg (‖d k‖)),abs_of_nonneg hk] using hd' + exact ((hR.comp_tendsto hd0).trans_isBigO HO).tendsto_div_nhds_zero + +end ParameterVariation + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +open ParameterVariation + +section CompactEnvelopes +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +def modifiedDatum (v : M → ℝ) (a D b : ℝ) (B : ℝ → ℝ) (y : M) : ℝ := + v y+b*B ((v y-a)/D) + +def modifiedExcess (v : M → ℝ) (a D b : ℝ) (Bc Bo : ℝ → ℝ) (y : M) : ℝ := + modifiedDatum v a D b Bc y-cTransform (cTransform (modifiedDatum v a D b Bo)) y + +omit [CompactSpace M] [Nonempty M] in +lemma continuous_modifiedDatum {v : M → ℝ} (hv : Continuous v) (a D b : ℝ) + {B : ℝ → ℝ} (hB : Continuous B) : Continuous (modifiedDatum v a D b B) := + hv.add (continuous_const.mul (hB.comp ((hv.sub continuous_const).div_const D))) + +def parameterPenalty (bplus b : ℝ) : ℝ := b/4096+2*b^2/bplus + +def regularizedComparison (v : M → ℝ) (a D bplus t : ℝ) + (Bc Bo : ℝ → ℝ) (q : ℝ×M) : ℝ := + hopfLax t (cTransform (modifiedDatum v a D q.1 Bo)) q.2+ + hopfLax (1-t) (modifiedDatum v a D q.1 Bc) q.2-parameterPenalty bplus q.1 + +lemma modified_outer_decrease_bounds {v : M → ℝ} (hv : Continuous v) + {a D b h H : ℝ} {B : ℝ → ℝ} (hB : Continuous B) + (hh : 0 ≤ h) (hbound : ∀ s, 0 ≤ B s ∧ B s ≤ H) (x : M) : + 0 ≤ cTransform (modifiedDatum v a D (b-h) B) x- + cTransform (modifiedDatum v a D b B) x ∧ + cTransform (modifiedDatum v a D (b-h) B) x- + cTransform (modifiedDatum v a D b B) x ≤ h*H := by + have hw := continuous_modifiedDatum hv a D b hB + have hw' := continuous_modifiedDatum hv a D (b-h) hB + have H1 := cTransform_antitone hw' hw (fun y => by + dsimp only [modifiedDatum] + nlinarith only [mul_nonneg hh (hbound ((v y-a)/D)).1]) x + have H2 := cTransform_antitone (v := fun y => modifiedDatum v a D b B y + (-h*H)) + (hw.add continuous_const) hw' (fun y => by + dsimp only [modifiedDatum] + nlinarith only [mul_le_mul_of_nonneg_left (hbound ((v y-a)/D)).2 hh]) x + rw [cTransform_add_const hw] at H2 + constructor <;> linarith only [H1,H2] + +end CompactEnvelopes + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.hopfLax_minimizer_unique (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0 w.1.1) + (hmtw.injective_graphProjection hv ht ht1 hXY) + +lemma modified_active_split_contact {v : M → ℝ} (hv : Continuous v) + {a D b h t q : ℝ} {B : ℝ → ℝ} (hB : Continuous B) {x z x' : M} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hp : p∈minimizingVectors x) + (hact : contactGap (cTransform (modifiedDatum v a D b B)) + (modifiedDatum v a D b B) x (riemannianExp x p)=0) + (hq : 0] 0) (𝓝 x) ∧ Tendsto d (𝓝[>] 0) (𝓝 0) ∧ + ∀ᶠ h in 𝓝[>] 0, riemannianExp x (d h)=X h ∧ ‖d h‖^2≤K*h := by + classical + dsimp only + let r := ∑ i, m i • p i + let z := riemannianExp x (t • r) + let w := modifiedDatum v a D b B + let g : ℝ → M → ℝ := fun β => cTransform (modifiedDatum v a D β B) + have hw : Continuous w := continuous_modifiedDatum hv a D b hB + have hg : ∀ β, Continuous (g β) := fun β => + continuous_cTransform (continuous_modifiedDatum hv a D β hB) + have hAS : range p ⊆ activeLogs (n := n) w x := by + rintro _ ⟨i,rfl⟩ + exact ⟨hmin i,hactive i⟩ + have hr : r∈convexHull ℝ (range p) := + (convex_convexHull ℝ (range p)).sum_mem (fun i _ => (hm i).le) hsum + (fun i _ => subset_convexHull ℝ (range p) (mem_range_self i)) + have hrsub := active_hull_subset_normalSubdifferential hw x ((convexHull_mono hAS) hr) + let G : subgradientGraph (n := n) (cTransform w) := ⟨⟨x,r⟩,hrsub⟩ + have hval : hopfLax t (g b) z=g b x+cost x z/t := by + exact hmtw.hopfLax_graph_value hw ht ht1 G + refine ⟨hval,?_⟩ + have hID : ∀ q∈convexHull ℝ (range p), t • q∈injectivityDomain x := + fun q hq => hmtw.active_hull_precut hw ht ht1 x q ((convexHull_mono hAS) hq) + obtain ⟨β,hβ,hgrowth⟩ := hmtw.active_local_growth hw p m hm hsum hmin hactive ht ht1 hID + choose X hX hXmin using (fun h : ℝ => exists_hopfLax_minimizer (hg (b-h)) t z) + let f : M → ℝ := fun y => g b y+cost y z/t + have hf : Continuous f := (hg b).add ((continuous_cost_left z).div_const t) + have hfmin : ∀ y, f x ≤ f y := by + intro y + have H := hopfLax_le (hg b) t z y + rwa [hval] at H + have hfunique : ∀ y, f y=f x → y=x := by + intro y hy + exact hmtw.hopfLax_minimizer_unique hw ht ht1 (hval.trans hy.symm) hval + have hXbound : ∀ᶠ h : ℝ in 𝓝[>] 0, f (X h)≤f x+H*h := by + filter_upwards [self_mem_nhdsWithin] with h hh + have HL := modified_outer_decrease_bounds (a := a) (D := D) (b := b) hv hB (le_of_lt hh) hbound (X h) + have HR := modified_outer_decrease_bounds (a := a) (D := D) (b := b) hv hB (le_of_lt hh) hbound x + have HM := hXmin h x + change g (b-h) (X h)+cost (X h) z/t≤g (b-h) x+cost x z/t at HM + change 0 ≤ g (b-h) (X h)-g b (X h) ∧ _ at HL + change 0 ≤ g (b-h) x-g b x ∧ _ at HR + change g b (X h)+cost (X h) z/t≤g b x+cost x z/t+H*h + linarith only [HL.1,HR.2,HM] + have hh0 : Tendsto (fun h : ℝ => h) (𝓝[>] 0) (𝓝 0) := + tendsto_id.mono_right nhdsWithin_le_nhds + have hX0 : Tendsto X (𝓝[>] 0) (𝓝 x) := + perturbed_compact_minimizers_tendsto hf hfmin hfunique hh0 hXbound + obtain ⟨L,hL,hLx,hLi⟩ := exists_smooth_fiber_log (zero_mem_injectivityDomain (n := n) x) + simp only [riemannianExp_zero] at hL hLx hLi + let d : ℝ → TangentSpace 𝓘(ℝ,Model n) x := fun h => L (X h) + have hd0 : Tendsto d (𝓝[>] 0) (𝓝 0) := by + rw [←hLx] + exact hL.continuousAt.tendsto.comp hX0 + have hdrep : ∀ᶠ h : ℝ in 𝓝[>] 0, riemannianExp x (d h)=X h := + hX0.eventually hLi + have hH : 0 ≤ H := (hbound 0).1.trans (hbound 0).2 + refine ⟨X,d,H/β,div_nonneg hH hβ.le,hX,hX0,hd0,?_⟩ + filter_upwards [hdrep,hd0.eventually hgrowth,hXbound] with h hrep hgr hbo + refine ⟨hrep,?_⟩ + rw [hrep] at hgr + change β*‖d h‖^2≤g b (X h)-g b x+(cost (X h) z-cost x z)/t at hgr + change g b (X h)+cost (X h) z/t≤g b x+cost x z/t+H*h at hbo + rw [sub_div] at hgr + apply (mul_le_mul_iff_left₀ hβ).mp + calc ‖d h‖^2*β ≤ H*h := by nlinarith only [hgr,hbo] + _ = H/β*h*β := by field_simp + +lemma WeakMTW.modified_prefix_weighted_bound (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {a D b t H U : ℝ} + {B : ℝ → ℝ} (hB : Continuous B) (hbound : ∀ s, 0 ≤ B s ∧ B s ≤ H) + {ι : Type*} [Fintype ι] [Nonempty ι] {x : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (m : ι → ℝ) + (hm : ∀ i, 0 < m i) (hsum : ∑ i, m i=1) + (hmin : ∀ i, p i∈minimizingVectors x) + (hactive : ∀ i, contactGap (cTransform (modifiedDatum v a D b B)) + (modifiedDatum v a D b B) x (riemannianExp x (p i))=0) + (ht : 0 e0 h/h) (𝓝[>] 0) (𝓝 0)) + (hupper : let z := riemannianExp x (t • (∑ i, m i • p i)) + ∀ᶠ h in 𝓝[>] 0, + hopfLax t (cTransform (modifiedDatum v a D (b-h) B)) z- + hopfLax t (cTransform (modifiedDatum v a D b B)) z≤h*U+e0 h) : + ∑ i, m i*B ((v (riemannianExp x (p i))-a)/D) ≤ U := by + classical + let E := TangentSpace 𝓘(ℝ,Model n) x + let : FiniteDimensional ℝ E := inferInstanceAs (FiniteDimensional ℝ (Model n)) + let r := ∑ i, m i • p i + let z := riemannianExp x (t • r) + let w := modifiedDatum v a D b B + have hw : Continuous w := continuous_modifiedDatum hv a D b hB + have hAS : range p ⊆ activeLogs (n := n) w x := by + rintro _ ⟨i,rfl⟩ + exact ⟨hmin i,hactive i⟩ + have hr : r∈convexHull ℝ (range p) := + (convex_convexHull ℝ (range p)).sum_mem (fun i _ => (hm i).le) hsum + (fun i _ => subset_convexHull ℝ (range p) (mem_range_self i)) + have hID : ∀ q∈convexHull ℝ (range p), t • q∈injectivityDomain x := + fun q hq => hmtw.active_hull_precut hw ht ht1 x q ((convexHull_mono hAS) hq) + have hrt := hID r hr + obtain ⟨q,htq,hq1⟩ := exists_between ht1 + have hq : 0 contracted_minimizer_mem_injectivityDomain (hmin i) hq hq1 + let f : ι → E → ℝ := fun i d => + t⁻¹*(normalCost x (t • r) d-normalCost x (t • r) 0)- + q⁻¹*(normalCost x (q • p i) d-normalCost x (q • p i) 0) + let A : ι → E := fun i => p i-r + let Q : ι → E →L[ℝ] E →L[ℝ] ℝ := fun i => fderiv ℝ (fderiv ℝ (f i)) 0 + have hleft : ContDiffAt ℝ 2 (normalCost x (t • r)) 0 := + (normalCost_contDiffAt hrt).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hright : ∀ i, ContDiffAt ℝ 2 (normalCost x (q • p i)) 0 := + fun i => (normalCost_contDiffAt (hqi i)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hf : ∀ i, ContDiffAt ℝ 2 (f i) 0 := fun i => + (contDiffAt_const.mul (hleft.sub contDiffAt_const)).sub + (contDiffAt_const.mul ((hright i).sub contDiffAt_const)) + have hf0 : ∀ i, f i 0=0 := fun i => by simp only [f,sub_self,mul_zero] + have hfirst : ∀ i, fderiv ℝ (f i) 0=innerSL ℝ (A i) := by + intro i + have HD := (((normalCost_hasFDerivAt_zero hrt).sub_const + (normalCost x (t • r) 0)).const_smul t⁻¹).sub + (((normalCost_hasFDerivAt_zero (hqi i)).sub_const + (normalCost x (q • p i) 0)).const_smul q⁻¹) + have HD' : HasFDerivAt (f i) (innerSL ℝ (A i)) 0 := by + apply HD.congr_fderiv + ext v + simp only [A,sub_apply,smul_apply,innerSL_apply_apply,inner_neg_left, + real_inner_smul_left,inner_sub_left,smul_eq_mul] + field_simp [ht.ne',hq.ne'] + ring + exact HD'.fderiv + have hsecond : ∀ i v, Q i v v= + hessianValue x (t • r) v/t-hessianValue x (q • p i) v/q := by + intro i v + dsimp only [Q,f] + rw [second_fderiv_scaled_differences hleft (hright i)] + rw [hessianValue_eq_normalHessian hrt,hessianValue_eq_normalHessian (hqi i)] + simp only [normalHessian,div_eq_mul_inv] + ring + have hbar : ∑ i, m i • A i=0 := by + simp only [A,smul_sub,Finset.sum_sub_distrib,←Finset.sum_smul,hsum,one_smul,r,sub_self] + have hQ : ∀ v∈(Submodule.span ℝ (range A))ᗮ, 0 ≤ (∑ i, m i • Q i) v v := by + intro v hv + by_cases hv0 : v=0 + · simp [hv0] + have horth : ∀ i, inner ℝ v (p i-r)=0 := by + intro i + rw [real_inner_comm] + exact (Submodule.mem_orthogonal _ _).mp hv (A i) + (Submodule.subset_span (mem_range_self i)) + have HS := hmtw.finite_transverse_slack_strict p m hm hsum hmin ht htq hq1 hID hv0 horth + have HQ : (∑ i, m i • Q i) v v= + hessianValue x (t • r) v/t-∑ i, m i*(hessianValue x (q • p i) v/q) := by + simp only [sum_apply,smul_apply,smul_eq_mul,hsecond,mul_sub,Finset.sum_sub_distrib, + ←Finset.sum_mul,hsum,one_mul] + rw [HQ] + exact (sub_pos.mpr HS).le + obtain ⟨hval,X,d,K,hK,hX,hX0,hd0,hd⟩ := + hmtw.modified_pole_movement hv hB hbound p m hm hsum hmin hactive ht ht1 + let V : ℝ → ℝ := fun h => hopfLax t (cTransform (modifiedDatum v a D (b-h) B)) z- + hopfLax t (cTransform (modifiedDatum v a D b B)) z + let e : ι → ℝ → ℝ := fun i h => f i (d h)-inner ℝ (A i) (d h)-Q i (d h) (d h)/2 + have HE : ∀ i, Tendsto (fun h => e i h/h) (𝓝[>] 0) (𝓝 0) := by + intro i + have HR := contDiffAt_second_order_remainder (hf i) + simp only [hf0,sub_zero,hfirst,innerSL_apply_apply] at HR + have Hres := second_remainder_along_sqrt (d := d) (h := fun h : ℝ => h) HR hd0 + (show ∀ᶠ h : ℝ in 𝓝[>] 0, 0 ≤ h from + (show ∀ᶠ h : ℝ in 𝓝[>] 0, 0 < h from self_mem_nhdsWithin).mono (fun _ h => h.le)) + (hd.mono (fun _ h => h.2)) + exact Hres + have HC : ∀ᶠ h : ℝ in 𝓝[>] 0, ∀ i, + h*B ((v (riemannianExp x (p i))-a)/D)+inner ℝ (A i) (d h)+ + Q i (d h) (d h)/2+e i h≤V h := by + filter_upwards [hd] with h hdh i + have HS := modified_active_split_contact hv hB (hmin i) (hactive i) + hq hq1 (t := t) (h := h) (z := z) (x' := X h) + rw [←hX h,←hval] at HS + change h*B ((v (riemannianExp x (p i))-a)/D)+ + (cost (X h) z-cost x z)/t- + (cost (X h) (riemannianExp x (q • p i))-cost x (riemannianExp x (q • p i)))/q≤V h at HS + rw [←hdh.1] at HS + have HF : f i (d h)=(cost (riemannianExp x (d h)) z-cost x z)/t- + (cost (riemannianExp x (d h)) (riemannianExp x (q • p i))- + cost x (riemannianExp x (q • p i)))/q := by + simp only [f,normalCost,riemannianExp_zero,z,div_eq_mul_inv,mul_comm] + dsimp only [e] + rw [HF] + linarith only [HS] + exact weighted_parameter_bound (l := 𝓝[>] (0 : ℝ)) (h := fun h : ℝ => h) A (fun i => B ((v (riemannianExp x (p i))-a)/D)) Q + hm hsum hbar hK (show ∀ᶠ h : ℝ in 𝓝[>] 0, 0 < h from self_mem_nhdsWithin) + (tendsto_id.mono_right nhdsWithin_le_nhds) (hd.mono (fun _ h => h.2)) HE he0 hupper HC hQ + +lemma WeakMTW.modified_parameter_inequality + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {a D b bplus t H : ℝ} + {Bc Bo : ℝ → ℝ} (hc : Continuous Bc) (ho : Continuous Bo) + (hbound : ∀ s, 0 ≤ Bo s ∧ Bo s ≤ H) + {ι : Type*} [Fintype ι] [Nonempty ι] {x y : M} + (p : ι → TangentSpace 𝓘(ℝ,Model n) x) (m : ι → ℝ) + (hm : ∀ i, 0 < m i) (hsum : ∑ i, m i=1) + (hmin : ∀ i, p i∈minimizingVectors x) + (hactive : ∀ i, contactGap (cTransform (modifiedDatum v a D b Bo)) + (modifiedDatum v a D b Bo) x (riemannianExp x (p i))=0) + (ht : 0 hopfLax (1-t) (modifiedDatum v a D β Bc) z + let f : M → ℝ := fun w => modifiedDatum v a D b Bc w+cost w z/(1-t) + let G : M → ℝ := fun w => Bc ((v w-a)/D) + have hf : Continuous f := (continuous_modifiedDatum hv a D b hc).add + ((continuous_cost_left z).div_const (1-t)) + have hG : Continuous G := hc.comp ((hv.sub continuous_const).div_const D) + have hcval : C b=f y := (hcenter y).mpr rfl + have hfmin : ∀ w, f y≤f w := by + intro w + rw [←hcval] + exact hopfLax_le (continuous_modifiedDatum hv a D b hc) (1-t) z w + have hfunique : ∀ w, f w=f y → w=y := fun w hw => + (hcenter w).mp (hcval.trans hw.symm) + choose Y hY hYmin using (fun h : ℝ => + exists_hopfLax_minimizer (continuous_modifiedDatum hv a D (b-h) hc) (1-t) z) + have hh : ∀ᶠ h : ℝ in 𝓝[>] 0, 0 h) (𝓝[>] 0) (𝓝 0) := + tendsto_id.mono_right nhdsWithin_le_nhds + have HCY : ∀ᶠ h : ℝ in 𝓝[>] 0, ∀ w, f (Y h)-h*G (Y h)≤f w-h*G w := by + apply Eventually.of_forall + intro h w + have H := hYmin h w + dsimp only [f,G,modifiedDatum] at H ⊢ + linarith only [H] + have HC0 : Tendsto (fun h => (C (b-h)-C b)/h) (𝓝[>] 0) (𝓝 (-G y)) := by + have H := affine_minimum_derivative hf hG hfmin hfunique hh hh0 HCY + apply H.congr' + apply Eventually.of_forall + intro h + dsimp only [C] + rw [hY h,show hopfLax (1-t) (modifiedDatum v a D b Bc) z=f y from hcval] + dsimp only [f,G,modifiedDatum] + congr 1 + ring + let dP := (1:ℝ)/4096+4*b/bplus + have HP0 : Tendsto (fun h => (parameterPenalty bplus (b-h)-parameterPenalty bplus b)/h) + (𝓝[>] 0) (𝓝 (-dP)) := by + have H : Tendsto (fun h : ℝ => 2*h/bplus-dP) (𝓝[>] 0) (𝓝 (-dP)) := by + simpa using ((tendsto_const_nhds.mul hh0).div_const bplus).sub tendsto_const_nhds + apply H.congr' + filter_upwards [hh] with h hpos + dsimp only [parameterPenalty,dP] + field_simp [hpos.ne',hbp.ne'] + ring + let U := G y-dP + let e0 : ℝ → ℝ := fun h => parameterPenalty bplus (b-h)-parameterPenalty bplus b- + (C (b-h)-C b)-h*U + have HE0 : Tendsto (fun h => e0 h/h) (𝓝[>] 0) (𝓝 0) := by + have H := (HP0.sub HC0).sub (tendsto_const_nhds (x := U)) + have H' : Tendsto (fun h => + (parameterPenalty bplus (b-h)-parameterPenalty bplus b)/h- + (C (b-h)-C b)/h-U) (𝓝[>] 0) (𝓝 0) := by + have hlimit : -dP - -G y - U = 0 := by dsimp only [U]; ring + simpa only [hlimit] using H + apply H'.congr' + filter_upwards [hh] with h hpos + dsimp only [e0] + field_simp [hpos.ne'] + have hb0 : Tendsto (fun h : ℝ => b-h) (𝓝[>] 0) (𝓝 b) := by + simpa using tendsto_const_nhds.sub hh0 + have HU : ∀ᶠ h : ℝ in 𝓝[>] 0, + hopfLax t (cTransform (modifiedDatum v a D (b-h) Bo)) z- + hopfLax t (cTransform (modifiedDatum v a D b Bo)) z≤h*U+e0 h := by + filter_upwards [hb0.eventually hmax] with h hmh + dsimp only [regularizedComparison] at hmh + dsimp only [e0,C] + linarith only [hmh] + have Hlow := hmtw.modified_prefix_weighted_bound hv ho hbound p m hm hsum hmin hactive ht ht1 HE0 HU + constructor + · change dP≤G y-_ + change _≤G y-dP at Hlow + linarith only [Hlow] + · have Hpos : 0≤4*b/bplus := div_nonneg (mul_nonneg (by norm_num) hb) hbp.le + linarith only [Hpos] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualScaleSmallness.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualScaleSmallness.lean new file mode 100644 index 0000000000000000000000000000000000000000..4e5ed11250f7b9b0fcd565a61ac2192a81adf1f2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualScaleSmallness.lean @@ -0,0 +1,77 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +def lowerGapScale (A J:ℝ):ℝ := Real.exp (-(A+2*J/3)) +def upperGapScale (A J:ℝ):ℝ := Real.exp (-(A+J/3)) + +lemma gap_scale_ratios (A J:ℝ) : + Real.exp (-(A+J))/lowerGapScale A J=Real.exp (-J/3) ∧ + lowerGapScale A J/upperGapScale A J=Real.exp (-J/3) ∧ + upperGapScale A J/Real.exp (-A)=Real.exp (-J/3) := by + simp only [lowerGapScale,upperGapScale,←Real.exp_sub] + constructor + · congr 1; ring + constructor <;> congr 1 <;> ring + +lemma exists_uniform_plateau_smallness {C eps:ℝ} (hC:0 ≤ C) (heps:0 < eps) : + ∃J:ℝ,4 ≤ J ∧ Real.exp (2/J) ≤ 1+eps ∧ + ∀A D:ℝ,J^2 ≤ A → 0 < D → |Real.log D| ≤ C+A/J^2+J⁻¹ → + Real.exp (-(A+J)) ≤ eps*lowerGapScale A J ∧ + lowerGapScale A J ≤ eps*upperGapScale A J ∧ + upperGapScale A J ≤ eps*Real.exp (-A) ∧ + (∀k:ℕ,k ≤ 2 → upperGapScale A J ≤ eps*D^k) := by + have ht : Tendsto (fun J:ℝ=>Real.exp (2*C+2-J/3)) atTop (𝓝 0) := by + apply Real.tendsto_exp_atBot.comp + simpa only [sub_eq_add_neg,Function.comp_def,id_eq] using tendsto_const_nhds.add_atBot + (tendsto_neg_atTop_atBot.comp (tendsto_id.atTop_div_const (by norm_num : (0:ℝ)<3))) + have hr : Tendsto (fun J:ℝ=>Real.exp (-J/3)) atTop (𝓝 0) := by + apply Real.tendsto_exp_atBot.comp + simpa only [Function.comp_def,neg_div,id_eq] using + (tendsto_neg_atTop_atBot.comp (tendsto_id.atTop_div_const (by norm_num : (0:ℝ)<3))) + have hd : Tendsto (fun J:ℝ=>Real.exp (2/J)) atTop (𝓝 1) := by + simpa only [Real.exp_zero,Function.comp_def] using Real.continuous_exp.continuousAt.tendsto.comp + (show Tendsto (fun J:ℝ=>2/J) atTop (𝓝 0) from tendsto_const_nhds.div_atTop tendsto_id) + obtain ⟨J,hJ,Ht,Hr,Hd⟩ := ((eventually_ge_atTop (4:ℝ)).and + ((ht.eventually (gt_mem_nhds heps)).and + ((hr.eventually (gt_mem_nhds heps)).and (hd.eventually (gt_mem_nhds (by linarith : (1:ℝ)<1+eps)))))).exists + refine ⟨J,hJ,Hd.le,?_⟩ + intro A D hA hD hlog + have hJ0:0 < J:=by linarith + have hJ2:16 ≤ J^2:=by nlinarith only [hJ] + have hA0:0 ≤ A:=(sq_nonneg J).trans hA + have hfrac:A/J^2 ≤ A/16:=by + apply div_le_div_of_nonneg_left hA0 (by norm_num) hJ2 + have hinv:J⁻¹ ≤ 1:=by exact inv_le_one_of_one_le₀ (by linarith) + have hlog': -(C+A/16+1) ≤ Real.log D:=by + have H:=neg_abs_le (Real.log D) + linarith only [H,hlog,hfrac,hinv] + obtain ⟨H1,H2,H3⟩:=gap_scale_ratios A J + refine ⟨?_,?_,?_,?_⟩ + · exact (div_le_iff₀ (Real.exp_pos _)).mp (H1.le.trans Hr.le) + · exact (div_le_iff₀ (Real.exp_pos _)).mp (H2.le.trans Hr.le) + · exact (div_le_iff₀ (Real.exp_pos _)).mp (H3.le.trans Hr.le) + · intro k hk + have hex : -(A+J/3)-(k:ℝ)*Real.log D ≤ 2*C+2-J/3 := by + interval_cases k <;> norm_num <;> nlinarith only [hlog',hA0,hC] + have He:= (Real.exp_le_exp.mpr hex).trans Ht.le + have heq: Real.exp (-(A+J/3)-(k:ℝ)*Real.log D)=upperGapScale A J/D^k := by + rw [Real.exp_sub,Real.exp_nat_mul,Real.exp_log hD] + rfl + rw [heq] at He + exact (div_le_iff₀ (pow_pos hD k)).mp He + +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualSmallPlateau.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualSmallPlateau.lean new file mode 100644 index 0000000000000000000000000000000000000000..b76aa77da675bf14583011d3f2b3c2662b50b965 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualSmallPlateau.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.ActualPlateaus +import OAI.Analysis.BiholderTransport.Regularity.ActualScaleSmallness + +namespace OAI + +section + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology + +namespace WeakMTWTransport +section ActualSmallPlateau +variable {M:Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] [MeasurableSpace M] + +lemma exists_actual_small_plateau {vol:Measure M} {lam cap:ℝ} {x0:M} + (hc:(densityDualClass vol lam cap x0).Nonempty) + (hno:¬ HasPowerUpperBound (classOscillation vol lam cap x0)) {eps:ℝ} (heps:0 < eps) : + ∃r R bm bp:ℝ,0 < r ∧ 0 < R ∧ 0 < bm ∧ 0 < bp ∧ + ∃uv∈densityDualClass vol lam cap x0,∃x y0 y1:M, + y0∈gapSection uv.1 uv.2 x r ∧ y1∈gapSection uv.1 uv.2 x r ∧ + (∀y∈gapSection uv.1 uv.2 x r,uv.2 y0 ≤ uv.2 y) ∧ + (∀y∈gapSection uv.1 uv.2 x r,uv.2 y ≤ uv.2 y1) ∧ + sectionOscillation uv.1 uv.2 x r=uv.2 y1-uv.2 y0 ∧ 0 < uv.2 y1-uv.2 y0 ∧ + classOscillation vol lam cap x0 R ≤ (1+eps)*(uv.2 y1-uv.2 y0) ∧ + r ≤ eps*bm ∧ bm ≤ eps*bp ∧ bp ≤ eps*R ∧ + (∀k:ℕ,k ≤ 2 → bp ≤ eps*(uv.2 y1-uv.2 y0)^k) := by + obtain ⟨J,hJ,heJ,Hs⟩:=exists_uniform_plateau_smallness + (abs_nonneg (Real.log (1+Metric.diam (univ:Set M)^2))) heps + obtain ⟨A,uv,huv,x,y0,y1,hA,hy0,hy1,hlo,hhi,he,hD,hR,hlog⟩:= + exists_actual_plateau_section hc hno (show 1 ≤ J by linarith) + obtain ⟨hrbm,hbmbp,hbpR,hbpD⟩:=Hs A (uv.2 y1-uv.2 y0) hA hD hlog + refine ⟨Real.exp (-(A+J)),Real.exp (-A),lowerGapScale A J,upperGapScale A J, + Real.exp_pos _,Real.exp_pos _,Real.exp_pos _,Real.exp_pos _,uv,huv,x,y0,y1, + hy0,hy1,hlo,hhi,he,hD,?_,hrbm,hbmbp,hbpR,hbpD⟩ + exact hR.trans (mul_le_mul_of_nonneg_right heJ hD.le) + +end ActualSmallPlateau +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ActualTransferInequality.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualTransferInequality.lean new file mode 100644 index 0000000000000000000000000000000000000000..07554e70dcee4687413ab55fcca4819aed2237f2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ActualTransferInequality.lean @@ -0,0 +1,123 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ActualPoleJet +import OAI.Analysis.BiholderTransport.Calculus.FiniteTaylor + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {ι : Type*} [Fintype ι] [DecidableEq ι] + +lemma single_move_weighted_sum {E : Type*} [Zero E] (w : ι → ℝ) (i : ι) + (ψ : ι → E → ℝ) (d : E) : + ∑ j,w j*ψ j (if j=i then d else 0)-∑ j,w j*ψ j 0 = + w i*(ψ i d-ψ i 0) := by + rw [←Finset.sum_sub_distrib] + have he : ∀ j, w j*ψ j (if j=i then d else 0)-w j*ψ j 0 = + if j=i then w i*(ψ i d-ψ i 0) else 0 := by + intro j; by_cases hj:j=i <;> simp [hj,mul_sub] + simp_rw [he] + simp + +lemma WeakMTW.actual_transfer_inequality (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (hdual : IsCostDualPair u v) + {t s : ℝ} (ht : 0 + prefixDefect x t p (h.1,w i • h.2)- + ∑ j,w j*splitDefect x s (pj j) (h.1,if j=i then h.2 else 0) + let f := fun d : TangentSpace 𝓘(ℝ,Model n) x => + hopfLax t u (riemannianExp x (t • (p+w i • d)))-t*(‖p+w i • d‖^2/2) + let ψ := fun d : TangentSpace 𝓘(ℝ,Model n) x => + v (riemannianExp x (pj i+d))+‖pj i+d‖^2/2 + ∀ᶠ d in 𝓝 (0:TangentSpace 𝓘(ℝ,Model n) x), + S (a (p+w i • d),d)-S 0-(f d-f 0)≤w i*(ψ d-ψ 0) := by + dsimp only + let V := TangentSpace 𝓘(ℝ,Model n) x + let ψ : ι → V → ℝ := fun j d => v (riemannianExp x (pj j+d))+‖pj j+d‖^2/2 + have hpole : hopfPole (n := n) t u (riemannianExp x (t • p))=x := by + have hlimit := ((continuous_riemannianExp x).continuousAt.comp ha).tendsto.congr' harep + simpa only [Function.comp_apply, ha0, riemannianExp_zero] using eq_of_tendsto_nhds hlimit + have hf0 := (hmtw.actualPole_fixed_support hu hv hdual ht ht1 hp hpole).1 + have hψ0 : ∀ j, ψ j 0 = -u x := by + intro j + have H := hactive j + have hm := hmin j + change dist x (riemannianExp x (pj j))=‖pj j‖ at hm + rw [contactGap,cost,hm] at H + dsimp [ψ]; simp only [add_zero]; linarith + have hD0 : ∀ j,splitDefect x s (pj j) 0=0 := by + intro j + simp only [splitDefect,Prod.fst_zero,Prod.snd_zero,add_zero, + splitEndpointCost_axis hs hs1 (hleft j) (hright j),sub_self] + have hB0 : prefixDefect x t p 0=0 := by + simp only [prefixDefect,Prod.fst_zero,Prod.snd_zero,add_zero,prefixAction_axis hp,sub_self] + have hq : Tendsto (fun d:V => p+w i • d) (𝓝 0) (𝓝 p) := by + simpa only [ContinuousAt,smul_zero,add_zero] using + (show ContinuousAt (fun d:V => p+w i • d) 0 from by fun_prop) + filter_upwards [hq.eventually harep] with d hd + have henv := hmtw.hopfPole_minimizer hu hv hdual ht ht1 + (riemannianExp x (t • (p+w i • d))) + rw [←hd] at henv + let a' := a (p+w i • d) + let δ : ι → V := fun j => if j=i then d else 0 + have hineq : -u (riemannianExp x a')≤∑ j,w j*(splitEndpointCost x s (a',pj j+δ j)+ + v (riemannianExp x (pj j+δ j))) := by + have H := Finset.sum_le_sum (s := Finset.univ) (fun j _ => + mul_le_mul_of_nonneg_left + (show -u (riemannianExp x a')≤ splitEndpointCost x s (a',pj j+δ j)+ + v (riemannianExp x (pj j+δ j)) from by + have HG := dualPair_gap_nonneg hv hdual (riemannianExp x a') + (riemannianExp x (pj j+δ j)) + have HC := normalCost_le_splitNormalAction x (pj j+δ j) a' (pj j+δ j) hs hs1 + dsimp only [contactGap] at HG + change cost (riemannianExp x a') (riemannianExp x (pj j+δ j))≤ + splitEndpointCost x s (a',pj j+δ j) at HC + linarith) (hw j)) + simpa only [←Finset.sum_mul,hsum,one_mul] using H + have hsumψ := single_move_weighted_sum w i ψ d + have hψsum : ∑ j,w j*ψ j 0 = -u x := by + simp only [hψ0,←Finset.sum_mul,hsum,one_mul] + rw [hψsum,hψ0 i] at hsumψ + have hψi0 := hψ0 i + dsimp only [ψ] at hψi0 + simp only [add_zero] at hψi0 + have hψi0w := congrArg (fun z:ℝ => w i*z) hψi0 + simp only [Prod.fst_zero,Prod.snd_zero,smul_zero,add_zero,ite_self, + ←Prod.zero_eq_mk,hD0,mul_zero,Finset.sum_const_zero,hB0,sub_zero,hf0] + dsimp only [prefixDefect,splitDefect,prefixAction] at * + simp only [mul_sub,Finset.sum_sub_distrib,Finset.sum_add_distrib,mul_add] at hineq ⊢ + have Hψ : ∑ j,w j*ψ j (δ j)= + (∑ j,w j*v (riemannianExp x (pj j+δ j)))+∑ j,w j*(‖pj j+δ j‖^2/2) := by + dsimp only [ψ]; simp only [mul_add,Finset.sum_add_distrib] + change (∑ j,w j*ψ j (δ j))- -u x=w i*(ψ i d- -u x) at hsumψ + rw [Hψ] at hsumψ + dsimp only [ψ] at hsumψ + dsimp only [a',δ] at hineq hsumψ + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/Alignment.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/Alignment.lean new file mode 100644 index 0000000000000000000000000000000000000000..961122155cabd68d7cef993fc780b0f5217da3eb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/Alignment.lean @@ -0,0 +1,184 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates +import OAI.Analysis.BiholderTransport.Regularity.HopfApproximation + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +lemma hopfLax_derivative_of_scaled_minimizer {u : M → ℝ} (hu : Continuous u) + {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 u x+cost x a/(t-ε)+cost a y/ε + have hG : HasMFDerivAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) G z.1 (innerSL ℝ z.2) := by + have H := (hasMFDerivAt_const (I := 𝓘(ℝ,Model n)) (I' := 𝓘(ℝ,ℝ)) + (u x+cost x a/(t-ε)) z.1).add (hshort.const_smul ε⁻¹) + have heD : 0+ε⁻¹ • innerSL ℝ (ε • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2) = + innerSL ℝ z.2 := by + ext v + simp only [zero_add,_root_.smul_apply,smul_eq_mul,innerSL_apply_apply, + real_inner_smul_left] + dsimp [z,w] + field_simp + replace H := H.congr_mfderiv heD + have heG : G = ((fun _ => u x+cost x a/(t-ε)) + + ε⁻¹ • fun y => dist (sprayFlow (t-ε) (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 y^2/2) := by + funext y + dsimp [G,cost,a,w] + ring + rw [heG] + exact H + have hmin : dist x z.1=t*‖p‖ := by + dsimp [z,w] + rw [←riemannianExp_smul,hp,norm_smul, + Real.norm_eq_abs,abs_of_pos ht] + have hleft : dist x a=(t-ε)*‖p‖ := + sprayFlow_minimizing_prefix w (sub_pos.mpr hεt).le (by linarith) hmin + have hright : dist a z.1=ε*‖p‖ := by + have H := sprayFlow_minimizing_subinterval w (sub_pos.mpr hεt).le (by linarith) hmin + simpa only [sub_sub_cancel] using H + have hcontact : hopfLax t u z.1=G z.1 := by + rw [heq] + dsimp [G,cost] + rw [hmin,hleft,hright] + field_simp + ring + have hle : ∀ y, hopfLax t u y≤G y := by + intro y + have H := cost_divided_triangle_two_times x a y (sub_pos.mpr hεt) hε + rw [sub_add_cancel] at H + exact (hopfLax_le hu t y x).trans (by dsimp [G]; linarith) + exact hd.hasMFDerivAt.congr_mfderiv + ((upper_contact_mfderiv hd hG.mdifferentiableAt (Filter.Eventually.of_forall hle) hcontact).trans hG.mfderiv) + +lemma hopfLax_backward_minimizer {u : M → ℝ} (hu : Continuous u) + {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma gradients_cancel_at_local_max {f g : M → ℝ} {z : M} + (hf : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f z) + (hg : MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) g z) + (hmax : ∀ᶠ a in 𝓝 z,f a+g a≤f z+g z) : + riemannianGradient g z= -riemannianGradient (n := n) f z := by + let : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) z) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + have H := upper_contact_mfderiv (hf.add hg) + (mdifferentiableAt_const (I := 𝓘(ℝ,Model n)) (I' := 𝓘(ℝ,ℝ))) hmax rfl + rw [(hasMFDerivAt_riemannianGradient hf).add + (hasMFDerivAt_riemannianGradient hg) |>.mfderiv, + (hasMFDerivAt_const (I := 𝓘(ℝ,Model n)) (I' := 𝓘(ℝ,ℝ)) (f z+g z) z).mfderiv] at H + have HE : riemannianGradient (n := n) f z+riemannianGradient (n := n) g z=0 := by + apply ext_inner_right ℝ + intro u + have H0 := congrArg (fun L => L u) H + change inner ℝ (riemannianGradient f z) u+inner ℝ (riemannianGradient g z) u=0 at H0 + simpa only [inner_add_left,inner_zero_left] using H0 + exact eq_neg_of_add_eq_zero_left (by simpa only [add_comm] using HE) + +lemma WeakMTW.hopf_maximum_aligned (hmtw : WeakMTW (n := n) (M := M)) + {w v : M → ℝ} (hw : Continuous w) (hv : Continuous v) + {t : ℝ} (ht : 0 hxy (e.toOpenPartialHomeomorph.injOn hx hy h) + exact (e.toOpenPartialHomeomorph.continuousAt hx).disjoint + (disjoint_nhds_nhds.mpr he) (e.toOpenPartialHomeomorph.continuousAt hy) + · exact (FiberBundle.continuous_proj F E).continuousAt.disjoint + (disjoint_nhds_nhds.mpr hb) (FiberBundle.continuous_proj F E).continuousAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterDetCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterDetCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..17ddc9cdc60f6ba0d4612e9177d10fa70e1d9a0c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterDetCompact.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingHessianLimit +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearCompact +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearMatrix +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section CenterDetCompact +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +local instance centerDetDualGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance centerDetDualSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +local instance centerDetBilinearGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance +local instance centerDetBilinearSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance + +lemma exists_center_matrix_limit {V C:ℕ → E →L[ℝ] E →L[ℝ] ℝ} + {C₀:E →L[ℝ] E →L[ℝ] ℝ} {a:ℕ → ℝ} {a₀ k₀:ℝ} + (hC:Tendsto C atTop (𝓝 C₀)) (ha:Tendsto a atTop (𝓝 a₀)) (hk:0 ‖C j‖) atTop (𝓝 ‖C₀‖) := hC.norm + have hCb:∀ᶠ j in atTop,‖C j‖≤‖C₀‖+1:=by + filter_upwards [hCn.eventually (gt_mem_nhds (show ‖C₀‖<‖C₀‖+1 by linarith))] with j hj + exact hj.le + have hbound:∀ᶠ j in atTop,‖V j‖≤‖C₀‖+1:=by + filter_upwards [hCb,hV] with j hj hv + apply symmetric_bilinear_norm_bound hv.1 (by positivity) + intro d + rw [abs_of_nonneg (hv.2.1 d)] + calc + V j d d ≤ C j d d:=hv.2.2.1 d + _ ≤ |C j d d|:=le_abs_self _ + _ ≤ ‖C j‖*‖d‖^2:=bilinear_quadratic_norm_bound _ _ + _ ≤ (‖C₀‖+1)*‖d‖^2:=mul_le_mul_of_nonneg_right hj (sq_nonneg _) + obtain ⟨V₀,σ,hσ,HV⟩:=exists_bilinear_limit hbound + have hve:=hσ.tendsto_atTop.eventually hV + have hvs:∀d e,V₀ d e=V₀ e d:=bilinear_limit_symm HV (hve.mono (fun j hj=>hj.1)) + have hvp:∀d,0≤V₀ d d:=bilinear_limit_nonneg HV (hve.mono (fun j hj=>hj.2.1)) + have hae:0≤a₀:=ge_of_tendsto (ha.comp hσ.tendsto_atTop) (hve.mono (fun j hj=>hj.2.2.2.1)) + have hdet:k₀≤a₀*(bilinearOperator V₀).det:=ge_of_tendsto + ((ha.comp hσ.tendsto_atTop).mul (bilinear_det_tendsto HV)) (hve.mono (fun j hj=>hj.2.2.2.2)) + have hdp:0 < (bilinearOperator V₀).det:=by + have H:=bilinear_det_nonneg hvs hvp + nlinarith only [hk,hdet,hae,H] + have hap:0hj.2.2.1 d)) + +lemma exists_center_matrix_limit_variable {V C:ℕ → E →L[ℝ] E →L[ℝ] ℝ} + {C₀:E →L[ℝ] E →L[ℝ] ℝ} {a k:ℕ → ℝ} {a₀ k₀:ℝ} + (hC:Tendsto C atTop (𝓝 C₀)) (ha:Tendsto a atTop (𝓝 a₀)) + (hk:Tendsto k atTop (𝓝 k₀)) (hk0:0hj.2.2.2.2)) +end CenterDetCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterFullPullback.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterFullPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..e250abef7da0fa3c170a828a85ff96d203791e4e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterFullPullback.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.SecondFderivAdd +import OAI.Analysis.BiholderTransport.Coordinates.NormalLowerTaylorBound +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CenterFullPullback +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma scalar_support_full_pullback_identity {a b : M} + {p : TangentSpace 𝓘(ℝ,Model n) a} {q : TangentSpace 𝓘(ℝ,Model n) b} + {l s : ℝ} {φ : ℝ → ℝ} {v : ℝ} + (hs : s≠0) (hp : s • p∈injectivityDomain a) + (hlp : l • p∈injectivityDomain a) (hq : q∈injectivityDomain b) + (hab : riemannianExp a (l • p)=b) + (hφ : ContDiffAt ℝ 2 φ v) (hφd : deriv φ v=l) + {R : TangentSpace 𝓘(ℝ,Model n) b → TangentSpace 𝓘(ℝ,Model n) a} + (hR : ContDiffAt ℝ ∞ R q) (hR0 : R q=0) + (hRe : ∀ᶠ w in 𝓝 q,riemannianExp a (R w)=riemannianExp b w) + (d : TangentSpace 𝓘(ℝ,Model n) b) : + ‖d‖^2+fderiv ℝ (fderiv ℝ (fun w=>scalarCostSupport φ v a p s + (riemannianExp b w))) q d d= + fderiv ℝ (fderiv ℝ (fun h=>scalarCostSupport φ v a p s + (riemannianExp a h))) 0 (fderiv ℝ R q d) (fderiv ℝ R q d)+ + hessianValue a (l • p) (fderiv ℝ R q d) := by + let S := fun h:TangentSpace 𝓘(ℝ,Model n) a=>scalarCostSupport φ v a p s (riemannianExp a h) + let C := normalCost a (l • p) + have hc : ContDiffAt ℝ 2 C 0 := + (normalCost_contDiffAt hlp).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + obtain ⟨hsC,hsD,_⟩ := scalarCostSupport_normal_jet hs hp hφ hφd + have hstat : fderiv ℝ (fun h=>S h+C h) 0=0 := by + rw [fderiv_fun_add (hsC.differentiableAt (by norm_num)) (hc.differentiableAt (by norm_num)), + hsD.fderiv,(normalCost_hasFDerivAt_zero hlp).fderiv] + simp only [map_neg,add_neg_cancel] + have hR2 := hR.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hcomp := second_fderiv_comp_stationary (f := fun h=>S h+C h) + (hR0.symm ▸ hsC.add hc) hR2 (by rwa [hR0]) d d + rw [hR0,second_fderiv_add_eq hsC hc] at hcomp + rw [hessianValue_eq_normalHessian hlp] + have he : (fun w=>S (R w)+C (R w))=ᶠ[𝓝 q] + (fun w=>scalarCostSupport φ v a p s (riemannianExp b w)+‖w‖^2/2) := by + filter_upwards [hRe,(isOpen_injectivityDomain b).mem_nhds hq] with w hw hwi + dsimp only [S,C,normalCost] + rw [hw,hab] + congr 1 + change dist (riemannianExp b w) b^2/2=‖w‖^2/2 + rw [dist_comm,injectivityDomain_subset_minimizingVectors b hwi] + have hsE : ContDiffAt ℝ 2 (fun w=>scalarCostSupport φ v a p s (riemannianExp b w)) q := + ((hR0.symm ▸ hsC).comp q hR2).congr_of_eventuallyEq + (hRe.mono (fun w hw=>congrArg (scalarCostSupport φ v a p s) hw.symm)) + rw [he.fderiv.fderiv_eq,second_fderiv_add_eq hsE + ((half_norm_sq_contDiff.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt), + add_apply,add_apply,half_norm_sq_second_fderiv] at hcomp + simpa only [innerSL_apply_apply,real_inner_self_eq_norm_sq,add_comm,S,C,normalHessian,add_apply] using hcomp + +omit [Nonempty M] in +lemma exists_uniform_center_full_pullback : + ∃ c>0,∀ᶠ l : ℝ in 𝓝 1, 0scalarCostSupport φ v a p ((1+l)/2) + (riemannianExp b w))) q d d := by + obtain ⟨c,hc,H⟩ := exists_uniform_center_support_pullback (n := n) (M := M) + refine ⟨c,hc,?_⟩ + filter_upwards [H] with l hl + intro hl0 hl1 a b p q hp hq hab hba φ v hφ hφd d + obtain ⟨R,hR,hR0,hRe,HR⟩ := hl hl1 a b p q hp hq hab hba φ v hφ hφd + have hs : 0<(1+l)/2 := by linarith + have hs1 : (1+l)/2<1 := by linarith + rw [scalar_support_full_pullback_identity hs.ne' + (contracted_minimizer_mem_injectivityDomain hp hs hs1) + (contracted_minimizer_mem_injectivityDomain hp hl0 hl1) hq hab hφ hφd hR hR0 hRe] + exact HR d + +end CenterFullPullback +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..28a090888141f539b166399f5f84bca13aa3e576 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleLimit.lean @@ -0,0 +1,124 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.Contact.CoordinateSupportGradient +import OAI.Analysis.BiholderTransport.Calculus.ShortGradientLimit + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterPoleLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +omit [Nonempty M] in +lemma coordinateBackward_negative_support_center {c : M} {v s l : ℝ} + {r : Model n} {φ : ℝ → ℝ} (hs : s≠0) + (hr : s • (show TangentSpace 𝓘(ℝ,Model n) c from r)∈injectivityDomain c) + (hφ : HasDerivAt φ l v) : + coordinateBackward c (1, extChartAt 𝓘(ℝ,Model n) c c, + -fderiv ℝ (fun w=>coordinateScalarSupport c φ + (((v,s),(extChartAt 𝓘(ℝ,Model n) c c,r)),w)) + (extChartAt 𝓘(ℝ,Model n) c c))=riemannianExp c (l • r) := by + let x := extChartAt 𝓘(ℝ,Model n) c c + have hx : x∈(extChartAt 𝓘(ℝ,Model n) c).target := + (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hb := (extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c) + have hL (d:Model n) : (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) c).symmL ℝ c d=d := by + rw [TangentBundle.symmL_trivializationAt_eq_core (mem_chart_source (Model n) c)] + exact tangentCoordChange_self (I := 𝓘(ℝ,Model n)) (mem_extChartAt_source c) + have hr' : s • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) c).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) c).symm x) r∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) c).symm x) := by + dsimp only [x] + rw [hb] + simpa only [hL] using hr + rw [(coordinateScalarSupport_hasFDerivAt hx hs hr' hφ).fderiv] + simp only [coordinateBackward,map_neg,map_smul,neg_smul,one_smul,neg_neg] + rw [movingNormal_eq hx,hb,hL] + change riemannianExp c (l • (riemannianCoordinateMetric c x).inverse ((riemannianCoordinateMetric c x) r))=_ + rw [(riemannianCoordinateMetric_isInvertible hx).inverse_apply_self] + +lemma parametric_short_center_pole_limit {a c : M} {ψ : P×Model n → ℝ} + {p : P} (L : ℝ≥0) + (hψ : ContDiffAt ℝ ∞ ψ (p,extChartAt 𝓘(ℝ,Model n) c c)) + {r : Model n} {v s l : ℝ} {φ : ℝ → ℝ} (hs : s≠0) + (hr : s • (show TangentSpace 𝓘(ℝ,Model n) c from r)∈injectivityDomain c) + (hφ : HasDerivAt φ l v) + (heq : (fun w=>ψ (p,w))=fun w=>coordinateScalarSupport c φ + (((v,s),(extChartAt 𝓘(ℝ,Model n) c c,r)),w)) + {pj : ℕ → P} {xj : ℕ → Model n} {tj τj : ℕ → ℝ} + {f : ℕ → M → ℝ} {F : ℕ → Model n → ℝ} {aj : ℕ → M} + (hp : Tendsto pj atTop (𝓝 p)) + (hxx : Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (ht : Tendsto tj atTop (𝓝 1)) (hτ : Tendsto τj atTop (𝓝 0)) + (ha : Tendsto aj atTop (𝓝 a)) (hτpos : ∀ᶠ i in atTop,0<τj i) + (hlip : ∀ᶠ i in atTop,LipschitzWith L (f i)) + (hbelow : ∀ᶠ i in atTop,∀ w,ψ (pj i,w)≤f i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (htouch : ∀ᶠ i in atTop,f i ((extChartAt 𝓘(ℝ,Model n) c).symm (xj i))=ψ (pj i,xj i)) + (hd : ∀ᶠ i in atTop,DifferentiableAt ℝ + (fun w=>hopfLax (τj i) (f i) ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (parametricShortForward c ψ ((pj i,τj i),xj i))) + (herr : Tendsto (fun i=>fderiv ℝ (F i) (parametricShortForward c ψ ((pj i,τj i),xj i))+ + fderiv ℝ (fun w=>hopfLax (τj i) (f i) ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (parametricShortForward c ψ ((pj i,τj i),xj i))) atTop (𝓝 0)) + (hback : ∀ᶠ i in atTop,coordinateBackward c (tj i, + parametricShortForward c ψ ((pj i,τj i),xj i), + fderiv ℝ (F i) (parametricShortForward c ψ ((pj i,τj i),xj i)))=aj i) : + a=riemannianExp c (l • r) := by + let x := extChartAt 𝓘(ℝ,Model n) c c + let z := fun i=>parametricShortForward c ψ ((pj i,τj i),xj i) + let j := fderiv ℝ (fun w=>ψ (p,w)) x + have hx : x∈(extChartAt 𝓘(ℝ,Model n) c).target := + (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hG := parametric_short_gradient_tendsto L hx hψ hp hxx hτ hτpos hlip hbelow htouch hd + have hF : Tendsto (fun i=>fderiv ℝ (F i) (z i)) atTop (𝓝 (-j)) := by + convert herr.sub hG using 1 <;> simp only [add_sub_cancel_right,zero_sub,j,z,x] + have hz : Tendsto z atTop (𝓝 x) := by + have HH := (parametricShortForward_contDiffAt hx hψ).continuousAt.tendsto.comp + ((hp.prodMk_nhds hτ).prodMk_nhds hxx) + change Tendsto z atTop (𝓝 (parametricShortForward c ψ ((p,0),x))) at HH + convert HH using 1 + simp only [parametricShortForward,shortForward_zero hx] + have HB := (coordinateBackward_contMDiffAt (q := (1,x,-j)) hx).continuousAt.tendsto.comp + (ht.prodMk_nhds (hz.prodMk_nhds hF)) + have HE : coordinateBackward c (1,x,-j)=a := tendsto_nhds_unique (HB.congr' hback) ha + rw [←HE] + dsimp only [j,x] + rw [heq] + exact coordinateBackward_negative_support_center hs hr hφ + +omit [Nonempty M] in +lemma reverse_minimizer_regular {a c : M} + {r : TangentSpace 𝓘(ℝ,Model n) c} {q : TangentSpace 𝓘(ℝ,Model n) a} + (hr : r∈injectivityDomain c) (hq : q∈minimizingVectors a) + (ha : riemannianExp c r=a) (hc : riemannianExp a q=c) : q∈injectivityDomain a := by + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨c,r⟩ + have hb : (reverseRay z).1=a := (reverseRay_base z).trans ha + have hR := reverseRay_regular (z := z) hr + have hE := reverseRay_endpoint z + generalize hw : reverseRay z=w + rw [hw] at hb hR hE + rcases w with ⟨b,p⟩ + change b=a at hb + subst b + have he := riemannianExp_interior_unique hR hq (hE.trans hc.symm) + exact he ▸ hR + +end CenterPoleLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleStationary.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleStationary.lean new file mode 100644 index 0000000000000000000000000000000000000000..45a4c7242ea9c786f290da16bc675057f2b6b65f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterPoleStationary.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound + +namespace OAI + +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterPoleStationary +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma CenterSequenceData.pole {a c:M} {u v:M → ℝ} {Φ:ℝ×ℝ → ℝ} {γ l:ℝ} + (hv:Continuous v) (hΦ:ContDiffAt ℝ ∞ Φ (γ,v c)) + (hder:deriv (fun s=>Φ (γ,s)) (v c)=l) (hl:0 < l) (hl1:l < 1) + {γj lj τj tj:ℕ → ℝ} {xj bj qj:ℕ → Model n} {zj:ℕ → M} + {F:ℕ → Model n → ℝ} + (D:CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F) + {r:Model n} (hr:(show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c) + (hγ:Tendsto γj atTop (𝓝 γ)) (hlm:Tendsto lj atTop (𝓝 l)) + (hτ:Tendsto τj atTop (𝓝 0)) (ht:Tendsto tj atTop (𝓝 1)) + (hx:Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hrr:Tendsto (fun i=>(D.row i).r) atTop (𝓝 r)) + (hτpos:∀ᶠ i in atTop,0 < τj i) (L:ℝ≥0) + (hLip:∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) : + a=riemannianExp c (l • r) := by + let p := (γ,((v c,(1+l)/2),(extChartAt 𝓘(ℝ,Model n) c c,r))) + let pj := fun i=>centerRowParameter c v (γj i) (lj i) (xj i) (D.row i).r + let ψ := jointScalarSupport (n := n) c Φ + have hp : Tendsto pj atTop (𝓝 p) := center_row_parameter_tendsto hv hγ hlm hx hrr + have hψ : ContDiffAt ℝ ∞ ψ (p,extChartAt 𝓘(ℝ,Model n) c c) := + center_limit_support_smooth hΦ hr hl hl1 + have hs : ((1+l)/2)≠0 := by linarith + have hr' := contracted_minimizer_mem_injectivityDomain hr (t := (1+l)/2) + (by linarith) (by linarith) + have hc := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hφinf : ContDiffAt ℝ ∞ (fun s=>Φ (γ,s)) (v c) := + hΦ.comp (v c) (contDiffAt_const.prodMk contDiffAt_id) + have hφ2 : ContDiffAt ℝ 2 (fun s=>Φ (γ,s)) (v c) := + hφinf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hφ : HasDerivAt (fun s=>Φ (γ,s)) l (v c) := by + rw [←hder] + exact (hφinf.differentiableAt (by simp)).hasDerivAt + have hforward (i : ℕ) : parametricShortForward c ψ ((pj i,τj i),xj i)= + extChartAt 𝓘(ℝ,Model n) c (zj i) := (D.row i).forward + have hbelow : ∀ᶠ i in atTop,∀ w,ψ (pj i,w)≤Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm w)) := + Eventually.of_forall (fun i=>(D.row i).below) + have htouch : ∀ᶠ i in atTop, + Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm (xj i)))=ψ (pj i,xj i) := + Eventually.of_forall (fun i=>(D.row i).touching.symm) + have ha : Tendsto (fun i=>(extChartAt 𝓘(ℝ,Model n) a).symm (bj i)) atTop (𝓝 a) := by + have hb0 := (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hy := (continuousAt_extChartAt_symm'' hb0).tendsto.comp hb + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] at hy + exact hy + have hd : ∀ᶠ i in atTop,DifferentiableAt ℝ + (fun w=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (parametricShortForward c ψ ((pj i,τj i),xj i)) := by + filter_upwards [D.derivative] with i hi + rw [hforward] + exact hi.1.self_of_nhds + have herr := D.gradient.congr' (Eventually.of_forall (fun i=>by rw [←hforward i])) + have hback : ∀ᶠ i in atTop,coordinateBackward c (tj i, + parametricShortForward c ψ ((pj i,τj i),xj i), + fderiv ℝ (F i) (parametricShortForward c ψ ((pj i,τj i),xj i)))= + (extChartAt 𝓘(ℝ,Model n) a).symm (bj i) := by + simpa only [hforward] using D.backward + have hstationary : a=riemannianExp c (l • r) := + parametric_short_center_pole_limit L hψ hs hr' hφ rfl hp hx ht hτ ha hτpos hLip + hbelow htouch hd herr hback + exact hstationary + +end CenterPoleStationary +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRayLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRayLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..3a8f0e60bb5a8090a0788c10b1fa4841d34364b2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRayLimit.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ReverseRegular +import OAI.Analysis.BiholderTransport.Regularity.ActiveGraphLimit +import OAI.Analysis.BiholderTransport.Coordinates.GraphCoordinates + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CenterRayLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + +def chartRay (c:M) (b r:Model n) : TangentBundle 𝓘(ℝ,Model n) M := + ⟨(extChartAt 𝓘(ℝ,Model n) c).symm b,chartFiberInverse c b r⟩ + +lemma chartRay_at_center (c:M) (r:Model n) : + chartRay c (extChartAt 𝓘(ℝ,Model n) c c) r=⟨c,r⟩ := by + simp only [chartRay,chartFiberInverse_at_center] + exact congrArg (fun y:M=>(⟨y,r⟩:TangentBundle 𝓘(ℝ,Model n) M)) + ((extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c)) + +lemma chartRay_tendsto {c:M} {b r:ℕ → Model n} {r0:Model n} + (hb:Tendsto b atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hr:Tendsto r atTop (𝓝 r0)) : + Tendsto (fun k=>chartRay c (b k) (r k)) atTop + (𝓝 (⟨c,r0⟩:TangentBundle 𝓘(ℝ,Model n) M)) := by + let χ:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨c,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hc:extChartAt 𝓘(ℝ,Model n) c c∈(extChartAt 𝓘(ℝ,Model n) c).target:= + (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have ht:(extChartAt 𝓘(ℝ,Model n) c c,r0)∈χ.target:= + (tangent_chart_target_iff _ _).mpr hc + have H: Tendsto (fun k=>χ.symm (b k,r k)) atTop + (𝓝 (χ.symm (extChartAt 𝓘(ℝ,Model n) c c,r0))):= + (continuousAt_extChartAt_symm'' ht).tendsto.comp (hb.prodMk_nhds hr) + rw [tangent_chart_symm_trivialization hc] at H + change Tendsto _ _ (𝓝 (chartRay c (extChartAt 𝓘(ℝ,Model n) c c) r0)) at H + rw [chartRay_at_center] at H + apply H.congr' + filter_upwards [hb.eventually ((isOpen_extChartAt_target _).mem_nhds hc)] with k hk + exact tangent_chart_symm_trivialization hk + +section +variable [CompactSpace M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +lemma modified_reverseRay_tendsto {c:M} {b r:ℕ → Model n} {l:ℕ → ℝ} {r0:Model n} {l0:ℝ} + (hb:Tendsto b atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hr:Tendsto r atTop (𝓝 r0)) (hl:Tendsto l atTop (𝓝 l0)) : + Tendsto (fun k=>reverseRay (tangentScale (l k) (chartRay c (b k) (r k)))) atTop + (𝓝 (reverseRay (⟨c,l0 • r0⟩:TangentBundle 𝓘(ℝ,Model n) M))) := by + exact continuous_reverseRay.continuousAt.tendsto.comp + (contMDiff_tangentScale.continuous.continuousAt.tendsto.comp + (hl.prodMk_nhds (chartRay_tendsto hb hr))) + +end + +lemma graph_coordinates_tendsto {q:ℕ → TangentBundle 𝓘(ℝ,Model n) M} + {q0:TangentBundle 𝓘(ℝ,Model n) M} (hq:Tendsto q atTop (𝓝 q0)) : + Tendsto (fun k=>graphBaseCoordinate q0.1 (q k)) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) q0.1 q0.1)) ∧ + Tendsto (fun k=>graphVelocityCoordinate q0.1 (q k)) atTop (𝓝 q0.2) := by + let χ:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) + (⟨q0.1,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hs:q0∈χ.source:=(tangent_chart_source_iff _ _).mpr (mem_extChartAt_source _) + have H:=((continuousOn_extChartAt _).continuousAt + ((isOpen_extChartAt_source _).mem_nhds hs)).tendsto.comp hq + have HV:Tendsto (fun k=>graphVelocityCoordinate q0.1 (q k)) atTop + (𝓝 (graphVelocityCoordinate q0.1 q0)):=H.snd_nhds + rw [graph_coordinates_at_center] at HV + exact ⟨H.fst_nhds,HV⟩ + +end CenterRayLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRegularCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRegularCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..f47c5d23d5685b5cafe3107eede3a5963f03c3d6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterRegularCompact.lean @@ -0,0 +1,51 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceCompact +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceRegular + +namespace OAI + +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterSequenceRegular +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma CenterSequenceData.regular_compact {a c:M} {u v:M → ℝ} {Φ:ℝ×ℝ → ℝ} {γ l:ℝ} + (hv:Continuous v) (hΦ:ContDiffAt ℝ ∞ Φ (γ,v c)) + (hder:deriv (fun s=>Φ (γ,s)) (v c)=l) (hl:0 < l) (hl1:l < 1) + {γj lj τj tj:ℕ → ℝ} {xj bj qj:ℕ → Model n} {zj:ℕ → M} + {F:ℕ → Model n → ℝ} + (D:CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F) + {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a) + (he:riemannianExp a q=c) + (hγ:Tendsto γj atTop (𝓝 γ)) (hlm:Tendsto lj atTop (𝓝 l)) + (hτ:Tendsto τj atTop (𝓝 0)) (ht:Tendsto tj atTop (𝓝 1)) + (hx:Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hτpos:∀ᶠ i in atTop,0 < τj i) (L:ℝ≥0) + (hLip:∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) : + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a := by + obtain ⟨σ,hσ,r,hr,hrr⟩:=center_support_family_subseq D.row hx + exact (D.comp σ hσ.tendsto_atTop).regular hv hΦ hder hl hl1 hr hq he + (hγ.comp hσ.tendsto_atTop) (hlm.comp hσ.tendsto_atTop) + (hτ.comp hσ.tendsto_atTop) (ht.comp hσ.tendsto_atTop) + (hx.comp hσ.tendsto_atTop) (hb.comp hσ.tendsto_atTop) hrr + (hσ.tendsto_atTop.eventually hτpos) L (hσ.tendsto_atTop.eventually hLip) + +end CenterSequenceRegular +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..a4d370823eda1647974cc76667271c5cf2f499d3 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceCompact.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterSequenceCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def CenterSequenceData.comp {a c : M} {u v : M → ℝ} {Φ : ℝ×ℝ → ℝ} + {γj lj τj tj : ℕ → ℝ} {xj bj qj : ℕ → Model n} {zj : ℕ → M} + {F : ℕ → Model n → ℝ} + (D : CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F) + (σ : ℕ → ℕ) (hσ : Tendsto σ atTop atTop) : + CenterSequenceData a c u v Φ (γj ∘ σ) (lj ∘ σ) (τj ∘ σ) (tj ∘ σ) + (xj ∘ σ) (bj ∘ σ) (qj ∘ σ) (zj ∘ σ) (F ∘ σ) where + row i := D.row (σ i) + endpoint i := D.endpoint (σ i) + derivative := hσ.eventually D.derivative + gradient := D.gradient.comp hσ + backward := hσ.eventually D.backward + +lemma exists_actual_center_gain : + ∃ c0>0,∀ᶠ l : ℝ in 𝓝 1, 0Φ (γ,s)) (v c)=l → + ∀ (γj lj τj tj : ℕ → ℝ) (xj bj qj : ℕ → Model n) (zj : ℕ → M) + (F : ℕ → Model n → ℝ), + CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F → + ∀ q : Model n, + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a → + riemannianExp a q=c → + Tendsto γj atTop (𝓝 γ) → Tendsto lj atTop (𝓝 l) → + Tendsto τj atTop (𝓝 0) → Tendsto tj atTop (𝓝 1) → + Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c)) → + Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)) → + Tendsto qj atTop (𝓝 q) → + (∀ᶠ i in atTop,0<τj i) → ∀ L : ℝ≥0, + (∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) → + ∀ ε : ℝ,0<ε → + ∀ᶠ i in atTop,∀ d : Model n, + c0*(1-l)*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + (iteratedDeriv 2 (fun s=>Φ (γ,s)) (v c)/l^2)* + (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2-ε*‖d‖^2 ≤ + coordinateCenterMatrix a (tj i) (hopfLax (τj i) (fun y=>Φ (γj i,v y))) + (bj i) (qj i) d d := by + obtain ⟨c0,hc0,H⟩ := exists_actual_center_sequential_gain (n := n) (M := M) + refine ⟨c0,hc0,?_⟩ + filter_upwards [H] with l hgain + intro hl hl1 a c u v Φ γ hv hΦ hder γj lj τj tj xj bj qj zj F D q hq he + hγ hlm hτ ht hx hb hqq hτpos L hLip ε hε + by_contra h + have hf := not_eventually.mp h + choose σ hσge hbad using frequently_atTop.mp hf + have hσ : Tendsto σ atTop atTop := tendsto_atTop_mono hσge tendsto_id + let D1 := D.comp σ hσ + obtain ⟨κ,hκ,r,hr,hrr⟩ := center_support_family_subseq D1.row (hx.comp hσ) + let D2 := D1.comp κ hκ.tendsto_atTop + have Hlow := hgain hl hl1 a c u v Φ γ hv hΦ hder + ((γj ∘ σ) ∘ κ) ((lj ∘ σ) ∘ κ) ((τj ∘ σ) ∘ κ) ((tj ∘ σ) ∘ κ) + ((xj ∘ σ) ∘ κ) ((bj ∘ σ) ∘ κ) ((qj ∘ σ) ∘ κ) ((zj ∘ σ) ∘ κ) + ((F ∘ σ) ∘ κ) D2 r q hr hq he + ((hγ.comp hσ).comp hκ.tendsto_atTop) ((hlm.comp hσ).comp hκ.tendsto_atTop) + ((hτ.comp hσ).comp hκ.tendsto_atTop) ((ht.comp hσ).comp hκ.tendsto_atTop) + ((hx.comp hσ).comp hκ.tendsto_atTop) ((hb.comp hσ).comp hκ.tendsto_atTop) + ((hqq.comp hσ).comp hκ.tendsto_atTop) hrr + (hκ.tendsto_atTop.eventually (hσ.eventually hτpos)) L + (hκ.tendsto_atTop.eventually (hσ.eventually hLip)) ε hε + obtain ⟨i,hi⟩ := Hlow.exists + exact hbad (κ i) hi + +end CenterSequenceCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceOriginalLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceOriginalLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..75c05db809560a7f17bdee5019b05d2c4b919544 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceOriginalLimit.lean @@ -0,0 +1,139 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OriginalCenterLimit +import OAI.Analysis.BiholderTransport.Volume.DensityOriginalJets +import OAI.Analysis.BiholderTransport.Regularity.CenterTrueRayCompact +import OAI.Analysis.BiholderTransport.Regularity.CenterRegularCompact +import OAI.Analysis.BiholderTransport.Calculus.ScalarSecond + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterSequenceOriginalLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance sequenceOrigDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance sequenceOrigDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance sequenceOrigBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance sequenceOrigBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +omit [MeasurableSpace M] [BorelSpace M] in +lemma exists_center_sequence_original_limit : ∃δ>0,∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀(a c:M) (u v:M → ℝ) (Φ:ℝ×ℝ → ℝ) (γ l χ:ℝ), + Continuous u → Continuous v → IsCostDualPair u v → ContDiff ℝ ∞ Φ → + deriv (fun s=>Φ (γ,s)) (v c)=l → l∈U → 0Φ (γj j,v y))) → + ∀(sj:ℕ → Model n) (Sj:ℕ → Model n →L[ℝ] Model n) + (g:Model n →L[ℝ] ℝ) (H:Model n →L[ℝ] Model n →L[ℝ] ℝ), + Tendsto (fun j=>innerSL ℝ (sj j)) atTop (𝓝 g) → + Tendsto (fun j=>(innerSL ℝ).comp (Sj j)) atTop (𝓝 H) → + (∀ᶠ j in atTop,OriginalCenterGood (n:=n) u χ ((extChartAt 𝓘(ℝ,Model n) c).symm (xj j)) ∧ + deriv (fun s=>Φ (γj j,s)) (v ((extChartAt 𝓘(ℝ,Model n) c).symm (xj j)))=lj j ∧ + (∀d e,inner ℝ (Sj j d) e=inner ℝ d (Sj j e)) ∧ + HasQuadraticExpansion (fun h=>Φ (γj j,v ((extChartAt 𝓘(ℝ,Model n) c).symm (xj j+h)))) (sj j) (Sj j)) → + ∃r:Model n,(show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c ∧ + reverseRay (⟨c,l • r⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩ ∧ + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0Φ (γ,s)) (v c)/l^2)* + (frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) q d)^2≤ + chartJetMatrix a c (extChartAt 𝓘(ℝ,Model n) a a) q g H d d) ∧ + 0(extChartAt 𝓘(ℝ,Model n) c).symm (xj j) + let pj (j:ℕ):TangentSpace 𝓘(ℝ,Model n) (yj j):= + if h:OriginalCenterGood (n:=n) u χ (yj j) then Classical.choose h else 0 + let Aj (j:ℕ):TangentSpace 𝓘(ℝ,Model n) (yj j) →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (yj j):= + if h:OriginalCenterGood (n:=n) u χ (yj j) then Classical.choose (Classical.choose_spec h) else 0 + have hPA:∀ᶠ j in atTop,NormalAlexandrovContact (n:=n) u (yj j) (pj j) (Aj j) ∧ + (∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator (yj j) (pj j)+Aj j) d) d) ∧ + χ≤expJacobian (yj j) (pj j)*(normalHessianOperator (yj j) (pj j)+Aj j).det:=by + filter_upwards [hgood] with j hj + have hj0 : OriginalCenterGood (n:=n) u χ (yj j) := hj.1 + simpa only [pj,Aj,dite_eq_left hj0] using Classical.choose_spec (Classical.choose_spec hj0) + have hray:∀ᶠ j in atTop,(⟨yj j,pj j⟩:TangentBundle 𝓘(ℝ,Model n) M)=chartRay c (xj j) (D.row j).r:=by + filter_upwards [hPA] with j hj + exact congrArg (fun p:TangentSpace 𝓘(ℝ,Model n) (yj j)=> + (⟨yj j,p⟩:TangentBundle 𝓘(ℝ,Model n) M)) + ((hj.1.active_eq hu ((D.row j).active hd)).symm) + obtain ⟨σ,hσ,r,hr,hrr,hshort⟩:=D.true_ray_compact hv (hΦ.contDiffAt) hder hl hl1 hq he + hγ hlm hτ ht hx hb hτpos L hLip + have hreg:=D.regular_compact hv hΦ.contDiffAt hder hl hl1 hq he hγ hlm hτ ht hx hb hτpos L hLip + have hfull:Tendsto (fun j=>(⟨yj (σ j),pj (σ j)⟩:TangentBundle 𝓘(ℝ,Model n) M)) atTop + (𝓝 (⟨c,r⟩:TangentBundle 𝓘(ℝ,Model n) M)):= + (chartRay_tendsto (hx.comp hσ.tendsto_atTop) hrr).congr' + (Filter.EventuallyEq.symm (hσ.tendsto_atTop.eventually hray)) + have hshort':Tendsto (fun j=>reverseRay (⟨yj (σ j),lj (σ j) • pj (σ j)⟩:TangentBundle 𝓘(ℝ,Model n) M)) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)):=by + apply hshort.congr' + filter_upwards [hσ.tendsto_atTop.eventually hray] with j hj + exact congrArg (fun w:TangentBundle 𝓘(ℝ,Model n) M=>reverseRay (tangentScale (lj (σ j)) w)) hj.symm + have hrev:reverseRay (⟨c,l • r⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩:= + tendsto_nhds_unique (modified_reverseRay_tendsto (hx.comp hσ.tendsto_atTop) hrr + (hlm.comp hσ.tendsto_atTop)) hshort + have hy:Tendsto yj atTop (𝓝 c):=by + have HH:=(continuousAt_extChartAt_symm'' (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) c)).tendsto.comp hx + rwa [(extChartAt 𝓘(ℝ,Model n) c).left_inv (mem_extChartAt_source c)] at HH + have hvy:Tendsto (fun j=>v (yj j)) atTop (𝓝 (v c)):=hv.continuousAt.tendsto.comp hy + have hκ:=((continuous_scalar_family_second hΦ).tendsto (γ,v c)).comp (hγ.prodMk_nhds hvy) + have hgood':∀ᶠ j in atTop,NormalAlexandrovContact (n:=n) u (yj j) (pj j) (Aj j) ∧ + (∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator (yj j) (pj j)+Aj j) d) d) ∧ + χ≤expJacobian (yj j) (pj j)*(normalHessianOperator (yj j) (pj j)+Aj j).det ∧ + ContDiffAt ℝ 2 (fun s=>Φ (γj j,s)) (cTransform u (yj j)) ∧ + deriv (fun s=>Φ (γj j,s)) (cTransform u (yj j))=lj j ∧ + (∀d e,inner ℝ (Sj j d) e=inner ℝ d (Sj j e)) ∧ + HasQuadraticExpansion (fun h=>Φ (γj j,cTransform u ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c (yj j)+h)))) (sj j) (Sj j):=by + filter_upwards [hgood,hPA] with j hj hP + refine ⟨hP.1,hP.2.1,hP.2.2,?_,?_,hj.2.2.1,?_⟩ + · exact ((hΦ.comp (contDiff_const.prodMk contDiff_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + · rw [←hd.2] + exact hj.2.1 + · rw [←hd.2] + dsimp only [yj] + rw [(extChartAt 𝓘(ℝ,Model n) c).right_inv (D.row j).chart] + exact hj.2.2.2 + refine ⟨r,hr,hrev,?_⟩ + apply Hδ u a c (fun j s=>Φ (γj (σ j),s)) (lj ∘ σ) (yj ∘ σ) + (fun j=>pj (σ j)) (fun j=>Aj (σ j)) (sj ∘ σ) (Sj ∘ σ) + l _ χ q r g H hlu hl hl1 hχ hreg he (hlm.comp hσ.tendsto_atTop) hfull hshort' + · rw [←hd.2] + exact hκ.comp hσ.tendsto_atTop + · exact hg.comp hσ.tendsto_atTop + · exact hH.comp hσ.tendsto_atTop + · exact hσ.tendsto_atTop.eventually hgood' +end CenterSequenceOriginalLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceRegular.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceRegular.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ea9bf9da89dafbb6ffda0bb2026562d3ea422bc --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterSequenceRegular.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound + +namespace OAI + +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterSequenceRegular +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma CenterSequenceData.regular {a c:M} {u v:M → ℝ} {Φ:ℝ×ℝ → ℝ} {γ l:ℝ} + (hv:Continuous v) (hΦ:ContDiffAt ℝ ∞ Φ (γ,v c)) + (hder:deriv (fun s=>Φ (γ,s)) (v c)=l) (hl:0 < l) (hl1:l < 1) + {γj lj τj tj:ℕ → ℝ} {xj bj qj:ℕ → Model n} {zj:ℕ → M} + {F:ℕ → Model n → ℝ} + (D:CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F) + {r q:Model n} (hr:(show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c) + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a) + (he:riemannianExp a q=c) + (hγ:Tendsto γj atTop (𝓝 γ)) (hlm:Tendsto lj atTop (𝓝 l)) + (hτ:Tendsto τj atTop (𝓝 0)) (ht:Tendsto tj atTop (𝓝 1)) + (hx:Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hrr:Tendsto (fun i=>(D.row i).r) atTop (𝓝 r)) + (hτpos:∀ᶠ i in atTop,0 < τj i) (L:ℝ≥0) + (hLip:∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) : + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a := by + let p := (γ,((v c,(1+l)/2),(extChartAt 𝓘(ℝ,Model n) c c,r))) + let pj := fun i=>centerRowParameter c v (γj i) (lj i) (xj i) (D.row i).r + let ψ := jointScalarSupport (n := n) c Φ + have hp : Tendsto pj atTop (𝓝 p) := center_row_parameter_tendsto hv hγ hlm hx hrr + have hψ : ContDiffAt ℝ ∞ ψ (p,extChartAt 𝓘(ℝ,Model n) c c) := + center_limit_support_smooth hΦ hr hl hl1 + have hs : ((1+l)/2)≠0 := by linarith + have hr' := contracted_minimizer_mem_injectivityDomain hr (t := (1+l)/2) + (by linarith) (by linarith) + have hc := (extChartAt 𝓘(ℝ,Model n) c).map_source (mem_extChartAt_source c) + have hφinf : ContDiffAt ℝ ∞ (fun s=>Φ (γ,s)) (v c) := + hΦ.comp (v c) (contDiffAt_const.prodMk contDiffAt_id) + have hφ2 : ContDiffAt ℝ 2 (fun s=>Φ (γ,s)) (v c) := + hφinf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hφ : HasDerivAt (fun s=>Φ (γ,s)) l (v c) := by + rw [←hder] + exact (hφinf.differentiableAt (by simp)).hasDerivAt + have hforward (i : ℕ) : parametricShortForward c ψ ((pj i,τj i),xj i)= + extChartAt 𝓘(ℝ,Model n) c (zj i) := (D.row i).forward + have hbelow : ∀ᶠ i in atTop,∀ w,ψ (pj i,w)≤Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm w)) := + Eventually.of_forall (fun i=>(D.row i).below) + have htouch : ∀ᶠ i in atTop, + Φ (γj i,v ((extChartAt 𝓘(ℝ,Model n) c).symm (xj i)))=ψ (pj i,xj i) := + Eventually.of_forall (fun i=>(D.row i).touching.symm) + have ha : Tendsto (fun i=>(extChartAt 𝓘(ℝ,Model n) a).symm (bj i)) atTop (𝓝 a) := by + have hb0 := (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hy := (continuousAt_extChartAt_symm'' hb0).tendsto.comp hb + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] at hy + exact hy + have hd : ∀ᶠ i in atTop,DifferentiableAt ℝ + (fun w=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (parametricShortForward c ψ ((pj i,τj i),xj i)) := by + filter_upwards [D.derivative] with i hi + rw [hforward] + exact hi.1.self_of_nhds + have herr := D.gradient.congr' (Eventually.of_forall (fun i=>by rw [←hforward i])) + have hback : ∀ᶠ i in atTop,coordinateBackward c (tj i, + parametricShortForward c ψ ((pj i,τj i),xj i), + fderiv ℝ (F i) (parametricShortForward c ψ ((pj i,τj i),xj i)))= + (extChartAt 𝓘(ℝ,Model n) a).symm (bj i) := by + simpa only [hforward] using D.backward + have hstationary : a=riemannianExp c (l • r) := + parametric_short_center_pole_limit L hψ hs hr' hφ rfl hp hx ht hτ ha hτpos hLip + hbelow htouch hd herr hback + exact reverse_minimizer_regular (contracted_minimizer_mem_injectivityDomain hr hl hl1) + hq hstationary.symm he + +end CenterSequenceRegular +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenterTrueRayCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterTrueRayCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..4256b411e9756952e8629d858d771f2544e56b9e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenterTrueRayCompact.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound +import OAI.Analysis.BiholderTransport.Regularity.CenterRayLimit +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceCompact +import OAI.Analysis.BiholderTransport.Regularity.CenterPoleStationary +import OAI.Analysis.BiholderTransport.Calculus.TrueCenterGradient + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section CenterTrueRayCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [MeasurableSpace M] [BorelSpace M] in +lemma CenterSequenceData.true_ray_compact {a c:M} {u v:M → ℝ} {Φ:ℝ×ℝ → ℝ} {γ l:ℝ} + (hv:Continuous v) (hΦ:ContDiffAt ℝ ∞ Φ (γ,v c)) + (hder:deriv (fun s=>Φ (γ,s)) (v c)=l) (hl:0 < l) (hl1:l < 1) + {γj lj τj tj:ℕ → ℝ} {xj bj qj:ℕ → Model n} {zj:ℕ → M} + {F:ℕ → Model n → ℝ} + (D:CenterSequenceData a c u v Φ γj lj τj tj xj bj qj zj F) + {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a) + (he:riemannianExp a q=c) + (hγ:Tendsto γj atTop (𝓝 γ)) (hlm:Tendsto lj atTop (𝓝 l)) + (hτ:Tendsto τj atTop (𝓝 0)) (ht:Tendsto tj atTop (𝓝 1)) + (hx:Tendsto xj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hτpos:∀ᶠ i in atTop,0 < τj i) (L:ℝ≥0) + (hLip:∀ᶠ i in atTop,LipschitzWith L (fun y=>Φ (γj i,v y))) : + ∃σ:ℕ → ℕ,StrictMono σ ∧ ∃r:Model n, + (show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c ∧ + Tendsto (fun i=>(D.row (σ i)).r) atTop (𝓝 r) ∧ + Tendsto (fun i=>reverseRay (tangentScale (lj (σ i)) + (chartRay c (xj (σ i)) (D.row (σ i)).r))) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) := by + obtain ⟨σ,hσ,r,hr,hrr⟩:=center_support_family_subseq D.row hx + have HP: a=riemannianExp c (l • r):= + (D.comp σ hσ.tendsto_atTop).pole hv hΦ hder hl hl1 hr + (hγ.comp hσ.tendsto_atTop) (hlm.comp hσ.tendsto_atTop) + (hτ.comp hσ.tendsto_atTop) (ht.comp hσ.tendsto_atTop) + (hx.comp hσ.tendsto_atTop) (hb.comp hσ.tendsto_atTop) hrr + (hσ.tendsto_atTop.eventually hτpos) L (hσ.tendsto_atTop.eventually hLip) + have HE:=reverse_minimizer_eq (contracted_minimizer_mem_injectivityDomain hr hl hl1) + hq HP.symm he + refine ⟨σ,hσ,r,hr,hrr,?_⟩ + have HT:=modified_reverseRay_tendsto (hx.comp hσ.tendsto_atTop) hrr + (hlm.comp hσ.tendsto_atTop) + have HE' : reverseRay (⟨c,l • r⟩ : TangentBundle 𝓘(ℝ,Model n) M) = + (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M) := by exact HE + rw [HE'] at HT + exact HT + +end CenterTrueRayCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CenteredQuadratic.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CenteredQuadratic.lean new file mode 100644 index 0000000000000000000000000000000000000000..239b0ae19bd7977c8200f0703c3f96b614c425ad --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CenteredQuadratic.lean @@ -0,0 +1,44 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.StationaryPullback + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section CenteredQuadratic +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma centered_half_norm_sq_c2 (z : E) : + ContDiff ℝ 2 (fun w : E => ‖w-z‖^2/2) := + (half_norm_sq_contDiff.comp (contDiff_id.sub contDiff_const)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + +lemma centered_half_norm_sq_fderiv (z : E) : + fderiv ℝ (fun w : E => ‖w-z‖^2/2) z=0 := by + have hq := (half_norm_sq_hasFDerivAt (z-z)).comp (f := fun w:E => w-z) z ((hasFDerivAt_id z).sub_const z) + simpa only [Function.comp_def,sub_self,map_zero,ContinuousLinearMap.zero_comp] using hq.fderiv + +lemma centered_half_norm_sq_second (z d : E) : + fderiv ℝ (fderiv ℝ (fun w : E => ‖w-z‖^2/2)) z d d=‖d‖^2 := by + have hc : ContDiffAt ℝ 2 (fun w:E => ‖w‖^2/2) (z-z) := + (half_norm_sq_contDiff.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + have H := second_fderiv_comp_stationary hc (g := fun w:E => w-z) + (contDiffAt_id.sub contDiffAt_const) + (by rw [sub_self,half_norm_sq_fderiv,map_zero]) d d + have hid : fderiv ℝ (fun w:E => w-z) z=ContinuousLinearMap.id ℝ E := + ((hasFDerivAt_id z).sub_const z).fderiv + simpa only [sub_self,hid,ContinuousLinearMap.id_apply, + half_norm_sq_second_fderiv,real_inner_self_eq_norm_sq] using H +end CenteredQuadratic + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CompactAE.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactAE.lean new file mode 100644 index 0000000000000000000000000000000000000000..efec6f975005151ca231d64c02a04358d4817d0f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactAE.lean @@ -0,0 +1,215 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.CompactDual +import OAI.Analysis.BiholderTransport.Regularity.ContinuousClosedRelationSelector + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory +open scoped Topology NNReal BoundedContinuousFunction + +namespace WeakMTWTransport + +section CompactAE +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +omit [Nonempty M] in + +lemma contact_gap_control_at (u v : M →ᵇ ℝ) (x y : M) + (hsingle : ∀ z, contactGap u v x z = 0 → z = y) + (hgap : ∀ z, 0 ≤ contactGap u v x z) (f : M →ᵇ ℝ) + {ε : ℝ} (hε : 0 < ε) : + ∃ δ : ℝ, 0 < δ ∧ ∀ z, contactGap u v x z ≤ δ → f y - f z ≤ ε := by + let G : M → ℝ := fun z => contactGap u v x z + let B : Set M := {z | ε ≤ f y - f z} + have hG : Continuous G := (continuous_const.add (continuous_cost_right x)).add v.continuous + have hB : IsCompact B := (isClosed_le continuous_const + (continuous_const.sub f.continuous)).isCompact + by_cases hne : B.Nonempty + · obtain ⟨z,hz,hmin⟩ := hB.exists_isMinOn hne hG.continuousOn + have hpos : 0 < G z := by + apply lt_of_le_of_ne (hgap z) + intro he + have heq := hsingle z he.symm + change ε ≤ f y - f z at hz + rw [heq,sub_self] at hz + exact (not_le.mpr hε) hz + refine ⟨G z / 2,half_pos hpos,?_⟩ + intro w hw + by_contra hn + have hm := hmin (le_of_lt (lt_of_not_ge hn)) + change G z ≤ contactGap u v x w at hm + linarith + · refine ⟨1,by norm_num,?_⟩ + intro z _ + by_contra hn + exact hne ⟨z,le_of_lt (lt_of_not_ge hn)⟩ + +lemma transform_perturbation_upper_at (u v : M →ᵇ ℝ) (x y : M) + (hsingle : ∀ z, contactGap u v x z = 0 → z = y) + (hgap : ∀ z, 0 ≤ contactGap u v x z) (f : M →ᵇ ℝ) + {ε : ℝ} (hε : 0 < ε) : + ∃ τ : ℝ, 0 < τ ∧ ∀ t : ℝ, 0 < t → t ≤ τ → + cTransform (fun z => v z + t * f z) x ≤ u x - t * f y + t * ε := by + obtain ⟨δ,hδ,hcontrol⟩ := contact_gap_control_at u v x y hsingle hgap f hε + have hden : 0 < 2 * ‖f‖ + 1 := by positivity + refine ⟨δ / (2 * ‖f‖ + 1),div_pos hδ hden,?_⟩ + intro t ht htτ + have htd : t * (2 * ‖f‖ + 1) ≤ δ := (le_div_iff₀ hden).mp htτ + have htbound : t * (2 * ‖f‖) ≤ δ := by nlinarith + rw [cTransform_le_iff (v := fun z => v z + t * f z) + (v.continuous.add (continuous_const.mul f.continuous))] + intro z + have hg := hgap z + have hbound : t * (f y - f z) ≤ contactGap u v x z + t * ε := by + by_cases hs : contactGap u v x z ≤ δ + · have hh := mul_le_mul_of_nonneg_left (hcontrol z hs) ht.le + nlinarith + · have hf1 := BoundedContinuousFunction.norm_coe_le_norm f y + have hf2 := BoundedContinuousFunction.norm_coe_le_norm f z + rw [Real.norm_eq_abs,abs_le] at hf1 hf2 + have hw : f y - f z ≤ 2 * ‖f‖ := by linarith [hf1.2,hf2.1] + have hh := mul_le_mul_of_nonneg_left hw ht.le + have hte : 0 ≤ t * ε := mul_nonneg ht.le hε.le + linarith + dsimp [contactGap] at hbound + nlinarith + +def transformedDifferenceQuotient (v f : M →ᵇ ℝ) (t : ℝ) : M →ᵇ ℝ := + t⁻¹ • (boundedCTransform (v + t • f) - boundedCTransform v) + +lemma transformedDifferenceQuotient_apply (v f : M →ᵇ ℝ) (t : ℝ) (x : M) : + transformedDifferenceQuotient v f t x = + (cTransform (fun z => v z + t * f z) x - cTransform v x) / t := by + simp only [transformedDifferenceQuotient,BoundedContinuousFunction.smul_apply, + BoundedContinuousFunction.sub_apply,boundedCTransform_apply,smul_eq_mul] + rw [div_eq_mul_inv,mul_comm] + rfl + +lemma transformedDifferenceQuotient_norm_le (v f : M →ᵇ ℝ) {t : ℝ} (ht : 0 < t) (x : M) : + ‖transformedDifferenceQuotient v f t x‖ ≤ ‖f‖ := by + have hh := boundedCTransform_nonexpansive (M := M) |>.dist_le_mul (v + t • f) v + simp only [NNReal.coe_one,one_mul,dist_eq_norm,add_sub_cancel_left,norm_smul, + Real.norm_eq_abs,abs_of_pos ht] at hh + have hp := BoundedContinuousFunction.norm_coe_le_norm + (boundedCTransform (v + t • f) - boundedCTransform v) x + have hbound := hp.trans hh + rw [transformedDifferenceQuotient,BoundedContinuousFunction.smul_apply,norm_smul, + Real.norm_eq_abs,abs_inv,abs_of_pos ht] + exact (inv_mul_le_iff₀ ht).mpr hbound + +lemma transformedDifferenceQuotient_tendsto_at (v f : M →ᵇ ℝ) (x y : M) + (hcontact : contactGap (cTransform v) v x y = 0) + (hsingle : ∀ z, contactGap (cTransform v) v x z = 0 → z = y) + {s : ℕ → ℝ} (hs : ∀ j, 0 < s j) (hlim : Tendsto s atTop (𝓝 0)) : + Tendsto (fun j => transformedDifferenceQuotient v f (s j) x) atTop (𝓝 (-f y)) := by + rw [Metric.tendsto_nhds] + intro ε hε + obtain ⟨τ,hτ,hup⟩ := transform_perturbation_upper_at (boundedCTransform v) v x y + hsingle (cTransform_gap_nonneg v.continuous x) f (half_pos hε) + have hevent : ∀ᶠ j in atTop, s j ≤ τ := + (hlim.eventually (eventually_lt_nhds hτ)).mono fun _ h => h.le + filter_upwards [hevent] with j hj + rw [transformedDifferenceQuotient_apply,Real.dist_eq,sub_neg_eq_add,abs_lt] + have hu := hup (s j) (hs j) hj + have hl := cTransform_gap_nonneg + (v.continuous.add (continuous_const.mul f.continuous) : + Continuous (fun z => v z + s j * f z)) x y + change cTransform (fun z => v z + s j * f z) x ≤ + cTransform v x - s j * f y + s j * (ε/2) at hu + dsimp only [contactGap] at hcontact + change 0 ≤ cTransform (fun z => v z + s j * f z) x + cost x y + (v y + s j * f y) at hl + have hlo : -f y ≤ (cTransform (fun z => v z + s j * f z) x - cTransform v x) / s j := by + apply (le_div_iff₀ (hs j)).mpr + nlinarith + have hhi : (cTransform (fun z => v z + s j * f z) x - cTransform v x) / s j ≤ -f y + ε/2 := by + apply (div_le_iff₀ (hs j)).mpr + nlinarith + constructor <;> linarith + +variable [MeasurableSpace M] [BorelSpace M] + +lemma dual_minimum_ae_integral_eq (μ ν : Measure M) [IsProbabilityMeasure μ] + [IsProbabilityMeasure ν] (v : M →ᵇ ℝ) (T : M → M) + (hcontact : ∀ x, contactGap (cTransform v) v x (T x) = 0) + (hsingle : ∀ᵐ x ∂μ, ∀ y, contactGap (cTransform v) v x y = 0 → y = T x) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective μ ν (boundedCTransform v,v) ≤ dualObjective μ ν (a,b)) + (f : M →ᵇ ℝ) : (∫ x, f (T x) ∂μ) = ∫ y, f y ∂ν := by + have hle (f : M →ᵇ ℝ) : (∫ x, f (T x) ∂μ) ≤ ∫ y, f y ∂ν := by + let s : ℕ → ℝ := fun j => 1 / ((j : ℝ) + 1) + have hs (j : ℕ) : 0 < s j := by dsimp [s]; positivity + have hslim : Tendsto s atTop (𝓝 0) := tendsto_one_div_add_atTop_nhds_zero_nat + have hlim : Tendsto (fun j => ∫ x, transformedDifferenceQuotient v f (s j) x ∂μ) + atTop (𝓝 (∫ x, -f (T x) ∂μ)) := by + apply tendsto_integral_of_dominated_convergence (fun _ => ‖f‖) + · intro j + exact (transformedDifferenceQuotient v f (s j)).continuous.aestronglyMeasurable + · exact integrable_const _ + · intro j + exact Eventually.of_forall (transformedDifferenceQuotient_norm_le v f (hs j)) + · filter_upwards [hsingle] with x hx + exact transformedDifferenceQuotient_tendsto_at v f x (T x) (hcontact x) hx hs hslim + have hineq (j : ℕ) : -(∫ y, f y ∂ν) ≤ + ∫ x, transformedDifferenceQuotient v f (s j) x ∂μ := by + let a := boundedCTransform (v + s j • f) + let b : M →ᵇ ℝ := v + s j • f + have hi := hmin a b (cTransform_gap_nonneg b.continuous) + have hb : (∫ y, b y ∂ν) = (∫ y, v y ∂ν) + s j * ∫ y, f y ∂ν := by + change (∫ y, v y + s j * f y ∂ν) = _ + rw [integral_add (v.integrable ν) ((f.integrable ν).const_mul (s j)), + integral_const_mul] + have hq : (∫ x, transformedDifferenceQuotient v f (s j) x ∂μ) = + ((∫ x, a x ∂μ) - (∫ x, boundedCTransform v x ∂μ)) / s j := by + change (∫ x, (s j)⁻¹ * (a x - boundedCTransform v x) ∂μ) = _ + rw [integral_const_mul,integral_sub (a.integrable μ) ((boundedCTransform v).integrable μ)] + rw [div_eq_mul_inv,mul_comm] + rw [hq] + apply (le_div_iff₀ (hs j)).mpr + change (∫ x, boundedCTransform v x ∂μ) + (∫ y, v y ∂ν) ≤ + (∫ x, a x ∂μ) + (∫ y, b y ∂ν) at hi + rw [hb] at hi + nlinarith + have hbound := ge_of_tendsto' hlim hineq + rw [integral_neg] at hbound + linarith + apply le_antisymm (hle f) + have hneg := hle (-f) + simp only [BoundedContinuousFunction.neg_apply,integral_neg] at hneg + linarith + +omit [CompactSpace M] [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma cost_contact_relation_isClosed (u v : M →ᵇ ℝ) : + IsClosed {z : M × M | contactGap u v z.1 z.2 = 0} := by + apply isClosed_eq _ continuous_const + exact ((u.continuous.comp continuous_fst).add + (((continuous_fst.dist continuous_snd).pow 2).div_const 2)).add + (v.continuous.comp continuous_snd) + +lemma dual_minimum_ae_pushforward (μ ν : Measure M) [IsProbabilityMeasure μ] + [IsProbabilityMeasure ν] (v : M →ᵇ ℝ) (T : M → M) + (hcontact : ∀ x, contactGap (cTransform v) v x (T x) = 0) + (hsingle : ∀ᵐ x ∂μ, ∀ y, contactGap (cTransform v) v x y = 0 → y = T x) + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective μ ν (boundedCTransform v,v) ≤ dualObjective μ ν (a,b)) : + AEMeasurable T μ ∧ Measure.map T μ = ν := by + have hT : AEMeasurable T μ := aemeasurable_closed_relation_selector + (cost_contact_relation_isClosed (boundedCTransform v) v) hcontact hsingle + refine ⟨hT,?_⟩ + apply ext_of_forall_integral_eq_of_IsFiniteMeasure + intro f + rw [integral_map hT f.continuous.aestronglyMeasurable] + exact dual_minimum_ae_integral_eq μ ν v T hcontact hsingle hmin f + +end CompactAE +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CompactDisk.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactDisk.lean new file mode 100644 index 0000000000000000000000000000000000000000..12cd1b8b5f71719daf43f120ccdb8e9e2e5835f6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactDisk.lean @@ -0,0 +1,134 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +namespace WeakMTWTransport +variable {B : Type*} [TopologicalSpace B] + {F : Type*} [NormedAddCommGroup F] [NormedSpace ℝ F] + {E : B → Type*} [TopologicalSpace (TotalSpace F E)] + [∀ x, NormedAddCommGroup (E x)] [∀ x, InnerProductSpace ℝ (E x)] + [FiberBundle F E] [VectorBundle ℝ F E] [IsContinuousRiemannianBundle F E] + +lemma continuous_bundle_norm : Continuous (fun z : TotalSpace F E => ‖z.2‖) := by + have h : Continuous (fun z : TotalSpace F E => inner ℝ z.2 z.2) := + (continuous_id : Continuous (id : TotalSpace F E → _)).inner_bundle continuous_id + simpa only [← norm_eq_sqrt_real_inner] using h.sqrt + +lemma isCompact_bundle_disk [CompactSpace B] [T2Space B] + [FiniteDimensional ℝ F] (R : ℝ) : + IsCompact {z : TotalSpace F E | ‖z.2‖ ≤ R} := by + classical + have hsclosed : IsClosed {z : TotalSpace F E | ‖z.2‖ ≤ R} := + isClosed_le continuous_bundle_norm continuous_const + by_cases hR : R < 0 + · have : {z : TotalSpace F E | ‖z.2‖ ≤ R} = ∅ := by + ext z + simp only [mem_ofPred_eq,mem_empty_iff_false,iff_false] + exact not_le.mpr ((hR.trans_le (norm_nonneg _))) + rw [this] + exact isCompact_empty + have hlocal (x : B) : ∃ C : ℝ, 0 < C ∧ ∃ K : Set B, + K ∈ 𝓝 x ∧ IsCompact K ∧ K ⊆ (trivializationAt F E x).baseSet ∧ + ∀ y ∈ K, ‖(trivializationAt F E x).continuousLinearMapAt ℝ y‖ < C := by + obtain ⟨C,hC,hbound⟩ := eventually_norm_trivializationAt_lt F E x + obtain ⟨K,hK,hKs,hKc⟩ := local_compact_nhds + (inter_mem ((trivializationAt F E x).open_baseSet.mem_nhds + (mem_baseSet_trivializationAt F E x)) hbound) + exact ⟨C,hC,K,hK,hKc,fun y hy => (hKs hy).1,fun y hy => (hKs hy).2⟩ + choose C hC K hKn hKc hKb hKC using hlocal + let L (x : B) : Set (TotalSpace F E) := + (trivializationAt F E x).toOpenPartialHomeomorph.symm '' + (K x ×ˢ Metric.closedBall (0 : F) (C x * R)) + have hLc (x : B) : IsCompact (L x) := by + apply ((hKc x).prod (isCompact_closedBall (0 : F) (C x * R))).image_of_continuousOn + apply (trivializationAt F E x).toOpenPartialHomeomorph.continuousOn_symm.mono + intro y hy + change y ∈ (trivializationAt F E x).target + exact (trivializationAt F E x).mem_target.mpr (hKb x hy.1) + obtain ⟨t,ht⟩ := finite_cover_nhds hKn + apply (t.isCompact_biUnion (fun x _ => hLc x)).of_isClosed_subset hsclosed + intro z hz + have hzm : z.1 ∈ ⋃ x ∈ t, K x := by rw [ht]; trivial + obtain ⟨x,hx,hzK⟩ := mem_iUnion₂.mp hzm + apply mem_iUnion₂.mpr ⟨x,hx,?_⟩ + have hzb := hKb x hzK + have hzs : z ∈ (trivializationAt F E x).source := + (trivializationAt F E x).mem_source.mpr hzb + refine ⟨(trivializationAt F E x) z,?_,?_⟩ + · refine ⟨?_,?_⟩ + · rwa [Trivialization.coe_fst _ hzs] + · rw [Metric.mem_closedBall,dist_zero_right] + have he : (trivializationAt F E x z).2 = + (trivializationAt F E x).continuousLinearMapAt ℝ z.1 z.2 := by + rw [Trivialization.continuousLinearMapAt_apply_of_mem ℝ _ hzb] + rw [he] + calc + _ ≤ ‖(trivializationAt F E x).continuousLinearMapAt ℝ z.1‖ * ‖z.2‖ := + ContinuousLinearMap.le_opNorm _ _ + _ ≤ C x * R := mul_le_mul (hKC x z.1 hzK).le hz (norm_nonneg _) (hC x).le + · exact (trivializationAt F E x).left_inv hzs + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CompactUniformSecondRemainder.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactUniformSecondRemainder.lean new file mode 100644 index 0000000000000000000000000000000000000000..6b23c2d771e9a6ea19fb74db159f9f4b4140a1f0 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CompactUniformSecondRemainder.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Calculus +import OAI.Analysis.BiholderTransport.Coordinates.ChartCostJets + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport + +lemma compact_uniform_second_remainder {Q E : Type*} + [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] + {P : Set Q} (hP : IsCompact P) {F : Q → E → ℝ} + (hF : ∀ q∈P, ContDiffAt ℝ ∞ (Function.uncurry F) (q,0)) : + ∃ B>0, ∃ d>0, ∀ q∈P, ∀ z : E, ‖z‖ fderiv ℝ (fderiv ℝ (F w.2)) w.1 + have hC : ∀ q∈P, ContinuousAt H (0,q) := by + intro q hq + exact (ContDiffAt.partial_snd_fderiv_two (hF q hq)).continuousAt.comp + (x := (0,q)) (f := fun w : E×Q => (w.2,w.1)) + (continuousAt_snd.prodMk continuousAt_fst) + obtain ⟨B,hB,HB⟩ := compact_eventually_fiberwise_bound hP + (f := fun _ : Q => ()) continuous_const (g := fun _ : E => ()) + (continuousAt_const (x := (0:E))) (h := H) (fun q hq _ => hC q hq) + have HS : ∀ᶠ z : E in 𝓝 0, ∀ q∈P, ()=() → ContDiffAt ℝ 2 (F q) z := by + apply compact_eventually_fiberwise hP (f := fun _ : Q => ()) continuous_const + (g := fun _ : E => ()) (continuousAt_const (x := (0:E))) + intro q hq _ + have He := ((hF q hq).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp) + have hc : ContinuousAt (fun w : E×Q => (w.2,w.1)) (0,q) := + continuousAt_snd.prodMk continuousAt_fst + filter_upwards [hc.tendsto.eventually He] with w hw + exact hw.comp w.1 (contDiffAt_const.prodMk contDiffAt_id) + obtain ⟨d,hd,hnear⟩ := Metric.eventually_nhds_iff.mp (HB.and HS) + refine ⟨B,hB,d,hd,?_⟩ + intro q hq z hz + have Hrem := first_order_remainder_le_of_hessian_bound (convex_ball (0:E) d) hB.le + (fun w hw => (hnear hw).2 q hq rfl) (fun w hw => (hnear hw).1 q hq rfl) + (show (0:E)∈ball 0 d by simpa only [mem_ball,dist_self] using hd) + (show z∈ball 0 d by simpa only [mem_ball,dist_zero_right] using hz) + simpa only [sub_zero] using Hrem + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ConfigurationCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ConfigurationCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a70fd0c585d1918f50b5053f9de004596b19ca6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ConfigurationCompact.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingCoordinateLimit +import OAI.Analysis.BiholderTransport.Regularity.ParametricActive + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ConfigurationCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma active_configuration_subseq {ι : Type*} [Fintype ι] [Nonempty ι] + [TopologicalSpace ι] [DiscreteTopology ι] + {a:M} {v:M → ℝ} (hv:Continuous v) {α D:ℝ} {B:ℝ → ℝ} (hB:Continuous B) + {β:ℕ → ℝ} {β₀:ℝ} (hβ:Tendsto β atTop (𝓝 β₀)) + {bj p:ℕ → Model n} {p₀:Model n} + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hp:Tendsto p atTop (𝓝 p₀)) + (hbt:∀k,bj k∈(extChartAt 𝓘(ℝ,Model n) a).target) + {pj:ℕ → ι → Model n} {w:ℕ → ι → ℝ} (i:ℕ → ι) + (ha:∀k j,chartFiberInverse a (bj k) (pj k j)∈ + activeLogs (modifiedDatum v α D (β k) B) ((extChartAt 𝓘(ℝ,Model n) a).symm (bj k))) + (hw:∀k j,0 ≤ w k j) (hs:∀k,∑j,w k j=1) + (hbar:∀k,∑j,w k j • pj k j=p k) : + ∃σ:ℕ → ℕ,StrictMono σ ∧ ∃r:ι → Model n,∃m:ι → ℝ,∃i₀:ι, + Tendsto (pj ∘ σ) atTop (𝓝 r) ∧ Tendsto (w ∘ σ) atTop (𝓝 m) ∧ + (∀ᶠ k in atTop,i (σ k)=i₀) ∧ + (∀j,(show TangentSpace 𝓘(ℝ,Model n) a from r j)∈activeLogs (modifiedDatum v α D β₀ B) a) ∧ + (∀j,0 ≤ m j) ∧ ∑j,m j=1 ∧ ∑j,m j • r j=p₀ := by + let χ:=extChartAt 𝓘(ℝ,Model n) a + have hat:χ a∈χ.target := mem_extChartAt_target a + have hy:Tendsto (fun k=>χ.symm (bj k)) atTop (𝓝 a) := by + have H:=(continuousAt_extChartAt_symm'' hat).tendsto.comp hb + rwa [χ.left_inv (mem_extChartAt_source a)] at H + obtain ⟨K,hK,hKs,N,hN⟩:=compact_in_chart_tail (n := n) (a := a) hy (mem_extChartAt_source a) + let shift:=fun k:ℕ=>k+N + have hshift:Tendsto shift atTop atTop := tendsto_add_atTop_nat N + let C:=minimizingChartParameters (n := n) a K + have hC:IsCompact C := isCompact_minimizingChartParameters hK hKs + let S:= {q:EnvelopeData (Model n) ι | (∀j,(q.1.1,q.1.2 j)∈C) ∧ + (∀j,0 ≤ q.2.1 j) ∧ ∑j,q.2.1 j=1 ∧ q.2.2∈Icc 0 0} + have hc:IsCompact (S×ˢ(univ:Set ι)) := (compact_common_base_configurations hC 0).prod isCompact_univ + let f:ℕ → EnvelopeData (Model n) ι × ι := fun k=>(((bj (shift k),pj (shift k)),(w (shift k),0)),i (shift k)) + have hf:∀k,f k∈S×ˢ(univ:Set ι) := by + intro k + refine ⟨⟨?_,hw _,hs _,le_rfl,le_rfl⟩,mem_univ _⟩ + intro j + exact inverse_mem_minimizingChartParameters (hbt _) (hN k) (ha _ j).1 + obtain ⟨q,hq,τ,hτ,hlim⟩:=hc.isSeqCompact hf + let σ:=shift ∘ τ + have hσ:StrictMono σ := fun k l h=>Nat.add_lt_add_right (hτ h) N + have hr:Tendsto (pj ∘ σ) atTop (𝓝 q.1.1.2) := hlim.fst_nhds.fst_nhds.snd_nhds + have hm:Tendsto (w ∘ σ) atTop (𝓝 q.1.2.1) := hlim.fst_nhds.snd_nhds.fst_nhds + have hi:∀ᶠ k in atTop,i (σ k)=q.2 := by + exact hlim.snd_nhds.eventually ((isOpen_discrete {q.2}).mem_nhds rfl) + refine ⟨σ,hσ,q.1.1.2,q.1.2.1,q.2,hr,hm,hi,?_,hq.1.2.1,hq.1.2.2.1,?_⟩ + · intro j + apply modified_active_coordinates_limit hv hB (hβ.comp hσ.tendsto_atTop) + (hb.comp hσ.tendsto_atTop) ((tendsto_pi_nhds.mp hr) j) + (Eventually.of_forall (fun k=>hbt (σ k))) + (Eventually.of_forall (fun k=>ha (σ k) j)) + · have H:Tendsto (fun k=>∑j,w (σ k) j • pj (σ k) j) atTop + (𝓝 (∑j,q.1.2.1 j • q.1.1.2 j)) := by + apply tendsto_finsetSum + intro j _ + exact ((tendsto_pi_nhds.mp hm) j).smul ((tendsto_pi_nhds.mp hr) j) + simp only [hbar] at H + exact tendsto_nhds_unique H (hp.comp hσ.tendsto_atTop) +end ConfigurationCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricQuadratic.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricQuadratic.lean new file mode 100644 index 0000000000000000000000000000000000000000..b9036cfd5e4acbaedf4ac671a1211b5b29f18093 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricQuadratic.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CompactMinty + +namespace OAI + +section +section +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +section +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma contDiffAt_parametric_quadratic_upper {f : E×F → ℝ} {x : E} {a : F} + (hf : ContDiffAt ℝ ∞ f (x,a)) : + ∃ δ>0, ∃ K>0, ∀ z∈Metric.ball x δ, ∀ w∈Metric.ball x δ, + ∀ b∈Metric.ball a δ, + f (w,b)-f (z,b)-fderiv ℝ f (z,b) (w-z,0) ≤ K*‖w-z‖^2 := by + let K := ‖fderiv ℝ (fderiv ℝ f) (x,a)‖+1 + have hK : 0 ‖fderiv ℝ (fderiv ℝ f) q‖) (x,a) := + ((hf.fderiv_right (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 3)).continuousAt_fderiv (by norm_num)).norm + have hf2 : ContDiffAt ℝ 2 f (x,a) := hf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hk : ‖fderiv ℝ (fderiv ℝ f) (x,a)‖ (hbound hq).1) (fun q hq => (hbound hq).2.le) hzb hwb + have H' := (abs_le.mp (show |f (w,b)-f (z,b)-fderiv ℝ f (z,b) ((w,b)-(z,b))| + ≤ K*‖(w,b)-(z,b)‖^2 from H)).2 + simpa only [Prod.mk_sub_mk,sub_self,Prod.norm_def,norm_zero,max_eq_left (norm_nonneg _)] using H' + +end +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma compact_eventually_uniform_radius_bound {A T : Type*} + [TopologicalSpace A] [TopologicalSpace T] {K : Set A} (hK : IsCompact K) + {t : T} {P : ℝ → ℝ → T → A → Prop} + (hmono : ∀ {r R b B : ℝ}, 00, ∃ b>0, ∀ᶠ q : T×A in 𝓝 (t,a), P r b q.1 q.2) : + ∃ r>0, ∃ b>0, ∀ᶠ s in 𝓝 t, ∀ a∈K, P r b s a := by + apply hK.induction_on + (p := fun J => ∃ r>0, ∃ b>0, ∀ᶠ s in 𝓝 t, ∀ a∈J, P r b s a) + · exact ⟨1,by norm_num,1,by norm_num,Filter.Eventually.of_forall (by simp)⟩ + · intro J L hJL hL + obtain ⟨r,hr,b,hb,H⟩ := hL + refine ⟨r,hr,b,hb,?_⟩ + filter_upwards [H] with s hs + exact fun a ha => hs a (hJL ha) + · intro J L hJ hL + obtain ⟨r,hr,b,hb,H⟩ := hJ + obtain ⟨R,hR,B,hB,G⟩ := hL + refine ⟨min r R,lt_min hr hR,max b B,lt_max_of_lt_left hb,?_⟩ + filter_upwards [H,G] with s hs gs + intro a ha + rcases ha with ha|ha + · exact hmono (lt_min hr hR) (min_le_left _ _) (le_max_left _ _) s a (hs a ha) + · exact hmono (lt_min hr hR) (min_le_right _ _) (le_max_right _ _) s a (gs a ha) + · intro a ha + obtain ⟨r,hr,b,hb,H⟩ := hlocal a ha + obtain ⟨U,hU,V,hV,hUV⟩ := mem_nhds_prod_iff.mp H + refine ⟨V,mem_nhdsWithin_of_mem_nhds hV,r,hr,b,hb,?_⟩ + filter_upwards [hU] with s hs + intro a ha + exact hUV (show (s,a)∈U×ˢV from ⟨hs,ha⟩) + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricSecant.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricSecant.lean new file mode 100644 index 0000000000000000000000000000000000000000..19a88751d4f82baa1953cd43311926f677f5f553 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffParametricSecant.lean @@ -0,0 +1,253 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma contDiffAt_parametric_secant_lower {E : Type*} [NormedAddCommGroup E] + [NormedSpace ℝ E] {F : E×ℝ → ℝ} {x : E} + (hF : ContDiffAt ℝ 1 F (x,0)) {K : ℝ} + (hK : K < fderiv ℝ F (x,0) (0,1)) : + ∀ᶠ q : E×ℝ in 𝓝 (x,0), 0≤q.2 → K*q.2≤F q-F (q.1,0) := by + have hd : ContinuousAt (fun q : E×ℝ => fderiv ℝ F q (0,1)) (x,0) := + (hF.continuousAt_fderiv (by norm_num)).clm_apply continuousAt_const + have H : ∀ᶠ q : E×ℝ in 𝓝 (x,0), ContDiffAt ℝ 1 F q ∧ K F (q.1,r)) + (fderiv ℝ F (q.1,r) (0,1)) r := by + intro r hr + exact ((Hj r hr).1.differentiableAt_one.hasFDerivAt).comp_hasDerivAt r + ((hasDerivAt_const r q.1).prodMk (hasDerivAt_id r)) + rcases ht.eq_or_lt with he|ht + · have hqeq : q = (q.1, 0) := by ext <;> simp [←he] + rw [hqeq] + simp + obtain ⟨r,hr,he⟩ := exists_hasDerivAt_eq_slope (fun r => F (q.1,r)) + (fun r => fderiv ℝ F (q.1,r) (0,1)) ht + (fun r hr => (hD r hr).continuousAt.continuousWithinAt) + (fun r hr => hD r ⟨hr.1.le,hr.2.le⟩) + have hk := (Hj r ⟨hr.1.le,hr.2.le⟩).2.le + rw [he,sub_zero] at hk + exact (le_div_iff₀ ht).mp hk + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffQuadraticUpper.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffQuadraticUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad0a037b8d5a356c2d94c8362ad6c583badcd1ff --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffQuadraticUpper.lean @@ -0,0 +1,162 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma contDiffAt_quadratic_upper {f : ℝ → ℝ} (hf : ContDiffAt ℝ 2 f 0) + (hf0 : f 0=0) (hd0 : deriv f 0=0) : + ∃ eps C : ℝ, 0 h.differentiableAt (by norm_num)) + obtain ⟨eps,heps,hball⟩ := Metric.mem_nhds_iff.mp (inter_mem hU hnear) + refine ⟨eps,(K:ℝ)+1,heps,by positivity,?_⟩ + intro s hs + have hsub : Icc 0 s ⊆ Metric.ball (0:ℝ) eps := by + intro r hr + simpa only [Metric.mem_ball,Real.dist_eq,sub_zero,abs_of_nonneg hr.1] using hr.2.trans_lt hs.2 + have hzero : (0:ℝ) ∈ U := (hball (Metric.mem_ball_self heps)).1 + have hbound : ∀ r ∈ Icc 0 s, ‖deriv f r‖ ≤ (K:ℝ)*s := by + intro r hr + have H := hLip.dist_le_mul r (hball (hsub hr)).1 0 hzero + have H' : ‖deriv f r‖ ≤ (K:ℝ)*r := by + simpa only [hd0,dist_zero_right,Real.norm_eq_abs,abs_of_nonneg hr.1] using H + exact H'.trans (mul_le_mul_of_nonneg_left hr.2 K.coe_nonneg) + have H := Convex.norm_image_sub_le_of_norm_deriv_le + (fun r hr => (hball (hsub hr)).2) hbound (convex_Icc (0:ℝ) s) + (left_mem_Icc.mpr hs.1.le) (right_mem_Icc.mpr hs.1.le) + have H' : |f s|≤(K:ℝ)*s^2 := by + simpa only [hf0,sub_zero,Real.norm_eq_abs,abs_of_pos hs.1,pow_two,mul_assoc] using H + exact (le_abs_self (f s)).trans (H'.trans (by nlinarith [sq_nonneg s])) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffSecondOrder.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffSecondOrder.lean new file mode 100644 index 0000000000000000000000000000000000000000..536ffbe171270cccdf2ed6fb12d73be9670dfdb3 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffSecondOrder.lean @@ -0,0 +1,219 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +lemma contDiffAt_second_order_remainder + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f : E → ℝ} (hf : ContDiffAt ℝ 2 f 0) : + (fun h => f h-f 0-fderiv ℝ f 0 h-fderiv ℝ (fderiv ℝ f) 0 h h/2) + =o[𝓝 0] (fun h : E => ‖h‖^2) := by + let D := fderiv ℝ f 0 + let B := fderiv ℝ (fderiv ℝ f) 0 + have hs : ∀ v w, B v w=B w v := fun v w => (hf.isSymmSndFDerivAt (by norm_num)).eq v w + let R : E → ℝ := fun h => f h-f 0-D h-B h h/2 + let R' : E → E →L[ℝ] ℝ := fun h => fderiv ℝ f h-D-B h + have hB : HasFDerivAt (fderiv ℝ f) B 0 := + (hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) |>.hasFDerivAt + obtain ⟨r,hr,hrdiff⟩ := Metric.mem_nhds_iff.mp ((hf.eventually (by norm_num)).mono fun h hh => + hh.differentiableAt (by norm_num)) + have hder : ∀ h ∈ Metric.ball (0:E) r, HasFDerivWithinAt R (R' h) (Metric.ball (0:E) r) h := by + intro h hh + have hquad : HasFDerivAt (fun z : E => B z z/2) (B h) h := by + have H := (B.hasFDerivAt_of_bilinear (hasFDerivAt_id h) (hasFDerivAt_id h)).const_smul (1/2:ℝ) + have heq : (fun z : E => B z z/2) = ((1/2:ℝ) • fun z : E => B z z) := by ext z; simp only [Pi.smul_apply,smul_eq_mul]; ring + rw [heq] + apply H.congr_fderiv + ext v + simp only [smul_apply,add_apply,ContinuousLinearMap.precompR_apply, + ContinuousLinearMap.precompL_apply,ContinuousLinearMap.compL_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.id_apply,smul_eq_mul,id_eq] + rw [hs v h] + ring + exact (((hrdiff hh).hasFDerivAt.sub_const (f 0)).sub D.hasFDerivAt |>.sub hquad).hasFDerivWithinAt + have ho : R' =o[𝓝[Metric.ball (0:E) r] (0:E)] fun h => ‖h-(0:E)‖^1 := by + simpa only [R',D,B,sub_zero,pow_one] using hB.isLittleO.norm_right.mono nhdsWithin_le_nhds + have H := (convex_ball (0:E) r).isLittleO_pow_succ (Metric.mem_ball_self hr) hder ho + rw [nhdsWithin_eq_nhds.mpr (Metric.ball_mem_nhds _ hr)] at H + simpa only [R,D,B,map_zero,zero_apply,zero_div,sub_self,sub_zero] using H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffUncurryIterated.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffUncurryIterated.lean new file mode 100644 index 0000000000000000000000000000000000000000..49f46c3ca5196dcafeed3bcdf3855cb96bc64094 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContDiffUncurryIterated.lean @@ -0,0 +1,127 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +namespace WeakMTWTransport + +lemma contDiffAt_uncurry_iteratedDeriv {E F : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {f : E → ℝ → F} {x : E} {t : ℝ} + (hf : ContDiffAt ℝ ∞ (Function.uncurry f) (x,t)) (k : ℕ) : + ContDiffAt ℝ ∞ (fun q : E×ℝ => iteratedDeriv k (f q.1) q.2) (x,t) := by + induction k with + | zero => + apply hf.congr_of_eventuallyEq + exact Filter.Eventually.of_forall (fun q => congrFun (iteratedDeriv_zero (f := f q.1)) q.2) + | succ k ih => + have hcomp : ContDiffAt ℝ ∞ + (Function.uncurry (fun q : E×ℝ => fun s : ℝ => iteratedDeriv k (f q.1) s)) ((x,t),t) := + ih.comp ((x,t),t) ((contDiffAt_fst.fst).prodMk contDiffAt_snd) + have hd : ContDiffAt ℝ ∞ + (fun q : E×ℝ => fderiv ℝ (iteratedDeriv k (f q.1)) q.2) (x,t) := + hcomp.fderiv contDiffAt_snd (by simp) + simpa only [iteratedDeriv_succ,deriv] using hd.clm_apply (contDiffAt_const (c := (1:ℝ))) + +lemma contDiffAt_iteratedDeriv_parameter {E F : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {f : E → ℝ → F} {x : E} {t : ℝ} + (hf : ContDiffAt ℝ ∞ (Function.uncurry f) (x,t)) (k : ℕ) : + ContDiffAt ℝ ∞ (fun q : E => iteratedDeriv k (f q) t) x := + (contDiffAt_uncurry_iteratedDeriv hf k).comp x (contDiffAt_id.prodMk contDiffAt_const) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ContinuousClosedRelationSelector.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ContinuousClosedRelationSelector.lean new file mode 100644 index 0000000000000000000000000000000000000000..455bad6115991733c54f4b8e8fa0d4636a86a1bd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ContinuousClosedRelationSelector.lean @@ -0,0 +1,67 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory +open scoped Topology + +namespace WeakMTWTransport + +lemma continuousAt_closed_relation_selector + {X Y : Type*} [MetricSpace X] [MetricSpace Y] [CompactSpace Y] + {R : Set (X × Y)} (hR : IsClosed R) {T : X → Y} + (hT : ∀ x, (x,T x) ∈ R) {x : X} + (hx : ∀ y, (x,y) ∈ R → y = T x) : ContinuousAt T x := by + rw [Metric.continuousAt_iff] + intro ε hε + let B : Set (X × Y) := R ∩ {z | ε ≤ dist z.2 (T x)} + have hB : IsClosed B := + hR.inter (isClosed_le continuous_const (continuous_snd.dist continuous_const)) + have hclosed : IsClosed (Prod.fst '' B) := isClosedMap_fst_of_compactSpace B hB + have hxB : x ∈ (Prod.fst '' B)ᶜ := by + rintro ⟨⟨a,b⟩, hab, hax⟩ + change a = x at hax + subst a + have hb := hx b hab.1 + have hdist := hab.2 + change ε ≤ dist b (T x) at hdist + rw [hb,dist_self] at hdist + exact (not_le.mpr hε) hdist + obtain ⟨δ,hδ,hd⟩ := Metric.mem_nhds_iff.mp (hclosed.isOpen_compl.mem_nhds hxB) + refine ⟨δ,hδ,?_⟩ + intro a ha + apply lt_of_not_ge + intro han + exact hd ha ⟨(a,T a),⟨hT a,han⟩,rfl⟩ + +lemma aemeasurable_closed_relation_selector + {X Y : Type*} [MetricSpace X] [MetricSpace Y] [CompactSpace Y] + [MeasurableSpace X] [BorelSpace X] [MeasurableSpace Y] [BorelSpace Y] + {μ : Measure X} {R : Set (X × Y)} (hR : IsClosed R) {T : X → Y} + (hT : ∀ x, (x,T x) ∈ R) + (hsingle : ∀ᵐ x ∂μ, ∀ y, (x,y) ∈ R → y = T x) : AEMeasurable T μ := by + let S : Set X := {x | ∀ y, (x,y) ∈ R → y = T x} + have hS : ∀ᵐ x ∂μ, x ∈ S := hsingle + have hSnull : NullMeasurableSet S μ := by + have he : (univ : Set X) =ᵐ[μ] S := by + filter_upwards [hS] with x hx + exact propext ⟨fun _ => hx, fun _ => mem_univ x⟩ + exact nullMeasurableSet_univ.congr he + have hc : ContinuousOn T S := by + intro x hx + exact (continuousAt_closed_relation_selector hR hT hx).continuousWithinAt + have hm := hc.aemeasurable₀ hSnull + rwa [Measure.restrict_eq_self_of_ae_mem hS] at hm + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/CriticalChain.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/CriticalChain.lean new file mode 100644 index 0000000000000000000000000000000000000000..53967358d766e9bbd3714df53aea9a90719d4dea --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/CriticalChain.lean @@ -0,0 +1,45 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section CriticalChain +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_fderiv_comp_at_critical {f : F → ℝ} {g : E → F} {p : E} + (hf : ContDiffAt ℝ 2 f (g p)) (hg : ContDiffAt ℝ 2 g p) + (hzero : fderiv ℝ f (g p)=0) (v w : E) : + fderiv ℝ (fderiv ℝ (f ∘ g)) p v w= + fderiv ℝ (fderiv ℝ f) (g p) (fderiv ℝ g p v) (fderiv ℝ g p w) := by + have hdf := (hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hdg := (hg.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hn : ∀ᶠ a in 𝓝 p, DifferentiableAt ℝ g a ∧ DifferentiableAt ℝ f (g a) := by + have hnG := (hg.of_le (m := 1) (by norm_num)).eventually (by norm_num) + have hnF := hg.continuousAt.eventually ((hf.of_le (m := 1) (by norm_num)).eventually (by norm_num)) + filter_upwards [hnG,hnF] with a ha hb + exact ⟨ha.differentiableAt (by norm_num),hb.differentiableAt (by norm_num)⟩ + have heq : fderiv ℝ (f ∘ g) =ᶠ[𝓝 p] + (fun a => (fderiv ℝ f (g a)).comp (fderiv ℝ g a)) := + hn.mono (fun a ha => fderiv_comp a ha.2 ha.1) + have hD := (hdf.hasFDerivAt.comp p (hg.differentiableAt (by norm_num)).hasFDerivAt).clm_comp hdg.hasFDerivAt + have H := congrArg (fun A : E →L[ℝ] E →L[ℝ] ℝ => A v w) (heq.fderiv_eq.trans hD.fderiv) + simpa only [_root_.add_apply,ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, ContinuousLinearMap.compL_apply, Function.comp_apply, + hzero, ContinuousLinearMap.zero_comp,_root_.zero_apply,zero_add] using H + +end CriticalChain +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/Diagonal.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/Diagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..dcdf6d8cd36e52353847c30c123efda7b0ce4073 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/Diagonal.lean @@ -0,0 +1,23 @@ +import Mathlib + +namespace OAI + + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport + +lemma diagonal_tendsto_of_close {X : Type*} [PseudoMetricSpace X] + {f a : ℕ → X} {x : X} {ε : ℕ → ℝ} + (ha : Tendsto a atTop (𝓝 x)) (hε : Tendsto ε atTop (𝓝 0)) + (hclose : ∀ᶠ k in atTop,dist (f k) (a k)≤ε k) : Tendsto f atTop (𝓝 x) := by + apply tendsto_of_tendsto_of_dist ha + exact squeeze_zero' (Eventually.of_forall (fun _=>dist_nonneg)) (hclose.mono (fun k hk=>by simpa only [dist_comm] using hk)) hε + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/EuclideanUpper.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/EuclideanUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..46a22176e9f181566e01de96a27775968caaa925 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/EuclideanUpper.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.CompactDual +import OAI.Analysis.BiholderTransport.CostGeometry.DividedAction + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +def hopfLax (t : ℝ) (u : M → ℝ) (z : M) : ℝ := + sInf (Set.range (fun x => u x + cost x z / t)) + +lemma exists_hopfLax_minimizer {u : M → ℝ} (hu : Continuous u) (t : ℝ) (z : M) : + ∃ x, hopfLax t u z = u x+cost x z/t ∧ + ∀ a, u x+cost x z/t ≤ u a+cost a z/t := by + obtain ⟨x,_,hx⟩ := isCompact_univ.exists_isMinOn univ_nonempty + (hu.add ((continuous_cost_left z).div_const t)).continuousOn + have hmin : ∀ a, u x+cost x z/t ≤ u a+cost a z/t := fun a => hx (mem_univ a) + refine ⟨x,le_antisymm ?_ ?_,hmin⟩ + · exact csInf_le ⟨_,by rintro _ ⟨a,rfl⟩; exact hmin a⟩ ⟨x,rfl⟩ + · exact le_csInf (range_nonempty _) (by rintro _ ⟨a,rfl⟩; exact hmin a) + +lemma hopfLax_le {u : M → ℝ} (hu : Continuous u) (t : ℝ) (z x : M) : + hopfLax t u z ≤ u x+cost x z/t := by + obtain ⟨a,ha,hmin⟩ := exists_hopfLax_minimizer hu t z + rw [ha] + exact hmin x + +lemma hopfLax_eq_of_min {u : M → ℝ} (hu : Continuous u) (t : ℝ) (z x : M) + (hmin : ∀ a, u x+cost x z/t ≤ u a+cost a z/t) : + hopfLax t u z = u x+cost x z/t := by + apply le_antisymm (hopfLax_le hu t z x) + obtain ⟨a,ha,_⟩ := exists_hopfLax_minimizer hu t z + rw [ha] + exact hmin a + +lemma hopfLax_eq_neg_transform {u : M → ℝ} (hu : Continuous u) {t : ℝ} + (ht : 0 t*u x) z/t := by + let v := fun x => t*u x + have hv : Continuous v := continuous_const.mul hu + obtain ⟨a,ha,hmin⟩ := exists_hopfLax_minimizer hu t z + have hc : cTransform v z = -t*(u a+cost a z/t) := by + apply le_antisymm + · apply (cTransform_le_iff hv z _).mpr + intro x + have H := mul_le_mul_of_nonneg_left (hmin x) ht.le + rw [mul_add,mul_div_cancel₀ _ ht.ne',mul_add,mul_div_cancel₀ _ ht.ne'] at H + dsimp [v] + rw [cost_symm z x] + have : t*(u a+cost a z/t)=t*u a+cost a z := by field_simp + rw [neg_mul,this] + linarith + · have H := cTransform_gap_nonneg hv z a + dsimp [contactGap] at H + rw [cost_symm z a] at H + have : -t*(u a+cost a z/t) = -cost a z-t*u a := by field_simp; ring + rw [this] + linarith + rw [hc,ha] + field_simp + +omit [CompactSpace M] [Nonempty M] in +lemma divided_cost_triangle (x z y : M) {t : ℝ} (ht : 0 + simp only [cost,div_div,mul_comm] + +lemma dual_hopfLax_sum_nonneg {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {t : ℝ} (ht : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +lemma WeakMTW.family_comparison_local_data (hmtw : WeakMTW (n := n) (M := M)) + {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) {Kp : Set P} (hKp : IsCompact Kp) + (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) {Lφ : ℝ≥0} + (hφL : ∀ p∈Kp,LipschitzWith Lφ (fun s=>Φ (p,s))) (A B : ℝ) (a : M) : + ∃ R>0,∃ δ>0,∀ p∈Kp,∀ u:M → ℝ,Continuous u → (∀ y,cTransform u y∈Icc A B) → + ∀ ψ:ℝ → ℝ,Continuous ψ → ∀ τ:ℝ,0<τ → τ<1/2 → τ<δ → + ∀ c:M,extChartAt 𝓘(ℝ,Model n) a c∈ball (extChartAt 𝓘(ℝ,Model n) a a) R → + let χ := extChartAt 𝓘(ℝ,Model n) a + let w := fun y=>ψ (cTransform u y) + let g := fun y=>Φ (p,cTransform u y) + let F := chartOuterEnvelope w (1-τ) a + let G := chartCenterEnvelope g (1-τ) a + let pole : Model n → M := chartActualPole w (1-τ) a + let χP := extChartAt 𝓘(ℝ,Model n) (pole (χ c)) + ∃ r>0,∃ JF JG JY JP:ℝ≥0,∃ Y:Model n → M, + (∀ z∈ball (χ c) r,DifferentiableAt ℝ F z) ∧ + (∀ z∈ball (χ c) r,DifferentiableAt ℝ G z) ∧ + LipschitzOnWith JF (fderiv ℝ F) (ball (χ c) r) ∧ + LipschitzOnWith JG (fderiv ℝ G) (ball (χ c) r) ∧ + LipschitzOnWith JY (fun z=>χ (Y z)) (ball (χ c) r) ∧ + LipschitzOnWith JP (fun z=>χP (pole z)) (ball (χ c) r) ∧ + ∀ z∈ball (χ c) r, + Y z∈χ.source ∧ pole z∈χP.source ∧ + (∀ y:M,G z=g y+cost y (χ.symm z)/(1-(1-τ)) ↔ y=Y z) ∧ + F z=cTransform w (pole z)+cost (pole z) (χ.symm z)/(1-τ) := by + obtain ⟨J,JY,Rg,hRg,δ,hδ,HG⟩ := + uniform_family_short_envelope_data (n := n) hΦ hKp hmono hφL A B a + obtain ⟨BF,hBF,Rf,hRf,hTf,HF⟩ := hmtw.uniform_hopfLax_C11 a + obtain ⟨CP,hCP,Rp,hRp,hTp,HP⟩ := hmtw.uniform_hopfPole_lipschitz a + let R := min (Rg/8) (min (Rf/8) (Rp/2)) + have hR : 0ψ (cTransform u y) + have hw : Continuous w := hψ.comp (continuous_cTransform hu) + have hdual : IsCostDualPair (cTransform w) (cTransform (cTransform w)) := + ⟨(cTransform_triple hw).symm,rfl⟩ + have ht : 0<1-τ := by linarith + have ht1 : 1-τ<1 := by linarith + obtain ⟨hgdiff,hgl,Y,hY,hy⟩ := HG p hp u hu hb τ hτ hτδ + let G : Model n → ℝ := fun z=>hopfLax τ (fun y=>Φ (p,cTransform u y)) (χ.symm z) + have hsmall : ball (χ a) (Rg/4)⊆ball (χ a) Rg := ball_subset_ball (by linarith) + obtain ⟨hgD,hgL⟩ := C11_const_mul_cancel (f := G) hτ.ne' + (fun z hz=>hgdiff z (hsmall hz)) hgl + obtain ⟨hfD,hfL⟩ := HF (1-τ) ht ht1 (cTransform w) (cTransform (cTransform w)) + (continuous_cTransform hw) (continuous_cTransform (continuous_cTransform hw)) hdual + let pole : Model n → M := chartActualPole w (1-τ) a + have hpL : LipschitzOnWith (Real.toNNReal (CP/(1-(1-τ)))) pole (ball (χ a) Rp) := + HP (1-τ) (by linarith) ht1 (cTransform w) (cTransform (cTransform w)) + (continuous_cTransform hw) (continuous_cTransform (continuous_cTransform hw)) hdual + have hrg : R≤Rg/8 := min_le_left _ _ + have hrf : R≤Rf/8 := (min_le_right _ _).trans (min_le_left _ _) + have hrp : R≤Rp/2 := (min_le_right _ _).trans (min_le_right _ _) + have hcRp : χ c∈ball (χ a) Rp := (ball_subset_ball (by linarith : R≤Rp)) hc + have hpC : ContinuousAt pole (χ c) := hpL.continuousOn.continuousAt (isOpen_ball.mem_nhds hcRp) + obtain ⟨AP,rP,hrP,hpsrc,hpchart⟩ := exists_lipschitzOn_chart (n := n) (pole (χ c)) + obtain ⟨r,hr,hrsub⟩ := Metric.mem_nhds_iff.mp + (inter_mem (isOpen_ball.mem_nhds hc) (hpC.preimage_mem_nhds (ball_mem_nhds (pole (χ c)) hrP))) + have hsub : ball (χ c) r⊆ball (χ a) R := fun z hz=>(hrsub hz).1 + have himage : ∀ z∈ball (χ c) r,pole z∈ball (pole (χ c)) rP := fun z hz=>(hrsub hz).2 + have hrg4 : ball (χ c) r⊆ball (χ a) (Rg/4) := hsub.trans (ball_subset_ball (by linarith)) + have hrf4 : ball (χ c) r⊆ball (χ a) (Rf/4) := hsub.trans (ball_subset_ball (by linarith)) + have hrp' : ball (χ c) r⊆ball (χ a) Rp := hsub.trans (ball_subset_ball (by linarith)) + have htau : 1-(1-τ)=τ := by ring + have heq : chartCenterEnvelope (n := n) (fun y=>Φ (p,cTransform u y)) (1-τ) a=G := by + funext z + change hopfLax (1-(1-τ)) _ _=hopfLax τ _ _ + rw [htau] + refine ⟨r,hr,Real.toNNReal (6*(BF/(1-τ)+BF/(1-(1-τ)))),‖τ⁻¹‖₊*J,JY, + AP*Real.toNNReal (CP/(1-(1-τ))),Y,?_,?_,hfL.mono hrf4,?_, + hY.mono (hrg4.trans hsmall),hpchart.comp (hpL.mono hrp') himage,?_⟩ + · exact fun z hz=>hfD z ((hsub.trans (ball_subset_ball (by linarith : R≤Rf))) hz) + · rw [heq] + exact fun z hz=>hgD z (hrg4 hz) + · rw [heq] + exact hgL.mono hrg4 + · intro z hz + have hyz := hy z (hsmall (hrg4 hz)) + refine ⟨hyz.1,hpsrc (himage z hz),?_,hmtw.hopfPole_minimizer + (continuous_cTransform hw) (continuous_cTransform (continuous_cTransform hw)) hdual ht ht1 _⟩ + simpa only [chartCenterEnvelope,htau,G,χ] using hyz.2 +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FamilyGlobal.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FamilyGlobal.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c9c498d3324bf98f01454cf7f5077e0f02f4828 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FamilyGlobal.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition +import OAI.Analysis.BiholderTransport.Convexity.FamilyShortEnvelope + +namespace OAI + +section + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section FamilyGlobal +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +omit [CompactSpace M] [Nonempty M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma mdifferentiableAt_of_chart_differentiable_of_mem {f : M → ℝ} {a x : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hd : DifferentiableAt ℝ (fun y=>f ((extChartAt 𝓘(ℝ,Model n) a).symm y)) + (extChartAt 𝓘(ℝ,Model n) a x)) : + MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f x := by + have H := hd.hasFDerivAt.hasMFDerivAt.comp x + (mdifferentiableAt_extChartAt (I := 𝓘(ℝ,Model n)) + (show x∈(chartAt (Model n) a).source from by simpa only [extChartAt_source] using hx)).hasMFDerivAt + apply (H.congr_of_eventuallyEq ?_).mdifferentiableAt + filter_upwards [(isOpen_extChartAt_source a).mem_nhds hx] with y hy + simp only [Function.comp_apply,(extChartAt 𝓘(ℝ,Model n) a).left_inv hy] + +lemma uniform_family_short_mdifferentiable {Φ : P×ℝ → ℝ} (hΦ : ContDiff ℝ ∞ Φ) + {Kp : Set P} (hKp : IsCompact Kp) (hmono : ∀ p∈Kp,Monotone (fun s=>Φ (p,s))) + {Lφ : ℝ≥0} (hφL : ∀ p∈Kp,LipschitzWith Lφ (fun s=>Φ (p,s))) (A B : ℝ) : + ∃ δ>0,∀ p∈Kp,∀ u:M → ℝ,Continuous u → (∀ y,cTransform u y∈Icc A B) → + ∀ τ:ℝ,0<τ → τ<δ → + MDifferentiable 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (hopfLax τ (fun y=>Φ (p,cTransform u y))) := by + classical + choose J JY r hr δ hδ H using fun a:M=> + uniform_family_short_envelope_data (n := n) hΦ hKp hmono hφL A B a + let U : M → Set M := fun a=> + (extChartAt 𝓘(ℝ,Model n) a).source ∩ + (extChartAt 𝓘(ℝ,Model n) a) ⁻¹' ball (extChartAt 𝓘(ℝ,Model n) a a) (r a) + have hU : ∀ a,U a∈𝓝 a := by + intro a + exact inter_mem (extChartAt_source_mem_nhds a) + (((continuousOn_extChartAt a).continuousAt (extChartAt_source_mem_nhds a)).preimage_mem_nhds + (ball_mem_nhds _ (hr a))) + obtain ⟨s,hs⟩ := CompactSpace.elim_nhds_subcover U hU + have ht : ∀ᶠ τ:ℝ in 𝓝 0,∀ a∈s,τ<δ a := by + apply (eventually_all_finset s).mpr + intro a ha + exact eventually_lt_nhds (hδ a) + obtain ⟨ε,hε,hεsub⟩ := Metric.mem_nhds_iff.mp ht + refine ⟨ε,hε,?_⟩ + intro p hp u hu hb τ hτ hτε x + have hτδ : ∀ a∈s,τ<δ a := hεsub (by simpa [mem_ball,dist_zero_right,abs_of_pos hτ] using hτε) + have hx : x∈⋃ a∈s,U a := by rw [hs]; trivial + obtain ⟨a,ha,hx⟩ := mem_iUnion₂.mp hx + have hd := (H a p hp u hu hb τ hτ (hτδ a ha)).1 _ hx.2 + apply mdifferentiableAt_of_chart_differentiable_of_mem hx.1 + have HH := hd.const_mul τ⁻¹ + simpa only [←mul_assoc,inv_mul_cancel₀ hτ.ne',one_mul] using HH +end FamilyGlobal +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteIntervalMesh.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteIntervalMesh.lean new file mode 100644 index 0000000000000000000000000000000000000000..f412846ee9a1929c842f9728e769576fdf7c398c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteIntervalMesh.lean @@ -0,0 +1,143 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.UniformFiniteRadialScale + +namespace OAI + +section +section +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma finite_interval_mesh {K ε e : ℝ} (hK : 0 ≤ K) (hε : 0 < ε) + (he : e∈Ioo (0:ℝ) 1) : + ∃ N : ℕ, 0 (k:ℝ)/N*(1-e) + refine ⟨N,hNnat,t,by simp [t],by simp [t,ne_of_gt hn0],?_,?_⟩ + · intro k hk + have hr : (k:ℝ)/N ≤ 1 := (div_le_one hn0).mpr (by exact_mod_cast hk) + have hr0 : 0 ≤ (k:ℝ)/N := div_nonneg (Nat.cast_nonneg _) hn0.le + dsimp [t] + constructor + · exact mul_nonneg hr0 (by linarith [he.2]) + · have HH := mul_le_mul_of_nonneg_right hr (show 0 ≤ 1-e by linarith [he.2]) + simpa only [one_mul] using HH + · intro k hk + have hstep : t (k+1)-t k=(1-e)/N := by + dsimp [t] + rw [Nat.cast_add,Nat.cast_one] + ring + rw [hstep,abs_of_nonneg (div_nonneg (by linarith [he.2]) hn0.le)] + have hKN : K/N ≤ ε := by + rw [div_le_iff₀ hn0] + have HH := (div_lt_iff₀ hε).mp (show K/ε<(N:ℝ) by linarith [hN]) + linarith + have HH := mul_le_mul_of_nonneg_left (show (1-e)/N ≤ 1/N by + exact div_le_div_of_nonneg_right (by linarith [he.1]) hn0.le) hK + rw [mul_one_div] at HH + exact HH.trans hKN +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma uniform_finite_profile_comparison {C l u b D e K : ℝ} + (hC : 0 norm_num) + have hs₁ : 0 s (t k)) + have hSc : S.card ≤ N+1 := Finset.card_image_le.trans (by simp) + obtain ⟨δ,hd0,hdη,hdsmall,hdlarge,hdsep⟩ := HC S hSc (s 0) (s 1) hs₁ hsD hfail + have hd : δ∈Ioc (0:ℝ) (1/2) := ⟨hd0,hdη.trans (min_le_left _ _)⟩ + have hbg : b*δ ≤ l/32 := by + have HH := hdη.trans (min_le_right _ _) + have HH2 := (le_div_iff₀ (show 0<32*b by positivity)).mp HH + nlinarith only [HH2] + have hti (k : ℕ) (hk : k≤N) : t k∈Icc (0:ℝ) 1 := + ⟨(ht k hk).1,le_trans (ht k hk).2 (by linarith [he.1])⟩ + have hlarge_case (r : ℝ) (hr : r∈Icc (0:ℝ) 1) (hh : Real.exp L*s r ≤ δ) : + l/4 ≤ f δ r := by + have HH := radial_profile_small (hs r hr) hd0 hl.le hR hh hbg (hprof δ hd r hr).1 + linarith + have hsmall_case (r : ℝ) (hr : r∈Icc (0:ℝ) 1) (hh : δ*Real.exp L ≤ s r) : + f δ r ≤ ε := by + have HH := radial_profile_large (hs r hr) hd0 hu.le (Real.exp_pos L) hh hbg + (hprof δ hd r hr).2 + dsimp [ε] + linarith + have hfzero : l/4 ≤ f δ (t 0) := by + rw [ht0] + exact hlarge_case 0 (by constructor <;> norm_num) hdsmall + have hfend : f δ 1 ≤ ε := hsmall_case 1 (by constructor <;> norm_num) hdlarge + have hfbin (k : ℕ) (hk : k≤N) : f δ (t k) ≤ ε ∨ l/4 ≤ f δ (t k) := by + have hmem : s (t k)∈S := Finset.mem_image.mpr ⟨k,Finset.mem_range.mpr (by omega),rfl⟩ + rcases hdsep _ hmem with Hs|Hs + · exact Or.inr (hlarge_case (t k) (hti k hk) Hs) + · exact Or.inl (hsmall_case (t k) (hti k hk) Hs) + have hfstep (k : ℕ) (hk : k f δ (t k)) + (show 2*ε hp ⟨i,h⟩)) (hw i) + simp only [hz,Finset.sum_const_zero] at hsum + norm_num at hsum + obtain ⟨j,hj⟩ := hpos + have hh : (∑ i, w i * f i) < ∑ i, w i * a := by + apply Finset.sum_lt_sum + · intro i _ + exact mul_le_mul_of_nonneg_left (hf i).le (hw i) + · exact ⟨j,Finset.mem_univ j,mul_lt_mul_of_pos_left (hf j) hj⟩ + rw [← Finset.sum_mul,hsum,one_mul] at hh + exact (not_lt_of_ge ha) hh + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteNonnegativeWeightPos.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteNonnegativeWeightPos.lean new file mode 100644 index 0000000000000000000000000000000000000000..6f93290b1ae26274f766c0d3d5bbb951bc3d39ba --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteNonnegativeWeightPos.lean @@ -0,0 +1,39 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport + +lemma finite_nonnegative_weight_zero_on_pos {ι : Type*} [Fintype ι] + (w f : ι → ℝ) (hw : ∀ i, 0 ≤ w i) (hf : ∀ i, f i ≤ 0) + (hsum : ∑ i, w i * f i = 0) : ∀ i, 0 < w i → f i = 0 := by + intro i hi + apply le_antisymm (hf i) + by_contra! hh + have hs : (∑ j, w j * f j) < ∑ j ∈ (Finset.univ : Finset ι), (0:ℝ) := by + apply Finset.sum_lt_sum + · intro j _ + exact mul_nonpos_of_nonneg_of_nonpos (hw j) (hf j) + · exact ⟨i,Finset.mem_univ i,mul_neg_of_pos_of_neg hi hh⟩ + simp [hsum] at hs + +lemma sum_filter_positive_weights {ι E : Type*} [Fintype ι] + [AddCommMonoid E] [Module ℝ E] (w : ι → ℝ) (hw : ∀ i, 0 ≤ w i) (f : ι → E) : + ∑ i ∈ (Finset.univ.filter (fun i => 0 < w i)), w i • f i = ∑ i, w i • f i := by + classical + rw [Finset.sum_filter] + apply Finset.sum_congr rfl + intro i _ + by_cases h : 0 < w i + · simp only [h,ite_true] + · have hz : w i = 0 := le_antisymm (le_of_not_gt h) (hw i) + simp [hz] + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteSimplexRepresentation.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteSimplexRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..d7b0565f2b7e50b03a13cbec47e96a46bf08ecc7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FiniteSimplexRepresentation.lean @@ -0,0 +1,38 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma finite_simplex_representation {E : Type*} [AddCommGroup E] [Module ℝ E] + [FiniteDimensional ℝ E] {S : Set E} {x : E} (hx : x ∈ convexHull ℝ S) : + ∃ m : ℕ, 0 < m ∧ m ≤ Module.finrank ℝ E + 1 ∧ + ∃ z : Fin m → E, ∃ w : Fin m → ℝ, + (∀ i, z i ∈ S) ∧ (∀ i, 0 ≤ w i) ∧ + (∑ i, w i = 1) ∧ (∑ i, w i • z i = x) := by + classical + obtain ⟨ι,inst,z,w,hz,hi,hw,hsum,heq⟩ := eq_pos_convex_span_of_mem_convexHull hx + let : Fintype ι := inst + have : Nonempty ι := by + by_contra h + have : IsEmpty ι := not_nonempty_iff.mp h + simp at hsum + let e := Fintype.equivFin ι + refine ⟨Fintype.card ι,Fintype.card_pos, + hi.card_le_finrank_succ.trans (Nat.add_le_add_right (Submodule.finrank_le _) 1), + fun i => z (e.symm i),fun i => w (e.symm i),?_,?_,?_,?_⟩ + · intro i + exact hz (mem_range_self _) + · intro i + exact (hw _).le + · simpa only [e.symm.sum_comp] using hsum + · exact (e.symm.sum_comp (fun i => w i • z i)).trans heq + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FirstActiveLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FirstActiveLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..0b4be76b1d496db7a9ddbe3aba98a49478d54dfe --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FirstActiveLimit.lean @@ -0,0 +1 @@ +import Mathlib diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FirstOutward.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FirstOutward.lean new file mode 100644 index 0000000000000000000000000000000000000000..a411015de1b1aa1285c2094618933766d3a44c80 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FirstOutward.lean @@ -0,0 +1,94 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartFirstMatrix +import OAI.Analysis.BiholderTransport.Regularity.ActualOutward + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FirstOutward +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma ChartFixedPrefixLimit.outward_endpoint + (hmtw:WeakMTW (n := n) (M := M)) + {u v G:M → ℝ} (hu:Continuous u) (hv:Continuous v) (hdual:IsCostDualPair u v) + {α D β H:ℝ} {Bc Bo:ℝ → ℝ} (ho:Continuous Bo) (hβ:0 ≤ β) + (hob:∀s,0 ≤ Bo s ∧ Bo s ≤ H) (hcb:∀s,-1 ≤ Bc s ∧ Bc s ≤ 1) + (hright:∀s,3/4 ≤ s → Bc s ≤ 0) + {a:M} {t:ℝ} {q:ℕ → subgradientGraph (n := n) (cTransform (modifiedDatum v α D β Bo))} + {q₀:subgradientGraph (n := n) (cTransform (modifiedDatum v α D β Bo))} + (J:ChartFixedPrefixLimit a (modifiedDatum v α D β Bo) G t q q₀) : + let b:=graphBaseCoordinate a q₀.1 + let x:=(extChartAt 𝓘(ℝ,Model n) a).symm b + let E:=TangentSpace 𝓘(ℝ,Model n) x + let P:E:=chartFiberInverse a b (graphVelocityCoordinate a q₀.1) + let pj:=fun i=>chartFiberInverse a b (J.pj₀ i) + let κ:Type:={i:Fin (Module.finrank ℝ (Model n)+1) // 0 < J.w₀ i} + ∀ e:E,‖e‖=1 → 0 < inner ℝ P e → + Submodule.span ℝ (range (fun i:κ=>pj i-P))=Submodule.span ℝ {e} → + ∀ c eta delta zeta a0:ℝ,0 < D → 0 < c → 0 < a0 → + a0*D ≤ (inner ℝ P e)^2 → eta ≤ 1/128 → delta ≤ zeta → delta ≤ eta → zeta ≤ 1/16 → + (∀s,s < 1-eta → 1 ≤ Bo s) → + 0 < modifiedExcess v α D β Bc Bo (riemannianExp x P) → + 2*(H+2)*β ≤ zeta*D → sectionOscillation u v x ((H+2)*β) ≤ (1+delta)*D → + c ≤ Bc ((v (riemannianExp x P)-α)/D)-∑ i,J.w₀ i*Bo ((v (riemannianExp x (pj i))-α)/D) → + let si:=fun i=>(v (riemannianExp x (pj i))-α)/D + let mstar:=c/(12*(Module.finrank ℝ (Model n)+1:ℝ)) + let theta0:=min (mstar/2) (a0/3) + ∃ i d,0 < J.w₀ i ∧ 0 < d ∧ pj i=P+d • e ∧ mstar ≤ J.w₀ i ∧ + c*D/(8*(Module.finrank ℝ (Model n)+1:ℝ)*(inner ℝ P e)) ≤ J.w₀ i*d ∧ + d ≤ 3*D/(2*(inner ℝ P e)) ∧ -2*eta ≤ si i ∧ si i < 1-eta ∧ + Bo (si i) ≤ 12*(Module.finrank ℝ (Model n)+1:ℝ)/c ∧ 0 < theta0 ∧ + ∀ theta∈Icc (-theta0) 1, + P+theta • (pj i-P)∈convexHull ℝ (activeLogs (modifiedDatum v α D β Bo) x) ∧ + (inner ℝ P e)/2 ≤ inner ℝ (P+theta • (pj i-P)) e ∧ + ‖pj i-P‖^2/(inner ℝ (P+theta • (pj i-P)) (pj i-P)) ≤ 3/a0 := by + dsimp only + intro e he hq hline c eta delta zeta a0 hD hc ha0 hqa heta hdelta hdeltaEta hzeta + hleft hexcess herror hosc hparameter + classical + let b:=graphBaseCoordinate a q₀.1 + let x:=(extChartAt 𝓘(ℝ,Model n) a).symm b + let P:=chartFiberInverse a b (graphVelocityCoordinate a q₀.1) + let pj:=fun i=>chartFiberInverse a b (J.pj₀ i) + let κ:Type:={i:Fin (Module.finrank ℝ (Model n)+1) // 0 < J.w₀ i} + have hr:=positive_barycentric_restriction pj J.w₀ J.nonnegLimit J.totalLimit + have hbar:∑ i:κ,J.w₀ i • pj i=P := by + rw [hr.2.2.1] + change ∑ i,J.w₀ i • chartFiberInverse a b (J.pj₀ i)=P + simp only [←map_smul] + rw [←map_sum,J.baryLimit] + have hN:Fintype.card κ ≤ Module.finrank ℝ (Model n)+1 := by + exact (Fintype.card_subtype_le _).trans_eq (Fintype.card_fin _) + have hparam:c ≤ Bc ((v (riemannianExp x P)-α)/D)- + ∑ i:κ,J.w₀ i*Bo ((v (riemannianExp x (pj i))-α)/D) := by + rw [hr.2.2.2 (fun i=>Bo ((v (riemannianExp x (pj i))-α)/D))] + exact hparameter + obtain ⟨i,d,hd,hpd,hm,hmom,hdmax,hsi,hsi',hcap,htheta,Htheta⟩:= + hmtw.actual_outward_endpoint hu hv hdual ho hβ hob hcb hright hN + (fun i:κ=>i.2) hr.2.1 hbar (fun i=>J.activeLimit i) + he hq hline hD hc ha0 hqa heta hdelta hdeltaEta hzeta hleft hexcess herror hosc hparam + refine ⟨i.1,d,i.2,hd,hpd,hm,hmom,hdmax,hsi,hsi',hcap,htheta,?_⟩ + intro theta htheta + obtain ⟨hconv,hq',hratio⟩:=Htheta theta htheta + refine ⟨convexHull_mono ?_ hconv,hq',hratio⟩ + rintro _ ⟨j,rfl⟩ + exact J.activeLimit j + +end FirstOutward +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinMiddle.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinMiddle.lean new file mode 100644 index 0000000000000000000000000000000000000000..631f4fa284c6fc0080bf1b77a7b0195909176766 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinMiddle.lean @@ -0,0 +1,66 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.StationaryPullback + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +section +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma fixedJoinMiddle_eq_slice {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hB : ContDiffAt ℝ 2 (fixedJoinAction x h T p) (0,p)) + (v w : TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinMiddle x h T p v w=fderiv ℝ + (fderiv ℝ (fun b => fixedJoinAction x h T p (0,b))) p v w := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let I : V →L[ℝ] V×V := (0 : V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V) + have H := second_fderiv_comp_affine (f := fixedJoinAction x h T p) I 0 p + (by simpa [I] using hB) v w + simpa [I,fixedJoinMiddle_apply] using H.symm + +lemma fixedJoinMiddle_symmetric {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hB : ContDiffAt ℝ 2 (fixedJoinAction x h T p) (0,p)) + (v w : TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinMiddle x h T p v w=fixedJoinMiddle x h T p w v := + (hB.isSymmSndFDerivAt (by norm_num)).eq (0,v) (0,w) + +end + +lemma fixedJoinMiddle_one_nonneg {x : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hh : 0 (p,z)) + (0,p) (contDiffAt_const.prodMk contDiffAt_id) + have HB2 := HB.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have H := fixedJoinMiddle_rescale (x := x) (h := h) (p := p) (T := 1) + (by norm_num) (by simpa only [Function.comp_def,div_one,one_smul] using HB2) v v + simp only [div_one,one_smul,one_mul] at H + rw [H,←splitTrialValue_eq_hessian hleft hright] + exact splitTrialValue_nonneg hh hh1 hp hleft hright + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinUpper.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc9d7f4c53fa0aa233f8248059a428982ebda3d7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FixedJoinUpper.lean @@ -0,0 +1,194 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates3 +import OAI.Analysis.BiholderTransport.Coordinates.FixedJoinSmooth + +namespace OAI + + + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteProfile (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def movingFixedJoinAction (a : M) (h : ℝ) (q : ℝ×(Model n×Model n)) (z : Model n) : ℝ := + cost (movingNormal a (q.2.1,0)) (movingNormal a (q.2.1,h • (q.2.2+z)))/h+ + cost (movingNormal a (q.2.1,h • (q.2.2+z))) (movingNormal a (q.2.1,q.1 • q.2.2))/(q.1-h) + +def movingFixedJoinMiddle (a : M) (h : ℝ) (q : ℝ×(Model n×Model n)) : + Model n →L[ℝ] Model n →L[ℝ] ℝ := + fderiv ℝ (fderiv ℝ (movingFixedJoinAction a h q)) 0 + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingFixedJoinAction_eq {a : M} {b : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (h T : ℝ) (p z : Model n) : + movingFixedJoinAction a h (T,(b,p)) z= + fixedJoinAction ((extChartAt 𝓘(ℝ,Model n) a).symm b) h T + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) + (0,((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p)+ + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) z)) := by + simp only [movingFixedJoinAction,fixedJoinAction,movingNormal_eq hb,map_smul,map_add,map_zero] + +lemma movingFixedJoinAction_contDiffAt {a : M} {b p : Model n} {h T : ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hTh : T≠h) + (hleft : h • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hright : (T-h) • (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (Function.uncurry (movingFixedJoinAction a h)) ((T,(b,p)),0) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + let q := ((T,(b,p)),(0 : Model n)) + let Q := (ℝ×(Model n×Model n))×Model n + have hA : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal a (z.1.2.1,0)) q := + (movingNormal_contMDiffAt (q := (b,0)) hb).comp q + (contDiffAt_fst.snd.fst.prodMk contDiffAt_const).contMDiffAt + have hB : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal a (z.1.2.1,h • (z.1.2.2+z.2))) q := + (movingNormal_contMDiffAt (q := (b,h • (p+0))) hb).comp q + (contDiffAt_fst.snd.fst.prodMk + ((contDiffAt_const (c := h)).smul (contDiffAt_fst.snd.snd.add contDiffAt_snd))).contMDiffAt + have hC : ContMDiffAt 𝓘(ℝ,Q) 𝓘(ℝ,Model n) ∞ + (fun z : Q => movingNormal a (z.1.2.1,z.1.1 • z.1.2.2)) q := + (movingNormal_contMDiffAt (q := (b,T • p)) hb).comp q + (contDiffAt_fst.snd.fst.prodMk + (contDiffAt_fst.fst.smul contDiffAt_fst.snd.snd)).contMDiffAt + have hc₁ := cost_contMDiffAt_of_injectivityDomain + (⟨x,h • L p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hleft + have hc₂ := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow h (⟨x,L p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (T-h) • (sprayFlow h (⟨x,L p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + have hc₁' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + (movingNormal a (b,0),movingNormal a (b,h • (p+0))) := by + simpa only [movingNormal_eq hb,map_zero,riemannianExp_zero,add_zero,map_smul] using hc₁ + have hc₂' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun z : M×M => cost z.1 z.2) + (movingNormal a (b,h • (p+0)),movingNormal a (b,T • p)) := by + dsimp only at hc₂ + rw [shifted_exp_time] at hc₂ + simpa only [movingNormal_eq hb,add_zero,map_smul,riemannianExp_smul] using hc₂ + exact ((hc₁'.comp q (hA.prodMk hB)).contDiffAt.div_const h).add + (((hc₂'.comp q (hB.prodMk hC)).contDiffAt).div + (contDiffAt_fst.fst.sub contDiffAt_const) (sub_ne_zero.mpr hTh)) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingFixedJoinMiddle_contDiffAt {a : M} {h T : ℝ} {b p : Model n} + (H : ContDiffAt ℝ ∞ (Function.uncurry (movingFixedJoinAction a h)) ((T,(b,p)),0)) : + ContDiffAt ℝ ∞ (movingFixedJoinMiddle a h) (T,(b,p)) := + (ContDiffAt.partial_snd_fderiv_two H).comp (T,(b,p)) + (contDiffAt_id.prodMk contDiffAt_const) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma movingFixedJoinMiddle_eq {a : M} {b : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (h T : ℝ) (p v w : Model n) + (H : ContDiffAt ℝ 2 (fixedJoinAction ((extChartAt 𝓘(ℝ,Model n) a).symm b) h T + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p)) + (0,((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p))) : + movingFixedJoinMiddle a h (T,(b,p)) v w= + fixedJoinMiddle ((extChartAt 𝓘(ℝ,Model n) a).symm b) h T + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) v) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) w) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + let I := (0 : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x).prod L + have he : movingFixedJoinAction a h (T,(b,p))= + (fun z => fixedJoinAction x h T (L p) ((0,L p)+I z)) := by + ext z + simpa only [I,ContinuousLinearMap.prod_apply,zero_apply, + Prod.mk_add_mk,add_zero] using movingFixedJoinAction_eq hb h T p z + rw [movingFixedJoinMiddle,he] + have H' := second_fderiv_comp_affine I (0,L p) 0 (by simpa only [map_zero,add_zero] using H) v w + simpa only [I,ContinuousLinearMap.prod_apply,zero_apply,map_zero, + add_zero,fixedJoinMiddle_apply] using H' + +lemma movingFixedJoinMiddle_trivialization {a x : M} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) (h T : ℝ) + (p v w : TangentSpace 𝓘(ℝ,Model n) x) + (H : ContDiffAt ℝ 2 (fixedJoinAction x h T p) (0,p)) : + movingFixedJoinMiddle a h (T,(extChartAt 𝓘(ℝ,Model n) a x, + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x p)) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x v) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x w)= + fixedJoinMiddle x h T p v w := by + let e := trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + have hx' : x∈e.baseSet := by simpa only [e,TangentBundle.trivializationAt_baseSet,extChartAt_source] using hx + have HL : ∀ v : TangentSpace 𝓘(ℝ,Model n) x, e.symmL ℝ x (e.continuousLinearMapAt ℝ x v)=v := + fun v => e.symmL_continuousLinearMapAt hx' v + have HB : ContDiffAt ℝ 2 + (fixedJoinAction ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a x)) h T + (e.symmL ℝ ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a x)) + (e.continuousLinearMapAt ℝ x p))) + (0,e.symmL ℝ ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a x)) + (e.continuousLinearMapAt ℝ x p)) := by + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv hx,HL] + exact H + have HE := movingFixedJoinMiddle_eq ((extChartAt 𝓘(ℝ,Model n) a).map_source hx) h T + (e.continuousLinearMapAt ℝ x p) (e.continuousLinearMapAt ℝ x v) + (e.continuousLinearMapAt ℝ x w) HB + dsimp only [e] at HL HE + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv hx] at HE + simpa only [HL] using HE + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FrameAbsorption.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameAbsorption.lean new file mode 100644 index 0000000000000000000000000000000000000000..217abfdf65c882e887fee507a8552f0128396c98 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameAbsorption.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingHessianLimit +import OAI.Analysis.BiholderTransport.Regularity.FrameMetric +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearAbsorption + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FrameAbsorption +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma eventual_frame_rank_lower {a:M} {b p:ℕ → Model n} {q:Model n} + {H:ℕ → Model n →L[ℝ] Model n →L[ℝ] ℝ} {A C:ℝ} (hA:0.comp (tendsto_clm_apply hG hp) + obtain ⟨δ,hδ,hcoer⟩ := frameMetric_center_coercive (n := n) a + have HH : ∀ε:ℝ,0<ε → ∀ᶠ k in atTop,∀d:Model n, + A*frameMetric a b₀ d d+C*covectorSquare (frameMetric a b₀ q) d d-ε*‖d‖^2≤H k d d := by + intro ε he + filter_upwards [hH ε he] with k hk + intro d + have hself : frameMetric a b₀ d d=‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2 := by + exact (frameMetric_center a d d).trans + (real_inner_self_eq_norm_sq (show TangentSpace 𝓘(ℝ,Model n) a from d)) + simpa only [hself,covectorSquare_apply,frameMetric_center,←sq,b₀] using hk d + have HG := eventual_moving_rank_lower hA hδ hcoer hG hR HH + have ht : ∀ᶠ k in atTop,b k∈(extChartAt 𝓘(ℝ,Model n) a).target := + hb.eventually ((isOpen_extChartAt_target a).mem_nhds hb₀) + filter_upwards [HG,ht] with k hk hbk + intro d + simpa only [Function.comp_def,covectorSquare_apply,frameMetric_apply hbk,real_inner_self_eq_norm_sq,←sq] using hk d + +end FrameAbsorption +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FrameDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..19528c863db076996fb8ede4b1764220760e46ab --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameDet.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FrameMetric +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearMatrix + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FrameDet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance frameDetFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance frameDetComplete (x:M) : CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x) := + FiniteDimensional.complete ℝ _ + +lemma frameMetric_operator {a:M} {b:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + bilinearOperator (frameMetric a b)=(chartFiberInverse a b).adjoint.comp (chartFiberInverse a b) := by + apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro e + rw [bilinearOperator_inner,frameMetric_apply hb] + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] + +lemma frameMetric_det {a:M} {b:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + (bilinearOperator (frameMetric a b)).det=(chartFiberInverse a b).toLinearMap.normDet^2 := by + rw [frameMetric_operator hb] + simpa only [RCLike.ofReal_real_eq_id,id_eq] using (chartFiberInverse a b).normDet_sq.symm + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma frameNormDet_pos {a:M} {b:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + 0<(chartFiberInverse a b).toLinearMap.normDet := by + apply lt_of_le_of_ne (LinearMap.normDet_nonneg _) (Ne.symm _) + intro h + exact (LinearMap.normDet_eq_zero_iff_ker_ne_bot.mp h) + (LinearMap.ker_eq_bot.mpr (chartFiberInverse_injective hb)) + +lemma frameNormDet_continuousAt {a:M} {b:Model n} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContinuousAt (fun z=>(chartFiberInverse a z).toLinearMap.normDet) b := by + have H:ContinuousAt (fun z=>Real.sqrt (bilinearOperator (frameMetric a z)).det) b := by + exact Real.continuous_sqrt.continuousAt.tendsto.comp + (bilinear_det_tendsto (frameMetric_continuousAt hb).tendsto) + apply H.congr_of_eventuallyEq + filter_upwards [(isOpen_extChartAt_target _).mem_nhds hb] with z hz + rw [frameMetric_det hz,Real.sqrt_sq (LinearMap.normDet_nonneg _)] + +end FrameDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FrameMetric.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameMetric.lean new file mode 100644 index 0000000000000000000000000000000000000000..be02aa5236ef22f2aba54cab6f048183a8abb6d4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FrameMetric.lean @@ -0,0 +1,88 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.UniformEnvelope +import OAI.Analysis.BiholderTransport.Regularity.MovingPrefix +import OAI.Analysis.BiholderTransport.LocalFlow.ModelTangentJet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section FrameMetric +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def frameMetric (a:M) (b:Model n) : Model n →L[ℝ] Model n →L[ℝ] ℝ := + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 b)) 0 + +omit [Nonempty M] in +lemma frameMetric_apply {a:M} {b:Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (d e:Model n) : + frameMetric a b d e=inner ℝ (chartFiberInverse a b d) (chartFiberInverse a b e) := by + have hp : (1:ℝ) • chartFiberInverse a b 0∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm b) := by + simpa only [map_zero,smul_zero] using zero_mem_injectivityDomain + (n := n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) + simpa only [frameMetric,chartFiberInverse,one_mul] using movingPrefixEnergy_hessian hb hp d e + +omit [Nonempty M] in +lemma frameMetric_continuousAt {a:M} {b:Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) : ContinuousAt (frameMetric a) b := by + have hp : (1:ℝ) • chartFiberInverse a b 0∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm b) := by + simpa only [map_zero,smul_zero] using zero_mem_injectivityDomain + (n := n) ((extChartAt 𝓘(ℝ,Model n) a).symm b) + have H := (ContDiffAt.partial_snd_fderiv_two (movingPrefixEnergy_contDiffAt hb hp)).continuousAt + exact ContinuousAt.comp (f := fun z:Model n=>(z,(0:Model n))) H + (show ContinuousAt (fun z:Model n=>(z,(0:Model n))) b from + continuousAt_id.prodMk continuousAt_const) + +omit [Nonempty M] in +lemma frameMetric_center (a:M) (d e:Model n) : + frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) d e= + inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from d) e := by + rw [frameMetric_apply ((extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a))] + have ha := (extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a) + dsimp only [chartFiberInverse] + rw [ha,center_frame_identity,center_frame_identity] + +omit [Nonempty M] in +lemma frameMetric_center_coercive (a:M) : ∃ δ>0,∀ d:Model n, + δ*‖d‖^2≤frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) d d := by + let T := trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + let A := T.continuousLinearMapAt ℝ a + let K := ‖A‖+1 + have hK : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma moving_frame_outward_limit {a:M} {b p r:ℕ → Model n} {q s:Model n} + {w:ℕ → ℝ} {m μ κ D ν:ℝ} + (hb:Tendsto b atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hp:Tendsto p atTop (𝓝 q)) (hr:Tendsto r atTop (𝓝 s)) + (hw:Tendsto w atTop (𝓝 m)) (hμ:0 < μ) (hκ:0 < κ) (hD:0 < D) (hν:0 < ν) + (hsel:∀ᶠ k in atTop, + let A:=chartFiberInverse a (b k) + ∃e:TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)),∃d:ℝ, + ‖e‖=1 ∧ 0 < inner ℝ (A (p k)) e ∧ κ*D ≤ (inner ℝ (A (p k)) e)^2 ∧ + 0 < d ∧ A (r k)=A (p k)+d • e ∧ μ ≤ w k ∧ + ν*D/(inner ℝ (A (p k)) e) ≤ w k*d ∧ + d ≤ 3*D/(2*(inner ℝ (A (p k)) e))) : + μ ≤ m ∧ ∃e:TangentSpace 𝓘(ℝ,Model n) a,∃d:ℝ,‖e‖=1 ∧ 0 < d ∧ + (show TangentSpace 𝓘(ℝ,Model n) a from s)=(show TangentSpace 𝓘(ℝ,Model n) a from q)+d • e ∧ + 0 < inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e ∧ + κ*D ≤ (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e)^2 ∧ + ν*D/(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e) ≤ m*d ∧ + d ≤ 3*D/(2*(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e)) ∧ + ‖show TangentSpace 𝓘(ℝ,Model n) a from s‖^2- + ‖show TangentSpace 𝓘(ℝ,Model n) a from q‖^2 ≤ (3+9/(4*κ))*D := by + have hbase:(extChartAt 𝓘(ℝ,Model n) a a)∈(extChartAt 𝓘(ℝ,Model n) a).target:=mem_extChartAt_target a + have hbt:∀ᶠ k in atTop,b k∈(extChartAt 𝓘(ℝ,Model n) a).target:= + hb.eventually ((isOpen_extChartAt_target a).mem_nhds hbase) + have hG:=(frameMetric_continuousAt hbase).tendsto.comp hb + have hdiff:=hr.sub hp + have hI:=tendsto_clm_apply (tendsto_clm_apply hG hp) hdiff + have hN:=tendsto_clm_apply (tendsto_clm_apply hG hdiff) hdiff + simp only [frameMetric_center] at hI hN + have H:∀ᶠ k in atTop,μ ≤ w k ∧ + ν*D ≤ w k*frameMetric a (b k) (p k) (r k-p k) ∧ + κ*D*frameMetric a (b k) (r k-p k) (r k-p k) ≤ + (frameMetric a (b k) (p k) (r k-p k))^2 ∧ + frameMetric a (b k) (p k) (r k-p k) ≤ 3*D/2 ∧ + frameMetric a (b k) (r k-p k) (r k-p k) ≤ (9/(4*κ))*D:=by + filter_upwards [hsel,hbt] with k hk hbk + dsimp only at hk + obtain ⟨e,d,he,hep,hq,hd,hrd,hm,hmom,hdb⟩:=hk + have HH:=outward_closed_conditions he hep hd hrd hκ hD hq hmom hdb + simp only [frameMetric_apply hbk] + simp only [map_sub,real_inner_self_eq_norm_sq] + exact ⟨hm,HH⟩ + have Hm:μ ≤ m:=ge_of_tendsto hw (H.mono (fun k hk=>hk.1)) + refine ⟨Hm,?_⟩ + apply outward_direction_of_closed_conditions (hμ.trans_le Hm) hκ hD hν + · exact ge_of_tendsto (hw.mul hI) (H.mono (fun k hk=>hk.2.1)) + · have HH:=le_of_tendsto_of_tendsto (tendsto_const_nhds.mul hN) (hI.pow 2) + (H.mono (fun k hk=>hk.2.2.1)) + rw [show inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from s-q) (s-q)= + ‖show TangentSpace 𝓘(ℝ,Model n) a from s-q‖^2 from + @real_inner_self_eq_norm_sq (TangentSpace 𝓘(ℝ,Model n) a) _ _ (s-q)] at HH + exact HH + · exact le_of_tendsto hI (H.mono (fun k hk=>hk.2.2.2.1)) + · have HH:=le_of_tendsto hN (H.mono (fun k hk=>hk.2.2.2.2)) + rw [show inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from s-q) (s-q)= + ‖show TangentSpace 𝓘(ℝ,Model n) a from s-q‖^2 from + @real_inner_self_eq_norm_sq (TangentSpace 𝓘(ℝ,Model n) a) _ _ (s-q)] at HH + exact HH + +end FrameOutwardLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/FunctionalDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/FunctionalDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..0e0b1b66caf675d4ab8407ad34fc1140869995c5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/FunctionalDet.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.DeterminantOrder + +namespace OAI + +section + +noncomputable section +open Matrix +open scoped MatrixOrder + +namespace WeakMTWTransport +variable {n : Type*} [Fintype n] [DecidableEq n] + +lemma determinant_gain_of_functional_bounds [Nonempty n] + {L V W : Matrix n n ℝ} {e p pi : n → ℝ} {m beta gamma : ℝ} + (hL : L.IsHermitian) (he : L *ᵥ e = 0) + (hq : 0 < p ⬝ᵥ e) (hqi : p ⬝ᵥ e ≤ pi ⬝ᵥ e) + (hm : 0 < m) (hbeta : 0 < beta) (hgamma : 0 < gamma) + (hV : V.PosDef) (hVL : V ≤ L + beta • Matrix.vecMulVec p p) + (hLW : m • L + gamma • Matrix.vecMulVec pi pi ≤ W) : + gamma * m ^ (Fintype.card n - 1) * V.det ≤ beta * W.det := by + let q := p ⬝ᵥ e + let qi := pi ⬝ᵥ e + let t := Real.sqrt (gamma / (m * beta)) + have hq0 : q ≠ 0 := ne_of_gt hq + have ht : 0 < t := Real.sqrt_pos.2 (div_pos hgamma (mul_pos hm hbeta)) + have ht2 : t ^ 2 = gamma / (m * beta) := + Real.sq_sqrt (le_of_lt (div_pos hgamma (mul_pos hm hbeta))) + let a : n → ℝ := q⁻¹ • (t • pi - p) + let S : Matrix n n ℝ := 1 + Matrix.vecMulVec e a + have hSp : Sᵀ *ᵥ p = t • pi := by + dsimp [S] + rw [Matrix.mulVec_transpose, Matrix.vecMul_add, Matrix.vecMul_one, + Matrix.vecMul_vecMulVec] + change p + q • (q⁻¹ • (t • pi - p)) = t • pi + rw [smul_smul, mul_inv_cancel₀ hq0, one_smul, add_sub_cancel] + have hSdet : S.det = t * qi / q := by + dsimp [S] + rw [det_one_add_vecMulVec] + dsimp [a] + rw [smul_dotProduct, sub_dotProduct, smul_dotProduct] + change 1 + q⁻¹ * (t * qi - q) = t * qi / q + field_simp + ring + have hSge : t ≤ S.det := by + rw [hSdet, le_div_iff₀ hq] + exact mul_le_mul_of_nonneg_left hqi ht.le + have hSpos : 0 < S.det := ht.trans_le hSge + have hSinj : Function.Injective S.mulVec := + Matrix.mulVec_injective_iff_isUnit.2 + ((Matrix.isUnit_iff_isUnit_det S).2 (isUnit_iff_ne_zero.2 hSpos.ne')) + have hsmall : (m • (Sᵀ * V * S)).PosDef := by + simpa only [Matrix.conjTranspose_eq_transpose_of_trivial] using + (hV.conjTranspose_mul_mul_same hSinj).smul hm + have hfix : Sᵀ * L * S = L := oblique_fixes_kernel_form hL he a + have hscalar : m * beta * t ^ 2 = gamma := by + rw [ht2] + field_simp + have heq : m • (Sᵀ * (L + beta • Matrix.vecMulVec p p) * S) = + m • L + gamma • Matrix.vecMulVec pi pi := by + rw [Matrix.mul_add Sᵀ L (beta • Matrix.vecMulVec p p), Matrix.add_mul, hfix, smul_add, + Matrix.mul_smul, Matrix.smul_mul, congruence_rank_one, hSp] + ext i j + simp only [Matrix.add_apply, Matrix.smul_apply, smul_eq_mul, + Matrix.vecMulVec_apply, Pi.smul_apply] + linear_combination pi i * pi j * hscalar + have horder : m • (Sᵀ * V * S) ≤ W := by + apply le_trans _ hLW + rw [← heq] + have h := (transpose_congruence_mono hVL S).smul hm.le + rw [Matrix.le_iff] + simpa only [smul_sub] using h + have hdet := det_le_of_posDef_le hsmall horder + rw [Matrix.det_smul, Matrix.det_mul, Matrix.det_mul, Matrix.det_transpose] at hdet + have hsquare : t ^ 2 ≤ S.det ^ 2 := by nlinarith + have hmpow : 0 < m ^ Fintype.card n := pow_pos hm _ + have hlower : m ^ Fintype.card n * t ^ 2 * V.det ≤ W.det := by + nlinarith [mul_nonneg (mul_nonneg hmpow.le (sub_nonneg.2 hsquare)) hV.det_pos.le] + have hcard : Fintype.card n = (Fintype.card n - 1) + 1 := + (Nat.sub_add_cancel Fintype.card_pos).symm + have hpower : m ^ Fintype.card n = m ^ (Fintype.card n - 1) * m := by + conv_lhs => rw [hcard, pow_succ] + have hcancel : beta * (m ^ Fintype.card n * t ^ 2 * V.det) = + gamma * m ^ (Fintype.card n - 1) * V.det := by + rw [hpower] + calc + beta * (m ^ (Fintype.card n - 1) * m * t ^ 2 * V.det) = + m ^ (Fintype.card n - 1) * V.det * (m * beta * t ^ 2) := by ring + _ = gamma * m ^ (Fintype.card n - 1) * V.det := by rw [hscalar]; ring + rw [← hcancel] + exact mul_le_mul_of_nonneg_left hlower hbeta.le + +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/GeneratingKernel.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/GeneratingKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..11aae707a6773a32cdf729ec76cda8d306098263 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/GeneratingKernel.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.Hessian + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma localMin_generating_kernel {B : E×F → ℝ} {Q : E → F} {p w : E} + (hB : ContDiffAt ℝ 2 B (p,Q p)) (hmin : IsLocalMin B (p,Q p)) + (hQ : DifferentiableAt ℝ Q p) + (hstat : ∀ᶠ v in 𝓝 p, ∀ a : E, fderiv ℝ B (v,Q v) (a,0) = 0) + (hker : fderiv ℝ Q p w = 0) : + fderiv ℝ (fderiv ℝ B) (p,Q p) (w,0) = 0 := by + let G : E → E×F := fun v => (v,Q v) + let G' : E →L[ℝ] E×F := (ContinuousLinearMap.id ℝ E).prod (fderiv ℝ Q p) + have hG : HasFDerivAt G G' p := (hasFDerivAt_id p).prodMk hQ.hasFDerivAt + have hDB : HasFDerivAt (fderiv ℝ B) (fderiv ℝ (fderiv ℝ B) (p,Q p)) (G p) := + ((hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)).hasFDerivAt + have hd := ((hDB.comp p hG).clm_apply (hasFDerivAt_const (w,(0:F)) p)).fderiv + have heq : (fun v => fderiv ℝ B (G v) (w,0)) =ᶠ[𝓝 p] fun _ => (0:ℝ) := + hstat.mono (fun _ hv => hv w) + have hzero : fderiv ℝ (fun v => fderiv ℝ B (G v) (w,0)) p = 0 := by + rw [heq.fderiv_eq]; exact fderiv_const_apply (0:ℝ) + have hh := congrArg (fun L : E →L[ℝ] ℝ => L w) (hzero.symm.trans hd) + have hdiag : fderiv ℝ (fderiv ℝ B) (p,Q p) (w,0) (w,0) = 0 := by + simpa [G',hker] using hh.symm + apply ContinuousLinearMap.ext + intro u + exact localMin_hessian_null hB hmin hdiag u + +lemma localMin_generating_cotangent_kernel {B : E×F → ℝ} {Q : E → F} {p w : E} + (hB : ContDiffAt ℝ 2 B (p,Q p)) (hmin : IsLocalMin B (p,Q p)) + (hQ : DifferentiableAt ℝ Q p) + (hstat : ∀ᶠ v in 𝓝 p, ∀ a : E, fderiv ℝ B (v,Q v) (a,0) = 0) + (hker : fderiv ℝ Q p w = 0) (u : F) : + fderiv ℝ (fun v => fderiv ℝ B (v,Q v) (0,u)) p w = 0 := by + have hdB : DifferentiableAt ℝ (fderiv ℝ B) (p,Q p) := + (hB.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + have hd := ((hdB.hasFDerivAt.comp p + ((hasFDerivAt_id p).prodMk hQ.hasFDerivAt)).clm_apply + (hasFDerivAt_const ((0:E),u) p)).fderiv + have hh := congrArg (fun L : E →L[ℝ] ℝ => L w) hd + simpa [hker,localMin_generating_kernel hB hmin hQ hstat hker] using hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/GraphInverse.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/GraphInverse.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5d87fe053e9a93a5f8cea3ca4799c26b6705190 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/GraphInverse.lean @@ -0,0 +1,58 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.PoleCoordinates + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def WeakMTW.graphHomeomorph (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0hmtw.active_hull_precut hv ht ht1 x p + (normalSubdifferential_subset_active_hull hv x hp))) + +lemma WeakMTW.graphHomeomorph_inverse_pole (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0graphProjection (cTransform v) t (q k)) atTop + (𝓝 (graphProjection (cTransform v) t q₀))) : + Tendsto (fun k=>(q k).1) atTop (𝓝 q₀.1) := by + have H := (hmtw.graphHomeomorph hv ht ht1).symm.continuous.tendsto + ((hmtw.graphHomeomorph hv ht ht1) q₀) + have H' := H.comp hz + change Tendsto (fun k=>(hmtw.graphHomeomorph hv ht ht1).symm + ((hmtw.graphHomeomorph hv ht ht1) (q k))) atTop + (𝓝 ((hmtw.graphHomeomorph hv ht ht1).symm + ((hmtw.graphHomeomorph hv ht ht1) q₀))) at H' + simp only [Homeomorph.symm_apply_apply] at H' + exact continuous_subtype_val.tendsto q₀ |>.comp H' + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/HopfApproximation.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/HopfApproximation.lean new file mode 100644 index 0000000000000000000000000000000000000000..1438a6d15de94eb2511ac8c6e0f504aa6dc5b8c4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/HopfApproximation.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.EuclideanUpper + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology NNReal + +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +lemma hopfLax_le_self {u : M → ℝ} (hu : Continuous u) (t : ℝ) (z : M) : + hopfLax t u z ≤ u z := by + simpa only [cost,dist_self,zero_pow (by norm_num : 2≠0),zero_div,add_zero] using hopfLax_le hu t z z + +lemma hopfLax_short_approx {u : M → ℝ} {L : ℝ≥0} (hu : LipschitzWith L u) + {t : ℝ} (ht : 0 linarith only [hx,hy,Hx,Hy,Bx,By] + +lemma hopfLax_one (u : M → ℝ) (hu : Continuous u) : + hopfLax 1 u=fun z => -cTransform u z := by + funext z + simpa only [one_mul,div_one] using hopfLax_eq_neg_transform hu (by norm_num : (0:ℝ)<1) z + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +lemma uniform_hopfLax_minimizers_eventually_in (L : ℝ≥0) {x : M} {V : Set M} + (hV : V∈𝓝 x) : + ∀ᶠ q : ℝ×M in 𝓝 ((0:ℝ),x), 0 2*(L:ℝ)*q.1+dist q.2 x) (0,x) := by fun_prop + have he : ∀ᶠ q : ℝ×M in 𝓝 ((0:ℝ),x),2*(L:ℝ)*q.1+dist q.2 x B ((v y-a)/D), + hB.comp ((hv.sub continuous_const).div_const D)⟩ + +omit [Nonempty M] in +lemma continuous_boundedModifiedDatum (v : M → ℝ) (hv : Continuous v) (a D : ℝ) + (B : ℝ → ℝ) (hB : Continuous B) : Continuous (boundedModifiedDatum v hv a D B hB) := + continuous_const.add (continuous_id.smul continuous_const) + +lemma continuous_cTransform_family {X : Type*} [TopologicalSpace X] + {U : X → M →ᵇ ℝ} (hU : Continuous U) : + Continuous (fun q : X×M => cTransform (U q.1) q.2) := by + exact continuous_eval.comp ((boundedCTransform_nonexpansive.continuous.comp + (hU.comp continuous_fst)).prodMk continuous_snd) + +lemma continuous_hopfLax_family {X : Type*} [TopologicalSpace X] + {U : X → M →ᵇ ℝ} (hU : Continuous U) {t : ℝ} (ht : 0 hopfLax t (U q.1) q.2) := by + have H := (continuous_cTransform_family ((continuous_const : Continuous (fun _ : X => t)).smul hU)).neg.div_const t + convert H using 1 + funext q + exact hopfLax_eq_neg_transform (U q.1).continuous ht q.2 + +lemma continuous_regularizedComparison {v : M → ℝ} (hv : Continuous v) + (a D bplus : ℝ) {t : ℝ} (ht : 0 parameterPenalty bplus q.1) := by + unfold parameterPenalty + fun_prop + exact (H1.add H2).sub HP + +lemma regularizedComparison_error {v : M → ℝ} (hv : Continuous v) + {a D bplus t b H : ℝ} {Bc Bo : ℝ → ℝ} (ho : Continuous Bo) + {L : ℝ≥0} (hc : LipschitzWith L (modifiedDatum v a D b Bc)) + (hH : ∀ x y : M,cost x y≤H) (_ : 0 linarith only [H3.1,H3.2,H2.1,H2.2, + mul_nonneg (sq_nonneg (L:ℝ)) (sub_nonneg.mpr ht1.le)] + +lemma regularized_interior_maximum {v : M → ℝ} (hv : Continuous v) + {a D bplus bminus t err : ℝ} {Bc Bo : ℝ → ℝ} + (hc : Continuous Bc) (ho : Continuous Bo) (ht : 0 linarith only [hsmall,hp] + have hmp : bminus≤bplus := hbs.1.trans hbs.2 + obtain ⟨y,hy⟩ := hlower + change bplus/(8*1024^2)≤ modifiedExcess v a D bs Bc Bo y at hy + let F := regularizedComparison v a D bplus t Bc Bo + have hPstar : parameterPenalty bplus bs=bplus/(16*1024^2) := by + dsimp [parameterPenalty,bs] + field_simp [hp.ne'] + ring + have Hstar := (abs_le.mp (he bs hbs y)).1 + rw [hPstar] at Hstar + have hstar : bplus/(16*1024^2)-err≤F (bs,y) := by + change _≤regularizedComparison v a D bplus t Bc Bo (bs,y) + linarith only [Hstar,hy] + have HS : IsCompact (Icc bminus bplus×ˢ(univ : Set M)) := isCompact_Icc.prod isCompact_univ + obtain ⟨q,hq,hqmax⟩ := HS.exists_isMaxOn ⟨(bs,y),hbs,mem_univ y⟩ + (continuous_regularizedComparison hv a D bplus ht ht1 hc ho).continuousOn + have hmax : F (bs,y)≤F q := hqmax ⟨hbs,mem_univ y⟩ + have hpos : 0 hqmax ⟨hw,mem_univ _⟩⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/IntrinsicTestDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/IntrinsicTestDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..d4993aef9546bf194f536fddff016aba6bd13f24 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/IntrinsicTestDet.lean @@ -0,0 +1,98 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.UniformCharts +import OAI.Analysis.BiholderTransport.Regularity.PullbackDet +import OAI.Analysis.BiholderTransport.Coordinates.NormalTestChart +import OAI.Analysis.BiholderTransport.Regularity.MixedDetIntrinsic +import OAI.Analysis.BiholderTransport.Regularity.UniformTestDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction NNReal + +namespace WeakMTWTransport +section IntrinsicTestDet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance ivFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.exists_uniform_intrinsic_test_det_bound + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} + (hlam:00,∀d,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) 0 d d+hessianValue x p d) → + expJacobian (n:=n) x p * + |(bilinearOperator (fderiv ℝ (fderiv ℝ φ) 0+normalHessian x p)).det|≤K := by + obtain ⟨C,hC,l,u,hl,hu,Hcharts⟩:=exists_uniform_volume_charts (n:=n) (M:=M) + let A:ℝ:=(cap/lam)*((C:ℝ)*(C:ℝ))^n + have hA:0≤A:=by dsimp [A]; positivity + refine ⟨u*A/l+1,by positivity,?_⟩ + intro x0 x uv p φ huv hp hφ hφD hval hlo hpos + let y:=riemannianExp (n:=n) x p + obtain ⟨a,U,hU,hxU,hUa,hCa,hDa,hJa⟩:=Hcharts x + obtain ⟨b,V,hV,hyV,hVb,hCb,hDb,hJb⟩:=Hcharts y + have hx:=hUa hxU + have hy:=hVb hyV + let z:=extChartAt 𝓘(ℝ,Model n) a x + obtain ⟨ψ,R,hψ,hreg,hey,hvalue,hlower,hpositive,hR,hpull⟩:= + normal_test_to_chart hx hp hφ hφD hval hlo hpos + have Hbound:|(fderiv ℝ (chartTestContact a b ψ) z).det|≤A:=by + apply hmtw.test_det_bound_on_charts hlam hcap hU hUa hV hVb hDa hCb + (mem_image_of_mem _ hxU) huv hψ (by rwa [hey]) hreg hvalue hlower + simpa only [hey] using hpositive + let W:=bilinearOperator (fderiv ℝ (fderiv ℝ φ) 0+normalHessian x p) + let B:=mixedCostOperator a b z (extChartAt 𝓘(ℝ,Model n) b y) + let T:=fderiv ℝ (chartTestContact a b ψ) z + have hfactor:(R.adjoint.comp (W.comp R))=B.comp T:=by + rw [←hpull] + have H:=relative_hessian_operator_factor_fixed ((extChartAt 𝓘(ℝ,Model n) a).map_source hx) + hψ hreg (by rwa [hey]) + simpa only [hey] using H + have Hdet:R.toLinearMap.normDet^2* |W.det|=|B.det| * |T.det|:=by + rw [←abs_det_hessian_pullback R W rfl,hfactor] + change |(B.toLinearMap.comp T.toLinearMap).det|=_ + rw [LinearMap.det_comp,abs_mul] + have Hmix:chartJacobian (n:=n) a x * |B.det| * + (chartJacobian (n:=n) b y*expJacobian (n:=n) x p)=1:=mixed_intrinsic_det hx hp hy + have Heq:chartJacobian (n:=n) b y*expJacobian (n:=n) x p* |W.det|= + chartJacobian (n:=n) a x* |T.det|:=by + calc + _ = (chartJacobian (n:=n) a x*R.toLinearMap.normDet)^2* + (chartJacobian (n:=n) b y*expJacobian (n:=n) x p* |W.det|):=by rw [hR]; ring + _ = (chartJacobian (n:=n) a x)^2*(chartJacobian (n:=n) b y*expJacobian (n:=n) x p)* + (R.toLinearMap.normDet^2* |W.det|):=by ring + _ = (chartJacobian (n:=n) a x)^2*(chartJacobian (n:=n) b y*expJacobian (n:=n) x p)* + (|B.det| * |T.det|):=by rw [Hdet] + _ = chartJacobian (n:=n) a x*(chartJacobian (n:=n) a x* |B.det| * + (chartJacobian (n:=n) b y*expJacobian (n:=n) x p))* |T.det|:=by ring + _ = _:=by rw [Hmix]; ring + have Hlo:l*(expJacobian (n:=n) x p* |W.det|)≤ + chartJacobian (n:=n) b y*expJacobian (n:=n) x p* |W.det|:=by + nlinarith only [mul_le_mul_of_nonneg_right (hJb y hyV).1 + (mul_nonneg (expJacobian_pos_of_injectivityDomain hp).le (abs_nonneg W.det))] + have Hhi:chartJacobian (n:=n) a x* |T.det|≤u*A:= + mul_le_mul (hJa x hxU).2 Hbound (abs_nonneg _) hu.le + have H:expJacobian (n:=n) x p* |W.det|≤u*A/l:= + (le_div_iff₀ hl).mpr (by nlinarith only [Hlo,Heq,Hhi]) + exact H.trans (by linarith) + +end IntrinsicTestDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/InverseDifferenceGain.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/InverseDifferenceGain.lean new file mode 100644 index 0000000000000000000000000000000000000000..6264b0a87c211ff6b3dd47e8a51e531cbee73543 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/InverseDifferenceGain.lean @@ -0,0 +1,67 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.EigenOrder + +namespace OAI + +noncomputable section +open Set Module + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma inverse_difference_pullback_identity {D B R S : E →L[ℝ] E} + (hB : B.toLinearMap.IsSymmetric) + (hBR : ∀ v, B (R v)=v) (hDS : ∀ v, S (D v)=v) (w : E) : + inner ℝ (R (D w)-S (D w)) (D w)= + inner ℝ ((D-B) w) w+inner ℝ (R ((D-B) w)) ((D-B) w) := by + have hRB := left_inverse_of_right_inverse hBR + have hRw : R (D w)-S (D w)=R ((D-B) w) := by + simp only [sub_apply,map_sub,hDS,hRB] + rw [hRw] + have hsplit : D w=B w+(D-B) w := by simp + conv_lhs => rhs; rw [hsplit] + rw [inner_add_right] + have H : inner ℝ (R ((D-B) w)) (B w)=inner ℝ ((D-B) w) w := by + calc + _ = inner ℝ (B (R ((D-B) w))) w := (hB _ _).symm + _ = _ := congrArg (fun v => inner ℝ v w) (hBR ((D-B) w)) + rw [H] + +lemma inverse_difference_pullback_lower {D B R S : E →L[ℝ] E} {c : ℝ} + (hB : B.toLinearMap.IsSymmetric) + (hBR : ∀ v, B (R v)=v) (hDS : ∀ v, S (D v)=v) + (hR : ∀ v, 0≤ inner ℝ (R v) v) + (hcross : ∀ v, c*‖v‖^2≤ inner ℝ ((D-B) v) v) (w : E) : + c*‖w‖^2≤ inner ℝ (R (D w)-S (D w)) (D w) := by + rw [inverse_difference_pullback_identity hB hBR hDS] + exact (hcross w).trans (le_add_of_nonneg_right (hR _)) + +lemma inverse_difference_isotropic_of_factor + {F : Type*} [NormedAddCommGroup F] [InnerProductSpace ℝ F] + {D B R S : E →L[ℝ] E} {J : F →L[ℝ] E} {C : E →L[ℝ] F} {a c : ℝ} + (ha : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma joint_movingPrefix_contMDiffAt {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContMDiffAt 𝓘(ℝ,(ℝ×Model n)×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : (ℝ×Model n)×Model n=>movingPrefix a q.1.1 q.1.2 q.2) ((t,b),p) := by + exact (movingNormal_contMDiffAt (q := (b,t • p)) hb).comp ((t,b),p) + (contDiffAt_fst.snd.prodMk (contDiffAt_fst.fst.smul contDiffAt_snd)).contMDiffAt + +lemma joint_movingPrefixChart_contDiffAt {a c : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) : + ContDiffAt ℝ ∞ + (fun q : (ℝ×Model n)×Model n=>movingPrefixChart a c q.1.1 q.1.2 q.2) ((t,b),p) := by + exact ((contMDiffAt_extChartAt' (I := 𝓘(ℝ,Model n)) + (by simpa only [extChartAt_source] using hc)).comp ((t,b),p) + (joint_movingPrefix_contMDiffAt hb)).contDiffAt + +lemma joint_movingPrefixEnergy_contDiffAt {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (ht : t≠0) + (hp : t • chartFiberInverse a b p∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + ContDiffAt ℝ ∞ + (fun q : (ℝ×Model n)×Model n=>movingPrefixEnergy a q.1.1 q.1.2 q.2) ((t,b),p) := by + have hA : ContMDiffAt 𝓘(ℝ,(ℝ×Model n)×Model n) 𝓘(ℝ,Model n) ∞ + (fun q : (ℝ×Model n)×Model n=>movingNormal a (q.1.2,0)) ((t,b),p) := + (movingNormal_contMDiffAt (q := (b,0)) hb).comp ((t,b),p) + (contDiffAt_fst.snd.prodMk contDiffAt_const).contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm b,t • chartFiberInverse a b p⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hp + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q:M×M=>cost q.1 q.2) (movingNormal a (b,0),movingPrefix a t b p) := by + simpa only [movingNormal_zero hb,movingPrefix_eq hb,chartFiberInverse] using hC + exact ((hC'.comp ((t,b),p) (hA.prodMk (joint_movingPrefix_contMDiffAt hb))).contDiffAt.div + contDiffAt_fst.fst ht) + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingPrefix_at_center (a : M) (t : ℝ) (p : Model n) : + movingPrefix a t (extChartAt 𝓘(ℝ,Model n) a a) p=riemannianExp a (t • p) := by + have hb := (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + rw [movingPrefix_eq hb] + change riemannianExp _ (t • chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a) p)=_ + rw [chartFiberInverse_at_center,(extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a)] + rfl + +lemma movingPrefixEnergy_hessian_at_center {a : M} {p : Model n} + (hp : p∈injectivityDomain a) (d e : Model n) : + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 (extChartAt 𝓘(ℝ,Model n) a a))) p d e= + inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from d) e := by + have hb := (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hbase := (extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a) + have hL (r : Model n) : + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ a r=r := by + rw [TangentBundle.symmL_trivializationAt_eq_core (mem_chart_source (Model n) a)] + exact tangentCoordChange_self (I := 𝓘(ℝ,Model n)) (mem_extChartAt_source a) + have hp' : (1:ℝ) • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a a)) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a a)) := by + rw [hbase] + simp only [hL] + change (1:ℝ) • (show TangentSpace 𝓘(ℝ,Model n) a from p)∈injectivityDomain a + rw [one_smul] + exact hp + have H := movingPrefixEnergy_hessian hb hp' d e + rw [hbase] at H + simpa only [hL,one_mul] using H + +end JointMovingPrefix +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/KernelBounds.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/KernelBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..753e974f16d2849a824c1ca53dd9e7961e851f33 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/KernelBounds.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.PartialDerivatives +import OAI.Analysis.BiholderTransport.LinearAlgebra.Calculus + +namespace OAI + +noncomputable section +open Set Filter Metric Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma kernel_rectangle_of_partial_lipschitz {C : E → E → ℝ} {S T : Set E} + {K : ℝ≥0} (hT : Convex ℝ T) + (hd : ∀ y∈S,∀ z∈T,DifferentiableAt ℝ (C y) z) + (hLip : LipschitzOnWith K (fun q : E×E => fderiv ℝ (C q.1) q.2) (S×ˢT)) : + ∀ y∈S,∀ y'∈S,∀ z∈T,∀ z'∈T, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖ := by + intro y hy y' hy' z hz z' hz' + have HH := Convex.norm_image_sub_le_of_norm_hasFDerivWithin_le + (f := fun q => C y' q-C y q) + (f' := fun q => fderiv ℝ (C y') q-fderiv ℝ (C y) q) + (fun q hq => ((hd y' hy' q hq).hasFDerivAt.sub (hd y hy q hq).hasFDerivAt).hasFDerivWithinAt) + (C := (K:ℝ)*‖y'-y‖) (by + intro q hq + have H := hLip.dist_le_mul (y',q) ⟨hy',hq⟩ (y,q) ⟨hy,hq⟩ + simpa only [dist_eq_norm,Prod.dist_eq,dist_self,max_eq_left (dist_nonneg),←dist_eq_norm] using H) + hT hz hz' + rw [Real.norm_eq_abs] at HH + convert HH using 1; ring_nf + +lemma smooth_kernel_second_locally_bounded {C : E → E → ℝ} {a:E} + (hc : ContDiffAt ℝ ∞ (Function.uncurry C) (a,a)) : + ∃ B : ℝ,0≤B ∧ ∀ᶠ q:E×E in 𝓝 (a,a), + ‖fderiv ℝ (fderiv ℝ (C q.1)) q.2‖≤B := by + let : NormedAddCommGroup (E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + have hh : ContinuousAt (fun q:E×E => fderiv ℝ (fderiv ℝ (C q.1)) q.2) (a,a) := + (ContDiffAt.partial_snd_fderiv_two hc).continuousAt + let B := ‖fderiv ℝ (fderiv ℝ (C a)) a‖+1 + refine ⟨B,by dsimp [B]; positivity,?_⟩ + have HH := (Metric.tendsto_nhds (β := E×E) + (α := E →L[ℝ] E →L[ℝ] ℝ)).mp hh (1:ℝ) zero_lt_one + filter_upwards [HH] with q hq + have hd : ‖fderiv ℝ (fderiv ℝ (C q.1)) q.2-fderiv ℝ (fderiv ℝ (C a)) a‖<1 := by + simpa only [dist_eq_norm] using hq + have hn := norm_le_norm_sub_add (fderiv ℝ (fderiv ℝ (C q.1)) q.2) + (fderiv ℝ (fderiv ℝ (C a)) a) + dsimp only [B] + linarith only [hd,hn] + +lemma smooth_kernel_local_data {C : E → E → ℝ} {a:E} + (hc : ContDiffAt ℝ ∞ (Function.uncurry C) (a,a)) : + ∃ K : ℝ≥0, ∃ B : ℝ,0≤B ∧ ∃ r>0, + (∀ y∈ball a r,∀ z∈ball a r,ContDiffAt ℝ 2 (C y) z) ∧ + (∀ y∈ball a r,∀ z∈ball a r,‖fderiv ℝ (fderiv ℝ (C y)) z‖≤B) ∧ + LipschitzOnWith K (fun q : E×E => fderiv ℝ (C q.1) q.2) + (ball a r×ˢball a r) := by + have hd := ContDiffAt.partial_snd_fderiv hc + obtain ⟨K,U,hU,hK⟩ := (hd.of_le (by norm_num : (1:WithTop ℕ∞)≤∞)).exists_lipschitzOnWith + obtain ⟨B,hB,hH⟩ := smooth_kernel_second_locally_bounded hc + have hs : ∀ᶠ q:E×E in 𝓝 (a,a),ContDiffAt ℝ 2 (C q.1) q.2 := by + filter_upwards [(hc.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp)] with q hq + exact hq.comp (f := fun z:E => (q.1,z)) q.2 (contDiffAt_const.prodMk contDiffAt_id) + obtain ⟨r,hr,hrU⟩ := Metric.mem_nhds_iff.mp (inter_mem hU (hH.and hs)) + have H (y z:E) (hy:y∈ball a r) (hz:z∈ball a r) := + hrU (show (y,z)∈ball (a,a) r from by rw [←ball_prod_same]; exact ⟨hy,hz⟩) + refine ⟨K,B,hB,r,hr,?_,?_,?_⟩ + · exact fun y hy z hz => (H y z hy hz).2.2 + · exact fun y hy z hz => (H y z hy hz).2.1 + · exact hK.mono (fun q hq => (H q.1 q.2 hq.1 hq.2).1) + +lemma smooth_kernel_local_bounds {C : E → E → ℝ} {a:E} + (hc : ContDiffAt ℝ ∞ (Function.uncurry C) (a,a)) : + ∃ K B : ℝ,0≤K ∧ 0≤B ∧ ∃ r>0, + (∀ y∈ball a r,∀ z∈ball a r,ContDiffAt ℝ 2 (C y) z) ∧ + (∀ y∈ball a r,∀ z∈ball a r,∀ z'∈ball a r, + |C y z'-C y z-fderiv ℝ (C y) z (z'-z)|≤B*‖z'-z‖^2) ∧ + (∀ y∈ball a r,∀ y'∈ball a r,∀ z∈ball a r,∀ z'∈ball a r, + |C y' z'-C y' z-C y z'+C y z|≤K*‖y'-y‖*‖z'-z‖) := by + obtain ⟨K,B,hB,r,hr,hs,hH,hK⟩ := smooth_kernel_local_data hc + refine ⟨K,B,K.coe_nonneg,hB,r,hr,hs,?_,?_⟩ + · intro y hy z hz z' hz' + exact first_order_remainder_le_of_hessian_bound (f := C y) (convex_ball a r) hB + (hs y hy) (hH y hy) hz hz' + · exact kernel_rectangle_of_partial_lipschitz (convex_ball a r) + (fun y hy z hz => (hs y hy z hz).differentiableAt (by norm_num)) hK +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/LiftedSections.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/LiftedSections.lean new file mode 100644 index 0000000000000000000000000000000000000000..e6ba7475199d4dfb9debd8f30f6506512184fb2d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/LiftedSections.lean @@ -0,0 +1,83 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.DoubleMountain + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] + [ChartedSpace (Model n) M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + +def liftedGapSection (u v : M → ℝ) (x : M) (r : ℝ) : + Set (TangentSpace 𝓘(ℝ,Model n) x) := + {p | p∈minimizingVectors x ∧ u x+‖p‖^2/2+v (riemannianExp x p)≤r} + +lemma cost_minimizingVector {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈minimizingVectors x) : cost x (riemannianExp x p)=‖p‖^2/2 := by + unfold cost + rw [show dist x (riemannianExp x p)=‖p‖ from hp] + +lemma mem_liftedGapSection_iff {u v : M → ℝ} {x : M} {r : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} : + p∈liftedGapSection u v x r ↔ p∈minimizingVectors x ∧ riemannianExp x p∈gapSection u v x r := by + constructor + · intro hp + exact ⟨hp.1,by simpa only [gapSection,mem_ofPred_eq,contactGap,cost_minimizingVector hp.1] using hp.2⟩ + · intro hp + exact ⟨hp.1,by simpa only [gapSection,mem_ofPred_eq,contactGap,cost_minimizingVector hp.1] using hp.2⟩ + +variable [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma liftedGapSection_image (u v : M → ℝ) (x : M) (r : ℝ) : + riemannianExp x '' liftedGapSection (n := n) u v x r=gapSection u v x r := by + apply Subset.antisymm + · rintro y ⟨p,hp,rfl⟩ + exact (mem_liftedGapSection_iff.mp hp).2 + · intro y hy + obtain ⟨p,hp,hpy⟩ := exists_minimizing_vector (n := n) x y + exact ⟨p,mem_liftedGapSection_iff.mpr ⟨hp,by rwa [hpy]⟩,hpy⟩ + +variable [Nonempty M] + +lemma WeakMTW.convex_liftedGapSection (hmtw : WeakMTW (n := n) (M := M)) + {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) (huv : IsCostDualPair u v) + (x : M) (r : ℝ) : Convex ℝ (liftedGapSection (n := n) u v x r) := by + intro p hp q hq a b ha hb hab + have hp' := mem_liftedGapSection_iff.mp hp + have hq' := mem_liftedGapSection_iff.mp hq + obtain ⟨hm,hcomp⟩ := hmtw.double_mountain hp.1 hq.1 ha hb hab + rw [mem_liftedGapSection_iff] + refine ⟨hm,?_⟩ + change u x+cost x (riemannianExp x (a • p+b • q))+v (riemannianExp x (a • p+b • q))≤r + have HB : cTransform u (riemannianExp x (a • p+b • q))≤ + r-u x-cost x (riemannianExp x (a • p+b • q)) := by + rw [cTransform_le_iff hu] + intro z + rw [cost_symm (riemannianExp x (a • p+b • q)) z] + have hcp := dualPair_gap_nonneg hv huv z (riemannianExp x p) + have hcq := dualPair_gap_nonneg hv huv z (riemannianExp x q) + have hpS : u x+cost x (riemannianExp x p)+v (riemannianExp x p)≤r := hp'.2 + have hqS : u x+cost x (riemannianExp x q)+v (riemannianExp x q)≤r := hq'.2 + have hpB : cost x (riemannianExp x p)-cost z (riemannianExp x p)≤r-u x+u z := by + dsimp [contactGap] at hcp + linarith [hpS] + have hqB : cost x (riemannianExp x q)-cost z (riemannianExp x q)≤r-u x+u z := by + dsimp [contactGap] at hcq + linarith [hqS] + have hmax := (hcomp z).trans (max_le hpB hqB) + linarith + rw [huv.2] + linarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/LimitGeometry.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/LimitGeometry.lean new file mode 100644 index 0000000000000000000000000000000000000000..1044c3d5c4078eb501def5f79f91374bc368e3d9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/LimitGeometry.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.FirstCutConvex +import OAI.Analysis.BiholderTransport.Geodesics.GraphGlobalMinimal + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter Manifold Bundle +open scoped Topology ContDiff Pointwise + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma continuous_graphProjection_family (u : M → ℝ) : + Continuous (fun q : ℝ × subgradientGraph (n := n) u => graphProjection u q.1 q.2) := + contMDiff_riemannianExp.continuous.comp + (contMDiff_tangentScale.continuous.comp (continuous_fst.prodMk (continuous_subtype_val.comp continuous_snd))) + +lemma graph_global_min_at_left_limit {u : M → ℝ} (hu : Continuous u) + {T : ℝ} (hT : 0 t • z.1.2) := continuous_id.smul continuous_const + apply (isClosed_minimizingVectors z.1.1).mem_of_tendsto + (hcs.continuousAt.tendsto.mono_left (show 𝓝[<] T ≤ 𝓝 T from nhdsWithin_le_nhds)) + exact H.mono (fun _ h => h.1) + · intro a + have hc (b : M) : ContinuousAt (fun t => u b+cost b (graphProjection u t z)/t) T := + continuousAt_const.add (((continuous_cost_right b).continuousAt.comp + ((continuous_graphProjection_family u).continuousAt.comp + (f := fun t : ℝ => (t,z)) (continuousAt_id.prodMk continuousAt_const))).div continuousAt_id hT.ne') + exact le_of_tendsto_of_tendsto (b := 𝓝[<] T) + ((hc z.1.1).tendsto.mono_left nhdsWithin_le_nhds) + ((hc a).tendsto.mono_left nhdsWithin_le_nhds) (H.mono (fun _ h => h.2 a)) + +lemma WeakMTW.active_hull_nonconjugate_of_minimizing + (hmtw : WeakMTW (n := n) (M := M)) {v : M → ℝ} {x : M} + {T : ℝ} (hT : 0 extChartAt 𝓘(ℝ,Model n) + (riemannianExp x (T • p)) (riemannianExp x q)) (T • p)) := by + apply hmtw.convexHull_nonconjugate (S := T • activeLogs (n := n) v x) + · rw [convexHull_smul] + rintro _ ⟨q,hq,rfl⟩ + exact hmin q hq + · rintro _ ⟨q,hq,rfl⟩ + exact riemannianExp_interior_nonconjugate + (contracted_minimizer_mem_injectivityDomain hq.1 hT hT1) + · rw [convexHull_smul] + exact ⟨p,hp,rfl⟩ + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma active_hull_interior_below_minimizing {v : M → ℝ} {x : M} + {T : ℝ} (hT : 0 F q.1 q.2)) + {a : P} (ha : a ∈ closure {p | Function.Bijective (F p)}) (y : Y) : + IsPreconnected {x | F a x = y} := by + have hFa : Continuous (F a) := hF.comp (continuous_const.prodMk continuous_id) + have hs : IsClosed {x | F a x = y} := isClosed_eq hFa continuous_const + apply (isPreconnected_iff_subset_of_fully_disjoint_closed hs).mpr + intro A B hA hB hcover hAB + by_contra hnot + push Not at hnot + obtain ⟨x,hx,hxA⟩ := Set.not_subset.mp hnot.1 + obtain ⟨z,hz,hzB⟩ := Set.not_subset.mp hnot.2 + have hxB : x ∈ B := (hcover hx).resolve_left hxA + have hzA : z ∈ A := (hcover hz).resolve_right hzB + obtain ⟨U,V,hU,hV,hAU,hBV,hUV⟩ := normal_separation hA hB hAB + let K := (U ∪ V)ᶜ + have hK : IsCompact K := (hU.union hV).isClosed_compl.isCompact + have H : ∀ᶠ q : P × Y in 𝓝 (a,y), ∀ b ∈ K, F q.1 b ≠ q.2 := by + apply hK.eventually_forall_of_forall_eventually + intro b hb + have hbne : F a b ≠ y := by + intro he + exact hb ((hcover he).imp (fun h => hAU h) (fun h => hBV h)) + have hf : Continuous (fun q : (P × Y) × X => F q.1.1 q.2) := + hF.comp ((continuous_fst.fst).prodMk continuous_snd) + exact (isOpen_ne_fun hf continuous_fst.snd).mem_nhds hbne + obtain ⟨O,hO,W,hW,hOW⟩ := mem_nhds_prod_iff.mp H + obtain ⟨N,hNW,hN,hyN,hNc⟩ := + (locallyConnectedSpace_iff_subsets_isOpen_isConnected.mp (inferInstance : LocallyConnectedSpace Y)) y W hW + have Hx : ∀ᶠ p in 𝓝 a, F p x ∈ N := by + have hc : ContinuousAt (fun p => F p x) a := + (hF.comp (continuous_id.prodMk continuous_const)).continuousAt + exact hc.preimage_mem_nhds (hx.symm ▸ hN.mem_nhds hyN) + have Hz : ∀ᶠ p in 𝓝 a, F p z ∈ N := by + have hc : ContinuousAt (fun p => F p z) a := + (hF.comp (continuous_id.prodMk continuous_const)).continuousAt + exact hc.preimage_mem_nhds (hz.symm ▸ hN.mem_nhds hyN) + have HO : ∀ᶠ p in 𝓝 a, p ∈ O := hO + obtain ⟨p,hp,hpO,hpx,hpz⟩ := + ((mem_closure_iff_frequently.mp ha).and_eventually (HO.and (Hx.and Hz))).exists + have hpC : Continuous (F p) := hF.comp (continuous_const.prodMk continuous_id) + have hpconn : IsPreconnected (F p ⁻¹' N) := + hNc.isPreconnected.preimage_of_isClosedMap hp.1 hpC.isClosedMap + (fun w _ => hp.2 w) + have hsub : F p ⁻¹' N ⊆ U ∪ V := by + intro b hb + by_contra hn + exact hOW (show (p,F p b) ∈ O ×ˢ W from ⟨hpO,hNW hb⟩) b hn rfl + obtain ⟨b,hb,hbU,hbV⟩ := hpconn U V hU hV hsub + ⟨z,hpz,hAU hzA⟩ ⟨x,hpx,hBV hxB⟩ + exact Set.disjoint_left.mp hUV hbU hbV + +lemma fiber_subsingleton_of_preconnected_isolated + {X : Type*} [TopologicalSpace X] [T1Space X] {s : Set X} + (hs : IsPreconnected s) + (hisol : ∀ x ∈ s, ∃ U, IsOpen U ∧ x ∈ U ∧ U ∩ s ⊆ {x}) : + s.Subsingleton := by + intro x hx y hy + obtain ⟨U,hU,hxU,hUs⟩ := hisol x hx + by_contra hxy + have hcov : s ⊆ U ∪ ({x} : Set X)ᶜ := by + intro z hz + by_cases he : z=x + · exact Or.inl (he.symm ▸ hxU) + · exact Or.inr he + obtain ⟨z,hzs,hzU,hzne⟩ := hs U ({x} : Set X)ᶜ hU isClosed_singleton.isOpen_compl hcov + ⟨x,hx,hxU⟩ ⟨y,hy,Ne.symm hxy⟩ + exact hzne (hUs ⟨hzU,hzs⟩) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/LipschitzSubAeDeriv.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/LipschitzSubAeDeriv.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ff92dd4abf9c26428b647cbd07764994f2d4a15 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/LipschitzSubAeDeriv.lean @@ -0,0 +1,85 @@ +import Mathlib + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter MeasureTheory +open scoped Topology Interval NNReal + +lemma lipschitzOn_sub_le_of_ae_deriv_le {f : ℝ → ℝ} {a b c : ℝ} {K : ℝ≥0} + (hab : a ≤ b) (hf : LipschitzOnWith K f (Icc a b)) + (hd : ∀ᵐ x : ℝ, x∈Icc a b → deriv f x ≤ c) : + f b-f a ≤ c*(b-a) := by + have ha : AbsolutelyContinuousOnInterval f a b := + (by rwa [uIcc_of_le hab] : LipschitzOnWith K f (uIcc a b)).absolutelyContinuousOnInterval + have H := intervalIntegral.integral_mono_ae_restrict hab ha.intervalIntegrable_deriv + (intervalIntegrable_const : IntervalIntegrable (fun _ : ℝ => c) volume a b) + ((ae_restrict_iff' measurableSet_Icc).mpr hd) + rw [ha.integral_deriv_eq_sub,intervalIntegral.integral_const] at H + simpa only [smul_eq_mul,mul_comm] using H + +lemma lipschitzOn_barrier {f : ℝ → ℝ} {a b c : ℝ} {K : ℝ≥0} + (_ : a ≤ b) (hf : LipschitzOnWith K f (Icc a b)) (hfa : f a ≤ c) + (hd : ∀ᵐ x : ℝ, x∈Icc a b → c < f x → deriv f x ≤ 0) : + ∀ x∈Icc a b, f x ≤ c := by + intro x hx + by_contra Hx + have hcx : c < f x := lt_of_not_ge Hx + let S : Set ℝ := {r∈Icc a x | f r ≤ c} + have hxs : Icc a x⊆Icc a b := Icc_subset_Icc_right hx.2 + have hS : IsCompact S := + isCompact_Icc.of_isClosed_subset + (isClosed_Icc.isClosed_le (hf.continuousOn.mono hxs) continuousOn_const) + (fun _ h => h.1) + have haS : a∈S := ⟨⟨le_rfl,hx.1⟩,hfa⟩ + obtain ⟨r,hr,hgreat⟩ := hS.exists_isGreatest ⟨a,haS⟩ + have hrx : r < x := lt_of_le_of_ne hr.1.2 (by intro H; subst r; exact (not_le_of_gt hcx) hr.2) + have hfr : ∀ u∈Icc r x, u≠r → c < f u := by + intro u hu hur + by_contra H + have huS : u∈S := ⟨⟨hr.1.1.trans hu.1,hu.2⟩,le_of_not_gt H⟩ + exact hur (le_antisymm (hgreat huS) hu.1) + have hsub : Icc r x⊆Icc a b := Icc_subset_Icc hr.1.1 hx.2 + have hd' : ∀ᵐ u : ℝ, u∈Icc r x → deriv f u ≤ 0 := by + have hneq : ∀ᵐ u : ℝ, u≠r := by rw [ae_iff]; simp + filter_upwards [hd,hneq] with u hu hur hus + exact hu (hsub hus) (hfr u hus hur) + have H := lipschitzOn_sub_le_of_ae_deriv_le hrx.le (hf.mono hsub) hd' + simp only [zero_mul] at H + linarith only [H,hr.2,hcx] + +end + +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology NNReal ContDiff + +lemma norm_deficit_advance {q N t D : ℝ} (hq : 0 ≤ q) (hN : 0 ≤ N) + (ht : 0 ≤ t) (ht1 : t ≤ 1/2) (hD : 0 ≤ D) + (hgap : q^2 ≤ (1-t)^2*N^2-D) : q*N-(1-t)*N^2 ≤ -D/2 := by + have ha : 0 ≤ (1-t)*N := mul_nonneg (by linarith only [ht1]) hN + have hqA : q ≤ (1-t)*N := (sq_le_sq₀ hq ha).mp (by nlinarith only [hgap,hD]) + have hdiff : 0 ≤ (1-t)*N-q := sub_nonneg.mpr hqA + have hsum : (1-t)*N+q ≤ 2*N := by nlinarith [mul_nonneg ht hN] + have H := mul_nonneg hdiff (sub_nonneg.mpr hsum) + nlinarith only [H,hgap] + +lemma norm_surplus_advance {q N t D : ℝ} (hq : 0 ≤ q) (hN : 0 ≤ N) + (_ : 0 ≤ t) (ht1 : t ≤ 1/2) (hD : 0 ≤ D) + (hgap : q^2 ≤ (1-t)^2*N^2+D) : q*N-(1-t)*N^2 ≤ 2*D := by + by_cases Hq : q ≤ (1-t)*N + · have H := mul_le_mul_of_nonneg_right Hq hN + nlinarith only [H,hD] + · have hdiff : 0 ≤ q-(1-t)*N := (le_of_not_ge Hq).trans (le_refl _)|> sub_nonneg.mpr + have hsum : N/2 ≤ (1-t)*N+q := by nlinarith only [ht1,hN,hq,mul_nonneg (sub_nonneg.mpr ht1) hN] + have H := mul_nonneg hdiff (sub_nonneg.mpr hsum) + nlinarith only [H,hgap] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinSecondDeriv.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinSecondDeriv.lean new file mode 100644 index 0000000000000000000000000000000000000000..edbeeacd40a9bef9ac0afe560e91c7d2b6b81700 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinSecondDeriv.lean @@ -0,0 +1,89 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma localMin_second_deriv_nonneg {f : ℝ → ℝ} {a : ℝ} + (h : IsLocalMin f a) (hc : ContinuousAt f a) : 0 ≤ deriv (deriv f) a := by + by_contra hn + have hm := isLocalMax_of_deriv_deriv_neg (lt_of_not_ge hn) h.deriv_eq_zero hc + have heq : f =ᶠ[𝓝 a] fun _ => f a := by + filter_upwards [h,hm] with x hx hy + exact le_antisymm hy hx + have hh := heq.deriv.deriv_eq + simpa using (not_le_of_gt (lt_of_not_ge hn)) (show 0 ≤ deriv (deriv f) a by simpa using hh.ge) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinStrictGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinStrictGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..6674297efa018edeeb53397a1fe48e34ce3e0af6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/LocalMinStrictGrowth.lean @@ -0,0 +1,233 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport + +lemma exists_local_min_of_strict_growth {X P : Type*} [MetricSpace X] [ProperSpace X] + [TopologicalSpace P] {F : X → P → ℝ} (hF : Continuous (fun q : X×P => F q.1 q.2)) + {x : X} {p : P} (H : ∀ᶠ z in 𝓝 x, z≠x → F x p F w q) z := by + intro O hO + obtain ⟨r,hr,hball⟩ := Metric.mem_nhds_iff.mp (inter_mem hO H) + obtain ⟨s,hs,hsr⟩ := exists_between hr + have Hs : ∀ z∈Metric.sphere x s, F x p TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumJensenFamily.active_subseq + {hmtw:WeakMTW (n:=n) (M:=M)} {v:M → ℝ} {hv:Continuous v} + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + {q:Model n} {β:ℝ} (hb:Tendsto F.b atTop (𝓝 β)) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + (i:ℕ → Fin (Module.finrank ℝ (Model n)+1)) : + ∃σ:ℕ → ℕ,StrictMono σ ∧ + ∃r:Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃m:Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃i₀:Fin (Module.finrank ℝ (Model n)+1), + Tendsto (fun k=>(J.first (σ k)).pj₀) atTop (𝓝 r) ∧ + Tendsto (fun k=>(J.first (σ k)).w₀) atTop (𝓝 m) ∧ + (∀ᶠ k in atTop,i (σ k)=i₀) ∧ + (∀j,(show TangentSpace 𝓘(ℝ,Model n) a from r j)∈ + activeLogs (modifiedDatum v α D β Bo) a) ∧ + (∀j,0 ≤ m j) ∧ ∑j,m j=1 ∧ ∑j,m j • r j=q := by + obtain ⟨hbase,hvel,_,_⟩:=F.limit_coordinates hQ + exact active_configuration_subseq hv ho hb hbase hvel + (fun k=>(extChartAt 𝓘(ℝ,Model n) a).map_source (J.poleSource k)) i + (fun k j=>(J.first k).activeLimit j) (fun k j=>(J.first k).nonnegLimit j) + (fun k=>(J.first k).totalLimit) (fun k=>(J.first k).baryLimit) + +end MaximumActiveCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumActiveLimits.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumActiveLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..288a51e7523b995a4c15b2408bb47bccff428779 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumActiveLimits.lean @@ -0,0 +1,55 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumActiveLimits +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +local instance activeLimitDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance activeLimitDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance activeLimitBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance activeLimitBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma MaximumDiagonal.active_weight_limits {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) + {r:Fin (Module.finrank ℝ (Model n)+1) → Model n} + {m:Fin (Module.finrank ℝ (Model n)+1) → ℝ} + (hr:Tendsto (fun k=>(J.first k).pj₀) atTop (𝓝 r)) + (hm:Tendsto (fun k=>(J.first k).w₀) atTop (𝓝 m)) : + Tendsto (fun k=>(J.first k).pj (S.ν k)) atTop (𝓝 r) ∧ + Tendsto (fun k=>(J.first k).w (S.ν k)) atTop (𝓝 m) := by + exact ⟨diagonal_tendsto_of_close hr hε (Eventually.of_forall (fun k=>(S.activeClose k).le)), + diagonal_tendsto_of_close hm hε (Eventually.of_forall (fun k=>(S.weightClose k).le))⟩ + +lemma MaximumDiagonal.sample_pole_limit {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {L:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hL:Tendsto (fun k=>(J.first k).L) atTop (𝓝 L)) : + Tendsto (fun k=>J.sampleL k (S.ν k)) atTop (𝓝 L) := by + apply diagonal_tendsto_of_close hL hε + exact Eventually.of_forall (fun k=>by simpa only [dist_eq_norm] using (S.LClose k).le) + +end MaximumActiveLimits +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..5e8a9295a12b3a03fd8ab24193da89b892373cb9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterCompact.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterUpper +import OAI.Analysis.BiholderTransport.Regularity.MovingCenterLower + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumCenterCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +local instance maximumDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance maximumBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma MaximumDiagonal.sample_center_lower {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {C:ℝ} + (hH:∀ᶠ k in atTop,∀d,-C*‖d‖^2 ≤ (J.first k).H d d) : + ∀ᶠ k in atTop,∀d,-(C+1)*‖d‖^2 ≤ J.sampleH k (S.ν k) d d := by + filter_upwards [hH,hε.eventually (gt_mem_nhds zero_lt_one)] with k hk hεk + intro d + have hn : ‖(J.first k).H-J.sampleH k (S.ν k)‖ ≤ 1 := by + rw [norm_sub_rev] + exact (S.HClose k).le.trans hεk.le + have hclose:=bilinear_quadratic_close hn d + nlinarith only [hclose,hk d] + +lemma MaximumDiagonal.center_lower {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {C:ℝ} (hC:0 ≤ C) (hH:∀ᶠ k in atTop,∀d,-C*‖d‖^2 ≤ (J.first k).H d d) : + ∃K≥0,∀ᶠ k in atTop,∀d,-K*‖d‖^2 ≤ + fderiv ℝ (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))) d d := by + obtain ⟨hb,hp,hx,hg⟩:=S.limits J hε hQ he + have hz:=S.endpoint_tendsto he hb hp + obtain ⟨K,hK,HK⟩:=S.center_gradient_bound hg hz + have hn:∀ᶠ k in atTop,∀ᶠ z in 𝓝 ((J.sample k).z (J.sampleIndex k (S.ν k))), + DifferentiableAt ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) z := by + apply Eventually.of_forall + intro k + filter_upwards [(J.sample k).openRegion.mem_nhds ((J.sample k).sampleInRegion (J.sampleIndex k (S.ν k)))] with z hz + exact (J.sample k).centerDifferentiable z hz + have hd:∀ᶠ k in atTop,DifferentiableAt ℝ + (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))) := + Eventually.of_forall (fun k=>((J.sample k).samples (J.sampleIndex k (S.ν k))).2.2.2.2.2.2.2.2.1) + have HB:=S.sample_center_lower hε hH + have H:=moving_center_sequential_lower hq he hb hp F.time + (Gj := fun k=>hopfLax (1-F.t k) (modifiedDatum v α D (F.b k) Bc)) + (by simpa only [S.movingChart] using hn) (by simpa only [S.movingChart] using hd) + hK (show 0 ≤ C+1 by linarith) (by simpa only [S.movingChart] using HK) HB + simpa only [S.movingChart] using H + +lemma MaximumDiagonal.center_compact {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {C U:ℝ} (hC:0 ≤ C) (hD:0 ≤ U) + (hH:∀ᶠ k in atTop,∀d,-C*‖d‖^2 ≤ (J.first k).H d d) + (hL:∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ U*‖d‖^2) : + ∃B:Model n →L[ℝ] Model n →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ + Tendsto (fun i=>fderiv ℝ + (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b (σ i)) Bc) (F.t (σ i)) c)) + ((J.sample (σ i)).z (J.sampleIndex (σ i) (S.ν (σ i))))) atTop (𝓝 B) := by + obtain ⟨K,hK,HK⟩:=S.center_lower hε hq he hQ hC hH + obtain ⟨L,hL',HL⟩:=S.center_upper hε hq he hQ hD hL + change ∃ B σ, StrictMono σ ∧ Tendsto ((fun k => fderiv ℝ + (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) ∘ σ) atTop (𝓝 B) + apply exists_bilinear_limit (C := K+L) + filter_upwards [HK,HL] with i hi hl + apply symmetric_bilinear_norm_of_two_bounds (C := K) (D := L) _ hK hL' hi hl + apply rough_hessian_symmetric + · filter_upwards [(J.sample i).openRegion.mem_nhds + ((J.sample i).sampleInRegion (J.sampleIndex i (S.ν i)))] with z hz + exact (J.sample i).centerDifferentiable z hz + · exact ((J.sample i).samples (J.sampleIndex i (S.ν i))).2.2.2.2.2.2.2.2.1 + +end MaximumCenterCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..cb48937cadb1ac73b3d76317e625c233dad6e514 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLimit.lean @@ -0,0 +1,107 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartTrueMatrix +import OAI.Analysis.BiholderTransport.Convexity.MovingCenterSemibound +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal +import OAI.Analysis.BiholderTransport.Regularity.MaximumEndpoint +import OAI.Analysis.BiholderTransport.LinearAlgebra.MovingFamilyHessian + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumCenterLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumDiagonal.center_matrix_limit {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {g:Model n →L[ℝ] ℝ} {B:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hg:Tendsto (fun k=>fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 g)) + (hB:Tendsto (fun k=>fderiv ℝ (fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 B)) : + Tendsto (fun k=>J.sampleH k (S.ν k)) atTop + (𝓝 (chartJetMatrix a c (extChartAt 𝓘(ℝ,Model n) a a) q g B)) := by + obtain ⟨hb,hp,_,_⟩:=S.limits J hε hQ he + have hb0:=mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a + have hc0:movingPrefix a 1 (extChartAt 𝓘(ℝ,Model n) a a) q∈ + (extChartAt 𝓘(ℝ,Model n) c).source:=by + rw [movingPrefix_at_center,one_smul,he] + exact mem_extChartAt_source c + have hn:∀ᶠ k in atTop,(∀ᶠ z in 𝓝 ((J.sample k).z (J.sampleIndex k (S.ν k))), + DifferentiableAt ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) z) ∧ + DifferentiableAt ℝ (fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))):=by + apply Eventually.of_forall + intro k + refine ⟨?_,((J.sample k).samples (J.sampleIndex k (S.ν k))).2.2.2.2.2.2.2.2.1⟩ + filter_upwards [(J.sample k).openRegion.mem_nhds + ((J.sample k).sampleInRegion (J.sampleIndex k (S.ν k)))] with z hz + exact (J.sample k).centerDifferentiable z hz + have HC:=moving_family_rough_hessian_limit + (f:=fun k=>chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + (g:=fun z:ℝ×Model n=>movingPrefixChart a c z.1 z.2) + (joint_movingPrefixChart_contDiffAt hb0 hc0) (F.time.prodMk_nhds hb) hp + (by simpa only [S.movingChart] using hg) (by simpa only [S.movingChart] using hB) + (by simpa only [S.movingChart] using hn) + have HE:=moving_energy_hessian_tendsto hq hb hp F.time + have heq:fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 (extChartAt 𝓘(ℝ,Model n) a a))) q= + frameMetric a (extChartAt 𝓘(ℝ,Model n) a a):=by + ext d e + rw [movingPrefixEnergy_hessian_at_center hq,frameMetric_center] + rw [heq] at HE + have HT:=HE.add HC + apply HT.congr' + apply Eventually.of_forall + intro k + have hc:movingPrefix a (F.t k) (graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) + (graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1)∈ + (extChartAt 𝓘(ℝ,Model n) c).source:=by + rw [movingPrefix_graph_coordinates (S.poleSource k)] + exact S.endpointSource k + exact (coordinateCenterMatrix_chart + ((extChartAt 𝓘(ℝ,Model n) a).map_source (S.poleSource k)) hc).symm + +lemma MaximumDiagonal.center_matrix_le_pole_limit {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) + {H L:Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hH:Tendsto (fun k=>J.sampleH k (S.ν k)) atTop (𝓝 H)) + (hL:Tendsto (fun k=>(J.first k).L) atTop (𝓝 L)) (d:Model n) : H d d ≤ L d d := by + have hhh:Tendsto (fun k=>J.sampleH k (S.ν k) d d) atTop (𝓝 (H d d)):=tendsto_clm_apply (tendsto_clm_apply hH tendsto_const_nhds) tendsto_const_nhds + have hll:Tendsto (fun k=>(J.first k).L d d) atTop (𝓝 (L d d)):=tendsto_clm_apply (tendsto_clm_apply hL tendsto_const_nhds) tendsto_const_nhds + have HE:=hε.mul_const (‖d‖^2) + have HI:∀ᶠ k in atTop,J.sampleH k (S.ν k) d d ≤ (J.first k).L d d+ε k*‖d‖^2:=by + apply Eventually.of_forall + intro k + exact (bilinear_quadratic_close (S.HClose k).le d).trans + (add_le_add ((J.first k).upper d) le_rfl) + simpa only [zero_mul,add_zero] using le_of_tendsto_of_tendsto hhh (hll.add HE) HI +end MaximumCenterLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLower.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLower.lean new file mode 100644 index 0000000000000000000000000000000000000000..84a80cc2ceb4e41b0920c5e6f0e2021d5632260d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterLower.lean @@ -0,0 +1,96 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterSequence + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumCenterLower +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_maximum_center_gain : + ∃ c0>0,∀ᶠ l:ℝ in 𝓝 1,0modifiedScalar α D Bc (b,s))) → + ∀ L:ℝ≥0,(∀ b∈Icc bminus bplus,LipschitzWith L (modifiedDatum v α D b Bc)) → + ∀ (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) (a c:M) (N:Set (Model n)), + ∀ J : MaximumJensenFamily hmtw hv.continuous ho F a c N, + ∀ (q:Model n) (β:ℝ), + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a → + riemannianExp a q=c → + Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto F.b atTop (𝓝 β) → + deriv (fun s=>modifiedScalar α D Bc (β,s)) (v c)=l → + ∀ ε:ℝ,0<ε → ∀ᶠ k in atTop,∀ d:Model n, + c0*(1-l)*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + (iteratedDeriv 2 (fun s=>modifiedScalar α D Bc (β,s)) (v c)/l^2)* + (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2 - ε*‖d‖^2 ≤ + (J.first k).H d d := by + obtain ⟨c0,hc0,H⟩ := exists_actual_center_gain (n := n) (M := M) + refine ⟨c0,hc0,?_⟩ + filter_upwards [H] with l hgain + intro hl hl1 hmtw u v hu Lv hv hdual α D bminus bplus Bc Bo ho hBc hmono L hLip + F a c N J q β hq he hQ hβ hder ε hε + let θ := fun k:ℕ=>1/((k:ℝ)+1) + have hθpos (k:ℕ) : 0<θ k := by dsimp [θ]; positivity + have hθ : Tendsto θ atTop (𝓝 0) := tendsto_one_div_add_atTop_nhds_zero_nat + obtain ⟨S⟩ := J.exists_diagonal hθpos (P := fun _ _=>True) (fun _=>Eventually.of_forall (fun _=>True.intro)) + obtain ⟨hb,hp,hx,hg⟩ := S.limits J hθ hQ he + have hlj := S.slope_tendsto hBc hβ hx + rw [hder] at hlj + obtain ⟨K,hK⟩ := eventually_atTop.mp (hlj.eventually (Ioo_mem_nhds hl hl1)) + let σ := fun i:ℕ=>i+K + have hσ : Tendsto σ atTop atTop := tendsto_add_atTop_nat K + let S1 := S.comp σ hσ + have hls (i:ℕ) : 0<(J.comp σ hσ).sampleSlope i (S1.ν i) ∧ + (J.comp σ hσ).sampleSlope i (S1.ν i)<1 := hK (i+K) (Nat.le_add_left _ _) + let CD := S1.center_sequence hu hv hdual hBc hmono hls (hg.comp hσ) + have hτ : Tendsto (fun k=>1-F.t k) atTop (𝓝 (0:ℝ)) := by + simpa only [sub_self] using (tendsto_const_nhds.sub F.time : + Tendsto (fun k=>(1:ℝ)-F.t k) atTop (𝓝 (1-1))) + have HG := hgain hl hl1 a c u v (modifiedScalar α D Bc) β hv.continuous + (modifiedScalar_contDiff hBc α D).contDiffAt hder + (F.b ∘ σ) (fun i=>J.sampleSlope (σ i) (S.ν (σ i))) (fun i=>1-F.t (σ i)) + (F.t ∘ σ) (fun i=>J.sampleCenter (σ i) (S.ν (σ i))) + (fun i=>graphBaseCoordinate a (J.samplePoint (σ i) (S.ν (σ i))).1) + (fun i=>graphVelocityCoordinate a (J.samplePoint (σ i) (S.ν (σ i))).1) + (fun i=>graphProjection (cTransform (modifiedDatum v α D (F.b (σ i)) Bo)) (F.t (σ i)) + (J.samplePoint (σ i) (S.ν (σ i)))) + (fun i=>chartOuterEnvelope (modifiedDatum v α D (F.b (σ i)) Bo) (F.t (σ i)) c) + CD q hq he (hβ.comp hσ) (hlj.comp hσ) (hτ.comp hσ) (F.time.comp hσ) + (hx.comp hσ) (hb.comp hσ) (hp.comp hσ) + (Eventually.of_forall (fun i=>by linarith [(F.prefixTime (σ i)).2])) L + (Eventually.of_forall (fun i=>hLip _ (Ioo_subset_Icc_self (F.parameter (σ i))))) + (ε/2) (half_pos hε) + rw [←map_add_atTop_eq_nat K] + change ∀ᶠ i in atTop,∀ d:Model n,_≤(J.first (i+K)).H d d + filter_upwards [HG,(hθ.comp hσ).eventually (gt_mem_nhds (half_pos hε))] with i hi hθi + intro d + have Hclose := bilinear_quadratic_close ((S.HClose (σ i)).le.trans hθi.le) d + have HH := hi d + change _≤J.sampleH (σ i) (S.ν (σ i)) d d at HH + nlinarith only [Hclose,HH] + +end MaximumCenterLower +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterRegular.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterRegular.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d777b8b4a74fe646094294c5c008c4cabfecebd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterRegular.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CenterRegularCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterSequence + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumCenterRegular +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +lemma MaximumJensenFamily.center_regular + {u v : M → ℝ} (hu : Continuous u) {Lv : ℝ≥0} (hv : LipschitzWith Lv v) + (hdual : IsCostDualPair u v) + {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} {ho : Continuous Bo} + (hBc : ContDiff ℝ ∞ Bc) + (hmono : ∀ b∈Icc bminus bplus,Monotone (fun s=>modifiedScalar α D Bc (b,s))) + (L : ℝ≥0) (hLip : ∀ b∈Icc bminus bplus,LipschitzWith L (modifiedDatum v α D b Bc)) + {hmtw : WeakMTW (n := n) (M := M)} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c:M} {N:Set (Model n)} + (J : MaximumJensenFamily hmtw hv.continuous ho F a c N) + {q:Model n} {β l:ℝ} + (hq : (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a) + (he : riemannianExp a q=c) + (hQ : Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + (hβ : Tendsto F.b atTop (𝓝 β)) + (hder : deriv (fun s=>modifiedScalar α D Bc (β,s)) (v c)=l) + (hl:01/((k:ℝ)+1) + have hθpos (k:ℕ) : 0<θ k := by dsimp [θ]; positivity + have hθ : Tendsto θ atTop (𝓝 0) := tendsto_one_div_add_atTop_nhds_zero_nat + obtain ⟨S⟩ := J.exists_diagonal hθpos (P := fun _ _=>True) (fun _=>Eventually.of_forall (fun _=>True.intro)) + obtain ⟨hb,hp,hx,hg⟩ := S.limits J hθ hQ he + have hlj := S.slope_tendsto hBc hβ hx + rw [hder] at hlj + obtain ⟨K,hK⟩ := eventually_atTop.mp (hlj.eventually (Ioo_mem_nhds hl hl1)) + let σ := fun i:ℕ=>i+K + have hσ : Tendsto σ atTop atTop := tendsto_add_atTop_nat K + let S1 := S.comp σ hσ + have hls (i:ℕ) : 0<(J.comp σ hσ).sampleSlope i (S1.ν i) ∧ + (J.comp σ hσ).sampleSlope i (S1.ν i)<1 := hK (i+K) (Nat.le_add_left _ _) + let CD := S1.center_sequence hu hv hdual hBc hmono hls (hg.comp hσ) + have hτ : Tendsto (fun k=>1-F.t k) atTop (𝓝 (0:ℝ)) := by + simpa only [sub_self] using (tendsto_const_nhds.sub F.time : + Tendsto (fun k=>(1:ℝ)-F.t k) atTop (𝓝 (1-1))) + exact CD.regular_compact hv.continuous (modifiedScalar_contDiff hBc α D).contDiffAt + hder hl hl1 hq he (hβ.comp hσ) (hlj.comp hσ) (hτ.comp hσ) + (F.time.comp hσ) (hx.comp hσ) (hb.comp hσ) + (Eventually.of_forall (fun i=>by change 0 < 1-F.t (σ i); linarith [(F.prefixTime (σ i)).2])) L + (Eventually.of_forall (fun i=>hLip _ (Ioo_subset_Icc_self (F.parameter (σ i))))) + +end MaximumCenterRegular +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSequence.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..31633e246b9e42b7abfdd8cb9961b9bc267aff72 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSequence.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamily +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal +import OAI.Analysis.BiholderTransport.Regularity.MaximumReindex +import OAI.Analysis.BiholderTransport.Convexity.JensenAtCenter +import OAI.Analysis.BiholderTransport.Regularity.SampleCenterFamilies + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumCenterSequence +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +def MaximumJensenFamily.sampleSlope (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : ℝ := + deriv (fun s=>modifiedScalar α D Bc (F.b k,s)) + (v ((J.sample k).Y ((J.sample k).z (J.sampleIndex k j)))) + +lemma MaximumDiagonal.center_tendsto {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) + (hx : Tendsto (fun k=>J.sampleCenter k (S.ν k)) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) : + Tendsto (fun k=>(J.sample k).Y ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 c) := by + let χ := extChartAt 𝓘(ℝ,Model n) c + have H := (continuousAt_extChartAt_symm'' (χ.map_source (mem_extChartAt_source c))).tendsto.comp hx + rw [χ.left_inv (mem_extChartAt_source c)] at H + apply H.congr + intro k + exact χ.left_inv ((J.sample k).samples (J.sampleIndex k (S.ν k))).1 + +lemma MaximumDiagonal.slope_tendsto {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) + (hBc : ContDiff ℝ ∞ Bc) {β : ℝ} (hβ : Tendsto F.b atTop (𝓝 β)) + (hx : Tendsto (fun k=>J.sampleCenter k (S.ν k)) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) : + Tendsto (fun k=>J.sampleSlope k (S.ν k)) atTop + (𝓝 (deriv (fun s=>modifiedScalar α D Bc (β,s)) (v c))) := by + exact ((continuous_scalar_family_deriv (modifiedScalar_contDiff hBc α D)).tendsto (β,v c)).comp + (hβ.prodMk_nhds ((hv.tendsto c).comp (S.center_tendsto hx))) + +def MaximumDiagonal.center_sequence {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) + {u : M → ℝ} (hu : Continuous u) {Lv : ℝ≥0} (hLv : LipschitzWith Lv v) + (hdual : IsCostDualPair u v) (hBc : ContDiff ℝ ∞ Bc) + (hmono : ∀ b∈Icc bminus bplus,Monotone (fun s=>modifiedScalar α D Bc (b,s))) + (hl : ∀ k,0J.sampleGradient k (S.ν k)) atTop (𝓝 0)) : + CenterSequenceData a c u v (modifiedScalar α D Bc) F.b + (fun k=>J.sampleSlope k (S.ν k)) (fun k=>1-F.t k) F.t + (fun k=>J.sampleCenter k (S.ν k)) + (fun k=>graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) + (fun k=>graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1) + (fun k=>graphProjection (cTransform (modifiedDatum v α D (F.b k) Bo)) (F.t k) + (J.samplePoint k (S.ν k))) + (fun k=>chartOuterEnvelope (modifiedDatum v α D (F.b k) Bo) (F.t k) c) := by + have R (k:ℕ) : Nonempty (TrueCenterRow c u v + (fun s=>modifiedScalar α D Bc (F.b k,s)) (J.sampleCenter k (S.ν k)) + (graphProjection (cTransform (modifiedDatum v α D (F.b k) Bo)) (F.t k) + (J.samplePoint k (S.ν k))) (1-F.t k) (J.sampleSlope k (S.ν k))) := by + rw [J.sampleProjection] + exact hmtw.jensen_at_center_row hu hLv hdual + ((modifiedScalar_contDiff hBc α D).continuous.comp (continuous_const.prodMk continuous_id)) + (hmono (F.b k) (Ioo_subset_Icc_self (F.parameter k))) + (F.prefixTime k).1 (F.prefixTime k).2 (J.sample k) (J.sampleIndex k (S.ν k)) + (scalar_family_derivable (modifiedScalar_contDiff hBc α D) + (F.b k,v ((J.sample k).Y ((J.sample k).z (J.sampleIndex k (S.ν k)))))) (hl k).1 (hl k).2 + apply hmtw.center_sequence_of_graph + (fun k=>continuous_modifiedDatum hv α D (F.b k) ho) + (fun k=>(F.prefixTime k).1) (fun k=>(F.prefixTime k).2) + (fun k=>J.samplePoint k (S.ν k)) S.poleSource S.endpointSource + (fun k=>Classical.choice (R k)) + · apply Eventually.of_forall + intro k + rw [S.endpointChart] + obtain ⟨_,_,_,_,_,_,_,_,hC,_,_⟩ := (J.sample k).samples (J.sampleIndex k (S.ν k)) + refine ⟨?_,hC⟩ + filter_upwards [(J.sample k).openRegion.mem_nhds ((J.sample k).sampleInRegion + (J.sampleIndex k (S.ν k)))] with z hz + exact (J.sample k).centerDifferentiable z hz + · convert hg using 1 + ext k + rw [S.endpointChart] + rfl + +end MaximumCenterSequence +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSign.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSign.lean new file mode 100644 index 0000000000000000000000000000000000000000..bc317eb1de551d84262175c5b9604ea632a9c70b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterSign.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily +import OAI.Analysis.BiholderTransport.Coordinates.ChartParameter + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumCenterSign +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumJensenFamily.center_parameter_bound + {hmtw:WeakMTW (n:=n) (M:=M)} {v:M → ℝ} {hv:Continuous v} + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + (hm:0 ≤ bminus) (hp:0 < bplus) (hb:∀s,0 ≤ Bo s) (k:ℕ) : + (1:ℝ)/4096 ≤ Bc ((v (riemannianExp (F.row k).q.1.1 (F.row k).q.1.2)-α)/D) := by + have H:=(F.row k).chart_first_limit_parameter (J.poleSource k) (J.first k) + dsimp only at H + have hs:0 ≤ ∑i,(J.first k).w₀ i*Bo ((v (movingNormal a + (graphBaseCoordinate a (F.row k).q.1,(J.first k).pj₀ i))-α)/D) := by + apply Finset.sum_nonneg + intro i _ + exact mul_nonneg ((J.first k).nonnegLimit i) (hb _) + have hp':0 ≤ 4*F.b k/bplus:=div_nonneg (mul_nonneg (by norm_num) + (hm.trans (F.parameter k).1.le)) hp.le + have hbt:graphBaseCoordinate a (F.row k).q.1∈(extChartAt 𝓘(ℝ,Model n) a).target:= + (extChartAt 𝓘(ℝ,Model n) a).map_source (J.poleSource k) + have heq:movingNormal a (graphBaseCoordinate a (F.row k).q.1, + graphVelocityCoordinate a (F.row k).q.1)=riemannianExp (F.row k).q.1.1 (F.row k).q.1.2 := by + rw [movingNormal_eq hbt] + exact congrArg (fun z:TangentBundle 𝓘(ℝ,Model n) M=>riemannianExp z.1 z.2) + (graph_coordinate_reconstruction (J.poleSource k)) + rw [heq] at H + linarith only [H,hs,hp'] + +lemma MaximumJensenFamily.center_limit_positive + {hmtw:WeakMTW (n:=n) (M:=M)} {v:M → ℝ} {hv:Continuous v} + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + (hm:0 ≤ bminus) (hp:0 < bplus) (hb:∀s,0 ≤ Bo s) (hc:Continuous Bc) + {q:Model n} (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) : + (1:ℝ)/4096 ≤ Bc ((v c-α)/D) := by + have H:=(F.limit_coordinates hQ).2.2.2 + rw [he] at H + exact ge_of_tendsto (hc.continuousAt.tendsto.comp + (((hv.continuousAt.tendsto.comp H).sub_const α).div_const D)) + (Eventually.of_forall (J.center_parameter_bound hm hp hb)) + +end MaximumCenterSign +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterUpper.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..b37b1a4e1f64fac7706c695f9e08047d9db04a87 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCenterUpper.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearClose +import OAI.Analysis.BiholderTransport.Regularity.MaximumEndpoint +import OAI.Analysis.BiholderTransport.Regularity.MovingCenterUpper +import OAI.Analysis.BiholderTransport.Calculus.HopfGradientBound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumCenterUpper +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumDiagonal.sample_center_upper {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {C:ℝ} + (hL:∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ C*‖d‖^2) : + ∀ᶠ k in atTop,∀d,J.sampleH k (S.ν k) d d ≤ (C+1)*‖d‖^2 := by + filter_upwards [hL,hε.eventually (gt_mem_nhds zero_lt_one)] with k hk hεk + intro d + calc + _ ≤ (J.first k).H d d+1*‖d‖^2 := bilinear_quadratic_close ((S.HClose k).le.trans hεk.le) d + _ ≤ (J.first k).L d d+1*‖d‖^2 := by linarith only [(J.first k).upper d] + _ ≤ C*‖d‖^2+1*‖d‖^2 := by linarith only [hk d] + _ = _ := by ring + +lemma MaximumDiagonal.center_gradient_bound {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hg:Tendsto (fun k=>J.sampleGradient k (S.ν k)) atTop (𝓝 0)) + (hz:Tendsto (fun k=>(J.sample k).z (J.sampleIndex k (S.ν k))) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) : + ∃K≥0,∀ᶠ k in atTop, + ‖fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + ((J.sample k).z (J.sampleIndex k (S.ν k)))‖ ≤ K := by + obtain ⟨K,hK,HK⟩:=exists_chart_hopf_gradient_bound (n := n) c + have hgg:∀ᶠ k in atTop,‖J.sampleGradient k (S.ν k)‖<1 := by + simpa only [norm_zero,Function.comp_def] using ((continuous_norm.tendsto (0:Model n →L[ℝ] ℝ)).comp hg).eventually + (gt_mem_nhds (by simp : ‖(0:Model n →L[ℝ] ℝ)‖<1)) + refine ⟨1+K,by linarith,?_⟩ + filter_upwards [hz.eventually HK,F.time.eventually (lt_mem_nhds (by norm_num : (1/2:ℝ)<1)),hgg] + with k hk htk hgk + have houter:=hk (F.t k) htk.le (cTransform (modifiedDatum v α D (F.b k) Bo)) + (continuous_cTransform (continuous_modifiedDatum hv α D (F.b k) ho)) + let x:=(J.sample k).z (J.sampleIndex k (S.ν k)) + have he:fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) x= + J.sampleGradient k (S.ν k)- + fderiv ℝ (chartOuterEnvelope (modifiedDatum v α D (F.b k) Bo) (F.t k) c) x := by + dsimp only [MaximumJensenFamily.sampleGradient,x] + abel + rw [he] + exact (norm_sub_le _ _).trans (add_le_add hgk.le houter) + +lemma MaximumDiagonal.center_upper {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {C:ℝ} (hC:0 ≤ C) (hL:∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ C*‖d‖^2) : + ∃K≥0,∀ᶠ k in atTop,∀d, + fderiv ℝ (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))) d d ≤ K*‖d‖^2 := by + obtain ⟨hb,hp,hx,hg⟩:=S.limits J hε hQ he + have hz:=S.endpoint_tendsto he hb hp + obtain ⟨K,hK,HK⟩:=S.center_gradient_bound hg hz + have hn:∀ᶠ k in atTop,∀ᶠ z in 𝓝 ((J.sample k).z (J.sampleIndex k (S.ν k))), + DifferentiableAt ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) z := by + apply Eventually.of_forall + intro k + filter_upwards [(J.sample k).openRegion.mem_nhds ((J.sample k).sampleInRegion (J.sampleIndex k (S.ν k)))] with z hz + exact (J.sample k).centerDifferentiable z hz + have hd:∀ᶠ k in atTop,DifferentiableAt ℝ + (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))) := + Eventually.of_forall (fun k=>((J.sample k).samples (J.sampleIndex k (S.ν k))).2.2.2.2.2.2.2.2.1) + have HB:=S.sample_center_upper hε hL + have H:=moving_center_sequential_upper hq he hb hp F.time + (Gj := fun k=>hopfLax (1-F.t k) (modifiedDatum v α D (F.b k) Bc)) + (by simpa only [S.movingChart] using hn) (by simpa only [S.movingChart] using hd) + hK (show 0 ≤ C+1 by linarith) (by simpa only [S.movingChart] using HK) HB + simpa only [S.movingChart] using H + +end MaximumCenterUpper +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..b062d66ad88884e6a59af55534cc952ffafb5f8f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumCompact.lean @@ -0,0 +1,85 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.GraphCoordinates +import OAI.Analysis.BiholderTransport.Regularity.MaximumFamily + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def MaximumFamily.comp {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) + (σ : ℕ → ℕ) (hσ : Tendsto σ atTop atTop) : + MaximumFamily (n := n) v α D bminus bplus Bc Bo where + t := F.t ∘ σ + b := F.b ∘ σ + z := F.z ∘ σ + prefixTime k := F.prefixTime (σ k) + parameter k := F.parameter (σ k) + time := F.time.comp hσ + positive k := F.positive (σ k) + maximum k := F.maximum (σ k) + row k := F.row (σ k) + +lemma MaximumFamily.compact_subseq {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) : + ∃ σ:ℕ → ℕ,StrictMono σ ∧ ∃ β∈Icc bminus bplus, + ∃ Q:TangentBundle 𝓘(ℝ,Model n) M,Q.2∈minimizingVectors Q.1 ∧ + Tendsto (F.b ∘ σ) atTop (𝓝 β) ∧ + Tendsto (fun k=>(F.row (σ k)).q.1) atTop (𝓝 Q) := by + let : FirstCountableTopology (ModelProd (Model n) (Model n)) := + inferInstanceAs (FirstCountableTopology (Model n×Model n)) + let : FirstCountableTopology (TangentBundle 𝓘(ℝ,Model n) M) := by + constructor + intro x + let e := chartAt (ModelProd (Model n) (Model n)) x + have he : map e.symm (𝓝 (e x))=𝓝 x := e.symm_map_nhds_eq (mem_chart_source _ _) + rw [←he] + infer_instance + have hc := isCompact_Icc (a := bminus) (b := bplus) |>.prod + (isCompact_total_minimizingVectors (n := n) (M := M)) + obtain ⟨q,hq,σ,hσ,hlim⟩ := hc.isSeqCompact (fun k=> + show (F.b k,(F.row k).q.1)∈Icc bminus bplus×ˢ + {Q:TangentBundle 𝓘(ℝ,Model n) M | Q.2∈minimizingVectors Q.1} from + ⟨Ioo_subset_Icc_self (F.parameter k),(F.row k).minimizing⟩) + exact ⟨σ,hσ,q.1,hq.1,q.2,hq.2,hlim.fst_nhds,hlim.snd_nhds⟩ + +lemma MaximumFamily.limit_coordinates {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + (F : MaximumFamily (n := n) v α D bminus bplus Bc Bo) + {Q:TangentBundle 𝓘(ℝ,Model n) M} + (hQ : Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 Q)) : + Tendsto (fun k=>graphBaseCoordinate Q.1 (F.row k).q.1) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) Q.1 Q.1)) ∧ + Tendsto (fun k=>graphVelocityCoordinate Q.1 (F.row k).q.1) atTop (𝓝 (show Model n from Q.2)) ∧ + Tendsto F.z atTop (𝓝 (riemannianExp Q.1 Q.2)) ∧ + Tendsto (fun k=>riemannianExp (F.row k).q.1.1 (F.row k).q.1.2) atTop + (𝓝 (riemannianExp Q.1 Q.2)) := by + let χ := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (⟨Q.1,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hs : Q∈χ.source := (tangent_chart_source_iff _ _).mpr (mem_extChartAt_source Q.1) + have HC := ((continuousOn_extChartAt _).continuousAt ((isOpen_extChartAt_source _).mem_nhds hs)).tendsto.comp hQ + have hvel : Tendsto (fun k=>graphVelocityCoordinate Q.1 (F.row k).q.1) atTop + (𝓝 (graphVelocityCoordinate Q.1 Q)) := HC.snd_nhds + rw [graph_coordinates_at_center] at hvel + have HE := contMDiff_riemannianExp.continuous.tendsto Q |>.comp hQ + have HP := (contMDiff_riemannianExp.continuous.comp contMDiff_tangentScale.continuous).tendsto (1,Q) + |>.comp (F.time.prodMk_nhds hQ) + have HZ : Tendsto F.z atTop (𝓝 (riemannianExp Q.1 Q.2)) := by + change Tendsto (fun k=>riemannianExp (F.row k).q.1.1 (F.t k • (F.row k).q.1.2)) atTop + (𝓝 (riemannianExp Q.1 ((1:ℝ) • Q.2))) at HP + simp only [one_smul] at HP + exact HP.congr (fun k=>(F.row k).projection) + exact ⟨HC.fst_nhds,hvel,HZ,HE⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumConfiguration.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumConfiguration.lean new file mode 100644 index 0000000000000000000000000000000000000000..84e0556364f69ec6881f0bd23543bf796f4f4f03 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumConfiguration.lean @@ -0,0 +1,86 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.Alignment +import OAI.Analysis.BiholderTransport.Regularity.ActualParameter + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.modified_maximum_configuration + (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {a D b bplus t H : ℝ} {z : M} + {Bc Bo : ℝ → ℝ} (hc : Continuous Bc) (ho : Continuous Bo) + (hbound : ∀ s,0≤Bo s ∧ Bo s≤H) + (ht : 0(hactive i).1) (fun i=>(hactive i).2) ht ht1 hb hbp ?_ ?_).1 + · dsimp only + rw [hmp,←hpz] + exact hcenter + · dsimp only + rw [hmp,←hpz] + exact (tendsto_id.prodMk_nhds tendsto_const_nhds).eventually hmax + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumDiagonal.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumDiagonal.lean new file mode 100644 index 0000000000000000000000000000000000000000..d4eeefea836f5277dbd3e73db2d4df3306b020fb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumDiagonal.lean @@ -0,0 +1,104 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily +import OAI.Analysis.BiholderTransport.Regularity.MaximumSample +import OAI.Analysis.BiholderTransport.Regularity.Diagonal + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +abbrev MaximumJensenFamily.sampleIndex (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) := + (J.first k).σ j + +def MaximumJensenFamily.samplePoint (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : + subgradientGraph (n := n) (cTransform (modifiedDatum v α D (F.b k) Bo)) := + (hmtw.graphHomeomorph (continuous_modifiedDatum hv α D (F.b k) ho) + (F.prefixTime k).1 (F.prefixTime k).2).symm + ((extChartAt 𝓘(ℝ,Model n) c).symm ((J.sample k).z (J.sampleIndex k j))) + +def MaximumJensenFamily.sampleCenter (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : Model n := + extChartAt 𝓘(ℝ,Model n) c ((J.sample k).Y ((J.sample k).z (J.sampleIndex k j))) + +def MaximumJensenFamily.sampleGradient (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : + Model n →L[ℝ] ℝ := + fderiv ℝ (chartOuterEnvelope (modifiedDatum v α D (F.b k) Bo) (F.t k) c) + ((J.sample k).z (J.sampleIndex k j))+ + fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + ((J.sample k).z (J.sampleIndex k j)) + +def MaximumJensenFamily.sampleH (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : + Model n →L[ℝ] Model n →L[ℝ] ℝ := + coordinateCenterMatrix a (F.t k) (hopfLax (1-F.t k) (modifiedDatum v α D (F.b k) Bc)) + (graphBaseCoordinate a (J.samplePoint k j).1) (graphVelocityCoordinate a (J.samplePoint k j).1) + +def MaximumJensenFamily.sampleL (J : MaximumJensenFamily hmtw hv ho F a c N) (k j:ℕ) : + Model n →L[ℝ] Model n →L[ℝ] ℝ := + coordinatePoleMatrix a (F.t k) (modifiedDatum v α D (F.b k) Bo) + (graphBaseCoordinate a (J.samplePoint k j).1) (graphVelocityCoordinate a (J.samplePoint k j).1) + +structure MaximumDiagonal (J : MaximumJensenFamily hmtw hv ho F a c N) + (ε : ℕ → ℝ) (P : ℕ → ℕ → Prop) where + ν : ℕ → ℕ + poleSource : ∀ k,(J.samplePoint k (ν k)).1.1∈(extChartAt 𝓘(ℝ,Model n) a).source + chart : ∀ k,(J.sample k).z (J.sampleIndex k (ν k))∈(extChartAt 𝓘(ℝ,Model n) c).target + baseClose : ∀ k,dist (graphBaseCoordinate a (J.samplePoint k (ν k)).1) + (graphBaseCoordinate a (F.row k).q.1)<ε k + velocityClose : ∀ k,dist (graphVelocityCoordinate a (J.samplePoint k (ν k)).1) + (graphVelocityCoordinate a (F.row k).q.1)<ε k + centerClose : ∀ k,dist (J.sampleCenter k (ν k)) + (extChartAt 𝓘(ℝ,Model n) c (riemannianExp (F.row k).q.1.1 (F.row k).q.1.2))<ε k + gradientClose : ∀ k,‖J.sampleGradient k (ν k)‖<ε k + HClose : ∀ k,‖J.sampleH k (ν k)-(J.first k).H‖<ε k + LClose : ∀ k,‖J.sampleL k (ν k)-(J.first k).L‖<ε k + activeClose : ∀ k,dist ((J.first k).pj (ν k)) (J.first k).pj₀<ε k + weightClose : ∀ k,dist ((J.first k).w (ν k)) (J.first k).w₀<ε k + extra : ∀ k,P k (ν k) + +lemma MaximumJensenFamily.exists_diagonal (J : MaximumJensenFamily hmtw hv ho F a c N) + {ε : ℕ → ℝ} (hε : ∀ k,0<ε k) {P : ℕ → ℕ → Prop} + (hP : ∀ k,∀ᶠ j in atTop,P k j) : Nonempty (MaximumDiagonal J ε P) := by + have H (k:ℕ) := (F.row k).jensen_approximation hmtw hv ho (F.prefixTime k).1 + (F.prefixTime k).2 (J.sample k) (J.endpointSource k) (J.poleSource k) (J.first k) + (ε k) (hε k) (P k) (hP k) + choose ν hs hc hb hp hy hg hH hL hi hw hex using H + exact ⟨⟨ν,hs,hc,hb,hp,hy,hg,hH,hL,hi,hw,hex⟩⟩ + +lemma MaximumDiagonal.limits (J : MaximumJensenFamily hmtw hv ho F a c N) + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) + (hε : Tendsto ε atTop (𝓝 0)) {q : Model n} + (hQ : Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) (hc : riemannianExp a q=c) : + Tendsto (fun k=>graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)) ∧ + Tendsto (fun k=>graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1) atTop (𝓝 q) ∧ + Tendsto (fun k=>J.sampleCenter k (S.ν k)) atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c)) ∧ + Tendsto (fun k=>J.sampleGradient k (S.ν k)) atTop (𝓝 0) := by + obtain ⟨hb,hp,hz,hy⟩ := F.limit_coordinates hQ + rw [hc] at hy + have hY := ((continuousOn_extChartAt _).continuousAt ((isOpen_extChartAt_source _).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) c))).tendsto.comp hy + refine ⟨diagonal_tendsto_of_close hb hε (Eventually.of_forall (fun k=>(S.baseClose k).le)), + diagonal_tendsto_of_close hp hε (Eventually.of_forall (fun k=>(S.velocityClose k).le)), + diagonal_tendsto_of_close hY hε (Eventually.of_forall (fun k=>(S.centerClose k).le)),?_⟩ + apply diagonal_tendsto_of_close tendsto_const_nhds hε + exact Eventually.of_forall (fun k=>by simpa only [dist_zero_right] using (S.gradientClose k).le) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumEndpoint.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumEndpoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..b7aff61026245cab6cc4f46097be24303c849cc7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumEndpoint.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.JointMovingPrefix +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal +import OAI.Analysis.BiholderTransport.Regularity.MaximumReindex + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumEndpoint +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumDiagonal.movingChart {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) (k:ℕ) : + movingPrefixChart a c (F.t k) (graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) + (graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1)= + (J.sample k).z (J.sampleIndex k (S.ν k)) := by + rw [movingPrefixChart,movingPrefix_graph_coordinates (S.poleSource k)] + exact S.endpointChart k + +lemma MaximumDiagonal.endpoint_tendsto {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + {q:Model n} (hc:riemannianExp a q=c) + (hb:Tendsto (fun k=>graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hp:Tendsto (fun k=>graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1) atTop (𝓝 q)) : + Tendsto (fun k=>(J.sample k).z (J.sampleIndex k (S.ν k))) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c)) := by + have hb0:extChartAt 𝓘(ℝ,Model n) a a∈(extChartAt 𝓘(ℝ,Model n) a).target:= + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hgc:movingPrefix a 1 (extChartAt 𝓘(ℝ,Model n) a a) q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + rw [movingPrefix_at_center,one_smul,hc] + exact mem_extChartAt_source c + have H:=((joint_movingPrefixChart_contDiffAt hb0 hgc).continuousAt.tendsto).comp + ((F.time.prodMk_nhds hb).prodMk_nhds hp) + change Tendsto (fun k=>movingPrefixChart a c (F.t k) + (graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) + (graphVelocityCoordinate a (J.samplePoint k (S.ν k)).1)) atTop + (𝓝 (movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a) q)) at H + simp only [S.movingChart] at H + simpa only [movingPrefixChart,movingPrefix_at_center,one_smul,hc] using H + +end MaximumEndpoint +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumFamily.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumFamily.lean new file mode 100644 index 0000000000000000000000000000000000000000..f3f416fced403cb3d2a27635f093f35f9158e527 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumFamily.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.InteriorMaximum +import OAI.Analysis.BiholderTransport.Regularity.MaximumRow + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure MaximumFamily (v : M → ℝ) (α D bminus bplus : ℝ) (Bc Bo : ℝ → ℝ) where + t : ℕ → ℝ + b : ℕ → ℝ + z : ℕ → M + prefixTime : ∀ k,01/((k:ℝ)+2) + let t : ℕ → ℝ := fun k=>1-r k + have hr : Tendsto r atTop (𝓝 0) := by + have Hr : Tendsto (fun k:ℕ=>(1:ℝ)/((k:ℝ)+1)) atTop (𝓝 0) := + tendsto_one_div_add_atTop_nhds_zero_nat + have H := Hr.comp (tendsto_add_atTop_nat 1) + change Tendsto (fun k:ℕ=>(1:ℝ)/(((k+1:ℕ):ℝ)+1)) atTop (𝓝 0) at H + simpa only [r,Nat.cast_add,Nat.cast_one,add_assoc,one_add_one_eq_two] using H + have ht : Tendsto t atTop (𝓝 1) := by simpa only [sub_zero] using tendsto_const_nhds.sub hr + have ht01 : ∀ k,0.mpr Hd + exact div_le_div_of_nonneg_right Hsq (by norm_num) + let err : ℕ → ℝ := fun k=>C*|1/t k-1|+(L:ℝ)^2*(1-t k)/2 + have he : Tendsto err atTop (𝓝 0) := by + have h1 : Tendsto (fun k=>(1:ℝ)/t k-1) atTop (𝓝 (1/1-1)) := + (tendsto_const_nhds.div ht (by norm_num : (1:ℝ)≠0)).sub tendsto_const_nhds + have h2 : Tendsto err atTop (𝓝 (C*|1/1-1|+(L:ℝ)^2*(1-1)/2)) := + (tendsto_const_nhds.mul h1.abs).add + ((tendsto_const_nhds.mul (tendsto_const_nhds.sub ht)).div_const 2) + simpa only [one_div_one,sub_self,abs_zero,mul_zero,zero_div,add_zero] using h2 + have hε : 0hk.le)).and + (((tendsto_const_nhds.sub ht : Tendsto (fun k=>1-t k) atTop (𝓝 (1-1))).eventually + (by simpa using (gt_mem_nhds hδ : Iio δ∈𝓝 (0:ℝ))))) + obtain ⟨N,hN⟩ := eventually_atTop.mp hevent + have Hmax : ∀ k,∃ q:ℝ×M,q.1∈Ioo bminus bplus ∧ + 0Classical.choice (Hrow k) + exact ⟨⟨fun k=>t (k+N),fun k=>(q k).1,fun k=>(q k).2,fun k=>ht01 _,hq, + ht.comp (tendsto_add_atTop_nat N),hpq,hmax,R⟩⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumGoodCenters.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumGoodCenters.lean new file mode 100644 index 0000000000000000000000000000000000000000..6082894c5efcb461062495452b1c09298caeb42e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumGoodCenters.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ShortSelectorNonsingularity +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumDiagonal.good_centers {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) (hBc:Continuous Bc) + (hx:Tendsto (fun k=>J.sampleCenter k (S.ν k)) atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + (hz:Tendsto (fun k=>(J.sample k).z (J.sampleIndex k (S.ν k))) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) c c))) + {C:ℝ} (hG:∀ᶠ k in atTop,∀d, + fderiv ℝ (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k))) d d ≤ C*‖d‖^2) : + ∀ᶠ k in atTop,J.sampleCenter k (S.ν k)∉N := by + let χ:=extChartAt 𝓘(ℝ,Model n) c + obtain ⟨m,hm,H⟩:=actual_short_selector_injective_near (χ.map_source (mem_extChartAt_source c)) + have hτ:Tendsto (fun k=>(1-F.t k)*C) atTop (𝓝 (0:ℝ)) := by + simpa only [sub_self,zero_mul] using ((tendsto_const_nhds (x := (1:ℝ))).sub F.time).mul_const C + filter_upwards [hG,(hx.prodMk_nhds hz).eventually H,hτ.eventually (gt_mem_nhds hm)] + with k hGk hnear hsmall + let j:=J.sampleIndex k (S.ν k) + let T:=J.sample k + obtain ⟨hy,_,_,_,hY,_,hnot,_,_,_,_⟩:=T.samples j + have hcontact:∀ᶠ z in 𝓝 (T.z j), + chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c z= + modifiedDatum v α D (F.b k) Bc (χ.symm (χ (T.Y z)))+ + chartCost c (χ.symm (χ (T.Y z))) z/(1-F.t k) := by + filter_upwards [T.openRegion.mem_nhds (T.sampleInRegion j)] with z hz + have he:χ.symm (χ (T.Y z))=T.Y z:=χ.left_inv (T.actual z hz).1 + rw [he] + simpa only [chartCost,cost_symm] using ((T.actual z hz).2.2.1 (T.Y z)).mpr rfl + have hd:∀ᶠ z in 𝓝 (T.z j), + DifferentiableAt ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) z := by + filter_upwards [T.openRegion.mem_nhds (T.sampleInRegion j)] with z hz + exact T.centerDifferentiable z hz + have hinj:Function.Injective (fderiv ℝ (fun z=>χ (T.Y z)) (T.z j)) := + hnear (1-F.t k) (by linarith [(F.prefixTime k).2]) + (modifiedDatum v α D (F.b k) Bc) (continuous_modifiedDatum hv α D (F.b k) hBc) + (fun z=>χ (T.Y z)) _ rfl hY hcontact hd C hsmall hGk + apply hnot + intro hzero + exact (LinearMap.det_eq_zero_iff_ker_ne_bot.mp hzero) (LinearMap.ker_eq_bot.mpr hinj) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumLowerBound.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumLowerBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..2bf29207dec02dee1f94da5f05190fb700e3b347 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumLowerBound.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FrameMetric + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumLowerBound +variable {n:ℕ} {M:Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance lowerDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance lowerDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance lowerBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance lowerBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +omit [Nonempty M] in +lemma eventual_lower_bound_of_center_gain {a:M} {q:TangentSpace 𝓘(ℝ,Model n) a} + {A C:ℝ} (hA:0 ≤ A) (hC:C ≤ 0) {H:ℕ → Model n →L[ℝ] Model n →L[ℝ] ℝ} + (hH:∀ε:ℝ,0 < ε → ∀ᶠ k in atTop,∀d:Model n, + A*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + C*(inner ℝ q (show TangentSpace 𝓘(ℝ,Model n) a from d))^2-ε*‖d‖^2 ≤ H k d d) : + ∃CH:ℝ,0 ≤ CH ∧ ∀ᶠ k in atTop,∀d,-CH*‖d‖^2 ≤ H k d d := by + let f:=frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) (show Model n from q) + have hneg : 0 ≤ -C := neg_nonneg.mpr hC + refine ⟨1+(-C)*‖f‖^2,by positivity,?_⟩ + filter_upwards [hH 1 (by norm_num)] with k hk + intro d + have hf:|f d| ≤ ‖f‖*‖d‖:=f.le_opNorm d + have hs:(f d)^2 ≤ ‖f‖^2*‖d‖^2:=by + have hp:=sq_le_sq₀ (abs_nonneg (f d)) (mul_nonneg (norm_nonneg f) (norm_nonneg d)) |>.mpr hf + simpa only [sq_abs,mul_pow] using hp + have hm:=mul_le_mul_of_nonpos_left hs hC + have hpos:0 ≤ A*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2:=mul_nonneg hA (sq_nonneg _) + have hh:=hk d + have he:f d=inner ℝ q (show TangentSpace 𝓘(ℝ,Model n) a from d):=frameMetric_center a q d + rw [he] at hm + nlinarith only [hm,hh,hpos] + +end MaximumLowerBound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterBound.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1b95722d6bfaaff2d8b810f66cfab063f8b2c0c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterBound.lean @@ -0,0 +1,93 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MaximumPolePositive +import OAI.Analysis.BiholderTransport.Regularity.ModifiedOuterNeighborhood + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section MaximumOuterBound +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma MaximumJensenFamily.outer_bound + {hmtw:WeakMTW (n := n) (M := M)} + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {x0:M} + {uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)} (huv:uv∈densityDualClass (metricVolume n) lam cap x0) + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} (ho:ContDiff ℝ ∞ Bo) + {F:MaximumFamily (n := n) uv.2 α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} + (J:MaximumJensenFamily hmtw uv.2.continuous ho.continuous F a c N) + {β:ℝ} (hb:Tendsto F.b atTop (𝓝 β)) + (hbcoord:Tendsto (fun k=>graphBaseCoordinate a (F.row k).q.1) atTop + (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (i:ℕ → Fin (Module.finrank ℝ (Model n)+1)) {r:Model n} + (hr:Tendsto (fun k=>(J.first k).pj₀ (i k)) atTop (𝓝 r)) + {mstar:ℝ} (hmstar:0 < mstar) (hm:∀ᶠ k in atTop,mstar ≤ (J.first k).w₀ (i k)) + (hmono:∀k,StrictMono (fun s=>modifiedScalar α D Bo (F.b k,s))) + (hmono0:StrictMono (fun s=>modifiedScalar α D Bo (β,s))) + (hslope:1 < deriv (fun s=>modifiedScalar α D Bo (β,s)) (uv.2 (riemannianExp a r))) + (hcurve:iteratedDeriv 2 (fun s=>modifiedScalar α D Bo (β,s)) + (uv.2 (riemannianExp a r)) < 0) : + ∃C≥0,∀ᶠ k in atTop,∀d:Model n,(J.first k).L d d ≤ C*‖d‖^2 := by + have hactive:(show TangentSpace 𝓘(ℝ,Model n) a from r)∈ + activeLogs (modifiedDatum uv.2 α D β Bo) a := + modified_active_coordinates_limit uv.2.continuous ho.continuous hb hbcoord hr + (Eventually.of_forall (fun k=>(extChartAt 𝓘(ℝ,Model n) a).map_source (J.poleSource k))) + (Eventually.of_forall (fun k=>(J.first k).activeLimit (i k))) + obtain ⟨U,hU,C,hC,HC⟩:=hmtw.modified_outer_neighborhood hlam hcap huv + (modifiedScalar_contDiff ho α D) hmono0 hactive hslope hcurve + have hlim:Tendsto (fun k=>((graphBaseCoordinate a (F.row k).q.1,(J.first k).pj₀ (i k)),F.b k)) + atTop (𝓝 ((extChartAt 𝓘(ℝ,Model n) a a,r),β)) := + (hbcoord.prodMk_nhds hr).prodMk_nhds hb + have hnear:∀ᶠ k in atTop,U∈𝓝 ((graphBaseCoordinate a (F.row k).q.1,(J.first k).pj₀ (i k)),F.b k) := + hlim.eventually (eventually_eventually_nhds.mpr hU) + refine ⟨C/mstar,div_nonneg hC hmstar.le,?_⟩ + filter_upwards [hnear,hm] with k hUk hmk + have hσ:=(J.first k).strictMono.tendsto_atTop + obtain ⟨hq,hb',hp'⟩:=(F.row k).jensen_graph_limit hmtw uv.2.continuous ho.continuous + (F.prefixTime k).1 (F.prefixTime k).2 (J.sample k) (J.endpointSource k) (J.poleSource k) + have hlj:Tendsto (fun j=>((graphBaseCoordinate a (J.samplePoint k j).1, + (J.first k).pj j (i k)),F.b k)) atTop + (𝓝 ((graphBaseCoordinate a (F.row k).q.1,(J.first k).pj₀ (i k)),F.b k)) := + ((hb'.comp hσ).prodMk_nhds (tendsto_pi_nhds.mp (J.first k).pjLimit (i k))).prodMk_nhds tendsto_const_nhds + have hw:Tendsto (fun j=>(J.first k).w j (i k)) atTop (𝓝 ((J.first k).w₀ (i k))) := + tendsto_pi_nhds.mp (J.first k).wLimit (i k) + have hwpos:∀ᶠ j in atTop,0 < (J.first k).w j (i k) := + hw.eventually (lt_mem_nhds (hmstar.trans_le hmk)) + have H:∀ᶠ j in atTop,∀d:Model n,(J.first k).w j (i k)*J.sampleL k j d d ≤ C*‖d‖^2 := by + filter_upwards [hlj.eventually hUk,hwpos,J.sample_pole_positive k,(J.first k).samples] + with j hj hwj hpos hjets + intro d + exact HC _ hj (hmono k) ((J.first k).w j (i k) • J.sampleL k j) + (fun e=>by exact mul_nonneg hwj.le (hpos e)) (hjets.2.2.2.2 (i k) hwj) d + intro d + have hld:Tendsto (fun j=>J.sampleL k j d d) atTop (𝓝 ((J.first k).L d d)) := + ((show Continuous (fun B:Model n →L[ℝ] Model n →L[ℝ] ℝ=>B d d) from + (continuous_id.clm_apply continuous_const).clm_apply continuous_const).tendsto _).comp + (J.first k).LLimit + have HQ:(J.first k).w₀ (i k)*(J.first k).L d d ≤ C*‖d‖^2 := + le_of_tendsto (hw.mul hld) (H.mono (fun j hj=>hj d)) + have Hstar:mstar*(J.first k).L d d ≤ C*‖d‖^2 := + (mul_le_mul_of_nonneg_right hmk ((J.first k).positive d)).trans HQ + calc + (J.first k).L d d ≤ (C*‖d‖^2)/mstar := (le_div_iff₀ hmstar).mpr (by nlinarith only [Hstar]) + _ = C/mstar*‖d‖^2 := by ring + +end MaximumOuterBound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterSamples.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterSamples.lean new file mode 100644 index 0000000000000000000000000000000000000000..550c1747190d50f0e263ac313fbbd2d85e4b5578 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOuterSamples.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal +import OAI.Analysis.BiholderTransport.LinearAlgebra.MaximumPolePositive +import OAI.Analysis.BiholderTransport.Regularity.MaximumPoleSymmetric + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumOuterSamples +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +def MaximumJensenFamily.OuterSampleGood (J:MaximumJensenFamily hmtw hv ho F a c N) + (k j:ℕ):Prop := + let b:=graphBaseCoordinate a (J.samplePoint k j).1 + (∀d e,J.sampleL k j d e=J.sampleL k j e d) ∧ + (∀d,0 ≤ J.sampleL k j d d) ∧ + (∀i,0 ≤ (J.first k).w j i) ∧ + (∀i,chartFiberInverse a b ((J.first k).pj j i)∈ + activeLogs (modifiedDatum v α D (F.b k) Bo) ((extChartAt 𝓘(ℝ,Model n) a).symm b)) ∧ + (∀i,0 < (J.first k).w j i → HasLowerSecondTaylor + (fun d=>modifiedDatum v α D (F.b k) Bo (movingNormal a (b,(J.first k).pj j i+d))+ + ‖chartFiberInverse a b ((J.first k).pj j i+d)‖^2/2) 0 + ((J.first k).w j i • J.sampleL k j)) + +lemma MaximumJensenFamily.outer_samples_eventually (J:MaximumJensenFamily hmtw hv ho F a c N) + (k:ℕ):∀ᶠ j in atTop,J.OuterSampleGood k j := by + filter_upwards [J.sample_pole_symmetric k,J.sample_pole_positive k,(J.first k).samples] + with j hs hp hj + exact ⟨hs,hp,hj.1,hj.2.2.2.1,hj.2.2.2.2⟩ + +lemma MaximumJensenFamily.exists_outer_diagonal (J:MaximumJensenFamily hmtw hv ho F a c N) + {ε:ℕ → ℝ} (hε:∀k,0 < ε k): + Nonempty (MaximumDiagonal J ε J.OuterSampleGood) := + J.exists_diagonal hε J.outer_samples_eventually + +end MaximumOuterSamples +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutward.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutward.lean new file mode 100644 index 0000000000000000000000000000000000000000..e6e6e5ec2bebe1c4315999a437e26602ea0c6a46 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutward.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MaximumRank +import OAI.Analysis.BiholderTransport.Regularity.FirstOutward + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumOutward +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma MaximumFamily.positive_excess + {v:M → ℝ} {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} + (F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo) + (hm:0 ≤ bminus) (hp:0 < bplus) (k:ℕ) : + 0 < modifiedExcess v α D (F.b k) Bc Bo + (riemannianExp (F.row k).q.1.1 (F.row k).q.1.2) := by + have h0:0 ≤ F.b k:=hm.trans (F.parameter k).1.le + have hpen:0 ≤ parameterPenalty bplus (F.b k):=by + unfold parameterPenalty + positivity + have H:=F.positive k + rw [(F.row k).value] at H + linarith only [H,hpen] + +lemma MaximumJensenFamily.eventual_outward + {hmtw:WeakMTW (n:=n) (M:=M)} {u v:M → ℝ} + (hu:Continuous u) {hv:Continuous v} (hdual:IsCostDualPair u v) + {α D bminus bplus H:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} + (hm:0 ≤ bminus) (hp:0 < bplus) (hprofiles:∀s,Bc s ≤ Bo s) + (hob:∀s,0 ≤ Bo s ∧ Bo s ≤ H) (hcb:∀s,-1 ≤ Bc s ∧ Bc s ≤ 1) + (hright:∀s,3/4 ≤ s → Bc s ≤ 0) + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + {q:Model n} (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {A C:ℝ} (hA:0 < A) (hC:C < 0) + (hH:∀ ε:ℝ,0 < ε → ∀ᶠ k in atTop,∀d:Model n, + A*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + C*(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2-ε*‖d‖^2 ≤ (J.first k).H d d) + {eta delta zeta a0:ℝ} (hD:0 < D) (ha0:0 < a0) (hqa:2*(-C)*a0*D ≤ A) + (heta:eta ≤ 1/128) (hdelta:delta ≤ zeta) (hdeltaEta:delta ≤ eta) (hzeta:zeta ≤ 1/16) + (hleft:∀s,s < 1-eta → 1 ≤ Bo s) + (herror:∀k,2*(H+2)*F.b k ≤ zeta*D) + (hosc:∀k,sectionOscillation u v (F.row k).q.1.1 ((H+2)*F.b k) ≤ (1+delta)*D) : + ∀ᶠ k in atTop, + let b:=graphBaseCoordinate a (F.row k).q.1 + let x:=(extChartAt 𝓘(ℝ,Model n) a).symm b + let P:=chartFiberInverse a b (graphVelocityCoordinate a (F.row k).q.1) + let si:=fun i=>(v (riemannianExp x (chartFiberInverse a b ((J.first k).pj₀ i)))-α)/D + ∃e:TangentSpace 𝓘(ℝ,Model n) x,∃i:Fin (Module.finrank ℝ (Model n)+1),∃d:ℝ, + ‖e‖=1 ∧ 0 < inner ℝ P e ∧ a0*D ≤ (inner ℝ P e)^2 ∧ 0 < d ∧ + chartFiberInverse a b ((J.first k).pj₀ i)=P+d • e ∧ + (1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)) ≤ (J.first k).w₀ i ∧ + (1/4096)*D/(8*(Module.finrank ℝ (Model n)+1:ℝ)*(inner ℝ P e)) ≤ (J.first k).w₀ i*d ∧ + d ≤ 3*D/(2*(inner ℝ P e)) ∧ -2*eta ≤ si i ∧ si i < 1-eta ∧ + Bo (si i) ≤ 12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) := by + have HR:=J.eventual_rank_of_center_lower hm hp hprofiles hQ hA hH + filter_upwards [HR] with k hk + dsimp only at hk ⊢ + obtain ⟨e,hes,he,hpe,hline,hgain⟩:=hk + have hqa':a0*D ≤ (inner ℝ + (chartFiberInverse a (graphBaseCoordinate a (F.row k).q.1) + (graphVelocityCoordinate a (F.row k).q.1)) e)^2:=by + apply (mul_le_mul_iff_right₀ (neg_pos.mpr hC)).mp + nlinarith only [hgain,hqa] + have hbt:graphBaseCoordinate a (F.row k).q.1∈(extChartAt 𝓘(ℝ,Model n) a).target:= + (extChartAt 𝓘(ℝ,Model n) a).map_source (J.poleSource k) + have hrec:=graph_coordinate_reconstruction (J.poleSource k) + have hx: (extChartAt 𝓘(ℝ,Model n) a).symm (graphBaseCoordinate a (F.row k).q.1)= + (F.row k).q.1.1:=congrArg Bundle.TotalSpace.proj hrec + have hept:riemannianExp + ((extChartAt 𝓘(ℝ,Model n) a).symm (graphBaseCoordinate a (F.row k).q.1)) + (chartFiberInverse a (graphBaseCoordinate a (F.row k).q.1) + (graphVelocityCoordinate a (F.row k).q.1))= + riemannianExp (F.row k).q.1.1 (F.row k).q.1.2:= + congrArg (fun z:TangentBundle 𝓘(ℝ,Model n) M=>riemannianExp z.1 z.2) hrec + have hb:0 ≤ F.b k:=hm.trans (F.parameter k).1.le + have hparam:=(F.row k).chart_first_limit_parameter (J.poleSource k) (J.first k) + dsimp only at hparam + simp only [movingNormal_eq hbt] at hparam + have hpn:(1:ℝ)/4096 ≤ (1:ℝ)/4096+4*F.b k/bplus:= + le_add_of_nonneg_right (div_nonneg (mul_nonneg (by norm_num) hb) hp.le) + obtain ⟨i,d,_,hd,hpd,hmi,hmom,hdmax,hsi,hsi',hcap,_,_⟩:= + (J.first k).outward_endpoint hmtw hu hv hdual ho hb hob hcb hright e he hpe hline + (1/4096) eta delta zeta a0 hD (by norm_num) ha0 hqa' heta hdelta hdeltaEta hzeta hleft + (by rw [hept]; exact F.positive_excess hm hp k) (herror k) + (by rw [hx]; exact hosc k) (hpn.trans hparam) + exact ⟨e,i,d,he,hpe,hqa',hd,hpd,hmi,hmom,hdmax,hsi,hsi',hcap⟩ + +end MaximumOutward +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutwardCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutwardCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..d7397dd71805c24a7f6e74318f7b755a34a8befa --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumOutwardCompact.lean @@ -0,0 +1,125 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CenterRayLimit +import OAI.Analysis.BiholderTransport.Regularity.MaximumActiveCompact +import OAI.Analysis.BiholderTransport.Regularity.FrameOutwardLimit + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumOutwardCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumJensenFamily.active_outward_compact + {hmtw:WeakMTW (n:=n) (M:=M)} {v:M → ℝ} {hv:Continuous v} + {α D bminus bplus:ℝ} {Bc Bo:ℝ → ℝ} {ho:Continuous Bo} + {F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} (J:MaximumJensenFamily hmtw hv ho F a c N) + {q:Model n} {β μ ν κ eta U:ℝ} (hb:Tendsto F.b atTop (𝓝 β)) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + (hμ:0 < μ) (hν:0 < ν) (hκ:0 < κ) (hD:0 < D) + (hsel:∀ᶠ k in atTop, + let b:=graphBaseCoordinate a (F.row k).q.1 + let A:=chartFiberInverse a b + let P:=A (graphVelocityCoordinate a (F.row k).q.1) + let si:=fun i=>(v (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) + (A ((J.first k).pj₀ i)))-α)/D + ∃i:Fin (Module.finrank ℝ (Model n)+1), + ∃e:TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm b),∃d:ℝ, + ‖e‖=1 ∧ 0 < inner ℝ P e ∧ κ*D ≤ (inner ℝ P e)^2 ∧ 0 < d ∧ + A ((J.first k).pj₀ i)=P+d • e ∧ μ ≤ (J.first k).w₀ i ∧ + ν*D/(inner ℝ P e) ≤ (J.first k).w₀ i*d ∧ + d ≤ 3*D/(2*(inner ℝ P e)) ∧ -2*eta ≤ si i ∧ si i < 1-eta ∧ Bo (si i) ≤ U) : + ∃σ:ℕ → ℕ,StrictMono σ ∧ + ∃r:Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃m:Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃i₀:Fin (Module.finrank ℝ (Model n)+1), + Tendsto (fun k=>(J.first (σ k)).pj₀) atTop (𝓝 r) ∧ + Tendsto (fun k=>(J.first (σ k)).w₀) atTop (𝓝 m) ∧ + (∀j,(show TangentSpace 𝓘(ℝ,Model n) a from r j)∈ + activeLogs (modifiedDatum v α D β Bo) a) ∧ + (∀j,0 ≤ m j) ∧ ∑j,m j=1 ∧ ∑j,m j • r j=q ∧ μ ≤ m i₀ ∧ + (∀ᶠ k in atTop,μ ≤ (J.first (σ k)).w₀ i₀) ∧ + -2*eta ≤ (v (riemannianExp a (r i₀))-α)/D ∧ + (v (riemannianExp a (r i₀))-α)/D ≤ 1-eta ∧ + Bo ((v (riemannianExp a (r i₀))-α)/D) ≤ U ∧ + ∃e:TangentSpace 𝓘(ℝ,Model n) a,∃d:ℝ,‖e‖=1 ∧ 0 < d ∧ + (show TangentSpace 𝓘(ℝ,Model n) a from r i₀)= + (show TangentSpace 𝓘(ℝ,Model n) a from q)+d • e ∧ + 0 < inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e ∧ + κ*D ≤ (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e)^2 ∧ + ν*D/(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e) ≤ m i₀*d ∧ + d ≤ 3*D/(2*(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e)) ∧ + ‖show TangentSpace 𝓘(ℝ,Model n) a from r i₀‖^2- + ‖show TangentSpace 𝓘(ℝ,Model n) a from q‖^2 ≤ (3+9/(4*κ))*D := by + classical + let b:=fun k=>graphBaseCoordinate a (F.row k).q.1 + let p:=fun k=>graphVelocityCoordinate a (F.row k).q.1 + let S:=fun k (i:Fin (Module.finrank ℝ (Model n)+1))=> + ∃e:TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)),∃d:ℝ, + ‖e‖=1 ∧ 0 < inner ℝ (chartFiberInverse a (b k) (p k)) e ∧ + κ*D ≤ (inner ℝ (chartFiberInverse a (b k) (p k)) e)^2 ∧ 0 < d ∧ + chartFiberInverse a (b k) ((J.first k).pj₀ i)= + chartFiberInverse a (b k) (p k)+d • e ∧ μ ≤ (J.first k).w₀ i ∧ + ν*D/(inner ℝ (chartFiberInverse a (b k) (p k)) e) ≤ (J.first k).w₀ i*d ∧ + d ≤ 3*D/(2*(inner ℝ (chartFiberInverse a (b k) (p k)) e)) ∧ + -2*eta ≤ (v (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)) + (chartFiberInverse a (b k) ((J.first k).pj₀ i)))-α)/D ∧ + (v (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)) + (chartFiberInverse a (b k) ((J.first k).pj₀ i)))-α)/D < 1-eta ∧ + Bo ((v (riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm (b k)) + (chartFiberInverse a (b k) ((J.first k).pj₀ i)))-α)/D) ≤ U + let i:=fun k=>if h:∃j,S k j then Classical.choose h else 0 + have Hi:∀ᶠ k in atTop,S k (i k):=by + filter_upwards [hsel] with k hk + change ∃j,S k j at hk + dsimp only [i] + rw [dite_eq_left hk] + exact Classical.choose_spec hk + obtain ⟨σ,hσ,r,m,i₀,hr,hm,hfix,hact,hmn,hmt,hbar⟩:=J.active_subseq hb hQ i + have Hs:∀ᶠ k in atTop,S (σ k) i₀:=by + filter_upwards [hσ.tendsto_atTop.eventually Hi,hfix] with k hk hki + rwa [hki] at hk + obtain ⟨hbase,hvel,_,_⟩:=F.limit_coordinates hQ + have hbs:=hbase.comp hσ.tendsto_atTop + have hps:=hvel.comp hσ.tendsto_atTop + have hrs:=tendsto_pi_nhds.mp hr i₀ + have hms:=tendsto_pi_nhds.mp hm i₀ + have hdir:=moving_frame_outward_limit hbs hps hrs hms hμ hκ hD hν + have HD:μ ≤ m i₀ ∧ _:=hdir (by + filter_upwards [Hs] with k hk + obtain ⟨e,d,he,hep,hq,hd,hrd,hm',hmom,hdb,_,_,_⟩:=hk + exact ⟨e,d,he,hep,hq,hd,hrd,hm',hmom,hdb⟩) + have hT: Tendsto (fun k=>(v (riemannianExp + ((extChartAt 𝓘(ℝ,Model n) a).symm (b (σ k))) + (chartFiberInverse a (b (σ k)) ((J.first (σ k)).pj₀ i₀)))-α)/D) + atTop (𝓝 ((v (riemannianExp a (r i₀))-α)/D)):=by + have he:=contMDiff_riemannianExp.continuous.continuousAt.tendsto.comp (chartRay_tendsto hbs hrs) + exact ((hv.continuousAt.tendsto.comp he).sub tendsto_const_nhds).div_const D + refine ⟨σ,hσ,r,m,i₀,hr,hm,hact,hmn,hmt,hbar,HD.1,?_,?_,?_,?_,HD.2⟩ + · exact Hs.mono (fun k hk=>by obtain ⟨e,d,_,_,_,_,_,hh,_⟩:=hk; exact hh) + · apply ge_of_tendsto hT + exact Hs.mono (fun k hk=>by obtain ⟨e,d,_,_,_,_,_,_,_,_,hh,_⟩:=hk; exact hh) + · apply le_of_tendsto hT + exact Hs.mono (fun k hk=>by obtain ⟨e,d,_,_,_,_,_,_,_,_,_,hh,_⟩:=hk; exact hh.le) + · apply le_of_tendsto (ho.continuousAt.tendsto.comp hT) + exact Hs.mono (fun k hk=>by obtain ⟨e,d,_,_,_,_,_,_,_,_,_,_,hh⟩:=hk; exact hh) + +end MaximumOutwardCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPhaseCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPhaseCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce43dcc6ea96f1b3df12d6f51cf53f0b17454bd7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPhaseCompact.lean @@ -0,0 +1,61 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterCompact +import OAI.Analysis.BiholderTransport.Duality.DualCompact + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumPhaseCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +local instance maximumPhaseDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumPhaseDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumPhaseBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance maximumPhaseBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma MaximumDiagonal.center_phase_compact {J:MaximumJensenFamily hmtw hv ho F a c N} + {ε:ℕ → ℝ} {P:ℕ → ℕ → Prop} (S:MaximumDiagonal J ε P) + (hε:Tendsto ε atTop (𝓝 0)) {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (he:riemannianExp a q=c) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {C U:ℝ} (hC:0 ≤ C) (hU:0 ≤ U) + (hH:∀ᶠ k in atTop,∀d,-C*‖d‖^2 ≤ (J.first k).H d d) + (hL:∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ U*‖d‖^2) : + ∃g:Model n →L[ℝ] ℝ,∃B:Model n →L[ℝ] Model n →L[ℝ] ℝ, + ∃σ:ℕ → ℕ,StrictMono σ ∧ + Tendsto (fun i=>fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b (σ i)) Bc) (F.t (σ i)) c) + ((J.sample (σ i)).z (J.sampleIndex (σ i) (S.ν (σ i))))) atTop (𝓝 g) ∧ + Tendsto (fun i=>fderiv ℝ + (fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D (F.b (σ i)) Bc) (F.t (σ i)) c)) + ((J.sample (σ i)).z (J.sampleIndex (σ i) (S.ν (σ i))))) atTop (𝓝 B) := by + obtain ⟨B,σ,hσ,HB⟩:=S.center_compact hε hq he hQ hC hU hH hL + obtain ⟨hb,hp,hx,hg⟩:=S.limits J hε hQ he + have hz:=S.endpoint_tendsto he hb hp + obtain ⟨K,hK,HK⟩:=S.center_gradient_bound hg hz + obtain ⟨g,τ,hτ,HG⟩:=exists_dual_limit (hσ.tendsto_atTop.eventually HK) + exact ⟨g,B,σ ∘ τ,hσ.comp hτ,HG,HB.comp hτ.tendsto_atTop⟩ + +end MaximumPhaseCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..d8d9a51072547838f63e3e249f7398d8c1b1d515 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleCompact.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearCompact +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumPoleCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +local instance poleCompactDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance poleCompactDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance poleCompactBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance poleCompactBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma MaximumJensenFamily.pole_compact (J:MaximumJensenFamily hmtw hv ho F a c N) + {U:ℝ} (hU:0 ≤ U) (hL:∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ U*‖d‖^2) : + ∃L:Model n →L[ℝ] Model n →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ + Tendsto (fun k=>(J.first (σ k)).L) atTop (𝓝 L) := by + apply exists_bilinear_limit (Bj:=fun k=>(J.first k).L) (C:=U) + filter_upwards [hL] with k hk + apply symmetric_bilinear_norm_bound (J.first k).symmetric hU + intro d + rw [abs_of_nonneg ((J.first k).positive d)] + exact hk d + +lemma MaximumJensenFamily.pole_limit_properties (J:MaximumJensenFamily hmtw hv ho F a c N) + {L:Model n →L[ℝ] Model n →L[ℝ] ℝ} {q:Model n} + {r:Fin (Module.finrank ℝ (Model n)+1) → Model n} + (hL:Tendsto (fun k=>(J.first k).L) atTop (𝓝 L)) + (hp:Tendsto (fun k=>graphVelocityCoordinate a (F.row k).q.1) atTop (𝓝 q)) + (hr:Tendsto (fun k=>(J.first k).pj₀) atTop (𝓝 r)) : + (∀d,0 ≤ L d d) ∧ (∀d e,L d e=L e d) ∧ (∀i d,L (r i-q) d=0) := by + refine ⟨bilinear_limit_nonneg hL (Eventually.of_forall (fun k=>(J.first k).positive)), + bilinear_limit_symm hL (Eventually.of_forall (fun k=>(J.first k).symmetric)),?_⟩ + intro i d + exact bilinear_limit_kernel hL ((tendsto_pi_nhds.mp hr i).sub hp) + (Eventually.of_forall (fun k=>(J.first k).kernel i)) d +end MaximumPoleCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleSymmetric.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleSymmetric.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0f3286b6f4f025155d36549ad15b9c52ba20fa6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumPoleSymmetric.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MaximumJensenFamily +import OAI.Analysis.BiholderTransport.Regularity.MaximumSample +import OAI.Analysis.BiholderTransport.Regularity.MaximumReindex + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MaximumPoleSymmetric +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +lemma MaximumJensenFamily.sample_pole_symmetric (J:MaximumJensenFamily hmtw hv ho F a c N) + (k:ℕ) : ∀ᶠ j in atTop,∀d e:Model n,J.sampleL k j d e=J.sampleL k j e d := by + let χ:=extChartAt 𝓘(ℝ,Model n) c + let v0:=modifiedDatum v α D (F.b k) Bo + have hv0:=continuous_modifiedDatum hv α D (F.b k) ho + have ht:=(F.prefixTime k).1 + have ht1:=(F.prefixTime k).2 + have hσ:=(J.first k).strictMono.tendsto_atTop + obtain ⟨hQ,hb,hp⟩:=(F.row k).jensen_graph_limit hmtw hv ho ht ht1 + (J.sample k) (J.endpointSource k) (J.poleSource k) + have hbase: Tendsto (fun j=>(J.samplePoint k j).1.1) atTop (𝓝 (F.row k).q.1.1) := + (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto (F.row k).q.1 + |>.comp (hQ.comp hσ) + have ha:=hbase.eventually ((isOpen_extChartAt_source _).mem_nhds (J.poleSource k)) + have hd:=hbase.eventually ((isOpen_extChartAt_source (F.row k).q.1.1).mem_nhds + (mem_extChartAt_source (I := 𝓘(ℝ,Model n)) (F.row k).q.1.1)) + have hz:=((J.sample k).points.comp hσ).eventually ((isOpen_extChartAt_target c).mem_nhds + (χ.map_source (J.endpointSource k))) + have hpole:chartActualPole v0 (F.t k) c (χ (F.z k))=(F.row k).q.1.1 := by + dsimp only [chartActualPole] + rw [χ.left_inv (J.endpointSource k)] + rw [←hmtw.graphHomeomorph_inverse_pole hv0 ht ht1 (F.z k)] + exact congrArg (fun q=>q.1.1) ((F.row k).graph_inverse hmtw hv ho ht ht1) + filter_upwards [ha,hd,hz] with j haj hdj hzj + let q:=J.samplePoint k j + let b:=graphBaseCoordinate a q.1 + let p:=graphVelocityCoordinate a q.1 + have hbt:b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source haj + have he:movingPrefix a (F.t k) b p=graphProjection (cTransform v0) (F.t k) q := + movingPrefix_graph_coordinates haj (F.t k) + have hec:χ (movingPrefix a (F.t k) b p)=(J.sample k).z (J.sampleIndex k j) := by + rw [he,J.sampleProjection] + exact χ.right_inv hzj + have hs:movingPrefix a (F.t k) b p∈χ.source := by + rw [he,J.sampleProjection] + exact χ.map_target hzj + have hbd:(extChartAt 𝓘(ℝ,Model n) a).symm b∈ + (extChartAt 𝓘(ℝ,Model n) (F.row k).q.1.1).source := by + change (extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a q.1.1)∈_ + rw [(extChartAt 𝓘(ℝ,Model n) a).left_inv haj] + exact hdj + have hD: DifferentiableAt ℝ (fun w:Model n=>extChartAt 𝓘(ℝ,Model n) (F.row k).q.1.1 + (hopfPole (n := n) (F.t k) (cTransform v0) (χ.symm w))) + (χ (movingPrefix a (F.t k) b p)) := by + rw [hec,←hpole] + exact ((J.sample k).samples (J.sampleIndex k j)).2.2.2.2.2.1.differentiableAt + exact (hmtw.coordinate_sample_pole_matrix hv0 ht ht1 hbt + (graphCoordinate_normalSubdifferential q haj) hs hbd hD).2.1 + +end MaximumPoleSymmetric +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumReindex.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumReindex.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc5042dfe48e43715309a90809f047b0871f0822 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumReindex.lean @@ -0,0 +1,78 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumDiagonal + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumReindex +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {v : M → ℝ} {α D bminus bplus : ℝ} {Bc Bo : ℝ → ℝ} + {hmtw : WeakMTW (n := n) (M := M)} {hv : Continuous v} {ho : Continuous Bo} + {F : MaximumFamily (n := n) v α D bminus bplus Bc Bo} {a c : M} {N : Set (Model n)} + +def MaximumJensenFamily.comp (J : MaximumJensenFamily hmtw hv ho F a c N) + (σ : ℕ → ℕ) (hσ : Tendsto σ atTop atTop) : + MaximumJensenFamily hmtw hv ho (F.comp σ hσ) a c N where + poleSource k := J.poleSource (σ k) + endpointSource k := J.endpointSource (σ k) + sample k := J.sample (σ k) + first k := J.first (σ k) + +def MaximumDiagonal.comp {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) + (σ : ℕ → ℕ) (hσ : Tendsto σ atTop atTop) : + MaximumDiagonal (J.comp σ hσ) (ε ∘ σ) (fun k j=>P (σ k) j) where + ν := S.ν ∘ σ + poleSource k := S.poleSource (σ k) + chart k := S.chart (σ k) + baseClose k := S.baseClose (σ k) + velocityClose k := S.velocityClose (σ k) + centerClose k := S.centerClose (σ k) + gradientClose k := S.gradientClose (σ k) + HClose k := S.HClose (σ k) + LClose k := S.LClose (σ k) + activeClose k := S.activeClose (σ k) + weightClose k := S.weightClose (σ k) + extra k := S.extra (σ k) + +lemma MaximumJensenFamily.sampleProjection (J : MaximumJensenFamily hmtw hv ho F a c N) + (k j:ℕ) : + graphProjection (cTransform (modifiedDatum v α D (F.b k) Bo)) (F.t k) + (J.samplePoint k j)= + (extChartAt 𝓘(ℝ,Model n) c).symm ((J.sample k).z (J.sampleIndex k j)) := by + exact (hmtw.graphHomeomorph (continuous_modifiedDatum hv α D (F.b k) ho) + (F.prefixTime k).1 (F.prefixTime k).2).apply_symm_apply _ + +lemma MaximumDiagonal.endpointSource {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) (k:ℕ) : + graphProjection (cTransform (modifiedDatum v α D (F.b k) Bo)) (F.t k) + (J.samplePoint k (S.ν k))∈(extChartAt 𝓘(ℝ,Model n) c).source := by + rw [J.sampleProjection] + exact (extChartAt 𝓘(ℝ,Model n) c).map_target (S.chart k) + +lemma MaximumDiagonal.endpointChart {J : MaximumJensenFamily hmtw hv ho F a c N} + {ε : ℕ → ℝ} {P : ℕ → ℕ → Prop} (S : MaximumDiagonal J ε P) (k:ℕ) : + extChartAt 𝓘(ℝ,Model n) c + (graphProjection (cTransform (modifiedDatum v α D (F.b k) Bo)) (F.t k) + (J.samplePoint k (S.ν k)))=(J.sample k).z (J.sampleIndex k (S.ν k)) := by + rw [J.sampleProjection] + exact (extChartAt 𝓘(ℝ,Model n) c).right_inv (S.chart k) + +end MaximumReindex +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumRow.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumRow.lean new file mode 100644 index 0000000000000000000000000000000000000000..9f4532f6b5c084dd07ecc9dbe066c3afd3bc31a8 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumRow.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.GraphInverse +import OAI.Analysis.BiholderTransport.Regularity.MaximumConfiguration + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +structure MaximumRow (v : M → ℝ) (a D b bplus t : ℝ) (Bc Bo : ℝ → ℝ) (z : M) where + q : subgradientGraph (n := n) (cTransform (modifiedDatum v a D b Bo)) + minimizing : q.1.2∈minimizingVectors q.1.1 + projection : graphProjection (cTransform (modifiedDatum v a D b Bo)) t q=z + activeHull : q.1.2∈convexHull ℝ (activeLogs (modifiedDatum v a D b Bo) q.1.1) + center : ∀ w,hopfLax (1-t) (modifiedDatum v a D b Bc) z= + modifiedDatum v a D b Bc w+cost w z/(1-t) ↔ w=riemannianExp q.1.1 q.1.2 + value : regularizedComparison v a D bplus t Bc Bo (b,z)= + modifiedExcess v a D b Bc Bo (riemannianExp q.1.1 q.1.2)-parameterPenalty bplus b + parameter : ∀ (ι : Type) [Fintype ι] [Nonempty ι] + (pj : ι → TangentSpace 𝓘(ℝ,Model n) q.1.1) (weights : ι → ℝ), + (∀ i,0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumRow.jensen_graph_limit {v : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {z a c : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + (hmtw : WeakMTW (n := n) (M := M)) (hv : Continuous v) (ho : Continuous Bo) + (ht : 0e.symm (χ.symm (J.z j)) + Tendsto (fun j=>(q j).1) atTop (𝓝 R.q.1) ∧ + Tendsto (fun j=>graphBaseCoordinate a (q j).1) atTop (𝓝 (graphBaseCoordinate a R.q.1)) ∧ + Tendsto (fun j=>graphVelocityCoordinate a (q j).1) atTop (𝓝 (graphVelocityCoordinate a R.q.1)) := by + dsimp only + let χ := extChartAt 𝓘(ℝ,Model n) c + let e := hmtw.graphHomeomorph (continuous_modifiedDatum hv α D b ho) ht ht1 + let q := fun j=>e.symm (χ.symm (J.z j)) + have HC := (continuousAt_extChartAt_symm'' (χ.map_source hc)).tendsto.comp J.points + rw [χ.left_inv hc] at HC + have H := (e.symm.continuous.tendsto z).comp HC + rw [R.graph_inverse hmtw hv ho ht ht1] at H + have Hq := continuous_subtype_val.tendsto R.q |>.comp H + let χa := extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hs : R.q.1∈χa.source := (tangent_chart_source_iff _ _).mpr ha + have Hchart := ((continuousOn_extChartAt _).continuousAt ((isOpen_extChartAt_source _).mem_nhds hs)).tendsto.comp Hq + exact ⟨Hq,Hchart.fst_nhds,Hchart.snd_nhds⟩ + +lemma MaximumRow.jensen_approximation {v : M → ℝ} {α D b bplus t : ℝ} + {Bc Bo : ℝ → ℝ} {z a c : M} (R : MaximumRow (n := n) v α D b bplus t Bc Bo z) + (hmtw : WeakMTW (n := n) (M := M)) (hv : Continuous v) (ho : Continuous Bo) + (ht : 0e.symm (χ.symm (J.z j)) + ∀ P:ChartFixedPrefixLimit a (modifiedDatum v α D b Bo) + (hopfLax (1-t) (modifiedDatum v α D b Bc)) t q R.q, + ∀ ε:ℝ,0<ε → ∀ W:ℕ → Prop,(∀ᶠ j in atTop,W j) → + ∃ j:ℕ, + (q (P.σ j)).1.1∈(extChartAt 𝓘(ℝ,Model n) a).source ∧ + J.z (P.σ j)∈χ.target ∧ + dist (graphBaseCoordinate a (q (P.σ j)).1) (graphBaseCoordinate a R.q.1)<ε ∧ + dist (graphVelocityCoordinate a (q (P.σ j)).1) (graphVelocityCoordinate a R.q.1)<ε ∧ + dist (χ (J.Y (J.z (P.σ j)))) (χ (riemannianExp R.q.1.1 R.q.1.2))<ε ∧ + ‖fderiv ℝ (chartOuterEnvelope (modifiedDatum v α D b Bo) t c) (J.z (P.σ j))+ + fderiv ℝ (chartCenterEnvelope (modifiedDatum v α D b Bc) t c) (J.z (P.σ j))‖<ε ∧ + ‖coordinateCenterMatrix a t (hopfLax (1-t) (modifiedDatum v α D b Bc)) + (graphBaseCoordinate a (q (P.σ j)).1) (graphVelocityCoordinate a (q (P.σ j)).1)-P.H‖<ε ∧ + ‖coordinatePoleMatrix a t (modifiedDatum v α D b Bo) + (graphBaseCoordinate a (q (P.σ j)).1) (graphVelocityCoordinate a (q (P.σ j)).1)-P.L‖<ε ∧ + dist (P.pj j) P.pj₀<ε ∧ dist (P.w j) P.w₀<ε ∧ W j := by + dsimp only + intro P ε hε W hW + let : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance + let : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + obtain ⟨Hq,Hb,Hp⟩ := R.jensen_graph_limit hmtw hv ho ht ht1 J hc ha + have hσ := P.strictMono.tendsto_atTop + have Hbase := (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto R.q.1 + |>.comp (Hq.comp hσ) + have Ha := Hbase.eventually ((isOpen_extChartAt_source _).mem_nhds ha) + have Ht := (J.points.comp hσ).eventually ((isOpen_extChartAt_target _).mem_nhds + ((extChartAt 𝓘(ℝ,Model n) c).map_source hc)) + have HB := (Hb.comp hσ).eventually (Metric.ball_mem_nhds _ hε) + have HP := (Hp.comp hσ).eventually (Metric.ball_mem_nhds _ hε) + have HY := ((R.jensen_center_limit J hc).comp hσ).eventually (Metric.ball_mem_nhds _ hε) + have HG := (J.gradients.comp hσ).eventually (Metric.ball_mem_nhds _ hε) + have HH := P.HLimit.eventually (Metric.ball_mem_nhds P.H hε) + have HL := P.LLimit.eventually (Metric.ball_mem_nhds P.L hε) + have Hi := P.pjLimit.eventually (Metric.ball_mem_nhds _ hε) + have Hw := P.wLimit.eventually (Metric.ball_mem_nhds _ hε) + have Hall := Ha.and (Ht.and (HB.and (HP.and (HY.and (HG.and (HH.and (HL.and (Hi.and (Hw.and hW))))))))) + obtain ⟨j,hj⟩ := Hall.exists + exact ⟨j,hj.1,hj.2.1,hj.2.2.1,hj.2.2.2.1,hj.2.2.2.2.1, + by simpa only [Metric.mem_ball,Function.comp_apply,dist_zero_right] using hj.2.2.2.2.2.1, + by simpa only [Metric.mem_ball,Function.comp_apply,dist_eq_norm] using hj.2.2.2.2.2.2.1, + by simpa only [Metric.mem_ball,Function.comp_apply,dist_eq_norm] using hj.2.2.2.2.2.2.2.1, + hj.2.2.2.2.2.2.2.2.1,hj.2.2.2.2.2.2.2.2.2.1,hj.2.2.2.2.2.2.2.2.2.2⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSelectionCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSelectionCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..8fad897c71e5e721d39d062bfb421e8497c76627 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSelectionCompact.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumPoleCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumOutward +import OAI.Analysis.BiholderTransport.Regularity.MaximumOutwardCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumOuterBound + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section MaximumSelectionCompact +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma MaximumJensenFamily.selected_pole_compact + {hmtw:WeakMTW (n:=n) (M:=M)} {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {x0:M} + {uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)} (huv:uv∈densityDualClass (metricVolume n) lam cap x0) + {α D bminus bplus H:ℝ} {Bc Bo:ℝ → ℝ} (ho:ContDiff ℝ ∞ Bo) + {F:MaximumFamily (n:=n) uv.2 α D bminus bplus Bc Bo} + {a c:M} {N:Set (Model n)} + (J:MaximumJensenFamily hmtw uv.2.continuous ho.continuous F a c N) + (hd:IsCostDualPair (uv.1:M → ℝ) uv.2) + (hm:0 ≤ bminus) (hp:0 < bplus) (hprofiles:∀s,Bc s ≤ Bo s) + (hob:∀s,0 ≤ Bo s ∧ Bo s ≤ H) (hcb:∀s,-1 ≤ Bc s ∧ Bc s ≤ 1) + (hright:∀s,3/4 ≤ s → Bc s ≤ 0) + {q:Model n} {β:ℝ} (hβ:Tendsto F.b atTop (𝓝 β)) + (hQ:Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M))) + {A C:ℝ} (hA:0 < A) (hC:C < 0) + (hH:∀ε:ℝ,0 < ε → ∀ᶠ k in atTop,∀d:Model n, + A*‖show TangentSpace 𝓘(ℝ,Model n) a from d‖^2+ + C*(inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) d)^2-ε*‖d‖^2 ≤ (J.first k).H d d) + {eta delta zeta a0:ℝ} (hD:0 < D) (ha0:0 < a0) (hqa:2*(-C)*a0*D ≤ A) + (heta:eta ≤ 1/128) (hdelta:delta ≤ zeta) (hdeltaEta:delta ≤ eta) (hzeta:zeta ≤ 1/16) + (hleft:∀s,s < 1-eta → 1 ≤ Bo s) + (herror:∀k,2*(H+2)*F.b k ≤ zeta*D) + (hosc:∀k,sectionOscillation uv.1 uv.2 (F.row k).q.1.1 ((H+2)*F.b k) ≤ (1+delta)*D) + (hmono:∀b∈Icc bminus bplus,StrictMono (fun s=>modifiedScalar α D Bo (b,s))) + (hmargin:∀s:ℝ,-2*eta ≤ s → s ≤ 1-eta → + Bo s ≤ 12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) → + 1 < deriv (fun z=>modifiedScalar α D Bo (β,z)) (α+D*s) ∧ + iteratedDeriv 2 (fun z=>modifiedScalar α D Bo (β,z)) (α+D*s)<0) : + ∃σ:ℕ → ℕ,StrictMono σ ∧ + ∃r:Fin (Module.finrank ℝ (Model n)+1) → Model n, + ∃m:Fin (Module.finrank ℝ (Model n)+1) → ℝ, + ∃L:Model n →L[ℝ] Model n →L[ℝ] ℝ,∃CL:ℝ,0 ≤ CL ∧ + ∃i:Fin (Module.finrank ℝ (Model n)+1), + Tendsto (fun k=>(J.first (σ k)).pj₀) atTop (𝓝 r) ∧ + Tendsto (fun k=>(J.first (σ k)).w₀) atTop (𝓝 m) ∧ + Tendsto (fun k=>(J.first (σ k)).L) atTop (𝓝 L) ∧ + (∀ᶠ k in atTop,∀d,(J.first (σ k)).L d d ≤ CL*‖d‖^2) ∧ + (∀j,(show TangentSpace 𝓘(ℝ,Model n) a from r j)∈minimizingVectors a) ∧ + (∀j,0 ≤ m j) ∧ ∑j,m j=1 ∧ ∑j,m j • r j=q ∧ + (1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)) ≤ m i ∧ + -2*eta ≤ (uv.2 (riemannianExp a (r i))-α)/D ∧ + (uv.2 (riemannianExp a (r i))-α)/D ≤ 1-eta ∧ + Bo ((uv.2 (riemannianExp a (r i))-α)/D) ≤ 12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) ∧ + ∃e:TangentSpace 𝓘(ℝ,Model n) a,∃d:ℝ,‖e‖=1 ∧ 0 < d ∧ + (show TangentSpace 𝓘(ℝ,Model n) a from r i)= + (show TangentSpace 𝓘(ℝ,Model n) a from q)+d • e ∧ + 0 < inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e ∧ + a0*D ≤ (inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e)^2 ∧ + ‖show TangentSpace 𝓘(ℝ,Model n) a from r i‖^2- + ‖show TangentSpace 𝓘(ℝ,Model n) a from q‖^2 ≤ (3+9/(4*a0))*D := by + have hsel:=J.eventual_outward uv.1.continuous hd hm hp hprofiles hob hcb hright hQ hA hC + hH hD ha0 hqa heta hdelta hdeltaEta hzeta hleft herror hosc + let μ:ℝ:=(1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)) + let ν:ℝ:=(1/4096)/(8*(Module.finrank ℝ (Model n)+1:ℝ)) + have hμ:0 < μ:=by dsimp [μ]; positivity + have hν:0 < ν:=by dsimp [ν]; positivity + obtain ⟨σ,hσ,r,m,i,hr,hm',ha,hmn,hmt,hbar,hmi,hmi',hs,hs',hcapO,e,d,he,hd',hri,hpe,hpD,hmom,hdmax,hgap⟩:= + J.active_outward_compact hβ hQ hμ hν ha0 hD (by + filter_upwards [hsel] with k hk + obtain ⟨e,i,d,he,hpe,hpD,hd,hri,hmi,hmom,hdmax,hs,hs',hcapO⟩:=hk + refine ⟨i,e,d,he,hpe,hpD,hd,hri,hmi,?_,hdmax,hs,hs',hcapO⟩ + dsimp only [ν] + convert! hmom using 1 + simp only [div_eq_mul_inv,mul_inv_rev] + ring) + have hβmem:β∈Icc bminus bplus:=isClosed_Icc.mem_of_tendsto hβ + (Eventually.of_forall (fun k=>Ioo_subset_Icc_self (F.parameter k))) + have hz:α+D*((uv.2 (riemannianExp a (r i))-α)/D)=uv.2 (riemannianExp a (r i)):=by + field_simp [hD.ne'] + ring + have hmar:=hmargin _ hs hs' hcapO + rw [hz] at hmar + let J':=J.comp σ hσ.tendsto_atTop + obtain ⟨CL,hCL,HCL⟩:=J'.outer_bound hlam hcap huv ho (hβ.comp hσ.tendsto_atTop) + ((F.limit_coordinates hQ).1.comp hσ.tendsto_atTop) (fun _=>i) + (tendsto_pi_nhds.mp hr i) hμ hmi' + (fun k=>hmono _ (Ioo_subset_Icc_self (F.parameter (σ k)))) (hmono β hβmem) hmar.1 hmar.2 + obtain ⟨L,τ,hτ,hL⟩:=J'.pole_compact hCL HCL + refine ⟨σ ∘ τ,hσ.comp hτ,r,m,L,CL,hCL,i,hr.comp hτ.tendsto_atTop, + hm'.comp hτ.tendsto_atTop,hL,hτ.tendsto_atTop.eventually HCL,?_,hmn,hmt,hbar,hmi, + hs,hs',hcapO,e,d,he,hd',hri,hpe,hpD,hgap⟩ + intro j + exact (ha j).1 + +end MaximumSelectionCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSimultaneous.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSimultaneous.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed8eb6bf468ea37faf72bf9605504f4a8ef24e93 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumSimultaneous.lean @@ -0,0 +1,168 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MaximumPhaseCompact +import OAI.Analysis.BiholderTransport.Regularity.MaximumTrueCenter +import OAI.Analysis.BiholderTransport.Regularity.MaximumOuterSamples +import OAI.Analysis.BiholderTransport.Regularity.MaximumTrueOuter +import OAI.Analysis.BiholderTransport.Regularity.MaximumPoleCompact +import OAI.Analysis.BiholderTransport.LinearAlgebra.FunctionalCoercive +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section MaximumSimultaneous +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance simulDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance simulDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance simulBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance simulBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma WeakMTW.exists_maximum_simultaneous + (hmtw:WeakMTW (n:=n) (M:=M)) (hn:0 < n) {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) : + ∃δ:ℝ,δ>0 ∧ ∃K:ℝ,K>0 ∧ ∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)),uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀Lv:ℝ≥0,LipschitzWith Lv (uv.2:M → ℝ) → IsCostDualPair (uv.1:M → ℝ) uv.2 → + ∀(α D bminus bplus A₀ B₀:ℝ) (Bc Bo:ℝ → ℝ), + ∀ho:Continuous Bo,ContDiff ℝ ∞ Bc → ContDiff ℝ ∞ Bo → + (∀b∈Icc bminus bplus,Monotone (fun s=>modifiedScalar α D Bc (b,s))) → + (∀b∈Icc bminus bplus,StrictMono (fun s=>modifiedScalar α D Bo (b,s))) → + (∀y,uv.2 y∈Icc A₀ B₀) → + (∀b∈Icc bminus bplus,∀y:M,0 < deriv (fun s=>modifiedScalar α D Bc (b,s)) (uv.2 y) ∧ + deriv (fun s=>modifiedScalar α D Bc (b,s)) (uv.2 y)<1) → + ∀Klip:ℝ≥0,(∀b∈Icc bminus bplus,LipschitzWith Klip (modifiedDatum uv.2 α D b Bc)) → + ∀F:MaximumFamily (n:=n) uv.2 α D bminus bplus Bc Bo, + ∀(a c:M) (χ:ℝ) (N:Set (Model n)) (r₀:ℝ),0 < χ → 0 < r₀ → + (∀z∈ball (extChartAt 𝓘(ℝ,Model n) c c) r₀,z∉N → + OriginalCenterGood (n:=n) uv.1 χ ((extChartAt 𝓘(ℝ,Model n) c).symm z) ∧ + ∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>uv.2 ((extChartAt 𝓘(ℝ,Model n) c).symm (z+h))) p A) → + ∀J:MaximumJensenFamily hmtw uv.2.continuous ho F a c N, + ∀(q:Model n) (β l κc:ℝ), + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a → riemannianExp a q=c → + Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto F.b atTop (𝓝 β) → deriv (fun s=>modifiedScalar α D Bc (β,s)) (uv.2 c)=l → + iteratedDeriv 2 (fun s=>modifiedScalar α D Bc (β,s)) (uv.2 c)=κc → + l∈U → 0 < l → l<1 → κc<0 → + ∀(r:Fin (Module.finrank ℝ (Model n)+1) → Model n) + (m:Fin (Module.finrank ℝ (Model n)+1) → ℝ) + (L:Model n →L[ℝ] Model n →L[ℝ] ℝ), + Tendsto (fun k=>(J.first k).pj₀) atTop (𝓝 r) → + Tendsto (fun k=>(J.first k).w₀) atTop (𝓝 m) → + Tendsto (fun k=>(J.first k).L) atTop (𝓝 L) → + ∀CH CL:ℝ,0 ≤ CH → 0 ≤ CL → + (∀ᶠ k in atTop,∀d,-CH*‖d‖^2 ≤ (J.first k).H d d) → + (∀ᶠ k in atTop,∀d,(J.first k).L d d ≤ CL*‖d‖^2) → + ∀i,(show TangentSpace 𝓘(ℝ,Model n) a from r i)∈minimizingVectors a → + 0 < m i → ∀(e:TangentSpace 𝓘(ℝ,Model n) a) (t lo κo:ℝ), + ‖e‖=1 → 0 < t → (show TangentSpace 𝓘(ℝ,Model n) a from r i)= (show TangentSpace 𝓘(ℝ,Model n) a from q)+t • e → + 0 < inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e → + deriv (fun s=>modifiedScalar α D Bo (β,s)) (uv.2 (riemannianExp a (r i)))=lo → + iteratedDeriv 2 (fun s=>modifiedScalar α D Bo (β,s)) (uv.2 (riemannianExp a (r i)))=κo → + 1 < lo → κo<0 → + ∃rc:Model n,(show TangentSpace 𝓘(ℝ,Model n) c from rc)∈minimizingVectors c ∧ + reverseRay (⟨c,l • rc⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩ ∧ + ∃V W:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0 < V d d) ∧ + (∀d e,W d e=W e d) ∧ (∀d,d≠0 → 0 < W d d) ∧ + 0 < expJacobian c rc ∧ + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n* + (expJacobian a q)^2*χ≤expJacobian c rc*(bilinearOperator V).det ∧ + expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (lo⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2)*(bilinearOperator W).det ≤ + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*lo^n*K* + (expJacobian (n:=n) a (r i))^2 ∧ + (-κo/lo^2)*(m i)^(n-1)*(bilinearOperator V).det≤(-κc/l^2)*(bilinearOperator W).det := by + classical + let : NeZero n:=⟨Nat.ne_of_gt hn⟩ + obtain ⟨δ,hδ,U,hU,h1,HC⟩:=exists_maximum_true_center (n:=n) (M:=M) + obtain ⟨K,hK,HO⟩:=hmtw.exists_maximum_true_outer hlam hcap + refine ⟨δ,hδ,K,hK,U,hU,h1,?_⟩ + intro x0 uv huv Lv hv hd α D bminus bplus A₀ B₀ Bc Bo ho hBc hBo hmono hmonoO + hrange hslope Klip hLip F a c χ N r₀ hχ hr₀ hgood J q β l κc hq he hQ hβ hdC hddC + hlu hl hl1 hκc r m L hr hm hL CH CL hCH hCL hH hCLbd i hri hmi e t lo κo he1 ht hriq + hqe hdO hddO hlo hκo + let ε:=fun k:ℕ=>1/((k:ℝ)+1) + have hε:Tendsto ε atTop (𝓝 0):=tendsto_one_div_add_atTop_nhds_zero_nat + obtain ⟨S⟩:=J.exists_outer_diagonal (show ∀k,0 < ε k by intro k; dsimp [ε]; positivity) + have hreg:=J.center_regular uv.1.continuous hv hd hBc hmono Klip hLip hq he hQ hβ hdC hl hl1 + obtain ⟨g,H,σ,hσ,hg,hHs⟩:=S.center_phase_compact hε hreg he hQ hCH hCL hH hCLbd + let σt:=hσ.tendsto_atTop + let J':=J.comp σ σt + let S':=S.comp σ σt + obtain ⟨rc,hrc,hrev,V,hVs,hVp,hgain,hσc,hdetC⟩:=HC uv.1 uv.2 uv.1.continuous Lv hv hd + α D bminus bplus A₀ B₀ Bc Bo ho hBc hmono hrange hslope Klip hLip hmtw + (F.comp σ σt) a c χ N r₀ hχ hr₀ hgood J' (ε ∘ σ) _ S' (hε.comp σt) + q β l hq he (hQ.comp σt) (hβ.comp σt) hdC hlu hl hl1 g H L hg hHs (hL.comp σt) + obtain ⟨_,hp,_,_⟩:=F.limit_coordinates hQ + obtain ⟨hLp,hLs,hker⟩:=J.pole_limit_properties hL hp hr + have hke:∀d:Model n,L (show Model n from e) d=0:=by + intro d + have hh:=hker i d + have hriq' : r i = q+t • (show Model n from e) := hriq + have heq:r i-q=t • (show Model n from e):=by + rw [hriq',add_sub_cancel_left] + rw [heq,map_smul,smul_apply,smul_eq_mul] at hh + exact (mul_eq_zero.mp hh).resolve_left ht.ne' + let f:=frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) q + let gO:=frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) (r i) + have hf:0 < f (show Model n from e):=by + calc + 0 < inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e := hqe + _ = f (show Model n from e) := (frameMetric_center a q (show Model n from e)).symm + have hfg:f (show Model n from e)≤gO (show Model n from e):=by + calc + f (show Model n from e) = inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from q) e := + frameMetric_center a q (show Model n from e) + _ ≤ inner ℝ (show TangentSpace 𝓘(ℝ,Model n) a from r i) e := by + rw [hriq,inner_add_left,inner_smul_left,real_inner_self_eq_norm_sq,he1] + simp only [one_pow,mul_one,starRingEnd_apply,star_trivial] + linarith only [ht] + _ = gO (show Model n from e) := (frameMetric_center a (r i) (show Model n from e)).symm + have hVL:∀d:Model n,V d d≤L d d+(-κc/l^2)*(f d)^2:=by + intro d + have HH:=hgain d + rw [hddC] at HH + have hpG:0 ≤ δ*(1-l)*frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) d d:=by + rw [frameMetric_center,real_inner_self_eq_norm_sq] + positivity + dsimp only [f] + simp only [neg_div, neg_mul] + linarith only [HH,hpG] + have hbc:0 < -κc/l^2:=div_pos (neg_pos.mpr hκc) (sq_pos_of_pos hl) + have hbo:0 < -κo/lo^2:=div_pos (neg_pos.mpr hκo) (sq_pos_of_pos (zero_lt_one.trans hlo)) + have hbase:=functional_rank_one_positive hLs hLp hVp hVL hke hf.ne' + (hf.trans_le hfg).ne' hmi hbo + obtain ⟨W,hWs,hWp,hW,hdetO⟩:=HO x0 uv huv α D bminus bplus Bc Bo ho hBo hmonoO + (F.comp σ σt) a c N J' (ε ∘ σ) S' (hε.comp σt) q β he (hQ.comp σt) (hβ.comp σt) + r m L (hr.comp σt) (hm.comp σt) (hL.comp σt) i hri hmi lo κo hdO hddO hlo hκo (by + intro d hd + have HH:=hbase d hd + dsimp only [gO] at HH + simpa only [neg_div, neg_mul, sub_eq_add_neg] using HH) + have hdet:=bilinear_determinant_gain hLs hVs hWs hke hf hfg hmi hbc hbo hVp hVL (by + intro d + have HH:=hW d + dsimp only [gO] + simpa only [neg_div, neg_mul, sub_eq_add_neg] using HH) + refine ⟨rc,hrc,hrev,V,W,hVs,hVp,hWs,hWp,hσc,hdetC,hdetO,?_⟩ + simpa only [Model,finrank_euclideanSpace,Fintype.card_fin] using hdet +end MaximumSimultaneous +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTemplateBound.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTemplateBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..d56f7035b0d5d742d2f7575847262d19e2802281 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTemplateBound.lean @@ -0,0 +1,203 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.OriginalNullSet +import OAI.Analysis.BiholderTransport.Regularity.MaximumSimultaneous +import OAI.Analysis.BiholderTransport.LinearAlgebra.FrameDeterminantClosure +import OAI.Analysis.BiholderTransport.Regularity.MaximumSelectionCompact +import OAI.Analysis.BiholderTransport.Regularity.OuterTemplatePrimitive +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterSign +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterLower +import OAI.Analysis.BiholderTransport.Regularity.MaximumLowerBound +import OAI.Analysis.BiholderTransport.Calculus.ScalarFamilyBounds + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle Metric MeasureTheory +open scoped Topology ContDiff NNReal BoundedContinuousFunction + +namespace WeakMTWTransport +section MaximumTemplateBound +variable {n:ℕ} {M:Type*} [MetricSpace M] [CompactSpace M] [ConnectedSpace M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x:M=>TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance templateDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance templateDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance templateBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance templateBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma WeakMTW.maximum_template_bound (hmtw:WeakMTW (n:=n) (M:=M)) + (hn:0 < n) {lam cap:ℝ} (hlam:0 < lam) (hcap:lam ≤ cap) : + ∃B:ℝ,0 < B ∧ ∃eps:ℝ,0 < eps ∧ + ∀K eta:ℝ,1 ≤ K → 0 < eta → eta ≤ 1/128 → + (let M0:ℝ:=12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) + eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) → + ∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)),uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀α D bm bp:ℝ,0 < D → 0 < bm → 0 < bp → + bp/D*centerGamma ≤ 1 → bp/D*centerGamma/2 < eps → + ∀C:ℝ,0 ≤ C → + (∀s,|deriv (outerTemplate (12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096)) K eta) s| ≤ C) → + bp/D*C ≤ 1/2 → + (∀z:M,sectionOscillation uv.1 uv.2 z + ((2*(12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096))+10)*bp) ≤ (1+eta)*D) → + 2*(2*(12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096))+10)*bp ≤ eta*D → + MaximumFamily (n:=n) uv.2 α D bm bp centerTemplate + (outerTemplate (12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096)) K eta) → + (((1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)))^(n-1)*K/(8*centerGamma^2)) ≤ B := by + classical + have hgamma:=centerGamma_pos + obtain ⟨c0,hc0,HG⟩:=exists_maximum_center_gain (n:=n) (M:=M) + obtain ⟨χ,hχ,Hχ⟩:=exists_density_original_center_good (n:=n) (M:=M) hlam hcap + obtain ⟨δ,hδ,Kd,hKd,U,hU,hU1,HS⟩:=hmtw.exists_maximum_simultaneous hn hlam (hlam.le.trans hcap) + let a0:ℝ:=c0/(16*centerGamma) + let μ:ℝ:=(1/4096)/(12*(Module.finrank ℝ (Model n)+1:ℝ)) + have ha0:0 < a0:=by dsimp [a0]; positivity + have hμ:0 < μ:=by dsimp [μ]; positivity + obtain ⟨B,hB,HB⟩:=hmtw.frame_determinant_closure hμ ha0 + (show 0 < 3+9/(4*a0) by positivity) hχ hKd + obtain ⟨eps,heps,HE⟩:=Metric.mem_nhds_iff.mp (Filter.Eventually.and (show ∀ᶠ l in 𝓝 (1:ℝ), l∈U from hU.mem_nhds hU1) HG) + refine ⟨B,hB,eps,heps,?_⟩ + intro K eta hK heta heta1 hetasmall x0 uv huv α D bm bp hD hbm hbp hcenter hclose C hC hder houter hosc herror F + let M0:ℝ:=12*(Module.finrank ℝ (Model n)+1:ℝ)/(1/4096) + let Bo:=outerTemplate M0 K eta + let H:ℝ:=2*M0+8 + have hM:2 ≤ M0:=by dsimp [M0]; have hn0:=Nat.cast_nonneg (α:=ℝ) (Module.finrank ℝ (Model n)); linarith + have hBo:ContDiff ℝ ∞ Bo:=outerTemplate_smooth _ _ _ + have hob (s):0 ≤ Bo s ∧ Bo s ≤ H:=⟨outerTemplate_nonneg hM hK heta heta1 hetasmall, + outerTemplate_upper hM hK heta heta1 hetasmall⟩ + have hprof (s):centerTemplate s ≤ Bo s:=centerTemplate_le_outer hM hK heta heta1 hetasmall + have hd:=densityDualClass_isDual huv + let Lv:ℝ≥0:=⟨Metric.diam (univ:Set M),Metric.diam_nonneg⟩ + have hv:LipschitzWith Lv (uv.2:M → ℝ):=by + rw [hd.2] + exact cTransform_lipschitz uv.1.continuous (fun x y=>Metric.dist_le_diam_of_mem + isCompact_univ.isBounded (mem_univ x) (mem_univ y)) + obtain ⟨A0,hA0⟩:=isCompact_univ.exists_bound_of_continuousOn uv.2.continuous.continuousOn + have hrange:∀y:M,uv.2 y∈Icc (-A0) A0:=fun y=>abs_le.mp (hA0 y (mem_univ y)) + have hcsmall (b:ℝ) (hb:b∈Icc bm bp): b/D*(centerGamma/2) ≤ 1/2:=by + have ht:=mul_le_mul_of_nonneg_right ((div_le_div_iff_of_pos_right hD).mpr hb.2) centerGamma_pos.le + nlinarith only [ht,hcenter] + have hosmall (b:ℝ) (hb:b∈Icc bm bp):b/D*C ≤ 1/2:= + (mul_le_mul_of_nonneg_right ((div_le_div_iff_of_pos_right hD).mpr hb.2) hC).trans houter + have hmono (b:ℝ) (hb:b∈Icc bm bp):Monotone (fun s=>modifiedScalar α D centerTemplate (b,s)):= + (modifiedScalar_strictMono centerTemplate_smooth (by positivity) hD (hbm.le.trans hb.1) + (hcsmall b hb) exact_center_deriv_abs α).monotone + have hmonoO (b:ℝ) (hb:b∈Icc bm bp):StrictMono (fun s=>modifiedScalar α D Bo (b,s)):= + modifiedScalar_strictMono hBo hC hD (hbm.le.trans hb.1) (hosmall b hb) hder α + have hLipφ (b:ℝ) (hb:b∈Icc bm bp):LipschitzWith 2 (fun s=>modifiedScalar α D centerTemplate (b,s)):= + modifiedScalar_lipschitz centerTemplate_smooth (by positivity) hD (hbm.le.trans hb.1) + (hcsmall b hb) exact_center_deriv_abs α + have hLip (b:ℝ) (hb:b∈Icc bm bp):LipschitzWith (2*Lv) (modifiedDatum uv.2 α D b centerTemplate):= + (hLipφ b hb).comp hv + have hslope (b:ℝ) (hb:b∈Icc bm bp) (y:M): + 0 < deriv (fun s=>modifiedScalar α D centerTemplate (b,s)) (uv.2 y) ∧ + deriv (fun s=>modifiedScalar α D centerTemplate (b,s)) (uv.2 y)<1:=by + refine ⟨lt_of_lt_of_le (by norm_num) + (modifiedScalar_slope_bounds centerTemplate_smooth (by positivity) hD (hbm.le.trans hb.1) + (hcsmall b hb) exact_center_deriv_abs α (uv.2 y)).1,?_⟩ + rw [modifiedScalar_deriv centerTemplate_smooth] + have H:=mul_neg_of_pos_of_neg (div_pos (hbm.trans_le hb.1) hD) (centerTemplate_deriv_neg ((uv.2 y-α)/D)) + linarith only [H] + obtain ⟨σ,hσ,β,hβmem,Q,hq,hβ,hQ⟩:=F.compact_subseq + let F1:=F.comp σ hσ.tendsto_atTop + let a:=Q.1 + let q:Model n:=Q.2 + let c:=riemannianExp a q + obtain ⟨r0,hr0,N,hN,hNt,hgood⟩:=original_chart_good_null (Hχ x0 uv huv) uv.1.continuous hd c + obtain ⟨k0,⟨J⟩⟩:=F1.eventually_jensen_first hmtw uv.1.continuous uv.2.continuous hd hBo.continuous + (modifiedScalar_contDiff centerTemplate_smooth α D) hmono hLipφ hrange hQ hN + let τ:ℕ → ℕ:=fun k=>k+k0 + have hτ:Tendsto τ atTop atTop:=tendsto_add_atTop_nat k0 + let F2:=F1.comp τ hτ + have hQ2:Tendsto (fun k=>(F2.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)):=hQ.comp hτ + have hβ2:Tendsto F2.b atTop (𝓝 β):=hβ.comp hτ + let l:=deriv (fun s=>modifiedScalar α D centerTemplate (β,s)) (uv.2 c) + let kc:=iteratedDeriv 2 (fun s=>modifiedScalar α D centerTemplate (β,s)) (uv.2 c) + have hjcenter:=J.center_limit_positive hbm.le hbp (fun s=>(hob s).1) centerTemplate_smooth.continuous rfl hQ2 + have hcentβ:β/D*centerGamma ≤ 1:= + (mul_le_mul_of_nonneg_right ((div_le_div_iff_of_pos_right hD).mpr hβmem.2) centerGamma_pos.le).trans hcenter + obtain ⟨hlhalf,hl1,hkc,hkc1,hkc2⟩:=exact_center_slope_curvature hD (hbm.trans_le hβmem.1) hcentβ + (lt_of_lt_of_le (by norm_num) hjcenter) + change -kc / l^2 ≤ 4*centerGamma*(1-l)/D at hkc2 + have hl:0 < l:=lt_of_lt_of_le (by norm_num) hlhalf + have hldist:dist l 1 < eps:=by + rw [Real.dist_eq] + apply exact_center_slope_small hD (hbm.le.trans hβmem.1) + have h:=mul_le_mul_of_nonneg_right ((div_le_div_iff_of_pos_right hD).mpr hβmem.2) centerGamma_pos.le + exact (div_le_div_of_nonneg_right h (by norm_num)).trans_lt hclose + obtain ⟨hlU,hgain⟩:=HE (show l∈ball 1 eps from hldist) + have hH:=hgain hl hl1 hmtw uv.1 uv.2 uv.1.continuous Lv hv hd α D bm bp centerTemplate Bo + hBo.continuous centerTemplate_smooth hmono (2*Lv) hLip F2 a c N J q β hq rfl hQ2 hβ2 rfl + have hqa:2*(-(kc/l^2))*a0*D ≤ c0*(1-l):=by + have H:=mul_le_mul_of_nonneg_right hkc2 (show 0 ≤ 2*a0*D by positivity) + have he:(4*centerGamma*(1-l)/D)*(2*a0*D)=c0*(1-l)/2:=by + dsimp only [a0] + field_simp [hD.ne', centerGamma_pos.ne'] + ring + rw [he] at H + have hpos:0 ≤ c0*(1-l):=mul_nonneg hc0.le (sub_nonneg.mpr hl1.le) + calc + 2*(-(kc/l^2))*a0*D = (-kc/l^2)*(2*a0*D) := by ring + _ ≤ c0*(1-l)/2 := H + _ ≤ c0*(1-l) := by linarith only [hpos] + have hmargin (s:ℝ) (hs:-2*eta ≤ s) (hs':s ≤ 1-eta) (hsM:Bo s ≤ M0): + 1 < deriv (fun z=>modifiedScalar α D Bo (β,z)) (α+D*s) ∧ + iteratedDeriv 2 (fun z=>modifiedScalar α D Bo (β,z)) (α+D*s)<0:=by + have he:(α+D*s-α)/D=s:=by field_simp [hD.ne']; ring + have hh:=exact_outer_slope_curvature hM hK heta hD (hbm.trans_le hβmem.1) hC hder + (hosmall β hβmem) (by rwa [he]) (by rwa [he]) (by rwa [he]) + exact ⟨hh.1,hh.2.2.1⟩ + have hHeq:H+2=2*M0+10:=by dsimp [H]; ring + have herr (k):2*(H+2)*F2.b k ≤ eta*D:=by + have hh:=mul_le_mul_of_nonneg_left (F2.parameter k).2.le (show 0 ≤ 2*(H+2) by dsimp [H,M0]; positivity) + apply hh.trans + simpa only [hHeq] using herror + have hbk (k):0 < F2.b k:=hbm.trans (F2.parameter k).1 + have hosc2 (k):sectionOscillation uv.1 uv.2 (F2.row k).q.1.1 ((H+2)*F2.b k) ≤ (1+eta)*D:=by + apply le_trans (sectionOscillation_mono uv.2.continuous hd _ (by have hb:=hbk k; dsimp [H,M0]; positivity) + (mul_le_mul_of_nonneg_left (F2.parameter k).2.le (show 0 ≤ H+2 by dsimp [H,M0]; positivity))) + simpa only [hHeq] using hosc (F2.row k).q.1.1 + obtain ⟨s,hs,r,m,L,CL,hCL,i,hr,hm,hL,hCLbd,hri,hmn,hmt,hbar,hmi,hsl,hsu,hcapO,e,t,he,ht,hriq,hqe,hqD,hgap⟩:= + J.selected_pole_compact hlam (hlam.le.trans hcap) huv hBo hd hbm.le hbp hprof hob + (fun s=>⟨(centerTemplate_bounds s).1.le,(centerTemplate_bounds s).2.le⟩) + (fun s hs=>(centerTemplate_right hs).le) hβ2 hQ2 + (mul_pos hc0 (sub_pos.mpr hl1)) (div_neg_of_neg_of_pos hkc (sq_pos_of_pos hl)) hH + hD ha0 hqa heta1 le_rfl le_rfl (by linarith only [heta1]) + (fun s hs=>outerTemplate_lower hM hK heta heta1 hetasmall hs.le) herr hosc2 hmonoO hmargin + let J3:=J.comp s hs.tendsto_atTop + let F3:=F2.comp s hs.tendsto_atTop + obtain ⟨CH,hCH,hCHbd⟩:=eventual_lower_bound_of_center_gain (mul_pos hc0 (sub_pos.mpr hl1)).le + (div_neg_of_neg_of_pos hkc (sq_pos_of_pos hl)).le hH + let lo:=deriv (fun z=>modifiedScalar α D Bo (β,z)) (uv.2 (riemannianExp a (r i))) + let ko:=iteratedDeriv 2 (fun z=>modifiedScalar α D Bo (β,z)) (uv.2 (riemannianExp a (r i))) + obtain ⟨hlo,hlo2,hko,hko1⟩:=exact_outer_slope_curvature hM hK heta hD + (hbm.trans_le hβmem.1) hC hder (hosmall β hβmem) hsl hsu hcapO + obtain ⟨rc,hrc,hrev,V,W,hVs,hVp,hWs,hWp,hσc,hdc,hdo,hdet⟩:=HS x0 uv huv Lv hv hd α D bm bp + (-A0) A0 centerTemplate Bo hBo.continuous centerTemplate_smooth hBo hmono hmonoO hrange hslope + (2*Lv) hLip F3 a c χ N r0 hχ hr0 hgood J3 q β l kc hq rfl + (hQ2.comp hs.tendsto_atTop) (hβ2.comp hs.tendsto_atTop) rfl rfl hlU hl hl1 hkc + r m L hr hm hL CH CL hCH hCL (hs.tendsto_atTop.eventually hCHbd) hCLbd i (hri i) + (hμ.trans_le hmi) e t lo ko he ht hriq hqe rfl rfl hlo hko + have hVdet:0 < (bilinearOperator V).det:=symmetric_det_pos (bilinearOperator_symmetric hVs) (by + intro d hd; simpa only [bilinearOperator_inner] using hVp d hd) + have hWdet:0 < (bilinearOperator W).det:=symmetric_det_pos (bilinearOperator_symmetric hWs) (by + intro d hd; simpa only [bilinearOperator_inner] using hWp d hd) + have hgainDet:=scalar_determinant_gain hμ hmi (zero_lt_one.trans_le hK) centerGamma_pos + (hbm.trans_le hβmem.1) hD hVdet.le hWdet.le hkc1 hko1 hdet + exact HB _ a c (fun j=>(show TangentSpace 𝓘(ℝ,Model n) a from r j)) m q hmn hmt hri hbar + i e t D l lo hmi he ht hD hqe hqD hgap hriq ⟨hlhalf,hl1.le⟩ hl1 ⟨hlo.le,hlo2⟩ hlo rc hrc hrev + (bilinearOperator V).det (bilinearOperator W).det (μ^(n-1)*K/(8*centerGamma^2)) hWdet + (by positivity) hdc hdo hgainDet + +end MaximumTemplateBound +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueCenter.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..09e87ac8a8beb7183216e68e79b630a5953010e2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueCenter.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CenterSequenceOriginalLimit +import OAI.Analysis.BiholderTransport.Regularity.MaximumEndpoint +import OAI.Analysis.BiholderTransport.Calculus.MaximumScalarJets +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterLimit +import OAI.Analysis.BiholderTransport.Regularity.MaximumCenterRegular + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle Metric +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section MaximumTrueCenter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance maximumTrueDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumTrueDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumTrueBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance maximumTrueBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +omit [MeasurableSpace M] [BorelSpace M] in +lemma exists_maximum_true_center : ∃δ>0,∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀(u v:M → ℝ),Continuous u → ∀Lv:ℝ≥0,∀hv:LipschitzWith Lv v, + IsCostDualPair u v → ∀(α D bminus bplus A₀ B₀:ℝ) (Bc Bo:ℝ → ℝ), + ∀ho:Continuous Bo,ContDiff ℝ ∞ Bc → + (∀b∈Icc bminus bplus,Monotone (fun s=>modifiedScalar α D Bc (b,s))) → + (∀y,v y∈Icc A₀ B₀) → + (∀b∈Icc bminus bplus,∀y:M,0modifiedScalar α D Bc (b,s)) (v y) ∧ + deriv (fun s=>modifiedScalar α D Bc (b,s)) (v y)<1) → + ∀K:ℝ≥0,(∀b∈Icc bminus bplus,LipschitzWith K (modifiedDatum v α D b Bc)) → + ∀hmtw:WeakMTW (n:=n) (M:=M), + ∀F:MaximumFamily (n:=n) v α D bminus bplus Bc Bo, + ∀(a c:M) (χ:ℝ) (N:Set (Model n)) (r₀:ℝ),0<χ → 0v ((extChartAt 𝓘(ℝ,Model n) c).symm (z+h))) p A) → + ∀J:MaximumJensenFamily hmtw hv.continuous ho F a c N, + ∀(ε:ℕ → ℝ) (P:ℕ → ℕ → Prop) (S:MaximumDiagonal J ε P), + Tendsto ε atTop (𝓝 0) → ∀(q:Model n) (β l:ℝ), + (show TangentSpace 𝓘(ℝ,Model n) a from q)∈minimizingVectors a → riemannianExp a q=c → + Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto F.b atTop (𝓝 β) → deriv (fun s=>modifiedScalar α D Bc (β,s)) (v c)=l → + l∈U → 0fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 g) → + Tendsto (fun k=>fderiv ℝ (fderiv ℝ + (chartCenterEnvelope (modifiedDatum v α D (F.b k) Bc) (F.t k) c)) + ((J.sample k).z (J.sampleIndex k (S.ν k)))) atTop (𝓝 H) → + Tendsto (fun k=>(J.first k).L) atTop (𝓝 L) → + ∃r:Model n,(show TangentSpace 𝓘(ℝ,Model n) c from r)∈minimizingVectors c ∧ + reverseRay (⟨c,l • r⟩:TangentBundle 𝓘(ℝ,Model n) M)=⟨a,q⟩ ∧ + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0modifiedScalar α D Bc (β,s)) (v c)/l^2)* + (frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) q d)^2≤L d d) ∧ + 01-F.t k) atTop (𝓝 (0:ℝ)):=by + simpa only [sub_self] using (tendsto_const_nhds.sub F.time: + Tendsto (fun k=>(1:ℝ)-F.t k) atTop (𝓝 (1-1))) + have hgood':∀ᶠ k in atTop,OriginalCenterGood (n:=n) u χ + ((extChartAt 𝓘(ℝ,Model n) c).symm (J.sampleCenter k (S.ν k))) ∧ + deriv (fun s=>modifiedScalar α D Bc (F.b k,s)) + (v ((extChartAt 𝓘(ℝ,Model n) c).symm (J.sampleCenter k (S.ν k))))=J.sampleSlope k (S.ν k) ∧ + (∀d e,inner ℝ (Sj k d) e=inner ℝ d (Sj k e)) ∧ + HasQuadraticExpansion (fun h=>modifiedScalar α D Bc (F.b k, + v ((extChartAt 𝓘(ℝ,Model n) c).symm (J.sampleCenter k (S.ν k)+h)))) (sj k) (Sj k):=by + filter_upwards [hsj] with k hk + have hY:(extChartAt 𝓘(ℝ,Model n) c).symm (J.sampleCenter k (S.ν k))= + (J.sample k).Y ((J.sample k).z (J.sampleIndex k (S.ν k))):= + (extChartAt 𝓘(ℝ,Model n) c).left_inv ((J.sample k).samples (J.sampleIndex k (S.ν k))).1 + exact ⟨hY.symm ▸ hk.1,by rw [hY]; rfl,hk.2⟩ + obtain ⟨r,hr,hrev,V,hVs,hVp,hgain,hσ,hdet⟩:=Hδ a c u v (modifiedScalar α D Bc) β l χ + hu hv.continuous hd (modifiedScalar_contDiff hBc α D) hder hlu hl hl1 hχ + _ _ _ _ _ _ _ _ _ CD q hq he hβ hlj hτ F.time hx hb + (Eventually.of_forall (fun k=>sub_pos.mpr (F.prefixTime k).2)) K + (Eventually.of_forall (fun k=>hLip _ (Ioo_subset_Icc_self (F.parameter k)))) + sj Sj g H hsg hSH hgood' + have hreg:=J.center_regular hu hv hd hBc hmono K hLip hq he hQ hβ hder hl hl1 + have hmat:=S.center_matrix_limit hε hreg he hQ hg hH + refine ⟨r,hr,hrev,V,hVs,hVp,?_,hσ,hdet⟩ + intro d + exact (hgain d).trans (S.center_matrix_le_pole_limit hε hmat hL d) +end MaximumTrueCenter +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueOuter.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueOuter.lean new file mode 100644 index 0000000000000000000000000000000000000000..f099cb49c74c6d099989e25f5f2f205ef288f5aa --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MaximumTrueOuter.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OriginalOuterLimit +import OAI.Analysis.BiholderTransport.Regularity.MaximumActiveLimits +import OAI.Analysis.BiholderTransport.Regularity.MaximumOuterSamples + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section MaximumTrueOuter +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance maximumOuterFinite (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance maximumOuterComplete (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ +local instance maximumOuterDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumOuterDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance maximumOuterBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance maximumOuterBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma WeakMTW.exists_maximum_true_outer + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) : + ∃K>0,∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀(α D bminus bplus:ℝ) (Bc Bo:ℝ → ℝ),∀ho:Continuous Bo,ContDiff ℝ ∞ Bo → + (∀b∈Icc bminus bplus,StrictMono (fun s=>modifiedScalar α D Bo (b,s))) → + ∀F:MaximumFamily (n:=n) uv.2 α D bminus bplus Bc Bo, + ∀(a c:M) (N:Set (Model n)), + ∀J:MaximumJensenFamily hmtw uv.2.continuous ho F a c N, + ∀(ε:ℕ → ℝ),MaximumDiagonal J ε J.OuterSampleGood → + Tendsto ε atTop (𝓝 0) → ∀(q:Model n) (β:ℝ),riemannianExp a q=c → + Tendsto (fun k=>(F.row k).q.1) atTop (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto F.b atTop (𝓝 β) → + ∀(r:Fin (Module.finrank ℝ (Model n)+1) → Model n) + (m:Fin (Module.finrank ℝ (Model n)+1) → ℝ) + (L:Model n →L[ℝ] Model n →L[ℝ] ℝ), + Tendsto (fun k=>(J.first k).pj₀) atTop (𝓝 r) → + Tendsto (fun k=>(J.first k).w₀) atTop (𝓝 m) → + Tendsto (fun k=>(J.first k).L) atTop (𝓝 L) → + ∀i,(show TangentSpace 𝓘(ℝ,Model n) a from r i)∈minimizingVectors a → + 0 < m i → ∀l κ:ℝ, + deriv (fun s=>modifiedScalar α D Bo (β,s)) (uv.2 (riemannianExp a (r i)))=l → + iteratedDeriv 2 (fun s=>modifiedScalar α D Bo (β,s)) (uv.2 (riemannianExp a (r i)))=κ → + 1 < l → κ < 0 → + (∀d,d≠0 → 0 < m i*L d d-(κ/l^2)* + (frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) (r i) d)^2) → + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0 < V d d) ∧ + (∀d,m i*L d d-(κ/l^2)*(frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) (r i) d)^2 ≤ V d d) ∧ + expJacobian (n:=n) (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (l⁻¹ • (reverseRay (⟨a,r i⟩:TangentBundle 𝓘(ℝ,Model n) M)).2)*(bilinearOperator V).det ≤ + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n*K* + (expJacobian (n:=n) a (r i))^2 := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_original_outer_limit hlam hcap + refine ⟨K,hK,?_⟩ + intro x0 uv huv α D bminus bplus Bc Bo ho hBo hmono F a c N J ε S hε q β he hQ hβ + r m L hr hm hL i hmin hmi l κ hd hdd hl hκ hp + obtain ⟨hb,_,_,_⟩:=S.limits J hε hQ he + obtain ⟨hri,hwi⟩:=S.active_weight_limits hε hr hm + have hLi:=S.sample_pole_limit hε hL + apply HK x0 uv (modifiedScalar α D Bo) huv (modifiedScalar_contDiff hBo α D) + a (fun k=>graphBaseCoordinate a (J.samplePoint k (S.ν k)).1) + (fun k=>(J.first k).pj (S.ν k) i) F.b (fun k=>(J.first k).w (S.ν k) i) + (fun k=>J.sampleL k (S.ν k)) β (m i) l κ (r i) L hmin hb + (tendsto_pi_nhds.mp hri i) hβ (tendsto_pi_nhds.mp hwi i) hLi hd hdd hl hκ hp + filter_upwards [(tendsto_pi_nhds.mp hwi i).eventually (lt_mem_nhds hmi)] with k hk + have hS:=S.extra k + have htarget:(graphBaseCoordinate a (J.samplePoint k (S.ν k)).1)∈ + (extChartAt 𝓘(ℝ,Model n) a).target:= + (extChartAt 𝓘(ℝ,Model n) a).map_source (S.poleSource k) + exact ⟨htarget,hmono _ (Ioo_subset_Icc_self (F.parameter k)),hS.2.2.2.1 i, + hS.2.2.1 i,hS.1,hS.2.1,hS.2.2.2.2 i hk⟩ +end MaximumTrueOuter +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MetricDefinitions.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MetricDefinitions.lean new file mode 100644 index 0000000000000000000000000000000000000000..29f8ef0c8960fff9476aa598eb958d2bb519b6e7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MetricDefinitions.lean @@ -0,0 +1,273 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder + +variable {M : Type*} [MetricSpace M] + +def cTransform (v : M → ℝ) (x : M) : ℝ := + sSup (Set.range (fun y => -cost x y - v y)) + +def IsCostDualPair (u v : M → ℝ) : Prop := + u = cTransform v ∧ v = cTransform u + +def contactGap (u v : M → ℝ) (x y : M) : ℝ := + u x + cost x y + v y + +def gapSection (u v : M → ℝ) (x : M) (r : ℝ) : Set M := + {y | contactGap u v x y ≤ r} + +lemma continuous_cost_left (y : M) : Continuous (fun x => cost x y) := by + exact ((continuous_id.dist continuous_const).pow 2).div_const 2 + +lemma continuous_cost_right (x : M) : Continuous (cost x) := by + exact ((continuous_const.dist continuous_id).pow 2).div_const 2 + +lemma cost_symm (x y : M) : cost x y = cost y x := by + simp only [cost, dist_comm] + +lemma cost_nonneg (x y : M) : 0 ≤ cost x y := by + exact div_nonneg (sq_nonneg _) (by norm_num) + +lemma cost_lipschitz_of_distance_bound {D : ℝ} + (hD : ∀ x y : M, dist x y ≤ D) (x x' y : M) : + |cost x y - cost x' y| ≤ D * dist x x' := by + have htri := abs_dist_sub_le x x' y + have hsum : 0 ≤ dist x y + dist x' y := by positivity + have hprod := mul_le_mul htri (show dist x y + dist x' y ≤ 2 * D by + linarith [hD x y, hD x' y]) hsum (dist_nonneg : 0 ≤ dist x x') + rw [cost, cost] + have heq : dist x y ^ 2 / 2 - dist x' y ^ 2 / 2 = + (dist x y - dist x' y) * (dist x y + dist x' y) / 2 := by ring + rw [heq, abs_div, abs_mul, abs_of_nonneg hsum] + norm_num + linarith + +variable [CompactSpace M] [Nonempty M] + +lemma exists_cTransform_contact {v : M → ℝ} (hv : Continuous v) (x : M) : + ∃ y, cTransform v x = -cost x y - v y ∧ + ∀ z, -cost x z - v z ≤ cTransform v x := by + obtain ⟨y, _, hy⟩ := isCompact_univ.exists_isMaxOn + Set.univ_nonempty (((continuous_cost_right x).neg.sub hv).continuousOn) + have hg : IsGreatest (Set.range (fun y => -cost x y - v y)) (-cost x y - v y) := by + refine ⟨Set.mem_range_self y, ?_⟩ + rintro a ⟨z, rfl⟩ + exact hy (Set.mem_univ z) + refine ⟨y, hg.csSup_eq, ?_⟩ + intro z + rw [cTransform, hg.csSup_eq] + exact hy (Set.mem_univ z) + +lemma cTransform_gap_nonneg {v : M → ℝ} (hv : Continuous v) (x y : M) : + 0 ≤ contactGap (cTransform v) v x y := by + obtain ⟨_, _, hmax⟩ := exists_cTransform_contact hv x + dsimp [contactGap] + linarith [hmax y] + +lemma cTransform_gap_zero {v : M → ℝ} (hv : Continuous v) (x : M) : + ∃ y, contactGap (cTransform v) v x y = 0 := by + obtain ⟨y, heq, _⟩ := exists_cTransform_contact hv x + refine ⟨y, ?_⟩ + dsimp [contactGap] + rw [heq] + ring + +lemma cTransform_lipschitz {v : M → ℝ} (hv : Continuous v) {D : ℝ≥0} + (hD : ∀ x y : M, dist x y ≤ D) : LipschitzWith D (cTransform v) := by + rw [lipschitzWith_iff_dist_le_mul] + intro x x' + rw [Real.dist_eq, abs_le] + obtain ⟨y, hy, hmax⟩ := exists_cTransform_contact hv x + obtain ⟨y', hy', hmax'⟩ := exists_cTransform_contact hv x' + have hcost := cost_lipschitz_of_distance_bound hD x x' y + have hcost' := cost_lipschitz_of_distance_bound hD x x' y' + constructor + · have hh := hmax y' + rw [hy'] + linarith [(abs_le.mp hcost').2] + · have hh := hmax' y + rw [hy] + linarith [(abs_le.mp hcost).1] + +lemma continuous_cTransform {v : M → ℝ} (hv : Continuous v) : + Continuous (cTransform v) := by + apply (cTransform_lipschitz hv (D := ⟨Metric.diam (univ : Set M), + Metric.diam_nonneg⟩) _).continuous + intro x y + exact Metric.dist_le_diam_of_mem isCompact_univ.isBounded (mem_univ x) (mem_univ y) + +lemma dualPair_gap_nonneg {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x y : M) : 0 ≤ contactGap u v x y := by + rw [huv.1] + exact cTransform_gap_nonneg hv x y + +lemma dualPair_contact_left {u v : M → ℝ} (hv : Continuous v) + (huv : IsCostDualPair u v) (x : M) : ∃ y, contactGap u v x y = 0 := by + rw [huv.1] + exact cTransform_gap_zero hv x + +omit [CompactSpace M] [Nonempty M] in +lemma contactGap_symm (u v : M → ℝ) (x y : M) : + contactGap u v x y = contactGap v u y x := by + dsimp [contactGap] + rw [cost_symm x y] + ring + +lemma dualPair_contact_right {u v : M → ℝ} (hu : Continuous u) + (huv : IsCostDualPair u v) (y : M) : ∃ x, contactGap u v x y = 0 := by + obtain ⟨x, hx⟩ := dualPair_contact_left hu ⟨huv.2, huv.1⟩ y + exact ⟨x, (contactGap_symm u v x y).trans hx⟩ + +lemma homeomorph_of_contact_bounds {u v : M → ℝ} (hu : Continuous u) + (hv : Continuous v) (huv : IsCostDualPair u v) {alpha C : ℝ} + (ha : 0 < alpha) (hC : 0 ≤ C) + (hf : ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist y y' ≤ C * dist x x' ^ alpha) + (hr : ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist x x' ≤ C * dist y y' ^ alpha) : + ∃ T : M ≃ₜ M, (∀ x, contactGap u v x (T x) = 0) ∧ + (∀ x x', dist (T x) (T x') ≤ C * dist x x' ^ alpha) ∧ + (∀ y y', dist (T.symm y) (T.symm y') ≤ C * dist y y' ^ alpha) := by + classical + choose T hT using dualPair_contact_left hv huv + choose S hS using dualPair_contact_right hu huv + have hST : Function.LeftInverse S T := by + intro x + apply dist_eq_zero.mp + have hh := hr (S (T x)) x (T x) (T x) (hS (T x)) (hT x) + exact le_antisymm (by simpa only [dist_self, Real.zero_rpow ha.ne', mul_zero] using hh) + dist_nonneg + have hTS : Function.RightInverse S T := by + intro y + apply dist_eq_zero.mp + have hh := hf (S y) (S y) (T (S y)) y (hT (S y)) (hS y) + exact le_antisymm (by simpa only [dist_self, Real.zero_rpow ha.ne', mul_zero] using hh) + dist_nonneg + have hf' (x x') : dist (T x) (T x') ≤ C * dist x x' ^ alpha := + hf x x' (T x) (T x') (hT x) (hT x') + have hr' (y y') : dist (S y) (S y') ≤ C * dist y y' ^ alpha := + hr (S y) (S y') y y' (hS y) (hS y') + have cont_of_bound (f : M → M) + (h : ∀ x x', dist (f x) (f x') ≤ C * dist x x' ^ alpha) : Continuous f := by + have holder : HolderWith ⟨C, hC⟩ ⟨alpha, ha.le⟩ f := by + intro x x' + simp only [edist_dist] + have hh := ENNReal.ofReal_le_ofReal (h x x') + rw [ENNReal.ofReal_mul hC, ← ENNReal.ofReal_rpow_of_nonneg dist_nonneg ha.le] at hh + rw [show ENNReal.ofReal C = ENNReal.ofNNReal (NNReal.mk C hC) from + ENNReal.ofReal_coe_nnreal (p := NNReal.mk C hC)] at hh + exact hh + exact holder.continuous ha + exact ⟨⟨⟨T, S, hST, hTS⟩, cont_of_bound T hf', cont_of_bound S hr'⟩, + hT, hf', hr'⟩ + +omit [CompactSpace M] [Nonempty M] in + +lemma contactGap_le_of_contact {u v : M → ℝ} {D : ℝ≥0} + (hu : LipschitzWith D u) (hD : ∀ x y : M, dist x y ≤ D) + {x x' y : M} (hcontact : contactGap u v x' y = 0) : + contactGap u v x y ≤ (2 * D) * dist x x' := by + have hdu := hu.dist_le_mul x x' + rw [Real.dist_eq, abs_le] at hdu + have hdc := (abs_le.mp (cost_lipschitz_of_distance_bound hD x x' y)).2 + dsimp [contactGap] at hcontact ⊢ + linarith + +omit [CompactSpace M] [Nonempty M] in + +lemma contact_section_zero_diameter {u v : M → ℝ} {x y y' : M} {K alpha r0 : ℝ} + (ha : 0 < alpha) (hr0 : 0 < r0) + (hsection : ∀ r, 0 < r → r < r0 → + ∀ z ∈ gapSection u v x r, ∀ z' ∈ gapSection u v x r, + dist z z' ≤ K * r ^ alpha) + (hy : contactGap u v x y = 0) (hy' : contactGap u v x y' = 0) : + dist y y' = 0 := by + have hcl : (0 : ℝ) ∈ closure (Ioo 0 r0) := by + rw [closure_Ioo hr0.ne] + exact ⟨le_rfl, hr0.le⟩ + have hc : Continuous (fun r : ℝ => K * r ^ alpha) := + continuous_const.mul (Real.continuous_rpow_const ha.le) + have hh := ContinuousWithinAt.closure_le hcl + (continuousWithinAt_const (b := dist y y')) hc.continuousWithinAt + (fun r hr => hsection r hr.1 hr.2 y (by simpa [gapSection, hy] using hr.1.le) + y' (by simpa [gapSection, hy'] using hr.1.le)) + apply le_antisymm _ dist_nonneg + simpa only [Real.zero_rpow ha.ne', mul_zero] using hh + +omit [CompactSpace M] [Nonempty M] in + +lemma global_contact_bound_of_local {u v : M → ℝ} {D K alpha delta : ℝ} + (hD : ∀ y y' : M, dist y y' ≤ D) (hK : 0 ≤ K) (ha : 0 < alpha) + (hdelta : 0 < delta) + (hlocal : ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist x x' < delta → dist y y' ≤ K * dist x x' ^ alpha) : + ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist y y' ≤ (K + max D 0 / delta ^ alpha) * dist x x' ^ alpha := by + intro x x' y y' hy hy' + have hrpow : 0 ≤ dist x x' ^ alpha := Real.rpow_nonneg dist_nonneg _ + have hdap : 0 < delta ^ alpha := Real.rpow_pos_of_pos hdelta _ + by_cases hd : dist x x' < delta + · exact (hlocal x x' y y' hy hy' hd).trans + (mul_le_mul_of_nonneg_right (le_add_of_nonneg_right + (div_nonneg (le_max_right D 0) hdap.le)) hrpow) + · have hmono : delta ^ alpha ≤ dist x x' ^ alpha := + Real.rpow_le_rpow hdelta.le (le_of_not_gt hd) ha.le + calc + dist y y' ≤ max D 0 := (hD y y').trans (le_max_left D 0) + _ = (max D 0 / delta ^ alpha) * delta ^ alpha := by + rw [div_mul_cancel₀ _ hdap.ne'] + _ ≤ (max D 0 / delta ^ alpha) * dist x x' ^ alpha := + mul_le_mul_of_nonneg_left hmono (div_nonneg (le_max_right D 0) hdap.le) + _ ≤ (K + max D 0 / delta ^ alpha) * dist x x' ^ alpha := + mul_le_mul_of_nonneg_right (le_add_of_nonneg_left hK) hrpow + +omit [CompactSpace M] [Nonempty M] in + +lemma contact_bound_of_section_bound {u v : M → ℝ} {D : ℝ≥0} + (hu : LipschitzWith D u) (hD : ∀ x y : M, dist x y ≤ D) + {K alpha r0 : ℝ} (hK : 0 ≤ K) (ha : 0 < alpha) (hr0 : 0 < r0) + (hsection : ∀ x r, 0 < r → r < r0 → + ∀ y ∈ gapSection u v x r, ∀ y' ∈ gapSection u v x r, + dist y y' ≤ K * r ^ alpha) : + ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist y y' ≤ + (K * (2 * D + 1) ^ alpha + D / (r0 / (2 * D + 1)) ^ alpha) * + dist x x' ^ alpha := by + let L : ℝ := 2 * D + 1 + have hL : 0 < L := by dsimp [L]; positivity + have hlocal : ∀ x x' y y', contactGap u v x y = 0 → contactGap u v x' y' = 0 → + dist x x' < r0 / L → dist y y' ≤ (K * L ^ alpha) * dist x x' ^ alpha := by + intro x x' y y' hy hy' hd + by_cases heq : x = x' + · subst x' + rw [contact_section_zero_diameter ha hr0 (hsection x) hy hy', dist_self, + Real.zero_rpow ha.ne', mul_zero] + · have hdist : 0 < dist x x' := dist_pos.mpr heq + have hr : 0 < L * dist x x' := mul_pos hL hdist + have hr' : L * dist x x' < r0 := by + have hm := (lt_div_iff₀ hL).mp hd + nlinarith + have hgap : contactGap u v x y' ≤ L * dist x x' := + (contactGap_le_of_contact hu hD hy').trans + (mul_le_mul_of_nonneg_right (by dsimp [L]; linarith) hdist.le) + have hh := hsection x (L * dist x x') hr hr' y + (by simpa [gapSection, hy] using hr.le) y' hgap + rw [Real.mul_rpow hL.le hdist.le, ← mul_assoc] at hh + exact hh + have hh := global_contact_bound_of_local hD + (mul_nonneg hK (Real.rpow_nonneg hL.le _)) ha (div_pos hr0 hL) hlocal + simpa only [L, max_eq_left D.coe_nonneg] using hh + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MinMax.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MinMax.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c5665af69daa65ed456024ec409d4970ccc09c6 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MinMax.lean @@ -0,0 +1,107 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set +open scoped BigOperators + +namespace WeakMTWTransport +section MinMax +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma paired_basis_slice {n : ℕ} (a b : OrthonormalBasis (Fin n) ℝ E) (i : Fin n) : + ∃ v : E, v ≠ 0 ∧ (∀ j : Fin n, i < j → a.repr v j = 0) ∧ + (∀ j : Fin n, j < i → b.repr v j = 0) := by + classical + let f : Fin (i.val+1) → Fin n := fun j => ⟨j.val,by omega⟩ + have hf : Function.Injective f := by + intro j k h + apply Fin.ext + simpa only [f] using congrArg (fun z : Fin n => z.val) h + let V := Submodule.span ℝ (range (fun j : Fin (i.val+1) => a (f j))) + have hdim : Module.finrank ℝ V = i.val+1 := by + exact (finrank_span_eq_card (a.toBasis.linearIndependent.comp f hf)).trans (Fintype.card_fin _) + let L : V →ₗ[ℝ] (Fin i.val → ℝ) := + { toFun := fun v j => b.repr v ⟨j.val,lt_trans j.isLt i.isLt⟩ + map_add' := by intros; ext j; simp + map_smul' := by intros; ext j; simp } + have hk := LinearMap.ker_ne_bot_of_finrank_lt (f := L) (by + rw [hdim,Module.finrank_pi,Fintype.card_fin]; omega) + obtain ⟨v,hv,hv0⟩ := (Submodule.ne_bot_iff _).mp hk + have hvE : (v:E) ≠ 0 := by + intro h + exact hv0 (Subtype.ext h) + refine ⟨v,hvE,?_,?_⟩ + · intro j hj + have H : ∀ w∈V, a.repr w j = 0 := by + intro w hw + induction hw using Submodule.span_induction with + | mem w hw => + obtain ⟨k,rfl⟩ := hw + have hne : f k ≠ j := by intro h; have := congrArg Fin.val h; dsimp [f] at this; omega + simp [Ne.symm hne] + | zero => simp + | add x y hx hy ihx ihy => simp [ihx,ihy] + | smul c x hx ih => simp [ih] + exact H v v.property + · intro j hj + have H := congrFun (show L v = 0 from hv) (⟨j.val,hj⟩ : Fin i.val) + exact H + +lemma eigenvalue_quadratic_expansion {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (hn : Module.finrank ℝ E = n) (v : E) : + inner ℝ (A v) v = ∑ j, hA.eigenvalues hn j*((hA.eigenvectorBasis hn).repr v j)^2 := by + have H := (hA.eigenvectorBasis hn).repr.inner_map_map (A v) v + rw [←H,PiLp.inner_apply] + apply Finset.sum_congr rfl + intro j hj + rw [hA.eigenvectorBasis_apply_self_apply] + simp only [RCLike.inner_apply,conj_trivial,RCLike.ofReal_real_eq_id,id_eq] + ring + +omit [FiniteDimensional ℝ E] in +lemma eigenbasis_norm_expansion {n : ℕ} (b : OrthonormalBasis (Fin n) ℝ E) (v : E) : + ‖v‖^2 = ∑ j, (b.repr v j)^2 := by + rw [←b.repr.norm_map v,EuclideanSpace.real_norm_sq_eq] + +lemma ordered_eigenvalue_quadratic_comparison {A B : E →ₗ[ℝ] E} + (hA : A.IsSymmetric) (hB : B.IsSymmetric) {a b : ℝ} (ha : 0 ≤ a) + (h : ∀ v, inner ℝ (A v) v ≤ a*inner ℝ (B v) v+b*‖v‖^2) + {n : ℕ} (hn : Module.finrank ℝ E = n) (i : Fin n) : + hA.eigenvalues hn i ≤ a*hB.eigenvalues hn i+b := by + obtain ⟨v,hv,hav,hbv⟩ := paired_basis_slice (hA.eigenvectorBasis hn) (hB.eigenvectorBasis hn) i + have hAv : hA.eigenvalues hn i*‖v‖^2 ≤ inner ℝ (A v) v := by + rw [eigenvalue_quadratic_expansion hA hn,eigenbasis_norm_expansion (hA.eigenvectorBasis hn), + Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hji : j ≤ i + · exact mul_le_mul_of_nonneg_right (hA.eigenvalues_antitone hn hji) (sq_nonneg _) + · rw [hav j (lt_of_not_ge hji)]; simp + have hBv : inner ℝ (B v) v ≤ hB.eigenvalues hn i*‖v‖^2 := by + rw [eigenvalue_quadratic_expansion hB hn,eigenbasis_norm_expansion (hB.eigenvectorBasis hn), + Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hij : i ≤ j + · exact mul_le_mul_of_nonneg_right (hB.eigenvalues_antitone hn hij) (sq_nonneg _) + · rw [hbv j (lt_of_not_ge hij)]; simp + have H := h v + have Hmul := mul_le_mul_of_nonneg_left hBv ha + have hpos : 0 < ‖v‖^2 := sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv) + nlinarith + +end MinMax +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MixedDetIntrinsic.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MixedDetIntrinsic.lean new file mode 100644 index 0000000000000000000000000000000000000000..ed67c0af8a5b05a00ed14ec79297e591e9102c2c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MixedDetIntrinsic.lean @@ -0,0 +1,56 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.ChartJacobianBounds +import OAI.Analysis.BiholderTransport.Regularity.MixedIntrinsic +import OAI.Analysis.BiholderTransport.LinearAlgebra.NormDetAdjoint + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MixedDetIntrinsic +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance midFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] in +lemma mixed_intrinsic_det {x a b:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + (hx:x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hp:p∈injectivityDomain x) + (hy:riemannianExp x p∈(extChartAt 𝓘(ℝ,Model n) b).source) : + chartJacobian (n:=n) a x * + |(mixedCostOperator a b (extChartAt 𝓘(ℝ,Model n) a x) + (extChartAt 𝓘(ℝ,Model n) b (riemannianExp x p))).det| * + (chartJacobian (n:=n) b (riemannianExp x p)*expJacobian (n:=n) x p)=1 := by + let E:=TangentSpace 𝓘(ℝ,Model n) x + let T:=fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n:=n) x) 0 + let S:=fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) b) ∘ riemannianExp (n:=n) x) p + let B:=mixedCostOperator a b (extChartAt 𝓘(ℝ,Model n) a x) + (extChartAt 𝓘(ℝ,Model n) b (riemannianExp x p)) + have hT:T.toLinearMap.normDet=chartJacobian (n:=n) a x:=normDet_chart_exp_zero _ _ hx + have hS:S.toLinearMap.normDet=chartJacobian (n:=n) b (riemannianExp x p)*expJacobian (n:=n) x p:= + normDet_chart_exp _ _ _ hy + have hTa:T.adjoint.toLinearMap.normDet=T.toLinearMap.normDet:= + normDet_adjoint_of_pos T rfl (hT.symm ▸ chartJacobian_pos hx) + have H:=congrArg (fun A:E →L[ℝ] E=>A.toLinearMap.normDet) (mixed_intrinsic_factor hx hp hy) + change (T.adjoint.comp (B.comp S)).toLinearMap.normDet=(LinearMap.id:E →ₗ[ℝ] E).normDet at H + rw [normDet_comp_three S B T.adjoint rfl rfl,LinearMap.normDet_id,hTa,hT,hS, + LinearMap.normDet_eq_abs_det] at H + exact H + +end MixedDetIntrinsic +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MixedIntrinsic.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MixedIntrinsic.lean new file mode 100644 index 0000000000000000000000000000000000000000..906f3875679958e3c607cec65582b3d8bfc50ac7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MixedIntrinsic.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.RelativeHessianBound +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MixedIntrinsic +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance finiteMixed (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [Nonempty M] in +lemma chart_normal_smooth {a x:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + (hp:riemannianExp x p∈(extChartAt 𝓘(ℝ,Model n) a).source) : + ContDiffAt ℝ ∞ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp x) p := by + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp p _ (contMDiff_riemannianExp_fiber x p) + exact contMDiffAt_extChartAt' (by simpa only [extChartAt_source] using hp) + +omit [Nonempty M] in +lemma mixed_intrinsic_factor {x a b:M} {p:TangentSpace 𝓘(ℝ,Model n) x} + (hx:x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hp:p∈injectivityDomain x) + (hy:riemannianExp x p∈(extChartAt 𝓘(ℝ,Model n) b).source) : + let T := fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp x) 0 + let S := fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) b) ∘ riemannianExp x) p + T.adjoint.comp ((mixedCostOperator a b (extChartAt 𝓘(ℝ,Model n) a x) + (extChartAt 𝓘(ℝ,Model n) b (riemannianExp x p))).comp S)= + ContinuousLinearMap.id ℝ (TangentSpace 𝓘(ℝ,Model n) x) := by + dsimp only + let E:=TangentSpace 𝓘(ℝ,Model n) x + let χ:=extChartAt 𝓘(ℝ,Model n) a + let ψ:=extChartAt 𝓘(ℝ,Model n) b + let f:=χ ∘ riemannianExp (n:=n) x + let g:=ψ ∘ riemannianExp (n:=n) x + let T:=fderiv ℝ f 0 + let S:=fderiv ℝ g p + let G:=chartCostCovector (n:=n) a b + have hf:ContDiffAt ℝ ∞ f 0:=chart_normal_smooth (by simpa only [riemannianExp_zero] using hx) + have hg:ContDiffAt ℝ ∞ g p:=chart_normal_smooth hy + have hf0:f 0=χ x:=by simp only [f,Function.comp_apply,riemannianExp_zero] + have hgc:ContDiffAt ℝ ∞ G (χ x,g p):=chartCostCovector_contDiffAt + (χ.map_source hx) (ψ.map_source hy) (by + change ContMDiffAt _ _ ∞ (fun q:M×M=>cost q.1 q.2) (χ.symm (χ x),ψ.symm (ψ (riemannianExp x p))) + rw [χ.left_inv hx,ψ.left_inv hy] + exact cost_contMDiffAt_of_injectivityDomain (⟨x,p⟩:TangentBundle 𝓘(ℝ,Model n) M) hp) + have hn:∀ᶠ v:E in 𝓝 p,v∈injectivityDomain x ∧ riemannianExp x v∈ψ.source:=by + filter_upwards [(isOpen_injectivityDomain x).mem_nhds hp, + (contMDiff_riemannianExp_fiber x p).continuousAt.preimage_mem_nhds + ((isOpen_extChartAt_source b).mem_nhds hy)] with v hv hw + exact ⟨hv,hw⟩ + have hsource:∀ᶠ h:E in 𝓝 0,riemannianExp x h∈χ.source:= + (contMDiff_riemannianExp_fiber x 0).continuousAt.preimage_mem_nhds + (by simpa only [riemannianExp_zero] using (isOpen_extChartAt_source a).mem_nhds hx) + have he: (fun v:E => (G (χ x,g v)).comp T) =ᶠ[𝓝 p] (fun v:E => -(innerSL ℝ v)):=by + filter_upwards [hn] with v hv + have hcost:ContDiffAt ℝ ∞ (chartCost a (riemannianExp x v)) (χ x):=by + have H:=cost_contMDiffAt_of_injectivityDomain + (⟨x,v⟩:TangentBundle 𝓘(ℝ,Model n) M) hv.1 + have hi:ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ χ.symm (χ x):= + (contMDiffOn_extChartAt_symm a).contMDiffAt ((isOpen_extChartAt_target a).mem_nhds (χ.map_source hx)) + have H':ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q:M×M=>cost q.1 q.2) (χ.symm (χ x),riemannianExp x v):=by + simpa only [χ.left_inv hx] using H + exact (H'.comp (χ x) (hi.prodMk contMDiffAt_const)).contDiffAt + have heq:(normalCost x v)=ᶠ[𝓝 (0:E)] ((chartCost a (riemannianExp x v)) ∘ f):=by + filter_upwards [hsource] with h hh + change cost (riemannianExp x h) (riemannianExp x v)=cost (χ.symm (χ (riemannianExp x h))) (riemannianExp x v) + rw [χ.left_inv hh] + have HD:HasFDerivAt ((chartCost a (riemannianExp x v)) ∘ f) + ((fderiv ℝ (chartCost a (riemannianExp x v)) (χ x)).comp T) 0:=by + apply HasFDerivAt.comp 0 _ (hf.differentiableAt (by simp)).hasFDerivAt + simpa only [hf0] using (hcost.differentiableAt (by simp)).hasFDerivAt + have HH: (fderiv ℝ (chartCost a (riemannianExp x v)) (χ x)).comp T= -(innerSL ℝ v):=by + rw [←HD.fderiv,←heq.fderiv_eq,(normalCost_hasFDerivAt_zero hv.1).fderiv] + simp only [map_neg] + change (fderiv ℝ (chartCost a (ψ.symm (ψ (riemannianExp x v)))) (χ x)).comp T=_ + rw [ψ.left_inv hv.2] + exact HH + have hmap:HasFDerivAt (fun v:E => (χ x,g v)) + ((0:E →L[ℝ] Model n).prod S) p:= + (hasFDerivAt_const (χ x) p).prodMk (hg.differentiableAt (by simp)).hasFDerivAt + have hd:=((hgc.differentiableAt (by simp)).hasFDerivAt.comp p hmap).clm_comp + (hasFDerivAt_const T p) + have hr:HasFDerivAt (fun v:E => -(innerSL ℝ v)) (-(innerSL ℝ)) p:= + (innerSL ℝ).hasFDerivAt.neg + have hde:= (hd.congr_of_eventuallyEq he.symm).unique hr + apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro e + have H:=congrArg (fun A:E →L[ℝ] E →L[ℝ] ℝ=>A d e) hde + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.flip_apply,add_apply,zero_apply,zero_add, + map_zero,neg_apply] at H + change (fderiv ℝ G (χ x,g p)) (0,S d) (T e) = -inner ℝ d e at H + change inner ℝ (T.adjoint ((mixedCostOperator a b (χ x) (g p)) (S d))) e=inner ℝ d e + rw [ContinuousLinearMap.adjoint_inner_left,mixedCostOperator,bilinearOperator_inner] + simpa only [mixedCostOperator,neg_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.inr_apply,neg_eq_iff_eq_neg,G,innerSL_apply_apply] using H + +end MixedIntrinsic +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedData.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedData.lean new file mode 100644 index 0000000000000000000000000000000000000000..4cf7ce2510ca494fc9fa92de5419796ad5112e7c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedData.lean @@ -0,0 +1,81 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ActualParameter + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology NNReal + +namespace WeakMTWTransport +section ModifiedData +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + +lemma modified_transform_bounds {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {a D b H : ℝ} {B : ℝ → ℝ} + (hB : Continuous B) (hb : 0 ≤ b) (hbound : ∀ s,0 ≤ B s ∧ B s ≤ H) (x : M) : + u x-b*H ≤ cTransform (modifiedDatum v a D b B) x ∧ + cTransform (modifiedDatum v a D b B) x ≤ u x := by + have hw := continuous_modifiedDatum hv a D b hB + have hshift : Continuous (fun y => v y+b*H) := by + rw [hdual.2] + exact (continuous_cTransform hu).add continuous_const + have h1 := cTransform_antitone (w := fun y => v y+b*H) hw hshift + (fun y => add_le_add_right (mul_le_mul_of_nonneg_left (hbound _).2 hb) (v y)) x + have h2 := cTransform_antitone hv hw + (fun y => le_add_of_nonneg_right (mul_nonneg hb (hbound _).1)) x + rw [cTransform_add_const hv,hdual.1.symm] at h1 + rw [hdual.1.symm] at h2 + exact ⟨h1,h2⟩ + +lemma modified_double_bounds {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {a D b : ℝ} {B : ℝ → ℝ} + (hB : Continuous B) (hb : 0 ≤ b) (hbound : ∀ s,0 ≤ B s) (y : M) : + v y ≤ cTransform (cTransform (modifiedDatum v a D b B)) y ∧ + cTransform (cTransform (modifiedDatum v a D b B)) y ≤ modifiedDatum v a D b B y := by + have hw := continuous_modifiedDatum hv a D b hB + have h1 := cTransform_antitone hv hw + (fun y => le_add_of_nonneg_right (mul_nonneg hb (hbound _))) + rw [←hdual.1] at h1 + have h2 := cTransform_antitone (continuous_cTransform hw) hu h1 y + rw [←hdual.2] at h2 + exact ⟨h2,cTransform_cTransform_le hw y⟩ + +lemma modified_excess_upper {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {a D b : ℝ} {Bc Bo : ℝ → ℝ} + (hBo : Continuous Bo) (hb : 0 ≤ b) (ho : ∀ s,0 ≤ Bo s) (hc : ∀ s,Bc s ≤ 1) + (y : M) : modifiedExcess v a D b Bc Bo y ≤ b := by + have H := (modified_double_bounds (a := a) (D := D) hu hv hdual hBo hb ho y).1 + have Hc := mul_le_mul_of_nonneg_left (hc ((v y-a)/D)) hb + dsimp only [modifiedExcess,modifiedDatum] + linarith + +lemma modified_contact_original_section {u v : M → ℝ} (hu : Continuous u) (hv : Continuous v) + (hdual : IsCostDualPair u v) {a D b H : ℝ} {B : ℝ → ℝ} + (hB : Continuous B) (hb : 0 ≤ b) (hbound : ∀ s,0 ≤ B s ∧ B s ≤ H) {x y : M} + (hc : contactGap (cTransform (modifiedDatum v a D b B)) (modifiedDatum v a D b B) x y=0) : + contactGap u v x y ≤ b*H := by + have Hg := (modified_transform_bounds (a := a) (D := D) hu hv hdual hB hb hbound x).1 + have Ho := mul_nonneg hb (hbound ((v y-a)/D)).1 + dsimp only [contactGap,modifiedDatum] at hc ⊢ + linarith only [Hg,Ho,hc] + +omit [CompactSpace M] [Nonempty M] in +lemma modified_excess_at_contact {v : M → ℝ} {a D b : ℝ} {Bc Bo : ℝ → ℝ} {x y : M} + (hc : contactGap (cTransform (modifiedDatum v a D b Bo)) + (cTransform (cTransform (modifiedDatum v a D b Bo))) x y=0) : + modifiedExcess v a D b Bc Bo y = + v y+b*Bc ((v y-a)/D)+cost x y+cTransform (modifiedDatum v a D b Bo) x := by + dsimp only [contactGap] at hc + dsimp only [modifiedExcess,modifiedDatum] + linarith only [hc] + +end ModifiedData +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedOuterNeighborhood.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedOuterNeighborhood.lean new file mode 100644 index 0000000000000000000000000000000000000000..7917781f8e14447f4027a20a0b5df506476f2518 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedOuterNeighborhood.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.ScalarSecond +import OAI.Analysis.BiholderTransport.Regularity.ActiveOuter +import OAI.Analysis.BiholderTransport.Coordinates.OuterCoordinate +import OAI.Analysis.BiholderTransport.Calculus.ScalarJetNeighborhood + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section ModifiedOuterNeighborhood +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [MeasurableSpace M] [BorelSpace M] + +lemma WeakMTW.modified_outer_neighborhood (hmtw:WeakMTW (n := n) (M := M)) + {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) {x0:M} + {uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)} (huv:uv∈densityDualClass (metricVolume n) lam cap x0) + {Φ:ℝ×ℝ → ℝ} (hΦ:ContDiff ℝ ∞ Φ) {β:ℝ} (hmono:StrictMono (fun s=>Φ (β,s))) + {a:M} {p:Model n} + (ha:p∈activeLogs (fun y=>Φ (β,uv.2 y)) a) + (hslope:1 < deriv (fun s=>Φ (β,s)) (uv.2 (riemannianExp a p))) + (hcurve:iteratedDeriv 2 (fun s=>Φ (β,s)) (uv.2 (riemannianExp a p)) < 0) : + ∃V:Set ((Model n×Model n)×ℝ),V∈𝓝 ((extChartAt 𝓘(ℝ,Model n) a a,(p:Model n)),β) ∧ + ∃C≥0,∀q∈V,StrictMono (fun s=>Φ (q.2,s)) → + ∀B:Model n →L[ℝ] Model n →L[ℝ] ℝ,(∀d,0 ≤ B d d) → + HasLowerSecondTaylor (fun d=>Φ (q.2,uv.2 (movingNormal a (q.1.1,q.1.2+d)))+ + ‖chartFiberInverse a q.1.1 (q.1.2+d)‖^2/2) 0 B → + ∀d,B d d ≤ C*‖d‖^2 := by + have hφ:=scalar_family_contDiff hΦ β + have hφ2:ContDiff ℝ 2 (fun s=>Φ (β,s)):=hφ.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hnc:=hmtw.active_outer_nonconjugate hlam hcap huv hφ.continuous hmono + (z := (⟨a,p⟩:TangentBundle 𝓘(ℝ,Model n) M)) ha hφ2.contDiffAt (scalar_family_derivable hΦ (β,uv.2 (riemannianExp a p))) hslope hcurve.le + obtain ⟨U,hU,C,hC,HC⟩:=hmtw.exists_outer_coordinate_jet_bound hlam hcap ha.1 hnc hslope + let q0:(Model n×Model n)×ℝ:=((extChartAt 𝓘(ℝ,Model n) a a,(p:Model n)),β) + have he:movingNormal a q0.1=riemannianExp a p := by + change movingNormal a (extChartAt 𝓘(ℝ,Model n) a a,p)=_ + rw [movingNormal_eq (mem_extChartAt_target (I := 𝓘(ℝ,Model n)) a)] + change riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm (extChartAt 𝓘(ℝ,Model n) a a)) + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a) p)=_ + rw [chartFiberInverse_at_center] + congr 1 + exact (extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a) + have hf:ContinuousAt (fun q:Model n×Model n=>uv.2 (movingNormal a q)) q0.1 := + uv.2.continuous.continuousAt.comp ((movingNormal_contMDiffAt + (q := q0.1) (mem_extChartAt_target a)).continuousAt) + obtain ⟨V,hV,HV⟩:=scalar_jet_neighborhood hf (continuous_scalar_family_deriv hΦ) (continuous_scalar_family_second hΦ) + (by simpa only [he,q0] using hU) (by simpa only [he,q0] using hcurve) + refine ⟨V,hV,C,hC,?_⟩ + intro q hq hm B hB hjet d + exact HC _ (HV q hq).1 x0 uv huv (fun s=>Φ (q.2,s)) hm + (((scalar_family_contDiff hΦ q.2).of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt) + (scalar_family_derivable hΦ (q.2,uv.2 (movingNormal a q.1))) (HV q hq).2.le B hB hjet d + +end ModifiedOuterNeighborhood +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedPhase.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedPhase.lean new file mode 100644 index 0000000000000000000000000000000000000000..4d6171a8c2d460c8f8b7469d46496936782c9856 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ModifiedPhase.lean @@ -0,0 +1,71 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Calculus.SecondTaylorComposition +import OAI.Analysis.BiholderTransport.Regularity.ActualCenterRay +import OAI.Analysis.BiholderTransport.Contact.PhaseContact + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [CompactSpace M] [Nonempty M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma mdifferentiable_of_fixed_chart {a z:M} {f:M → ℝ} + (hz:z∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hd:DifferentiableAt ℝ (fun q=>f ((extChartAt 𝓘(ℝ,Model n) a).symm q)) + (extChartAt 𝓘(ℝ,Model n) a z)) : + MDifferentiableAt 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) f z := by + have H:=hd.hasFDerivAt.hasMFDerivAt.comp z + (mdifferentiableAt_extChartAt (I:=𝓘(ℝ,Model n)) + (show z∈(chartAt (Model n) a).source from by simpa only [extChartAt_source] using hz)).hasMFDerivAt + apply (H.congr_of_eventuallyEq ?_).mdifferentiableAt + filter_upwards [(isOpen_extChartAt_source a).mem_nhds hz] with y hy + simp only [Function.comp_apply,(extChartAt 𝓘(ℝ,Model n) a).left_inv hy] + +lemma WeakMTW.modified_phase_subgradient (hmtw:WeakMTW (n:=n) (M:=M)) + {u v:M → ℝ} (hu:Continuous u) {L:ℝ≥0} (hv:LipschitzWith L v) + (hdual:IsCostDualPair u v) {φ:ℝ → ℝ} (hφc:Continuous φ) + {a y z:M} {l τ:ℝ} (hφ:HasDerivAt φ l (v y)) + (hl:0φ (v w)) z=φ (v y)+cost y z/τ) + (hy:y∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hz:z∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hd:DifferentiableAt ℝ (fun q=>hopfLax τ (fun w=>φ (v w)) + ((extChartAt 𝓘(ℝ,Model n) a).symm q)) (extChartAt 𝓘(ℝ,Model n) a z)) + {s:Set (Model n)} {K:ℝ} (hys:extChartAt 𝓘(ℝ,Model n) a y∈s) + (hsem:ConvexOn ℝ s (fun q=>φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm q))+K/2*‖q‖^2)) : + let Q:=coordinatePhaseFlow a (τ,extChartAt 𝓘(ℝ,Model n) a z, + fderiv ℝ (fun q=>hopfLax τ (fun w=>φ (v w)) ((extChartAt 𝓘(ℝ,Model n) a).symm q)) + (extChartAt 𝓘(ℝ,Model n) a z)) + Q.1=extChartAt 𝓘(ℝ,Model n) a y ∧ + IsSemiconvexSubgradientOn (fun q=>φ (v ((extChartAt 𝓘(ℝ,Model n) a).symm q))) s K + (extChartAt 𝓘(ℝ,Model n) a y) ((InnerProductSpace.toDual ℝ (Model n)).symm Q.2) := by + obtain ⟨p,_,he,_,_,hp⟩:=hmtw.exists_center_ray_of_minimizer hu hv hdual hφc hφ hl hl1 hτ hτ1 hval + have he':(sprayFlow τ (⟨y,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).1=z := by + rwa [riemannianExp_smul] at he + have HH:=phase_contact_semiconvex (hφc.comp hv.continuous) + (injectivityDomain_subset_minimizingVectors y hp) hτ hτ1 + (he'.symm ▸ hval) hy (he'.symm ▸ hz) + (he'.symm ▸ mdifferentiable_of_fixed_chart hz hd) hys hsem + rw [he'] at HH + dsimp only at HH ⊢ + exact ⟨HH.1,HH.1 ▸ HH.2⟩ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterLower.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterLower.lean new file mode 100644 index 0000000000000000000000000000000000000000..50b6dc92aa5a4dd93c79032b90ae80493c4f5479 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterLower.lean @@ -0,0 +1,84 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MovingCenterUpper + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MovingCenterLower +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma moving_center_sequential_lower {a c:M} {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (hc:riemannianExp a q=c) {bj qj:ℕ → Model n} {tj:ℕ → ℝ} + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq:Tendsto qj atTop (𝓝 q)) (ht:Tendsto tj atTop (𝓝 1)) + {Gj:ℕ → M → ℝ} + (hnear:∀ᶠ i in atTop,∀ᶠ z in 𝓝 (movingPrefixChart a c (tj i) (bj i) (qj i)), + DifferentiableAt ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) z) + (hder:∀ᶠ i in atTop,DifferentiableAt ℝ + (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c (tj i) (bj i) (qj i))) + {P C:ℝ} (hP:0 ≤ P) (hC:0 ≤ C) + (hp:∀ᶠ i in atTop,‖fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (movingPrefixChart a c (tj i) (bj i) (qj i))‖ ≤ P) + (hB:∀ᶠ i in atTop,∀d,-C*‖d‖^2 ≤ coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i) d d) : + ∃K≥0,∀ᶠ i in atTop,∀d, + fderiv ℝ (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c (tj i) (bj i) (qj i)) d d ≥ -K*‖d‖^2 := by + let g:(ℝ×Model n) → Model n → Model n:=fun z r=>movingPrefixChart a c z.1 z.2 r + obtain ⟨hA,hAlim,hQlim,hElim,hbt,hct⟩:=moving_center_limit_data hq hc hb hqq ht + have he:∀ᶠ i in atTop,∀d, + coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i) d d= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i) d d+ + fderiv ℝ (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (g (tj i,bj i) (qj i)) (fderiv ℝ (g (tj i,bj i)) (qj i) d) + (fderiv ℝ (g (tj i,bj i)) (qj i) d)+ + fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (g (tj i,bj i) (qj i)) (fderiv ℝ (fderiv ℝ (g (tj i,bj i))) (qj i) d d) := by + filter_upwards [hbt,hct,hnear,hder] with i hbi hci hni hdi + exact coordinateCenterMatrix_chain hbi hci hni hdi + have heNeg:∀ᶠ i in atTop,∀d, + (-coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i)) d d= + (-fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i)) d d+ + (-fderiv ℝ (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (g (tj i,bj i) (qj i))) (fderiv ℝ (g (tj i,bj i)) (qj i) d) + (fderiv ℝ (g (tj i,bj i)) (qj i) d)+ + (-fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (g (tj i,bj i) (qj i))) (fderiv ℝ (fderiv ℝ (g (tj i,bj i))) (qj i) d d) := by + filter_upwards [he] with i hi + intro d + simp only [neg_apply] + linarith only [hi d] + have hpNeg:∀ᶠ i in atTop,‖-fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (g (tj i,bj i) (qj i))‖≤P := by simpa only [norm_neg] using hp + have hBNeg:∀ᶠ i in atTop,∀d,(-coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i)) d d≤C*‖d‖^2 := by + filter_upwards [hB] with i hi + intro d + simp only [neg_apply] + linarith only [hi d] + obtain ⟨K,hK,HK⟩:=sequential_quadratic_upper_transfer hA hAlim hElim.neg hQlim heNeg hP hC hpNeg hBNeg + refine ⟨K,hK,?_⟩ + filter_upwards [HK] with i hi + intro d + have H:=hi d + simp only [neg_apply] at H + linarith only [H] + +end MovingCenterLower +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterUpper.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterUpper.lean new file mode 100644 index 0000000000000000000000000000000000000000..df2c976b790dcfa89cd2c94772bfbd61f4326153 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCenterUpper.lean @@ -0,0 +1,158 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.MovingCenterSemibound +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSequentialUpper + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section MovingCenterUpper +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma coordinateCenterMatrix_chain {a c:M} {t:ℝ} {b p:Model n} {G:M → ℝ} + (hb:b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc:movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) + (hn:∀ᶠ z in 𝓝 (movingPrefixChart a c t b p), + DifferentiableAt ℝ (fun w=>G ((extChartAt 𝓘(ℝ,Model n) c).symm w)) z) + (hd:DifferentiableAt ℝ (fderiv ℝ (fun w=>G ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c t b p)) (d:Model n) : + coordinateCenterMatrix a t G b p d d= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p d d+ + fderiv ℝ (fderiv ℝ (fun w=>G ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c t b p) (fderiv ℝ (movingPrefixChart a c t b) p d) + (fderiv ℝ (movingPrefixChart a c t b) p d)+ + fderiv ℝ (fun w=>G ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (movingPrefixChart a c t b p) (fderiv ℝ (fderiv ℝ (movingPrefixChart a c t b)) p d d) := by + rw [coordinateCenterMatrix_chart hb hc] + simp only [add_apply] + have hg:ContDiffAt ℝ 2 (movingPrefixChart a c t b) p := + ((joint_movingPrefixChart_contDiffAt hb hc).comp p + (contDiffAt_const.prodMk contDiffAt_id)).of_le + (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + rw [second_fderiv_comp_at hn hd hg] + exact (add_assoc _ _ _).symm + +lemma movingPrefixChart_injective_at_center {a c:M} {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (hc:riemannianExp a q=c) : + Function.Injective (fderiv ℝ (movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a)) q) := by + have heq:movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a)= + (fun r:Model n=>extChartAt 𝓘(ℝ,Model n) (riemannianExp a q) (riemannianExp a r)) := by + funext r + simp only [movingPrefixChart,movingPrefix_at_center,one_smul,hc] + rw [heq] + exact riemannianExp_interior_nonconjugate hq + +lemma moving_center_derivative_limits {a c:M} {q:Model n} + (hc:riemannianExp a q=c) {bj qj:ℕ → Model n} {tj:ℕ → ℝ} + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq:Tendsto qj atTop (𝓝 q)) (ht:Tendsto tj atTop (𝓝 1)) : + Tendsto (fun i=>fderiv ℝ (movingPrefixChart a c (tj i) (bj i)) (qj i)) atTop + (𝓝 (fderiv ℝ (movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a)) q)) ∧ + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (movingPrefixChart a c (tj i) (bj i))) (qj i)) atTop + (𝓝 (fderiv ℝ (fderiv ℝ (movingPrefixChart a c 1 (extChartAt 𝓘(ℝ,Model n) a a))) q)) := by + let b:=extChartAt 𝓘(ℝ,Model n) a a + let g:(ℝ×Model n) → Model n → Model n:=fun z r=>movingPrefixChart a c z.1 z.2 r + have hb0:b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hgc:movingPrefix a 1 b q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + simp only [b,movingPrefix_at_center,one_smul,hc] + exact mem_extChartAt_source c + have hg:ContDiffAt ℝ ∞ (Function.uncurry g) ((1,b),q):= + joint_movingPrefixChart_contDiffAt (a := a) (c := c) (t := 1) (b := b) (p := q) hb0 hgc + have harg:Tendsto (fun i=>((tj i,bj i),qj i)) atTop (𝓝 ((1,b),q)):= + (ht.prodMk_nhds hb).prodMk_nhds hqq + have hA : ContinuousAt (fun z:(ℝ×Model n)×Model n=>fderiv ℝ (g z.1) z.2) ((1,b),q) := + (ContDiffAt.partial_snd_fderiv (f := g) (q := (1,b)) (h := q) hg).continuousAt + have hQ : ContinuousAt (fun z:(ℝ×Model n)×Model n=>fderiv ℝ (fderiv ℝ (g z.1)) z.2) ((1,b),q) := + (ContDiffAt.partial_snd_fderiv_two (f := g) (q := (1,b)) (h := q) hg).continuousAt + have H1:=hA.tendsto.comp harg + have H2:=hQ.tendsto.comp harg + dsimp only [Function.comp_def,g,b] at H1 H2 + exact ⟨H1,H2⟩ + +lemma moving_center_limit_data {a c:M} {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (hc:riemannianExp a q=c) {bj qj:ℕ → Model n} {tj:ℕ → ℝ} + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq:Tendsto qj atTop (𝓝 q)) (ht:Tendsto tj atTop (𝓝 1)) : + let g:(ℝ×Model n) → Model n → Model n:=fun z r=>movingPrefixChart a c z.1 z.2 r + let b:=extChartAt 𝓘(ℝ,Model n) a a + Function.Injective (fderiv ℝ (g (1,b)) q) ∧ + Tendsto (fun i=>fderiv ℝ (g (tj i,bj i)) (qj i)) atTop (𝓝 (fderiv ℝ (g (1,b)) q)) ∧ + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (g (tj i,bj i))) (qj i)) atTop + (𝓝 (fderiv ℝ (fderiv ℝ (g (1,b))) q)) ∧ + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i)) atTop + (𝓝 (fderiv ℝ (fderiv ℝ (movingPrefixEnergy a 1 b)) q)) ∧ + (∀ᶠ i in atTop,bj i∈(extChartAt 𝓘(ℝ,Model n) a).target) ∧ + (∀ᶠ i in atTop,movingPrefix a (tj i) (bj i) (qj i)∈(extChartAt 𝓘(ℝ,Model n) c).source) := by + dsimp only + let b:=extChartAt 𝓘(ℝ,Model n) a a + let g:(ℝ×Model n) → Model n → Model n:=fun z r=>movingPrefixChart a c z.1 z.2 r + have hb0:b∈(extChartAt 𝓘(ℝ,Model n) a).target := + (extChartAt 𝓘(ℝ,Model n) a).map_source (mem_extChartAt_source a) + have hgc:movingPrefix a 1 b q∈(extChartAt 𝓘(ℝ,Model n) c).source := by + simp only [b,movingPrefix_at_center,one_smul,hc] + exact mem_extChartAt_source c + have harg:Tendsto (fun i=>((tj i,bj i),qj i)) atTop (𝓝 ((1,b),q)):= + (ht.prodMk_nhds hb).prodMk_nhds hqq + have hA:Function.Injective (fderiv ℝ (g (1,b)) q) := + movingPrefixChart_injective_at_center hq hc + obtain ⟨hAlim,hQlim⟩ := moving_center_derivative_limits hc hb hqq ht + have hElim:=moving_energy_hessian_tendsto (a := a) hq hb hqq ht + have hbt:∀ᶠ i in atTop,bj i∈(extChartAt 𝓘(ℝ,Model n) a).target:= + hb.eventually ((isOpen_extChartAt_target a).mem_nhds hb0) + have hct:∀ᶠ i in atTop,movingPrefix a (tj i) (bj i) (qj i)∈(extChartAt 𝓘(ℝ,Model n) c).source:= + ((joint_movingPrefix_contMDiffAt (a := a) (t := 1) (b := b) (p := q) hb0).continuousAt.tendsto.comp harg).eventually + ((isOpen_extChartAt_source c).mem_nhds hgc) + exact ⟨hA,hAlim,hQlim,hElim,hbt,hct⟩ + +lemma moving_center_sequential_upper {a c:M} {q:Model n} + (hq:(show TangentSpace 𝓘(ℝ,Model n) a from q)∈injectivityDomain a) + (hc:riemannianExp a q=c) {bj qj:ℕ → Model n} {tj:ℕ → ℝ} + (hb:Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hqq:Tendsto qj atTop (𝓝 q)) (ht:Tendsto tj atTop (𝓝 1)) + {Gj:ℕ → M → ℝ} + (hnear:∀ᶠ i in atTop,∀ᶠ z in 𝓝 (movingPrefixChart a c (tj i) (bj i) (qj i)), + DifferentiableAt ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) z) + (hder:∀ᶠ i in atTop,DifferentiableAt ℝ + (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c (tj i) (bj i) (qj i))) + {P C:ℝ} (hP:0 ≤ P) (hC:0 ≤ C) + (hp:∀ᶠ i in atTop,‖fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (movingPrefixChart a c (tj i) (bj i) (qj i))‖ ≤ P) + (hB:∀ᶠ i in atTop,∀d,coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i) d d ≤ C*‖d‖^2) : + ∃K≥0,∀ᶠ i in atTop,∀d, + fderiv ℝ (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (movingPrefixChart a c (tj i) (bj i) (qj i)) d d ≤ K*‖d‖^2 := by + let g:(ℝ×Model n) → Model n → Model n:=fun z r=>movingPrefixChart a c z.1 z.2 r + obtain ⟨hA,hAlim,hQlim,hElim,hbt,hct⟩:=moving_center_limit_data hq hc hb hqq ht + have he:∀ᶠ i in atTop,∀d, + coordinateCenterMatrix a (tj i) (Gj i) (bj i) (qj i) d d= + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a (tj i) (bj i))) (qj i) d d+ + fderiv ℝ (fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w))) + (g (tj i,bj i) (qj i)) (fderiv ℝ (g (tj i,bj i)) (qj i) d) + (fderiv ℝ (g (tj i,bj i)) (qj i) d)+ + fderiv ℝ (fun w=>Gj i ((extChartAt 𝓘(ℝ,Model n) c).symm w)) + (g (tj i,bj i) (qj i)) (fderiv ℝ (fderiv ℝ (g (tj i,bj i))) (qj i) d d) := by + filter_upwards [hbt,hct,hnear,hder] with i hbi hci hni hdi + exact coordinateCenterMatrix_chain hbi hci hni hdi + exact sequential_quadratic_upper_transfer hA hAlim hElim hQlim he hP hC hp hB + +end MovingCenterUpper +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCrossing.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCrossing.lean new file mode 100644 index 0000000000000000000000000000000000000000..25f4dc2bcc9d3498e9af7dbf80bd2f514ff792e3 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingCrossing.lean @@ -0,0 +1,68 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.NormLower +import OAI.Analysis.BiholderTransport.LinearAlgebra.InverseProfile +import OAI.Analysis.BiholderTransport.Regularity.FixedJoinUpper +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactCrossing +import OAI.Analysis.BiholderTransport.Calculus.DerivativeNegLowerCrossing + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma movingFixedJoinMiddle_strict_crossing {a : M} {b p : Model n} {h : ℝ} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (hh : 0 < h) (hh1 : h < 1) + (hleft : h • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) + (hright : (1-h) • (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h + (⟨((extChartAt 𝓘(ℝ,Model n) a).symm b), + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) (v : Model n) (hv : ‖v‖=1) : + 0 < -(fderiv ℝ (movingFixedJoinMiddle a h) (1,(b,p)) (1,0) v v) := by + let x := (extChartAt 𝓘(ℝ,Model n) a).symm b + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ x + have hx : x∈(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).baseSet := by + change x∈(chartAt (Model n) a).source + simpa only [x,extChartAt_source] using (extChartAt 𝓘(ℝ,Model n) a).map_target hb + have hv0 : v≠0 := by intro h; simp only [h,norm_zero] at hv; norm_num at hv + have hLv : L v≠0 := by + intro Hz + have H := congrArg ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).continuousLinearMapAt ℝ x) Hz + have HL := Trivialization.continuousLinearMapAt_symmL (R := ℝ) + (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a) hx v + exact hv0 (by simpa only [L,HL,map_zero] using H) + have hLVpos : 0 < ‖L v‖^2 := sq_pos_of_pos (norm_pos_iff.mpr hLv) + have hM := movingFixedJoinMiddle_contDiffAt + (movingFixedJoinAction_contDiffAt hb hh1.ne' hleft hright) + have hD := bilinear_time_hasDerivAt (hM.differentiableAt (by simp)) v + obtain ⟨c,hc,HC⟩ := exists_fixedJoinMiddle_lower_crossing hh hh1 hleft hright + apply derivative_neg_of_lower_crossing hD hh1 (mul_pos hc hLVpos) + filter_upwards [HC] with T hT + intro hhT hT1 + have HB1 := (fixedJoinAction_contDiffAt hh1.ne' hleft hright).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have HBT := (fixedJoinAction_shortened_contDiffAt hh1 hhT hT1 hleft hright).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + rw [movingFixedJoinMiddle_eq hb h T p v v HBT,movingFixedJoinMiddle_eq hb h 1 p v v HB1] + have H := hT hhT hT1 (L v) + nlinarith only [H] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/MovingPrefix.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingPrefix.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7f900103b4658336715b9ec115a97de0e8187cb --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/MovingPrefix.lean @@ -0,0 +1,108 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates3 +import OAI.Analysis.BiholderTransport.Regularity.PrefixAction +import OAI.Analysis.BiholderTransport.Regularity.StationaryPullback + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def movingPrefix (a : M) (t : ℝ) (b p : Model n) : M := movingNormal a (b,t • p) +def movingPrefixChart (a c : M) (t : ℝ) (b p : Model n) : Model n := + extChartAt 𝓘(ℝ,Model n) c (movingPrefix a t b p) +def movingPrefixEnergy (a : M) (t : ℝ) (b p : Model n) : ℝ := + cost (movingNormal a (b,0)) (movingPrefix a t b p)/t + +lemma movingPrefix_contMDiffAt {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (Function.uncurry (movingPrefix a t)) (b,p) := by + exact (movingNormal_contMDiffAt (q := (b,t • p)) hb).comp (b,p) + (contDiffAt_fst.prodMk (contDiffAt_snd.const_smul t)).contMDiffAt + +lemma movingPrefixChart_contDiffAt {a c : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hc : movingPrefix a t b p∈(extChartAt 𝓘(ℝ,Model n) c).source) : + ContDiffAt ℝ ∞ (Function.uncurry (movingPrefixChart a c t)) (b,p) := by + exact ((contMDiffAt_extChartAt' (I := 𝓘(ℝ,Model n)) (by simpa only [extChartAt_source,Function.uncurry] using hc)) |>.comp (b,p) + (movingPrefix_contMDiffAt hb)).contDiffAt + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingPrefix_eq {a : M} {b : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) (t : ℝ) (p : Model n) : + movingPrefix a t b p=riemannianExp ((extChartAt 𝓘(ℝ,Model n) a).symm b) + (t • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p) := by + rw [movingPrefix,movingNormal_eq hb,map_smul] + +lemma movingPrefixEnergy_contDiffAt {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : t • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + ContDiffAt ℝ ∞ (Function.uncurry (movingPrefixEnergy a t)) (b,p) := by + have hA : ContMDiffAt 𝓘(ℝ,Model n×Model n) 𝓘(ℝ,Model n) ∞ + (fun q:Model n×Model n=> movingNormal a (q.1,0)) (b,p) := + (movingNormal_contMDiffAt (q := (b,0)) hb).comp (b,p) + (contDiffAt_fst.prodMk contDiffAt_const).contMDiffAt + have hC := cost_contMDiffAt_of_injectivityDomain + (⟨(extChartAt 𝓘(ℝ,Model n) a).symm b, + t • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hC' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q:M×M=>cost q.1 q.2) (movingNormal a (b,0),movingPrefix a t b p) := by + simpa only [movingNormal_zero hb,movingPrefix_eq hb] using hC + exact ((hC'.comp (b,p) (hA.prodMk (movingPrefix_contMDiffAt hb))).contDiffAt.div_const t) + +lemma movingPrefixEnergy_axis_near {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : t • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) : + (movingPrefixEnergy a t b)=ᶠ[𝓝 p] + (fun q=>t*(‖(trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) q‖^2/2)) := by + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) + filter_upwards [(L.continuous.tendsto p).eventually (prefixAction_axis_near hp)] with q hq + simpa only [movingPrefixEnergy,movingNormal_zero hb,movingPrefix_eq hb, + prefixAction,riemannianExp_zero] using hq + +lemma movingPrefixEnergy_hessian {a : M} {t : ℝ} {b p : Model n} + (hb : b∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : t • (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) p∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm b)) (d e : Model n) : + fderiv ℝ (fderiv ℝ (movingPrefixEnergy a t b)) p d e= + t*inner ℝ + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) d) + ((trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) e) := by + let L := (trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a).symmL ℝ + ((extChartAt 𝓘(ℝ,Model n) a).symm b) + rw [((movingPrefixEnergy_axis_near hb hp).fderiv (𝕜 := ℝ)).fderiv_eq] + rw [second_fderiv_const_mul] + have H := second_fderiv_comp_affine (f := fun q=>‖q‖^2/2) L 0 p + ((half_norm_sq_contDiff.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt) d e + simpa only [zero_add,half_norm_sq_second_fderiv,innerSL_apply_apply,smul_apply, + smul_eq_mul] using congrArg (fun r:ℝ=>t*r) H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/NonnegativeTransfer.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/NonnegativeTransfer.lean new file mode 100644 index 0000000000000000000000000000000000000000..c30208a9540ca95512392c5edaf558f7c20b6887 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/NonnegativeTransfer.lean @@ -0,0 +1,54 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.ModifiedActiveLowerJet +import OAI.Analysis.BiholderTransport.Regularity.ActiveLimit + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.modified_active_lower_jet_nonneg (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) + {t s : ℝ} (ht : 0 + v (riemannianExp x (pj i+d))+‖pj i+d‖^2/2) 0 + (w i • ((innerSL ℝ).comp R)) := by + classical + let κ := {j : ι // 0pj j) (fun j:κ=>w j) (fun j=>j.2) hs (⟨i,hi⟩:κ) + (fun j=>hmin j) (fun j=>hactive j) (fun j=>hleft j) (fun j=>hright j) + (by simpa only [hb] using ha) (by simpa only [hb] using ha0) + (by simpa only [hb] using harep) + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/NormLower.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/NormLower.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5ff1e727961eac87bdb4ed1c60eee93f4a30103 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/NormLower.lean @@ -0,0 +1,101 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.QuantitativeDividedAction +import OAI.Analysis.BiholderTransport.Coordinates.JoiningCoordinates +import OAI.Analysis.BiholderTransport.Coordinates.FixedJoinSmooth +import OAI.Analysis.BiholderTransport.Coordinates.FixedJoinDifference + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] [FiniteDimensional ℝ E] + +lemma exists_norm_sq_lower_of_injective (L : E →L[ℝ] F) (hL : Function.Injective L) : + ∃ c>0, ∀ v:E, c*‖v‖^2 ≤ ‖L v‖^2 := by + obtain ⟨K,hK,HK⟩ := L.toLinearMap.injective_iff_antilipschitz.mp hL + have hKr : (0:ℝ) TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_fixedJoinMiddle_lower_crossing {x : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} (hh : 00, ∀ᶠ T in 𝓝 (1:ℝ), h (T-h)/(1-h) + have htcont : ContinuousAt t 1 := by fun_prop + have ht1 : t 1=1 := div_self hden.ne' + have htend : Tendsto t (𝓝 1) (𝓝 1) := by simpa only [ht1] using htcont.tendsto + refine ⟨c*a/(1-h)^2,div_pos (mul_pos hc ha) (sq_pos_of_pos hden),?_⟩ + filter_upwards [htend.eventually Hc] with T hCT + intro hT hT1 k + have ht0 : 0 ⟨j.val,by omega⟩ + have hf : Function.Injective f := by + intro j k h + apply Fin.ext + simpa only [f] using congrArg (fun z : Fin n => z.val) h + let V := Submodule.span ℝ (range (fun j : Fin (i.val+1) => a (f j))) + have hdim : Module.finrank ℝ V = i.val+1 := by + exact (finrank_span_eq_card (a.toBasis.linearIndependent.comp f hf)).trans (Fintype.card_fin _) + let L : V →ₗ[ℝ] (Fin i.val → ℝ) := + { toFun := fun v j => b.repr (K v) ⟨j.val,lt_trans j.isLt i.isLt⟩ + map_add' := by intros; ext j; simp + map_smul' := by intros; ext j; simp } + have hk := LinearMap.ker_ne_bot_of_finrank_lt (f := L) (by + rw [hdim,Module.finrank_pi,Fintype.card_fin]; omega) + obtain ⟨v,hv,hv0⟩ := (Submodule.ne_bot_iff _).mp hk + have hvE : (v:E) ≠ 0 := by + intro h + exact hv0 (Subtype.ext h) + refine ⟨v,hvE,?_,?_⟩ + · intro j hj + have H : ∀ w∈V, a.repr w j = 0 := by + intro w hw + induction hw using Submodule.span_induction with + | mem w hw => + obtain ⟨k,rfl⟩ := hw + have hne : f k ≠ j := by intro h; have := congrArg Fin.val h; dsimp [f] at this; omega + simp [Ne.symm hne] + | zero => simp + | add x y hx hy ihx ihy => simp [ihx,ihy] + | smul c x hx ih => simp [ih] + exact H v v.property + · intro j hj + have H := congrFun (show L v = 0 from hv) (⟨j.val,hj⟩ : Fin i.val) + exact H + +lemma quadratic_lower_spectral_slice {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (hn : Module.finrank ℝ E = n) (i : Fin n) (v : E) + (hv : ∀ j : Fin n, i < j → (hA.eigenvectorBasis hn).repr v j = 0) : + hA.eigenvalues hn i * ‖v‖^2 ≤ inner ℝ (A v) v := by + rw [eigenvalue_quadratic_expansion hA hn,eigenbasis_norm_expansion (hA.eigenvectorBasis hn), + Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hji : j ≤ i + · exact mul_le_mul_of_nonneg_right (hA.eigenvalues_antitone hn hji) (sq_nonneg _) + · rw [hv j (lt_of_not_ge hji)]; simp + +lemma quadratic_upper_spectral_slice {A : E →ₗ[ℝ] E} (hA : A.IsSymmetric) + {n : ℕ} (hn : Module.finrank ℝ E = n) (i : Fin n) (v : E) + (hv : ∀ j : Fin n, j < i → (hA.eigenvectorBasis hn).repr v j = 0) : + inner ℝ (A v) v ≤ hA.eigenvalues hn i * ‖v‖^2 := by + rw [eigenvalue_quadratic_expansion hA hn,eigenbasis_norm_expansion (hA.eigenvectorBasis hn), + Finset.mul_sum] + apply Finset.sum_le_sum + intro j hj + by_cases hij : i ≤ j + · exact mul_le_mul_of_nonneg_right (hA.eigenvalues_antitone hn hij) (sq_nonneg _) + · rw [hv j (lt_of_not_ge hij)]; simp + +lemma ordered_eigenvalue_pullback_comparison {A : E →ₗ[ℝ] E} {B : F →ₗ[ℝ] F} + (hA : A.IsSymmetric) (hB : B.IsPositive) (K : E →ₗ[ℝ] F) + {a b c : ℝ} (ha : 0 ≤ a) (hc : 0 ≤ c) + (hK : ∀ v, ‖K v‖ ≤ c * ‖v‖) + (h : ∀ v, inner ℝ (A v) v ≤ a * inner ℝ (B (K v)) (K v) + b * ‖v‖^2) + {n : ℕ} (hnE : Module.finrank ℝ E = n) (hnF : Module.finrank ℝ F = n) (i : Fin n) : + hA.eigenvalues hnE i ≤ a * c^2 * hB.isSymmetric.eigenvalues hnF i + b := by + obtain ⟨v,hv,hav,hbv⟩ := paired_basis_slice_map (hA.eigenvectorBasis hnE) + (hB.isSymmetric.eigenvectorBasis hnF) K i + have hAv := quadratic_lower_spectral_slice hA hnE i v hav + have hBv := quadratic_upper_spectral_slice hB.isSymmetric hnF i (K v) hbv + have hBp := hB.nonneg_eigenvalues hnF i + have hnorm := sq_le_sq₀ (norm_nonneg (K v)) (mul_nonneg hc (norm_nonneg v)) |>.mpr (hK v) + have hmul := mul_le_mul_of_nonneg_left hnorm hBp + have hmul' := mul_le_mul_of_nonneg_left (hBv.trans hmul) ha + have hpos : 0 < ‖v‖^2 := sq_pos_of_ne_zero (norm_ne_zero_iff.mpr hv) + have H := h v + nlinarith + +lemma ordered_singularValues_pullback {A : E →ₗ[ℝ] G} {B : F →ₗ[ℝ] H} + (K : E →ₗ[ℝ] F) {a c : ℝ} (ha : 0 ≤ a) (hc : 0 ≤ c) + (hK : ∀ v, ‖K v‖ ≤ c * ‖v‖) (h : ∀ v, ‖A v‖ ≤ a * ‖B (K v)‖) + {n : ℕ} (hnE : Module.finrank ℝ E = n) (hnF : Module.finrank ℝ F = n) + (i : Fin n) : A.singularValues i ≤ a * c * B.singularValues i := by + have H := ordered_eigenvalue_pullback_comparison A.isSymmetric_adjoint_comp_self + B.isPositive_adjoint_comp_self K (sq_nonneg a) hc hK (b := 0) (fun v => by + simp only [LinearMap.comp_apply,LinearMap.adjoint_inner_left,real_inner_self_eq_norm_sq, + zero_mul,add_zero] + nlinarith [h v,norm_nonneg (A v),norm_nonneg (B (K v))]) hnE hnF i + rw [←A.sq_singularValues_fin hnE,←B.sq_singularValues_fin hnF] at H + have hAp := A.singularValues_nonneg i + have hBp := B.singularValues_nonneg i + have hprod := mul_nonneg (mul_nonneg ha hc) hBp + nlinarith + +end NormMinMax +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalCenterLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalCenterLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ea8357559b655962580e0e6623b66a985b0c77e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalCenterLimit.lean @@ -0,0 +1,103 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.JointMovingPrefix +import OAI.Analysis.BiholderTransport.Calculus.TrueCenterJetBuild +import OAI.Analysis.BiholderTransport.Regularity.TrueCenterLimit + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section OriginalCenterLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance originalLimitFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance originalLimitDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance originalLimitDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance originalLimitBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance originalLimitBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma exists_original_center_limit : ∃δ>0,∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀(u:M → ℝ) (a c:M) (φ:ℕ → ℝ → ℝ) (lj:ℕ → ℝ) (yj:ℕ → M), + ∀(pj:(j:ℕ) → TangentSpace 𝓘(ℝ,Model n) (yj j)) + (Aj:(j:ℕ) → TangentSpace 𝓘(ℝ,Model n) (yj j) →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (yj j)) + (sj:ℕ → Model n) (Sj:ℕ → Model n →L[ℝ] Model n), + ∀(l κ χ:ℝ) (q r:Model n) (g:Model n →L[ℝ] ℝ) (H:Model n →L[ℝ] Model n →L[ℝ] ℝ), + l∈U → 0(⟨yj j,pj j⟩:TangentBundle 𝓘(ℝ,Model n) M)) atTop + (𝓝 (⟨c,r⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto (fun j=>reverseRay (⟨yj j,lj j • pj j⟩:TangentBundle 𝓘(ℝ,Model n) M)) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto (fun j=>iteratedDeriv 2 (φ j) (cTransform u (yj j))) atTop (𝓝 κ) → + Tendsto (fun j=>innerSL ℝ (sj j)) atTop (𝓝 g) → + Tendsto (fun j=>(innerSL ℝ).comp (Sj j)) atTop (𝓝 H) → + (∀ᶠ j in atTop,NormalAlexandrovContact (n:=n) u (yj j) (pj j) (Aj j) ∧ + (∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator (yj j) (pj j)+Aj j) d) d) ∧ + χ≤expJacobian (yj j) (pj j)*(normalHessianOperator (yj j) (pj j)+Aj j).det ∧ + ContDiffAt ℝ 2 (φ j) (cTransform u (yj j)) ∧ + deriv (φ j) (cTransform u (yj j))=lj j ∧ + (∀d e,inner ℝ (Sj j d) e=inner ℝ d (Sj j e)) ∧ + HasQuadraticExpansion (fun h=>φ j (cTransform u ((extChartAt 𝓘(ℝ,Model n) c).symm + (extChartAt 𝓘(ℝ,Model n) c (yj j)+h)))) (sj j) (Sj j)) → + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0reverseRay (⟨yj j,lj j • pj j⟩:TangentBundle 𝓘(ℝ,Model n) M) + have hy:Tendsto yj atTop (𝓝 c):= + (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).continuousAt.tendsto.comp hfull + have hz:Tendsto (fun j=>(z j).1) atTop (𝓝 a):= + (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).continuousAt.tendsto.comp hshort + have hccharts:=hy.eventually ((isOpen_extChartAt_source (I:=𝓘(ℝ,Model n)) c).mem_nhds (mem_extChartAt_source c)) + have hacharts:=hz.eventually ((isOpen_extChartAt_source (I:=𝓘(ℝ,Model n)) a).mem_nhds (mem_extChartAt_source a)) + have hpos:=hlj.eventually (Ioo_mem_nhds hl hl1) + obtain ⟨N,hN⟩:=eventually_atTop.mp (hgood.and (hpos.and (hccharts.and hacharts))) + let σ:=fun j:ℕ=>j+N + have hσ:Tendsto σ atTop atTop:=tendsto_add_atTop_nat N + have hn (j:ℕ):N≤σ j:=Nat.le_add_left _ _ + let J (j:ℕ):TrueCenterJet (n:=n) u a c (φ (σ j)) (lj (σ j)):= + trueCenterJetOfOriginal (hN _ (hn j)).1.1 (hN _ (hn j)).1.2.1 + (hN _ (hn j)).2.1.1 (hN _ (hn j)).2.1.2 + (hN _ (hn j)).2.2.1 (hN _ (hn j)).2.2.2 + (hN _ (hn j)).1.2.2.2.1 (hN _ (hn j)).1.2.2.2.2.1 + (hN _ (hn j)).1.2.2.2.2.2.1 (hN _ (hn j)).1.2.2.2.2.2.2 + obtain ⟨hb,hqq⟩:=graph_coordinates_tendsto hshort + have hbj:Tendsto (fun j=>(J j).b) atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)):=hb.comp hσ + have hqj:Tendsto (fun j=>(J j).q) atTop (𝓝 q):=hqq.comp hσ + have hc:movingPrefix a 1 (extChartAt 𝓘(ℝ,Model n) a a) q∈(extChartAt 𝓘(ℝ,Model n) c).source:=by + rw [movingPrefix_at_center,one_smul,he] + exact mem_extChartAt_source c + have hmatrix:Tendsto (fun j=>(J j).matrix) atTop + (𝓝 (chartJetMatrix a c (extChartAt 𝓘(ℝ,Model n) a a) q g H)):= + chartJetMatrix_tendsto (mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a) hc hbj hqj (hg.comp hσ) (hH.comp hσ) + exact Hδ u a c (φ ∘ σ) (lj ∘ σ) J l κ χ q r _ hlu hl hl1 hχ hq + (hlj.comp hσ) hbj hqj (hfull.comp hσ) (hκ.comp hσ) hmatrix + (Eventually.of_forall (fun j=>(hN _ (hn j)).1.2.2.1)) +end OriginalCenterLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalOuterLimit.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalOuterLimit.lean new file mode 100644 index 0000000000000000000000000000000000000000..c6c6cd5e16af807b0054ecbbd7521251d272f557 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OriginalOuterLimit.lean @@ -0,0 +1,168 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.CenterRayLimit +import OAI.Analysis.BiholderTransport.Coordinates.ExpJacContinuity +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearGainLimit +import OAI.Analysis.BiholderTransport.Calculus.ScalarSecond +import OAI.Analysis.BiholderTransport.LinearAlgebra.ChartOuterMatrix +import OAI.Analysis.BiholderTransport.Regularity.OuterDetCompact + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OriginalOuterLimit +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance originalOuterFinite (x:M):FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x):= + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance originalOuterComplete (x:M):CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x):= + FiniteDimensional.complete ℝ _ +local instance originalOuterDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance originalOuterDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance originalOuterBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance originalOuterBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma WeakMTW.exists_original_outer_limit + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0 < lam) (hcap:0 ≤ cap) : + ∃K>0,∀ (x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)) (Φ:ℝ×ℝ → ℝ), + uv∈densityDualClass (metricVolume n) lam cap x0 → ContDiff ℝ ∞ Φ → + ∀(a:M) (bj pj:ℕ → Model n) (γj mj:ℕ → ℝ) + (Lj:ℕ → Model n →L[ℝ] Model n →L[ℝ] ℝ) + (γ m l κ:ℝ) (p:Model n) (L:Model n →L[ℝ] Model n →L[ℝ] ℝ), + (show TangentSpace 𝓘(ℝ,Model n) a from p)∈minimizingVectors a → + Tendsto bj atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)) → Tendsto pj atTop (𝓝 p) → + Tendsto γj atTop (𝓝 γ) → Tendsto mj atTop (𝓝 m) → Tendsto Lj atTop (𝓝 L) → + deriv (fun s=>Φ (γ,s)) (uv.2 (riemannianExp a p))=l → + iteratedDeriv 2 (fun s=>Φ (γ,s)) (uv.2 (riemannianExp a p))=κ → + 1 < l → κ < 0 → + (∀d,d≠0 → 0 < m*L d d-(κ/l^2)* + (frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) p d)^2) → + (∀ᶠ j in atTop,bj j∈(extChartAt 𝓘(ℝ,Model n) a).target ∧ + StrictMono (fun s=>Φ (γj j,s)) ∧ + (chartRay a (bj j) (pj j)).2∈activeLogs ((fun s=>Φ (γj j,s)) ∘ uv.2) + (chartRay a (bj j) (pj j)).1 ∧ + 0 ≤ mj j ∧ (∀d e,Lj j d e=Lj j e d) ∧ (∀d,0 ≤ Lj j d d) ∧ + HasLowerSecondTaylor (fun d=>Φ (γj j,uv.2 (movingNormal a (bj j,pj j+d)))+ + ‖chartFiberInverse a (bj j) (pj j+d)‖^2/2) 0 (mj j • Lj j)) → + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0 < V d d) ∧ + (∀d,m*L d d-(κ/l^2)*(frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) p d)^2 ≤ V d d) ∧ + expJacobian (n:=n) (reverseRay (⟨a,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).1 + (l⁻¹ • (reverseRay (⟨a,p⟩:TangentBundle 𝓘(ℝ,Model n) M)).2)*(bilinearOperator V).det ≤ + (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n*K* + (expJacobian (n:=n) a p)^2 := by + classical + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_chart_outer_matrix hlam hcap + refine ⟨K,hK,?_⟩ + intro x0 uv Φ huv hΦ a bj pj γj mj Lj γ m l κ p L hmin hb hp hγ hm hL hd hdd hl hκneg hpos hgood + let z:=fun j=>chartRay a (bj j) (pj j) + let z₀:TangentBundle 𝓘(ℝ,Model n) M:=⟨a,p⟩ + let sj:=fun j=>uv.2 (riemannianExp (z j).1 (z j).2) + let lj:=fun j=>deriv (fun s=>Φ (γj j,s)) (sj j) + let κj:=fun j=>iteratedDeriv 2 (fun s=>Φ (γj j,s)) (sj j) + have hz:Tendsto z atTop (𝓝 z₀):=chartRay_tendsto hb hp + have he:Tendsto (fun j=>riemannianExp (z j).1 (z j).2) atTop (𝓝 (riemannianExp a p)):= + (contMDiff_riemannianExp (n:=n) (M:=M)).continuous.continuousAt.tendsto.comp hz + have hs:Tendsto sj atTop (𝓝 (uv.2 (riemannianExp a p))):=uv.2.continuous.continuousAt.tendsto.comp he + have hlj:Tendsto lj atTop (𝓝 l):=by + rw [←hd] + exact ((continuous_scalar_family_deriv hΦ).tendsto (γ,uv.2 (riemannianExp a p))).comp (hγ.prodMk_nhds hs) + have hκj:Tendsto κj atTop (𝓝 κ):=by + rw [←hdd] + have H:=((continuous_scalar_family_second hΦ).tendsto (γ,uv.2 (riemannianExp a p))).comp (hγ.prodMk_nhds hs) + exact H + have hl0:0 < l:=zero_lt_one.trans hl + have hcur:∀ᶠ j in atTop,1 < lj j ∧ κj j < 0:= + (hlj.eventually (lt_mem_nhds hl)).and (hκj.eventually (gt_mem_nhds hκneg)) + let P:=fun j (V:Model n →L[ℝ] Model n)=> + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,mj j*Lj j d d-(κj j/(lj j)^2)*(frameMetric a (bj j) (pj j) d)^2 ≤ inner ℝ (V d) d) ∧ + expJacobian (n:=n) (reverseRay (z j)).1 ((lj j)⁻¹ • (reverseRay (z j)).2)*V.det ≤ + (chartFiberInverse a (bj j)).toLinearMap.normDet^2*(lj j)^n*K*(expJacobian (n:=n) (z j).1 (z j).2)^2 + have hVe:∀ᶠ j in atTop,∃V,P j V:=by + filter_upwards [hgood,hcur] with j hj hc + have hf:ContDiff ℝ ∞ (fun s=>Φ (γj j,s)):=hΦ.comp (contDiff_const.prodMk contDiff_id) + obtain ⟨V,hVs,hVp,hgain,_,_,hdet⟩:=HK x0 uv (fun s=>Φ (γj j,s)) huv hf.continuous + hj.2.1 a (bj j) (pj j) hj.1 (lj j) hj.2.2.1 + (hf.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).contDiffAt + (hf.differentiable (by norm_num) (sj j)).hasDerivAt hc.1 hc.2.le + (mj j • Lj j) (fun d e=>by simp only [smul_apply,smul_eq_mul,hj.2.2.2.2.1]) + (fun d=>mul_nonneg hj.2.2.2.1 (hj.2.2.2.2.2.1 d)) hj.2.2.2.2.2.2 + exact ⟨V,hVs,hVp,hgain,hdet⟩ + let Vj:=fun j=>if h:∃V,P j V then Classical.choose h else 0 + have hVj:∀ᶠ j in atTop,P j (Vj j):=hVe.mono (fun j hj=>by + simpa only [Vj,dite_eq_left hj] using Classical.choose_spec hj) + let W:=fun j=>(innerSL ℝ).comp (Vj j) + let G:=fun j=>frameMetric a (bj j) + let G₀:=frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) + have hb0:=mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a + have hG:Tendsto G atTop (𝓝 G₀):=(frameMetric_continuousAt hb0).tendsto.comp hb + have hfc:=tendsto_clm_apply hG hp + have hc:Tendsto (fun j=>κj j/(lj j)^2) atTop (𝓝 (κ/l^2)):=hκj.div (hlj.pow 2) (pow_ne_zero _ hl0.ne') + let Bj:=fun j=>mj j • Lj j-(κj j/(lj j)^2) • (G j (pj j)).smulRight (G j (pj j)) + let B₀:=m • L-(κ/l^2) • (G₀ p).smulRight (G₀ p) + have hB:Tendsto Bj atTop (𝓝 B₀):=(hm.smul hL).sub (hc.smul (rankForm_tendsto hfc)) + have hBpos:∀d,d≠0 → 0 < B₀ d d:=by + intro d hd + simpa only [B₀,sub_apply,smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,pow_two,mul_assoc] using hpos d hd + let aj:=fun j=>expJacobian (n:=n) (reverseRay (z j)).1 ((lj j)⁻¹ • (reverseRay (z j)).2) + let a₀:=expJacobian (n:=n) (reverseRay z₀).1 (l⁻¹ • (reverseRay z₀).2) + have hreverse:=continuous_reverseRay.continuousAt.tendsto.comp hz + have ha:Tendsto aj atTop (𝓝 a₀):=continuous_expJacobian.continuousAt.tendsto.comp + (contMDiff_tangentScale.continuous.continuousAt.tendsto.comp ((hlj.inv₀ hl0.ne').prodMk_nhds hreverse)) + have ha0:0 < a₀:=expJacobian_pos_of_injectivityDomain + (contracted_minimizer_mem_injectivityDomain (reverseRay_minimizing hmin) + (inv_pos.mpr hl0) (inv_lt_one_of_one_lt₀ hl)) + have hσ:=continuous_expJacobian.continuousAt.tendsto.comp hz + have hfr: Tendsto (fun j=>(chartFiberInverse a (bj j)).toLinearMap.normDet) atTop + (𝓝 (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet):= + (frameNormDet_continuousAt hb0).tendsto.comp hb + let kj:=fun j=>(chartFiberInverse a (bj j)).toLinearMap.normDet^2*(lj j)^n*K*(expJacobian (z j).1 (z j).2)^2 + have hk:Tendsto kj atTop (𝓝 ((chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n*K*(expJacobian a p)^2)):= + (((hfr.pow 2).mul (hlj.pow n)).mul_const K).mul (hσ.pow 2) + have HW:∀ᶠ j in atTop,(∀d e,W j d e=W j e d) ∧ (∀d,0 ≤ W j d d) ∧ + (∀d,Bj j d d≤W j d d) ∧ aj j*(bilinearOperator (W j)).det≤kj j:=by + filter_upwards [hVj] with j hj + have hw (d e:Model n):W j d e=inner ℝ (Vj j d) e:=rfl + refine ⟨?_,?_,?_,?_⟩ + · intro d e + rw [hw,hw,hj.1,real_inner_comm] + · intro d + rw [hw] + by_cases hd:d=0 + · simp [hd] + · exact (hj.2.1 d hd).le + · intro d + simpa only [Bj,sub_apply,smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,pow_two,mul_assoc,hw] using hj.2.2.1 d + · have hW:bilinearOperator (W j)=Vj j:=by + apply ContinuousLinearMap.ext + intro d + apply ext_inner_right ℝ + intro e + exact bilinearOperator_inner _ _ _ + rw [hW] + exact hj.2.2.2 + obtain ⟨V,σ,hσ,HV,hVs,hVp,hgain,hdet⟩:=exists_outer_matrix_limit hB ha hk ha0 hBpos HW + refine ⟨V,hVs,hVp,?_,hdet⟩ + intro d + simpa only [B₀,sub_apply,smul_apply, + ContinuousLinearMap.smulRight_apply,smul_eq_mul,pow_two,mul_assoc] using hgain d +end OriginalOuterLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterBounds.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..b8a288b65faa614c78b3d30903f1c7cbfb3ac9a5 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterBounds.lean @@ -0,0 +1,23 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OuterTemplate + +namespace OAI + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma outerJ_add_integral (K M η a b:ℝ) : + outerJ K M η a + ∫q in a..b,outerW K M η q = outerJ K M η b := by + have hc := (outerW_contDiff K M η).continuous + have hh := intervalIntegral.integral_add_adjacent_intervals (μ:=volume) + (hc.intervalIntegrable 0 a) (hc.intervalIntegrable a b) + unfold outerJ + linarith only [hh] +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterDetCompact.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterDetCompact.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d1d7963287271ebfe4d6eec6e9a9533a053150c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterDetCompact.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.BilinearMatrix +import OAI.Analysis.BiholderTransport.LinearAlgebra.PositiveDetCompact + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section OuterDetCompact +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] +local instance outerDetDualGroup : NormedAddCommGroup (E →L[ℝ] ℝ) := inferInstance +local instance outerDetDualSpace : NormedSpace ℝ (E →L[ℝ] ℝ) := inferInstance +local instance outerDetBilinearGroup : NormedAddCommGroup (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance +local instance outerDetBilinearSpace : NormedSpace ℝ (E →L[ℝ] E →L[ℝ] ℝ) := inferInstance + +lemma exists_outer_matrix_limit {V B:ℕ → E →L[ℝ] E →L[ℝ] ℝ} + {B₀:E →L[ℝ] E →L[ℝ] ℝ} {a k:ℕ → ℝ} {a₀ k₀:ℝ} + (hB:Tendsto B atTop (𝓝 B₀)) (ha:Tendsto a atTop (𝓝 a₀)) + (hk:Tendsto k atTop (𝓝 k₀)) (ha0:0 < a₀) + (hpos:∀d,d≠0 → 0 < B₀ d d) + (hV:∀ᶠ j in atTop,(∀d e,V j d e=V j e d) ∧ + (∀d,0 ≤ V j d d) ∧ (∀d,B j d d ≤ V j d d) ∧ + a j*(bilinearOperator (V j)).det ≤ k j) : + ∃V₀:E →L[ℝ] E →L[ℝ] ℝ,∃σ:ℕ → ℕ,StrictMono σ ∧ + Tendsto (V ∘ σ) atTop (𝓝 V₀) ∧ (∀d e,V₀ d e=V₀ e d) ∧ + (∀d,d≠0 → 0 < V₀ d d) ∧ (∀d,B₀ d d ≤ V₀ d d) ∧ + a₀*(bilinearOperator V₀).det ≤ k₀ := by + let K:=2*(|k₀|+1)/a₀ + have hK:0 ≤ K:=by dsimp only [K]; positivity + have hbound:∀ᶠ j in atTop,|(bilinearOperator (V j)).det| ≤ K:=by + filter_upwards [hV,ha.eventually (lt_mem_nhds (show a₀/2⟨hj.1,hj.2.2.1⟩)) hK hbound + refine ⟨V₀,σ,hσ,HV,hVs,hp,hlo,?_⟩ + exact le_of_tendsto_of_tendsto + ((ha.comp hσ.tendsto_atTop).mul (bilinear_det_tendsto HV)) (hk.comp hσ.tendsto_atTop) + ((hσ.tendsto_atTop.eventually hV).mono (fun j hj=>hj.2.2.2)) +end OuterDetCompact +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..a5f3451968ecd9c9594530fcd0037ee30395fbf4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicDet.lean @@ -0,0 +1,193 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.FixedJoinSpectrum +import OAI.Analysis.BiholderTransport.Calculus.ScalarInverseJet +import OAI.Analysis.BiholderTransport.LinearAlgebra.QuadraticTest +import OAI.Analysis.BiholderTransport.LinearAlgebra.BranchDividedBaseline +import OAI.Analysis.BiholderTransport.LinearAlgebra.Aggregate +import OAI.Analysis.BiholderTransport.Regularity.IntrinsicTestDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OuterIntrinsicDet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance oiFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.exists_uniform_outer_normal_det_bound + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0cost q.1 q.2)=ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) → 1φ (uv.1 (riemannianExp a w))+ + G (riemannianExp a w,riemannianExp a r)) 0 H → + ∃V:TangentSpace 𝓘(ℝ,Model n) a →L[ℝ] TangentSpace 𝓘(ℝ,Model n) a, + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,inner ℝ (V d) d=H d d+ + (l*hessianValue a (l⁻¹ • r) d- + fderiv ℝ (fderiv ℝ (fun w=>G (riemannianExp a w,riemannianExp a r))) 0 d d)- + (iteratedDeriv 2 φ (uv.1 a)/l^2)*(inner ℝ r d)^2) ∧ + expJacobian (n:=n) a (l⁻¹ • r)*V.det≤l^n*K := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_intrinsic_test_det_bound hlam hcap + refine ⟨K,hK,?_⟩ + intro a r G l hr hG hagree hl x0 uv φ huv hmono hφ hd hconc H hHs hH hjet + let E:=TangentSpace 𝓘(ℝ,Model n) a + let c:E → ℝ:=fun w=>G (riemannianExp a w,riemannianExp a r) + have hlp:0contracted_minimizer_mem_injectivityDomain hr hs.1 hs.2) + have hc:ContDiffAt ℝ 2 c 0:=by + have hh:ContDiffAt ℝ ∞ c 0:=by simpa only [c,one_smul] using hCJ.1 + exact hh.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hcD:fderiv ℝ c 0=innerSL ℝ (-r):=by simpa only [c,one_smul] using hCJ.2.1.fderiv + let I:E →L[ℝ] E →L[ℝ] ℝ := innerSL ℝ + let R:E →L[ℝ] E →L[ℝ] ℝ:=(innerSL ℝ r).smulRight (innerSL ℝ r) + let W:E →L[ℝ] E →L[ℝ] ℝ:=H+l • normalHessian a (l⁻¹ • r)-fderiv ℝ (fderiv ℝ c) 0- + (iteratedDeriv 2 φ (uv.1 a)/l^2) • R + have hdiag:∀d,W d d=H d d+(l*hessianValue a (l⁻¹ • r) d- + fderiv ℝ (fderiv ℝ c) 0 d d)-(iteratedDeriv 2 φ (uv.1 a)/l^2)*(inner ℝ r d)^2:=by + intro d + simp only [W,R,sub_apply,add_apply, + smul_apply,ContinuousLinearMap.smulRight_apply,smul_eq_mul, + innerSL_apply_apply,hessianValue_eq_normalHessian hp] + ring + have hWs:∀d e,W d e=W e d:=by + intro d e + simp only [W,R,sub_apply,add_apply, + smul_apply,ContinuousLinearMap.smulRight_apply,smul_eq_mul, + innerSL_apply_apply,hHs d e,normalHessian_symm hp d e, + (hc.isSymmSndFDerivAt (by norm_num)).eq d e] + ring + have hbase:∀d,m*‖d‖^2≤W d d:=by + intro d + have HB:=Hm d + change m*‖d‖^2≤hessianValue a (l⁻¹ • r) d/l⁻¹-fderiv ℝ (fderiv ℝ c) 0 d d at HB + rw [div_inv_eq_mul,mul_comm (hessianValue _ _ _)] at HB + have hs:0≤-(iteratedDeriv 2 φ (uv.1 a)/l^2)*(inner ℝ r d)^2:= + mul_nonneg (neg_nonneg.mpr (div_nonpos_of_nonpos_of_nonneg hconc (sq_nonneg _))) (sq_nonneg _) + rw [hdiag] + linarith only [HB,hH d,hs] + let V:=bilinearOperator W + have hVs:∀d e,inner ℝ (V d) e=inner ℝ d (V e):=bilinearOperator_symmetric hWs + have hVp:∀d,d≠0 → 0 < inner ℝ (V d) d:=by + intro d hd + rw [show inner ℝ (V d) d=W d d from bilinearOperator_inner W d d] + exact (mul_pos hm (sq_pos_of_pos (norm_pos_iff.mpr hd))).trans_le (hbase d) + refine ⟨V,hVs,hVp,?_,?_⟩ + · intro d + exact (bilinearOperator_inner W d d).trans (hdiag d) + have Hbound:∀ε:ℝ,0<ε → ε < m/2 → + expJacobian (n:=n) a (l⁻¹ • r)* |(bilinearOperator (W-ε • I)).det|≤l^n*K:=by + intro ε hε hεm + obtain ⟨q,hq,hq0,hqD,hqlo,hqH⟩:=hjet.exists_smooth_minorant hε + let F:E → ℝ:=fun w=>q w-c w + have hF:ContDiffAt ℝ 2 F 0:=hq.sub hc + have hF0:F 0=φ (uv.1 a):=by + dsimp only [F,c] + rw [hq0,riemannianExp_zero] + ring + have hFlo:∀ᶠ w in 𝓝 (0:E),F w≤φ (uv.1 (riemannianExp a w)):=by + filter_upwards [hqlo] with w hw + change q w≤φ (uv.1 (riemannianExp a w))+c w at hw + dsimp only [F] + linarith only [hw] + have hFD:fderiv ℝ F 0=innerSL ℝ r:=by + rw [show F=(fun w=>q w-c w) from rfl, + fderiv_fun_sub (hq.differentiableAt (by norm_num)) (hc.differentiableAt (by norm_num)), + hqD,hcD,map_neg,zero_sub,neg_neg] + obtain ⟨f,hf,hf0,hflo,hfD,hfH⟩:=scalar_inverse_lower_test + (v:=fun w:E=>uv.1 (riemannianExp a w)) (x:=0) hmono + (by simpa only [riemannianExp_zero] using hφ) + (by simpa only [riemannianExp_zero] using hd) hlp.ne' hF + (by simpa only [riemannianExp_zero] using hF0) hFlo + have hfD':fderiv ℝ f 0=innerSL ℝ (l⁻¹ • r):=by rw [hfD,hFD,map_smul] + let B:=fderiv ℝ (fderiv ℝ f) 0+normalHessian a (l⁻¹ • r) + have Heq:∀d,l*(B d d)=W d d-ε*‖d‖^2:=by + intro d + simp only [B,add_apply] + rw [hfH,show F=(fun w=>q w-c w) from rfl,second_fderiv_sub hq hc,hqH,hFD,hdiag, + hessianValue_eq_normalHessian hp] + simp only [riemannianExp_zero,innerSL_apply_apply] + field_simp [hlp.ne'] + ring + have hpos:∀d,(m/2/l)*‖d‖^2≤B d d:=by + intro d + apply (mul_le_mul_iff_right₀ hlp).mp + rw [Heq] + have he:l*((m/2/l)*‖d‖^2)=(m/2)*‖d‖^2:=by field_simp [hlp.ne'] + rw [he] + nlinarith only [hbase d,mul_le_mul_of_nonneg_right hεm.le (sq_nonneg ‖d‖)] + have Htest:=HK x0 a uv (l⁻¹ • r) f huv hp hf hfD' + (by simpa only [riemannianExp_zero] using hf0.symm) hflo + ⟨m/2/l,by positivity,by simpa only [B,add_apply,hessianValue_eq_normalHessian hp] using hpos⟩ + have Hop:bilinearOperator (W-ε • I)=l • bilinearOperator B:=by + have HB:W-ε • I=l • B:=by + apply symmetric_bilinear_eq_of_diagonal + · intro d e + change W d e-ε*inner ℝ d e=W e d-ε*inner ℝ e d + rw [hWs,real_inner_comm d e] + · intro d e + simp only [B,add_apply,smul_apply, + normalHessian_symm hp d e,(hf.isSymmSndFDerivAt (by norm_num)).eq d e] + · intro d + change W d d-ε*inner ℝ d d=l*B d d + rw [real_inner_self_eq_norm_sq] + exact (Heq d).symm + rw [HB] + ext d + simp only [bilinearOperator,ContinuousLinearMap.comp_apply,smul_apply,map_smul] + rw [Hop] + change expJacobian (n:=n) a (l⁻¹ • r)* |(l • (bilinearOperator B).toLinearMap).det|≤_ + rw [LinearMap.det_smul,show Module.finrank ℝ E=n from tangent_finrank a,abs_mul,abs_of_pos (pow_pos hlp n)] + nlinarith only [mul_le_mul_of_nonneg_left Htest (pow_pos hlp n).le] + have hcont:Continuous (fun ε:ℝ=>expJacobian (n:=n) a (l⁻¹ • r)* + |(bilinearOperator (W-ε • I)).det|):=by + exact continuous_const.mul (continuous_linearized_det + (InnerProductSpace.toDual ℝ E).symm.toContinuousLinearMap W I) + have hlim:= (hcont.continuousAt (x:=0)).tendsto.mono_left (nhdsWithin_le_nhds (s:=Ioi (0:ℝ))) + have hz:W-(0:ℝ) • I=W:=by + ext d e + change W d e-0*inner ℝ d e=W d e + ring + have H:expJacobian (n:=n) a (l⁻¹ • r)* |V.det|≤l^n*K:=by + apply le_of_tendsto (show Tendsto (fun ε:ℝ=>expJacobian (n:=n) a (l⁻¹ • r)* + |(bilinearOperator (W-ε • I)).det|) (𝓝[>] 0) (𝓝 (expJacobian (n:=n) a (l⁻¹ • r)* |V.det|)) from + by simpa only [hz,V] using hlim) + filter_upwards [self_mem_nhdsWithin,(eventually_lt_nhds (show (0:ℝ) < m/2 by positivity)).filter_mono nhdsWithin_le_nhds] with ε hε hεm + exact Hbound ε hε hεm + rw [abs_of_pos (symmetric_det_pos hVs hVp)] at H + exact H + +end OuterIntrinsicDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicSecond.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicSecond.lean new file mode 100644 index 0000000000000000000000000000000000000000..d6670aeb51d4ee53ed8cf93b4c95784ab2330455 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterIntrinsicSecond.lean @@ -0,0 +1,76 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OuterIntrinsicDet + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section OuterIntrinsicSecond +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance oisFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.exists_uniform_outer_normal_det_bound_second + (hmtw:WeakMTW (n:=n) (M:=M)) {lam cap:ℝ} (hlam:0cost q.1 q.2)=ᶠ[𝓝 (z.1,riemannianExp z.1 z.2)] G) → 1φ (uv.2 (riemannianExp a w))+ + G (riemannianExp a w,riemannianExp a r)) 0 H → + ∃V:TangentSpace 𝓘(ℝ,Model n) a →L[ℝ] TangentSpace 𝓘(ℝ,Model n) a, + (∀d e,inner ℝ (V d) e=inner ℝ d (V e)) ∧ + (∀d,d≠0 → 0 < inner ℝ (V d) d) ∧ + (∀d,inner ℝ (V d) d=H d d+ + (l*hessianValue a (l⁻¹ • r) d- + fderiv ℝ (fderiv ℝ (fun w=>G (riemannianExp a w,riemannianExp a r))) 0 d d)- + (iteratedDeriv 2 φ (uv.2 a)/l^2)*(inner ℝ r d)^2) ∧ + expJacobian (n:=n) a (l⁻¹ • r)*V.det≤l^n*K := by + obtain ⟨K,hK,HK⟩:=hmtw.exists_uniform_outer_normal_det_bound hlam hcap + refine ⟨K,hK,?_⟩ + intro a r G l hr hG hagree hl x0 uv φ huv hmono hφ hd hconc H hHs hH hjet + let vu:=reverseNormalizedPair x0 uv + let ψ:=fun s:ℝ=>φ (uv.2 x0+s) + have heq (y:M):uv.2 x0+vu.1 y=uv.2 y:=by + change uv.2 x0+(uv.2 y+-uv.2 x0)=uv.2 y + ring + have hψ:ContDiffAt ℝ 2 ψ (vu.1 a):= + ((heq a).symm ▸ hφ).comp _ (contDiffAt_const.add contDiffAt_id) + have hdψ:HasDerivAt ψ l (vu.1 a):=by + have hd':HasDerivAt φ l (uv.2 x0+vu.1 a):=(heq a).symm ▸ hd + simpa only [mul_one,Function.comp_def,ψ] using + hd'.comp _ ((hasDerivAt_id _).const_add (uv.2 x0)) + have hec:iteratedDeriv 2 ψ (vu.1 a)=iteratedDeriv 2 φ (uv.2 a):=by + dsimp only [ψ] + rw [iteratedDeriv_comp_const_add] + dsimp only + rw [heq] + have HM:=HK a r G l hr hG hagree hl x0 vu ψ (densityDualClass_reverse hlam huv) + (fun _ _ h=>hmono (by linarith)) hψ hdψ (by rw [hec]; exact hconc) H hHs hH + (by simpa only [ψ,heq] using hjet) + simpa only [hec] using HM +end OuterIntrinsicSecond +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterSplitLowerTest.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterSplitLowerTest.lean new file mode 100644 index 0000000000000000000000000000000000000000..19740293e908888650a92d324fcaaf8420df7fc2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterSplitLowerTest.lean @@ -0,0 +1,74 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.CenterSupport +import OAI.Analysis.BiholderTransport.Calculus.ScalarInverseJet + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section OuterSplitLowerTest +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma outer_split_lower_test {v : M → ℝ} {a : M} + {r : TangentSpace 𝓘(ℝ,Model n) a} (hr : r∈minimizingVectors a) + {φ : ℝ → ℝ} (hmono : StrictMono φ) (hφ : ContDiffAt ℝ 2 φ (v a)) + {l : ℝ} (hd : HasDerivAt φ l (v a)) (hl : l≠0) + (hmount : ∀ y : M,φ (v a)+cost a (riemannianExp a r)-cost y (riemannianExp a r)≤φ (v y)) + {s : ℝ} (hs : 0 < s) (hs1 : s < 1) : + ∃ f : TangentSpace 𝓘(ℝ,Model n) a → ℝ, ContDiffAt ℝ 2 f 0 ∧ f 0=v a ∧ + (∀ᶠ h in 𝓝 0,f h≤v (riemannianExp a h)) ∧ + fderiv ℝ f 0=innerSL ℝ (l⁻¹ • r) ∧ + ∀ ξ,fderiv ℝ (fderiv ℝ f) 0 ξ ξ= + -(l*s)⁻¹*hessianValue a (s • r) ξ- + (iteratedDeriv 2 φ (v a)/l^3)*(inner ℝ r ξ)^2 := by + let : Nonempty M := ⟨a⟩ + let F : TangentSpace 𝓘(ℝ,Model n) a → ℝ := fun h => + scalarCostSupport id (φ (v a)) a r s (riemannianExp a h) + have hsp := contracted_minimizer_mem_injectivityDomain hr hs hs1 + obtain ⟨hF,hDF,hHF⟩ := scalarCostSupport_normal_jet (φ := id) (v0 := φ (v a)) + (l := 1) hs.ne' hsp contDiffAt_id (by simp) + have hD : fderiv ℝ F 0=innerSL ℝ r := by simpa only [one_smul] using hDF.fderiv + have hFv : F 0=φ (v (riemannianExp a (0 : TangentSpace 𝓘(ℝ,Model n) a))) := by + simp only [F,riemannianExp_zero,scalarCostSupport_self,id_eq] + have hlo : ∀ᶠ h in 𝓝 0,F h≤φ (v (riemannianExp a h)) := by + apply Filter.Eventually.of_forall + intro h + have H := hmount (riemannianExp a h) + have Hs := minimizing_split_upper_support hr hs hs1 (riemannianExp a h) + have He := minimizing_split_contact hr hs hs1 + dsimp only [F,scalarCostSupport,id_eq] + linarith only [H,Hs,He] + obtain ⟨f,hf,hfv,hfl,hfd,hfh⟩ := scalar_inverse_lower_test hmono + (v := fun h => v (riemannianExp a h)) (x := 0) + (by simpa only [riemannianExp_zero] using hφ) + (by simpa only [riemannianExp_zero] using hd) hl hF hFv hlo + refine ⟨f,hf,by simpa only [riemannianExp_zero] using hfv,hfl,?_,?_⟩ + · rw [hfd,hD,map_smul] + · intro ξ + rw [hfh,hD] + have H := hHF ξ + change fderiv ℝ (fderiv ℝ F) 0 ξ ξ=_ at H + simp only [iteratedDeriv_succ,iteratedDeriv_zero,deriv_id',deriv_const,zero_mul,add_zero,one_div] at H + rw [H,riemannianExp_zero,innerSL_apply_apply] + ring + +end OuterSplitLowerTest +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplate.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplate.lean new file mode 100644 index 0000000000000000000000000000000000000000..22484a313811e0cc2aa65271171e0b29aaa29157 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplate.lean @@ -0,0 +1,95 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma contDiff_primitive {f:ℝ → ℝ} (hf:ContDiff ℝ ∞ f) (a:ℝ) : + ContDiff ℝ ∞ (fun s=>∫ q in a..s,f q) := by + apply contDiff_infty_iff_deriv.mpr + have hd:∀s,HasDerivAt (fun t=>∫ q in a..t,f q) (f s) s:=fun s=> + intervalIntegral.integral_hasDerivAt_right (hf.continuous.intervalIntegrable _ _) + hf.continuous.aestronglyMeasurable.stronglyMeasurableAtFilter hf.continuous.continuousAt + exact ⟨fun s=>(hd s).differentiableAt,by simpa only [funext (fun s=>(hd s).deriv)] using hf⟩ + +def outerW (K M η s:ℝ):ℝ := + (128*(M+3)*(K+1)-(K+1)*s)*Real.smoothTransition ((s+3*η)/η)* + (1-Real.smoothTransition ((s-1/(128*(K+1)))/(1/(128*(K+1))))) + +def outerJ (K M η s:ℝ):ℝ := 1+(1/2048:ℝ)+∫ q in (0:ℝ)..s,outerW K M η q + +def outerProfile (K M η s:ℝ):ℝ := + outerJ K M η s*(1-Real.smoothTransition ((s-(1-η))/η)) + +lemma outerW_contDiff (K M η:ℝ) : ContDiff ℝ ∞ (outerW K M η) := by + unfold outerW + exact ((contDiff_const.sub (contDiff_const.mul contDiff_id)).mul + (Real.smoothTransition.contDiff.comp ((contDiff_id.add contDiff_const).div_const _))).mul + (contDiff_const.sub (Real.smoothTransition.contDiff.comp ((contDiff_id.sub contDiff_const).div_const _))) + +lemma outerJ_contDiff (K M η:ℝ) : ContDiff ℝ ∞ (outerJ K M η) := + contDiff_const.add (contDiff_primitive (outerW_contDiff K M η) 0) + +lemma outerProfile_contDiff (K M η:ℝ) : ContDiff ℝ ∞ (outerProfile K M η) := by + unfold outerProfile + exact (outerJ_contDiff K M η).mul (contDiff_const.sub + (Real.smoothTransition.contDiff.comp ((contDiff_id.sub contDiff_const).div_const _))) + +lemma outerJ_hasDerivAt (K M η s:ℝ) : HasDerivAt (outerJ K M η) (outerW K M η s) s := by + have hc:Continuous (outerW K M η):=(outerW_contDiff K M η).continuous + exact (intervalIntegral.integral_hasDerivAt_right (hc.intervalIntegrable _ _) + hc.aestronglyMeasurable.stronglyMeasurableAtFilter hc.continuousAt).const_add _ + +lemma outerW_zero_right {K M η s:ℝ} (hK:1≤K) (hs:2/(128*(K+1))≤ s) : outerW K M η s=0 := by + have hh:0<1/(128*(K+1)):=by positivity + have hs' : 2*(1/(128*(K+1))) ≤ s := by convert hs using 1; ring + unfold outerW + rw [Real.smoothTransition.one_of_one_le ((le_div_iff₀ hh).mpr (by linarith only [hs']))] + ring + +lemma outerW_nonneg {K M η:ℝ} (hK:1≤K) (hM:2≤M) (_:0<η) (s:ℝ) : + 0≤outerW K M η s := by + by_cases hs:2/(128*(K+1))≤ s + · rw [outerW_zero_right hK hs] + · have hs':s<2/(128*(K+1)):=lt_of_not_ge hs + have hb:2/(128*(K+1))<128*(M+3):=by + apply (div_lt_iff₀ (by positivity : 0<128*(K+1))).mpr + nlinarith + dsimp only [outerW] + exact mul_nonneg (mul_nonneg (by nlinarith) (Real.smoothTransition.nonneg _)) + (sub_nonneg.mpr (Real.smoothTransition.le_one _)) + +lemma outerJ_monotone {K M η:ℝ} (hK:1≤K) (hM:2≤M) (hη:0<η) : + Monotone (outerJ K M η) := by + apply monotone_of_deriv_nonneg ((outerJ_contDiff K M η).differentiable (by simp)) + intro s + rw [(outerJ_hasDerivAt K M η s).deriv] + exact outerW_nonneg hK hM hη s + +lemma outerW_affine {K M η s:ℝ} (hK:1≤K) (hη:0<η) + (hs₁:-2*η≤ s) (hs₂:s≤1/(128*(K+1))) : + outerW K M η s=128*(M+3)*(K+1)-(K+1)*s := by + have hh:0<1/(128*(K+1)):=by positivity + unfold outerW + rw [Real.smoothTransition.one_of_one_le ((le_div_iff₀ hη).mpr (by linarith)), + Real.smoothTransition.zero_of_nonpos (div_nonpos_of_nonpos_of_nonneg (by linarith) hh.le)] + ring + +lemma outerProfile_left {K M η s:ℝ} (hη:0<η) (hs:s≤1-η) : + outerProfile K M η s=outerJ K M η s := by + unfold outerProfile + rw [Real.smoothTransition.zero_of_nonpos (div_nonpos_of_nonpos_of_nonneg (by linarith) hη.le)] + ring + +lemma outerJ_zero (K M η:ℝ) : outerJ K M η 0=1+(1/2048:ℝ) := by + simp only [outerJ,intervalIntegral.integral_same,add_zero] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplatePrimitive.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplatePrimitive.lean new file mode 100644 index 0000000000000000000000000000000000000000..77763189a7d4d52c2d99e128553c7cf81741f408 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterTemplatePrimitive.lean @@ -0,0 +1,100 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OuterVelocityFactorNonneg + +namespace OAI + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology Interval ContDiff + +namespace WeakMTWTransport + +lemma outerTemplate_eq_primitive {M0 K eta s:ℝ} (heta : 0 < eta) (hs : s ≤ 1-eta) : + outerTemplate M0 K eta s=outerPrimitive M0 K eta s := by + have H : (s-(1-eta))/eta ≤ 0 := div_nonpos_of_nonpos_of_nonneg (sub_nonpos.mpr hs) heta.le + simp only [outerTemplate,Real.smoothTransition.zero_of_nonpos H,sub_zero,mul_one] + +lemma outerTemplate_zero {M0 K eta s:ℝ} (heta : 0 < eta) (hs : 1 ≤ s) : + outerTemplate M0 K eta s=0 := by + have H : 1 ≤ (s-(1-eta))/eta := (le_div_iff₀ heta).mpr (by linarith only [hs]) + simp only [outerTemplate,Real.smoothTransition.one_of_one_le H,sub_self,mul_zero] + +lemma outerTemplate_nonneg {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hetasmall : eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) : + 0 ≤ outerTemplate M0 K eta s := by + have H := (outerPrimitive_bounds (s := s) hM hK heta heta1 hetasmall).1 + have hJ : 0 ≤ outerPrimitive M0 K eta s := by rw [templateEps_eq] at H; linarith only [H] + exact mul_nonneg hJ (sub_nonneg.mpr (Real.smoothTransition.le_one _)) + +lemma outerTemplate_lower {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hetasmall : eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) + (hs : s ≤ 1-eta) : 1 ≤ outerTemplate M0 K eta s := by + rw [outerTemplate_eq_primitive heta hs] + have H := (outerPrimitive_bounds (s := s) hM hK heta heta1 hetasmall).1 + rw [templateEps_eq] at H + linarith only [H] + +lemma outerTemplate_upper {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hetasmall : eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) : + outerTemplate M0 K eta s ≤ 2*M0+8 := by + obtain ⟨H1,H2⟩ := outerPrimitive_bounds (s := s) hM hK heta heta1 hetasmall + rw [templateEps_eq] at H1 H2 + have hJ : 0 ≤ outerPrimitive M0 K eta s := by linarith only [H1] + have H := mul_le_mul_of_nonneg_left + (show 1-Real.smoothTransition ((s-(1-eta))/eta) ≤ 1 by + linarith only [Real.smoothTransition.nonneg ((s-(1-eta))/eta)]) hJ + change outerTemplate M0 K eta s ≤ outerPrimitive M0 K eta s*1 at H + linarith only [H,H2] + +lemma outerTemplate_zero_level {M0 K eta:ℝ} (heta : 0 < eta) (heta1 : eta ≤ 1/128) : + outerTemplate M0 K eta 0=1+templateEps/2 := by + rw [outerTemplate_eq_primitive heta (by linarith only [heta1])] + simp [outerPrimitive] + +lemma centerTemplate_le_outer {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hetasmall : eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) : + centerTemplate s ≤ outerTemplate M0 K eta s := by + by_cases hs : s ≤ 1-eta + · exact (centerTemplate_bounds s).2.le.trans (outerTemplate_lower hM hK heta heta1 hetasmall hs) + · exact (centerTemplate_right (by linarith only [hs,heta1])).le.trans + (outerTemplate_nonneg hM hK heta heta1 hetasmall) + +lemma outerPrimitive_core_gain {M0 K eta:ℝ} (hK : 1 ≤ K) (heta : 0 < eta) : + outerPrimitive M0 K eta (1/(128*(K+1)))-outerPrimitive M0 K eta 0 = + M0+3-1/(32768*(K+1)) := by + let h : ℝ := 1/(128*(K+1)) + have hh : 0 ≤ h := by dsimp [h]; positivity + have H : (∫ q in (0:ℝ)..h,outerVelocity M0 K eta q)= + ∫ q in (0:ℝ)..h,(128*(M0+3)*(K+1)-(K+1)*q) := by + apply intervalIntegral.integral_congr + intro q hq + rw [uIcc_of_le hh] at hq + exact outerVelocity_core heta (by linarith only [hq.1,heta]) hq.2 hK + rw [outerPrimitive_sub,H] + rw [intervalIntegral.integral_sub intervalIntegrable_const (show IntervalIntegrable (fun q : ℝ => (K+1)*q) volume 0 h from + (show Continuous (fun q : ℝ => (K+1)*q) by fun_prop).intervalIntegrable _ _), + intervalIntegral.integral_const,intervalIntegral.integral_const_mul,integral_id] + simp only [sub_zero,zero_pow (by norm_num : 2≠0),smul_eq_mul] + dsimp [h] + have hk : K+1≠0 := by linarith only [hK] + field_simp + ring + +lemma outerTemplate_barrier {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hs : 1/16 ≤ s) (hs' : s ≤ 1-eta) : + outerTemplate M0 K eta 0+1 ≤ outerTemplate M0 K eta s := by + have hk : 0 < K+1 := by linarith only [hK] + have hh : 1/(128*(K+1)) ≤ s := by + have H : 1/(128*(K+1)) ≤ 1/16 := (div_le_iff₀ (by positivity)).mpr (by linarith only [hK]) + exact H.trans hs + have hcorr : 1/(32768*(K+1)) ≤ 1 := (div_le_iff₀ (by positivity)).mpr (by linarith only [hK]) + have H := outerPrimitive_core_gain (M0 := M0) hK heta + have Hm := outerPrimitive_monotone (eta := eta) hM hK hh + rw [outerTemplate_eq_primitive heta hs',outerTemplate_eq_primitive heta (by linarith only [heta1])] + linarith only [H,Hm,hcorr,hM] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OuterVelocityFactorNonneg.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterVelocityFactorNonneg.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c08ab4a096bf771c3d4282356334748df796258 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OuterVelocityFactorNonneg.lean @@ -0,0 +1,175 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.MiddleExclusion + +namespace OAI + +noncomputable section +open Set MeasureTheory Filter +open scoped Topology Interval ContDiff + +namespace WeakMTWTransport + +lemma outerVelocity_factor_nonneg {M0 K s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) + (hs : s ≤ 2*(1/(128*(K+1)))) : + 0 ≤ 128*(M0+3)*(K+1)-(K+1)*s := by + have hk : 0 < K+1 := by linarith + have hu : 2*(1/(128*(K+1))) ≤ 1 := by + rw [mul_one_div] + exact (div_le_iff₀ (by positivity)).mpr (by linarith) + have hv : s ≤ 128*(M0+3) := le_trans (hs.trans hu) (by linarith) + have H := mul_nonneg hk.le (sub_nonneg.mpr hv) + nlinarith only [H] + +lemma outerVelocity_nonneg {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) : + 0 ≤ outerVelocity M0 K eta s := by + by_cases hs : 2*(1/(128*(K+1))) ≤ s + · rw [outerVelocity_zero_right hK hs] + · exact mul_nonneg (mul_nonneg (outerVelocity_factor_nonneg hM hK (le_of_not_ge hs)) + (Real.smoothTransition.nonneg _)) (sub_nonneg.mpr (Real.smoothTransition.le_one _)) + +lemma outerVelocity_le_factor {M0 K eta s:ℝ} + (hf : 0 ≤ 128*(M0+3)*(K+1)-(K+1)*s) : + outerVelocity M0 K eta s ≤ 128*(M0+3)*(K+1)-(K+1)*s := by + have h1 := mul_le_mul_of_nonneg_left (Real.smoothTransition.le_one ((s+3*eta)/eta)) hf + have h2 := mul_le_mul_of_nonneg_left + (show 1-Real.smoothTransition ((s-1/(128*(K+1)))/(1/(128*(K+1)))) ≤ 1 from by + linarith only [Real.smoothTransition.nonneg ((s-1/(128*(K+1)))/(1/(128*(K+1))))]) + (mul_nonneg hf (Real.smoothTransition.nonneg ((s+3*eta)/eta))) + simpa only [mul_one,outerVelocity] using h2.trans (by simpa only [mul_one] using h1) + +lemma outerVelocity_le {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) : + outerVelocity M0 K eta s ≤ 128*(M0+3)*(K+1)+3*(K+1)*eta := by + have hk : 0 < K+1 := by linarith + by_cases hl : s ≤ -3*eta + · rw [outerVelocity_zero_left heta hl] + positivity + by_cases hr : 2*(1/(128*(K+1))) ≤ s + · rw [outerVelocity_zero_right hK hr] + positivity + have H := outerVelocity_le_factor (eta := eta) + (outerVelocity_factor_nonneg hM hK (le_of_not_ge hr)) + have HH := mul_nonneg hk.le (show 0 ≤ s+3*eta by linarith only [hl]) + nlinarith only [H,HH] + +lemma outerVelocity_le_L {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (hs : 0 ≤ s) : + outerVelocity M0 K eta s ≤ 128*(M0+3)*(K+1) := by + by_cases hr : 2*(1/(128*(K+1))) ≤ s + · rw [outerVelocity_zero_right hK hr] + positivity + have H := outerVelocity_le_factor (eta := eta) + (outerVelocity_factor_nonneg hM hK (le_of_not_ge hr)) + have HH := mul_nonneg (show 0 ≤ K+1 by linarith) hs + linarith only [H,HH] + +lemma hasDerivAt_outerPrimitive (M0 K eta s:ℝ) : + HasDerivAt (outerPrimitive M0 K eta) (outerVelocity M0 K eta s) s := by + have hc := (outerVelocity_smooth M0 K eta).continuous + exact (intervalIntegral.integral_hasDerivAt_right (hc.intervalIntegrable 0 s) + hc.stronglyMeasurable.stronglyMeasurableAtFilter hc.continuousAt).const_add _ + +lemma outerPrimitive_smooth (M0 K eta:ℝ) : ContDiff ℝ ∞ (outerPrimitive M0 K eta) := by + have hd : deriv (outerPrimitive M0 K eta)=outerVelocity M0 K eta := + funext (fun s => (hasDerivAt_outerPrimitive M0 K eta s).deriv) + have HH : ContDiff ℝ ((∞:ℕ∞ω)+1) (outerPrimitive M0 K eta) := by + apply contDiff_succ_iff_deriv.mpr + refine ⟨fun s => (hasDerivAt_outerPrimitive M0 K eta s).differentiableAt,?_,?_⟩ + · simp + · rw [hd] + exact outerVelocity_smooth M0 K eta + simpa using HH + +lemma outerTemplate_smooth (M0 K eta:ℝ) : ContDiff ℝ ∞ (outerTemplate M0 K eta) := by + unfold outerTemplate + exact (outerPrimitive_smooth M0 K eta).mul (contDiff_const.sub + (Real.smoothTransition.contDiff.comp ((contDiff_id.sub contDiff_const).div_const eta))) + +lemma outerPrimitive_monotone {M0 K eta:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) : + Monotone (outerPrimitive M0 K eta) := by + apply monotone_of_deriv_nonneg (fun s => (hasDerivAt_outerPrimitive M0 K eta s).differentiableAt) + intro s + rw [(hasDerivAt_outerPrimitive M0 K eta s).deriv] + exact outerVelocity_nonneg hM hK + +lemma outerPrimitive_sub (M0 K eta a b:ℝ) : + outerPrimitive M0 K eta b-outerPrimitive M0 K eta a= + ∫ q in a..b,outerVelocity M0 K eta q := by + have hc := (outerVelocity_smooth M0 K eta).continuous + have H := intervalIntegral.integral_add_adjacent_intervals (hc.intervalIntegrable (μ := volume) 0 a) + (hc.intervalIntegrable a b) + unfold outerPrimitive + linarith only [H] + +lemma outerPrimitive_flat_left {M0 K eta s:ℝ} (heta : 0 < eta) (hs : s ≤ -3*eta) : + outerPrimitive M0 K eta s=outerPrimitive M0 K eta (-3*eta) := by + have H := outerPrimitive_sub M0 K eta s (-3*eta) + have Hz : (∫ q in s..(-3*eta),outerVelocity M0 K eta q)=0 := by + calc + _=∫ _q in s..(-3*eta),(0:ℝ) := by + apply intervalIntegral.integral_congr + intro q hq + rw [uIcc_of_le hs] at hq + exact outerVelocity_zero_left heta hq.2 + _=0 := by simp + linarith only [H,Hz] + +lemma outerPrimitive_flat_right {M0 K eta s:ℝ} (hK : 1 ≤ K) + (hs : 2*(1/(128*(K+1))) ≤ s) : + outerPrimitive M0 K eta s=outerPrimitive M0 K eta (2*(1/(128*(K+1)))) := by + have H := outerPrimitive_sub M0 K eta (2*(1/(128*(K+1)))) s + have Hz : (∫ q in (2*(1/(128*(K+1))))..s,outerVelocity M0 K eta q)=0 := by + calc + _=∫ _q in (2*(1/(128*(K+1))))..s,(0:ℝ) := by + apply intervalIntegral.integral_congr + intro q hq + rw [uIcc_of_le hs] at hq + exact outerVelocity_zero_right hK hq.1 + _=0 := by simp + linarith only [H,Hz] + +lemma outerPrimitive_bounds {M0 K eta s:ℝ} (hM : 2 ≤ M0) (hK : 1 ≤ K) (heta : 0 < eta) + (heta1 : eta ≤ 1/128) (hetasmall : eta ≤ templateEps/(24*(128*(M0+3)*(K+1)))) : + 1+templateEps/4 ≤ outerPrimitive M0 K eta s ∧ + outerPrimitive M0 K eta s ≤ 1+templateEps/2+2*(M0+3) := by + have hk : 0 < K+1 := by linarith + have hL : 0 < 128*(M0+3)*(K+1) := by positivity + have hLbig : 3*(K+1)*eta ≤ 128*(M0+3)*(K+1) := by + have HH := mul_nonneg hk.le (show 0 ≤ 128*(M0+3)-3*eta by linarith only [hM,heta1]) + nlinarith only [HH] + have he : 6*eta*(128*(M0+3)*(K+1)) ≤ templateEps/4 := by + have HH := (le_div_iff₀ (show 0 < 24*(128*(M0+3)*(K+1)) by positivity)).mp hetasmall + nlinarith only [HH] + have hc := (outerVelocity_smooth M0 K eta).continuous + have Hleft := intervalIntegral.integral_mono_on (show -3*eta ≤ 0 by linarith) + (hc.intervalIntegrable (μ := volume) (-3*eta) 0) (continuous_const.intervalIntegrable (-3*eta) 0) + (fun q _ => outerVelocity_le (s := q) hM hK heta) + rw [intervalIntegral.integral_const] at Hleft + simp only [smul_eq_mul] at Hleft + have Hjleft : 1+templateEps/4 ≤ outerPrimitive M0 K eta (-3*eta) := by + rw [outerPrimitive,intervalIntegral.integral_symm] + nlinarith only [Hleft,hLbig,he,heta.le] + have hh : 0 ≤ 2*(1/(128*(K+1))) := by positivity + have Hright := intervalIntegral.integral_mono_on hh + (hc.intervalIntegrable (μ := volume) 0 (2*(1/(128*(K+1))))) + (continuous_const.intervalIntegrable 0 (2*(1/(128*(K+1))))) + (fun q hq => outerVelocity_le_L (eta := eta) hM hK hq.1) + rw [intervalIntegral.integral_const] at Hright + simp only [sub_zero,smul_eq_mul] at Hright + have heq : 2*(1/(128*(K+1)))*(128*(M0+3)*(K+1))=2*(M0+3) := by + field_simp + rw [heq] at Hright + have Hjright : outerPrimitive M0 K eta (2*(1/(128*(K+1)))) ≤ 1+templateEps/2+2*(M0+3) := by + unfold outerPrimitive + linarith only [Hright] + constructor + · by_cases hs : s ≤ -3*eta + · rwa [outerPrimitive_flat_left heta hs] + · exact Hjleft.trans (outerPrimitive_monotone (eta := eta) hM hK (le_of_not_ge hs)) + · by_cases hs : 2*(1/(128*(K+1))) ≤ s + · rwa [outerPrimitive_flat_right hK hs] + · exact (outerPrimitive_monotone (eta := eta) hM hK (le_of_not_ge hs)).trans Hjright + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardClosed.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardClosed.lean new file mode 100644 index 0000000000000000000000000000000000000000..ac2f276124ebb61d52d42ab13b50ed04890481c9 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardClosed.lean @@ -0,0 +1,93 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +section OutwardClosed +variable {E:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma outward_closed_conditions {p r e:E} {d w a D ν:ℝ} + (he:‖e‖=1) (hp:0 < inner ℝ p e) (hd:0 < d) (hr:r=p+d • e) + (ha:0 < a) (hD:0 < D) (hq:a*D ≤ (inner ℝ p e)^2) + (hm:ν*D/(inner ℝ p e) ≤ w*d) (hdb:d ≤ 3*D/(2*(inner ℝ p e))) : + ν*D ≤ w*inner ℝ p (r-p) ∧ + a*D*‖r-p‖^2 ≤ (inner ℝ p (r-p))^2 ∧ + inner ℝ p (r-p) ≤ 3*D/2 ∧ + ‖r-p‖^2 ≤ (9/(4*a))*D := by + have hrp:r-p=d • e:=by rw [hr]; abel + have hi:inner ℝ p (r-p)=d*inner ℝ p e:=by rw [hrp,real_inner_smul_right] + have hn:‖r-p‖=d:=by rw [hrp,norm_smul,Real.norm_eq_abs,abs_of_pos hd,he,mul_one] + have Hm:ν*D ≤ w*d*(inner ℝ p e):=(div_le_iff₀ hp).mp hm + have Hdb:d*(2*inner ℝ p e) ≤ 3*D:=(le_div_iff₀ (mul_pos (by norm_num) hp)).mp hdb + have Hsq:(d*inner ℝ p e)^2 ≤ (3*D/2)^2:=by + apply (sq_le_sq₀ (mul_nonneg hd.le hp.le) (by positivity)).mpr + linarith only [Hdb] + have Hq:=mul_le_mul_of_nonneg_right hq (sq_nonneg d) + have Hlast:d^2 ≤ (9/(4*a))*D:=by + apply (mul_le_mul_iff_right₀ (mul_pos ha hD)).mp + have hh:(a*D)*((9/(4*a))*D)=(3*D/2)^2:=by field_simp; ring + rw [hh] + calc a*D*d^2 ≤ (inner ℝ p e)^2*d^2:=Hq + _ = (d*inner ℝ p e)^2:=by ring + _ ≤ _:=Hsq + refine ⟨?_,?_,?_,?_⟩ + · rw [hi]; nlinarith only [Hm] + · rw [hn,hi]; nlinarith only [Hq] + · rw [hi]; linarith only [Hdb] + · rwa [hn] + +lemma outward_direction_of_closed_conditions {p r:E} {w a D ν:ℝ} + (hw:0 < w) (_:0 < a) (hD:0 < D) (hν:0 < ν) + (hm:ν*D ≤ w*inner ℝ p (r-p)) + (hq:a*D*‖r-p‖^2 ≤ (inner ℝ p (r-p))^2) + (hi:inner ℝ p (r-p) ≤ 3*D/2) + (hn:‖r-p‖^2 ≤ (9/(4*a))*D) : + ∃e:E,∃d:ℝ,‖e‖=1 ∧ 0 < d ∧ r=p+d • e ∧ + 0 < inner ℝ p e ∧ a*D ≤ (inner ℝ p e)^2 ∧ + ν*D/(inner ℝ p e) ≤ w*d ∧ + d ≤ 3*D/(2*(inner ℝ p e)) ∧ + ‖r‖^2-‖p‖^2 ≤ (3+9/(4*a))*D := by + have hp:0 < inner ℝ p (r-p):=by + have H:0 < w*inner ℝ p (r-p):=(mul_pos hν hD).trans_le hm + exact (mul_pos_iff_of_pos_left hw).mp H + have hv:r-p≠0:=by intro H; rw [H,inner_zero_right] at hp; exact lt_irrefl _ hp + have hd:0 < ‖r-p‖:=norm_pos_iff.mpr hv + let e:E:=‖r-p‖⁻¹ • (r-p) + have he:‖e‖=1:=by simp only [e,norm_smul,Real.norm_eq_abs,abs_inv,abs_of_pos hd,inv_mul_cancel₀ hd.ne'] + have hr:r=p+‖r-p‖ • e:=by + simp only [e,smul_smul,mul_inv_cancel₀ hd.ne',one_smul] + abel + have hpe:inner ℝ p e=inner ℝ p (r-p)/‖r-p‖:=by + simp only [e,real_inner_smul_right,div_eq_mul_inv,mul_comm] + have hpep:0 < inner ℝ p e:=by rw [hpe]; exact div_pos hp hd + refine ⟨e,‖r-p‖,he,hd,hr,hpep,?_,?_,?_,?_⟩ + · rw [hpe,div_pow] + exact (le_div_iff₀ (sq_pos_of_pos hd)).mpr hq + · apply (div_le_iff₀ hpep).mpr + rw [hpe] + have HH:w*‖r-p‖*(inner ℝ p (r-p)/‖r-p‖)=w*inner ℝ p (r-p):=by + field_simp + rwa [HH] + · apply (le_div_iff₀ (mul_pos (by norm_num) hpep)).mpr + rw [hpe] + have H:‖r-p‖*(2*(inner ℝ p (r-p)/‖r-p‖))=2*inner ℝ p (r-p):=by field_simp + rw [H] + linarith only [hi] + · have H:‖r‖^2=‖p‖^2+2*inner ℝ p (r-p)+‖r-p‖^2:=by + conv_lhs => rw [show r=p+(r-p) by abel] + exact norm_add_sq_real _ _ + nlinarith only [H,hi,hn] + +end OutwardClosed +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardWeightCap.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardWeightCap.lean new file mode 100644 index 0000000000000000000000000000000000000000..70931d20715180efe4a595c1429c877440cb53b2 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/OutwardWeightCap.lean @@ -0,0 +1,110 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set +open scoped BigOperators + +namespace WeakMTWTransport + +lemma outward_weight_and_cap {ι : Type*} [Fintype ι] [DecidableEq ι] + {N : ℕ} (hN : Fintype.card ι≤N) {m d B : ι → ℝ} {q D c : ℝ} + (hm : ∀ i,0 < m i) (hsum : ∑ i,m i=1) (hbar : ∑ i,m i*d i=0) + (hq : 0 + mul_le_mul_of_nonneg_left ((hrneg i hi).2.trans (le_max_left _ _)) (hm i).le) + _≤∑ i,m i*max (-d i) 0 := Finset.sum_le_sum_of_subset_of_nonneg + (Finset.subset_univ right) (fun i _ _ => mul_nonneg (hm i).le (le_max_right _ _)) + let a : ℝ := c*D/(8*(N:ℝ)*q) + have ha : 0 mul_nonneg (hm j).le (hB j)) (Finset.mem_univ i)).trans hcap + have hBi : B i≤12*(N:ℝ)/c := by + apply (le_div_iff₀ hc).mpr + have HH := mul_le_mul_of_nonneg_right hmi (hB i) + have HH' : c*B i/(12*(N:ℝ))≤1 := by + calc + c*B i/(12*(N:ℝ))=c/(12*(N:ℝ))*B i := by ring + _≤ m i*B i := HH + _≤1 := hone + have := (div_le_iff₀ (by positivity : 0<12*(N:ℝ))).mp HH' + nlinarith only [this] + exact ⟨i,hdi,hmi,hi,hdub,hBi⟩ + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricActive.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricActive.lean new file mode 100644 index 0000000000000000000000000000000000000000..2227e6e9484928b6403c565c7d58d9fe0a782837 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricActive.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters +import OAI.Analysis.BiholderTransport.Regularity.ActiveGraphLimit +import OAI.Analysis.BiholderTransport.Regularity.ActualParameter + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ParametricActive +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma activeLogs_iff_minimum {v:M → ℝ} (hv:Continuous v) {x:M} + {p:TangentSpace 𝓘(ℝ,Model n) x} : p∈activeLogs v x ↔ + p∈minimizingVectors x ∧ ∀ y:M,v (riemannianExp x p)+cost x (riemannianExp x p) ≤ v y+cost x y := by + constructor + · rintro ⟨hm,hcontact⟩ + refine ⟨hm,fun y=>?_⟩ + have H:=cTransform_gap_nonneg hv x y + dsimp only [contactGap] at * + linarith only [H,hcontact] + · rintro ⟨hm,hmin⟩ + refine ⟨hm,?_⟩ + obtain ⟨y,hy⟩:=cTransform_gap_zero hv x + have H:=cTransform_gap_nonneg hv x (riemannianExp x p) + have HH:=hmin y + dsimp only [contactGap] at * + linarith only [H,HH,hy] + +omit [CompactSpace M] [Nonempty M] in +lemma continuous_joint_modifiedDatum {v:M → ℝ} (hv:Continuous v) + (α D:ℝ) {B:ℝ → ℝ} (hB:Continuous B) : + Continuous (fun q:ℝ×M=>modifiedDatum v α D q.1 B q.2) := by + exact (hv.comp continuous_snd).add + (continuous_fst.mul (hB.comp (((hv.comp continuous_snd).sub continuous_const).div_const D))) + +lemma modified_active_bundle_limit {v:M → ℝ} (hv:Continuous v) + {α D:ℝ} {B:ℝ → ℝ} (hB:Continuous B) + {bk:ℕ → ℝ} {β:ℝ} (hb:Tendsto bk atTop (𝓝 β)) + {Qk:ℕ → TangentBundle 𝓘(ℝ,Model n) M} {Q:TangentBundle 𝓘(ℝ,Model n) M} + (hQ:Tendsto Qk atTop (𝓝 Q)) + (ha:∀ᶠ k in atTop,(Qk k).2∈activeLogs (modifiedDatum v α D (bk k) B) (Qk k).1) : + Q.2∈activeLogs (modifiedDatum v α D β B) Q.1 := by + let : T2Space (TangentBundle 𝓘(ℝ,Model n) M) := bundle_totalSpace_t2 + have hx: Tendsto (fun k=>(Qk k).1) atTop (𝓝 Q.1) := + (FiberBundle.continuous_proj (Model n) (TangentSpace 𝓘(ℝ,Model n))).tendsto Q |>.comp hQ + have hy:=contMDiff_riemannianExp.continuous.tendsto Q |>.comp hQ + have hm:Q.2∈minimizingVectors Q.1 := + (isCompact_total_minimizingVectors (n := n) (M := M)).isClosed.mem_of_tendsto hQ (ha.mono (fun _ h=>h.1)) + apply (activeLogs_iff_minimum (continuous_modifiedDatum hv α D β hB)).mpr + refine ⟨hm,fun y=>?_⟩ + have hφ:=continuous_joint_modifiedDatum hv α D hB + have hleft:= (hφ.tendsto (β,riemannianExp Q.1 Q.2) |>.comp (hb.prodMk_nhds hy)).add + ((hx.dist hy).pow 2 |>.div_const 2) + have hright:= (hφ.tendsto (β,y) |>.comp (hb.prodMk_nhds tendsto_const_nhds)).add + ((hx.dist (show Tendsto (fun _:ℕ=>y) atTop (𝓝 y) from tendsto_const_nhds)).pow 2 |>.div_const 2) + exact le_of_tendsto_of_tendsto hleft hright (ha.mono (fun k hk=> + ((activeLogs_iff_minimum (continuous_modifiedDatum hv α D (bk k) hB)).mp hk).2 y)) + +lemma modified_active_coordinates_limit {v:M → ℝ} (hv:Continuous v) + {α D:ℝ} {B:ℝ → ℝ} (hB:Continuous B) + {bk:ℕ → ℝ} {β:ℝ} (hb:Tendsto bk atTop (𝓝 β)) + {a:M} {xk pk:ℕ → Model n} {p:Model n} + (hx:Tendsto xk atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a))) + (hp:Tendsto pk atTop (𝓝 p)) + (hxt:∀ᶠ k in atTop,xk k∈(extChartAt 𝓘(ℝ,Model n) a).target) + (ha:∀ᶠ k in atTop,chartFiberInverse a (xk k) (pk k)∈ + activeLogs (modifiedDatum v α D (bk k) B) ((extChartAt 𝓘(ℝ,Model n) a).symm (xk k))) : + (show TangentSpace 𝓘(ℝ,Model n) a from p)∈activeLogs (modifiedDatum v α D β B) a := by + let χ:=extChartAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) (⟨a,0⟩:TangentBundle 𝓘(ℝ,Model n) M) + have ht:(extChartAt 𝓘(ℝ,Model n) a a,p)∈χ.target := + (tangent_chart_target_iff _ _).mpr (mem_extChartAt_target a) + have H:= (continuousAt_extChartAt_symm'' ht).tendsto.comp (hx.prodMk_nhds hp) + have hcenter:χ.symm (extChartAt 𝓘(ℝ,Model n) a a,p)= + (⟨a,p⟩:TangentBundle 𝓘(ℝ,Model n) M) := by + rw [tangent_chart_symm_trivialization (mem_extChartAt_target a),chartFiberInverse_at_center] + congr 1 + exact (extChartAt 𝓘(ℝ,Model n) a).left_inv (mem_extChartAt_source a) + rw [hcenter] at H + apply modified_active_bundle_limit hv hB hb H + filter_upwards [hxt,ha] with k hk hka + simp only [Function.comp_apply] + rwa [tangent_chart_symm_trivialization hk] + +end ParametricActive +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricLowerSequence.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricLowerSequence.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f40fb488e242cefd657487092eb726d396ae2e1 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ParametricLowerSequence.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ParametricShortLowerJets + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +lemma exists_parametric_short_lower_sequence {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} (L : ℝ≥0) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) + {pj : ℕ → P} {xj : ℕ → Model n} {tj : ℕ → ℝ} {f : ℕ → M → ℝ} + (hp : Tendsto pj atTop (𝓝 p)) (hxx : Tendsto xj atTop (𝓝 x)) + (ht : Tendsto tj atTop (𝓝 0)) (htpos : ∀ᶠ i in atTop,0parametricShortForward a ψ ((pj i,tj i),xj i) + ∃ U : ℕ → Model n → ℝ, + (∀ᶠ i in atTop,ContDiffAt ℝ 2 (U i) (z i) ∧ + U i (z i)=hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm (z i)) ∧ + ∀ᶠ w in 𝓝 (z i),U i w≤hopfLax (tj i) (f i) ((extChartAt 𝓘(ℝ,Model n) a).symm w)) ∧ + Tendsto (fun i=>fderiv ℝ (U i) (z i)) atTop + (𝓝 (fderiv ℝ (fun w=>ψ (p,w)) x)) ∧ + Tendsto (fun i=>fderiv ℝ (fderiv ℝ (U i)) (z i)) atTop + (𝓝 (fderiv ℝ (fderiv ℝ (fun w=>ψ (p,w))) x)) := by + dsimp only + let z := fun i=>parametricShortForward a ψ ((pj i,tj i),xj i) + have hQ := (hp.prodMk_nhds ht).prodMk_nhds hxx + have hzero : parametricShortForward a ψ ((p,0),x)=x := shortForward_zero hx + have hz : Tendsto z atTop (𝓝 x) := by + have H := (parametricShortForward_contDiffAt hx hψ).continuousAt.tendsto.comp hQ + rwa [hzero] at H + have hQz := (hp.prodMk_nhds ht).prodMk_nhds hz + obtain ⟨r,hr,B,U,hB,hU,hBx,hBZ,hZB,hlo,hD,hH⟩ := + exists_parametric_short_lower_jets L hx hψ + obtain ⟨V,hV,hVo,hV0⟩ := mem_nhds_iff.mp hlo + have hVB := hQz.eventually (hVo.mem_nhds hV0) + have hBK : ∀ᶠ i in atTop,B ((pj i,tj i),z i)=xj i := hQ.eventually hZB + have hUC : ∀ᶠ i in atTop,ContDiffAt ℝ 2 U ((pj i,tj i),z i) := + hQz.eventually ((hU.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by norm_num)) + refine ⟨fun i w=>U ((pj i,tj i),w),?_,hD.comp hQz,hH.comp hQz⟩ + filter_upwards [hVB,hBK,hUC,htpos,hlip,hbelow,htouch] with i hVi hBi hUi hti hfi hbei hti' + have htU := hUi.comp (z i) (contDiffAt_const.prodMk contDiffAt_id) + have H := hV hVi hti (f i) hfi (fun w _=>hbei w) + have Heq : f i ((extChartAt 𝓘(ℝ,Model n) a).symm (B ((pj i,tj i),z i)))= + ψ (pj i,B ((pj i,tj i),z i)) := by rw [hBi]; exact hti' + refine ⟨htU,H.2 Heq,?_⟩ + have hc : ContinuousAt (fun w:Model n=>((pj i,tj i),w)) (z i) := + continuousAt_const.prodMk continuousAt_id + filter_upwards [hc.eventually (hVo.mem_nhds hVi)] with w hw + exact (hV hw hti (f i) hfi (fun w _=>hbei w)).1 + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/PosSemidefApplyInner.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/PosSemidefApplyInner.lean new file mode 100644 index 0000000000000000000000000000000000000000..94a03fafd55efc30f0977555ccfd83e0d0639c60 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/PosSemidefApplyInner.lean @@ -0,0 +1,70 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +namespace WeakMTWTransport + +lemma posSemidef_apply_eq_zero_of_inner_eq_zero {E : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {A : E →L[ℝ] E} (hAs : ∀ u v, inner ℝ (A u) v=inner ℝ u (A v)) + (hA : ∀ v, 0 ≤ inner ℝ (A v) v) {v : E} (hv : inner ℝ (A v) v=0) : A v=0 := by + have hquad (t : ℝ) : + 0 ≤ inner ℝ (A (A v)) (A v)*(t*t)+(2*inner ℝ (A v) (A v))*t+0 := by + have H := hA (v+t • A v) + simp only [map_add,map_smul,inner_add_left,inner_add_right,real_inner_smul_left, + real_inner_smul_right,hv] at H + rw [hAs (A v) v] at H + nlinarith + have hd := discrim_le_zero hquad + simp only [discrim,mul_zero,sub_zero] at hd + have hs : inner ℝ (A v) (A v)=0 := by nlinarith [sq_nonneg (inner ℝ (A v) (A v))] + exact (inner_self_eq_zero).mp hs + +lemma posDef_of_posSemidef_injective {E : Type*} + [NormedAddCommGroup E] [InnerProductSpace ℝ E] + {A : E →L[ℝ] E} (hAs : ∀ u v, inner ℝ (A u) v=inner ℝ u (A v)) + (hA : ∀ v, 0 ≤ inner ℝ (A v) v) (hAi : Function.Injective A) : + ∀ v, v≠0 → 0 < inner ℝ (A v) v := by + intro v hv + apply lt_of_le_of_ne (hA v) + intro he + have hz := posSemidef_apply_eq_zero_of_inner_eq_zero hAs hA he.symm + exact hv (hAi (by simpa only [map_zero] using hz)) + +lemma injective_middle_of_det_comp_ne_zero {E F : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] [FiniteDimensional ℝ F] + (hdim : Module.finrank ℝ E=Module.finrank ℝ F) + (R : E →L[ℝ] F) (S : F →L[ℝ] E) (W : F →L[ℝ] F) + (hdet : (S.comp (W.comp R)).det≠0) : Function.Injective W := by + have hFi : Function.Injective (S.comp (W.comp R)) := by + apply LinearMap.ker_eq_bot.mp + exact not_not.mp (LinearMap.det_eq_zero_iff_ker_ne_bot.not.mp hdet) + have hRi : Function.Injective R := by + intro u v huv + apply hFi + simp only [ContinuousLinearMap.comp_apply,huv] + have hRs : Function.Surjective R := + (LinearMap.injective_iff_surjective_of_finrank_eq_finrank hdim).mp hRi + apply LinearMap.ker_eq_bot.mp + apply LinearMap.ker_eq_bot'.mpr + intro v hv + obtain ⟨u,rfl⟩ := hRs v + change W (R u)=0 at hv + have hu : u=0 := hFi (by + change S (W (R u))=S (W (R 0)) + simp only [hv,map_zero]) + simp only [hu,map_zero] + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/PrefixAction.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/PrefixAction.lean new file mode 100644 index 0000000000000000000000000000000000000000..18fb5a2780922b7565b58a1ff61415f33eb41c60 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/PrefixAction.lean @@ -0,0 +1,112 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.SplitPairing + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def prefixAction (x : M) (t : ℝ) + (q : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost (riemannianExp x q.1) (riemannianExp x (t • q.2))/t + +lemma prefixAction_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) : + ContDiffAt ℝ ∞ (prefixAction x t) (0,p) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have he := contMDiff_riemannianExp_fiber (n := n) x + have hu : ContMDiffAt 𝓘(ℝ,V×V) 𝓘(ℝ,Model n) ∞ + (fun q : V×V => riemannianExp x q.1) (0,p) := + (he _).comp (0,p) contDiffAt_fst.contMDiffAt + have hv : ContMDiffAt 𝓘(ℝ,V×V) 𝓘(ℝ,Model n) ∞ + (fun q : V×V => riemannianExp x (t • q.2)) (0,p) := + (he _).comp (0,p) (show ContDiffAt ℝ ∞ (fun q : V×V => t • q.2) (0,p) from by fun_prop).contMDiffAt + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨x,t • p⟩ : TangentBundle 𝓘(ℝ,Model n) M) hp + have hc' : ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (0:V),riemannianExp x (t • p)) := by + simpa only [riemannianExp_zero] using hc + exact ((hc'.comp (0,p) (hu.prodMk hv)).contDiffAt.div_const t) + +lemma prefixAction_axis {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) : + prefixAction x t (0,p)=t*(‖p‖^2/2) := by + have hm := injectivityDomain_subset_minimizingVectors x hp + change dist x (riemannianExp x (t • p))=‖t • p‖ at hm + simp only [prefixAction,riemannianExp_zero,cost,hm,norm_smul,Real.norm_eq_abs, + mul_pow,sq_abs] + by_cases ht : t=0 + · simp [ht] + · field_simp + +lemma prefixAction_axis_near {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hp : t • p ∈ injectivityDomain x) : + (fun v => prefixAction x t (0,v)) =ᶠ[𝓝 p] (fun v => t*(‖v‖^2/2)) := by + have hn : ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 p, t • v ∈ injectivityDomain x := + (continuous_const_smul t).continuousAt.eventually ((isOpen_injectivityDomain x).mem_nhds hp) + filter_upwards [hn] with v hv + exact prefixAction_axis hv + +lemma prefixAction_source_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t≠0) (hp : t • p ∈ injectivityDomain x) + (a : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (prefixAction x t) (0,p) (a,0) = -inner ℝ p a := by + have hnc := ((normalCost_contDiffAt hp).differentiableAt (by simp)).hasFDerivAt + have H := hnc.mul_const t⁻¹ + have hp₀ := (hasFDerivAt_id (𝕜 := ℝ) (0 : TangentSpace 𝓘(ℝ,Model n) x)).prodMk + (hasFDerivAt_const p (0 : TangentSpace 𝓘(ℝ,Model n) x)) + have H' : HasFDerivAt (fun u => prefixAction x t (u,p)) + (t⁻¹ • fderiv ℝ (normalCost x (t • p)) 0) 0 := by + simpa only [prefixAction,normalCost,div_eq_mul_inv] using H + have hB := (prefixAction_contDiffAt hp).differentiableAt (by simp) + have heq := (hB.hasFDerivAt.comp (f := fun u => (u,p)) 0 hp₀).unique H' + have hh := congrArg (fun A : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ => A a) heq + change fderiv ℝ (prefixAction x t) (0,p) (a,0) = + t⁻¹ * fderiv ℝ (normalCost x (t • p)) 0 a at hh + rw [normalCost_fderiv_zero hp,real_inner_smul_left] at hh + rw [hh] + field_simp + +lemma prefixAction_mixed {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : t≠0) (hp : t • p ∈ injectivityDomain x) + (a d : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (prefixAction x t)) (0,p) (0,d) (a,0) = -inner ℝ d a := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hC := (prefixAction_contDiffAt hp).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hL : HasFDerivAt (fun v : V => ((0:V),v)) + ((0 : V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V)) p := + (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := (((hC.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun v : V => ((0:V),v)) p hL).clm_apply + (hasFDerivAt_const (a,(0:V)) p) + have heq : (fun v : V => fderiv ℝ (prefixAction x t) (0,v) (a,0)) =ᶠ[𝓝 p] + (fun v => -inner ℝ v a) := by + have hn := (continuous_const_smul t).continuousAt.eventually + ((isOpen_injectivityDomain x).mem_nhds hp) + filter_upwards [hn] with v hv + exact prefixAction_source_gradient ht hv a + have hi : HasFDerivAt (fun v : V => -inner ℝ v a) (-(innerSL ℝ a)) p := by + convert! ((innerSL ℝ a).hasFDerivAt (x := p)).neg using 1 + funext v; exact congrArg Neg.neg (real_inner_comm a v) + have H := congrArg (fun A : V →L[ℝ] ℝ => A d) + ((hd.congr_of_eventuallyEq heq.symm).unique hi) + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,zero_apply,map_zero,add_zero,zero_add,add_apply, + ContinuousLinearMap.comp_zero,Function.comp_apply, + ContinuousLinearMap.flip_apply,neg_apply,innerSL_apply_apply,real_inner_comm] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/PullbackDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/PullbackDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..b407472d03e0f74c68e87e0d88936648ad5db12a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/PullbackDet.lean @@ -0,0 +1,87 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.InverseProfile + +namespace OAI + +section + +noncomputable section +open Set +open scoped Topology + +namespace WeakMTWTransport +section PullbackDet +variable {E F:Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] [CompleteSpace E] [CompleteSpace F] + +lemma abs_det_hessian_pullback (B:E →L[ℝ] F) (W:F →L[ℝ] F) + (hd:Module.finrank ℝ E=Module.finrank ℝ F) : + |(B.adjoint.comp (W.comp B)).det|=B.toLinearMap.normDet^2*|W.det| := by + have h1:=LinearMap.normDet_comp_of_finrank_eq B.toLinearMap W.toLinearMap hd + have h2:=LinearMap.normDet_comp_of_finrank_eq (W.comp B).toLinearMap B.adjoint.toLinearMap hd + have h3:=LinearMap.normDet_comp_of_finrank_eq B.toLinearMap B.adjoint.toLinearMap hd + have hs:(B.adjoint.comp B).det=B.toLinearMap.normDet^2:=by + simpa only [RCLike.ofReal_real_eq_id, id_eq] using B.normDet_sq.symm + rw [LinearMap.normDet_eq_abs_det] at h2 h3 + change |(B.adjoint.comp B).det|=B.adjoint.toLinearMap.normDet*B.toLinearMap.normDet at h3 + rw [hs,abs_of_nonneg (sq_nonneg _)] at h3 + rw [LinearMap.normDet_eq_abs_det] at h1 + change |(B.adjoint.comp (W.comp B)).det|=_ at h2 + rw [h2] + change B.adjoint.toLinearMap.normDet*(W.comp B).toLinearMap.normDet=_ + rw [show (W.comp B).toLinearMap.normDet=|W.det| *B.toLinearMap.normDet from h1] + calc + _ = (B.adjoint.toLinearMap.normDet*B.toLinearMap.normDet)*|W.det| := by ring + _ = _ := by rw [←h3] + +omit [CompleteSpace E] in +lemma symmetric_det_pos {A:E →L[ℝ] E} + (hA:∀x y,inner ℝ (A x) y=inner ℝ x (A y)) + (hp:∀x,x≠0 → 0 < inner ℝ (A x) x) : 0symmetric_eigenvalue_pos hs rfl hp i) + +lemma det_positive_hessian_pullback {B:E →L[ℝ] F} {W:F →L[ℝ] F} + (hd:Module.finrank ℝ E=Module.finrank ℝ F) (hi:Function.Injective B) + (hW:∀x y,inner ℝ (W x) y=inner ℝ x (W y)) + (hp:∀x,x≠0 → 0 < inner ℝ (W x) x) {l:ℝ} (hl:0hd (hi (h.trans B.map_zero.symm)))) + refine ⟨hpos,?_⟩ + have H:=abs_det_hessian_pullback B W hd + have hpull:0<(B.adjoint.comp (W.comp B)).det:=by + apply symmetric_det_pos + · intro x y + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left, + ContinuousLinearMap.adjoint_inner_right,hW] + · intro d hd + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.adjoint_inner_left] + exact hp _ (fun h=>hd (hi (h.trans B.map_zero.symm))) + rw [abs_of_pos hpull,abs_of_pos (symmetric_det_pos hW hp)] at H + change (l • (B.adjoint.comp (W.comp B)).toLinearMap).det=_ + rw [LinearMap.det_smul] + change l^Module.finrank ℝ E*(B.adjoint.comp (W.comp B)).det=_ + rw [H] + ring +end PullbackDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/RayAnchor.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/RayAnchor.lean new file mode 100644 index 0000000000000000000000000000000000000000..663916608a8a4013bdc849aeb9302f4fd716b220 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/RayAnchor.lean @@ -0,0 +1,106 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ActualParameter +import OAI.Analysis.BiholderTransport.Geodesics.RayAdvance + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology NNReal ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma minimizing_ray_tail_cost {z : TangentBundle 𝓘(ℝ,Model n) M} + (hp : z.2∈minimizingVectors z.1) {t : ℝ} (ht : 0≤t) (ht1 : t≤1) : + cost (sprayFlow t z).1 (riemannianExp z.1 z.2)=(1-t)^2*‖z.2‖^2/2 := by + have hm : dist z.1 (sprayFlow 1 z).1=1*‖z.2‖ := by + simpa only [one_mul,riemannianExp_eq_sprayFlow] using (show dist z.1 (riemannianExp z.1 z.2)=‖z.2‖ from hp) + have H := sprayFlow_minimizing_subinterval z ht ht1 hm + rw [cost,riemannianExp_eq_sprayFlow] + change dist (sprayFlow t z).1 (sprayFlow 1 z).1^2/2=_ + rw [H,mul_pow] + +def transformRayDifference (v : M → ℝ) (z : TangentBundle 𝓘(ℝ,Model n) M) (a t : ℝ) : ℝ := + cTransform v (sprayFlow t z).1+(1-t)^2*‖z.2‖^2/2+a + +lemma transformRayDifference_lipschitzOn {v : M → ℝ} (hv : Continuous v) + (z : TangentBundle 𝓘(ℝ,Model n) M) (a T : ℝ) : + ∃ K, LipschitzOnWith K (transformRayDifference v z a) (Icc 0 T) := by + obtain ⟨K,hK⟩ := cTransform_ray_lipschitz hv z + have hc : ContDiff ℝ 1 (fun t : ℝ => (1-t)^2*‖z.2‖^2/2) := by fun_prop + obtain ⟨L,hL⟩ := hc.contDiffOn.exists_lipschitzOnWith (by norm_num) (convex_Icc 0 T) isCompact_Icc + refine ⟨K+L,?_⟩ + have H := (hK.lipschitzOnWith.add hL).add (LipschitzWith.const a).lipschitzOnWith + simp only [add_zero] at H + exact H + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma transformRayDifference_hasDerivAt {v : M → ℝ} + {z : TangentBundle 𝓘(ℝ,Model n) M} (a : ℝ) {t d : ℝ} + (hd : HasDerivAt (fun s=>cTransform v (sprayFlow s z).1) d t) : + HasDerivAt (transformRayDifference v z a) (d-(1-t)*‖z.2‖^2) t := by + have hc0 := ((((hasDerivAt_const t (1:ℝ)).sub (hasDerivAt_id t)).pow 2).mul_const (‖z.2‖^2)).div_const 2 + have hc : HasDerivAt (fun s : ℝ => (1-s)^2*‖z.2‖^2/2) (-(1-t)*‖z.2‖^2) t := by + convert hc0 using 1 <;> norm_num + first | rfl | ring + have H := (hd.add hc).add_const a + have he' : d+(-(1-t)*‖z.2‖^2)=d-(1-t)*‖z.2‖^2 := by ring + rw [he'] at H + exact H + +lemma modified_ray_difference_lower {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} (hp : z.2∈minimizingVectors z.1) + {a D b : ℝ} {B : ℝ → ℝ} (hB : Continuous B) + (ha : v (riemannianExp z.1 z.2)=a) {t : ℝ} (ht : 0≤t) (ht1 : t≤1) : + -b*B 0≤transformRayDifference (modifiedDatum v a D b B) z a t := by + have H := cTransform_gap_nonneg (continuous_modifiedDatum hv a D b hB) + (sprayFlow t z).1 (riemannianExp z.1 z.2) + rw [contactGap,modifiedDatum,ha,sub_self,zero_div,minimizing_ray_tail_cost hp ht ht1] at H + dsimp only [transformRayDifference] + linarith only [H] + +omit [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma modified_active_norm_identity {v : M → ℝ} + {z : TangentBundle 𝓘(ℝ,Model n) M} {a D b t : ℝ} {B : ℝ → ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) (sprayFlow t z).1} + (hp : p∈activeLogs (modifiedDatum v a D b B) (sprayFlow t z).1) : + ‖p‖^2=(1-t)^2*‖z.2‖^2-2*(v (riemannianExp (sprayFlow t z).1 p)-a) + -2*b*B ((v (riemannianExp (sprayFlow t z).1 p)-a)/D) + -2*transformRayDifference (modifiedDatum v a D b B) z a t := by + have hc := hp.2 + have hd : dist (sprayFlow t z).1 (riemannianExp (sprayFlow t z).1 p)=‖p‖ := hp.1 + dsimp only [contactGap,modifiedDatum,cost] at hc + rw [hd] at hc + dsimp only [transformRayDifference] + linarith only [hc] + +lemma modified_right_active_deficit {v : M → ℝ} (hv : Continuous v) + {z : TangentBundle 𝓘(ℝ,Model n) M} (hz : z.2∈minimizingVectors z.1) + {a D b t eta : ℝ} {B : ℝ → ℝ} (hB : Continuous B) + (ha : v (riemannianExp z.1 z.2)=a) (hb : 0≤b) (hD : 0 -cost x y-v y) '' S) + +omit [CompactSpace M] in +lemma exists_restrictedTransform_contact {v : M → ℝ} (hv : Continuous v) + {S : Set M} (hS : IsCompact S) (hSn : S.Nonempty) (x : M) : + ∃ y∈S, restrictedTransform v S x = -cost x y-v y ∧ + ∀ z∈S, -cost x z-v z ≤ restrictedTransform v S x := by + obtain ⟨y,hy,H⟩ := hS.exists_isMaxOn hSn + (((continuous_cost_right x).neg.sub hv).continuousOn) + have hg : IsGreatest ((fun y => -cost x y-v y) '' S) (-cost x y-v y) := by + refine ⟨mem_image_of_mem _ hy,?_⟩ + rintro _ ⟨z,hz,rfl⟩ + exact H hz + refine ⟨y,hy,hg.csSup_eq,?_⟩ + intro z hz + rw [restrictedTransform,hg.csSup_eq] + exact H hz + +omit [CompactSpace M] in +lemma restrictedTransform_lipschitz {v : M → ℝ} (hv : Continuous v) + {S : Set M} (hS : IsCompact S) (hSn : S.Nonempty) {D : ℝ≥0} + (hD : ∀ x y : M,dist x y≤D) : LipschitzWith D (restrictedTransform v S) := by + rw [lipschitzWith_iff_dist_le_mul] + intro x x' + obtain ⟨y,hy,he,H⟩ := exists_restrictedTransform_contact hv hS hSn x + obtain ⟨y',hy',he',H'⟩ := exists_restrictedTransform_contact hv hS hSn x' + have A := H y' hy' + have B := H' y hy + have C := (abs_le.mp (cost_lipschitz_of_distance_bound hD x x' y)).1 + have C' := (abs_le.mp (cost_lipschitz_of_distance_bound hD x x' y')).2 + rw [Real.dist_eq,abs_le] + constructor <;> linarith only [he,he',A,B,C,C'] + +lemma continuous_restrictedTransform {v : M → ℝ} (hv : Continuous v) + {S : Set M} (hS : IsCompact S) (hSn : S.Nonempty) : + Continuous (restrictedTransform v S) := by + let D : ℝ≥0 := ⟨Metric.diam (univ:Set M),Metric.diam_nonneg⟩ + exact (restrictedTransform_lipschitz hv hS hSn (D := D) + (fun x y => Metric.dist_le_diam_of_mem isCompact_univ.isBounded + (mem_univ x) (mem_univ y))).continuous + +variable [Nonempty M] + +lemma restrictedTransform_le {v : M → ℝ} (hv : Continuous v) + {S : Set M} (hS : IsCompact S) (hSn : S.Nonempty) (x : M) : + restrictedTransform v S x ≤ cTransform v x := by + obtain ⟨y,hy,he,H⟩ := exists_restrictedTransform_contact hv hS hSn x + rw [he] + have Hc := cTransform_gap_nonneg hv x y + dsimp only [contactGap] at Hc + linarith only [Hc] + +lemma restrictedTransform_eq_of_contact {v : M → ℝ} (hv : Continuous v) + {S : Set M} (hS : IsCompact S) (hSn : S.Nonempty) {x y : M} + (hy : y∈S) (hc : contactGap (cTransform v) v x y=0) : + restrictedTransform v S x=cTransform v x := by + obtain ⟨z,hz,he,H⟩ := exists_restrictedTransform_contact hv hS hSn x + have H' := H y hy + have Hc := restrictedTransform_le hv hS hSn x + dsimp only [contactGap] at hc + linarith only [H',Hc,hc] + +lemma cTransform_eq_max_restricted {v : M → ℝ} (hv : Continuous v) + {S R : Set M} (hS : IsCompact S) (hSn : S.Nonempty) + (hR : IsCompact R) (hRn : R.Nonempty) {x : M} + (hcover : ∀ y, contactGap (cTransform v) v x y=0 → y∈S ∪ R) : + cTransform v x=max (restrictedTransform v S x) (restrictedTransform v R x) := by + have hle := max_le (restrictedTransform_le hv hS hSn x) + (restrictedTransform_le hv hR hRn x) + obtain ⟨y,hy,_⟩ := exists_cTransform_contact hv x + have hc : contactGap (cTransform v) v x y=0 := by + dsimp [contactGap]; linarith only [hy] + rcases hcover y hc with h|h + · rw [restrictedTransform_eq_of_contact hv hS hSn h hc] + exact (max_eq_left (restrictedTransform_le hv hR hRn x)).symm + · rw [restrictedTransform_eq_of_contact hv hR hRn h hc] + exact (max_eq_right (restrictedTransform_le hv hS hSn x)).symm + +end RestrictedTransform +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/Reversal.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/Reversal.lean new file mode 100644 index 0000000000000000000000000000000000000000..2936e69ef6a833799aef3ab80a6d43ece35a5725 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/Reversal.lean @@ -0,0 +1,60 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.ReverseRegular + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +section Reversal +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma reverseRay_reverseRay (z : TangentBundle 𝓘(ℝ,Model n) M) : + reverseRay (reverseRay z)=z := by + unfold reverseRay + rw [sprayFlow_reverse] + rcases z with ⟨x,v⟩ + change (⟨x,(-1:ℝ) • ((-1:ℝ) • v)⟩ : TangentBundle 𝓘(ℝ,Model n) M)=⟨x,v⟩ + rw [neg_one_smul,neg_one_smul,neg_neg] + +lemma reverseRay_injectivityDomain {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈injectivityDomain z.1) : + (reverseRay z).2∈injectivityDomain (reverseRay z).1 := by + have hi := interior_total_minimizingVectors z hz + have H : ∀ᶠ w : TangentBundle 𝓘(ℝ,Model n) M in 𝓝 (reverseRay z), + (reverseRay w).2∈minimizingVectors (reverseRay w).1 := by + have hN := continuous_reverseRay.continuousAt.preimage_mem_nhds + (show {q : TangentBundle 𝓘(ℝ,Model n) M | q.2∈minimizingVectors q.1} ∈ + 𝓝 (reverseRay (reverseRay z)) from by + rw [reverseRay_reverseRay]; exact mem_interior_iff_mem_nhds.mp hi) + exact hN + have hj : reverseRay z∈interior {q : TangentBundle 𝓘(ℝ,Model n) M | + q.2∈minimizingVectors q.1} := by + apply mem_interior_iff_mem_nhds.mpr + filter_upwards [H] with w hw + have hh := reverseRay_minimizing hw + change reverseRay (reverseRay w)∈{q : TangentBundle 𝓘(ℝ,Model n) M | + q.2∈minimizingVectors q.1} at hh + rwa [reverseRay_reverseRay] at hh + rwa [←total_injectivityDomain_eq_interior] at hj + +end Reversal +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ReverseRegular.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ReverseRegular.lean new file mode 100644 index 0000000000000000000000000000000000000000..1229f92451b2e9fcb34164ee9fd53fb96e3d965a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ReverseRegular.lean @@ -0,0 +1,65 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.TotalInjectivity + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def reverseRay (z : TangentBundle 𝓘(ℝ,Model n) M) := tangentScale (-1) (sprayFlow 1 z) + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma reverseRay_involutive : Function.Involutive (reverseRay (n := n) (M := M)) := by + intro z + dsimp only [reverseRay] + rw [sprayFlow_reverse] + rcases z with ⟨x,p⟩ + change (⟨x,(-1:ℝ) • ((-1:ℝ) • p)⟩ : TangentBundle 𝓘(ℝ,Model n) M)=⟨x,p⟩ + rw [neg_one_smul,neg_one_smul,neg_neg] + +omit [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma continuous_reverseRay : Continuous (reverseRay (n := n) (M := M)) := by + exact contMDiff_tangentScale.continuous.comp + (continuous_const.prodMk (contMDiff_sprayFlow.continuous.comp + (continuous_const.prodMk continuous_id))) + +lemma reverseRay_minimizing {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈minimizingVectors z.1) : + (reverseRay z).2∈minimizingVectors (reverseRay z).1 := by + change dist (reverseRay z).1 (riemannianExp (reverseRay z).1 (reverseRay z).2)=‖(reverseRay z).2‖ + rw [riemannianExp_eq_sprayFlow] + change dist (sprayFlow 1 z).1 (sprayFlow 1 (tangentScale (-1) (sprayFlow 1 z))).1= + ‖(-1:ℝ) • (sprayFlow 1 z).2‖ + rw [sprayFlow_reverse,neg_one_smul,norm_neg,sprayFlow_speed] + change dist (sprayFlow 1 z).1 z.1=‖z.2‖ + rw [dist_comm,←riemannianExp_eq_sprayFlow] + exact hz + +lemma reverseRay_regular {z : TangentBundle 𝓘(ℝ,Model n) M} + (hz : z.2∈injectivityDomain z.1) : + (reverseRay z).2∈injectivityDomain (reverseRay z).1 := by + have hzi := interior_total_minimizingVectors z hz + have H := continuous_reverseRay.continuousAt.eventually + (show ∀ᶠ q in 𝓝 (reverseRay (reverseRay z)), q.2∈minimizingVectors q.1 from + by rw [reverseRay_involutive z]; exact mem_interior_iff_mem_nhds.mp hzi) + have HR : ∀ᶠ q in 𝓝 (reverseRay z), q.2∈minimizingVectors q.1 := by + filter_upwards [H] with q hq + exact (reverseRay_involutive q) ▸ (reverseRay_minimizing hq) + have HI : reverseRay z∈interior {q : TangentBundle 𝓘(ℝ,Model n) M | q.2∈minimizingVectors q.1} := + mem_interior_iff_mem_nhds.mpr HR + rwa [←total_injectivityDomain_eq_interior] at HI + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/RiemannianMetricSegment.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/RiemannianMetricSegment.lean new file mode 100644 index 0000000000000000000000000000000000000000..98cb54a45e7b3739ba1c9afe438135aecf436bfd --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/RiemannianMetricSegment.lean @@ -0,0 +1,42 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.JensenHessian +import OAI.Analysis.BiholderTransport.Geodesics.MetricSegments + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +namespace WeakMTWTransport +open Set Manifold Bundle +open scoped ContDiff + +lemma riemannian_exists_metric_segment + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [MetricSpace M] [CompactSpace M] [ChartedSpace H M] + [RiemannianBundle (fun x : M => TangentSpace I x)] + [IsRiemannianManifold I M] (x y : M) : + ∃ γ : Icc (0:ℝ) (dist x y) → M, Isometry γ ∧ + γ ⟨0,⟨le_rfl,dist_nonneg⟩⟩ = x ∧ + γ ⟨dist x y,⟨dist_nonneg,le_rfl⟩⟩ = y := + exists_metric_segment x y (riemannian_exists_midpoint (I := I)) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/RoughLinear.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/RoughLinear.lean new file mode 100644 index 0000000000000000000000000000000000000000..b3fc86faf97b8dfe9897d65104dadffa7919f50b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/RoughLinear.lean @@ -0,0 +1,28 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ShortEnvelopeSemibound + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] +lemma second_fderiv_comp_linear_at {f : F → ℝ} (L : E →L[ℝ] F) {x : E} + (hnear : ∀ᶠ y in 𝓝 (L x),DifferentiableAt ℝ f y) + (hf : DifferentiableAt ℝ (fderiv ℝ f) (L x)) (d e : E) : + fderiv ℝ (fderiv ℝ (fun q=>f (L q))) x d e= + fderiv ℝ (fderiv ℝ f) (L x) (L d) (L e) := by + have hl : (fderiv ℝ L)=(fun _ : E=>L) := by funext q; exact L.fderiv + have H := second_fderiv_comp_at hnear hf (L.contDiff (n := 2)).contDiffAt d e + rw [hl] at H + have hz : fderiv ℝ (fun _ : E => L) x = 0 := fderiv_const_apply L + rw [hz] at H + simpa using H +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SampleCenterFamilies.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SampleCenterFamilies.lean new file mode 100644 index 0000000000000000000000000000000000000000..3199b41ce03f724b8a186374909b1c7b2631225e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SampleCenterFamilies.lean @@ -0,0 +1,75 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Convexity.ActualCenterSemibound +import OAI.Analysis.BiholderTransport.Convexity.JensenPackage + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +section SampleCenterFamilies +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma WeakMTW.coordinateBackward_graph_pole (hmtw : WeakMTW (n := n) (M := M)) + {v : M → ℝ} (hv : Continuous v) {t : ℝ} (ht : 0Φ (γj i,s)) (xj i) + (graphProjection (cTransform (wj i)) (tj i) (q i)) (τj i) (lj i)) + (hd : ∀ᶠ i in atTop, + (∀ᶠ z in 𝓝 (extChartAt 𝓘(ℝ,Model n) c (graphProjection (cTransform (wj i)) (tj i) (q i))), + DifferentiableAt ℝ (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) + ((extChartAt 𝓘(ℝ,Model n) c).symm z)) z) ∧ + DifferentiableAt ℝ (fderiv ℝ (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) + ((extChartAt 𝓘(ℝ,Model n) c).symm z))) + (extChartAt 𝓘(ℝ,Model n) c (graphProjection (cTransform (wj i)) (tj i) (q i)))) + (hg : Tendsto (fun i=>fderiv ℝ (chartOuterEnvelope (wj i) (tj i) c) + (extChartAt 𝓘(ℝ,Model n) c (graphProjection (cTransform (wj i)) (tj i) (q i)))+ + fderiv ℝ (fun z=>hopfLax (τj i) (fun y=>Φ (γj i,v y)) + ((extChartAt 𝓘(ℝ,Model n) c).symm z)) + (extChartAt 𝓘(ℝ,Model n) c (graphProjection (cTransform (wj i)) (tj i) (q i)))) atTop (𝓝 0)) : + CenterSequenceData a c u v Φ γj lj τj tj xj + (fun i=>graphBaseCoordinate a (q i).1) (fun i=>graphVelocityCoordinate a (q i).1) + (fun i=>graphProjection (cTransform (wj i)) (tj i) (q i)) + (fun i=>chartOuterEnvelope (wj i) (tj i) c) where + row := R + endpoint i := movingPrefix_graph_coordinates (ha i) (tj i) + derivative := hd + gradient := hg + backward := Eventually.of_forall (fun i=>by + rw [hmtw.coordinateBackward_graph_pole (hw i) (ht i) (ht1 i) (q i) (hc i)] + exact ((extChartAt 𝓘(ℝ,Model n) a).left_inv (ha i)).symm) + +end SampleCenterFamilies +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivAdd.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivAdd.lean new file mode 100644 index 0000000000000000000000000000000000000000..4a2acea1bbad494a65a048241663079cbefcbc92 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivAdd.lean @@ -0,0 +1,26 @@ +import Mathlib + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma second_fderiv_add_eq {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {f g : E → ℝ} {z : E} (hf : ContDiffAt ℝ 2 f z) (hg : ContDiffAt ℝ 2 g z) : + fderiv ℝ (fderiv ℝ (fun w => f w+g w)) z = + fderiv ℝ (fderiv ℝ f) z+fderiv ℝ (fderiv ℝ g) z := by + have he : fderiv ℝ (fun w => f w+g w) =ᶠ[𝓝 z] + (fun w => fderiv ℝ f w+fderiv ℝ g w) := by + filter_upwards [hf.eventually (by norm_num),hg.eventually (by norm_num)] with w hw hw' + exact fderiv_fun_add (hw.differentiableAt (by norm_num)) (hw'.differentiableAt (by norm_num)) + rw [he.fderiv_eq] + exact fderiv_fun_add ((hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)) + ((hg.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)) + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivCompLinear.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivCompLinear.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf88dc932c0e42b1e965d534ae63af028f97f6ce --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondFderivCompLinear.lean @@ -0,0 +1,28 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSmooth + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma second_fderiv_comp_linear_zero {E F : Type*} + [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + {f : F → ℝ} (hf : ContDiffAt ℝ 2 f 0) (L : E →L[ℝ] F) (v : E) : + fderiv ℝ (fderiv ℝ (fun h => f (L h))) 0 v v = + fderiv ℝ (fderiv ℝ f) 0 (L v) (L v) := by + have hcomp : ContDiffAt ℝ 2 (fun h => f (L h)) 0 := + (show ContDiffAt ℝ 2 f (L 0) by simpa using hf).comp 0 L.contDiff.contDiffAt + rw [← iteratedDeriv_two_affine_line hcomp v, ← iteratedDeriv_two_affine_line hf (L v)] + congr 2 + ext t + simp only [map_smul,zero_add] + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SecondScaled.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondScaled.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce3215d30034f1aa8f774003bac0747d8597ff7d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SecondScaled.lean @@ -0,0 +1,213 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.HessianSmooth + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped Topology + +open Set Filter +open scoped Topology ContDiff + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] +lemma second_fderiv_scaled_differences {f g : E → ℝ} + (hf : ContDiffAt ℝ 2 f 0) (hg : ContDiffAt ℝ 2 g 0) (a b : ℝ) (v : E) : + fderiv ℝ (fderiv ℝ (fun h => a*(f h-f 0)-b*(g h-g 0))) 0 v v = + a*fderiv ℝ (fderiv ℝ f) 0 v v-b*fderiv ℝ (fderiv ℝ g) 0 v v := by + have hline : ContDiffAt ℝ 2 (fun t : ℝ => (0:E)+t • v) 0 := by fun_prop + have hfl : ContDiffAt ℝ 2 (fun t : ℝ => f ((0:E)+t • v)) 0 := + (show ContDiffAt ℝ 2 f ((0:E)+(0:ℝ) • v) by simpa using hf).comp 0 hline + have hgl : ContDiffAt ℝ 2 (fun t : ℝ => g ((0:E)+t • v)) 0 := + (show ContDiffAt ℝ 2 g ((0:E)+(0:ℝ) • v) by simpa using hg).comp 0 hline + have hF : ContDiffAt ℝ 2 (fun h => a*(f h-f 0)-b*(g h-g 0)) 0 := + (contDiffAt_const.mul (hf.sub contDiffAt_const)).sub (contDiffAt_const.mul (hg.sub contDiffAt_const)) + rw [←iteratedDeriv_two_affine_line hF v, + iteratedDeriv_fun_sub (contDiffAt_const.mul (hfl.sub contDiffAt_const)) + (contDiffAt_const.mul (hgl.sub contDiffAt_const)), + iteratedDeriv_const_mul_field,iteratedDeriv_const_mul_field, + iteratedDeriv_fun_sub hfl contDiffAt_const,iteratedDeriv_fun_sub hgl contDiffAt_const] + simp only [iteratedDeriv_const,ite_false,show (2:ℕ)≠0 by norm_num,sub_zero, + iteratedDeriv_two_affine_line hf v,iteratedDeriv_two_affine_line hg v] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ShortForward.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ShortForward.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a52f1227c1da1f46a61e6251a1a68941773941d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ShortForward.lean @@ -0,0 +1,173 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.LiftedSections +import OAI.Analysis.BiholderTransport.Coordinates.ChartGradientMap +import OAI.Analysis.BiholderTransport.Calculus.ShortSmoothFamily + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def shortForward (a : M) (ψ : Model n → ℝ) (q : ℝ×Model n) : Model n := + extChartAt 𝓘(ℝ,Model n) a (coordinateBackward a (-1,q.2,q.1 • fderiv ℝ ψ q.2)) + +def shortEnergy (a : M) (ψ : Model n → ℝ) (y : Model n) : ℝ := + fderiv ℝ ψ y ((riemannianCoordinateMetric a y).inverse (fderiv ℝ ψ y))/2 + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma shortEnergy_eq_norm {a : M} {y : Model n} + (hy : y∈(extChartAt 𝓘(ℝ,Model n) a).target) (ψ : Model n → ℝ) : + shortEnergy a ψ y=‖chartGradientVector a y (fderiv ℝ ψ y)‖^2/2 := by + have H := (riemannianCoordinateMetric_isInvertible hy).self_apply_inverse (fderiv ℝ ψ y) + have He := congrArg (fun L : Model n →L[ℝ] ℝ => + L ((riemannianCoordinateMetric a y).inverse (fderiv ℝ ψ y))) H + rw [riemannianCoordinateMetric_apply,real_inner_self_eq_norm_sq] at He + exact congrArg (fun t : ℝ => t/2) He.symm + +omit [CompactSpace M] [Nonempty M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma shortForward_zero {a : M} {ψ : Model n → ℝ} {y : Model n} + (hy : y∈(extChartAt 𝓘(ℝ,Model n) a).target) : shortForward a ψ (0,y)=y := by + simp only [shortForward,zero_smul,coordinateBackward,map_zero,smul_zero] + rw [movingNormal_zero hy,(extChartAt 𝓘(ℝ,Model n) a).right_inv hy] + +omit [Nonempty M] in +lemma shortForward_action {a : M} {ψ : Model n → ℝ} {q : ℝ×Model n} + (hq : q.2∈(extChartAt 𝓘(ℝ,Model n) a).target) + (hp : chartGradientVector a q.2 (q.1 • fderiv ℝ ψ q.2)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm q.2)) : + cost ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) + (coordinateBackward a (-1,q.2,q.1 • fderiv ℝ ψ q.2))=q.1^2*shortEnergy a ψ q.2 ∧ + HasFDerivAt (chartCost a (coordinateBackward a (-1,q.2,q.1 • fderiv ℝ ψ q.2))) + (-(q.1 • fderiv ℝ ψ q.2)) q.2 := by + refine ⟨?_,chartCost_gradient_at_contact hq hp⟩ + rw [coordinateBackward_eq_exp_chartGradient hq, + cost_minimizingVector (injectivityDomain_subset_minimizingVectors _ hp),shortEnergy_eq_norm hq] + simp only [chartGradientVector,map_smul,norm_smul,Real.norm_eq_abs,mul_pow,sq_abs] + ring +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] [CompleteSpace P] + +def parametricShortForward (a : M) (ψ : P×Model n → ℝ) (q : (P×ℝ)×Model n) : Model n := + shortForward a (fun y => ψ (q.1.1,y)) (q.1.2,q.2) + +def parametricShortEnergy (a : M) (ψ : P×Model n → ℝ) (q : P×Model n) : ℝ := + shortEnergy a (fun y => ψ (q.1,y)) q.2 + +omit [CompactSpace M] [Nonempty M] [IsRiemannianManifold 𝓘(ℝ,Model n) M] + [CompleteSpace P] in +lemma parametricShortEnergy_contDiffAt {a : M} {ψ : P×Model n → ℝ} {p : P} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ContDiffAt ℝ ∞ (parametricShortEnergy a ψ) (p,x) := by + have hD := ContDiffAt.partial_snd_fderiv (f := fun p y => ψ (p,y)) hψ + have hg := ((contDiffOn_riemannianCoordinateMetric (E := Model n) a).contDiffAt + ((isOpen_extChartAt_target a).mem_nhds hx)).comp (f := Prod.snd) (p,x) contDiffAt_snd + have hi := (riemannianCoordinateMetric_isInvertible hx).contDiffAt_map_inverse.comp + (f := fun q : P×Model n => riemannianCoordinateMetric a q.2) (p,x) hg + exact (hD.clm_apply (hi.clm_apply hD)).div_const 2 + +omit [Nonempty M] [CompleteSpace P] in +lemma parametricShortForward_contDiffAt {a : M} {ψ : P×Model n → ℝ} {p : P} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ContDiffAt ℝ ∞ (parametricShortForward a ψ) ((p,0),x) := by + have hD := ContDiffAt.partial_snd_fderiv (f := fun p y => ψ (p,y)) hψ + let A : (P×ℝ)×Model n → (ℝ×Model n×(Model n →L[ℝ] ℝ)) := fun q => + (-1,q.2,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2) + have hA : ContDiffAt ℝ ∞ A ((p,0),x) := + contDiffAt_const.prodMk (contDiffAt_snd.prodMk + (contDiffAt_fst.snd.smul (hD.comp (f := fun q : (P×ℝ)×Model n => (q.1.1,q.2)) + ((p,0),x) (contDiffAt_fst.fst.prodMk contDiffAt_snd)))) + have hC : ContMDiffAt 𝓘(ℝ,(P×ℝ)×Model n) 𝓘(ℝ,Model n) ∞ + (coordinateBackward a ∘ A) ((p,0),x) := + (coordinateBackward_contMDiffAt (q := A ((p,0),x)) hx).comp + (f := A) ((p,0),x) hA.contMDiffAt + have he : coordinateBackward a (A ((p,0),x))=(extChartAt 𝓘(ℝ,Model n) a).symm x := by + simp only [A,coordinateBackward,zero_smul,map_zero,smul_zero,movingNormal_zero hx] + have hc : ContMDiffAt 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) ∞ (extChartAt 𝓘(ℝ,Model n) a) + (coordinateBackward a (A ((p,0),x))) := by + rw [he] + exact contMDiffAt_extChartAt' (by simpa only [extChartAt_source] using + (extChartAt 𝓘(ℝ,Model n) a).map_target hx) + exact (hc.comp (f := coordinateBackward a ∘ A) ((p,0),x) hC).contDiffAt + +omit [Nonempty M] [CompleteSpace P] in +lemma parametricShortForward_regular_near {a : M} {ψ : P×Model n → ℝ} {p : P} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ∀ᶠ q : (P×ℝ)×Model n in 𝓝 ((p,0),x), + q.2∈(extChartAt 𝓘(ℝ,Model n) a).target ∧ + chartGradientVector a q.2 (q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2)∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) ∧ + coordinateBackward a (-1,q.2,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2)∈ + (extChartAt 𝓘(ℝ,Model n) a).source := by + have hD := (ContDiffAt.partial_snd_fderiv (f := fun p y => ψ (p,y)) hψ).continuousAt + let A : (P×ℝ)×Model n → Model n×(Model n →L[ℝ] ℝ) := fun q => + (q.2,q.1.2 • fderiv ℝ (fun y => ψ (q.1.1,y)) q.2) + have hA : ContinuousAt A ((p,0),x) := continuousAt_snd.prodMk + (continuousAt_fst.snd.smul (hD.comp (x := ((p,0),x)) + (continuousAt_fst.fst.prodMk continuousAt_snd))) + have hp : chartGradientVector a (A ((p,0),x)).1 (A ((p,0),x)).2∈ + injectivityDomain ((extChartAt 𝓘(ℝ,Model n) a).symm x) := by + simpa only [A,chartGradientVector,zero_smul,map_zero] using zero_mem_injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm x) + have ha := hA.eventually (chartGradientVector_regular_near hx hp) + have hs : ∀ᶠ q : (P×ℝ)×Model n in 𝓝 ((p,0),x), + q.2∈(extChartAt 𝓘(ℝ,Model n) a).target := + continuousAt_snd.preimage_mem_nhds ((isOpen_extChartAt_target a).mem_nhds hx) + have hc := ((coordinateBackward_contMDiffAt (q := (-1,A ((p,0),x))) hx).continuousAt.comp + (x := ((p,0),x)) (continuousAt_const.prodMk hA)) + have he : coordinateBackward a (-1,A ((p,0),x))=(extChartAt 𝓘(ℝ,Model n) a).symm x := by + simp only [A,coordinateBackward,zero_smul,map_zero,smul_zero,movingNormal_zero hx] + have hb := hc.preimage_mem_nhds ((isOpen_extChartAt_source a).mem_nhds + (he.symm ▸ (extChartAt 𝓘(ℝ,Model n) a).map_target hx)) + exact hs.and (ha.and hb) + +omit [Nonempty M] in +lemma geometric_parametric_short_family {a : M} {ψ : P×Model n → ℝ} {p : P} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ∃ (B : (P×ℝ)×Model n → Model n) (U : (P×ℝ)×Model n → ℝ), + ContDiffAt ℝ ∞ B ((p,0),x) ∧ ContDiffAt ℝ ∞ U ((p,0),x) ∧ B ((p,0),x)=x ∧ + (∀ᶠ q in 𝓝 ((p,0),x),parametricShortForward a ψ (q.1,B q)=q.2) ∧ + (∀ᶠ q in 𝓝 ((p,0),x),B (q.1,parametricShortForward a ψ q)=q.2) ∧ + (∀ q,U q=ψ (q.1.1,B q)+q.1.2*parametricShortEnergy a ψ (q.1.1,B q)) ∧ + Tendsto (fun q : (P×ℝ)×Model n => fderiv ℝ (fderiv ℝ (fun y => U (q.1,y))) q.2) + (𝓝 ((p,0),x)) (𝓝 (fderiv ℝ (fderiv ℝ (fun y => ψ (p,y))) x)) := by + apply parametric_smooth_short_action (parametricShortForward_contDiffAt hx hψ) _ hψ + (parametricShortEnergy_contDiffAt hx hψ) + filter_upwards [(isOpen_extChartAt_target a).mem_nhds hx] with y hy + exact shortForward_zero hy + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/ShortSelectorNonsingularity.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/ShortSelectorNonsingularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d3c3944ca543e373b4e7b562f6e67668280d814 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/ShortSelectorNonsingularity.lean @@ -0,0 +1,129 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.EuclideanUpper +import OAI.Analysis.BiholderTransport.LinearAlgebra.DiagonalCostConvexity +import OAI.Analysis.BiholderTransport.Coordinates.ShortLocalMinimum +import OAI.Analysis.BiholderTransport.Contact.SmoothSupportSemibound +import OAI.Analysis.BiholderTransport.LinearAlgebra.EnvelopeKernelHessian + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma second_fderiv_partial_snd {C : E×E → ℝ} {a b : E} + (hC : ContDiffAt ℝ 2 C (a,b)) (v w:E) : + fderiv ℝ (fderiv ℝ (fun z => C (a,z))) b v w = + fderiv ℝ (fderiv ℝ C) (a,b) (0,v) (0,w) := by + have hg : ContDiffAt ℝ 2 (fun z:E => (a,z)) b := contDiffAt_const.prodMk contDiffAt_id + have hD : fderiv ℝ (fun z:E => (a,z)) = fun _ => + (0 : E →L[ℝ] E).prod (ContinuousLinearMap.id ℝ E) := by + funext z + exact ((hasFDerivAt_const a z).prodMk (hasFDerivAt_id z)).fderiv + rw [second_fderiv_comp_with_acceleration hC hg,hD] + rw [show fderiv ℝ (fun _ : E => (0 : E →L[ℝ] E).prod (ContinuousLinearMap.id ℝ E)) b=0 from + (hasFDerivAt_const _ b).fderiv] + simp only [ContinuousLinearMap.prod_apply,zero_apply, + ContinuousLinearMap.id_apply,map_zero,add_zero] + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma exists_chart_cost_kernel_gap {a:M} {x:Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) : + let C := fun q:Model n×Model n => chartCost a + ((extChartAt 𝓘(ℝ,Model n) a).symm q.1) q.2 + ∃ m>0, ∀ᶠ q in 𝓝 (x,x), ContDiffAt ℝ 2 C q ∧ + ∀ d:Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ C) q (0,d) (0,d) := by + let : NormedAddCommGroup (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedAddCommGroup + let : NormedSpace ℝ (Model n →L[ℝ] ℝ) := ContinuousLinearMap.toNormedSpace + let : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := + ContinuousLinearMap.toNormedAddCommGroup + dsimp only + let F := fun y:Model n => chartCost (n := n) a ((extChartAt 𝓘(ℝ,Model n) a).symm y) + have hc := chartCost_pair_contDiffAt_diagonal hx + have hH : ContinuousAt (fun q:Model n×Model n => fderiv ℝ (fderiv ℝ (F q.1)) q.2) (x,x) := + (ContDiffAt.partial_snd_fderiv_two (f := F) hc).continuousAt + obtain ⟨k,hk,hpos⟩ := chartCost_diagonal_coercive hx + have hdiff : ContinuousAt (fun q:Model n×Model n => + fderiv ℝ (fderiv ℝ (F q.1)) q.2-fderiv ℝ (fderiv ℝ (F x)) x) (x,x) := + hH.sub continuousAt_const + have hnorm := hdiff.norm + have hn : ∀ᶠ q:Model n×Model n in 𝓝 (x,x), + ‖fderiv ℝ (fderiv ℝ (F q.1)) q.2-fderiv ℝ (fderiv ℝ (F x)) x‖ < k/2 := by + apply hnorm.eventually_lt continuousAt_const + simpa only [Pi.sub_apply,Prod.fst,Prod.snd,sub_self,ContinuousLinearMap.opNorm_zero] using half_pos hk + refine ⟨k/2,half_pos hk,?_⟩ + filter_upwards [hn,(hc.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp)] with q hq hreg + refine ⟨hreg,fun d => ?_⟩ + rw [←second_fderiv_partial_snd hreg d d] + have hb := bilinear_diag_sub_bound (fderiv ℝ (fderiv ℝ (F q.1)) q.2) + (fderiv ℝ (fderiv ℝ (F x)) x) d + have hh := hpos d + have hm := mul_le_mul_of_nonneg_right hq.le (sq_nonneg ‖d‖) + have ha := (abs_le.mp hb).1 + change k/2*‖d‖^2≤fderiv ℝ (fderiv ℝ (F q.1)) q.2 d d + linarith only [hh,hm,ha] + +lemma actual_short_selector_injective_near {a:M} {x:Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) : + ∃ m>0, ∀ᶠ q:Model n×Model n in 𝓝 (x,x), + ∀ t : ℝ, 0 < t → ∀ u : M → ℝ, Continuous u → + ∀ Y:Model n → Model n,∀ R:Model n →L[ℝ] Model n, + Y q.2=q.1 → HasFDerivAt Y R q.2 → + let χ := extChartAt 𝓘(ℝ,Model n) a + let G := fun z:Model n => hopfLax t u (χ.symm z) + (∀ᶠ z in 𝓝 q.2,G z=u (χ.symm (Y z))+chartCost a (χ.symm (Y z)) z/t) → + (∀ᶠ z in 𝓝 q.2,DifferentiableAt ℝ G z) → + ∀ b : ℝ, t*b < m → + (∀ d:Model n,fderiv ℝ (fderiv ℝ G) q.2 d d≤b*‖d‖^2) → + Function.Injective R := by + obtain ⟨m,hm,H⟩ := exists_chart_cost_kernel_gap hx + refine ⟨m,hm,?_⟩ + filter_upwards [H] with q hq + intro t ht u hu Y R hY hR + dsimp only + intro hcontact hd b hb hupp + let χ := extChartAt 𝓘(ℝ,Model n) a + let G := fun z:Model n => hopfLax t u (χ.symm z) + let C := fun z:Model n×Model n => t⁻¹*chartCost a (χ.symm z.1) z.2 + have hc : ContDiffAt ℝ 2 C (Y q.2,q.2) := by + rw [hY] + exact contDiffAt_const.mul hq.1 + have hs : ∀ᶠ z in 𝓝 q.2,∀ᶠ v in 𝓝 z, + G v≤G z+C (Y z,v)-C (Y z,z) := by + filter_upwards [hcontact] with z hz + apply Filter.Eventually.of_forall + intro v + have hv := hopfLax_le hu t (χ.symm v) (χ.symm (Y z)) + rw [cost_symm] at hv + change G v≤u (χ.symm (Y z))+chartCost a (χ.symm (Y z)) v/t at hv + change G z=u (χ.symm (Y z))+chartCost a (χ.symm (Y z)) z/t at hz + dsimp only [C] + rw [hz] + convert hv using 1 + ring + apply envelope_selector_injective_of_hessian_gap hc hR hd hs + (show b < m/t from (lt_div_iff₀ ht).mpr (by linarith only [hb])) hupp + intro d + rw [hY] + change (m/t)*‖d‖^2≤fderiv ℝ (fderiv ℝ (fun z:Model n×Model n => + t⁻¹*chartCost a (χ.symm z.1) z.2)) q (0,d) (0,d) + rw [second_fderiv_const_mul] + have HH := mul_le_mul_of_nonneg_left (hq.2 d) (inv_nonneg.mpr ht.le) + convert HH using 1 + first | rfl | ring + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SingularValuesBound.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SingularValuesBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..3718eb5524fc4d87e5bc6dcc2d490985e21aa846 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SingularValuesBound.lean @@ -0,0 +1,37 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport + +lemma singularValues_le_of_bound {E F : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [NormedAddCommGroup F] [InnerProductSpace ℝ F] + [FiniteDimensional ℝ F] (A : E →ₗ[ℝ] F) {u : ℝ} (hu : 0 ≤ u) + (h : ∀ v, ‖A v‖ ≤ u*‖v‖) {n : ℕ} (hn : Module.finrank ℝ E=n) (i : Fin n) : + A.singularValues i ≤ u := by + let hS := A.isSymmetric_adjoint_comp_self + let v := hS.eigenvectorBasis hn i + have hv : ‖v‖=1 := (hS.eigenvectorBasis hn).orthonormal.norm_eq_one i + have he := congrArg (fun w => inner ℝ w v) (hS.apply_eigenvectorBasis hn i) + simp only [LinearMap.comp_apply,LinearMap.adjoint_inner_left, + real_inner_smul_left,RCLike.ofReal_real_eq_id,id_eq] at he + change inner ℝ (A v) (A v)=hS.eigenvalues hn i*inner ℝ v v at he + simp only [real_inner_self_eq_norm_sq] at he + rw [←A.sq_singularValues_fin hn, hv] at he + have HH := h v + rw [hv,mul_one] at HH + have hs := A.singularValues_nonneg i + nlinarith [norm_nonneg (A v)] + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SmallAffineTimeTube.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SmallAffineTimeTube.lean new file mode 100644 index 0000000000000000000000000000000000000000..4656e14fc04a5cff889d3d9ba743854a62a0f666 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SmallAffineTimeTube.lean @@ -0,0 +1,109 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +namespace WeakMTWTransport +lemma exists_small_affine_time_tube (a : ℝ) {h τ r η : ℝ} + (hh : 0 < h) (hτ : 0 < τ) (hr : 0 < r) (hη : 0 < η) : + ∃ ε : ℝ, 0 < ε ∧ ε ≤ η ∧ ε ≤ h ∧ + ∀ s u t : ℝ, |s-a| < ε → |u-a| < ε → |t| < r → + |s + (u-s)/τ*t-a| < h := by + let ε := min (h/4) (min η (h*τ/(8*r))) + have hε : 0 < ε := lt_min (by positivity) + (lt_min hη (div_pos (mul_pos hh hτ) (by positivity))) + have hεh : ε ≤ h/4 := min_le_left _ _ + have hεη : ε ≤ η := (min_le_right _ _).trans (min_le_left _ _) + have hεr : ε ≤ h*τ/(8*r) := (min_le_right _ _).trans (min_le_right _ _) + refine ⟨ε,hε,hεη,by linarith,?_⟩ + intro s u t hs hu ht + have hus : |u-s| < 2*ε := by + calc + |u-s| = |(u-a)+(a-s)| := by congr 1; ring + _ ≤ |u-a|+|a-s| := abs_add_le _ _ + _ < ε+ε := add_lt_add hu (by simpa only [abs_sub_comm] using hs) + _ = 2*ε := by ring + have hm : 2*ε/τ*r ≤ h/4 := by + have hmul := (le_div_iff₀ (show 0 < 8*r by positivity)).mp hεr + rw [div_mul_eq_mul_div,div_le_iff₀ hτ] + nlinarith + calc + |s+(u-s)/τ*t-a| = |(s-a)+(u-s)/τ*t| := by congr 1; ring + _ ≤ |s-a| + |(u-s)/τ*t| := abs_add_le _ _ + _ = |s-a| + |u-s|/τ*|t| := by rw [abs_mul,abs_div,abs_of_pos hτ] + _ ≤ |s-a| + 2*ε/τ*r := by + have H := mul_le_mul (div_le_div_of_nonneg_right hus.le hτ.le) ht.le + (abs_nonneg t) (show 0 ≤ 2*ε/τ by positivity) + linarith + _ < ε + 2*ε/τ*r := by linarith + _ ≤ h/4+h/4 := add_le_add hεh hm + _ < h := by linarith +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SmallEpsilon.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SmallEpsilon.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b73d0e16780c0cb49ba55e667f050e5bbe83c11 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SmallEpsilon.lean @@ -0,0 +1,35 @@ +import Mathlib + +namespace OAI + +section + +noncomputable section +open Set + +namespace WeakMTWTransport + +lemma exists_small_positive (S:Finset ℝ) (hS:∀a∈S,0 exact ⟨1,by norm_num,by simp⟩ + | @insert a S ha ih => + obtain ⟨e,he,heS⟩:=ih (fun b hb=>hS b (Finset.mem_insert_of_mem hb)) + refine ⟨min a e,lt_min (hS a (Finset.mem_insert_self _ _)) he,?_⟩ + intro b hb + rcases Finset.mem_insert.mp hb with rfl | hb + · exact min_le_left _ _ + · exact (min_le_right _ _).trans (heS b hb) + +lemma ratio_mul_le {a e X A B:ℝ} (ha:a ≤ e*X) (hA:0 ≤ A) (hX:0 ≤ X) + (he:e*A ≤ B) : a*A ≤ B*X := by + calc a*A ≤ (e*X)*A := mul_le_mul_of_nonneg_right ha hA + _ = (e*A)*X := by ring + _ ≤ B*X := mul_le_mul_of_nonneg_right he hX + +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SplitEndpointCost.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SplitEndpointCost.lean new file mode 100644 index 0000000000000000000000000000000000000000..e943e83195ba09734a1f243b61ded413fa5bdc48 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SplitEndpointCost.lean @@ -0,0 +1,116 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.SplitStationary +import OAI.Analysis.BiholderTransport.Coordinates.SplitPairing + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def splitEndpointCost (x : M) (s : ℝ) + (q : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + splitNormalAction x s q.2 (q.1,q.2) + +lemma splitEndpointCost_contDiffAt {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContDiffAt ℝ ∞ (splitEndpointCost x s) (0,p) := by + exact (splitNormalAction_contDiffAt hleft hright).comp + (f := fun q : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x => + (q.2,(q.1,q.2))) (0,p) + (contDiffAt_snd.prodMk (contDiffAt_fst.prodMk contDiffAt_snd)) + +lemma splitEndpointCost_axis {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : 0 < s) (hs1 : s < 1) + (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + splitEndpointCost x s (0,p)=‖p‖^2/2 := by + have hm := injectivityDomain_subset_minimizingVectors x hleft + have hn := injectivityDomain_subset_minimizingVectors _ hright + change dist x (riemannianExp x (s • p))=‖s • p‖ at hm + change dist (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 + (riemannianExp _ ((1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2)) = _ at hn + rw [shifted_exp_endpoint] at hn + simp only [norm_smul,Real.norm_eq_abs,abs_of_pos hs] at hm + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (sub_pos.mpr hs1),sprayFlow_speed] at hn + simp only [splitEndpointCost,splitNormalAction,riemannianExp_zero,cost] + rw [hm,riemannianExp_smul,hn] + field_simp + ring + +lemma splitEndpointCost_axis_near {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : 0 < s) (hs1 : s < 1) + (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + (fun v => splitEndpointCost x s (0,v)) =ᶠ[𝓝 p] (fun v => ‖v‖^2/2) := by + filter_upwards [split_regular_legs_near hleft hright] with v hv + exact splitEndpointCost_axis hs hs1 hv.1 hv.2 + +lemma splitEndpointCost_source_gradient {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : s ≠ 0) (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (a : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (splitEndpointCost x s) (0,p) (a,0) = -inner ℝ p a := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hC := (splitEndpointCost_contDiffAt hleft hright).differentiableAt (by simp) + have hB := (splitNormalAction_contDiffAt hleft hright).comp (0,p) + (contDiffAt_const.prodMk contDiffAt_id) + have hL : HasFDerivAt (fun b : V => (b,p)) + ((ContinuousLinearMap.id ℝ V).prod 0) 0 := + (hasFDerivAt_id (𝕜 := ℝ) (0:V)).prodMk (hasFDerivAt_const p (0:V)) + have hc := hC.hasFDerivAt.comp (f := fun b : V => (b,p)) 0 hL + have hb := (hB.differentiableAt (by simp)).hasFDerivAt.comp (f := fun b : V => (b,p)) 0 hL + have he := congrArg (fun A : V →L[ℝ] ℝ => A a) (hc.unique hb) + change fderiv ℝ (splitEndpointCost x s) (0,p) (a,0) = + fderiv ℝ (splitNormalAction x s p) (0,p) (a,0) at he + rw [he] + exact splitNormalAction_source_gradient hs hleft (hB.differentiableAt (by simp)) a + +lemma splitEndpointCost_mixed {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {s : ℝ} (hs : s ≠ 0) (hleft : s • p ∈ injectivityDomain x) + (hright : (1-s) • (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow s (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (a d : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ (fderiv ℝ (splitEndpointCost x s)) (0,p) (0,d) (a,0) = + -inner ℝ d a := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hC := (splitEndpointCost_contDiffAt hleft hright).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have hL : HasFDerivAt (fun v : V => ((0:V),v)) + ((0 : V →L[ℝ] V).prod (ContinuousLinearMap.id ℝ V)) p := + (hasFDerivAt_const (0:V) p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hd := (((hC.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := fun v : V => ((0:V),v)) p hL).clm_apply + (hasFDerivAt_const (a,(0:V)) p) + have heq : (fun v : V => fderiv ℝ (splitEndpointCost x s) (0,v) (a,0)) =ᶠ[𝓝 p] + (fun v => -inner ℝ v a) := by + filter_upwards [split_regular_legs_near hleft hright] with v hv + exact splitEndpointCost_source_gradient hs hv.1 hv.2 a + have hi : HasFDerivAt (fun v : V => -inner ℝ v a) (-(innerSL ℝ a)) p := by + convert! ((innerSL ℝ a).hasFDerivAt (x := p)).neg using 1 + funext v; exact congrArg Neg.neg (real_inner_comm a v) + have H := congrArg (fun A : V →L[ℝ] ℝ => A d) + ((hd.congr_of_eventuallyEq heq.symm).unique hi) + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.prod_apply, + ContinuousLinearMap.id_apply,zero_apply,map_zero,add_zero,zero_add,add_apply, + ContinuousLinearMap.comp_zero,Function.comp_apply, + ContinuousLinearMap.flip_apply,neg_apply,innerSL_apply_apply,real_inner_comm] using H + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/SplitSelection.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/SplitSelection.lean new file mode 100644 index 0000000000000000000000000000000000000000..175383f2de9d849b3f29ab153cc12295da54b47d --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/SplitSelection.lean @@ -0,0 +1,99 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.BranchCost2 +import OAI.Analysis.BiholderTransport.Regularity.Reversal +import OAI.Analysis.BiholderTransport.Coordinates.NormalEikonal + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SplitSelection +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma reverseRay_fraction_endpoint (z : TangentBundle 𝓘(ℝ,Model n) M) (t : ℝ) : + riemannianExp (reverseRay z).1 ((1-t) • (reverseRay z).2)= + riemannianExp z.1 (t • z.2) := by + rw [riemannianExp_smul,riemannianExp_smul] + change (sprayFlow (1-t) (tangentScale (-1) (sprayFlow 1 z))).1=(sprayFlow t z).1 + rw [sprayFlow_scale,←sprayFlow_add] + change (sprayFlow ((-1:ℝ)*(1-t)+1) z).1=(sprayFlow t z).1 + rw [show (-1:ℝ)*(1-t)+1=t by ring] + +lemma minimizing_reversed_split_action {y : M} {r : TangentSpace 𝓘(ℝ,Model n) y} + (hr : r∈minimizingVectors y) {t : ℝ} (ht : 0 riemannianExp R.1 ((1-t) • q u) + have hJ0 : J 0=riemannianExp x (t • p) := by + dsimp only [J] + rw [hq0] + exact reverseRay_fraction_endpoint z t + have hJ : ContMDiffAt 𝓘(ℝ,X) 𝓘(ℝ,Model n) ∞ J 0 := + (contMDiff_riemannianExp_fiber R.1 _).comp 0 (hq.const_smul (1-t)).contMDiffAt + let a : X → X := fun u => t⁻¹ • κ (J u) + have ha : ContDiffAt ℝ ∞ a 0 := by + apply ContDiffAt.const_smul + apply ContMDiffAt.contDiffAt + apply ContMDiffAt.comp 0 _ hJ + rwa [hJ0] + have ha0 : a 0=p := by + dsimp only [a] + rw [hJ0,hκ0,←mul_smul,inv_mul_cancel₀ ht.ne',one_smul] + have hright : ∀ᶠ u in 𝓝 0, riemannianExp x (t • a u)=J u := by + have H := hJ.continuousAt.eventually (by simpa only [hJ0] using hκright) + filter_upwards [H] with u hu + simpa only [a,←mul_smul,mul_inv_cancel₀ ht.ne',one_smul] using hu + have hqI : ∀ᶠ u in 𝓝 0, q u∈injectivityDomain R.1 := + hq.continuousAt.preimage_mem_nhds ((isOpen_injectivityDomain R.1).mem_nhds (hq0.symm ▸ hR)) + refine ⟨a,ha0,ha,?_⟩ + filter_upwards [hright,hqr,hqI] with u hu hv hw + have HE : R.1=riemannianExp x p := by + change (sprayFlow 1 z).1=riemannianExp x p + exact (riemannianExp_eq_sprayFlow x p).symm + dsimp only [splitNormalAction,normalCost] + rw [hu,←hv,←HE] + exact minimizing_reversed_split_action (injectivityDomain_subset_minimizingVectors R.1 hw) ht ht1 + +end SplitSelection +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/StationaryPullback.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/StationaryPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..5f66fe79e7364dc4606feea0e4208f2ab3546133 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/StationaryPullback.lean @@ -0,0 +1,163 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.SplitActionSchur + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +section +open Set Filter +open scoped Topology ContDiff + +variable {E F : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [NormedAddCommGroup F] [NormedSpace ℝ F] + +lemma second_fderiv_sub {f g : E → ℝ} {x : E} + (hf : ContDiffAt ℝ 2 f x) (hg : ContDiffAt ℝ 2 g x) (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => f a-g a)) x v w = + fderiv ℝ (fderiv ℝ f) x v w-fderiv ℝ (fderiv ℝ g) x v w := by + have he : fderiv ℝ (fun a => f a-g a) =ᶠ[𝓝 x] + (fun a => fderiv ℝ f a-fderiv ℝ g a) := by + filter_upwards [hf.eventually (by norm_num),hg.eventually (by norm_num)] with a ha hb + exact fderiv_fun_sub (ha.differentiableAt (by norm_num)) (hb.differentiableAt (by norm_num)) + rw [he.fderiv_eq] + rw [fderiv_fun_sub ((hf.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num)) + ((hg.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num))] + rfl + +lemma second_fderiv_const_mul {f : E → ℝ} {x : E} (c : ℝ) (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => c*f a)) x v w = c*fderiv ℝ (fderiv ℝ f) x v w := by + change fderiv ℝ (fderiv ℝ (c • f)) x v w = _ + rw [fderiv_const_smul_field c] + rw [fderiv_const_smul_field (f := fderiv ℝ f) c] + rfl + +lemma second_fderiv_comp_stationary {f : F → ℝ} {g : E → F} {x : E} + (hf : ContDiffAt ℝ 2 f (g x)) (hg : ContDiffAt ℝ 2 g x) + (hzero : fderiv ℝ f (g x)=0) (v w : E) : + fderiv ℝ (fderiv ℝ (fun a => f (g a))) x v w = + fderiv ℝ (fderiv ℝ f) (g x) (fderiv ℝ g x v) (fderiv ℝ g x w) := by + have hgd := (hg.differentiableAt (by norm_num)).hasFDerivAt + have hd1 := ((hf.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt.comp (f := g) x hgd + have hd2 := ((hg.fderiv_right (m := 1) (by norm_num)).differentiableAt + (by norm_num)).hasFDerivAt + have hd := hd1.clm_comp hd2 + have heq : (fun a => (fderiv ℝ f (g a)).comp (fderiv ℝ g a)) =ᶠ[𝓝 x] + fderiv ℝ (fun a => f (g a)) := by + filter_upwards [hgd.continuousAt.eventually (hf.eventually (by norm_num)), + hg.eventually (by norm_num)] with a hfa hga + exact ((hfa.differentiableAt (by norm_num)).hasFDerivAt.comp (f := g) a + (hga.differentiableAt (by norm_num)).hasFDerivAt).fderiv.symm + have H := congrArg (fun A : E →L[ℝ] E →L[ℝ] ℝ => A v w) + (hd.congr_of_eventuallyEq heq.symm).fderiv + simpa only [Function.comp_apply,hzero,ContinuousLinearMap.comp_apply,ContinuousLinearMap.compL_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.zero_comp,zero_apply, + zero_add,add_zero,add_apply] using H + +end + +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +def fixedJoinAction (x : M) (h T : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) + (z : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + cost (riemannianExp x z.1) (riemannianExp x (h • z.2))/h+ + cost (riemannianExp x (h • z.2)) (riemannianExp x (T • p))/(T-h) + +def fixedJoinMiddle (x : M) (h T : ℝ) (p : TangentSpace 𝓘(ℝ,Model n) x) : + TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] ℝ := + let I : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x := + (0 : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x).prod + (ContinuousLinearMap.id ℝ _) + ((fderiv ℝ (fderiv ℝ (fixedJoinAction x h T p)) (0,p)).comp I).flip.comp I |>.flip + +section +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +@[simp] lemma fixedJoinMiddle_apply (x : M) (h T : ℝ) + (p d k : TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinMiddle x h T p d k = + fderiv ℝ (fderiv ℝ (fixedJoinAction x h T p)) (0,p) (0,d) (0,k) := rfl + +lemma fixedJoinAction_rescale (x : M) {h T : ℝ} (hT : T≠0) + (p : TangentSpace 𝓘(ℝ,Model n) x) + (z : TangentSpace 𝓘(ℝ,Model n) x × TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinAction x h T p z = T⁻¹*splitNormalAction x (h/T) (T • p) (z.1,T • z.2) := by + simp only [fixedJoinAction,splitNormalAction,smul_smul,div_mul_cancel₀ _ hT] + have he : 1-h/T=(T-h)/T := by field_simp + rw [he] + simp only [div_div_eq_mul_div] + simp only [mul_add] + congr 1 <;> field_simp [hT] + +lemma fixedJoinMiddle_rescale {x : M} {h T : ℝ} (hT : T≠0) + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hB : ContDiffAt ℝ 2 (splitNormalAction x (h/T) (T • p)) (0,T • p)) + (d k : TangentSpace 𝓘(ℝ,Model n) x) : + fixedJoinMiddle x h T p d k = T* + fderiv ℝ (fderiv ℝ (splitNormalAction x (h/T) (T • p))) (0,T • p) (0,d) (0,k) := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let L : V×V →L[ℝ] V×V := (ContinuousLinearMap.fst ℝ V V).prod + (T • ContinuousLinearMap.snd ℝ V V) + have he : fixedJoinAction x h T p=(fun z => T⁻¹*splitNormalAction x (h/T) (T • p) (L z)) := + funext (fixedJoinAction_rescale x hT p) + rw [fixedJoinMiddle_apply,he,second_fderiv_const_mul] + have HL := second_fderiv_comp_affine (f := splitNormalAction x (h/T) (T • p)) L 0 (0,p) + (by simpa [L] using hB) (0,d) (0,k) + simp only [zero_add] at HL + rw [HL] + change T⁻¹*fderiv ℝ (fderiv ℝ (splitNormalAction x (h/T) (T • p))) (0,T • p) + (0,T • d) (0,T • k)=_ + have he1 (v : V) : ((0:V),T • v)=T • ((0:V),v) := by simp + simp only [he1,map_smul,smul_apply,smul_eq_mul] + field_simp [hT] + +end + +lemma fixedJoinAction_schur {x : M} {h T : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : T • p∈injectivityDomain x) (hh : 0 (T • p,z)) + (0,T • p) (contDiffAt_const.prodMk contDiffAt_id) + have hB := hBc.of_le (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + refine ⟨T⁻¹ • R,?_,?_⟩ + · intro d k + rw [smul_apply,map_smul,smul_apply, + fixedJoinMiddle_rescale hT.ne' hB,hR] + simp [smul_eq_mul,hT.ne'] + · intro d + have HA := hA d + rw [smul_smul,div_mul_cancel₀ _ hT.ne'] at HA + rw [HA,smul_apply,real_inner_smul_left] + field_simp + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/TemplateRightWeight.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/TemplateRightWeight.lean new file mode 100644 index 0000000000000000000000000000000000000000..01fca66fc5ae5ec20bcdb829e94fc42198d53747 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/TemplateRightWeight.lean @@ -0,0 +1,154 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.OutwardWeightCap + +namespace OAI + +section +section +noncomputable section +open Set +open scoped BigOperators + +namespace WeakMTWTransport + +lemma template_right_weight {ι : Type*} [Fintype ι] {m B s : ι → ℝ} + {eta center c : ℝ} (hm : ∀ i,0 ≤ m i) (hsum : ∑ i,m i=1) + (hB : ∀ i,0 ≤ B i) (hleft : ∀ i,s i < 1-eta → 1 ≤ B i) + (hcenter : center ≤ 1) (hparameter : c ≤ center-∑ i,m i*B i) : + c ≤ ∑ i∈Finset.univ.filter (fun i => 1-eta ≤ s i),m i := by + classical + let R := Finset.univ.filter (fun i => 1-eta ≤ s i) + let L := Finset.univ.filter (fun i => ¬1-eta ≤ s i) + have hpart : (∑ i∈R,m i)+(∑ i∈L,m i)=1 := by + rw [show (∑ i∈R,m i)+(∑ i∈L,m i)=∑ i,m i from + Finset.sum_filter_add_sum_filter_not Finset.univ (fun i => 1-eta ≤ s i) m,hsum] + have hbound : (∑ i∈L,m i) ≤ ∑ i,m i*B i := by + calc + _ ≤ ∑ i∈L,m i*B i := Finset.sum_le_sum (fun i hi => by + have HB := hleft i (lt_of_not_ge (Finset.mem_filter.mp hi).2) + simpa using mul_le_mul_of_nonneg_left HB (hm i)) + _ ≤ _ := Finset.sum_le_sum_of_subset_of_nonneg (Finset.subset_univ L) + (fun i _ _ => mul_nonneg (hm i) (hB i)) + change c ≤ ∑ i∈R,m i + linarith + +lemma outward_from_levels {ι : Type*} [Fintype ι] [DecidableEq ι] + {n : ℕ} (hn : Fintype.card ι ≤ n+1) {m d B si : ι → ℝ} + {q D c eta delta zeta s center : ℝ} + (hm : ∀ i,0 < m i) (hsum : ∑ i,m i=1) (hbar : ∑ i,m i*d i=0) + (hq : 0 < q) (hD : 0 < D) (hc : 0 < c) + (heta : eta ≤ 1/128) (hdelta : delta ≤ zeta) (hzeta : zeta ≤ 1/16) + (hs : s < 3/4) (hlow : ∀ i,-2*eta ≤ si i) + (hrange : ∀ i,|si i-s| ≤ 1+delta) + (hnorm : ∀ i,|2*q*d i+d i^2+2*D*(si i-s)| ≤ zeta*D) + (hB : ∀ i,0 ≤ B i) (hleft : ∀ i,si i < 1-eta → 1 ≤ B i) + (hcenter : center ≤ 1) (hparameter : c ≤ center-∑ i,m i*B i) : + ∃ i, 0 < d i ∧ c/(12*(n+1:ℝ)) ≤ m i ∧ + c*D/(8*(n+1:ℝ)*q) ≤ m i*d i ∧ d i ≤ 3*D/(2*q) ∧ + -2*eta ≤ si i ∧ si i < 1-eta ∧ B i ≤ 12*(n+1:ℝ)/c := by + classical + let R := Finset.univ.filter (fun i => 1-eta ≤ si i) + have hzm : zeta*D ≤ D/16 := by nlinarith [mul_le_mul_of_nonneg_right hzeta hD.le] + have hdm : delta*D ≤ D/16 := by nlinarith [mul_le_mul_of_nonneg_right (hdelta.trans hzeta) hD.le] + have hem : eta*D ≤ D/128 := by nlinarith [mul_le_mul_of_nonneg_right heta hD.le] + have hr : ∀ i∈R,2*q*d i+d i^2 ≤ -D/4 := by + intro i hi + have hright := (Finset.mem_filter.mp hi).2 + have H := (abs_le.mp (hnorm i)).2 + have HA := mul_le_mul_of_nonneg_left hright hD.le + have HB := mul_lt_mul_of_pos_left hs hD + nlinarith only [H,HA,HB,hzm,hem,hD] + have ho : ∀ i,0 < d i → 2*q*d i+d i^2 ≤ 3*D := by + intro i hd + have H := (abs_le.mp (hnorm i)).2 + have HA := mul_le_mul_of_nonneg_left (abs_le.mp (hrange i)).1 hD.le + nlinarith only [H,HA,hzm,hdm,hD] + have hcap : ∑ i,m i*B i ≤ 1 := by linarith + obtain ⟨i,hdi,hmi,hprod,hdub,hBi⟩ := outward_weight_and_cap hn hm hsum hbar hq hD hc R + (template_right_weight (fun i => (hm i).le) hsum hB hleft hcenter hparameter) hr ho hB hcap + have hir : si i < 1-eta := by + by_contra H + have HR := hr i (Finset.mem_filter.mpr ⟨Finset.mem_univ i,le_of_not_gt H⟩) + have HX := mul_pos hq hdi + nlinarith only [HR,HX,sq_nonneg (d i),hD] + push_cast at hmi hprod hBi + exact ⟨i,hdi,hmi,hprod,hdub,hlow i,hir,hBi⟩ + +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set +open scoped BigOperators + +namespace WeakMTWTransport + +lemma barycenter_opposite_extension {ι E : Type*} [Fintype ι] [DecidableEq ι] + [AddCommGroup E] [Module ℝ E] (pj : ι → E) (m : ι → ℝ) + (hm : ∀ i, 0 ≤ m i) (hsum : ∑ i,m i=1) (i : ι) + {theta : ℝ} (hl : -m i/2 ≤ theta) (hu : theta ≤ 1) : + (∑ j,m j • pj j)+theta • (pj i-(∑ j,m j • pj j)) ∈ convexHull ℝ (range pj) := by + classical + have hmi : m i ≤ 1 := (Finset.single_le_sum (fun j _ => hm j) (Finset.mem_univ i)).trans_eq hsum + let w : ι → ℝ := fun j => (1-theta)*m j + if j=i then theta else 0 + have hw : ∀ j, 0 ≤ w j := by + intro j + dsimp [w] + by_cases hji : j=i + · rw [ite_eq_left hji,hji] + by_cases ht : 0 ≤ theta + · exact add_nonneg (mul_nonneg (sub_nonneg.mpr hu) (hm i)) ht + · have H := mul_le_mul_of_nonneg_right hl (sub_nonneg.mpr hmi) + nlinarith [sq_nonneg (m i),hm i] + · rw [ite_eq_right hji,add_zero] + exact mul_nonneg (sub_nonneg.mpr hu) (hm j) + have hw1 : ∑ j,w j=1 := by + dsimp [w] + rw [Finset.sum_add_distrib,←Finset.mul_sum,hsum] + simp + have he : (∑ j,w j • pj j)=(∑ j,m j • pj j)+theta • (pj i-(∑ j,m j • pj j)) := by + dsimp [w] + simp_rw [add_smul,mul_smul] + rw [Finset.sum_add_distrib,←Finset.smul_sum] + have H : (∑ j,(if j=i then theta else 0) • pj j)=theta • pj i := by + simp_rw [ite_smul,zero_smul] + simp + rw [H] + module + rw [←he] + exact (convex_convexHull ℝ (range pj)).sum_mem (fun j _ => hw j) hw1 + (fun j _ => subset_convexHull ℝ _ (mem_range_self j)) + +lemma outward_radial_ratio {q D d a theta : ℝ} + (hq : 0 < q) (ha : 0 < a) (hd : 0 < d) + (hqa : a*D ≤ q^2) (hdub : d ≤ 3*D/(2*q)) + (ht : -a/3 ≤ theta) : + q/2 ≤ q+theta*d ∧ d^2/((q+theta*d)*d) ≤ 3/a := by + have hdq : d*(2*q) ≤ 3*D := (le_div_iff₀ (by positivity : 0 < 2*q)).mp hdub + have hadq : a*d ≤ 3*q/2 := by + have H := mul_le_mul_of_nonneg_left hdq ha.le + nlinarith only [H,hqa,hq] + have hlow : q/2 ≤ q+theta*d := by + have H := mul_le_mul_of_nonneg_right ht hd.le + nlinarith only [H,hadq] + refine ⟨hlow,?_⟩ + have hqp : 0 < q+theta*d := (half_pos hq).trans_le hlow + apply (div_le_div_iff₀ (mul_pos hqp hd) ha).mpr + have H := mul_le_mul_of_nonneg_right hadq hd.le + have H' := mul_le_mul_of_nonneg_right hlow hd.le + nlinarith only [H,H'] + +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/TrialBlowup.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/TrialBlowup.lean new file mode 100644 index 0000000000000000000000000000000000000000..31db5eac683178d7d58c41a3779f83b2c7414c00 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/TrialBlowup.lean @@ -0,0 +1,191 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.SplitTrial +import OAI.Analysis.BiholderTransport.LinearAlgebra.SchurRatioTendstoBot + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Filter Set +open scoped Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma split_regular_legs_eventually {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ∀ᶠ w in 𝓝 p, t • w ∈ injectivityDomain x ∧ + (1-t) • (sprayFlow t (⟨x,w⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,w⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1 := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have hL : ∀ᶠ w in 𝓝 p, t • w ∈ injectivityDomain x := + (show ContinuousAt (fun w : V => t • w) p from by fun_prop).preimage_mem_nhds + ((isOpen_injectivityDomain x).mem_nhds hleft) + let Z : V → TangentBundle 𝓘(ℝ,Model n) M := + fun w => tangentScale (1-t) (sprayFlow t ⟨x,w⟩) + have hZ : ContMDiff 𝓘(ℝ,V) (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) ∞ Z := + contMDiff_tangentScale.comp (contMDiff_const.prodMk (contMDiff_spray_fiber x t)) + have hR : ∀ᶠ w in 𝓝 p, Z w ∈ {z : TangentBundle 𝓘(ℝ,Model n) M | z.2 ∈ injectivityDomain z.1} := + hZ.continuous.continuousAt.preimage_mem_nhds (isOpen_total_injectivityDomain.mem_nhds hright) + exact hL.and hR + +lemma conjugate_radial_hessian_tendsto_atBot {x : M} {p xi k : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p ∈ minimizingVectors x) + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) + (hpair : inner ℝ k xi≠0) : + Tendsto (fun r : ℝ => hessianValue x (r • p) xi) (𝓝[<] 1) atBot := by + obtain ⟨t,ht,ht1,hleft,hright⟩ := exists_minimizing_two_regular_legs hp + have hline : Tendsto (fun r : ℝ => r • p) (𝓝[<] 1) (𝓝 p) := by + simpa only [one_smul] using + (show ContinuousAt (fun r : ℝ => r • p) 1 from by fun_prop).tendsto.mono_left nhdsWithin_le_nhds + have ha := ((splitTrialValue_contDiffAt hleft hright xi 0).continuousAt.tendsto).comp hline + have hQ := ((splitTrialValue_contDiffAt hleft hright 0 k).continuousAt.tendsto).comp hline + rw [splitTrialValue_conjugate_null ht ht1 hleft hright hk] at hQ + have hnear : ∀ᶠ r : ℝ in 𝓝[<] 1, + 0 h.1)) + (hnear.mono (fun _ h => h.2)) +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/TrueCenterGain.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/TrueCenterGain.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a857f7a5c9b2ded68b6650cd462f361d278d1e7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/TrueCenterGain.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.UniformJacobian +import OAI.Analysis.BiholderTransport.CostGeometry.UniformReverseGain + +namespace OAI + + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma regular_divided_hessian_decrease {y:M} {p d:TangentSpace 𝓘(ℝ,Model n) y} + (hp:p∈injectivityDomain y) {s:ℝ} (hs:00,∀ᶠ l:ℝ in 𝓝 1,l<1 → ∀x:M,∀q:TangentSpace 𝓘(ℝ,Model n) x, + ∀p:TangentSpace 𝓘(ℝ,Model n) (riemannianExp x q), + p∈injectivityDomain (riemannianExp x q) → q∈injectivityDomain x → + riemannianExp (riemannianExp x q) (l • p)=x → + ∀R:TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) (riemannianExp x q), + DifferentiableAt ℝ R q → R q=0 → + (∀ᶠ z in 𝓝 q,riemannianExp (riemannianExp x q) (R z)=riemannianExp x z) → + ∀d,c*(1-l)*‖d‖^2 ≤ + normalHessian (riemannianExp x q) (l • p) (fderiv ℝ R q d) (fderiv ℝ R q d)- + l*normalHessian (riemannianExp x q) p (fderiv ℝ R q d) (fderiv ℝ R q d) := by + obtain ⟨c,hc,H⟩:=exists_uniform_reverse_divided_gain (n:=n) (M:=M) + have hpair:Tendsto (fun l:ℝ=>(l,(1+l)/2)) (𝓝 1) (𝓝 (1,1)):=by + have hh:ContinuousAt (fun l:ℝ=>(l,(1+l)/2)) (1:ℝ):= + continuousAt_id.prodMk ((continuousAt_const.add continuousAt_id).div_const 2) + simpa using hh.tendsto + refine ⟨c/4,by positivity,?_⟩ + filter_upwards [hpair.eventually H,eventually_gt_nhds (by norm_num : (1/2:ℝ)<1)] with l hl hhalf + intro hl1 x q p hp hq hpx R hR hR0 hRe d + have hl0:0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance trueLimitFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +local instance trueLimitDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance trueLimitDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance trueLimitBilinearGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance trueLimitBilinearSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance + +lemma exists_true_center_limit : ∃δ>0,∃U:Set ℝ,IsOpen U ∧ 1∈U ∧ + ∀(u:M → ℝ) (a c:M) (φ:ℕ → ℝ → ℝ) (lj:ℕ → ℝ), + ∀J:(j:ℕ) → TrueCenterJet (n:=n) u a c (φ j) (lj j), + ∀(l κ χ:ℝ) (q r:Model n) (H:Model n →L[ℝ] Model n →L[ℝ] ℝ), + l∈U → 0(J j).b) atTop (𝓝 (extChartAt 𝓘(ℝ,Model n) a a)) → + Tendsto (fun j=>(J j).q) atTop (𝓝 q) → + Tendsto (fun j=>(J j).fullRay) atTop (𝓝 (⟨c,r⟩:TangentBundle 𝓘(ℝ,Model n) M)) → + Tendsto (fun j=>(J j).curvature) atTop (𝓝 κ) → + Tendsto (fun j=>(J j).matrix) atTop (𝓝 H) → + (∀ᶠ j in atTop,χ≤expJacobian (J j).y (J j).p* + (normalHessianOperator (J j).y (J j).p+(J j).A).det) → + ∃V:Model n →L[ℝ] Model n →L[ℝ] ℝ, + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0 + (∀d e,V d e=V e d) ∧ (∀d,d≠0 → 0if h:∃V,P j V then Classical.choose h else 0 + have hV:∀ᶠ j in atTop,P j (V j):=hVe.mono (fun j hj=>by + simpa only [V,dite_eq_left hj] using Classical.choose_spec hj) + let G:=fun j=>frameMetric a (J j).b + let G₀:=frameMetric a (extChartAt 𝓘(ℝ,Model n) a a) + have hb0:=mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a + have hG:Tendsto G atTop (𝓝 G₀):=(frameMetric_continuousAt hb0).tendsto.comp hb + have hf:=tendsto_clm_apply hG hqq + have hshort:Tendsto (fun j=>(J j).shortRay) atTop + (𝓝 (⟨a,q⟩:TangentBundle 𝓘(ℝ,Model n) M)):=chartRay_tendsto hb hqq + have hs:=continuous_expJacobian.continuousAt.tendsto.comp hshort + have ha:=continuous_expJacobian.continuousAt.tendsto.comp hfull + have hfr: Tendsto (fun j=>(chartFiberInverse a (J j).b).toLinearMap.normDet) atTop + (𝓝 (chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet):= + (frameNormDet_continuousAt hb0).tendsto.comp hb + let k:=fun j=>(chartFiberInverse a (J j).b).toLinearMap.normDet^2*(lj j)^n* + (expJacobian (J j).shortRay.1 (J j).shortRay.2)^2*χ + have hk:Tendsto k atTop (𝓝 ((chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n* + (expJacobian a q)^2*χ)):=(((hfr.pow 2).mul (hlj.pow n)).mul (hs.pow 2)).mul_const χ + have hk0:0<(chartFiberInverse a (extChartAt 𝓘(ℝ,Model n) a a)).toLinearMap.normDet^2*l^n* + (expJacobian a q)^2*χ:=by + have Hf:=frameNormDet_pos hb0 + have He:=expJacobian_pos_of_injectivityDomain hq + positivity + have HVe:∀ᶠ j in atTop,(∀d e,V j d e=V j e d) ∧ + (∀d,0≤V j d d) ∧ + (∀d,V j d d+(δ*(1-lj j))*G j d d+ + ((J j).curvature/(lj j)^2)*(G j (J j).q d)^2≤(J j).matrix d d) ∧ + 0≤expJacobian (J j).fullRay.1 (J j).fullRay.2 ∧ + k j≤expJacobian (J j).fullRay.1 (J j).fullRay.2*(bilinearOperator (V j)).det:=by + filter_upwards [hV,hpos,hvol] with j hj hljj hvolj + refine ⟨hj.1,?_,hj.2.2.2,expJacobian_nonneg _ _,?_⟩ + · intro d + by_cases hd:d=0 + · simp [hd] + · exact (hj.2.1 d hd).le + · rw [hj.2.2.1] + have hfactor:0≤(chartFiberInverse a (J j).b).toLinearMap.normDet^2*(lj j)^n* + (expJacobian (J j).shortRay.1 (J j).shortRay.2)^2:=by + exact mul_nonneg (mul_nonneg (sq_nonneg _) (pow_nonneg hljj.1.le _)) (sq_nonneg _) + have HH:=mul_le_mul_of_nonneg_left hvolj hfactor + dsimp only [k,TrueCenterJet.fullRay] + convert HH using 1; first | rfl | ring + have hbc:Tendsto (fun j=>δ*(1-lj j)) atTop (𝓝 (δ*(1-l))):= + tendsto_const_nhds.mul (tendsto_const_nhds.sub hlj) + have hcc:Tendsto (fun j=>(J j).curvature/(lj j)^2) atTop (𝓝 (κ/l^2)):= + hκ.div (hlj.pow 2) (pow_ne_zero _ hl.ne') + obtain ⟨V₀,σ,hσ,HV,hVs,hVp,hgain,ha0,hdet⟩:= + exists_bilinear_gain_limit hH hG hf ha hk hbc hcc hk0 HVe + exact ⟨V₀,hVs,hVp,hgain,ha0,hdet⟩ +end TrueCenterLimit +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformFiniteGrowth.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformFiniteGrowth.lean new file mode 100644 index 0000000000000000000000000000000000000000..10b6502aa2d0f69b79b847ef5a5a049027b4ff3b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformFiniteGrowth.lean @@ -0,0 +1,114 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.FiniteNonnegativeWeight + +namespace OAI + +noncomputable section +open Set Filter +open scoped Topology + +namespace WeakMTWTransport +variable {P E : Type*} [TopologicalSpace P] [CompactSpace P] + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + {ι : Type*} [Fintype ι] [Nonempty ι] + +lemma uniform_finite_transverse_quadratic_growth + (w : P → ι → ℝ) (L : P → ι → E →L[ℝ] ℝ) + (B : P → ι → E →L[ℝ] E →L[ℝ] ℝ) + (hw : ∀ a i, 0 ≤ w a i) (hsum : ∀ a, ∑ i, w a i = 1) + (hmean : ∀ a v, ∑ i, w a i * L a i v = 0) + (hwc : ∀ i, Continuous (fun a => w a i)) + (hLc : ∀ i, Continuous (fun a => L a i)) + (hBc : ∀ i, Continuous (fun a => B a i)) + (hpos : ∀ a v, ‖v‖ = 1 → (∀ i, L a i v ≤ 0) → + 0 < ∑ i, w a i * B a i v v) : + ∃ b > 0, ∀ᶠ h : E in 𝓝 0, ∀ a : P, ∃ i, + b * ‖h‖ ^ 2 ≤ L a i h + B a i h h := by + let Q : P × E → ℝ := fun z => ∑ i, w z.1 i * B z.1 i z.2 z.2 + have hQ : Continuous Q := by + apply continuous_finsetSum + intro i _ + exact ((hwc i).comp continuous_fst).mul + (((hBc i).comp continuous_fst).clm_apply continuous_snd |>.clm_apply continuous_snd) + have hL : ∀ i, Continuous (fun z : P × E => L z.1 i z.2) := + fun i => ((hLc i).comp continuous_fst).clm_apply continuous_snd + let C : Set (P × E) := univ ×ˢ Metric.sphere (0:E) 1 + have hC : IsCompact C := isCompact_univ.prod (isCompact_sphere (0:E) 1) + let K : Set (P × E) := C ∩ {z | ∀ i, L z.1 i z.2 ≤ 0} + have hK : IsCompact K := by + apply hC.inter_right + simpa only [Set.ofPred_forall] using + isClosed_iInter (fun i => isClosed_le (hL i) continuous_const) + obtain ⟨b,hb,hbK⟩ : ∃ b > 0, ∀ z ∈ K, b < Q z := by + by_cases hne : K.Nonempty + · obtain ⟨z,hz,hmin⟩ := hK.exists_isMinOn hne hQ.continuousOn + have hp : 0 < Q z := hpos z.1 z.2 + (by simpa only [Metric.mem_sphere,dist_zero_right] using hz.1.2) hz.2 + exact ⟨Q z / 2,half_pos hp,fun y hy => (half_lt_self hp).trans_le (hmin hy)⟩ + · exact ⟨1,zero_lt_one,fun z hz => (hne ⟨z,hz⟩).elim⟩ + have hloc : ∀ z ∈ C, ∀ᶠ q : ℝ × (P × E) in 𝓝 (0,z), + 0 ≤ q.1 → ∃ i, q.1 * b ≤ L q.2.1 i q.2.2 + q.1 * B q.2.1 i q.2.2 q.2.2 := by + intro z hz + by_cases hlin : ∃ i, 0 < L z.1 i z.2 + · obtain ⟨i,hi⟩ := hlin + have hc : Continuous (fun q : ℝ × (P × E) => + L q.2.1 i q.2.2 + q.1 * (B q.2.1 i q.2.2 q.2.2 - b)) := by + exact ((hL i).comp continuous_snd).add + (continuous_fst.mul (((((hBc i).comp (continuous_fst.comp continuous_snd)).clm_apply + (continuous_snd.comp continuous_snd)).clm_apply + (continuous_snd.comp continuous_snd)).sub continuous_const)) + have he : ∀ᶠ q : ℝ × (P × E) in 𝓝 (0,z), + 0 < L q.2.1 i q.2.2 + q.1 * (B q.2.1 i q.2.2 q.2.2 - b) := + hc.continuousAt.eventually (Ioi_mem_nhds (by simpa using hi)) + filter_upwards [he] with q hq _ + exact ⟨i,by nlinarith⟩ + · have hzK : z ∈ K := ⟨hz,fun i => le_of_not_gt (fun h => hlin ⟨i,h⟩)⟩ + have he : ∀ᶠ q : ℝ × (P × E) in 𝓝 (0,z), b < Q q.2 := + (hQ.comp continuous_snd).continuousAt.eventually (Ioi_mem_nhds (hbK z hzK)) + filter_upwards [he] with q hq hr + apply finite_nonnegative_weight_exists_ge (w q.2.1) + (fun i => L q.2.1 i q.2.2 + q.1 * B q.2.1 i q.2.2 q.2.2) + (hw q.2.1) (hsum q.2.1) + have heq : (∑ i, w q.2.1 i * + (L q.2.1 i q.2.2 + q.1 * B q.2.1 i q.2.2 q.2.2)) = q.1 * Q q.2 := by + simp only [mul_add,Finset.sum_add_distrib,hmean,zero_add,Q] + rw [Finset.mul_sum] + congr 1 + ext i + ring + rw [heq] + exact mul_le_mul_of_nonneg_left hq.le hr + have he : ∀ᶠ r : ℝ in 𝓝 0, ∀ z ∈ C, 0 ≤ r → ∃ i, + r * b ≤ L z.1 i z.2 + r * B z.1 i z.2 z.2 := + hC.eventually_forall_of_forall_eventually hloc + have hnorm : Tendsto (fun h : E => ‖h‖) (𝓝 0) (𝓝 (0:ℝ)) := by + simpa only [norm_zero] using continuous_norm.tendsto (0:E) + refine ⟨b,hb,?_⟩ + filter_upwards [hnorm.eventually he] with h hh + intro a + by_cases hz : h = 0 + · obtain ⟨i⟩ := ‹Nonempty ι› + exact ⟨i,by simp [hz]⟩ + · let v := ‖h‖⁻¹ • h + have hn : 0 < ‖h‖ := norm_pos_iff.mpr hz + have hv : v ∈ Metric.sphere (0:E) 1 := by + simp only [Metric.mem_sphere,dist_zero_right,v,norm_smul,Real.norm_eq_abs,abs_inv,abs_norm] + exact inv_mul_cancel₀ hn.ne' + obtain ⟨i,hi⟩ := hh (a,v) ⟨mem_univ _,hv⟩ hn.le + have hv' : ‖h‖ • v = h := by simp [v,smul_smul,hn.ne'] + have hil := mul_le_mul_of_nonneg_left hi hn.le + refine ⟨i,?_⟩ + have hL' : L a i h = ‖h‖ * L a i v := by + calc _ = L a i (‖h‖ • v) := congrArg (L a i) hv'.symm + _ = _ := by simp only [map_smul,smul_eq_mul] + have hB' : B a i h h = ‖h‖ * (‖h‖ * B a i v v) := by + calc _ = B a i (‖h‖ • v) (‖h‖ • v) := by rw [hv'] + _ = _ := by simp only [map_smul,_root_.smul_apply,smul_eq_mul] + rw [hL',hB'] + nlinarith + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformIntervalCrossing.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformIntervalCrossing.lean new file mode 100644 index 0000000000000000000000000000000000000000..99b8b9c3ec3c7b8c692e359bf5659e5be4c7b9e4 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformIntervalCrossing.lean @@ -0,0 +1,150 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MovingCrossing +import OAI.Analysis.BiholderTransport.Geodesics.MinimizingChartParameters +import OAI.Analysis.BiholderTransport.Volume.UniformExpJacobian + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma fixedJoinMiddle_interval_crossing_near_base {h : ℝ} (hh : 0 < h) (hh1 : h < 1) + (Hsplit : ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, p∈minimizingVectors x → + h • p∈injectivityDomain x ∧ + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) (a : M) : + ∃ c > 0, ∃ C > 0, ∃ K∈𝓝 a, ∀ᶠ z in 𝓝 ((1:ℝ),(1:ℝ)), h < z.1 → z.2 < 1 → z.1 ≤ z.2 → + ∀ x∈K, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, p∈minimizingVectors x → + ∀ k : TangentSpace 𝓘(ℝ,Model n) x, + c*(z.2-z.1)*‖k‖^2 ≤ fixedJoinMiddle x h z.1 p k k-fixedJoinMiddle x h z.2 p k k ∧ + fixedJoinMiddle x h z.1 p k k-fixedJoinMiddle x h z.2 p k k ≤ C*(z.2-z.1)*‖k‖^2 := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hBpos,hB⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + obtain ⟨D,hDpos,hD⟩ := eventually_norm_symmL_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + obtain ⟨K,hKn,hKs,hKc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) (inter_mem hB hD)) + let χ := extChartAt 𝓘(ℝ,Model n) a + let e := trivializationAt (Model n) (TangentSpace 𝓘(ℝ,Model n)) a + let P := minimizingChartParameters (n := n) a K + have HP : ∀ q∈P, q.1∈χ.target ∧ + h • e.symmL ℝ (χ.symm q.1) q.2∈injectivityDomain (χ.symm q.1) ∧ + (1-h) • (sprayFlow h (⟨χ.symm q.1,e.symmL ℝ (χ.symm q.1) q.2⟩ : + TangentBundle 𝓘(ℝ,Model n) M)).2∈injectivityDomain + (sprayFlow h (⟨χ.symm q.1,e.symmL ℝ (χ.symm q.1) q.2⟩ : + TangentBundle 𝓘(ℝ,Model n) M)).1 := by + intro q hq + have H := mem_minimizingChartParameters (fun x hx => (hKs hx).1) hq + exact ⟨H.1,Hsplit _ _ H.2.2⟩ + obtain ⟨c,hc,C,hC,ε,hε,HC⟩ := compact_bilinear_interval_crossing + (isCompact_minimizingChartParameters hKc (fun x hx => (hKs hx).1)) + (H := movingFixedJoinMiddle a h) + (fun q hq => movingFixedJoinMiddle_contDiffAt + (movingFixedJoinAction_contDiffAt (HP q hq).1 hh1.ne' (HP q hq).2.1 (HP q hq).2.2)) + (fun q hq v hv => movingFixedJoinMiddle_strict_crossing (HP q hq).1 hh hh1 + (HP q hq).2.1 (HP q hq).2.2 v hv) + refine ⟨c/D^2,div_pos hc (sq_pos_of_pos hDpos),C*B^2, + mul_pos hC (sq_pos_of_pos hBpos),K,hKn,?_⟩ + have Hz₁ : ∀ᶠ z : ℝ×ℝ in 𝓝 (1,1), z.1∈Metric.ball 1 ε := + continuousAt_fst.eventually (Metric.ball_mem_nhds 1 hε) + have Hz₂ : ∀ᶠ z : ℝ×ℝ in 𝓝 (1,1), z.2∈Metric.ball 1 ε := + continuousAt_snd.eventually (Metric.ball_mem_nhds 1 hε) + filter_upwards [Hz₁,Hz₂] with z hz₁ hz₂ + intro hhT hT1 hzle x hx p hp k + let A := e.continuousLinearMapAt ℝ x + have hxp : (χ x,A p)∈P := + trivialization_mem_minimizingChartParameters (fun x hx => (hKs hx).1) hx hp + have HE := HC z.1 z.2 hz₁ hz₂ hzle (χ x,A p) hxp (A k) + have HS := Hsplit x p hp + have HB1 := (fixedJoinAction_shortened_contDiffAt hh1 (hhT.trans_le hzle) hT1 HS.1 HS.2).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + have HBT := (fixedJoinAction_shortened_contDiffAt hh1 hhT (hzle.trans_lt hT1) HS.1 HS.2).of_le + (m := 2) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2) + rw [movingFixedJoinMiddle_trivialization (hKs hx).1 h z.1 p k k HBT, + movingFixedJoinMiddle_trivialization (hKs hx).1 h z.2 p k k HB1] at HE + have hbase : x∈e.baseSet := by + simpa only [e,TangentBundle.trivializationAt_baseSet,extChartAt_source] using (hKs hx).1 + have hA : ‖A k‖ ≤ B*‖k‖ := + (A.le_opNorm k).trans (mul_le_mul_of_nonneg_right (hKs hx).2.1.le (norm_nonneg _)) + have hL : ‖k‖ ≤ D*‖A k‖ := by + calc + ‖k‖ = ‖e.symmL ℝ x (A k)‖ := by rw [Trivialization.symmL_continuousLinearMapAt e hbase] + _ ≤ ‖e.symmL ℝ x‖*‖A k‖ := (e.symmL ℝ x).le_opNorm _ + _ ≤ D*‖A k‖ := mul_le_mul_of_nonneg_right (hKs hx).2.2.le (norm_nonneg _) + have hL2 : ‖k‖^2 ≤ D^2*‖A k‖^2 := by nlinarith only [hL,sq_nonneg (‖k‖-D*‖A k‖),norm_nonneg k,mul_nonneg hDpos.le (norm_nonneg (A k))] + have hA2 : ‖A k‖^2 ≤ B^2*‖k‖^2 := by nlinarith only [hA,sq_nonneg (‖A k‖-B*‖k‖),norm_nonneg (A k),mul_nonneg hBpos.le (norm_nonneg k)] + constructor + · calc + (c/D^2)*(z.2-z.1)*‖k‖^2 ≤ (c/D^2)*(z.2-z.1)*(D^2*‖A k‖^2) := by gcongr + _ = c*(z.2-z.1)*‖A k‖^2 := by field_simp + _ ≤ _ := HE.1 + · calc + _ ≤ C*(z.2-z.1)*‖A k‖^2 := HE.2 + _ ≤ C*(z.2-z.1)*(B^2*‖k‖^2) := by gcongr + _ = (C*B^2)*(z.2-z.1)*‖k‖^2 := by ring + +lemma fixedJoinMiddle_uniform_interval_crossing {h : ℝ} (hh : 0 < h) (hh1 : h < 1) + (Hsplit : ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, p∈minimizingVectors x → + h • p∈injectivityDomain x ∧ + (1-h) • (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2∈ + injectivityDomain (sprayFlow h (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ∃ c > 0, ∃ C > 0, ∀ᶠ z in 𝓝 ((1:ℝ),(1:ℝ)), h < z.1 → z.2 < 1 → z.1 ≤ z.2 → + ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, p∈minimizingVectors x → + ∀ k : TangentSpace 𝓘(ℝ,Model n) x, + c*(z.2-z.1)*‖k‖^2 ≤ fixedJoinMiddle x h z.1 p k k-fixedJoinMiddle x h z.2 p k k ∧ + fixedJoinMiddle x h z.1 p k k-fixedJoinMiddle x h z.2 p k k ≤ C*(z.2-z.1)*‖k‖^2 := by + classical + choose c hc C hC K hKn hK using fixedJoinMiddle_interval_crossing_near_base hh hh1 Hsplit + obtain ⟨s,hs⟩ := finite_cover_nhds hKn + have hlow : ∃ b > 0, ∀ a∈s, b ≤ c a := by + clear hs + induction s using Finset.induction_on with + | empty => exact ⟨1,zero_lt_one,by simp⟩ + | @insert a s ha ih => + obtain ⟨b,hb,Hb⟩ := ih + refine ⟨min b (c a),lt_min hb (hc a),?_⟩ + intro z hz + rcases Finset.mem_insert.mp hz with rfl|hz + · exact min_le_right _ _ + · exact (min_le_left _ _).trans (Hb z hz) + have hupp : ∃ b > 0, ∀ a∈s, C a ≤ b := by + clear hs hlow + induction s using Finset.induction_on with + | empty => exact ⟨1,zero_lt_one,by simp⟩ + | @insert a s ha ih => + obtain ⟨b,hb,Hb⟩ := ih + refine ⟨max b (C a),hb.trans_le (le_max_left _ _),?_⟩ + intro z hz + rcases Finset.mem_insert.mp hz with rfl|hz + · exact le_max_right _ _ + · exact (Hb z hz).trans (le_max_left _ _) + obtain ⟨b,hb,Hb⟩ := hlow + obtain ⟨B,hB,HB⟩ := hupp + refine ⟨b,hb,B,hB,?_⟩ + have HT := (eventually_all_finset s).mpr (fun a _ => hK a) + filter_upwards [HT] with z hT + intro hhT hT1 hzle x p hp k + have hx : x∈ ⋃ a∈s,K a := by rw [hs]; trivial + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp hx + have H := hT a ha hhT hT1 hzle x hxa p hp k + refine ⟨le_trans ?_ H.1,le_trans H.2 ?_⟩ + · gcongr; exact Hb a ha + · gcongr; exact HB a ha + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMiddle.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMiddle.lean new file mode 100644 index 0000000000000000000000000000000000000000..c014becbc9e3742bd147d665000e59dac8453641 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMiddle.lean @@ -0,0 +1,113 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.CompactQuadratic +import OAI.Analysis.BiholderTransport.CostGeometry.CrossingUniform + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section UniformMiddle +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma uniform_suffix_crossing_bounds : + ∃ c C : ℝ, 0 tangentScale q.1 (sprayFlow (1/4) q.2) + have hF : Continuous F := contMDiff_tangentScale.continuous.comp + (continuous_fst.prodMk (contMDiff_sprayFlow.continuous.comp + (continuous_const.prodMk continuous_snd))) + have hK : IsCompact (F '' (Icc (1/4:ℝ) (3/4) ×ˢ G)) := + (isCompact_Icc.prod (isCompact_total_minimizingVectors (n := n) (M := M))).image hF + have hI : ∀ z∈F '' (Icc (1/4:ℝ) (3/4) ×ˢ G), z.2∈injectivityDomain z.1 := by + rintro _ ⟨⟨s,z⟩,hsz,rfl⟩ + have H := proper_suffix_in_injectivityDomain hsz.2 (show (0:ℝ)<1/4 by norm_num) + (show (1/4:ℝ) radialCrossingValue x (r • p) v/r^2 + let f : ℝ → ℝ := fun r => normalHessian x (r • p) v v/r + have hI (r) (hr : r∈Icc (1/4:ℝ) (3/4)) : r • p∈injectivityDomain x := by + have HH := proper_suffix_in_injectivityDomain hz (show (0:ℝ)<1/4 by norm_num) + (show (1/4:ℝ) (hder r hr).continuousAt.continuousWithinAt + have hdf : DifferentiableOn ℝ f (interior (Icc (1/4:ℝ) (3/4))) := + fun r hr => (hder r (interior_subset hr)).differentiableAt.differentiableWithinAt + have hs : 1-δ-1/4∈Icc (1/4:ℝ) (3/4) := ⟨by linarith,by linarith⟩ + have ht : (3/4:ℝ)∈Icc (1/4:ℝ) (3/4) := ⟨by norm_num,le_rfl⟩ + have hst : 1-δ-1/4≤(3/4:ℝ) := by linarith + have hlo := (convex_Icc (1/4:ℝ) (3/4)).image_sub_le_mul_sub_of_deriv_le hf hdf + (C := -(c*‖v‖^2)) (fun r hr => by + rw [(hder r (interior_subset hr)).deriv] + exact neg_le_neg (H z hz r (interior_subset hr) v).1) + (1-δ-1/4) hs (3/4) ht hst + have hhi := (convex_Icc (1/4:ℝ) (3/4)).mul_sub_le_image_sub_of_le_deriv hf hdf + (C := -(C*‖v‖^2)) (fun r hr => by + rw [(hder r (interior_subset hr)).deriv] + exact neg_le_neg (H z hz r (interior_subset hr) v).2) + (1-δ-1/4) hs (3/4) ht hst + rw [middleHessian_apply,middleHessian_apply] + change _≤_ + f (1-δ-1/4)-(_+f (1-1/4)) ∧ + _+f (1-δ-1/4)-(_+f (1-1/4))≤_ + norm_num only [show (1:ℝ)-1/4=3/4 by norm_num] + constructor <;> nlinarith + +end UniformMiddle +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMixedBound.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMixedBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..589a2e89621b8882ea746a4d41be55195f04184e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformMixedBound.lean @@ -0,0 +1,147 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.MixedTrivializationBound +import OAI.Analysis.BiholderTransport.Geodesics.NormalEndpointLog +import OAI.Analysis.BiholderTransport.Calculus.MixedContinuity + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma movingNormalEndpointJoinAction_chart_contDiffAt {a c x : M} {h : ℝ} + {p : TangentSpace 𝓘(ℝ,Model n) x} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hy : riemannianExp x p∈(extChartAt 𝓘(ℝ,Model n) c).source) + (hh : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma movingEndpointFamily_contDiffAt {a c : M} {h : ℝ} + {q : Model n×(Model n×Model n)} + (H : ContDiffAt ℝ ∞ (Function.uncurry (movingNormalEndpointJoinAction a c)) + ((h,(q.1,q.2.1)),(0,q.2.2))) : + ContDiffAt ℝ ∞ (Function.uncurry (movingEndpointFamily a c)) ((h,q),(0,q.2.2)) := by + exact H.comp ((h,q),(0,q.2.2)) + ((contDiffAt_fst.fst.prodMk + (contDiffAt_fst.snd.fst.prodMk contDiffAt_fst.snd.snd.fst)).prodMk contDiffAt_snd) + +lemma compact_movingEndpointFamily_bound {a c : M} {h : ℝ} {K L : Set M} + (hK : IsCompact K) (hL : IsCompact L) + (hKs : K⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hLs : L⊆(extChartAt 𝓘(ℝ,Model n) c).source) + (hh : 00, ∀ᶠ s in 𝓝 h, ∀ q∈minimizingEndpointChartParameters (n := n) a c K L, + ContDiffAt ℝ 2 (movingEndpointFamily a c (s,q)) (0,q.2.2) ∧ + ‖fderiv ℝ (fderiv ℝ (movingEndpointFamily a c (s,q))) (0,q.2.2)‖≤B := by + apply compact_parameter_second_jet_on_graph + (isCompact_minimizingEndpointChartParameters hK hL hKs hLs) + (v := fun q : Model n×(Model n×Model n) => (0,q.2.2)) + (continuous_const.prodMk continuous_snd.snd) + intro q hq + obtain ⟨z,hz,rfl⟩ := hq + have hx := hKs hz.2.1 + have hy := hLs hz.2.2 + apply movingEndpointFamily_contDiffAt + simp only [tangent_chart_trivialization hx] + exact movingNormalEndpointJoinAction_chart_contDiffAt hx hy hh hh1 + (Hsplit z.1 z.2 hz.1).1 (Hsplit z.1 z.2 hz.1).2 + +lemma normalEndpointMixedOperator_bound_near_pair {h : ℝ} (hh : 00, ∃ U∈𝓝 (a,c), ∀ᶠ s in 𝓝 h, + ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + (x,riemannianExp x p)∈U → p∈minimizingVectors x → + ‖normalEndpointMixedOperator x (riemannianExp x p) s p‖≤C := by + have : IsContinuousRiemannianBundle (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨B,hBpos,hB⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) a + obtain ⟨D,hDpos,hD⟩ := eventually_norm_trivializationAt_lt (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x) c + obtain ⟨K,hKn,hKs,hKc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) a) hB) + obtain ⟨L,hLn,hLs,hLc⟩ := local_compact_nhds + (inter_mem (extChartAt_source_mem_nhds (I := 𝓘(ℝ,Model n)) c) hD) + obtain ⟨E,hE,HE⟩ := compact_movingEndpointFamily_bound hKc hLc + (fun x hx => (hKs hx).1) (fun y hy => (hLs hy).1) hh hh1 Hsplit + refine ⟨E*D*B,mul_pos (mul_pos hE hDpos) hBpos,K×ˢL,prod_mem_nhds hKn hLn,?_⟩ + filter_upwards [HE] with s hs + intro x p hxy hp + have H := hs _ (trivialization_mem_minimizingEndpointChartParameters hxy.1 + (hKs hxy.1).1 hp hxy.2) + exact (normalEndpointMixedOperator_norm_trivialization_le + (hKs hxy.1).1 (hLs hxy.2).1 hBpos.le hDpos.le + (hKs hxy.1).2.le (hLs hxy.2).2.le p H.1).trans (by + change ‖fderiv ℝ (fderiv ℝ (movingEndpointFamily a c (s,_))) _‖*D*B≤E*D*B + gcongr + exact H.2) + +lemma normalEndpointMixedOperator_uniform_bound {h : ℝ} (hh : 00, ∀ᶠ s in 𝓝 h, ∀ x : M, ∀ p : TangentSpace 𝓘(ℝ,Model n) x, + p∈minimizingVectors x → ‖normalEndpointMixedOperator x (riemannianExp x p) s p‖≤C := by + classical + have H := fun z : M×M => normalEndpointMixedOperator_bound_near_pair hh hh1 Hsplit z.1 z.2 + choose C hC U hU HU using H + obtain ⟨S,hS⟩ := finite_cover_nhds hU + let B := 1+∑ z∈S, |C z| + have hB : 0 HU a) + filter_upwards [HT] with t ht + intro x p hp + have hx : (x,riemannianExp x p)∈ ⋃ a∈S,U a := by rw [hS]; trivial + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp hx + apply (ht a ha x p hxa hp).trans + calc + C a≤|C a| := le_abs_self _ + _≤∑ z∈S, |C z| := Finset.single_le_sum (fun z _ => abs_nonneg (C z)) ha + _≤B := le_add_of_nonneg_left zero_le_one + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformShortMinima.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformShortMinima.lean new file mode 100644 index 0000000000000000000000000000000000000000..dbefec9e9b50f2ca7a9ee55e20054e56562b32ab --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformShortMinima.lean @@ -0,0 +1,62 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.LocalMountains +import OAI.Analysis.BiholderTransport.LinearAlgebra.DiagonalCostConvexity +import OAI.Analysis.BiholderTransport.Coordinates.ShortLocalMinimum + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff NNReal + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +variable {P : Type*} [NormedAddCommGroup P] [NormedSpace ℝ P] + +omit [Nonempty M] in +lemma exists_parametric_short_action_local_minima {a : M} {ψ : P×Model n → ℝ} + {p : P} {x : Model n} + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).target) (hψ : ContDiffAt ℝ ∞ ψ (p,x)) : + ∃ r>0, ∃ V∈𝓝 ((p,(0:ℝ)),x), ∀ q∈V, ∀ y∈Metric.closedBall x r, + fderiv ℝ (fun w => q.1.2*ψ (q.1.1,w)+ + chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) w) y=0 → + ∀ w∈Metric.closedBall x r, q.1.2*ψ (q.1.1,y)+ + chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) y≤ + q.1.2*ψ (q.1.1,w)+chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) w := by + let F : ((P×ℝ)×Model n) → Model n → ℝ := fun q y => + q.1.2*ψ (q.1.1,y)+chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm q.2) y + have hF : ContDiffAt ℝ ∞ (Function.uncurry F) (((p,(0:ℝ)),x),x) := + (contDiffAt_fst.fst.snd.mul (hψ.comp (f := fun q : ((P×ℝ)×Model n)×Model n => (q.1.1.1,q.2)) _ + (contDiffAt_fst.fst.fst.prodMk contDiffAt_snd))).add + ((chartCost_pair_contDiffAt_diagonal (a := a) (x := x) hx).comp (((p,(0:ℝ)),x),x) + (contDiffAt_fst.snd.prodMk contDiffAt_snd)) + have hswap : ContinuousAt (fun q : Model n×((P×ℝ)×Model n) => q.swap) (x,((p,(0:ℝ)),x)) := + continuousAt_snd.prodMk continuousAt_fst + have hH : ContinuousAt (fun q : Model n×((P×ℝ)×Model n) => + fderiv ℝ (fderiv ℝ (F q.2)) q.1) (x,((p,(0:ℝ)),x)) := by + have H := (ContDiffAt.partial_snd_fderiv_two (f := F) hF).continuousAt.comp + (x := (x,((p,(0:ℝ)),x))) hswap + exact H + have hD : ∀ᶠ q : Model n×((P×ℝ)×Model n) in 𝓝 (x,((p,(0:ℝ)),x)), + ContDiffAt ℝ 2 (F q.2) q.1 := by + have H := hswap.eventually ((hF.of_le (ENat.natCast_le_of_coe_top_le_withTop le_rfl 2)).eventually (by simp)) + filter_upwards [H] with q hq + exact hq.comp q.1 (contDiffAt_const.prodMk contDiffAt_id) + obtain ⟨m,hm,hpos⟩ := chartCost_diagonal_coercive hx + have heq : F ((p,0),x)=chartCost a ((extChartAt 𝓘(ℝ,Model n) a).symm x) := by + ext y; simp only [F,zero_mul,zero_add] + have hposF : ∀ d, m*‖d‖^2≤fderiv ℝ (fderiv ℝ (F ((p,0),x))) x d d := by + rw [heq] + exact hpos + exact exists_local_mountains hm hH hD hposF + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UniformTestDet.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformTestDet.lean new file mode 100644 index 0000000000000000000000000000000000000000..5c1141c3bb360970d3fbb834a472bb894ce4e843 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UniformTestDet.lean @@ -0,0 +1,200 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.SmoothTestPDE +import OAI.Analysis.BiholderTransport.Regularity.CenteredQuadratic +import OAI.Analysis.BiholderTransport.Contact.ContactJetCalculus + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle +open scoped Topology ContDiff BoundedContinuousFunction NNReal + +namespace WeakMTWTransport +section UniformTestDet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance uTDualGroup : NormedAddCommGroup (Model n →L[ℝ] ℝ) := inferInstance +local instance uTDualSpace : NormedSpace ℝ (Model n →L[ℝ] ℝ) := inferInstance +local instance uTBilinGroup : NormedAddCommGroup (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance uTBilinSpace : NormedSpace ℝ (Model n →L[ℝ] Model n →L[ℝ] ℝ) := inferInstance +local instance uTPairGroup : NormedAddCommGroup (Model n × (Model n →L[ℝ] ℝ)) := inferInstance +local instance uTPairSpace : NormedSpace ℝ (Model n × (Model n →L[ℝ] ℝ)) := inferInstance +local instance uTMapGroup : NormedAddCommGroup (Model n →L[ℝ] Model n × (Model n →L[ℝ] ℝ)) := inferInstance +local instance uTMapSpace : NormedSpace ℝ (Model n →L[ℝ] Model n × (Model n →L[ℝ] ℝ)) := inferInstance + +lemma WeakMTW.strict_test_det_bound_on_charts + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 0 < lam) (hcap : 0 ≤ cap) {a b : M} {U V : Set M} + (hU : IsOpen U) (hUa : U⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hV : IsOpen V) (hVb : V⊆(extChartAt 𝓘(ℝ,Model n) b).source) + {C D : ℝ≥0} (hD : LipschitzOnWith D (extChartAt 𝓘(ℝ,Model n) a).symm + ((extChartAt 𝓘(ℝ,Model n) a) '' U)) + (hC : LipschitzOnWith C (extChartAt 𝓘(ℝ,Model n) b) V) + {z : Model n} (hz : z∈(extChartAt 𝓘(ℝ,Model n) a) '' U) + {x0 : M} {uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)} + (huv : uv∈densityDualClass (metricVolume n) lam cap x0) + {φ : Model n → ℝ} (hφ : ContDiffAt ℝ 2 φ z) + (hYz : coordinateBackward a (-1,z,fderiv ℝ φ z)∈V) + (hpφ : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (hval : uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)=φ z) + (hgap : ∃ ε>0,∀ᶠ w in 𝓝 z,ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-φ w) + (hpos : ∃ m>0,∀ d : Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d) : + |(fderiv ℝ (chartTestContact a b φ) z).det|≤(cap/lam)*((C:ℝ)*(D:ℝ))^n := by + let χ := extChartAt 𝓘(ℝ,Model n) a + let ψ := extChartAt 𝓘(ℝ,Model n) b + have hchart : χ '' U⊆χ.target := by + rintro w ⟨x,hx,rfl⟩ + exact χ.map_source (hUa hx) + have hzT : z∈χ.target := hchart hz + have hUo : IsOpen (χ '' U) := by + have he : χ '' U = χ.target ∩ χ.symm ⁻¹' U := by + ext w + constructor + · rintro ⟨x,hx,rfl⟩ + exact ⟨χ.map_source (hUa hx),by simpa only [mem_preimage,χ.left_inv (hUa hx)] using hx⟩ + · rintro ⟨hw,hwU⟩ + exact ⟨χ.symm w,hwU,χ.right_inv hw⟩ + rw [he] + exact (continuousOn_extChartAt_symm a).isOpen_inter_preimage + (isOpen_extChartAt_target a) hU + obtain ⟨ε,hε,hgap⟩ := hgap + obtain ⟨m,hm,hpos⟩ := hpos + obtain ⟨r₂,hr₂,_,hmount⟩ := exists_test_mountains hzT hφ hpφ hm hpos + let Y := fun w : Model n => coordinateBackward a (-1,w,fderiv ℝ φ w) + have hY : ContinuousAt Y z := + (coordinateBackward_contMDiffAt (q := (-1,z,fderiv ℝ φ z)) hzT).continuousAt.comp + (x := z) (f := fun w : Model n => ((-1:ℝ),w,fderiv ℝ φ w)) + (continuousAt_const.prodMk (continuousAt_id.prodMk + (hφ.fderiv_right (m := 1) (by norm_num)).continuousAt)) + have hYn : ∀ᶠ w : Model n in 𝓝 z,Y w∈V := hY.preimage_mem_nhds (hV.mem_nhds hYz) + have hnear : ∀ᶠ w : Model n in 𝓝 z, + ε*dist w z^2≤uv.1 (χ.symm w)-φ w ∧ + w∈χ '' U ∧ w∈Metric.ball z r₂ ∧ ContinuousAt φ w ∧ Y w∈V := by + filter_upwards [hgap,hUo.mem_nhds hz,Metric.ball_mem_nhds z hr₂, + hφ.eventually (by norm_num),hYn] with w hw h₁ h₂ hφw hYw + exact ⟨hw,h₁,h₂,hφw.continuousAt,hYw⟩ + obtain ⟨r,hr,hrsub⟩ := Metric.nhds_basis_closedBall.mem_iff.mp hnear + obtain ⟨rho0,rho1,hrho0,hrho1,hmin⟩ := huv.2 + apply hmtw.lower_test_chart_det_bound hlam hcap hrho0 hrho1 + (densityDualClass_isDual huv) hmin hr hε + (fun w hw => hchart (hrsub hw).2.1) + (hD.mono (fun w hw => (hrsub hw).2.1)) hC + (fun w hw => (hrsub hw).2.2.2.1.continuousWithinAt) + hval (fun w hw => (hrsub hw).1) (S := chartTestContact a b φ) ?_ ?_ + ((chartTestContact_contDiffAt hzT hφ (hVb hYz)).hasStrictFDerivAt (by norm_num)) + · intro w hw + have hy : Y w∈ψ.source := hVb (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + refine ⟨ψ.map_source hy,?_⟩ + change ψ.symm (ψ (Y w))∈V + rw [ψ.left_inv hy] + exact (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + · intro w hw q hq + have hy : Y w∈ψ.source := hVb (hrsub (Metric.ball_subset_closedBall hw)).2.2.2.2 + change φ w+cost (χ.symm w) (ψ.symm (ψ (Y w)))≤φ q+cost (χ.symm q) (ψ.symm (ψ (Y w))) + rw [ψ.left_inv hy] + exact hmount w (Metric.ball_subset_closedBall (hrsub (Metric.ball_subset_closedBall hw)).2.2.1) + q (Metric.ball_subset_closedBall (hrsub hq).2.2.1) + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma chartTestContact_fderiv_formula {a b:M} {z:Model n} {φ:Model n → ℝ} + (hz:z∈(extChartAt 𝓘(ℝ,Model n) a).target) (hφ:ContDiffAt ℝ 2 φ z) + (hb:coordinateBackward a (-1,z,fderiv ℝ φ z)∈(extChartAt 𝓘(ℝ,Model n) b).source) : + fderiv ℝ (chartTestContact a b φ) z= + (fderiv ℝ (coordinateContact a b) (z,fderiv ℝ φ z)).comp + ((ContinuousLinearMap.id ℝ (Model n)).prod (fderiv ℝ (fderiv ℝ φ) z)) := by + have hC : ContDiffAt ℝ ∞ (coordinateContact (n:=n) a b) (z,fderiv ℝ φ z) := + coordinateContact_contDiffAt (n:=n) (M:=M) (a:=a) (b:=b) + (q:=(z,fderiv ℝ φ z)) hz hb + exact fderiv_contact_c2 hC hφ + +lemma WeakMTW.test_det_bound_on_charts + (hmtw : WeakMTW (n := n) (M := M)) {lam cap : ℝ} + (hlam : 0 < lam) (hcap : 0 ≤ cap) {a b : M} {U V : Set M} + (hU : IsOpen U) (hUa : U⊆(extChartAt 𝓘(ℝ,Model n) a).source) + (hV : IsOpen V) (hVb : V⊆(extChartAt 𝓘(ℝ,Model n) b).source) + {C D : ℝ≥0} (hD : LipschitzOnWith D (extChartAt 𝓘(ℝ,Model n) a).symm + ((extChartAt 𝓘(ℝ,Model n) a) '' U)) + (hC : LipschitzOnWith C (extChartAt 𝓘(ℝ,Model n) b) V) + {z : Model n} (hz : z∈(extChartAt 𝓘(ℝ,Model n) a) '' U) + {x0 : M} {uv : (M →ᵇ ℝ)×(M →ᵇ ℝ)} + (huv : uv∈densityDualClass (metricVolume n) lam cap x0) + {φ : Model n → ℝ} (hφ : ContDiffAt ℝ 2 φ z) + (hYz : coordinateBackward a (-1,z,fderiv ℝ φ z)∈V) + (hpφ : chartGradientVector a z (fderiv ℝ φ z)∈injectivityDomain + ((extChartAt 𝓘(ℝ,Model n) a).symm z)) + (hval : uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm z)=φ z) + (hlo : ∀ᶠ w in 𝓝 z,φ w≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)) + (hpos : ∃ m>0,∀ d : Model n,m*‖d‖^2≤fderiv ℝ (fderiv ℝ φ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ φ z)))) z d d) : + |(fderiv ℝ (chartTestContact a b φ) z).det|≤(cap/lam)*((C:ℝ)*(D:ℝ))^n := by + obtain ⟨m,hm,hpos⟩:=hpos + have hzT:z∈(extChartAt 𝓘(ℝ,Model n) a).target:=by + obtain ⟨w,hw,rfl⟩:=hz + exact (extChartAt 𝓘(ℝ,Model n) a).map_source (hUa hw) + let q:Model n → ℝ:=fun w=>‖w-z‖^2/2 + let H:=fderiv ℝ (fderiv ℝ φ) z + let Q:=fderiv ℝ (fderiv ℝ q) z + let J:=fderiv ℝ (coordinateContact a b) (z,fderiv ℝ φ z) + let F:ℝ → ℝ:=fun δ=>|(J.comp ((ContinuousLinearMap.id ℝ (Model n)).prod (H-δ • Q))).det| + have hF:Continuous F:=continuous_contact_jet_det J H Q + have hF0:F 0=|(fderiv ℝ (chartTestContact a b φ) z).det|:=by + rw [chartTestContact_fderiv_formula hzT hφ (hVb hYz)] + simp only [F,zero_smul,sub_zero,H,J] + have Hbound:∀ δ:ℝ, 0<δ → δ < m → F δ≤(cap/lam)*((C:ℝ)*(D:ℝ))^n:=by + intro δ hδ hδm + let ψ:Model n → ℝ:=fun w=>φ w-δ*q w + have hq:ContDiffAt ℝ 2 q z:=(centered_half_norm_sq_c2 z).contDiffAt + have hψ:ContDiffAt ℝ 2 ψ z:=hφ.sub (contDiffAt_const.mul hq) + have hψL:fderiv ℝ ψ z=fderiv ℝ φ z:=by + rw [show ψ=(fun w=>φ w-δ*q w) from rfl, + fderiv_fun_sub (hφ.differentiableAt (by norm_num)) + ((hq.differentiableAt (by norm_num)).const_mul _)] + change fderiv ℝ φ z-fderiv ℝ (δ • q) z=_ + rw [fderiv_const_smul_field,Pi.smul_apply,centered_half_norm_sq_fderiv,smul_zero,sub_zero] + have hψH:fderiv ℝ (fderiv ℝ ψ) z=H-δ • Q:=by + ext d e + rw [show ψ=(fun w=>φ w-δ*q w) from rfl, + second_fderiv_sub hφ (contDiffAt_const.mul hq),second_fderiv_const_mul] + rfl + have hψpos:∃ k>0,∀ d:Model n,k*‖d‖^2≤fderiv ℝ (fderiv ℝ ψ) z d d+ + fderiv ℝ (fderiv ℝ (chartCost a (coordinateBackward a (-1,z,fderiv ℝ ψ z)))) z d d:=by + refine ⟨m-δ,sub_pos.mpr hδm,fun d=>?_⟩ + rw [hψL,hψH] + change (m-δ)*‖d‖^2≤H d d-δ*(Q d d)+_ + change (m-δ)*‖d‖^2≤H d d-δ*(fderiv ℝ (fderiv ℝ (fun w:Model n=>‖w-z‖^2/2)) z d d)+_ + rw [centered_half_norm_sq_second] + linarith only [hpos d] + have hgap:∃ ε>0,∀ᶠ w in 𝓝 z,ε*dist w z^2≤uv.1 ((extChartAt 𝓘(ℝ,Model n) a).symm w)-ψ w:=by + refine ⟨δ/2,by positivity,?_⟩ + filter_upwards [hlo] with w hw + dsimp only [ψ,q] + rw [dist_eq_norm] + linarith only [hw] + have HB:=hmtw.strict_test_det_bound_on_charts hlam hcap hU hUa hV hVb hD hC hz huv hψ + (hψL.symm ▸ hYz) (hψL.symm ▸ hpφ) (by simpa only [ψ,q,sub_self,norm_zero,zero_pow (by norm_num : 2≠0),zero_div,mul_zero,sub_zero] using hval) + hgap hψpos + rw [chartTestContact_fderiv_formula hzT hψ (by rw [hψL]; exact hVb hYz),hψL,hψH] at HB + exact HB + rw [←hF0] + apply le_of_tendsto (hF.continuousAt.tendsto.mono_left (show 𝓝[>] (0:ℝ) ≤ 𝓝 (0:ℝ) from nhdsWithin_le_nhds)) + filter_upwards [self_mem_nhdsWithin, + mem_nhdsWithin_of_mem_nhds (gt_mem_nhds hm)] with δ hδ hδm + exact Hbound δ hδ hδm + +end UniformTestDet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Regularity/UnitTime.lean b/lean/OAI/Analysis/BiholderTransport/Regularity/UnitTime.lean new file mode 100644 index 0000000000000000000000000000000000000000..57e16c6ed3a12a2f732f6d2d9c4778f59e3ae164 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Regularity/UnitTime.lean @@ -0,0 +1,110 @@ +import Mathlib + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +abbrev UnitTime := Icc (0:ℝ) 1 +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +local instance : Fact ((0:ℝ) ≤ 1) := ⟨zero_le_one⟩ + +def extendUnitPath (u : C(UnitTime,E)) : C(ℝ,E) := + u.comp (ContinuousMap.projIccCM (a := (0:ℝ)) (b := 1)) + +omit [NormedSpace ℝ E] in +@[simp] lemma extendUnitPath_coe (u : C(UnitTime,E)) (t : UnitTime) : + extendUnitPath u t = u t := by + change u (projIcc 0 1 (by positivity) t) = u t + rw [projIcc_of_mem _ t.property] + +omit [NormedSpace ℝ E] in +@[simp] lemma extendUnitPath_add (u v : C(UnitTime,E)) : + extendUnitPath (u+v) = extendUnitPath u + extendUnitPath v := rfl + +@[simp] lemma extendUnitPath_smul (c : ℝ) (u : C(UnitTime,E)) : + extendUnitPath (c • u) = c • extendUnitPath u := rfl + +def unitPathPrimitive (u : C(UnitTime,E)) : C(UnitTime,E) := + ⟨fun t => ∫ s in (0:ℝ)..t.val, extendUnitPath u s, + (intervalIntegral.continuous_primitive + (fun a b => (extendUnitPath u).continuous.intervalIntegrable a b) 0).comp + continuous_subtype_val⟩ + +lemma unitPathPrimitive_bound (u : C(UnitTime,E)) : ‖unitPathPrimitive u‖ ≤ ‖u‖ := by + apply (ContinuousMap.norm_le _ (norm_nonneg u)).mpr + intro t + change ‖∫ s in (0:ℝ)..t.val, extendUnitPath u s‖ ≤ ‖u‖ + have h := intervalIntegral.norm_integral_le_of_norm_le_const + (a := (0:ℝ)) (b := t.val) (f := extendUnitPath u) + (C := ‖u‖) (fun s _ => u.norm_coe_le_norm (projIcc 0 1 (by positivity) s)) + apply h.trans + rw [sub_zero,abs_of_nonneg t.property.1] + exact mul_le_of_le_one_right (norm_nonneg u) t.property.2 + +def unitPathIntegral : C(UnitTime,E) →L[ℝ] C(UnitTime,E) := by + let L : C(UnitTime,E) →ₗ[ℝ] C(UnitTime,E) := + { toFun := unitPathPrimitive + map_add' := by + intro u v; ext t + change (∫ s in (0:ℝ)..t.val, extendUnitPath (u+v) s) = + (∫ s in (0:ℝ)..t.val, extendUnitPath u s) + + (∫ s in (0:ℝ)..t.val, extendUnitPath v s) + rw [extendUnitPath_add] + exact intervalIntegral.integral_add + ((extendUnitPath u).continuous.intervalIntegrable _ _) + ((extendUnitPath v).continuous.intervalIntegrable _ _) + map_smul' := by + intro c u; ext t + change (∫ s in (0:ℝ)..t.val, extendUnitPath (c • u) s) = + c • (∫ s in (0:ℝ)..t.val, extendUnitPath u s) + rw [extendUnitPath_smul] + exact intervalIntegral.integral_smul c (extendUnitPath u) } + exact L.mkContinuous 1 (by + intro u + change ‖unitPathPrimitive (u : C(UnitTime,E))‖ ≤ 1 * ‖u‖ + simpa only [one_mul] using unitPathPrimitive_bound u) + +@[simp] lemma unitPathIntegral_apply (u : C(UnitTime,E)) (t : UnitTime) : + unitPathIntegral u t = ∫ s in (0:ℝ)..t.val, extendUnitPath u s := rfl + +lemma hasDerivAt_unitPathPrimitive [CompleteSpace E] (u : C(UnitTime,E)) (t : ℝ) : + HasDerivAt (fun s => ∫ r in (0:ℝ)..s, extendUnitPath u r) (extendUnitPath u t) t := + intervalIntegral.integral_hasDerivAt_right + ((extendUnitPath u).continuous.intervalIntegrable 0 t) + (extendUnitPath u).continuous.stronglyMeasurable.stronglyMeasurableAtFilter + (extendUnitPath u).continuous.continuousAt + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/AESelection.lean b/lean/OAI/Analysis/BiholderTransport/Volume/AESelection.lean new file mode 100644 index 0000000000000000000000000000000000000000..eb7d0603ceb04a818d007b64945ddcae3590558c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/AESelection.lean @@ -0,0 +1,41 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.AEContacts +import OAI.Analysis.BiholderTransport.Volume.AemeasurableAeContinuous +import OAI.Analysis.BiholderTransport.Contact.ContactSelection + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport +section AESelection +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma contactSelection_aemeasurable {v : M → ℝ} (hv : Continuous v) : + AEMeasurable (contactSelection hv) (metricVolume (M := M) n) := by + apply aemeasurable_of_ae_continuousAt + filter_upwards [cTransform_ae_unique_contact (n := n) hv] with x hx + apply contact_selection_continuousAt (continuous_cTransform hv) hv (contactSelection_mem hv) + intro y hy + exact hx.unique hy (contactSelection_mem hv x) + +end AESelection +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/AemeasurableAeContinuous.lean b/lean/OAI/Analysis/BiholderTransport/Volume/AemeasurableAeContinuous.lean new file mode 100644 index 0000000000000000000000000000000000000000..a6ae5cf0114b9751981d17eb68c9a29435074566 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/AemeasurableAeContinuous.lean @@ -0,0 +1,29 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold MeasureTheory Bundle Metric +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport + +lemma aemeasurable_of_ae_continuousAt {X Y : Type*} [TopologicalSpace X] + [MeasurableSpace X] [OpensMeasurableSpace X] [TopologicalSpace Y] + [MeasurableSpace Y] [BorelSpace Y] {μ : Measure X} {f : X → Y} + (h : ∀ᵐ x ∂μ, ContinuousAt f x) : AEMeasurable f μ := by + let s := {x | ContinuousAt f x} + have hs : NullMeasurableSet s μ := .of_compl (.of_null (ae_iff.mp h)) + have hc : ContinuousOn f s := fun x hx => hx.continuousWithinAt + have H := hc.aemeasurable₀ hs + rw [Measure.restrict_eq_self_of_ae_mem (s := s) h] at H + exact H + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/ChartJacobianBounds.lean b/lean/OAI/Analysis/BiholderTransport/Volume/ChartJacobianBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..c4b49a8bc067caf49c20abac14ee59ba33e3c53e --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/ChartJacobianBounds.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.IntrinsicJacobian + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ChartJacobianBounds +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteChartJacobianBounds (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +attribute [local instance] normedAddCommGroupTangentSpaceVectorSpace normedSpaceTangentSpaceVectorSpace +local instance inverseChartNormedAddCommGroup (y : Model n) (x : M) : NormedAddCommGroup + (TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) := + ContinuousLinearMap.toNormedAddCommGroup +local instance inverseChartNormedSpace (y : Model n) (x : M) : NormedSpace ℝ + (TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) := + ContinuousLinearMap.toNormedSpace + +def inverseChartJacobian (a : M) (z : Model n) : ℝ := + let F : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) ((extChartAt 𝓘(ℝ,Model n) a).symm z) := + mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) (extChartAt 𝓘(ℝ,Model n) a).symm z + F.toLinearMap.normDet + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartJacobian_inverse_product (a : M) {z : Model n} + (hz : z∈(extChartAt 𝓘(ℝ,Model n) a).target) : + chartJacobian (n := n) a ((extChartAt 𝓘(ℝ,Model n) a).symm z)* + inverseChartJacobian (n := n) a z=1 := by + let d := extChartAt 𝓘(ℝ,Model n) a + let F : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (d.symm z) := + mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d.symm z + let G : TangentSpace 𝓘(ℝ,Model n) (d.symm z) →L[ℝ] Model n := + mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) d (d.symm z) + have h := mfderiv_extChartAt_comp_mfderivWithin_extChartAt_symm hz + simp only [ModelWithCorners.range_eq_univ,mfderivWithin_univ] at h + change G.comp F=ContinuousLinearMap.id ℝ (Model n) at h + have hn := congrArg (fun L : Model n →L[ℝ] Model n => L.toLinearMap.normDet) h + change (G.toLinearMap ∘ₗ F.toLinearMap).normDet=(LinearMap.id : Model n →ₗ[ℝ] Model n).normDet at hn + rw [LinearMap.normDet_comp_of_finrank_eq F.toLinearMap G.toLinearMap rfl,LinearMap.normDet_id] at hn + exact hn + +omit [CompactSpace M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartJacobian_pos {a x : M} (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) : + 0 TangentSpace 𝓘(ℝ,Model n) x) := + continuousRiemannianBundle_of_smooth (IB := 𝓘(ℝ,Model n)) + obtain ⟨C,hC,hCd⟩ := eventually_norm_mfderiv_extChartAt_lt 𝓘(ℝ,Model n) a + obtain ⟨D,hD,hDi⟩ := eventually_norm_mfderivWithin_symm_extChartAt_comp_lt 𝓘(ℝ,Model n) a + let N := Module.finrank ℝ (Model n) + let U : ℝ := N.factorial * C ^ N + let Q : ℝ := N.factorial * D ^ N + have hU : 0 (h hA).elim⟩ + have ha : 0 < |A.det| := abs_pos.mpr hA + let m : ℝ≥0 := ⟨|A.det|/2,by positivity⟩ + have hm : (m:ℝ≥0∞)] (0 : ℝ≥0), 0<δ := self_mem_nhdsWithin + obtain ⟨δ,hδ,H⟩ := (hpos.and (mul_le_addHaar_image_of_lt_det μ A hm)).exists + refine ⟨δ,hδ,fun _ a g hg hz => ?_⟩ + have hh : (m:ℝ≥0∞)*μ a=0 := le_antisymm ((H a g hg).trans_eq hz) bot_le + have hmpos : (0:ℝ≥0∞) < m := by + exact_mod_cast (show (0:ℝ)<(m:ℝ) by change 0 < |A.det| / 2; exact half_pos ha) + exact (mul_eq_zero.mp hh).resolve_left (ne_of_gt hmpos) + choose δ hδ Hδ using hchoice + obtain ⟨t,A,_,hcover,happrox,hA⟩ := + exists_closed_cover_approximatesLinearOn_of_hasFDerivWithinAt f s df hd δ + (fun A => (hδ A).ne') + rcases s.eq_empty_or_nonempty with rfl|hs + · exact measure_empty + have ht : ∀ k, μ (s∩t k)=0 := by + intro k + obtain ⟨y,hy,hAy⟩ := hA hs k + apply Hδ (A k) (hAy ▸ hdet y hy) (s∩t k) f (happrox k) + exact measure_mono_null (Set.image_mono inter_subset_left) hnull + apply measure_mono_null (t := ⋃ k, s∩t k) + · intro x hx + obtain ⟨k,hk⟩ := mem_iUnion.mp (hcover hx) + exact mem_iUnion.mpr ⟨k,hx,hk⟩ + · exact measure_iUnion_null ht + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/DensityBounds.lean b/lean/OAI/Analysis/BiholderTransport/Volume/DensityBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..eeda5e35b6d33571c029b1cbde632c8657635b4f --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/DensityBounds.lean @@ -0,0 +1,49 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section +section +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder +open scoped BoundedContinuousFunction + +section DensityBounds +variable {M : Type*} [MetricSpace M] [MeasurableSpace M] [BorelSpace M] [CompactSpace M] +omit [MetricSpace M] [BorelSpace M] [CompactSpace M] in + +lemma densityMeasure_bounds {vol : Measure M} {lam cap : ℝ} {rho : M → ℝ} + (hrho : AdmissibleDensity vol lam cap rho) : + ENNReal.ofReal lam • vol ≤ densityMeasure vol rho ∧ + densityMeasure vol rho ≤ ENNReal.ofReal cap • vol := by + constructor + · rw [← withDensity_const] + apply withDensity_mono + filter_upwards [hrho.2.2.2] with x hx + exact ENNReal.ofReal_le_ofReal hx.1 + · rw [← withDensity_const] + apply withDensity_mono + filter_upwards [hrho.2.2.2] with x hx + exact ENNReal.ofReal_le_ofReal hx.2 + +omit [MetricSpace M] [BorelSpace M] [CompactSpace M] in +lemma volume_absolutelyContinuous_densityMeasure {vol : Measure M} {lam cap : ℝ} + {rho : M → ℝ} (hlam : 0 < lam) (hrho : AdmissibleDensity vol lam cap rho) : + vol ≪ densityMeasure vol rho := by + apply withDensity_absolutelyContinuous' hrho.1.ennreal_ofReal + filter_upwards [hrho.2.2.2] with x hx + exact (ENNReal.ofReal_pos.mpr (hlam.trans_le hx.1)).ne' +end DensityBounds + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/DensityOriginalJets.lean b/lean/OAI/Analysis/BiholderTransport/Volume/DensityOriginalJets.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0803d8a39605d12279c8d3d27eae67ff6724509 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/DensityOriginalJets.lean @@ -0,0 +1,69 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Oscillation.SectionOscillation +import OAI.Analysis.BiholderTransport.Contact.IntrinsicCEMS +import OAI.Analysis.BiholderTransport.LinearAlgebra.TrueCenterMatrix + +namespace OAI + +section + +noncomputable section +open Set Filter Manifold Bundle MeasureTheory +open scoped Topology ContDiff BoundedContinuousFunction + +namespace WeakMTWTransport +section DensityOriginalJets +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance densityOriginalFinite (x:M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +local instance densityOriginalComplete (x:M) : CompleteSpace (TangentSpace 𝓘(ℝ,Model n) x) := + FiniteDimensional.complete ℝ _ + +def OriginalCenterGood (u:M → ℝ) (χ:ℝ) (y:M) : Prop := + ∃p:TangentSpace 𝓘(ℝ,Model n) y, + ∃A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y, + NormalAlexandrovContact (n:=n) u y p A ∧ + (∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d) ∧ + χ≤expJacobian y p*(normalHessianOperator y p+A).det + +omit [Nonempty M] [MeasurableSpace M] [BorelSpace M] in +lemma OriginalCenterGood.of_contact {u:M → ℝ} {χ:ℝ} {y:M} + {p:TangentSpace 𝓘(ℝ,Model n) y} + {A:TangentSpace 𝓘(ℝ,Model n) y →L[ℝ] TangentSpace 𝓘(ℝ,Model n) y} + (hA:NormalAlexandrovContact (n:=n) u y p A) + (hp:∀d,d≠0 → 0 < inner ℝ ((normalHessianOperator y p+A) d) d) + (hlo:χ≤expJacobian y p*|(normalHessianOperator y p+A).det|) : + OriginalCenterGood (n:=n) u χ y := by + have hs : ∀d e,inner ℝ ((normalHessianOperator y p+A) d) e= + inner ℝ d ((normalHessianOperator y p+A) e) := normal_contact_matrix_symmetric hA + have hdet : 0 < (normalHessianOperator y p+A).det := + symmetric_det_pos (A:=normalHessianOperator y p+A) hs hp + exact ⟨p,A,hA,hp,by simpa only [abs_of_pos hdet] using hlo⟩ + +lemma exists_density_original_center_good {lam cap:ℝ} (hlam:00,∀(x0:M) (uv:(M →ᵇ ℝ)×(M →ᵇ ℝ)), + uv∈densityDualClass (metricVolume n) lam cap x0 → + ∀ᵐ y ∂metricVolume n,OriginalCenterGood (n:=n) uv.1 χ y := by + obtain ⟨χ,_,hχ,_,H⟩:=minimizing_dualPair_uniform_intrinsic_cems (n:=n) (M:=M) hlam hcap + refine ⟨χ,hχ,?_⟩ + intro x0 uv huv + have hd:=densityDualClass_isDual huv + obtain ⟨_,ρ0,ρ1,h0,h1,hmin⟩:=huv + have Ha:=H ρ1 ρ0 h1 h0 uv.2 uv.1 ⟨hd.2,hd.1⟩ (dual_minimum_swap hmin) + filter_upwards [Ha] with y hy + obtain ⟨p,A,hA,hp,hlo,_⟩:=hy + exact OriginalCenterGood.of_contact hA hp hlo +end DensityOriginalJets +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/DiagonalKernel.lean b/lean/OAI/Analysis/BiholderTransport/Volume/DiagonalKernel.lean new file mode 100644 index 0000000000000000000000000000000000000000..3953a6cd8c520e767c52056d8ff84b0b1a837652 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/DiagonalKernel.lean @@ -0,0 +1,252 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.CostGeometry.SplitStationary + +namespace OAI + +noncomputable section + +namespace WeakMTWTransport + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Manifold Bundle +open scoped Topology ContDiff Manifold Bundle + +open Set Filter Bundle +open scoped Topology Bundle + +open scoped Topology +open Function Manifold Set +open Manifold Bundle +open scoped Manifold Bundle +open Set + +open Set Filter +open scoped Topology ContDiff + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set Filter +open scoped ContDiff Topology + +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + +lemma diagonal_stationary_hessian_null {F : E×E → ℝ} {p k : E} + (hF : ContDiffAt ℝ 2 F (p,p)) + (hstat : ∀ᶠ v in 𝓝 p, fderiv ℝ F (v,v) (0,k)=0) + (hker : ∀ᶠ v in 𝓝 p, fderiv ℝ F (p,v) (k,0)=0) : + fderiv ℝ (fderiv ℝ F) (p,p) (0,k) (0,k)=0 := by + have hdf := (hF.fderiv_right (m := 1) (by norm_num)).differentiableAt (by norm_num) + let L : E →L[ℝ] E×E := (ContinuousLinearMap.id ℝ E).prod (ContinuousLinearMap.id ℝ E) + have hD₁ := ((hdf.hasFDerivAt.comp (f := fun v : E => (v,v)) p L.hasFDerivAt).clm_apply + (hasFDerivAt_const ((0:E),k) p)).fderiv + have hz₁ : fderiv ℝ (fun v : E => fderiv ℝ F (v,v) (0,k)) p=0 := by + have heq : (fun v : E => fderiv ℝ F (v,v) (0,k)) =ᶠ[𝓝 p] (fun _ => (0:ℝ)) := hstat + rw [heq.fderiv_eq] + exact (hasFDerivAt_const (0:ℝ) p).fderiv + have hd₁ := congrArg (fun A : E →L[ℝ] ℝ => A k) (hD₁.symm.trans hz₁) + simp only [add_apply,ContinuousLinearMap.comp_apply, + zero_apply,map_zero,zero_add,ContinuousLinearMap.flip_apply,L, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply] at hd₁ + have hL₂ : HasFDerivAt (fun v : E => (p,v)) + ((0 : E →L[ℝ] E).prod (ContinuousLinearMap.id ℝ E)) p := + (hasFDerivAt_const p p).prodMk (hasFDerivAt_id (𝕜 := ℝ) p) + have hD₂ := ((hdf.hasFDerivAt.comp (f := fun v : E => (p,v)) p hL₂).clm_apply + (hasFDerivAt_const (k,(0:E)) p)).fderiv + have hz₂ : fderiv ℝ (fun v : E => fderiv ℝ F (p,v) (k,0)) p=0 := by + have heq : (fun v : E => fderiv ℝ F (p,v) (k,0)) =ᶠ[𝓝 p] (fun _ => (0:ℝ)) := hker + rw [heq.fderiv_eq] + exact (hasFDerivAt_const (0:ℝ) p).fderiv + have hd₂ := congrArg (fun A : E →L[ℝ] ℝ => A k) (hD₂.symm.trans hz₂) + simp only [add_apply,ContinuousLinearMap.comp_apply, + zero_apply,map_zero,zero_add,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.prod_apply,ContinuousLinearMap.id_apply] at hd₂ + rw [(hF.isSymmSndFDerivAt (by simp)).eq] at hd₂ + have heq : (k,k)=(k,0)+((0:E),k) := by ext <;> simp + rw [heq,map_add,add_apply,hd₂,zero_add] at hd₁ + exact hd₁ +end + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma second_leg_cost_smooth {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} {t : ℝ} + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) : + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) ∞ + (fun q : M×M => cost q.1 q.2) (riemannianExp x (t • p),riemannianExp x p) := by + have hc := cost_contMDiffAt_of_injectivityDomain + (⟨(sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1, + (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2⟩ : + TangentBundle 𝓘(ℝ,Model n) M) hright + dsimp only at hc + rw [shifted_exp_endpoint] at hc + simpa only [riemannianExp_smul] using hc + +lemma diagonalSplitAction_endpoint_kernel {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (hleft : t • p ∈ injectivityDomain x) + (hright : (1-t) • (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).2 ∈ + injectivityDomain (sprayFlow t (⟨x,p⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) + (hk : mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp x) p k=0) : + ∀ᶠ v : TangentSpace 𝓘(ℝ,Model n) x in 𝓝 p, + fderiv ℝ (diagonalSplitAction x t) (p,v) (k,0)=0 := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let y := riemannianExp x p + have he := (contMDiff_riemannianExp_fiber (n := n) x).mdifferentiable (by simp) + have hc := (second_leg_cost_smooth hright).of_le (m := 1) (by simp) + have hcn : ∀ᶠ z : M×M in 𝓝 (riemannianExp x (t • p),y), + ContMDiffAt (𝓘(ℝ,Model n).prod 𝓘(ℝ,Model n)) 𝓘(ℝ,ℝ) 1 + (fun q : M×M => cost q.1 q.2) z := + (contMDiffAt_iff_contMDiffAt_nhds (by norm_num)).mp hc + have hj : Continuous (fun v : V => (riemannianExp x (t • v),y)) := + ((continuous_riemannianExp x).comp (by fun_prop)).prodMk continuous_const + have hcnear := hj.continuousAt.eventually hcn + have hF := diagonalSplitAction_contDiffAt hleft hright + have hFn := (hF.of_le (m := 1) (by simp)).eventually (by norm_num) + have hL : Continuous (fun v : V => (p,v)) := continuous_const.prodMk continuous_id + have hFnear := hL.continuousAt.eventually hFn + filter_upwards [hcnear,hFnear] with v hcv hFv + change ContDiffAt ℝ 1 (diagonalSplitAction x t) (p,v) at hFv + have hcost := (hcv.comp y (contMDiffAt_const.prodMk contMDiffAt_id)).mdifferentiableAt (by norm_num) + have hD := hcost.hasMFDerivAt.comp p (he p).hasMFDerivAt + have hD' : HasFDerivAt (fun w : V => cost (riemannianExp x (t • v)) (riemannianExp x w)) + ((mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) (fun z => cost (riemannianExp x (t • v)) z) y).comp + (mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) (riemannianExp x) p)) p := by + convert! hD.hasFDerivAt using 1 + have hpart := (hD'.mul_const (1-t)⁻¹).const_add + (cost x (riemannianExp x (t • v))/t) + have heqfun : (fun w : V => diagonalSplitAction x t (w,v)) = + (fun w : V => cost x (riemannianExp x (t • v))/t + + cost (riemannianExp x (t • v)) (riemannianExp x w)*(1-t)⁻¹) := by + funext w + simp only [diagonalSplitAction,splitNormalAction,riemannianExp_zero,div_eq_mul_inv] + rw [←heqfun] at hpart + have hl := (hasFDerivAt_id (𝕜 := ℝ) p).prodMk (hasFDerivAt_const v p) + have hfull := (hFv.differentiableAt (by norm_num)).hasFDerivAt.comp + (f := fun w : V => (w,v)) p hl + have hh := congrArg (fun A : V →L[ℝ] ℝ => A k) (hfull.unique hpart) + change fderiv ℝ (diagonalSplitAction x t) (p,v) (k,0) = + (1-t)⁻¹ • (mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,ℝ) + (fun z => cost (riemannianExp x (t • v)) z) y) + (mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) (riemannianExp x) p k) at hh + rw [hk,map_zero,smul_zero] at hh + exact hh + +lemma diagonalSplitAction_conjugate_hessian_null {x : M} {p k : TangentSpace 𝓘(ℝ,Model n) x} + {t : ℝ} (ht : 0 diagonalSplitAction_stationary ht ht1 hv.1 hv.2 k) + · exact diagonalSplitAction_endpoint_kernel hleft hright hk + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/EuclideanVolumeFactorNe.lean b/lean/OAI/Analysis/BiholderTransport/Volume/EuclideanVolumeFactorNe.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ef93227514ee436bbf51a1d8a15a58dac93ea0a --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/EuclideanVolumeFactorNe.lean @@ -0,0 +1,50 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Model + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Metric Bundle +open scoped Topology ContDiff ENNReal NNReal + +namespace WeakMTWTransport + +lemma euclideanVolumeFactor_ne_zero (n : ℕ) : euclideanVolumeFactor n≠0 := by + have hdim : (Module.finrank ℝ (Model n):ℝ)=(n:ℝ) := by simp [Model] + have hH : (Measure.hausdorffMeasure (n:ℝ) : Measure (Model n)).IsAddHaarMeasure := by + rw [←hdim]; infer_instance + exact ENNReal.div_ne_zero.mpr ⟨(measure_ball_pos volume (0:Model n) zero_lt_one).ne', + measure_ball_lt_top.ne⟩ + +lemma euclideanVolumeFactor_ne_top (n : ℕ) : euclideanVolumeFactor n≠⊤ := by + have hdim : (Module.finrank ℝ (Model n):ℝ)=(n:ℝ) := by simp [Model] + have hH : (Measure.hausdorffMeasure (n:ℝ) : Measure (Model n)).IsAddHaarMeasure := by + rw [←hdim]; infer_instance + exact ENNReal.div_ne_top measure_ball_lt_top.ne + (measure_ball_pos _ (0:Model n) zero_lt_one).ne' + +instance metricVolume_model_haar (n : ℕ) : + (metricVolume (M := Model n) n).IsAddHaarMeasure := by + have hdim : (Module.finrank ℝ (Model n):ℝ)=(n:ℝ) := by simp [Model] + have hH : (Measure.hausdorffMeasure (n:ℝ) : Measure (Model n)).IsAddHaarMeasure := by + rw [←hdim]; infer_instance + exact Measure.IsAddHaarMeasure.smul _ (euclideanVolumeFactor_ne_zero n) + (euclideanVolumeFactor_ne_top n) + +lemma lipschitzOn_metricVolume_image_le {X Y : Type*} [MetricSpace X] [MetricSpace Y] + [MeasurableSpace X] [BorelSpace X] [MeasurableSpace Y] [BorelSpace Y] + {C : ℝ≥0} {f : X → Y} {s : Set X} (hf : LipschitzOnWith C f s) (n : ℕ) : + metricVolume n (f '' s)≤(C:ℝ≥0∞)^n*metricVolume n s := by + have H := hf.hausdorffMeasure_image_le (d := (n:ℝ)) (by positivity) + have hh := mul_le_mul_right H (euclideanVolumeFactor n) + simpa only [metricVolume,Measure.smul_apply,smul_eq_mul,ENNReal.rpow_natCast, + mul_assoc,mul_comm,mul_left_comm] using hh + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/ExponentialJacobian.lean b/lean/OAI/Analysis/BiholderTransport/Volume/ExponentialJacobian.lean new file mode 100644 index 0000000000000000000000000000000000000000..07375c6e5b8f5e578fbc5b3dd1ece0c7a0220157 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/ExponentialJacobian.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.UniformJacobian + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ExponentialJacobian +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteExponentialJacobian (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma mfderiv_exp_zero_norm (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + ‖mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp (n := n) x) 0 v‖=‖v‖ := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let z : TangentBundle 𝓘(ℝ,Model n) M := ⟨x,v⟩ + have hline : HasFDerivAt (fun t : ℝ => t • v) + ((1 : ℝ →L[ℝ] ℝ).smulRight v) 0 := (hasFDerivAt_id 0).smul_const v + have he := ((contMDiff_riemannianExp_fiber x ((0:ℝ) • v)).mdifferentiableAt (by simp)).hasMFDerivAt + have hc := he.comp 0 hline.hasMFDerivAt + have hs := hasMFDerivAt_spray_projection ((sprayFlow_curve z).isMIntegralCurveAt 0) + have hfun : (fun t : ℝ => riemannianExp (n := n) x (t • v))=(fun t : ℝ => (sprayFlow t z).1) := + funext (riemannianExp_smul x v) + have hsN : ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) + (fun t : ℝ => (sprayFlow t z).1) 0 1‖=‖v‖ := by + rw [hs.mfderiv] + change ‖(1 : ℝ) • (sprayFlow 0 z).2‖ = ‖v‖ + simpa only [one_smul] using sprayFlow_speed 0 z + have hnorm := (congrArg (fun f : ℝ → M => + ‖mfderiv 𝓘(ℝ,ℝ) 𝓘(ℝ,Model n) f 0 1‖) hfun).trans hsN + have hcm := hc.mfderiv + simp only [Function.comp_def] at hcm + rw [hcm] at hnorm + change ‖mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) + ((0:ℝ) • v) ((1:ℝ) • v)‖=‖v‖ at hnorm + simp only [one_smul] at hnorm + exact (congrArg (fun w : V => ‖mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) + (riemannianExp (n := n) x) w v‖) (zero_smul ℝ v)).symm.trans hnorm + +lemma expJacobian_zero (x : M) : expJacobian (n := n) x 0=1 := by + let F : TangentSpace 𝓘(ℝ,Model n) x →ₗ[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp (n := n) x 0) := (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) 0).toLinearMap + let e : TangentSpace 𝓘(ℝ,Model n) x →ₗᵢ[ℝ] + TangentSpace 𝓘(ℝ,Model n) (riemannianExp (n := n) x 0) := + { toLinearMap := F, norm_map' := mfderiv_exp_zero_norm x } + exact e.normDet_eq_one + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma expJacobian_ne_zero_iff (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + expJacobian (n := n) x p≠0 ↔ Function.Injective + (mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) p) := by + rw [expJacobian,ne_eq,LinearMap.normDet_eq_zero_iff_ker_ne_bot,not_not, + LinearMap.ker_eq_bot] + rfl + +lemma expJacobian_pos_of_injectivityDomain {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (hp : p∈injectivityDomain x) : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +local instance tangentFiniteIntrinsicJacobian (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def chartJacobian (a x : M) : ℝ := + let F : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] Model n := + mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) (extChartAt 𝓘(ℝ,Model n) a) x + F.toLinearMap.normDet + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma chartJacobian_nonneg (a x : M) : 0≤chartJacobian (n := n) a x := + LinearMap.normDet_nonneg _ + +lemma normDet_chart_exp (a x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) + (hp : riemannianExp (n := n) x p∈(extChartAt 𝓘(ℝ,Model n) a).source) : + (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) p).toLinearMap.normDet= + chartJacobian (n := n) a (riemannianExp (n := n) x p)*expJacobian (n := n) x p := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let E : V →L[ℝ] TangentSpace 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) := + mfderiv 𝓘(ℝ,V) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) p + let C : TangentSpace 𝓘(ℝ,Model n) (riemannianExp (n := n) x p) →L[ℝ] Model n := + mfderiv 𝓘(ℝ,Model n) 𝓘(ℝ,Model n) (extChartAt 𝓘(ℝ,Model n) a) (riemannianExp (n := n) x p) + have hd := mfderiv_comp p (mdifferentiableAt_extChartAt (by simpa only [extChartAt_source] using hp)) + ((contMDiff_riemannianExp_fiber x p).mdifferentiableAt (by simp)) + rw [mfderiv_eq_fderiv] at hd + change fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) p=C.comp E at hd + rw [hd] + exact LinearMap.normDet_comp_of_finrank_eq E.toLinearMap C.toLinearMap rfl + +lemma normDet_chart_exp_zero (a x : M) + (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) : + (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) 0).toLinearMap.normDet= + chartJacobian (n := n) a x := by + have h := normDet_chart_exp a x 0 (by simpa only [riemannianExp_zero] using hx) + rw [expJacobian_zero,mul_one] at h + simpa only [riemannianExp_zero] using h + +lemma intrinsic_contact_det {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + (a b : M) (hx : x∈(extChartAt 𝓘(ℝ,Model n) a).source) + (hp : riemannianExp (n := n) x p∈(extChartAt 𝓘(ℝ,Model n) b).source) + (W : TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) + (R : Model n →L[ℝ] TangentSpace 𝓘(ℝ,Model n) x) + (hR : (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) 0).comp R= + ContinuousLinearMap.id ℝ (Model n)) : + |((fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) b) ∘ riemannianExp (n := n) x) p).comp (W.comp R)).det| * + chartJacobian (n := n) a x= + chartJacobian (n := n) b (riemannianExp (n := n) x p)*expJacobian (n := n) x p*|W.det| := by + have hprod : chartJacobian (n := n) a x*R.toLinearMap.normDet=1 := by + have h := congrArg (fun F : Model n →L[ℝ] Model n => F.toLinearMap.normDet) hR + rw [show (ContinuousLinearMap.id ℝ (Model n)).toLinearMap=LinearMap.id by rfl, + LinearMap.normDet_id] at h + change ((fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) 0).toLinearMap ∘ₗ + R.toLinearMap).normDet=1 at h + erw [LinearMap.normDet_comp_of_finrank_eq R.toLinearMap + (fderiv ℝ ((extChartAt 𝓘(ℝ,Model n) a) ∘ riemannianExp (n := n) x) 0).toLinearMap rfl] at h + rw [normDet_chart_exp_zero a x hx] at h + exact h + rw [←LinearMap.normDet_eq_abs_det] + rw [normDet_comp_three R W _ rfl rfl,normDet_chart_exp b x p hp, + LinearMap.normDet_eq_abs_det] + calc + _ = (chartJacobian (n := n) b (riemannianExp (n := n) x p)*expJacobian (n := n) x p*|W.det|)* + (chartJacobian (n := n) a x*R.toLinearMap.normDet) := by ring + _ = _ := by rw [hprod,mul_one] + +end IntrinsicJacobian +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/JensenNullPullback.lean b/lean/OAI/Analysis/BiholderTransport/Volume/JensenNullPullback.lean new file mode 100644 index 0000000000000000000000000000000000000000..5435d79fce31800a876a5c2618e2da3f2c618e31 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/JensenNullPullback.lean @@ -0,0 +1,31 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Volume.ContactJacobianMeasure + +namespace OAI + +noncomputable section +open Set Filter MeasureTheory +open scoped Topology ENNReal NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + +lemma ae_nonsingular_map_avoids_null {Y : E → E} {D : E → E →L[ℝ] E} + {N : Set E} (hN : μ N=0) : + ∀ᵐ z ∂μ,HasFDerivAt Y (D z) z → (D z).det≠0 → Y z∉N := by + let Z := {z | HasFDerivAt Y (D z) z ∧ (D z).det≠0 ∧ Y z∈N} + have hZ : μ Z=0 := measure_eq_zero_of_nonsingular_null_image μ + (fun z hz => hz.1.hasFDerivWithinAt) (fun z hz => hz.2.1) + (measure_mono_null (by rintro _ ⟨z,hz,rfl⟩; exact hz.2.2) hN) + have H : ∀ᵐ z ∂μ,z∉Z := by + rw [ae_iff] + simpa only [not_not,Set.ofPred_mem_eq] using hZ + filter_upwards [H] with z hz hd hdet hmem + exact hz ⟨hd,hdet,hmem⟩ +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/LocalCharts.lean b/lean/OAI/Analysis/BiholderTransport/Volume/LocalCharts.lean new file mode 100644 index 0000000000000000000000000000000000000000..e767f3ade9a3912cd72d650885843da603291530 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/LocalCharts.lean @@ -0,0 +1,153 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LocalFlow.ForwardChart + +namespace OAI + +section + +section + +noncomputable section +open Set Filter MeasureTheory +open scoped ENNReal NNReal Topology + +namespace WeakMTWTransport +section Area +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] + (μ : Measure E) [μ.IsAddHaarMeasure] + +lemma ae_jacobian_bounds_of_image_mass {s : Set E} (hs : MeasurableSet s) + {f : E → E} {f' : E → E →L[ℝ] E} + (hf' : ∀ x∈s, HasFDerivWithinAt f (f' x) s x) (hi : InjOn f s) + {a b : ℝ≥0∞} + (hmass : ∀ A : Set E, MeasurableSet A → A⊆s → + a*μ A≤μ (f '' A) ∧ μ (f '' A)≤b*μ A) : + ∀ᵐ x ∂μ.restrict s, a≤ENNReal.ofReal |(f' x).det| ∧ + ENNReal.ofReal |(f' x).det|≤b := by + have hJ := aemeasurable_ofReal_abs_det_fderivWithin μ hs hf' + have harea (A : Set E) (hA : MeasurableSet A) : + (∫⁻ x in A, ENNReal.ofReal |(f' x).det| ∂μ.restrict s)=μ (f '' (A∩s)) := by + rw [Measure.restrict_restrict hA] + exact lintegral_abs_det_fderiv_eq_addHaar_image μ (hA.inter hs) + (fun x hx => (hf' x hx.2).mono inter_subset_right) (hi.mono inter_subset_right) + have hlo : ∀ᵐ x ∂μ.restrict s, a≤ENNReal.ofReal |(f' x).det| := by + apply ae_le_of_forall_setLIntegral_le_of_sigmaFinite₀ aemeasurable_const + intro A hA _ + rw [harea A hA,lintegral_const,Measure.restrict_apply MeasurableSet.univ, + univ_inter,Measure.restrict_apply hA] + exact (hmass (A∩s) (hA.inter hs) inter_subset_right).1 + have hup : ∀ᵐ x ∂μ.restrict s, ENNReal.ofReal |(f' x).det|≤b := by + apply ae_le_of_forall_setLIntegral_le_of_sigmaFinite₀ hJ + intro A hA _ + rw [harea A hA,lintegral_const,Measure.restrict_apply MeasurableSet.univ, + univ_inter,Measure.restrict_apply hA] + exact (hmass (A∩s) (hA.inter hs) inter_subset_right).2 + exact hlo.and hup + +end Area +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter MeasureTheory Manifold Metric +open scoped ENNReal NNReal Topology + +namespace WeakMTWTransport + +lemma metricVolume_lipschitz_image_le_nat {n : ℕ} {X Y : Type*} + [MetricSpace X] [MetricSpace Y] [MeasurableSpace X] [MeasurableSpace Y] + [BorelSpace X] [BorelSpace Y] {f : X → Y} {s : Set X} {C : ℝ≥0} + (hf : LipschitzOnWith C f s) : + metricVolume n (f '' s)≤(C:ℝ≥0∞)^n*metricVolume n s := by + simpa only [ENNReal.rpow_natCast] using metricVolume_lipschitz_image_le (n := n) hf + +lemma image_mass_in_bilipschitz_coordinates {n : ℕ} {M : Type*} + [MetricSpace M] [MeasurableSpace M] [BorelSpace M] + (d e : PartialEquiv M (Model n)) {G : Set M} {T : M → M} + (hGs : G⊆d.source) (hTs : T '' G⊆e.source) + {C D H K : ℝ≥0} (hC : 0.mpr hmhi + have hpos : ∀ᶠ δ : ℝ≥0 in 𝓝[>] (0 : ℝ≥0), 0 < δ := self_mem_nhdsWithin + obtain ⟨δ,hδ,Hδ⟩ := (hpos.and (mul_le_addHaar_image_of_lt_det μ A hm)).exists + obtain ⟨U,hU,happrox⟩ := hf.approximates_deriv_on_nhds (Or.inr hδ) + obtain ⟨s,hs,hs0,hsfin,hsimage⟩ := hsmall U hU + have H := (Hδ s f (happrox.mono_set hs)).trans hsimage + have Hm : (m:ℝ≥0∞) ≤ ENNReal.ofReal C := + (ENNReal.mul_le_mul_iff_left hs0 hsfin).mp H + rw [←ENNReal.ofReal_coe_nnreal] at Hm + have Hm' : (m:ℝ) ≤ C := (ENNReal.ofReal_le_ofReal_iff hC).mp Hm + exact (not_le_of_gt hmlo) Hm' + +end LocalJacobianBarrier +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/Measurable.lean b/lean/OAI/Analysis/BiholderTransport/Volume/Measurable.lean new file mode 100644 index 0000000000000000000000000000000000000000..c832a4fd2134cf5730ad31c039ef6579ec90a085 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/Measurable.lean @@ -0,0 +1,312 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Contact.Subgradient + +namespace OAI + +section +section +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +noncomputable section +open Set Filter +open scoped Topology NNReal + +namespace WeakMTWTransport +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] +open MeasureTheory + +namespace ConvexProximal +variable [FiniteDimensional ℝ E] +section Measurable +open MeasureTheory + +variable [MeasurableSpace E] [BorelSpace E] + +lemma exists_subgradient {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hc : ConvexOn ℝ univ f) (x : E) : + ∃ p, IsSubgradientOn f univ x p := by + let μ : Measure E := Measure.hausdorffMeasure (Module.finrank ℝ E) + have hdense : Dense {z | DifferentiableAt ℝ f z} := + μ.dense_of_ae (hlip.ae_differentiableAt (μ := μ)) + let P := Metric.closedBall (0:E) (L:ℝ) + have hP : IsCompact P := isCompact_closedBall _ _ + have : CompactSpace P := isCompact_iff_compactSpace.mp hP + let C : Set (E × P) := {z | IsSubgradientOn f univ z.1 z.2.1} + have hfc := hlip.continuous + have hC : IsClosed C := by + simp only [C, IsSubgradientOn, ofPred_forall] + apply isClosed_iInter + intro y + apply isClosed_iInter + intro _hy + exact isClosed_le (by fun_prop) (by fun_prop) + have hproj : IsClosed (Prod.fst '' C) := isClosedMap_fst_of_compactSpace C hC + have hsub : {z | DifferentiableAt ℝ f z} ⊆ Prod.fst '' C := by + intro z hz + let p := (InnerProductSpace.toDual ℝ E).symm (fderiv ℝ f z) + have hp : IsSubgradientOn f univ z p := gradient_subgradient hc hz.hasFDerivAt + have hpn : p ∈ P := by + simpa only [P, Metric.mem_closedBall, dist_zero_right] using subgradient_norm_le hlip hp + exact ⟨(z, ⟨p, hpn⟩), hp, rfl⟩ + have hx : x ∈ Prod.fst '' C := by + rw [← hproj.closure_eq] + exact (Dense.mono hsub hdense) x + obtain ⟨⟨z,p⟩, hz, rfl⟩ := hx + exact ⟨p.1, hz⟩ + +lemma prox_surjective {f : E → ℝ} {L : ℝ≥0} (hlip : LipschitzWith L f) + (hc : ConvexOn ℝ univ f) : Function.Surjective (prox f L hlip) := by + intro x + obtain ⟨p,hp⟩ := exists_subgradient hlip hc x + exact ⟨x+p, prox_of_subgradient hlip hc hp⟩ + +lemma ae_exists_regular_proximal_inverse {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) (hc : ConvexOn ℝ univ f) + (μ : Measure E) [μ.IsAddHaarMeasure] : + ∀ᵐ x ∂μ, ∃ y : E, prox f L hlip y = x ∧ + DifferentiableAt ℝ (prox f L hlip) y ∧ + (fderiv ℝ (prox f L hlip) y).det ≠ 0 := by + let P := prox f L hlip + let ν : Measure E := Measure.hausdorffMeasure (Module.finrank ℝ E) + have hP : LipschitzWith 1 P := prox_lipschitz hlip hc + let N : Set E := {y | ¬DifferentiableAt ℝ P y} + let Z : Set E := {y | DifferentiableAt ℝ P y ∧ (fderiv ℝ P y).det = 0} + have hN : ν N = 0 := (ae_iff).mp (hP.ae_differentiableAt (μ := ν)) + have hPN : ν (P '' N) = 0 := by + have hh := hP.hausdorffMeasure_image_le + (by positivity : (0:ℝ) ≤ Module.finrank ℝ E) N + simpa only [ν, hN, mul_zero, nonpos_iff_eq_zero] using hh + have hNμ : μ (P '' N) = 0 := + (Measure.absolutelyContinuous_isAddHaarMeasure μ ν) hPN + have hZμ : μ (P '' Z) = 0 := + addHaar_image_eq_zero_of_det_fderivWithin_eq_zero μ + (fun y hy => hy.1.hasFDerivAt.hasFDerivWithinAt) (fun y hy => hy.2) + have hgood : ∀ᵐ x ∂μ, x ∉ P '' N ∧ x ∉ P '' Z := by + exact (ae_iff.mpr (by simpa only [not_not, Set.ofPred_mem_eq] using hNμ)).and (ae_iff.mpr (by simpa only [not_not, Set.ofPred_mem_eq] using hZμ)) + filter_upwards [hgood] with x hx + obtain ⟨y,hy⟩ := prox_surjective hlip hc x + have hd : DifferentiableAt ℝ P y := by + by_contra hn + exact hx.1 ⟨y,hn,hy⟩ + refine ⟨y,hy,hd,?_⟩ + intro hz + exact hx.2 ⟨y,⟨hd,hz⟩,hy⟩ + +omit [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] in + +lemma subgradient_line_deriv {f : E → ℝ} {x h : E} {t a : ℝ} {p : E} + (hp : IsSubgradientOn f univ (x+t • h) p) + (hd : HasDerivAt (fun s : ℝ => f (x+s • h)) a t) : + a = inner ℝ p h := by + have hm : IsLocalMin (fun s : ℝ => f (x+s • h) - s*inner ℝ p h) t := by + apply Filter.Eventually.of_forall + intro s + have hh := hp (x+s • h) (mem_univ _) + have heq : (x+s • h)-(x+t • h) = (s-t) • h := by + simp only [sub_smul]; abel + rw [heq,real_inner_smul_right] at hh + dsimp + nlinarith + have hh := hm.hasDerivAt_eq_zero (hd.sub ((hasDerivAt_id t).mul_const (inner ℝ p h))) + simpa only [one_mul, sub_eq_zero] using hh + +lemma quadraticExpansion_of_subgradient_differential {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) (hc : ConvexOn ℝ univ f) + {x p : E} {A : E →L[ℝ] E} + (hdiff : ∀ eps : ℝ, 0 < eps → ∃ delta : ℝ, 0 < delta ∧ + ∀ z q : E, ‖z-x‖ < delta → IsSubgradientOn f univ z q → + ‖q-p-A (z-x)‖ ≤ eps*‖z-x‖) : + HasQuadraticExpansion (fun h => f (x+h)) p A := by + intro eps heps + obtain ⟨d,hd,hbound⟩ := hdiff eps heps + refine ⟨d,hd,?_⟩ + intro h hh + let g : ℝ → ℝ := fun t => f (x+t • h) + have hline : LipschitzWith ‖h‖₊ (fun t : ℝ => x+t • h) := by + apply LipschitzWith.of_dist_le_mul + intro s t + have heq : (x+s • h)-(x+t • h) = (s-t) • h := by + simp only [sub_smul]; abel + simp only [dist_eq_norm,heq,norm_smul,Real.norm_eq_abs,coe_nnnorm] + exact le_of_eq (mul_comm _ _) + have hgAC : AbsolutelyContinuousOnInterval g 0 1 := + (hlip.comp hline).lipschitzOnWith.absolutelyContinuousOnInterval + let a : ℝ := inner ℝ p h + let b : ℝ := inner ℝ (A h) h + have hlin : IntervalIntegrable (fun t : ℝ => a+t*b) volume 0 1 := + (by fun_prop : Continuous (fun t : ℝ => a+t*b)).intervalIntegrable _ _ + have haebound : ∀ᵐ t : ℝ, t ∈ uIoc (0:ℝ) 1 → + ‖deriv g t - (a+t*b)‖ ≤ eps*‖h‖^2 := by + filter_upwards [hgAC.ae_differentiableAt] with t ht htc + have ht01 : 0 ≤ t ∧ t ≤ 1 := by + rw [uIoc_of_le (by norm_num : (0:ℝ) ≤ 1)] at htc + exact ⟨htc.1.le,htc.2⟩ + have htu : t ∈ uIcc (0:ℝ) 1 := by + rw [uIcc_of_le (by norm_num : (0:ℝ) ≤ 1)] + exact ht01 + obtain ⟨q,hq⟩ := exists_subgradient hlip hc (x+t • h) + have hder : deriv g t = inner ℝ q h := subgradient_line_deriv hq (ht htu).hasDerivAt + have hth : ‖(x+t • h)-x‖ ≤ ‖h‖ := by + simp only [add_sub_cancel_left,norm_smul_of_nonneg ht01.1] + exact mul_le_of_le_one_left (norm_nonneg _) ht01.2 + have hnorm := hbound (x+t • h) q (hth.trans_lt hh) hq + have heq : deriv g t - (a+t*b) = inner ℝ (q-p-A ((x+t • h)-x)) h := by + simp only [hder,a,b,inner_sub_left,add_sub_cancel_left,map_smul, + real_inner_smul_left] + ring + calc + ‖deriv g t - (a+t*b)‖ = ‖inner ℝ (q-p-A ((x+t • h)-x)) h‖ := congrArg norm heq + _ ≤ ‖q-p-A ((x+t • h)-x)‖*‖h‖ := norm_inner_le_norm _ _ + _ ≤ (eps*‖(x+t • h)-x‖)*‖h‖ := mul_le_mul_of_nonneg_right hnorm (norm_nonneg _) + _ ≤ (eps*‖h‖)*‖h‖ := mul_le_mul_of_nonneg_right + (mul_le_mul_of_nonneg_left hth heps.le) (norm_nonneg _) + _ = eps*‖h‖^2 := by ring + have hi := intervalIntegral.norm_integral_le_of_norm_le_const_ae haebound + rw [intervalIntegral.integral_sub hgAC.intervalIntegrable_deriv hlin, + hgAC.integral_deriv_eq_sub] at hi + have hilin : (∫ t : ℝ in (0:ℝ)..1, a+t*b) = a+b/2 := by + rw [intervalIntegral.integral_add (f := fun _ : ℝ => a) (g := fun t : ℝ => t*b) + (continuous_const.intervalIntegrable _ _) + ((by fun_prop : Continuous (fun t : ℝ => t*b)).intervalIntegrable _ _), + intervalIntegral.integral_const, intervalIntegral.integral_mul_const,integral_id] + norm_num + ring + rw [hilin] at hi + simpa only [HasQuadraticExpansion,quadraticTaylor,g,a,b,one_smul,zero_smul,add_zero, + Real.norm_eq_abs,sub_zero,abs_one,mul_one,sub_sub,add_assoc] using hi + +omit [MeasurableSpace E] [BorelSpace E] in + +lemma symmetrized_quadratic (A : E →L[ℝ] E) : + let S := (1/2 : ℝ) • (A + A.adjoint) + (∀ h k, inner ℝ (S h) k = inner ℝ h (S k)) ∧ + (∀ h, inner ℝ (S h) h = inner ℝ (A h) h) := by + dsimp + constructor + · intro h k + simp only [smul_apply,add_apply,real_inner_smul_left,real_inner_smul_right, + inner_add_left,inner_add_right,A.adjoint_inner_left,A.adjoint_inner_right] + ring + · intro h + simp only [smul_apply,add_apply,real_inner_smul_left,inner_add_left, + A.adjoint_inner_left,real_inner_comm h (A h)] + ring + +lemma ae_quadraticExpansion_lipschitz_convex {f : E → ℝ} {L : ℝ≥0} + (hlip : LipschitzWith L f) (hc : ConvexOn ℝ univ f) + (μ : Measure E) [μ.IsAddHaarMeasure] : + ∀ᵐ x ∂μ, ∃ p : E, ∃ A : E →L[ℝ] E, + (∀ h k, inner ℝ (A h) k = inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => f (x+h)) p A := by + filter_upwards [hlip.ae_differentiableAt (μ := μ), + ae_exists_regular_proximal_inverse hlip hc μ] with x hdf hx + obtain ⟨y,hy,hdP,hdet⟩ := hx + let B := (fderiv ℝ (prox f L hlip) y).toContinuousLinearEquivOfDetNeZero hdet + have hB : HasFDerivAt (prox f L hlip) (B : E →L[ℝ] E) y := by + simpa only [B,ContinuousLinearMap.coe_toContinuousLinearEquivOfDetNeZero] using hdP.hasFDerivAt + let p := (InnerProductSpace.toDual ℝ E).symm (fderiv ℝ f x) + let A := (B.symm : E →L[ℝ] E) - ContinuousLinearMap.id ℝ E + have hdiff := uniform_subgradient_differential_of_regular_prox hlip hc + hdf.hasFDerivAt hy B hB + have hquad : HasQuadraticExpansion (fun h => f (x+h)) p A := + quadraticExpansion_of_subgradient_differential hlip hc hdiff + let S := (1/2 : ℝ) • (A + A.adjoint) + obtain ⟨hsym,hdiag⟩ := symmetrized_quadratic A + change ∀ h, inner ℝ (S h) h = inner ℝ (A h) h at hdiag + refine ⟨p,S,hsym,?_⟩ + intro eps heps + obtain ⟨d,hd,hbound⟩ := hquad eps heps + refine ⟨d,hd,?_⟩ + intro h hh + have hi := hbound h hh + simpa only [quadraticTaylor,hdiag h] using hi + +omit [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] in + +lemma quadraticExpansion_congr_nhds {f g : E → ℝ} {p : E} {A : E →L[ℝ] E} + (hfg : f =ᶠ[𝓝 (0:E)] g) (hf : HasQuadraticExpansion f p A) : + HasQuadraticExpansion g p A := by + obtain ⟨r,hr,hball⟩ := Metric.mem_nhds_iff.mp hfg + have hzero : f 0 = g 0 := hfg.self_of_nhds + intro eps heps + obtain ⟨d,hd,hbound⟩ := hf eps heps + refine ⟨min d r,by positivity,?_⟩ + intro h hh + have hhg : f h = g h := hball (by + simpa only [Metric.mem_ball,dist_zero_right] using lt_of_lt_of_le hh (min_le_right _ _)) + have hb := hbound h (lt_of_lt_of_le hh (min_le_left _ _)) + simpa only [quadraticTaylor,hzero,hhg] using hb + +lemma ae_quadraticExpansion_convex_open {f : E → ℝ} {s : Set E} + (hs : IsOpen s) (hc : ConvexOn ℝ s f) (μ : Measure E) [μ.IsAddHaarMeasure] : + ∀ᵐ x ∂μ, x ∈ s → ∃ p : E, ∃ A : E →L[ℝ] E, + (∀ h k, inner ℝ (A h) k = inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => f (x+h)) p A := by + apply ae_of_locally_ae μ + intro x hx + obtain ⟨L,t,ht,hlip⟩ := hc.locallyLipschitzOn hs hx + rw [nhdsWithin_eq_nhds.mpr (hs.mem_nhds hx)] at ht + obtain ⟨r,hr,hrt⟩ := Metric.mem_nhds_iff.mp (inter_mem ht (hs.mem_nhds hx)) + have hrt' : Metric.ball x r ⊆ t := fun _ hy => (hrt hy).1 + have hrs : Metric.ball x r ⊆ s := fun _ hy => (hrt hy).2 + obtain ⟨g,hgL,hgC,hfg⟩ := convex_lipschitz_extension + (hc.subset hrs (convex_ball _ _)) (hlip.mono hrt') + (Metric.nonempty_ball.mpr hr) + refine ⟨Metric.ball x r,Metric.isOpen_ball,Metric.mem_ball_self hr,?_⟩ + filter_upwards [ae_quadraticExpansion_lipschitz_convex hgL hgC μ] with z hz hzb + obtain ⟨p,A,hA,hquad⟩ := hz + refine ⟨p,A,hA,quadraticExpansion_congr_nhds ?_ hquad⟩ + have hcont : Tendsto (fun h : E => z+h) (𝓝 0) (𝓝 z) := by + have hc : Continuous (fun h : E => z+h) := continuous_const.add continuous_id + simpa only [add_zero] using hc.tendsto (0:E) + filter_upwards [hcont (Metric.isOpen_ball.mem_nhds hzb)] with h hh + exact (hfg hh).symm + +omit [FiniteDimensional ℝ E] [MeasurableSpace E] [BorelSpace E] in + +lemma quadraticExpansion_sub_quadratic {f : E → ℝ} {x p : E} {A : E →L[ℝ] E} + (K : ℝ) + (hg : HasQuadraticExpansion (fun h => f (x+h)+K/2*‖x+h‖^2) p A) : + HasQuadraticExpansion (fun h => f (x+h)) (p-K • x) + (A-K • ContinuousLinearMap.id ℝ E) := by + intro eps heps + obtain ⟨d,hd,hbound⟩ := hg eps heps + refine ⟨d,hd,?_⟩ + intro h hh + have heq : (f (x+h)+K/2*‖x+h‖^2) - + quadraticTaylor (f (x+0)+K/2*‖x+0‖^2) p A h = + f (x+h)-quadraticTaylor (f (x+0)) (p-K • x) + (A-K • ContinuousLinearMap.id ℝ E) h := by + simp only [quadraticTaylor,add_zero,norm_sq_add_real,inner_sub_left, + real_inner_smul_left,sub_apply,smul_apply,ContinuousLinearMap.id_apply, + real_inner_self_eq_norm_sq] + ring + have hb := hbound h hh + rwa [heq] at hb + +lemma ae_quadraticExpansion_semiconvex_open {f : E → ℝ} {s : Set E} (K : ℝ) + (hs : IsOpen s) (hc : ConvexOn ℝ s (fun z => f z+K/2*‖z‖^2)) + (μ : Measure E) [μ.IsAddHaarMeasure] : + ∀ᵐ x ∂μ, x ∈ s → ∃ p : E, ∃ A : E →L[ℝ] E, + (∀ h k, inner ℝ (A h) k = inner ℝ h (A k)) ∧ + HasQuadraticExpansion (fun h => f (x+h)) p A := by + filter_upwards [ae_quadraticExpansion_convex_open hs hc μ] with x hx hxs + obtain ⟨p,A,hA,hquad⟩ := hx hxs + refine ⟨p-K • x,A-K • ContinuousLinearMap.id ℝ E,?_, + quadraticExpansion_sub_quadratic K hquad⟩ + intro h k + simp only [sub_apply,smul_apply,ContinuousLinearMap.id_apply,inner_sub_left, + inner_sub_right,real_inner_smul_left,real_inner_smul_right,hA h k] +end Measurable + +end ConvexProximal +end WeakMTWTransport + +end +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/MeasurableFullSubset.lean b/lean/OAI/Analysis/BiholderTransport/Volume/MeasurableFullSubset.lean new file mode 100644 index 0000000000000000000000000000000000000000..58ea72137ddf2f47a88c501ff2bad397b506212b --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/MeasurableFullSubset.lean @@ -0,0 +1,29 @@ +import Mathlib + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Metric Manifold Bundle +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport + +lemma exists_measurable_full_subset {X : Type*} [MeasurableSpace X] {μ : Measure X} + {P : X → Prop} (h : ∀ᵐ x ∂μ, P x) : + ∃ G : Set X, MeasurableSet G ∧ (∀ᵐ x ∂μ, x∈G) ∧ ∀ x∈G, P x := by + have hn : μ {x | ¬P x}=0 := ae_iff.mp h + obtain ⟨G,hG,hGm,hGe⟩ := (NullMeasurableSet.of_null hn).compl.exists_measurable_subset_ae_eq + refine ⟨G,hGm,?_,?_⟩ + · filter_upwards [hGe,h] with x hx hp + exact hx.mpr (fun hn => hn hp) + · intro x hx + exact not_not.mp (hG hx) + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/MeasureContacts.lean b/lean/OAI/Analysis/BiholderTransport/Volume/MeasureContacts.lean new file mode 100644 index 0000000000000000000000000000000000000000..1ed7d07b688828bded52c6ce454bebc3732d7f18 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/MeasureContacts.lean @@ -0,0 +1,90 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Duality.CompactDual +import OAI.Analysis.BiholderTransport.Volume.DensityBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter MeasureTheory Manifold Bundle +open scoped ENNReal NNReal ContDiff Topology BoundedContinuousFunction + +namespace WeakMTWTransport + +section MeasureContacts +variable {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + +def contactImage (u v : M → ℝ) (A : Set M) : Set M := + {y | ∃ x ∈ A, contactGap u v x y = 0} + +omit [CompactSpace M] [Nonempty M] [BorelSpace M] in + +lemma dual_minimum_swap {μ ν : Measure M} {u v : M →ᵇ ℝ} + (hmin : ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective μ ν (u,v) ≤ dualObjective μ ν (a,b)) : + ∀ a b : M →ᵇ ℝ, (∀ x y, 0 ≤ contactGap a b x y) → + dualObjective ν μ (v,u) ≤ dualObjective ν μ (a,b) := by + intro a b hab + have hh := hmin b a (fun x y => by rw [contactGap_symm]; exact hab y x) + simpa only [dualObjective,add_comm] using hh + +omit [CompactSpace M] [Nonempty M] [BorelSpace M] in + +lemma contactImage_ae_eq_preimage {μ : Measure M} {u v : M → ℝ} {S : M → M} + (hcontact : ∀ y, contactGap u v (S y) y = 0) + (hsingle : ∀ᵐ y ∂μ, ∀ x, contactGap u v x y = 0 → x = S y) + (A : Set M) : contactImage u v A =ᵐ[μ] S ⁻¹' A := by + filter_upwards [hsingle] with y hy + apply propext + change (∃ x ∈ A, contactGap u v x y = 0) ↔ S y ∈ A + constructor + · rintro ⟨x,hx,hxy⟩ + simpa only [hy x hxy] using hx + · intro hx + exact ⟨S y,hx,hcontact y⟩ + +omit [CompactSpace M] [Nonempty M] [BorelSpace M] in + +lemma contactImage_measure {μ ν : Measure M} {u v : M → ℝ} {S : M → M} + (hcontact : ∀ y, contactGap u v (S y) y = 0) + (hsingle : ∀ᵐ y ∂ν, ∀ x, contactGap u v x y = 0 → x = S y) + (hS : AEMeasurable S ν) (hpush : Measure.map S ν = μ) + {A : Set M} (hA : MeasurableSet A) : + NullMeasurableSet (contactImage u v A) ν ∧ ν (contactImage u v A) = μ A := by + have he := contactImage_ae_eq_preimage hcontact hsingle A + refine ⟨?_,?_⟩ + · exact (hS.nullMeasurableSet_preimage hA).congr he.symm + · rw [measure_congr he,← Measure.map_apply_of_aemeasurable hS hA,hpush] + +omit [CompactSpace M] [Nonempty M] [BorelSpace M] in + +lemma contactImage_volume_comparison {vol : Measure M} {lam cap : ℝ} + {rho0 rho1 u v : M → ℝ} + (hrho0 : AdmissibleDensity vol lam cap rho0) + (hrho1 : AdmissibleDensity vol lam cap rho1) + {A : Set M} (hmass : densityMeasure vol rho1 (contactImage u v A) = + densityMeasure vol rho0 A) : + ENNReal.ofReal lam * vol A ≤ ENNReal.ofReal cap * vol (contactImage u v A) ∧ + ENNReal.ofReal lam * vol (contactImage u v A) ≤ ENNReal.ofReal cap * vol A := by + have h0 := densityMeasure_bounds hrho0 + have h1 := densityMeasure_bounds hrho1 + constructor + · calc + _ ≤ densityMeasure vol rho0 A := h0.1 A + _ = densityMeasure vol rho1 (contactImage u v A) := hmass.symm + _ ≤ _ := h1.2 (contactImage u v A) + · calc + _ ≤ densityMeasure vol rho1 (contactImage u v A) := h1.1 (contactImage u v A) + _ = densityMeasure vol rho0 A := hmass + _ ≤ _ := h0.2 A + +end MeasureContacts + +end WeakMTWTransport +end +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/OriginalNullSet.lean b/lean/OAI/Analysis/BiholderTransport/Volume/OriginalNullSet.lean new file mode 100644 index 0000000000000000000000000000000000000000..1ff28ac7cc9a35c8aa2f8d94b4c89ed3bd4790b1 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/OriginalNullSet.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.ChartLipschitz +import OAI.Analysis.BiholderTransport.Volume.EuclideanVolumeFactorNe +import OAI.Analysis.BiholderTransport.Coordinates.ChartAlexandrov + +namespace OAI + +section + +noncomputable section +open Set Filter Metric Manifold Bundle MeasureTheory +open scoped Topology ContDiff ENNReal + +namespace WeakMTWTransport +section OriginalNullSet +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [Nonempty M] + [MeasurableSpace M] [BorelSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +omit [Nonempty M] in +lemma original_ae_chart_null {P:M → Prop} (hP:∀ᵐ x ∂metricVolume n,P x) (a:M) : + ∃r>0,∃N:Set (Model n),volume N=0 ∧ + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀z∈ball (extChartAt 𝓘(ℝ,Model n) a a) r,z∉N → + P ((extChartAt 𝓘(ℝ,Model n) a).symm z) := by + let χ:=extChartAt 𝓘(ℝ,Model n) a + obtain ⟨C,R,hR,hS,hC⟩:=exists_lipschitzOn_chart (n:=n) a + have ht:χ a∈χ.target:=mem_extChartAt_target (I:=𝓘(ℝ,Model n)) a + have hi:ContinuousAt χ.symm (χ a):=continuousAt_extChartAt_symm'' ht + have he:χ.symm (χ a)=a:=χ.left_inv (mem_extChartAt_source a) + obtain ⟨r,hr,hsub⟩:=Metric.mem_nhds_iff.mp (inter_mem + ((isOpen_extChartAt_target a).mem_nhds ht) + (hi.preimage_mem_nhds (he.symm ▸ ball_mem_nhds a hR))) + let B:Set M:=ball a R ∩ {x | ¬P x} + let N:Set (Model n):=χ '' B + have hB:metricVolume n B=0:=measure_mono_null inter_subset_right (ae_iff.mp hP) + have hN:volume N=0:=by + apply (Measure.absolutelyContinuous_isAddHaarMeasure volume (metricVolume (M:=Model n) n)) + apply le_antisymm _ zero_le + have H:=lipschitzOn_metricVolume_image_le (hC.mono (show B⊆ball a R from inter_subset_left)) n + rw [hB,mul_zero] at H + exact H + refine ⟨r,hr,N,hN,fun z hz=>(hsub hz).1,?_⟩ + intro z hz hn + by_contra hp + apply hn + exact ⟨χ.symm z,⟨by + have hb:= (hsub hz).2 + change dist (χ.symm z) (χ.symm (χ a)) < R at hb + rw [he] at hb + exact hb,hp⟩,χ.right_inv (hsub hz).1⟩ + +omit [Nonempty M] in +lemma original_chart_good_null {P:M → Prop} (hP:∀ᵐ x ∂metricVolume n,P x) + {u v:M → ℝ} (hu:Continuous u) (hdual:IsCostDualPair u v) (a:M) : + ∃r>0,∃N:Set (Model n),volume N=0 ∧ + ball (extChartAt 𝓘(ℝ,Model n) a a) r ⊆ (extChartAt 𝓘(ℝ,Model n) a).target ∧ + ∀z∈ball (extChartAt 𝓘(ℝ,Model n) a a) r,z∉N → + P ((extChartAt 𝓘(ℝ,Model n) a).symm z) ∧ + ∃p:Model n,∃A:Model n →L[ℝ] Model n, + (∀d e,inner ℝ (A d) e=inner ℝ d (A e)) ∧ + HasQuadraticExpansion (fun h=>v ((extChartAt 𝓘(ℝ,Model n) a).symm (z+h))) p A := by + obtain ⟨r,hr,N,hN,ht,hg⟩:=original_ae_chart_null (n:=n) hP a + obtain ⟨s,hs,Q,hQ,hst,hq⟩:=original_chart_alexandrov_null (n:=n) hu hdual a + refine ⟨min r s,lt_min hr hs,N∪Q,measure_union_null hN hQ,?_,?_⟩ + · exact (ball_subset_ball (min_le_left _ _)).trans ht + · intro z hz hn + have hNr:z∉N:=fun hm=>hn (Or.inl hm) + have hQr:z∉Q:=fun hm=>hn (Or.inr hm) + exact ⟨hg z (ball_subset_ball (min_le_left _ _) hz) hNr, + hq z (ball_subset_ball (min_le_right _ _) hz) hQr⟩ +end OriginalNullSet +end WeakMTWTransport + +end +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/OutwardSpectrum.lean b/lean/OAI/Analysis/BiholderTransport/Volume/OutwardSpectrum.lean new file mode 100644 index 0000000000000000000000000000000000000000..242cecc7a9223bce1d85b986a36561dd1e3f16e7 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/OutwardSpectrum.lean @@ -0,0 +1,59 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.DoubleMountain +import OAI.Analysis.BiholderTransport.Volume.SpectralDeterminants +import OAI.Analysis.BiholderTransport.Convexity.ConvexBarycentricSegment +import OAI.Analysis.BiholderTransport.Coordinates.FiberNormal + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section OutwardSpectrum +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] [ConnectedSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance outwardSpectrumFiniteDimensionalTangentSpace (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma WeakMTW.uniform_outward_expJacobian_comparison + (hmtw : WeakMTW (n := n) (M := M)) {μ κ L : ℝ} + (hμ : 0<μ) (hκ : 0<κ) (hL : 0 τ * Real.sqrt (g (ζ s) (ζ s) + ε)) + (τ * g (ζ t) ζ' / Real.sqrt (g (ζ t) (ζ t) + ε)) t := by + have h := (((g.hasFDerivAt.comp_hasDerivAt t hζ).clm_apply hζ).add_const ε + |>.sqrt (ne_of_gt hpos)).const_mul τ + convert h using 1 <;> try rfl + simp only [Function.comp_apply,hsym ζ' (ζ t)] + ring + +lemma radial_calibration_length_lower_bound + (g : E →L[ℝ] E →L[ℝ] ℝ) (hg : ∀ v : E, 0 ≤ g v v) + (hsym : ∀ u v, g u v = g v u) {ζ : ℝ → E} {a b τ : ℝ} + (hab : a ≤ b) (hτ : 0 ≤ τ) (hζ : ContDiffOn ℝ 1 ζ (Icc a b)) (hζa : ζ a = 0) + (B : ℝ → ℝ) (hB : ∀ t ∈ Ioo a b, 0 ≤ B t) + (hbound : ∀ t ∈ Ioo a b, + |τ * g (ζ t) (deriv ζ t)| ≤ Real.sqrt (g (ζ t) (ζ t)) * B t) : + ENNReal.ofReal (τ * Real.sqrt (g (ζ b) (ζ b))) ≤ + ∫⁻ t in Icc a b, ENNReal.ofReal (B t) := by + by_cases heq : a = b + · subst b + simp only [hζa,map_zero,Real.sqrt_zero,mul_zero,ENNReal.ofReal_zero,zero_le] + have hεbound : ∀ ε : ℝ, 0 < ε → + ‖τ * Real.sqrt (g (ζ b) (ζ b)+ε) - τ * Real.sqrt ε‖ₑ ≤ + ∫⁻ t in Icc a b, ENNReal.ofReal (B t) := by + intro ε hε + let F : ℝ → ℝ := fun t => τ * Real.sqrt (g (ζ t) (ζ t)+ε) + have hF : ContDiffOn ℝ 1 F (Icc a b) := + contDiffOn_const.mul (((g.contDiff.comp_contDiffOn hζ).clm_apply hζ).add + contDiffOn_const |>.sqrt (fun t _ => ne_of_gt (by change 0 < g (ζ t) (ζ t) + ε; linarith [hg (ζ t)]))) + have hlen := enorm_sub_le_lintegral_derivWithin_Icc_of_contDiffOn_Icc hF hab + have hFa : F a = τ * Real.sqrt ε := by simp only [F,hζa,map_zero,zero_add] + rw [hFa] at hlen + apply hlen.trans + rw [←restrict_Ioo_eq_restrict_Icc] + apply setLIntegral_mono' measurableSet_Ioo + intro t ht + have hζt : HasDerivAt ζ (deriv ζ t) t := + ((hζ.contDiffAt (Icc_mem_nhds ht.1 ht.2)).differentiableAt one_ne_zero).hasDerivAt + have hFt := hasDerivAt_regularized_metric_radius g hsym hζt + (τ := τ) (ε := ε) (by linarith [hg (ζ t)]) + rw [derivWithin_of_mem_nhds (Icc_mem_nhds ht.1 ht.2),hFt.deriv, + Real.enorm_eq_ofReal_abs] + apply ENNReal.ofReal_le_ofReal + have hs : 0 < Real.sqrt (g (ζ t) (ζ t)+ε) := Real.sqrt_pos.2 (by linarith [hg (ζ t)]) + rw [abs_div,abs_of_pos hs,div_le_iff₀ hs] + refine (hbound t ht).trans ?_ + rw [mul_comm (B t)] + exact mul_le_mul_of_nonneg_right (Real.sqrt_le_sqrt (by linarith)) (hB t ht) + have hc : Continuous (fun ε : ℝ => + ‖τ * Real.sqrt (g (ζ b) (ζ b)+ε) - τ * Real.sqrt ε‖ₑ) := by fun_prop + have hlim : Tendsto (fun ε : ℝ => + ‖τ * Real.sqrt (g (ζ b) (ζ b)+ε) - τ * Real.sqrt ε‖ₑ) (𝓝[>] 0) + (𝓝 (‖τ * Real.sqrt (g (ζ b) (ζ b)+(0:ℝ)) - τ * Real.sqrt (0:ℝ)‖ₑ)) := + hc.continuousAt.tendsto.mono_left nhdsWithin_le_nhds + have hfinal := le_of_tendsto hlim (show ∀ᶠ ε : ℝ in 𝓝[>] 0, + ‖τ * Real.sqrt (g (ζ b) (ζ b)+ε) - τ * Real.sqrt ε‖ₑ ≤ + ∫⁻ t in Icc a b, ENNReal.ofReal (B t) from by + filter_upwards [self_mem_nhdsWithin] with ε hε + exact hεbound ε hε) + simpa only [add_zero,Real.sqrt_zero,mul_zero,sub_zero, + Real.enorm_of_nonneg (mul_nonneg hτ (Real.sqrt_nonneg _))] using hfinal + +lemma fderiv_partial_homeomorph_right_inverse + (e : OpenPartialHomeomorph E E) {y : E} (hy : y ∈ e.target) + (he : DifferentiableAt ℝ e (e.symm y)) (hi : DifferentiableAt ℝ e.symm y) : + (fderiv ℝ e (e.symm y)).comp (fderiv ℝ e.symm y) = ContinuousLinearMap.id ℝ E := by + have h := he.hasFDerivAt.comp y hi.hasFDerivAt + exact h.unique ((hasFDerivAt_id y).congr_of_eventuallyEq (e.eventually_right_inverse hy)) + +lemma normal_chart_gauss_dual_bound + (e : OpenPartialHomeomorph E E) {y : E} (hy : y ∈ e.target) + (he : DifferentiableAt ℝ e (e.symm y)) (hi : DifferentiableAt ℝ e.symm y) + (g₀ g₁ : E →L[ℝ] E →L[ℝ] ℝ) + (hg₁ : ∀ v, v ≠ 0 → 0 < g₁ v v) (hsym : ∀ u v, g₁ u v = g₁ v u) + (V : E) {τ : ℝ} + (henergy : g₁ V V = g₀ (e.symm y) (e.symm y)) + (hgauss : ∀ w, g₁ V ((fderiv ℝ e (e.symm y)) w) = τ * g₀ (e.symm y) w) + (u : E) : + |τ * g₀ (e.symm y) ((fderiv ℝ e.symm y) u)| ≤ + Real.sqrt (g₀ (e.symm y) (e.symm y)) * Real.sqrt (g₁ u u) := by + have hd := congrArg (fun L : E →L[ℝ] E => L u) + (fderiv_partial_homeomorph_right_inverse e hy he hi) + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.id_apply] at hd + have hG := hgauss ((fderiv ℝ e.symm y) u) + rw [hd] at hG + rw [←hG,←henergy] + exact positive_bilinear_abs_le g₁ hg₁ hsym V u + +lemma normal_chart_radial_path_bound + (e : OpenPartialHomeomorph E E) (he : ContDiffOn ℝ 1 e e.source) + (hi : ContDiffOn ℝ 1 e.symm e.target) (h0 : (0:E) ∈ e.source) + (g₀ : E →L[ℝ] E →L[ℝ] ℝ) (hg₀ : ∀ v, 0 ≤ g₀ v v) + (hsym₀ : ∀ u v, g₀ u v = g₀ v u) + (g : E → E →L[ℝ] E →L[ℝ] ℝ) + (hg : ∀ y ∈ e.target, ∀ v, v ≠ 0 → 0 < g y v v) + (hsym : ∀ y ∈ e.target, ∀ u v, g y u v = g y v u) + (V : E → E) {τ : ℝ} (hτ : 0 ≤ τ) + (henergy : ∀ y ∈ e.target, g y (V y) (V y) = g₀ (e.symm y) (e.symm y)) + (hgauss : ∀ y ∈ e.target, ∀ w, + g y (V y) ((fderiv ℝ e (e.symm y)) w) = τ * g₀ (e.symm y) w) + {γ : ℝ → E} {a b : ℝ} (hab : a ≤ b) + (hγ : ContDiffOn ℝ 1 γ (Icc a b)) (himg : MapsTo γ (Icc a b) e.target) + (ha : γ a = e 0) : + ENNReal.ofReal (τ * Real.sqrt (g₀ (e.symm (γ b)) (e.symm (γ b)))) ≤ + ∫⁻ t in Icc a b, ENNReal.ofReal (Real.sqrt (g (γ t) (deriv γ t) (deriv γ t))) := by + let ζ : ℝ → E := e.symm ∘ γ + have hζ : ContDiffOn ℝ 1 ζ (Icc a b) := hi.comp hγ himg + have hζa : ζ a = 0 := by simp only [ζ,Function.comp_apply,ha,e.left_inv h0] + apply radial_calibration_length_lower_bound g₀ hg₀ hsym₀ hab hτ hζ hζa _ + (fun _ _ => Real.sqrt_nonneg _) ?_ + intro t ht + have hmem := himg (Ioo_subset_Icc_self ht) + have hγd := (hγ.contDiffAt (Icc_mem_nhds ht.1 ht.2)).differentiableAt one_ne_zero + have hid := (hi.contDiffAt (e.open_target.mem_nhds hmem)).differentiableAt one_ne_zero + have hed := (he.contDiffAt (e.open_source.mem_nhds (e.map_target hmem))).differentiableAt one_ne_zero + have hζd := hid.hasFDerivAt.comp_hasDerivAt t hγd.hasDerivAt + change |τ * g₀ (e.symm (γ t)) (deriv ζ t)| ≤ _ + rw [hζd.deriv] + exact normal_chart_gauss_dual_bound e hmem hed hid g₀ (g (γ t)) + (hg _ hmem) (hsym _ hmem) (V (γ t)) (henergy _ hmem) (hgauss _ hmem) _ + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/RadialNull.lean b/lean/OAI/Analysis/BiholderTransport/Volume/RadialNull.lean new file mode 100644 index 0000000000000000000000000000000000000000..4fcf018c7e1a35c03bb7f1b47bea1c39f8389d55 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/RadialNull.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Regularity.MetricDefinitions + +namespace OAI + +noncomputable section +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +namespace WeakMTWTransport +open Matrix +open scoped MatrixOrder + +lemma convex_linear_bound {f : ℝ → ℝ} {l C : ℝ} (hl : 0 < l) + (hf : ConvexOn ℝ (Icc 0 l) f) (hzero : f 0 = 0) (hend : f l ≤ C * l) + {t : ℝ} (ht : t ∈ Icc 0 l) : f t ≤ C * t := by + have htl : 0 ≤ t / l := div_nonneg ht.1 hl.le + have htl1 : t / l ≤ 1 := (div_le_one hl).mpr ht.2 + have hh := hf.2 (show (0 : ℝ) ∈ Icc 0 l from ⟨le_rfl, hl.le⟩) + (show l ∈ Icc 0 l from ⟨hl.le, le_rfl⟩) + (show 0 ≤ 1 - t / l from sub_nonneg.mpr htl1) htl (by ring) + simp only [smul_eq_mul, mul_zero, zero_add, hzero] at hh + have hcancel : t / l * l = t := div_mul_cancel₀ t hl.ne' + rw [hcancel] at hh + have hmul := mul_le_mul_of_nonneg_left hend htl + apply hh.trans + calc + t / l * f l ≤ t / l * (C * l) := hmul + _ = C * (t / l * l) := by ring + _ = C * t := by rw [hcancel] +section TransportCertificates +variable {M : Type*} [MetricSpace M] [MeasurableSpace M] [BorelSpace M] + +omit [MetricSpace M] [BorelSpace M] in +lemma density_nonnegative {vol : Measure M} {lam cap : ℝ} {rho : M → ℝ} + (hlam : 0 < lam) (hrho : AdmissibleDensity vol lam cap rho) : + ∀ᵐ x ∂vol, 0 ≤ rho x := by + filter_upwards [hrho.2.2.2] with x hx + exact hlam.le.trans hx.1 + +omit [MetricSpace M] [BorelSpace M] in +lemma densityMeasure_probability {vol : Measure M} {lam cap : ℝ} {rho : M → ℝ} + (hlam : 0 < lam) (hrho : AdmissibleDensity vol lam cap rho) : + IsProbabilityMeasure (densityMeasure vol rho) := by + constructor + rw [densityMeasure, withDensity_apply _ MeasurableSet.univ, Measure.restrict_univ, + ← ofReal_integral_eq_lintegral_ofReal hrho.2.1 (density_nonnegative hlam hrho), + hrho.2.2.1, ENNReal.ofReal_one] + +omit [MetricSpace M] [BorelSpace M] in + +lemma integral_densityMeasure {vol : Measure M} {lam cap : ℝ} {rho : M → ℝ} + (hlam : 0 < lam) (hrho : AdmissibleDensity vol lam cap rho) (f : M → ℝ) : + (∫ x, f x ∂densityMeasure vol rho) = ∫ x, f x * rho x ∂vol := by + rw [densityMeasure, integral_withDensity_eq_integral_toReal_smul₀ + hrho.1.ennreal_ofReal (Filter.Eventually.of_forall (fun _ => ENNReal.ofReal_lt_top))] + apply integral_congr_ae + filter_upwards [density_nonnegative hlam hrho] with x hx + simp only [ENNReal.toReal_ofReal hx, smul_eq_mul, mul_comm] + +variable [CompactSpace M] + +lemma integrable_continuous_compact {mu : Measure M} [IsFiniteMeasure mu] + {f : M → ℝ} (hf : Continuous f) : Integrable f mu := by + obtain ⟨C, hC⟩ := isCompact_univ.exists_bound_of_continuousOn hf.continuousOn + exact Integrable.of_bound hf.aestronglyMeasurable C + (Filter.Eventually.of_forall (fun x => hC x (mem_univ x))) + +lemma integrable_cost_map {mu : Measure M} [IsFiniteMeasure mu] + {S : M → M} (hS : Measurable S) : Integrable (fun x => cost x (S x)) mu := by + have hcost : Continuous (fun z : M × M => cost z.1 z.2) := by + exact ((continuous_fst.dist continuous_snd).pow 2).div_const 2 + obtain ⟨C, hC⟩ := isCompact_univ.exists_bound_of_continuousOn hcost.continuousOn + exact Integrable.of_bound + ((hcost.stronglyMeasurable.comp_measurable (measurable_id.prodMk hS)).aestronglyMeasurable) C + (Filter.Eventually.of_forall (fun x => hC (x, S x) (mem_univ _))) + +lemma integrable_comp_transport {mu nu : Measure M} [IsFiniteMeasure nu] + {f : M → ℝ} {S : M → M} (hf : Continuous f) (hS : Measurable S) + (hpush : Measure.map S mu = nu) : Integrable (fun x => f (S x)) mu := by + have hh := integrable_continuous_compact (mu := nu) hf + rw [← hpush, integrable_map_measure hf.aestronglyMeasurable hS.aemeasurable] at hh + exact hh + +lemma integral_contactGap_transport {mu nu : Measure M} [IsFiniteMeasure mu] + [IsFiniteMeasure nu] {u v : M → ℝ} {S : M → M} + (hu : Continuous u) (hv : Continuous v) (hS : Measurable S) + (hpush : Measure.map S mu = nu) : + (∫ x, contactGap u v x (S x) ∂mu) = + (∫ x, u x ∂mu) + (∫ x, cost x (S x) ∂mu) + (∫ y, v y ∂nu) := by + have hiu := integrable_continuous_compact (mu := mu) hu + have hic := integrable_cost_map (mu := mu) hS + have hiv := integrable_comp_transport hv hS hpush + have hadd : (∫ x, contactGap u v x (S x) ∂mu) = + (∫ x, u x + cost x (S x) ∂mu) + ∫ x, v (S x) ∂mu := by + simpa only [contactGap, Pi.add_apply] using integral_add (hiu.add hic) hiv + rw [hadd, integral_add hiu hic] + congr 1 + rw [← hpush, integral_map_of_stronglyMeasurable hS hv.stronglyMeasurable] + +lemma isOptimalMap_of_dual_contact {vol : Measure M} {lam cap : ℝ} + {rho0 rho1 u v : M → ℝ} {T : M → M} + (hlam : 0 < lam) (hrho0 : AdmissibleDensity vol lam cap rho0) + (hrho1 : AdmissibleDensity vol lam cap rho1) + (hu : Continuous u) (hv : Continuous v) + (hgap : ∀ x y, 0 ≤ contactGap u v x y) + (hT : Measurable T) (hpush : Measure.map T (densityMeasure vol rho0) = densityMeasure vol rho1) + (hcontact : ∀ x, contactGap u v x (T x) = 0) : + IsOptimalMap vol rho0 rho1 T := by + let := densityMeasure_probability hlam hrho0 + let := densityMeasure_probability hlam hrho1 + refine ⟨hT, hpush, ?_⟩ + intro S hS hpushS + rw [← integral_densityMeasure hlam hrho0, ← integral_densityMeasure hlam hrho0] + have hzero : (∫ x, contactGap u v x (T x) ∂densityMeasure vol rho0) = 0 := by + simp only [hcontact, integral_zero] + have hnonneg : 0 ≤ ∫ x, contactGap u v x (S x) ∂densityMeasure vol rho0 := + integral_nonneg (fun x => hgap x (S x)) + rw [integral_contactGap_transport hu hv hT hpush] at hzero + rw [integral_contactGap_transport hu hv hS hpushS] at hnonneg + linarith + +lemma optimalMap_ae_eq_of_singleton_contacts {vol : Measure M} {lam cap : ℝ} + {rho0 rho1 u v : M → ℝ} {T S : M → M} + (hlam : 0 < lam) (hrho0 : AdmissibleDensity vol lam cap rho0) + (hrho1 : AdmissibleDensity vol lam cap rho1) + (hu : Continuous u) (hv : Continuous v) + (hgap : ∀ x y, 0 ≤ contactGap u v x y) + (hT : Measurable T) (hpush : Measure.map T (densityMeasure vol rho0) = densityMeasure vol rho1) + (hcontact : ∀ x, contactGap u v x (T x) = 0) + (hsingle : ∀ x y, contactGap u v x y = 0 → y = T x) + (hS : IsOptimalMap vol rho0 rho1 S) : + S =ᵐ[densityMeasure vol rho0] T := by + let := densityMeasure_probability hlam hrho0 + let := densityMeasure_probability hlam hrho1 + have hzero : (∫ x, contactGap u v x (T x) ∂densityMeasure vol rho0) = 0 := by + simp only [hcontact, integral_zero] + have hle := hS.2.2 T hT hpush + rw [← integral_densityMeasure hlam hrho0, ← integral_densityMeasure hlam hrho0] at hle + rw [integral_contactGap_transport hu hv hT hpush] at hzero + have hnonneg : ∀ᵐ x ∂densityMeasure vol rho0, 0 ≤ contactGap u v x (S x) := + Filter.Eventually.of_forall (fun x => hgap x (S x)) + have hgapint : Integrable (fun x => contactGap u v x (S x)) (densityMeasure vol rho0) := + ((integrable_continuous_compact hu).add (integrable_cost_map hS.1)).add + (integrable_comp_transport hv hS.1 hS.2.1) + have hgapzero : (∫ x, contactGap u v x (S x) ∂densityMeasure vol rho0) = 0 := by + have hnn := integral_nonneg_of_ae hnonneg + rw [integral_contactGap_transport hu hv hS.1 hS.2.1] at hnn ⊢ + linarith + have hae := (integral_eq_zero_iff_of_nonneg_ae hnonneg hgapint).mp hgapzero + filter_upwards [hae] with x hx + exact hsingle x (S x) hx + +end TransportCertificates + +open scoped BoundedContinuousFunction + +end WeakMTWTransport +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/ReversedRadial.lean b/lean/OAI/Analysis/BiholderTransport/Volume/ReversedRadial.lean new file mode 100644 index 0000000000000000000000000000000000000000..023f5032863a735edde1113b37eca23667493f75 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/ReversedRadial.lean @@ -0,0 +1,64 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Geodesics.ReverseSpectrum + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section ReversedRadial +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +lemma uniform_reversed_radial_expJacobian_comparison : + ∃ c C : ℝ, 0 < c ∧ 0 < C ∧ + (∀ z : TangentBundle 𝓘(ℝ,Model n) M, z.2∈minimizingVectors z.1 → + ∀ l∈Icc (1/2:ℝ) 1, + l⁻¹ • (reverseRay z).2∈minimizingVectors (reverseRay z).1 → + c*expJacobian (reverseRay z).1 (l⁻¹ • (reverseRay z).2) ≤ + C*expJacobian z.1 z.2) ∧ + (∀ z : TangentBundle 𝓘(ℝ,Model n) M, z.2∈minimizingVectors z.1 → + ∀ l∈Icc (1:ℝ) 2, + c*expJacobian z.1 z.2 ≤ + C*expJacobian (reverseRay z).1 (l⁻¹ • (reverseRay z).2)) := by + obtain ⟨c,hc,Hc⟩ := uniform_radial_expJacobian_comparison (n := n) (M := M) + obtain ⟨C,hC,HC⟩ := uniform_reverse_expJacobian_comparison (n := n) (M := M) + refine ⟨c,C,hc,hC,?_,?_⟩ + · intro z hz l hl hr + have hl0 : l≠0 := ne_of_gt (by linarith [hl.1]) + have H := Hc (reverseRay z).1 (l⁻¹ • (reverseRay z).2) hr l hl + rw [smul_smul,mul_inv_cancel₀ hl0,one_smul] at H + exact H.trans (HC z hz) + · intro z hz l hl + have hl1 : l⁻¹∈Icc (1/2:ℝ) 1 := by + constructor + · exact (le_inv_comm₀ (by norm_num) (by linarith [hl.1])).mpr (by simpa using hl.2) + · exact inv_le_one_of_one_le₀ hl.1 + have H := Hc (reverseRay z).1 (reverseRay z).2 (reverseRay_minimizing hz) l⁻¹ hl1 + have R := HC (reverseRay z) (reverseRay_minimizing hz) + rw [reverseRay_reverseRay] at R + calc c*expJacobian z.1 z.2 ≤ c*(C*expJacobian (reverseRay z).1 (reverseRay z).2) := + mul_le_mul_of_nonneg_left R hc.le + _ = C*(c*expJacobian (reverseRay z).1 (reverseRay z).2) := by ring + _ ≤ C*expJacobian (reverseRay z).1 (l⁻¹ • (reverseRay z).2) := + mul_le_mul_of_nonneg_left H hC.le +end ReversedRadial +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/RiemannianCalibration.lean b/lean/OAI/Analysis/BiholderTransport/Volume/RiemannianCalibration.lean new file mode 100644 index 0000000000000000000000000000000000000000..bd134d33920320035556b6fdb4a2e029e5803c91 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/RiemannianCalibration.lean @@ -0,0 +1,160 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.NormalCoordinates2 +import OAI.Analysis.BiholderTransport.Volume.RadialCalibration + +namespace OAI + +noncomputable section + +open Set MeasureTheory Manifold Bundle +open scoped ContDiff Manifold ENNReal NNReal Topology + +open Set Filter +open scoped Topology NNReal + +open Set Filter +open scoped Topology + +open Set Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology + +open Set +open scoped Topology + +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff Manifold Bundle + +open Set Filter ContinuousLinearMap InnerProductSpace +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff +open scoped NNReal + +open Set Filter ContinuousLinearMap +open scoped Topology ContDiff + +open Set Filter ContinuousLinearMap +open scoped Topology +open MeasureTheory +open scoped ContDiff ENNReal + +open Set Filter Manifold Bundle ContinuousLinearMap MeasureTheory +open scoped Topology ContDiff Manifold Bundle ENNReal + +open Set Filter Manifold MeasureTheory Bundle +open scoped ENNReal ContDiff Topology Manifold + +namespace WeakMTWTransport + +section +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + {H : Type*} [TopologicalSpace H] {I : ModelWithCorners ℝ E H} + {M : Type*} [MetricSpace M] [ChartedSpace H M] [IsManifold I 1 M] + [RiemannianBundle (fun x : M => TangentSpace I x)] + [IsRiemannianManifold I M] + +omit [IsManifold I 1 M] in +lemma short_riemannian_path_mapsTo_ball {x : M} {γ : ℝ → M} {δ : ℝ} + (hγ : ContMDiffOn 𝓘(ℝ,ℝ) I 1 γ (Icc 0 1)) (hγ0 : γ 0 = x) + (hlen : pathELength I γ 0 1 < ENNReal.ofReal δ) : + MapsTo γ (Icc 0 1) (Metric.ball x δ) := by + intro t ht + have hpre := riemannianEDist_le_pathELength (I := I) + (hγ.mono (Icc_subset_Icc le_rfl ht.2)) hγ0 rfl ht.1 + rw [←IsRiemannianManifold.out,edist_dist] at hpre + have hpm := pathELength_mono (I := I) (γ := γ) (a := 0) (a' := 0) (b := t) + (b' := 1) le_rfl ht.2 + have hd := (hpre.trans hpm).trans_lt hlen + rw [Metric.mem_ball,dist_comm] + exact (ENNReal.ofReal_lt_ofReal_iff (ENNReal.ofReal_pos.mp (zero_le.trans_lt hlen))).mp hd + +omit [IsManifold I 1 M] in +lemma riemannian_local_dist_lower_bound {S : Set M} {x y : M} {δ C : ℝ} + (hball : Metric.ball x δ ⊆ S) (hdist : dist x y < δ) + (hpath : ∀ γ : ℝ → M, ContMDiffOn 𝓘(ℝ,ℝ) I 1 γ (Icc 0 1) → + γ 0 = x → γ 1 = y → MapsTo γ (Icc 0 1) S → + ENNReal.ofReal C ≤ pathELength I γ 0 1) : + C ≤ dist x y := by + by_contra hn + have hlt : dist x y < min C δ := lt_min (lt_of_not_ge hn) hdist + have hriem : riemannianEDist I x y < ENNReal.ofReal (min C δ) := by + rw [←IsRiemannianManifold.out,edist_dist] + exact (ENNReal.ofReal_lt_ofReal_iff (dist_nonneg.trans_lt hlt)).mpr hlt + obtain ⟨γ,hγ0,hγ1,hγ,hlen⟩ := exists_lt_of_riemannianEDist_lt hriem + have hlenδ := hlen.trans_le (ENNReal.ofReal_le_ofReal (min_le_right C δ)) + have himg := (short_riemannian_path_mapsTo_ball hγ hγ0 hlenδ).mono_right hball + have hh := hpath γ hγ hγ0 hγ1 himg + exact (not_lt_of_ge hh) (hlen.trans_le (ENNReal.ofReal_le_ofReal (min_le_left C δ))) + +end + +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + [FiniteDimensional ℝ E] + +lemma coordinate_normal_chart_radial_bound + {g : E → E →L[ℝ] E →L[ℝ] ℝ} {S : Set E} (hS : IsOpen S) + (hg : ContDiffOn ℝ ∞ g S) (hpos : ∀ x ∈ S, ∀ v : E, v ≠ 0 → 0 < g x v v) + (hsym : ∀ x ∈ S, ∀ u v, g x u v = g x v u) + {Ψ W : ℝ × E → E} {r : ℝ} + (hΨ : ContDiffOn ℝ ∞ Ψ (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (hW : ContDiffOn ℝ ∞ W (Ioo (-r) r ×ˢ Metric.ball 0 r)) + (himg : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, Ψ (t,v) ∈ S) + (hode : ∀ t ∈ Ioo (-r) r, ∀ v ∈ Metric.ball 0 r, + HasDerivAt (fun q => Ψ (q,v)) (W (t,v)) t ∧ + HasDerivAt (fun q => W (q,v)) + (-coordinateChristoffel g (Ψ (t,v)) (W (t,v)) (W (t,v))) t) + {x : E} (h0 : 0 ∈ Ioo (-r) r) + (hΨ0 : ∀ v ∈ Metric.ball 0 r, Ψ (0,v) = x) + (hW0 : ∀ v ∈ Metric.ball 0 r, W (0,v) = v) + {τ : ℝ} (hτ : τ ∈ Ioo (-r) r) (hτnonneg : 0 ≤ τ) + (e : OpenPartialHomeomorph E E) (hef : (e : E → E) = fun v => Ψ (τ,v)) + (hes : 0 ∈ e.source) (hesub : e.source ⊆ Metric.ball 0 r) + (hed : ContDiffOn ℝ ∞ e e.source) (hei : ContDiffOn ℝ ∞ e.symm e.target) + {γ : ℝ → E} {a b : ℝ} (hab : a ≤ b) + (hγ : ContDiffOn ℝ 1 γ (Icc a b)) (hγimg : MapsTo γ (Icc a b) e.target) + (hγa : γ a = e 0) : + ENNReal.ofReal (τ * Real.sqrt (g x (e.symm (γ b)) (e.symm (γ b)))) ≤ + ∫⁻ t in Icc a b, ENNReal.ofReal (Real.sqrt (g (γ t) (deriv γ t) (deriv γ t))) := by + have hef_apply : ∀ v, Ψ (τ,v) = e v := fun v => congrFun hef.symm v + have hi : ∀ y ∈ S, (g y).IsInvertible := fun y hy => metricDual_isInvertible (g y) (hpos y hy) + have hx : x ∈ S := by + rw [←hΨ0 0 (hesub hes)] + exact himg 0 h0 0 (hesub hes) + have het : ∀ y ∈ e.target, y ∈ S := by + intro y hy + have hyv := hesub (e.map_target hy) + have hh := himg τ hτ (e.symm y) hyv + rw [hef_apply,e.right_inv hy] at hh + exact hh + apply normal_chart_radial_path_bound e (hed.of_le (by simp)) (hei.of_le (by simp)) hes + (g x) (positive_bilinear_nonneg _ (hpos x hx)) (hsym x hx) g + (fun y hy => hpos y (het y hy)) (fun y hy => hsym y (het y hy)) + (fun y => W (τ,e.symm y)) hτnonneg ?_ ?_ hab hγ hγimg hγa + · intro y hy + have hv := hesub (e.map_target hy) + have heq : Ψ (τ,e.symm y) = y := by rw [hef_apply,e.right_inv hy] + have hc := coordinate_geodesic_speed_constant + (fun t ht => (hg.contDiffAt (hS.mem_nhds (himg t ht (e.symm y) hv))).differentiableAt (by simp)) + (fun t ht => hi _ (himg t ht _ hv)) + (fun t ht => hsym _ (himg t ht _ hv)) + (fun t ht => hode t ht _ hv) hτ h0 + simpa only [heq,hΨ0 _ hv,hW0 _ hv] using hc + · intro y hy w + have hv := hesub (e.map_target hy) + have hh := coordinate_endpoint_gauss hS hg hi hsym hΨ hW himg hode + h0 hΨ0 hW0 hτ hv w + rw [hef_apply,e.right_inv hy,←hef] at hh + exact hh + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/SpectralDeterminants.lean b/lean/OAI/Analysis/BiholderTransport/Volume/SpectralDeterminants.lean new file mode 100644 index 0000000000000000000000000000000000000000..6bd7902f2a38471ade886f9e20255c1107f1f93c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/SpectralDeterminants.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.LinearAlgebra.EndpointSpectrumBound + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle ContinuousLinearMap +open scoped Topology ContDiff + +namespace WeakMTWTransport +section SpectralDeterminants +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance (x : M) : FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma expJacobian_eq_prod_singularValues (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + expJacobian x p = ∏ i : Fin (Module.finrank ℝ (Model n)), + (endpointExpDifferential x p).toLinearMap.singularValues i := by + change (endpointExpDifferential x p).toLinearMap.normDet=_ + rw [LinearMap.normDet_eq_prod_singularValues,Fin.prod_univ_eq_prod_range] + rfl + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma expJacobian_comparison_of_singularValues {x : M} + {p q : TangentSpace 𝓘(ℝ,Model n) x} {c : ℝ} (hc : 0 ≤ c) + (h : ∀ i : Fin (Module.finrank ℝ (Model n)), + c*(endpointExpDifferential x p).toLinearMap.singularValues i ≤ + (endpointExpDifferential x q).toLinearMap.singularValues i) : + c^Module.finrank ℝ (Model n)*expJacobian x p ≤ expJacobian x q := by + rw [expJacobian_eq_prod_singularValues,expJacobian_eq_prod_singularValues] + have HH := Finset.prod_le_prod₀ (s := (Finset.univ : Finset (Fin (Module.finrank ℝ (Model n))))) + (fun i _ => mul_nonneg hc ((endpointExpDifferential x p).toLinearMap.singularValues_nonneg i)) + (fun i _ => h i) + simpa only [Finset.prod_mul_distrib,Finset.prod_const,Finset.card_univ,Fintype.card_fin] using HH + +lemma uniform_radial_expJacobian_comparison : + ∃ c : ℝ, 0 linarith [ht.1,ht.2]) i).1 + rw [show (1:ℝ)-(1-θ)=θ by ring] at HH + have hm := mul_nonneg ha.le (show 0 ≤ 1-θ by linarith [ht.2]) + nlinarith only [HH,hm] + +lemma WeakMTW.uniform_extended_expJacobian_comparison + (hmtw : WeakMTW (n := n) (M := M)) {a B : ℝ} (ha : 0 + expJacobian_comparison_of_singularValues hc.le (H x p q hpq hB hline)⟩ +end SpectralDeterminants +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/UniformCharts.lean b/lean/OAI/Analysis/BiholderTransport/Volume/UniformCharts.lean new file mode 100644 index 0000000000000000000000000000000000000000..0b1e6d6e38882c62e768f4a04217c6b232ee806c --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/UniformCharts.lean @@ -0,0 +1,128 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.Charts +import OAI.Analysis.BiholderTransport.Volume.ChartJacobianBounds + +namespace OAI + +section +section +noncomputable section +open Set Filter Manifold Bundle Module Metric +open scoped Topology ContDiff BigOperators NNReal + +namespace WeakMTWTransport +section UniformCharts +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exists_uniform_volume_charts : + ∃ C : ℝ≥0, 0 hVs hz.2⟩ + choose C D l u hl hu U hUo hxU hUs hd hdi hj using H + obtain ⟨s,hs⟩ := isCompact_univ.elim_finite_subcover U hUo + (show univ⊆⋃ x, U x from fun x _ => mem_iUnion.mpr ⟨x,hxU x⟩) + let C0 : ℝ≥0 := 1+∑ a∈s, (C a+D a) + let R : ℝ := 1+∑ a∈s, (l a)⁻¹ + let u0 : ℝ := 1+∑ a∈s, u a + have hC0 : 0 (inv_pos.mpr (hl a)).le) + dsimp [R] + linarith + have hu0 : 0 (hu a).le) + dsimp [u0] + linarith + refine ⟨C0,hC0,R⁻¹,u0,inv_pos.mpr hR,hu0,?_⟩ + intro x + obtain ⟨a,ha,hxa⟩ := mem_iUnion₂.mp (hs (mem_univ x)) + have hCD : C a+D a≤C0 := by + have h := Finset.single_le_sum (f := fun a => C a+D a) (fun _ _ => zero_le) ha + exact h.trans (le_add_of_nonneg_left (by positivity)) + have hCa : C a≤C0 := (le_add_of_nonneg_right (zero_le)).trans hCD + have hDa : D a≤C0 := (le_add_of_nonneg_left (zero_le)).trans hCD + have hla : (l a)⁻¹≤R := by + have h := Finset.single_le_sum (fun b (_ : b∈s) => (inv_pos.mpr (hl b)).le) ha + dsimp [R] + linarith + have hlower : R⁻¹≤l a := by + have h := (inv_le_inv₀ hR (inv_pos.mpr (hl a))).mpr hla + simpa only [inv_inv] using h + have hua : u a≤u0 := by + have h := Finset.single_le_sum (fun b (_ : b∈s) => (hu b).le) ha + dsimp [u0] + linarith + exact ⟨a,U a,hUo a,hxa,hUs a,(hd a).weaken hCa,(hdi a).weaken hDa, + fun z hz => ⟨hlower.trans (hj a z hz).1,((hj a z hz).2).trans hua⟩⟩ + +end UniformCharts +end WeakMTWTransport + +end + +end + +section + +noncomputable section +open Set Filter MeasureTheory Manifold Bundle Metric +open scoped Topology ContDiff ENNReal NNReal BoundedContinuousFunction + +namespace WeakMTWTransport + +lemma scalar_intrinsic_jacobian_bounds {d j D a b ell u c C : ℝ} + (hd : 0≤d) (hjD : 0≤j*D) (hell : 0≤ell) (hc : 0 TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteUniformExpJac (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Metric +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {Q E : Type*} [NormedAddCommGroup Q] [NormedSpace ℝ Q] + [NormedAddCommGroup E] [NormedSpace ℝ E] [FiniteDimensional ℝ E] + +lemma compact_bilinear_interval_crossing {K : Set Q} (hK : IsCompact K) + {H : ℝ×Q → E →L[ℝ] E →L[ℝ] ℝ} + (hH : ∀ q∈K, ContDiffAt ℝ ∞ H (1,q)) + (hneg : ∀ q∈K, ∀ v:E, ‖v‖=1 → 0 < -(fderiv ℝ H (1,q) (1,0) v v)) : + ∃ c > 0, ∃ C > 0, ∃ ε > 0, + ∀ s t : ℝ, s∈ball 1 ε → t∈ball 1 ε → s≤t → ∀ q∈K, ∀ v:E, + c*(t-s)*‖v‖^2 ≤ H (s,q) v v-H (t,q) v v ∧ + H (s,q) v v-H (t,q) v v ≤ C*(t-s)*‖v‖^2 := by + let J : ℝ×Q → E →L[ℝ] E →L[ℝ] ℝ := fun z => fderiv ℝ H z (1,0) + have hJ : ∀ q∈K, ContinuousAt J (1,q) := by + intro q hq + exact ((hH q hq).continuousAt_fderiv (by simp)).clm_apply continuousAt_const + let S : Set (Q×E) := K ×ˢ sphere (0:E) 1 + have hS : IsCompact S := hK.prod (isCompact_sphere _ _) + let F : ℝ×(Q×E) → ℝ := fun z => -(J (z.1,z.2.1) z.2.2 z.2.2) + have hF : ∀ z∈S, ContinuousAt F (1,z) := by + intro z hz + exact ((((hJ z.1 hz.1).comp (x := (1,z)) + (continuousAt_fst.prodMk continuousAt_snd.fst)).clm_apply + continuousAt_snd.snd).clm_apply continuousAt_snd.snd).neg + have hFc : ContinuousOn (fun z => F (1,z)) S := by + intro z hz + exact ((hF z hz).comp (x := z) (continuousAt_const.prodMk continuousAt_id)).continuousWithinAt + obtain ⟨c,hc,HS⟩ : ∃ c>0, ∀ z∈S, c < F (1,z) := by + by_cases hne : S.Nonempty + · obtain ⟨z,hz,hmin⟩ := hS.exists_isMinOn hne hFc + have hp : 0 < F (1,z) := hneg z.1 hz.1 z.2 + (by simpa only [mem_sphere,dist_zero_right] using hz.2) + exact ⟨F (1,z)/2,half_pos hp,fun y hy => (half_lt_self hp).trans_le (hmin hy)⟩ + · exact ⟨1,zero_lt_one,fun z hz => (hne ⟨z,hz⟩).elim⟩ + have HF : ∀ᶠ t in 𝓝 (1:ℝ), ∀ z∈S, c < F (t,z) := + hS.eventually_forall_of_forall_eventually (fun z hz => + (continuousAt_const.eventually_lt (hF z hz) (HS z hz))) + obtain ⟨C,hC,HC⟩ := compact_eventually_fiberwise_bound hK + (f := fun _ : Q => ()) continuous_const (g := fun _ : ℝ => ()) + (continuousAt_const (x := 1)) (h := J) (fun q hq _ => hJ q hq) + have HD : ∀ᶠ t in 𝓝 (1:ℝ), ∀ q∈K, DifferentiableAt ℝ H (t,q) := + hK.eventually_forall_of_forall_eventually (fun q hq => + (((hH q hq).of_le (m := 1) (ENat.natCast_le_of_coe_top_le_withTop le_rfl 1)).eventually (by simp)).mono (fun z hz => hz.differentiableAt (by norm_num))) + obtain ⟨ε,hε,Hε⟩ := Metric.mem_nhds_iff.mp (HF.and (HC.and HD)) + refine ⟨c,hc,C,hC,ε,hε,?_⟩ + intro t₀ t₁ ht₀ ht₁ htt q hq v + have hall : ∀ s∈Icc t₀ t₁, + DifferentiableAt ℝ (fun s => H (s,q) v v) s ∧ + deriv (fun s => H (s,q) v v) s ≤ -c*‖v‖^2 ∧ + -C*‖v‖^2 ≤ deriv (fun s => H (s,q) v v) s := by + intro s hs + have hsb : s∈ball (1:ℝ) ε := by + rw [mem_ball,Real.dist_eq,abs_lt] at ht₀ ht₁ ⊢ + constructor <;> linarith only [ht₀.1,ht₀.2,ht₁.1,ht₁.2,hs.1,hs.2] + have HE := Hε hsb + have HDs := bilinear_time_hasDerivAt (HE.2.2 q hq) v + refine ⟨HDs.differentiableAt,?_,?_⟩ + · rw [HDs.deriv] + have HL := bilinear_lower_of_unit (-J (s,q)) (c := c) (by + intro w hw + have H := (HE.1 (q,w) ⟨hq,by simpa only [mem_sphere,dist_zero_right] using hw⟩).le + exact H) v + change c*‖v‖^2 ≤ -(J (s,q) v v) at HL + change J (s,q) v v ≤ -c*‖v‖^2 + linarith only [HL] + · rw [HDs.deriv] + have HL := (bilinear_diag_abs_le (J (s,q)) v).trans + (mul_le_mul_of_nonneg_right (HE.2.1 q hq rfl) (sq_nonneg ‖v‖)) + have HL' := (abs_le.mp HL).1 + change -C*‖v‖^2 ≤ J (s,q) v v + linarith only [HL'] + have Hcont : ContinuousOn (fun s => H (s,q) v v) (Icc t₀ t₁) := + fun s hs => (hall s hs).1.continuousAt.continuousWithinAt + have HDiff : DifferentiableOn ℝ (fun s => H (s,q) v v) (interior (Icc t₀ t₁)) := + fun s hs => (hall s (interior_subset hs)).1.differentiableWithinAt + have HU := (convex_Icc t₀ t₁).image_sub_le_mul_sub_of_deriv_le Hcont HDiff + (fun s hs => (hall s (interior_subset hs)).2.1) t₀ ⟨le_rfl,htt⟩ t₁ ⟨htt,le_rfl⟩ htt + have HL := (convex_Icc t₀ t₁).mul_sub_le_image_sub_of_le_deriv Hcont HDiff + (fun s hs => (hall s (interior_subset hs)).2.2) t₀ ⟨le_rfl,htt⟩ t₁ ⟨htt,le_rfl⟩ htt + constructor <;> nlinarith only [HU,HL] + +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/UniformJacobian.lean b/lean/OAI/Analysis/BiholderTransport/Volume/UniformJacobian.lean new file mode 100644 index 0000000000000000000000000000000000000000..4f571cfd9eb330a43ddff8a8b95f03d0c586d055 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/UniformJacobian.lean @@ -0,0 +1,137 @@ +import Mathlib +import OAI.Analysis.BiholderTransport.Coordinates.FiberLog + +namespace OAI + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteUniformJacobian (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] + +lemma exp_mfderiv_zero_apply (x : M) (v : TangentSpace 𝓘(ℝ,Model n) x) : + mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) (riemannianExp (n := n) x) 0 v=v := by + let V := TangentSpace 𝓘(ℝ,Model n) x + have heq : (fun t : ℝ => riemannianExp x (t • v))= + (fun t : ℝ => (sprayFlow t (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).1) := + funext (riemannianExp_smul x v) + have hf : HasFDerivAt (fun t : ℝ => t • v) ((1 : ℝ →L[ℝ] ℝ).smulRight v) 0 := + ((1 : ℝ →L[ℝ] ℝ).smulRight v).hasFDerivAt + have H := mfderiv_comp_apply (I := 𝓘(ℝ,ℝ)) (I' := 𝓘(ℝ,V)) + (I'' := 𝓘(ℝ,Model n)) (0:ℝ) + ((contMDiff_riemannianExp_fiber x (0 • v)).mdifferentiableAt (by simp)) + hf.differentiableAt.mdifferentiableAt (1:ℝ) + have hv := spray_velocity_eq_mfderiv ((sprayFlow_curve + (⟨x,v⟩ : TangentBundle 𝓘(ℝ,Model n) M)).isMIntegralCurveAt (0:ℝ)) + simp only [Function.comp_def,mfderiv_eq_fderiv,hf.fderiv] at H + rw [heq] at H + rw [sprayFlow_zero] at hv + have hz : (0:ℝ) • v=(0:V) := zero_smul ℝ v + have h1 : ((1 : ℝ →L[ℝ] ℝ).smulRight v) (1:ℝ)=v := by simp + erw [hz,h1] at H + exact H.symm.trans hv + +end WeakMTWTransport + +end + + + +noncomputable section +open Set Filter Manifold Bundle Module +open scoped Topology ContDiff + +namespace WeakMTWTransport +variable {n : ℕ} {M : Type*} [MetricSpace M] [CompactSpace M] + [ChartedSpace (Model n) M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [RiemannianBundle (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] +local instance tangentFiniteExpJac (x : M) : + FiniteDimensional ℝ (TangentSpace 𝓘(ℝ,Model n) x) := + inferInstanceAs (FiniteDimensional ℝ (Model n)) + +def expJacobian (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : ℝ := + (show TangentSpace 𝓘(ℝ,Model n) x →L[ℝ] + TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p) from + mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp (n := n) x) p).toLinearMap.normDet + +omit [CompactSpace M] [IsManifold 𝓘(ℝ,Model n) ∞ M] + [IsContMDiffRiemannianBundle 𝓘(ℝ,Model n) ∞ (Model n) + (fun x : M => TangentSpace 𝓘(ℝ,Model n) x)] + [IsRiemannianManifold 𝓘(ℝ,Model n) M] in +lemma expJacobian_nonneg (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + 0≤expJacobian x p := LinearMap.normDet_nonneg _ + +lemma normal_endpoint_derivative_eq {x y : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) y} + (hL : DifferentiableAt ℝ L p) (hLp : L p=0) + (hLi : ∀ᶠ v in 𝓝 p, riemannianExp y (L v)=riemannianExp x v) + (k : TangentSpace 𝓘(ℝ,Model n) x) : + fderiv ℝ L p k=mfderiv 𝓘(ℝ,TangentSpace 𝓘(ℝ,Model n) x) 𝓘(ℝ,Model n) + (riemannianExp x) p k := by + let V := TangentSpace 𝓘(ℝ,Model n) x + let W := TangentSpace 𝓘(ℝ,Model n) y + have H := mfderiv_comp_apply_of_eq (I := 𝓘(ℝ,V)) (I' := 𝓘(ℝ,W)) + (I'' := 𝓘(ℝ,Model n)) p + ((contMDiff_riemannianExp_fiber y 0).mdifferentiableAt (by simp)) + hL.mdifferentiableAt hLp k + erw [mfderiv_eq_fderiv,exp_mfderiv_zero_apply] at H + have HC := Filter.EventuallyEq.mfderiv_eq (I := 𝓘(ℝ,V)) (I' := 𝓘(ℝ,Model n)) + (show riemannianExp y ∘ L =ᶠ[𝓝 p] riemannianExp x from hLi) + have HC' := congrArg (fun A => A k) HC + exact H.symm.trans HC' + +lemma expJacobian_eq_normal_endpoint {x : M} {p : TangentSpace 𝓘(ℝ,Model n) x} + {L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p)} + (hL : DifferentiableAt ℝ L p) (hLp : L p=0) + (hLi : ∀ᶠ v in 𝓝 p, riemannianExp (riemannianExp x p) (L v)=riemannianExp x v) : + expJacobian x p=(fderiv ℝ L p).toLinearMap.normDet := by + unfold expJacobian + apply congrArg LinearMap.normDet + ext k + exact (normal_endpoint_derivative_eq hL hLp hLi k).symm + +lemma exists_normal_endpoint_coordinates (x : M) (p : TangentSpace 𝓘(ℝ,Model n) x) : + ∃ L : TangentSpace 𝓘(ℝ,Model n) x → TangentSpace 𝓘(ℝ,Model n) (riemannianExp x p), + ContDiffAt ℝ ∞ L p ∧ L p=0 ∧ + (∀ᶠ v in 𝓝 p, riemannianExp (riemannianExp x p) (L v)=riemannianExp x v) := by + let y := riemannianExp x p + obtain ⟨N,hN,hN0,hNi⟩ := exists_smooth_fiber_log (zero_mem_injectivityDomain (n := n) y) + simp only [riemannianExp_zero] at hN hN0 hNi + refine ⟨(fun v => N (riemannianExp x v)),?_,hN0,?_⟩ + · exact (hN.comp p (contMDiff_riemannianExp_fiber x p)).contDiffAt + · exact (continuous_riemannianExp x).continuousAt.eventually hNi +end WeakMTWTransport + +end + +end OAI diff --git a/lean/OAI/Analysis/BiholderTransport/Volume/UpperJacobianBarrier.lean b/lean/OAI/Analysis/BiholderTransport/Volume/UpperJacobianBarrier.lean new file mode 100644 index 0000000000000000000000000000000000000000..cb8df60083684f593f48b683994270124f4bfe15 --- /dev/null +++ b/lean/OAI/Analysis/BiholderTransport/Volume/UpperJacobianBarrier.lean @@ -0,0 +1,62 @@ +import Mathlib + +namespace OAI + +section + +section + +noncomputable section +open Set Module + +namespace WeakMTWTransport +section CenterRank +variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace ℝ E] + +lemma unit_positive_direction_of_rank_one_semibound (S : Submodule ℝ E) + {p : E} {a b : ℝ} (ha : 0 < a) (hS : S≠⊥) + (hbound : ∀ z ∈ S, a*‖z‖^2 ≤ b*(inner ℝ p z)^2) : + ∃ e ∈ S, ‖e‖=1 ∧ 0 < inner ℝ p e ∧ + S=Submodule.span ℝ {e} ∧ a ≤ b*(inner ℝ p e)^2 := by + have hk : ∀ z ∈ S, inner ℝ p z=0 → z=0 := by + intro z hz hpz + have H := hbound z hz + rw [hpz,zero_pow (by norm_num : 2≠0),mul_zero] at H + have Hsq : ‖z‖^2 ≤ 0 := (mul_le_mul_iff_of_pos_left ha).mp (by simpa only [mul_zero] using H) + exact norm_eq_zero.mp (by nlinarith only [Hsq,norm_nonneg z,sq_nonneg ‖z‖]) + obtain ⟨v,hv,hv0⟩ := Submodule.exists_mem_ne_zero_of_ne_bot hS + have hpv : inner ℝ p v≠0 := fun H => hv0 (hk v hv H) + obtain ⟨w,hw,hw0,hpw⟩ : ∃ w:E,w∈S ∧ w≠0 ∧ 0 < inner ℝ p w := by + rcases lt_or_gt_of_ne hpv with h | h + · exact ⟨-v,S.neg_mem hv,neg_ne_zero.mpr hv0,by simpa using neg_pos.mpr h⟩ + · exact ⟨v,hv,hv0,h⟩ + let e : E := ‖w‖⁻¹ • w + have hwn : 0 < ‖w‖ := norm_pos_iff.mpr hw0 + have heS : e∈S := S.smul_mem _ hw + have hen : ‖e‖=1 := by dsimp [e]; rw [norm_smul,Real.norm_of_nonneg (inv_nonneg.mpr hwn.le),inv_mul_cancel₀ hwn.ne'] + have hpe : 0 < inner ℝ p e := by + change 0 < inner ℝ p (‖w‖⁻¹ • w) + rw [inner_smul_right] + exact mul_pos (inv_pos.mpr hwn) hpw + have hspan : S=Submodule.span ℝ {e} := by + apply le_antisymm + · intro z hz + have heq : z=((inner ℝ p z)/(inner ℝ p e)) • e := by + apply sub_eq_zero.mp + apply hk _ (S.sub_mem hz (S.smul_mem _ heS)) + rw [inner_sub_right,inner_smul_right,div_mul_cancel₀ _ hpe.ne',sub_self] + rw [heq] + exact (Submodule.span ℝ {e}).smul_mem _ (Submodule.subset_span (mem_singleton e)) + · exact Submodule.span_le.mpr (singleton_subset_iff.mpr heS) + refine ⟨e,heS,hen,hpe,hspan,?_⟩ + simpa only [hen,one_pow,mul_one] using hbound e heS +end CenterRank +end WeakMTWTransport + +end + +end + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianCentralSupport.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianCentralSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..c14d483e6cba0c9c9cfe306d34a1ce1c6118cde8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianCentralSupport.lean @@ -0,0 +1,138 @@ +import OAI.Analysis.BoundedHochschild.TraceFreeComparison +import OAI.Analysis.BoundedHochschild.AbelianComparison +import OAI.Analysis.BoundedHochschild.TypeIICharacterization + +namespace OAI + +/-! Central support and comparison of abelian projections for type I reduction. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open FinitePathMain HochschildComparison + +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The central support of a projection, expressed by its central annihilators. -/ +def IsCentralSupport (p z : M) : Prop := + CentralProjection z ∧ p ≤ z ∧ + ∀ c : M, CentralProjection c → c * p = 0 → c * z = 0 + +theorem exists_central_support (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p : M} (hp : IsStarProjection p) : ∃ z : M, IsCentralSupport p z := by + classical + let S : Set M := {s | CentralProjection s ∧ s * p = 0} + have hzero : (0 : M) ∈ S := + ⟨⟨IsStarProjection.zero M, fun _ => Commute.zero_left _⟩, zero_mul _⟩ + obtain ⟨s, _, hm⟩ := zorn_le_nonempty₀ S (fun C hC hchain a ha => by + obtain ⟨t, ht, htp, hu⟩ := central_annihilator_chain e p C hchain ⟨a, ha⟩ + (fun q hq => hC hq) + exact ⟨t, ⟨ht, htp⟩, hu⟩) 0 hzero + have hs := hm.1.1 + have hsp := hm.1.2 + let z := 1 - s + have hz : CentralProjection z := + ⟨hs.1.one_sub, fun a => (Commute.one_left a).sub_left (hs.2 a)⟩ + refine ⟨z, hz, (hp.le_iff_mul_eq_right hz.1).mpr ?_, ?_⟩ + · change (1 - s) * p = p + rw [sub_mul, one_mul, hsp, sub_zero] + · intro c hc hcp + let t := z * c + have ht : CentralProjection t := + ⟨hz.1.mul hc.1 (hz.2 c), fun a => (hz.2 a).mul_left (hc.2 a)⟩ + have hst : s * t = 0 := by + change s * ((1 - s) * c) = 0 + rw [← mul_assoc, hs.1.mul_one_sub_self, zero_mul] + have htp : t * p = 0 := by + change z * c * p = 0 + rw [mul_assoc, hcp, mul_zero] + have hnew : s + t ∈ S := + ⟨⟨hs.1.add ht.1 hst, fun a => (hs.2 a).add_left (ht.2 a)⟩, + by rw [add_mul, hsp, htp, zero_add]⟩ + have hle : s ≤ s + t := le_add_of_nonneg_right ht.1.nonneg + have ht0 : t = 0 := add_eq_left.mp (le_antisymm (hm.2 hnew hle) hle) + exact (hc.2 z).eq.trans ht0 + +theorem central_support_full (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p z r : M} (hp : IsStarProjection p) (hz : IsCentralSupport p z) + (hr : IsStarProjection r) (hrz : r ≤ z) (hr0 : r ≠ 0) : + ∃ a : M, p * a * r ≠ 0 := by + by_contra hn + push Not at hn + have hrp (a : M) : r * a * p = 0 := by + simpa only [star_mul, star_star, hp.isSelfAdjoint.star_eq, + hr.isSelfAdjoint.star_eq, star_zero, mul_assoc] using congrArg star (hn (star a)) + obtain ⟨c, hc, hrc, hcp⟩ := exists_trace_free_central_separator e hr hp hrp + have hcz := hz.2.2 c hc hcp + have he : c * z * r = r := by + rw [mul_assoc, (hr.le_iff_mul_eq_right hz.1.1).mp hrz, + (hr.le_iff_mul_eq_right hc.1).mp hrc] + rw [hcz, zero_mul] at he + exact hr0 he.symm + +theorem trace_free_abelian_subequivalent (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p q : M} (hp : AbelianProjection p) (hq : IsStarProjection q) + (hfull : ∀ r : M, IsStarProjection r → r ≤ p → r ≠ 0 → ∃ a : M, q * a * r ≠ 0) : + ∃ v : PartialIso M, v.initial = p ∧ v.final ≤ q := by + classical + let S : Set (PartialIso M) := {v | v.initial ≤ p ∧ v.final ≤ q} + have hz : (0 : PartialIso M) ∈ S := + ⟨by simpa using hp.1.nonneg, by simpa using hq.nonneg⟩ + obtain ⟨v, _, hm⟩ := zorn_le_nonempty₀ S (fun C hC hchain a ha => by + obtain ⟨w, hwp, hwq, hu⟩ := partialIso_chain_upper e hp.1 hq C hchain ⟨a, ha⟩ + (fun t ht => hC ht) + exact ⟨w, ⟨hwp, hwq⟩, hu⟩) 0 hz + have hvp := hm.1.1 + have hvq := hm.1.2 + have hr := (v.initial_proj.le_iff_sub hp.1).mp hvp + have hs := (v.final_proj.le_iff_sub hq).mp hvq + have hir : v.initial * (p - v.initial) = 0 := by + rw [mul_sub, (v.initial_proj.le_iff_mul_eq_left hp.1).mp hvp, + v.initial_proj.isIdempotentElem.eq, sub_self] + have hvr (a : M) : v.final * a * (p - v.initial) = 0 := by + have h := HochschildTypeII.abelian_orthogonal_mul hp v.initial_proj hr hvp + (sub_le_self _ v.initial_proj.nonneg) hir (star (v : M) * a) + calc + _ = (v : M) * (v.initial * (star (v : M) * a) * (p - v.initial)) := by + simp only [← mul_assoc, v.mul_initial, PartialIso.final] + _ = 0 := by rw [h, mul_zero] + refine ⟨v, ?_, hvq⟩ + by_contra hi + obtain ⟨a, ha⟩ := hfull (p - v.initial) hr (sub_le_self _ v.initial_proj.nonneg) + (sub_ne_zero.mpr (Ne.symm hi)) + have hba : (q - v.final) * a * (p - v.initial) ≠ 0 := by + simpa only [sub_mul, hvr a, sub_zero] using ha + obtain ⟨w, hw0, hwi, hwf⟩ := partialIso_of_nonzero_corner e hs hr + ((q - v.final) * a * (p - v.initial)) hba + (by rw [← mul_assoc, ← mul_assoc, hs.isIdempotentElem.eq]) + (by rw [mul_assoc, hr.isIdempotentElem.eq]) + have hio := HochschildCentralComparison.orthogonal_of_le_sub hp.1 v.initial_proj + w.initial_proj hvp hwi + have hfo := HochschildCentralComparison.orthogonal_of_le_sub hq v.final_proj + w.final_proj hvq hwf + have hnew : v.orthogonalSum w hio hfo ∈ S := by + constructor + · rw [PartialIso.orthogonalSum_initial] + calc + v.initial + w.initial ≤ v.initial + (p - v.initial) := add_le_add_right hwi _ + _ = p := by abel + · rw [PartialIso.orthogonalSum_final] + calc + v.final + w.final ≤ v.final + (q - v.final) := add_le_add_right hwf _ + _ = q := by abel + have hle := v.le_orthogonalSum w hio hfo + have he := congrArg (fun t : PartialIso M => (t : M)) + (le_antisymm (hm.2 hnew hle) hle) + exact hw0 (add_eq_left.mp he) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianComparison.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..064ac0d4bbee233844a40755f221dcab45714418 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianComparison.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.Frames + +namespace OAI + +/-! Comparison with abelian projections. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildTypeII +open BoundedHochschild HochschildComparison FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma abelian_orthogonal_mul {p r t : M} (hp : AbelianProjection p) + (hr : IsStarProjection r) (ht : IsStarProjection t) (hrp : r ≤ p) (htp : t ≤ p) + (hrt : r*t=0) (a : M) : r*a*t=0 := by + have hpr := (hr.le_iff_mul_eq_right hp.1).mp hrp + have hrp' := (hr.le_iff_mul_eq_left hp.1).mp hrp + have hpt := (ht.le_iff_mul_eq_right hp.1).mp htp + have he : p*r*p=r := by rw [hpr,hrp'] + have hc := hp.2 r a + rw [he] at hc + calc + r*a*t = r*(p*a*p)*t := by rw [← mul_assoc,← mul_assoc,hrp',mul_assoc,mul_assoc,hpt,← mul_assoc] + _ = (p*a*p)*(r*t) := by rw [hc.eq,mul_assoc] + _ = 0 := by rw [hrt,mul_zero] + +include e hτ htr hfaith in + +theorem abelian_subequivalent_full {p q : M} (hp : AbelianProjection p) + (hq : IsStarProjection q) + (hfull : ∀ r : M, IsStarProjection r → r ≠ 0 → ∃ a : M, q*a*r ≠ 0) : + ∃ v : PartialIso M, v.initial=p ∧ v.final ≤ q := by + classical + let L := HochschildSakai.mul_hasPreadjoint e + let S : Set (PartialIso M) := {v | v.initial ≤ p ∧ v.final ≤ q} + have hzero : (0 : PartialIso M) ∈ S := by + exact ⟨by simpa using hp.1.nonneg,by simpa using hq.nonneg⟩ + obtain ⟨v,_hv0,hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain y hy => by + obtain ⟨s,hsp,hsq,hsup⟩ := PartialIso.chain_upper e τ L hτ htr hfaith hp.1 hq + c hchain ⟨y,hy⟩ (fun w hw => hc hw) + exact ⟨s,⟨hsp,hsq⟩,hsup⟩) 0 hzero + have hvp : v.initial ≤ p := hmax.1.1 + have hvq : v.final ≤ q := hmax.1.2 + have hr := (v.initial_proj.le_iff_sub hp.1).mp hvp + have hs := (v.final_proj.le_iff_sub hq).mp hvq + have hir : v.initial*(p-v.initial)=0 := by + rw [mul_sub,(v.initial_proj.le_iff_mul_eq_left hp.1).mp hvp, + v.initial_proj.isIdempotentElem.eq,sub_self] + have hvr : ∀ a : M, v.final*a*(p-v.initial)=0 := by + intro a + have h := abelian_orthogonal_mul hp v.initial_proj hr hvp + (sub_le_self _ v.initial_proj.nonneg) hir (star (v:M)*a) + calc + v.final*a*(p-v.initial) = (v:M)*(v.initial*(star (v:M)*a)*(p-v.initial)) := by + simp only [← mul_assoc,v.mul_initial,PartialIso.final] + _ = 0 := by rw [h,mul_zero] + refine ⟨v,?_,hvq⟩ + by_contra hi + obtain ⟨a,ha⟩ := hfull (p-v.initial) hr (sub_ne_zero.mpr (Ne.symm hi)) + have hba : (q-v.final)*a*(p-v.initial) ≠ 0 := by + simpa only [sub_mul,hvr a,sub_zero] using ha + obtain ⟨w,hw0,hwi,hwf⟩ := partialIso_of_nonzero_corner e hs hr + ((q-v.final)*a*(p-v.initial)) hba + (by rw [← mul_assoc,← mul_assoc,hs.isIdempotentElem.eq]) + (by rw [mul_assoc,hr.isIdempotentElem.eq]) + have hio := projection_orthogonal_of_le_sub hp.1 v.initial_proj w.initial_proj hvp hwi + have hfo := projection_orthogonal_of_le_sub hq v.final_proj w.final_proj hvq hwf + have hmem : v.orthogonalSum w hio hfo ∈ S := by + constructor + · rw [PartialIso.orthogonalSum_initial] + calc + v.initial+w.initial ≤ v.initial+(p-v.initial) := add_le_add_right hwi _ + _ = p := by abel + · rw [PartialIso.orthogonalSum_final] + calc + v.final+w.final ≤ v.final+(q-v.final) := add_le_add_right hwf _ + _ = q := by abel + have hle := v.le_orthogonalSum w hio hfo + have he := le_antisymm (hmax.2 hmem hle) hle + have hh : (v:M)+w=v := congrArg (fun z : PartialIso M => (z:M)) he + exact hw0 (add_eq_left.mp hh) + +include e hτ htr hfaith in +lemma abelian_trace_le_full {p q : M} (hp : AbelianProjection p) + (hq : IsStarProjection q) + (hfull : ∀ r : M, IsStarProjection r → r ≠ 0 → ∃ a : M, q*a*r ≠ 0) : + (τ p).re ≤ (τ q).re := by + obtain ⟨v,hv,hvq⟩ := abelian_subequivalent_full e τ hτ htr hfaith hp hq hfull + have ht : τ p=τ v.final := by rw [← hv]; exact htr _ _ + rw [ht] + exact Complex.re_le_re (τ.monotone hvq) + +end HochschildTypeII + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianPartitions.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianPartitions.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b3230ec8d7a322115e62866d2a08feffc68171a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianPartitions.lean @@ -0,0 +1,109 @@ +import Mathlib + +namespace OAI + +/-! +# Common finite partitions for commuting projections + +A finite family of projections in a commutative C⋆-algebra admits a common +orthogonal partition of unity. Adjoining one projection refines every cell +by multiplication with that projection and its complement. Zero cells are +retained, so no nonzero or trace assumptions are needed. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open scoped BigOperators + +variable {M : Type*} [CommCStarAlgebra M] + +private lemma split_same (a b q : M) (hq : IsStarProjection q) : + (a * q) * (b * q) = (a * b) * q := by + calc + (a * q) * (b * q) = (a * b) * (q * q) := by ring + _ = (a * b) * q := by rw [hq.isIdempotentElem.eq] + +private lemma split_cross (a b q : M) (hq : IsStarProjection q) : + (a * q) * (b * (1 - q)) = 0 := by + have hzero : q * (1 - q) = 0 := by + rw [mul_sub, mul_one, hq.isIdempotentElem.eq, sub_self] + calc + (a * q) * (b * (1 - q)) = (a * b) * (q * (1 - q)) := by ring + _ = 0 := by rw [hzero, mul_zero] + +private lemma decides_mul {r a : M} (h : r * a = 0 ∨ r * a = a) (b : M) : + r * (a * b) = 0 ∨ r * (a * b) = a * b := by + rcases h with h | h + · exact Or.inl (by rw [← mul_assoc, h, zero_mul]) + · exact Or.inr (by rw [← mul_assoc, h]) + +/-- A common orthogonal partition of unity for any finite family of projections. -/ +theorem exists_refining_partition (S : Finset {q : M // IsStarProjection q}) : + ∃ (n : ℕ) (p : Fin n → M), + (∀ i, IsStarProjection (p i)) ∧ + (∀ i j, i ≠ j → p i * p j = 0) ∧ + (∑ i, p i) = 1 ∧ + (∀ q ∈ S, ∀ i, q.val * p i = 0 ∨ q.val * p i = p i) := by + classical + induction S using Finset.induction_on with + | empty => + refine ⟨1, fun _ => 1, fun _ => IsStarProjection.one M, ?_, by simp, ?_⟩ + · intro i j hij + exact (hij (Subsingleton.elim i j)).elim + · simp + | @insert q S _ ih => + obtain ⟨n, p, hp, ho, hsum, hdec⟩ := ih + let parts : Fin (n + n) → M := + Fin.append (fun i => p i * q.val) (fun i => p i * (1 - q.val)) + refine ⟨n + n, parts, ?_, ?_, ?_, ?_⟩ + · intro i + refine Fin.addCases (fun j => ?_) (fun j => ?_) i + · simpa only [parts, Fin.append_left] using (hp j).mul q.property (Commute.all _ _) + · simpa only [parts, Fin.append_right] using + (hp j).mul q.property.one_sub (Commute.all _ _) + · intro i j + refine Fin.addCases (fun i => ?_) (fun i => ?_) i <;> + refine Fin.addCases (fun j => ?_) (fun j => ?_) j <;> intro hij + · have hij' : i ≠ j := fun h => hij (congrArg (Fin.castAdd n) h) + simp only [parts, Fin.append_left] + change (p i * q.val) * (p j * q.val) = 0 + rw [split_same _ _ _ q.property, ho i j hij', zero_mul] + · simp only [parts, Fin.append_left, Fin.append_right] + exact split_cross _ _ _ q.property + · simp only [parts, Fin.append_left, Fin.append_right] + rw [mul_comm] + exact split_cross _ _ _ q.property + · have hij' : i ≠ j := fun h => hij (congrArg (Fin.natAdd n) h) + simp only [parts, Fin.append_right] + change (p i * (1 - q.val)) * (p j * (1 - q.val)) = 0 + rw [split_same _ _ _ q.property.one_sub, ho i j hij', zero_mul] + · simp only [parts, Fin.sum_univ_add, Fin.append_left, Fin.append_right] + rw [← Finset.sum_mul, ← Finset.sum_mul, hsum] + ring + · intro r hr i + rcases Finset.mem_insert.mp hr with hrq | hr + · subst r + refine Fin.addCases (fun j => ?_) (fun j => ?_) i + · simp only [parts, Fin.append_left] + right + calc + q.val * (p j * q.val) = p j * (q.val * q.val) := by ring + _ = p j * q.val := by rw [q.property.isIdempotentElem.eq] + · simp only [parts, Fin.append_right] + left + calc + q.val * (p j * (1 - q.val)) = p j * (q.val * (1 - q.val)) := by ring + _ = 0 := by rw [mul_sub, mul_one, q.property.isIdempotentElem.eq, sub_self, mul_zero] + · refine Fin.addCases (fun j => ?_) (fun j => ?_) i + · simpa only [parts, Fin.append_left] using decides_mul (hdec r hr j) q.val + · simpa only [parts, Fin.append_right] using decides_mul (hdec r hr j) (1 - q.val) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..25fb83a124d923dde6e1e6dd0914836bcb74a760 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianPrimitives.lean @@ -0,0 +1,197 @@ +import OAI.Analysis.BoundedHochschild.AbelianPartitions +import OAI.Analysis.BoundedHochschild.Conditional +import OAI.Analysis.BoundedHochschild.CochainLimitDifferential + +namespace OAI + +/-! +# Norm-one primitives on abelian von Neumann algebras + +The abelian case of the classical type-I input is proved directly. Finite +families of projections admit common finite partitions. Their separability +homotopies have norm at most one; a bounded weak-* limit is exact on every +projection, hence everywhere by density of the span of projections. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +section FirstIdentity + +variable {M : Type*} [CStarAlgebra M] + +lemma mergeInputs_cons_zero {n : ℕ} (p : M) (v : Fin (n + 1) → M) : + mergeInputs (Fin.cons p v) (0 : Fin (n + 1)) = + Fin.cons (p * v 0) (fun i : Fin n => v i.succ) := by + funext i + refine Fin.cases ?_ (fun j => ?_) i + · simp [mergeInputs] + · simp [mergeInputs] + +lemma mergeInputs_cons_succ {n : ℕ} (p : M) (v : Fin (n + 1) → M) + (j : Fin n) : + mergeInputs (Fin.cons p v) j.succ = Fin.cons p (mergeInputs v j) := by + funext i + refine Fin.cases ?_ (fun k => ?_) i + · simp [mergeInputs] + · simp [mergeInputs, Fin.succ_lt_succ_iff] + +lemma differentialValue_cons {n : ℕ} (f : Cochain M (n + 1)) + (p : M) (v : Fin (n + 1) → M) : + differentialValue f (Fin.cons p v) = + p * f v - f (Fin.cons (p * v 0) (fun i : Fin n => v i.succ)) - + differentialValue (f.curryLeft p) v + + v 0 * f (Fin.cons p (fun i : Fin n => v i.succ)) := by + rw [differentialValue, Fin.sum_univ_succ] + simp only [Fin.cons_zero, Fin.cons_succ, mergeInputs_cons_zero, + mergeInputs_cons_succ, Fin.val_zero, zero_add, pow_one, neg_smul, one_smul, + Fin.val_succ] + have hi : (fun i : Fin (n + 1) => (Fin.cons p v : Fin (n + 2) → M) i.castSucc) = + Fin.cons p (fun i : Fin n => v i.castSucc) := by + funext i + refine Fin.cases ?_ (fun j => ?_) i <;> simp + rw [hi] + simp only [differentialValue, ContinuousMultilinearMap.curryLeft_apply] + have hs (j : Fin n) : (-1 : ℂ) ^ (j.val + 1 + 1) = -((-1 : ℂ) ^ (j.val + 1)) := by + rw [pow_succ] + ring + have hn : (-1 : ℂ) ^ (n + 2) = -((-1 : ℂ) ^ (n + 1)) := by + rw [show n + 2 = (n + 1) + 1 by omega, pow_succ] + ring + simp only [hs, hn, neg_smul, Finset.sum_neg_distrib] + abel + +lemma first_homotopy_identity {n : ℕ} (f : Cochain M (n + 1)) + (hf : ∀ x, differentialValue f x = 0) (p : M) (v : Fin (n + 1) → M) : + differentialValue (f.curryLeft p) v = + p * f v - f (Fin.cons (p * v 0) (fun i : Fin n => v i.succ)) + + v 0 * f (Fin.cons p (fun i : Fin n => v i.succ)) := by + have h := hf (Fin.cons p v) + rw [differentialValue_cons] at h + symm + apply sub_eq_zero.mp + convert h using 1 + abel + +end FirstIdentity + +variable {M : Type*} [CommCStarAlgebra M] + +def partitionHomotopy {r n : ℕ} (p : Fin r → M) (f : Cochain M (n + 1)) : + Cochain M n := ∑ i, centralOutput (p i) (f.curryLeft (p i)) + +lemma partitionHomotopy_norm {r n : ℕ} (p : Fin r → M) + (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i * p j = 0) (f : Cochain M (n + 1)) : + ‖partitionHomotopy p f‖ ≤ ‖f‖ := by + apply norm_sum_supported_cochains p hp horth + (fun i => centralOutput (p i) (f.curryLeft (p i))) + (fun i x => by + simp only [centralOutput_apply, ← mul_assoc, (hp i).isIdempotentElem.eq]) + (fun i x => by + simp only [centralOutput_apply] + calc + (p i * f.curryLeft (p i) x) * p i = (p i * p i) * f.curryLeft (p i) x := by ring + _ = p i * f.curryLeft (p i) x := by rw [(hp i).isIdempotentElem.eq]) + ‖f‖ (norm_nonneg _) (fun i => ?_) Finset.univ + refine (norm_centralOutput_le (p i) (hp i).norm_le _).trans ?_ + calc + ‖f.curryLeft (p i)‖ ≤ ‖f.curryLeft‖ * ‖p i‖ := f.curryLeft.le_opNorm (p i) + _ ≤ ‖f‖ := by + rw [ContinuousMultilinearMap.curryLeft_norm] + exact (mul_le_mul_of_nonneg_left (hp i).norm_le (norm_nonneg _)).trans_eq (mul_one _) + +lemma partitionHomotopy_exact {r n : ℕ} (p : Fin r → M) + (hp : ∀ i, IsStarProjection (p i)) (hsum : ∑ i, p i = 1) + (q : M) (hq : ∀ i, q * p i = 0 ∨ q * p i = p i) + (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) + (v : Fin n → M) : + differentialValue (partitionHomotopy p f) (Fin.cons q v) = f (Fin.cons q v) := by + have hpiece (i : Fin r) : + differentialValue (centralOutput (p i) (f.curryLeft (p i))) (Fin.cons q v) = + p i * f (Fin.cons q v) := by + rw [← central_differential_values (p i) (fun a => mul_comm _ _) (f.curryLeft (p i)) + (centralOutput (p i) (f.curryLeft (p i))) (fun _ => rfl)] + rw [first_homotopy_identity f hf] + simp only [Fin.cons_zero, Fin.cons_succ] + rcases hq i with h | h + · have hi : p i * q = 0 := (mul_comm _ _).trans h + rw [hi] + have hz : f (Fin.cons 0 v) = 0 := by + change f.curryLeft 0 v = 0 + simp + rw [hz] + simp only [sub_zero, mul_add, ← mul_assoc, hi, + (hp i).isIdempotentElem.eq, zero_mul, add_zero] + · have hi : p i * q = p i := (mul_comm _ _).trans h + rw [hi] + simp only [mul_add, mul_sub, ← mul_assoc, hi, + (hp i).isIdempotentElem.eq, sub_add_cancel] + rw [partitionHomotopy, ← differential_apply] + have hsumd : differential (∑ i, centralOutput (p i) (f.curryLeft (p i))) = + ∑ i, differential (centralOutput (p i) (f.curryLeft (p i))) := by + exact map_sum (differentialLinearMap M n) _ _ + rw [hsumd, sum_apply] + simp only [differential_apply, hpiece, ← Finset.sum_mul, hsum, one_mul] + +section Predual + +variable {X : Type*} [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The abelian case of the classical input, proved with an explicit norm-one bound. -/ +theorem abelian_primitive (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + classical + let P := {q : M // IsStarProjection q} + choose r p hp horth hsum href using fun S : Finset P => exists_refining_partition S + let F (S : Finset P) : Cochain M n := partitionHomotopy (p S) f + have hFn (S : Finset P) : ‖F S‖ ≤ ‖f‖ := partitionHomotopy_norm (p S) (hp S) (horth S) f + let U : Ultrafilter (Finset P) := Ultrafilter.of atTop + have hU : (U : Filter (Finset P)) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨g, hgn, ht⟩ := bounded_cochain_ultralimit e U F ‖f‖ (norm_nonneg _) hFn + have hproj (q : P) (v : Fin n → M) : + differentialValue g (Fin.cons (q : M) v) = f (Fin.cons (q : M) v) := by + have he : (fun S => differentialValue (F S) (Fin.cons (q : M) v)) =ᶠ[U] + (fun _ => f (Fin.cons (q : M) v)) := by + apply hU + filter_upwards [eventually_ge_atTop ({q} : Finset P)] with S hS + exact partitionHomotopy_exact (p S) (hp S) (hsum S) (q : M) + (href S q (hS (Finset.mem_singleton_self q))) f hf v + apply predual_tendsto_unique e (predual_tendsto_differential_of_predual e ht _) + intro z + exact tendsto_const_nhds.congr' (he.mono fun _ h => + congrArg (fun a : M => e.symm a z) h.symm) + have hall (v : Fin n → M) (a : M) : + differentialValue g (Fin.cons a v) = f (Fin.cons a v) := by + let L := firstSliceN (differential g - f) v + have hspan : Submodule.span ℂ {q : M | IsStarProjection q} ≤ L.ker := by + apply Submodule.span_le.mpr + intro q hq + change L q = 0 + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using + sub_eq_zero.mpr (hproj ⟨q, hq⟩ v) + have hclosed : (Submodule.span ℂ {q : M | IsStarProjection q}).topologicalClosure ≤ L.ker := + Submodule.topologicalClosure_minimal _ hspan L.isClosed_ker + rw [HochschildSakai.projection_span_dense e] at hclosed + have ha := hclosed (Submodule.mem_top : a ∈ (⊤ : Submodule ℂ M)) + change L a = 0 at ha + exact sub_eq_zero.mp (by + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using ha) + refine ⟨g, hgn, fun x => ?_⟩ + simpa only [Fin.cons_self_tail] using hall (Fin.tail x) (x 0) + +end Predual + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianProjectionForms.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianProjectionForms.lean new file mode 100644 index 0000000000000000000000000000000000000000..902d34cf3187b0db5a3dc940d86ea05b2b29d11c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianProjectionForms.lean @@ -0,0 +1,37 @@ +import OAI.Analysis.BoundedHochschild.TypeIMatrixColumns + +namespace OAI + +/-! Conversion between the two existing abelian-corner formulations. -/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open FinitePathMain HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma popa_abelian_of_finitePath {p : M} (hp : AbelianProjection p) : + PopaTypeII.AbelianProjection hp.1 := by + have hc (a : PopaCorner.algebra hp.1) : p * (a : M) * p = (a : M) := by + rw [a.property.1, a.property.2] + intro a b + apply Subtype.ext + change (a : M) * (b : M) = (b : M) * (a : M) + simpa only [hc] using (hp.2 (a : M) (b : M)).eq + +omit [PartialOrder M] [StarOrderedRing M] in +lemma abelian_partialIso (v : PartialIso M) (hp : AbelianProjection v.initial) : + AbelianProjection v.final := + finitePath_abelian_of_popa v.final_proj + (abelianProjection_partialIso v (popa_abelian_of_finitePath hp)) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianSupportEquivalence.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianSupportEquivalence.lean new file mode 100644 index 0000000000000000000000000000000000000000..df0cfa90713ac06f9ba429a37da9d770c2d19fc1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianSupportEquivalence.lean @@ -0,0 +1,96 @@ +import OAI.Analysis.BoundedHochschild.AbelianCentralSupport +import OAI.Analysis.BoundedHochschild.FiniteProjectionEquivalence + +namespace OAI + +/-! Abelian projections with the same central support are equivalent. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open FinitePathMain HochschildComparison + +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_initial_zero_iff_final_zero (v : PartialIso M) + {c : M} (hc : ∀ a : M, c * a = a * c) : + c * v.initial = 0 ↔ c * v.final = 0 := by + have hf (w : PartialIso M) (hi : c * w.initial = 0) : c * w.final = 0 := by + have hv : c * (w : M) = 0 := by + calc + _ = c * ((w : M) * w.initial) := by rw [w.mul_initial] + _ = (w : M) * (c * w.initial) := by rw [← mul_assoc, hc, mul_assoc] + _ = 0 := by rw [hi, mul_zero] + change c * ((w : M) * star (w : M)) = 0 + rw [← mul_assoc, hv, zero_mul] + exact ⟨hf v, fun h => by simpa using hf (adjointPartialIso v) (by simpa using h)⟩ + +lemma IsCentralSupport.partialIso (v : PartialIso M) {z : M} + (h : IsCentralSupport v.initial z) : IsCentralSupport v.final z := by + have hzv : z * (v : M) = v := by + calc + _ = z * ((v : M) * v.initial) := by rw [v.mul_initial] + _ = (v : M) * (z * v.initial) := by rw [← mul_assoc, (h.1.2 (v : M)).eq, mul_assoc] + _ = v := by rw [(v.initial_proj.le_iff_mul_eq_right h.1.1).mp h.2.1, v.mul_initial] + refine ⟨h.1, (v.final_proj.le_iff_mul_eq_right h.1.1).mpr ?_, ?_⟩ + · change z * ((v : M) * star (v : M)) = _ + rw [← mul_assoc, hzv] + rfl + · intro c hc hc0 + exact h.2.2 c hc ((central_initial_zero_iff_final_zero v (fun a => (hc.2 a).eq)).mpr hc0) + +/-- Each subprojection of an abelian projection is a central cut of it. -/ +theorem abelian_subprojection_central_cut (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p q : M} (hp : AbelianProjection p) (hq : IsStarProjection q) (hqp : q ≤ p) : + ∃ c : M, CentralProjection c ∧ c * p = q := by + have hr := (hq.le_iff_sub hp.1).mp hqp + have hqr : q * (p - q) = 0 := by + rw [mul_sub, (hq.le_iff_mul_eq_left hp.1).mp hqp, hq.isIdempotentElem.eq, sub_self] + obtain ⟨c, hc, hqc, hcr⟩ := exists_trace_free_central_separator e hq hr + (HochschildTypeII.abelian_orthogonal_mul hp hq hr hqp + (sub_le_self _ hq.nonneg) hqr) + refine ⟨c, hc, ?_⟩ + have hcq := (hq.le_iff_mul_eq_right hc.1).mp hqc + rw [mul_sub, hcq, sub_eq_zero] at hcr + exact hcr + +/-- Full abelian projections over the same central support are equivalent. -/ +theorem abelian_equivalent_of_central_support (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p q z : M} (hp : AbelianProjection p) (hq : AbelianProjection q) + (hpz : IsCentralSupport p z) (hqz : IsCentralSupport q z) : + ∃ v : PartialIso M, v.initial = p ∧ v.final = q := by + obtain ⟨v, hvp, hvq⟩ := trace_free_abelian_subequivalent e hp hq.1 + (fun r hr hrp hr0 => central_support_full e hq.1 hqz hr (hrp.trans hpz.2.1) hr0) + have hvz : IsCentralSupport v.final z := + IsCentralSupport.partialIso v (by simpa only [hvp] using hpz) + have hr := (v.final_proj.le_iff_sub hq.1).mp hvq + have hrq : q - v.final ≤ q := sub_le_self _ v.final_proj.nonneg + obtain ⟨c, hc, hcr⟩ := abelian_subprojection_central_cut e hq hr hrq + have hcf : c * v.final = 0 := by + have horth : (q - v.final) * v.final = 0 := by + rw [sub_mul, (v.final_proj.le_iff_mul_eq_right hq.1).mp hvq, + v.final_proj.isIdempotentElem.eq, sub_self] + calc + _ = (c * q) * v.final := by rw [mul_assoc, + (v.final_proj.le_iff_mul_eq_right hq.1).mp hvq] + _ = 0 := by rw [hcr, horth] + have hcz := hvz.2.2 c hc hcf + have hr0 : q - v.final = 0 := by + calc + _ = c * q := hcr.symm + _ = c * (z * q) := by rw [(hq.1.le_iff_mul_eq_right hqz.1.1).mp hqz.2.1] + _ = 0 := by rw [← mul_assoc, hcz, zero_mul] + exact ⟨v, hvp, (sub_eq_zero.mp hr0).symm⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AbelianTypeI.lean b/lean/OAI/Analysis/BoundedHochschild/AbelianTypeI.lean new file mode 100644 index 0000000000000000000000000000000000000000..cefaba6ea98e085700bf4421461e4f579461c945 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AbelianTypeI.lean @@ -0,0 +1,59 @@ +import OAI.Analysis.BoundedHochschild.Conditional + +namespace OAI + +/-! +# Type I structure of abelian algebras + +Every projection in an abelian C⋆-algebra has a commutative corner. Therefore +an abelian algebra, as well as each of its central corners, has no nonzero +type II₁ summand. This verifies the structural hypothesis of the classical +vanishing input for the abelian case. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +variable {M : Type*} [CommCStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +/-- A corner of a commutative C⋆-algebra is commutative. -/ +instance commutativeCorner (p : M) (hp : IsStarProjection p) : + CommCStarAlgebra (Corner p hp) where + mul_comm a b := Subtype.ext (mul_comm (a : M) (b : M)) + +omit [PartialOrder M] [StarOrderedRing M] in +/-- Every projection in a commutative algebra is abelian. -/ +lemma abelian_projection {p : M} (hp : IsStarProjection p) : + PopaTypeII.AbelianProjection hp := by + intro a b + exact Subtype.ext (mul_comm (a : M) (b : M)) + +omit [StarOrderedRing M] in +/-- Every projection in a commutative algebra has a type I corner. -/ +lemma abelian_typeICorner {z : M} (hz : IsStarProjection z) : + PopaTypeII.TypeICorner hz := by + intro p hp _ hp0 + exact ⟨p, hp, le_rfl, hp0, abelian_projection hp⟩ + +/-- A commutative C⋆-algebra has no type II₁ central summand. -/ +theorem abelian_noTypeII1Summand : NoTypeII1Summand M := by + intro z hz _hc _hfinite hnoI + by_contra hz0 + let N := Corner z hz + have hN1 : (1 : N) ≠ 0 := by + intro hzero + apply hz0 + exact congrArg (fun a : N => (a : M)) hzero + exact hnoI 1 (IsStarProjection.one N) (fun _ => Commute.one_left _) hN1 + (abelian_typeICorner (IsStarProjection.one N)) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AdditivePositiveSupport.lean b/lean/OAI/Analysis/BoundedHochschild/AdditivePositiveSupport.lean new file mode 100644 index 0000000000000000000000000000000000000000..a915b7a5d90f0242cfd5e17b38dfa9861f7772f3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AdditivePositiveSupport.lean @@ -0,0 +1,93 @@ +import OAI.Analysis.BoundedHochschild.CompleteAdditivity + +namespace OAI + +/-! Support projections for completely additive positive functionals. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Complete additivity supplies a support projection without assuming +normality in advance. This is used in proving the normality criterion. -/ +theorem exists_additive_positive_support (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : CompletelyAdditive (positiveFunctionalCLM ψ)) : + ∃ p : M, IsStarProjection p ∧ ψ p = ψ 1 ∧ + ∀ q : M, IsStarProjection q → q ≤ p → ψ q = 0 → q = 0 := by + classical + let A : Set (Set M) := {S | (∀ p ∈ S, IsStarProjection p ∧ p ≠ 0 ∧ ψ p = 0) ∧ + ∀ p ∈ S, ∀ q ∈ S, p ≠ q → p * q = 0} + obtain ⟨S, hS⟩ := zorn_subset A (fun c hc hchain => by + refine ⟨⋃₀ c, ⟨?_, ?_⟩, fun s hs => Set.subset_sUnion_of_mem hs⟩ + · intro p hp + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + exact (hc hs).1 p hps + · intro p hp q hq hpq + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + obtain ⟨t, ht, hqt⟩ := Set.mem_sUnion.mp hq + rcases hchain.total hs ht with hst | hts + · exact (hc ht).2 p (hst hps) q hqt hpq + · exact (hc hs).2 p hps q (hts hqt) hpq) + let f : S → M := Subtype.val + have hf (i : S) : IsStarProjection (f i) := (hS.1.1 i i.property).1 + have ho (i j : S) (hij : i ≠ j) : f i * f j = 0 := + hS.1.2 i i.property j j.property (fun h => hij (Subtype.ext h)) + obtain ⟨P, hP, hPu, hPl, _⟩ := exists_orthogonal_projection_sum e f hf ho + have hPnull : ψ P = 0 := by + have ht := hψ S f hf ho P hP hPu hPl + have heq : (fun s : Finset S => ∑ i ∈ s, positiveFunctionalCLM ψ (f i)) = + (fun _ : Finset S => (0 : ℂ)) := by + funext s + apply Finset.sum_eq_zero + intro i _ + exact (hS.1.1 i i.property).2.2 + rw [heq] at ht + exact tendsto_nhds_unique ht tendsto_const_nhds + refine ⟨1 - P, hP.one_sub, ?_, ?_⟩ + · rw [map_sub, hPnull, sub_zero] + · intro q hq hqP hnull + by_contra hq0 + have hPq : P * q = 0 := + HochschildTypeII.projection_orthogonal_of_le_complement hP hq hqP + have hfq (i : S) : f i * q = 0 := by + calc + f i * q = (f i * P) * q := by rw [((hf i).le_iff_mul_eq_left hP).mp (hPu i)] + _ = 0 := by rw [mul_assoc, hPq, mul_zero] + have hqf (i : S) : q * f i = 0 := by + simpa only [star_mul, (hf i).isSelfAdjoint.star_eq, hq.isSelfAdjoint.star_eq, + star_zero] using congrArg star (hfq i) + have hnew : insert q S ∈ A := by + constructor + · intro a ha + rcases Set.mem_insert_iff.mp ha with rfl | ha + · exact ⟨hq, hq0, hnull⟩ + · exact hS.1.1 a ha + · intro a ha b hb hab + rcases Set.mem_insert_iff.mp ha with har | ha + · subst a + rcases Set.mem_insert_iff.mp hb with hbr | hb + · exact (hab hbr.symm).elim + · exact hqf ⟨b, hb⟩ + · rcases Set.mem_insert_iff.mp hb with hbr | hb + · subst b + exact hfq ⟨a, ha⟩ + · exact hS.1.2 a ha b hb hab + have hsubset : insert q S ⊆ S := hS.2 hnew (Set.subset_insert q S) + have hqin : q ∈ S := hsubset (Set.mem_insert q S) + exact hq0 (by simpa only [f, hq.isIdempotentElem.eq] using hfq ⟨q, hqin⟩) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AlgebraicMatrixPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/AlgebraicMatrixPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..aa1a012738e5e1631b27b244187265de483d2508 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AlgebraicMatrixPrimitives.lean @@ -0,0 +1,51 @@ +import OAI.Analysis.BoundedHochschild.MultimodularNormalReduction + +namespace OAI + +/-! The properly infinite primitive endpoint needs module identities only +on the algebraic countable matrix units. Separate normality is supplied by +the proved normal reduction, retaining those identities. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem primitive_of_algebraic_matrix_multimodular [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + {n : ℕ} (f : Cochain M (n + 2)) + (hM : MultimodularOver (countableMatrixAlgebra c) f) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := by + obtain ⟨F, b, hFN, hFM, hFc, hid⟩ := + normal_reduction_multimodular e (countableMatrixAlgebra c) f hf hM + obtain ⟨g, _, hg⟩ := primitive_of_normal_matrix_multimodular e hno c hi ho ht F hFN hFM hFc + refine ⟨g + b, fun x => ?_⟩ + rw [differentialValue_add, hg] + exact (hid x).symm + +theorem primitive_of_matrix_units [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + {n : ℕ} (f : Cochain M (n + 2)) + (hM : ∀ i j, MultimodularAt f (countableMatrixUnit c i j)) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := + primitive_of_algebraic_matrix_multimodular e hno c hi ho ht f + (multimodular_of_matrixUnits c hi ho f hM) hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AlternatingMoments.lean b/lean/OAI/Analysis/BoundedHochschild/AlternatingMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..f98409407a4bef29a2b2e3a6f821c9895ea21546 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AlternatingMoments.lean @@ -0,0 +1,342 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.FreeCoefficients +import OAI.Analysis.BoundedHochschild.UltrapowerMoments + +namespace OAI + +/-! Integer powers, alternating words and graded free moments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open scoped BigOperators ComplexConjugate InnerProductSpace ComplexOrder +namespace HochschildPatching +variable {I : Type*} {M : Type*} [CStarAlgebra M] +abbrev IntAtom (I : Type*) := ℤ × Option I + +def integerEval (F : I → M) (u : unitary M) (a : Option I) (l : List (IntAtom I)) : M := + wordCoeff F a * (l.map (fun b => ((u^b.1 : unitary M):M)*wordCoeff F b.2)).prod + +def admissibleIntTail (l : List (IntAtom I)) : Prop := + l ≠ [] ∧ ∀ b ∈ l.dropLast, b.2 ≠ none + +def exponentCode (k : ℤ) : Bool × ℕ := (decide (k<0), k.natAbs-1) +lemma signed_exponentCode (k : ℤ) (hk : k ≠ 0) : signedExponent (exponentCode k)=k := by + have hn : (k.natAbs-1:ℕ)+1=k.natAbs := Nat.sub_add_cancel (Int.natAbs_pos.mpr hk) + have hn' : ((k.natAbs-1:ℕ):ℤ)+1=(k.natAbs:ℤ) := by exact_mod_cast hn + simp only [exponentCode,signedExponent,hn',Int.natCast_natAbs] + by_cases hh : k<0 + · simp [hh,abs_of_neg hh] + · simp [hh,abs_of_nonneg (le_of_not_gt hh)] + +def toIntAtom {K : ℕ} (b : WordAtom I K) : IntAtom I := (signedExponent (b.1.1,b.1.2.val),b.2) +lemma integerEval_toIntAtom {K : ℕ} (F : I → M) (u : unitary M) (a : Option I) (l : List (WordAtom I K)) : + integerEval F u a (l.map toIntAtom)=mixedEval F (asPartialUnitary u) a l := by + rw [mixedEval_unitary_product] + simp only [integerEval,List.map_map] + rfl + +lemma integer_moments_of_bounded (τ : M → ℂ) (F : I → M) (u : unitary M) + (hm : ∀ K : ℕ, ∀ a : Option I, ∀ l : List (WordAtom I K), + admissibleTail l → τ (mixedEval F (asPartialUnitary u) a l)=0) + (a : Option I) (l : List (IntAtom I)) (hl : admissibleIntTail l) + (hk : ∀ b ∈ l, b.1 ≠ 0) : τ (integerEval F u a l)=0 := by + classical + let s : Finset ℕ := (l.map (fun b => (exponentCode b.1).2)).toFinset + obtain ⟨K,hK⟩ := s.exists_nat_subset_range + let g : IntAtom I → WordAtom I (K+1) := fun b => + (( (exponentCode b.1).1, if h : (exponentCode b.1).2 < K+1 then ⟨(exponentCode b.1).2,h⟩ else ⟨0,Nat.zero_lt_succ K⟩),b.2) + have hg (b : IntAtom I) (hb : b ∈ l) : toIntAtom (g b)=b := by + have hh : (exponentCode b.1).2 < K := Finset.mem_range.mp (hK (List.mem_toFinset.mpr (List.mem_map.mpr ⟨b,hb,rfl⟩))) + dsimp only [g,toIntAtom] + rw [dite_eq_left (Nat.lt_succ_of_lt hh)] + change (signedExponent (exponentCode b.1),b.2)=b + rw [signed_exponentCode _ (hk b hb)] + have hmap : (l.map g).map toIntAtom=l := by + rw [List.map_map] + conv_rhs => rw [← List.map_id l] + exact List.map_congr_left hg + have had : admissibleTail (l.map g) := by + constructor + · intro h; exact hl.1 (List.map_eq_nil_iff.mp h) + · intro b hb + rw [← List.map_dropLast] at hb + obtain ⟨c,hc,rfl⟩ := List.mem_map.mp hb + exact hl.2 c hc + have ht := hm (K+1) a (l.map g) had + rw [← integerEval_toIntAtom,hmap] at ht + exact ht +end HochschildPatching + + + + + +namespace HochschildPatching +variable {I H M : Type*} [CStarAlgebra M] +def alternatingTag : I ⊕ H → Bool := Sum.elim (fun _ => false) (fun _ => true) +lemma intTail_cons {t : List (IntAtom I)} (ht : admissibleIntTail t) (k : ℤ) (i : I) : + admissibleIntTail ((k,some i)::t) := by + refine ⟨List.cons_ne_nil _ _,?_⟩ + rw [List.dropLast_cons_of_ne_nil ht.1] + intro b hb + rcases List.mem_cons.mp hb with rfl | hb + · simp + · exact ht.2 b hb + +lemma alternating_right_repr (F : I → M) (R : H → M) (u : unitary M) + (hR : ∀ h, R h=0 ∨ ∃ k : ℤ, k ≠ 0 ∧ R h=((u^k : unitary M):M)) + (h : H) (l : List (I ⊕ H)) + (hc : (Sum.inr h::l).IsChain (fun x y => alternatingTag x ≠ alternatingTag y)) + (hnz : ∀ h', Sum.inr h' ∈ Sum.inr h::l → R h' ≠ 0) : + ∃ t : List (IntAtom I), admissibleIntTail t ∧ (∀ b ∈ t, b.1 ≠ 0) ∧ + ((Sum.inr h::l).map (Sum.elim F R)).prod=integerEval F u none t := by + suffices hx : ∀ n : ℕ, ∀ l : List (I ⊕ H), l.length=n → ∀ h : H, + (Sum.inr h::l).IsChain (fun x y => alternatingTag x ≠ alternatingTag y) → + (∀ h', Sum.inr h' ∈ Sum.inr h::l → R h' ≠ 0) → + ∃ t : List (IntAtom I), admissibleIntTail t ∧ (∀ b ∈ t, b.1 ≠ 0) ∧ + ((Sum.inr h::l).map (Sum.elim F R)).prod=integerEval F u none t + from hx l.length l rfl h hc hnz + intro n + induction n using Nat.strong_induction_on with + | h n ih => + intro l hn h hc hnz + obtain ⟨k,hk,hku⟩ := (hR h).resolve_left (hnz h (by simp)) + cases l with + | nil => + refine ⟨[(k,none)],⟨by simp,by simp⟩,?_,?_⟩ + · simpa using hk + · simp [integerEval,wordCoeff,hku] + | cons x l => + cases x with + | inr h' => + have hx := (List.isChain_cons_cons.mp hc).1 + simp [alternatingTag,Sum.elim] at hx + | inl i => + cases l with + | nil => + refine ⟨[(k,some i)],⟨by simp,by simp⟩,?_,?_⟩ + · simpa using hk + · simp [integerEval,wordCoeff,hku] + | cons x l => + cases x with + | inl j => + have hx := (List.isChain_cons_cons.mp (List.isChain_cons_cons.mp hc).2).1 + simp [alternatingTag,Sum.elim] at hx + | inr j => + have hcl := (List.isChain_cons_cons.mp (List.isChain_cons_cons.mp hc).2).2 + obtain ⟨t,ht,hkt,he⟩ := ih l.length (by simp only [List.length_cons] at hn; omega) + l rfl j hcl (fun h' hh => hnz h' (by simp only [List.mem_cons] at hh ⊢; tauto)) + refine ⟨(k,some i)::t,intTail_cons ht k i,?_,?_⟩ + · intro b hb + rcases List.mem_cons.mp hb with rfl | hb + · exact hk + · exact hkt b hb + · change R h * (F i * ((Sum.inr j::l).map (Sum.elim F R)).prod)=_ + rw [he,hku] + simp only [integerEval,wordCoeff,List.map_cons,List.prod_cons,one_mul,mul_assoc] + +lemma alternating_moment_zero (τ : M →ₗ[ℂ] ℂ) (F : I → M) (R : H → M) (u : unitary M) + (hF : ∀ i, τ (F i)=0) + (hR : ∀ h, R h=0 ∨ ∃ k : ℤ, k ≠ 0 ∧ R h=((u^k : unitary M):M)) + (hm : ∀ a : Option I, ∀ t : List (IntAtom I), admissibleIntTail t → + (∀ b ∈ t, b.1 ≠ 0) → τ (integerEval F u a t)=0) + (l : List (I ⊕ H)) (hc : l.IsChain (fun x y => alternatingTag x ≠ alternatingTag y)) + (hl : l ≠ []) : τ ((l.map (Sum.elim F R)).prod)=0 := by + classical + by_cases hz : (0:M) ∈ l.map (Sum.elim F R) + · rw [List.prod_eq_zero hz,map_zero] + have hnz (h : H) (hh : Sum.inr h ∈ l) : R h ≠ 0 := by + intro hh0 + exact hz (List.mem_map.mpr ⟨Sum.inr h,hh,hh0⟩) + cases l with + | nil => exact (hl rfl).elim + | cons x l => + cases x with + | inr h => + obtain ⟨t,ht,hkt,he⟩ := alternating_right_repr F R u hR h l hc hnz + rw [he] + exact hm none t ht hkt + | inl i => + cases l with + | nil => simpa using hF i + | cons x l => + cases x with + | inl j => + have hx := (List.isChain_cons_cons.mp hc).1 + simp [alternatingTag,Sum.elim] at hx + | inr h => + obtain ⟨t,ht,hkt,he⟩ := alternating_right_repr F R u hR h l + (List.isChain_cons_cons.mp hc).2 (fun h' hh => hnz h' (by simp only [List.mem_cons] at hh ⊢; tauto)) + change τ (F i * ((Sum.inr h::l).map (Sum.elim F R)).prod)=0 + rw [he] + have ht' := hm (some i) t ht hkt + simpa only [integerEval,wordCoeff,one_mul] using ht' +end HochschildPatching + + + + + + + +namespace HochschildGradedFree +variable {M G H Q : Type*} [Ring M] [Algebra ℂ M] [Group G] [Group H] [Group Q] +variable (u : G →* M) (v : H →* M) (α : G →* Q) (β : H →* Q) +variable (τ : M →ₗ[ℂ] ℂ) +abbrev Letter := G ⊕ H + +def value : Letter (G := G) (H := H) → M := Sum.elim u v +def degreeLetter : Letter (G := G) (H := H) → Q := Sum.elim α β +def tag : Letter (G := G) (H := H) → Bool := Sum.elim (fun _ => false) (fun _ => true) +def evaluate (l : List (Letter (G := G) (H := H))) : M := (l.map (value u v)).prod +def degree (l : List (Letter (G := G) (H := H))) : Q := (l.map (degreeLetter α β)).prod +def centeredValue (x : Letter (G := G) (H := H)) : M := value u v x - τ (value u v x) • (1:M) +def centeredEval (l : List (Letter (G := G) (H := H))) : M := (l.map (centeredValue u v τ)).prod +section +omit [Algebra ℂ M] +@[simp] lemma evaluate_nil : evaluate u v []=1 := rfl +@[simp] lemma evaluate_cons (x : Letter (G := G) (H := H)) (l) : + evaluate u v (x::l)=value u v x*evaluate u v l := rfl +@[simp] lemma evaluate_append (p q : List (Letter (G := G) (H := H))) : + evaluate u v (p++q)=evaluate u v p*evaluate u v q := by simp [evaluate,List.prod_append] +end +@[simp] lemma degree_nil : degree α β []=1 := rfl +@[simp] lemma degree_cons (x : Letter (G := G) (H := H)) (l) : + degree α β (x::l)=degreeLetter α β x*degree α β l := rfl +@[simp] lemma degree_append (p q : List (Letter (G := G) (H := H))) : + degree α β (p++q)=degree α β p*degree α β q := by simp [degree,List.prod_append] +@[simp] lemma centeredEval_nil : centeredEval u v τ []=1 := rfl +@[simp] lemma centeredEval_cons (x : Letter (G := G) (H := H)) (l) : + centeredEval u v τ (x::l)=centeredValue u v τ x*centeredEval u v τ l := rfl + +lemma degree_rotate_ne_one (x : Letter (G := G) (H := H)) (p q : List (Letter (G := G) (H := H))) + (hd : degree α β ((x::p)++q) ≠ 1) : degree α β (p++(q++[x])) ≠ 1 := by + simp only [List.cons_append,degree_cons,degree_append,degree_nil,mul_one] at hd ⊢ + intro hz + apply hd + rw [← mul_assoc] at hz + exact (mul_eq_one_comm.mp hz) + +variable (htr : ∀ a b : M, τ (a*b)=τ (b*a)) +include htr in +lemma centered_rotate (x : Letter (G := G) (H := H)) (p q : List (Letter (G := G) (H := H))) : + τ (centeredEval u v τ (x::p)*evaluate u v q)= + τ (centeredEval u v τ p*evaluate u v (q++[x]))- + τ (value u v x)*τ (centeredEval u v τ p*evaluate u v q) := by + simp only [centeredEval_cons,centeredValue,sub_mul,smul_mul_assoc,one_mul,map_sub,map_smul,smul_eq_mul] + congr 1 + rw [mul_assoc,htr] + simp only [evaluate_append,evaluate_cons,evaluate_nil,mul_one,mul_assoc] + +include htr in +lemma partial_center_zero (N : ℕ) + (hg : ∀ x : Letter (G := G) (H := H), degreeLetter α β x ≠ 1 → τ (value u v x)=0) + (hs : ∀ l : List (Letter (G := G) (H := H)), l.length simpa using hs q (by simpa using hn) (by simpa using hd) + | cons x p ih => + rw [centered_rotate u v τ htr] + have hfirst := ih (q++[x]) (by simp only [List.length_cons,List.length_append,List.length_nil] at hn ⊢; omega) + (degree_rotate_ne_one α β x p q hd) + rw [hfirst] + by_cases hx : τ (value u v x)=0 + · simp [hx] + · have hgx : degreeLetter α β x=1 := by by_contra h; exact hx (hg x h) + have hrest : degree α β (p++q) ≠ 1 := by simpa only [List.cons_append,degree_cons,hgx,one_mul] using hd + rw [ih q (by simp only [List.length_cons] at hn; omega) hrest,mul_zero,sub_zero] + +include htr in +lemma partial_center_eq (N : ℕ) + (hg : ∀ x : Letter (G := G) (H := H), degreeLetter α β x ≠ 1 → τ (value u v x)=0) + (hs : ∀ l : List (Letter (G := G) (H := H)), l.length simp + | cons x p ih => + rw [centered_rotate u v τ htr] + rw [ih (q++[x]) (by simp only [List.length_cons,List.length_append,List.length_nil] at hn ⊢; omega) + (degree_rotate_ne_one α β x p q hd)] + have hzero : τ (value u v x)*τ (centeredEval u v τ p*evaluate u v q)=0 := by + by_cases hx : τ (value u v x)=0 + · simp [hx] + · have hgx : degreeLetter α β x=1 := by by_contra h; exact hx (hg x h) + have hrest : degree α β (p++q) ≠ 1 := by simpa only [List.cons_append,degree_cons,hgx,one_mul] using hd + rw [partial_center_zero u v α β τ htr N hg hs p q (by simp only [List.length_cons] at hn; omega) hrest,mul_zero] + rw [hzero,sub_zero] + simp only [List.cons_append,evaluate_cons,evaluate_append,evaluate_nil,mul_one] + rw [← mul_assoc,htr] + +include htr in + + +theorem moment_eq_zero_of_degree_ne_one + (hg : ∀ g : G, α g ≠ 1 → τ (u g)=0) + (hh : ∀ h : H, β h ≠ 1 → τ (v h)=0) + (hfree : ∀ l : List (Letter (G := G) (H := H)), + l.IsChain (fun x y => tag x ≠ tag y) → l ≠ [] → τ (centeredEval u v τ l)=0) + (l : List (Letter (G := G) (H := H))) (hl : degree α β l ≠ 1) : + τ (evaluate u v l)=0 := by + classical + have hletter (x : Letter (G := G) (H := H)) : degreeLetter α β x ≠ 1 → τ (value u v x)=0 := by + cases x with + | inl g => exact hg g + | inr h => exact hh h + suffices h : ∀ N : ℕ, ∀ k : List (Letter (G := G) (H := H)), k.length=N → + degree α β k ≠ 1 → τ (evaluate u v k)=0 from h l.length l rfl hl + intro N + induction N using Nat.strong_induction_on with + | h N ih => + intro k hk hd + have Hshort (t : List (Letter (G := G) (H := H))) (ht : t.length tag x ≠ tag y) + · have hkc := hfree k halt (fun hn => hd (by simp [hn])) + have he := partial_center_eq u v α β τ htr k.length hletter Hshort k [] (by simp) (by simpa using hd) + simpa only [evaluate_nil,mul_one,List.append_nil,hkc] using he.symm + · rw [List.isChain_iff_forall_rel_of_append_cons_cons] at halt + push Not at halt + obtain ⟨a,b,p,q,hk',hab⟩ := halt + subst k + cases a with + | inl a => + cases b with + | inl b => + have hz := Hshort (p++Sum.inl (a*b)::q) (by simp) + (by simpa [degreeLetter,map_mul,mul_assoc] using hd) + simpa [value,map_mul,mul_assoc] using hz + | inr b => simp [tag,Sum.elim] at hab + | inr a => + cases b with + | inl b => simp [tag,Sum.elim] at hab + | inr b => + have hz := Hshort (p++Sum.inr (a*b)::q) (by simp) + (by simpa [degreeLetter,map_mul,mul_assoc] using hd) + simpa [value,map_mul,mul_assoc] using hz + +end HochschildGradedFree +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AsymptoticRigidity.lean b/lean/OAI/Analysis/BoundedHochschild/AsymptoticRigidity.lean new file mode 100644 index 0000000000000000000000000000000000000000..ffbfcbebc2cca2b2f0b27a15e492578be1377853 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AsymptoticRigidity.lean @@ -0,0 +1,131 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.FirstLetter +import OAI.Analysis.BoundedHochschild.Ultrapowers + +namespace OAI + +/-! Asymptotic first-letter identities and endpoint rigidity. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +namespace HochschildFirstLetter +open Filter Topology +open scoped ComplexOrder +open HochschildRigidity TracialUltrapower HochschildUltrapower +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + + + +theorem asymptotic_first_letter_rigidity + (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (R : A →L[ℂ] A) (hR : BallSequential τ.toPreGNS R) + (u : ℕ → FreeGroup ℕ →* unitary A) + (hfree : ∀ g : FreeGroup ℕ, g ≠ 1 → + Tendsto (fun j => τ (u j g : A)) atTop (nhds 0)) + (a b : A) + (hw : ∀ (g : FreeGroup ℕ) i t l, g.toWord = (i,t)::l → + (g.toWord.map Prod.fst).Nodup → + Tendsto (fun j => ‖τ.toPreGNS (R (u j g : A) - (if t then a else b)*(u j g : A))‖) + atTop (nhds 0)) : a = b := by + let ω := Ultrafilter.of (atTop : Filter ℕ) + have hω : (ω : Filter ℕ) ≤ atTop := Ultrafilter.of_le _ + have hm : BallModulus (traceHilbertMap τ h1) R := + (ballSequential_iff_modulus _ _).mp hR + apply constant_injective τ h1 ω htr hf + apply countable_first_letter_rigidity (quotientTrace τ h1 ω htr) + (quotientFamily τ h1 ω htr u) (quotientTrace_one τ h1 ω htr) + (quotientFamily_star τ h1 ω htr u) + (fun g hg => quotientFamily_trace_zero τ h1 ω htr u g hω (hfree g hg)) + (quotientTrace_tracial τ h1 ω htr) (quotientTrace_faithful τ h1 ω htr) + (HochschildUltrapower.map τ h1 ω htr R hm) + · exact (ballSequential_iff_modulus _ _).mpr (map_modulus τ h1 ω htr R hm) + · intro g i t l hword hnodup + have hh := map_asymptotic_identity τ h1 ω htr u g hω R hm (if t then a else b) + (hw g i t l hword hnodup) + cases t <;> exact hh + +end HochschildFirstLetter + +namespace HochschildUltrapower +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open TracialUltrapower HochschildRigidity +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) (ω : Ultrafilter ℕ) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) +variable {G : Type*} [Group G] + +lemma map_asymptotic_identity_sequence (u : ℕ → G →* unitary A) (g : G) + (hω : (ω : Filter ℕ) ≤ atTop) + (R : A →L[ℂ] A) (hR : BallModulus (traceHilbertMap τ h1) R) (a : ℕ →ᵇ A) + (ha : Tendsto (fun j => ‖τ.toPreGNS (R (u j g : A) - a j*(u j g : A))‖) atTop (nhds 0)) : + map τ h1 ω htr R hR (quotientFamily τ h1 ω htr u g) = + quotientHom τ h1 ω htr a * quotientFamily τ h1 ω htr u g := by + apply sub_eq_zero.mp + change (Ideal.Quotient.mk (ideal τ h1 ω htr)) + (R.compLeftContinuousBounded ℕ (boundedHom u g) - a * boundedHom u g) = 0 + apply (Ideal.Quotient.eq_zero_iff_mem).mpr + change _ ∈ nullSubmodule (traceHilbertMap τ h1).toLinearMap (ω : Filter ℕ) + rw [mem_nullSubmodule] + exact ha.mono_left hω + +end HochschildUltrapower + +namespace HochschildFirstLetter +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open HochschildRigidity TracialUltrapower HochschildUltrapower +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + + + +theorem asymptotic_first_letter_endpoints + (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (R : A →L[ℂ] A) (hR : BallSequential τ.toPreGNS R) + (u : ℕ → FreeGroup ℕ →* unitary A) + (hfree : ∀ g : FreeGroup ℕ, g ≠ 1 → + Tendsto (fun j => τ (u j g : A)) atTop (nhds 0)) + (a b : ℕ →ᵇ A) + (hw : ∀ (g : FreeGroup ℕ) i t l, g.toWord = (i,t)::l → + (g.toWord.map Prod.fst).Nodup → + Tendsto (fun j => ‖τ.toPreGNS (R (u j g : A) - (if t then a j else b j)*(u j g : A))‖) + atTop (nhds 0)) : + Tendsto (fun j => ‖τ.toPreGNS (a j - b j)‖) atTop (nhds 0) := by + rw [Filter.tendsto_iff_ultrafilter] + intro ω hω + have hm : BallModulus (traceHilbertMap τ h1) R := + (ballSequential_iff_modulus _ _).mp hR + have he : quotientHom τ h1 ω htr a = quotientHom τ h1 ω htr b := by + apply countable_first_letter_rigidity (quotientTrace τ h1 ω htr) + (quotientFamily τ h1 ω htr u) (quotientTrace_one τ h1 ω htr) + (quotientFamily_star τ h1 ω htr u) + (fun g hg => quotientFamily_trace_zero τ h1 ω htr u g hω (hfree g hg)) + (quotientTrace_tracial τ h1 ω htr) (quotientTrace_faithful τ h1 ω htr) + (HochschildUltrapower.map τ h1 ω htr R hm) + · exact (ballSequential_iff_modulus _ _).mpr (map_modulus τ h1 ω htr R hm) + · intro g i t l hword hnodup + cases t with + | false => + exact map_asymptotic_identity_sequence τ h1 ω htr u g hω R hm b + (hw g i false l hword hnodup) + | true => + exact map_asymptotic_identity_sequence τ h1 ω htr u g hω R hm a + (hw g i true l hword hnodup) + have hz : Ideal.Quotient.mk (ideal τ h1 ω htr) (a-b) = 0 := by + change quotientHom τ h1 ω htr (a-b) = 0 + rw [map_sub,he,sub_self] + have ha := Ideal.Quotient.eq_zero_iff_mem.mp hz + change (a-b) ∈ nullSubmodule (traceHilbertMap τ h1).toLinearMap (ω : Filter ℕ) at ha + rw [mem_nullSubmodule] at ha + exact ha + +end HochschildFirstLetter +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AtomicPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/AtomicPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..3384d4b258214c37bfac2b44be7c3366b6c08109 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AtomicPrimitives.lean @@ -0,0 +1,70 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers +import OAI.Analysis.BoundedHochschild.FiniteFactorPrimitives +import OAI.Analysis.BoundedHochschild.CornerCochains +import OAI.Analysis.BoundedHochschild.AtomicResolution + +namespace OAI + +/-! Bounded primitives over an atomic finite center. -/ + +noncomputable section + +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildAtomic HochschildCorners +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem primitive_of_atomic_finite + (hτ : TraceInPredual e τ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hatomic : AtomicCenter M) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖ ≤ (12+n)*‖f‖ ∧ ∀ x, differentialValue g x=f x := by + classical + let I := {p : M // CentralAtom p} + have hex (p : I) : ∃ g : Cochain (Corner p.val p.property.1) n, + ‖g‖≤12*‖f‖ ∧ ∀ x, differentialValue g x=cornerRestrict p.val p.property.1 p.property.2.1 f x := by + let ec := cornerPredualEquiv p.val p.property.1 e + let tc := cornerTrace p.val p.property.1 τ + obtain ⟨g,hg,he⟩ := primitive_of_finite_factor ec tc + (cornerTrace_normal p.val p.property.1 e τ hτ) + (cornerTrace_one p.val p.property.1 τ hfaith p.property.2.2.1) + (cornerTrace_tracial p.val p.property.1 τ htr) + (cornerTrace_faithful p.val p.property.1 τ hfaith p.property.2.2.1) + (central_atom_corner_factor e p.property) + (cornerRestrict p.val p.property.1 p.property.2.1 f) + (fun x => by rw [differential_cornerRestrict,hf,map_zero]) + exact ⟨g,hg.trans (mul_le_mul_of_nonneg_left + (cornerRestrict_norm p.val p.property.1 p.property.2.1 f) (by norm_num)),he⟩ + choose g hg he using hex + let b : I → Cochain M n := fun p => cornerExtend p.val p.property.1 p.property.2.1 (g p) + obtain ⟨G,hG,hGF⟩ := primitive_of_central_cut_primitives e + (HochschildSakai.mul_hasPreadjoint e) (fun p : I => p.val) + (fun p => p.property.1) (fun p a => (p.property.2.1 a).eq) + (fun p q hne => central_atoms_orthogonal p.property q.property + (fun heq => hne (Subtype.ext heq))) + (fun x hx => central_atoms_total e τ hτ htr hfaith hatomic x (fun p hp => hx ⟨p,hp⟩)) + f hf b (fun p x => cornerExtend_support p.val p.property.1 p.property.2.1 (g p) x) + (fun p => cornerExtend_primitive p.val p.property.1 p.property.2.1 f (g p) (he p)) + (12*‖f‖) (by positivity) + (fun p => (cornerExtend_norm p.val p.property.1 p.property.2.1 (g p)).trans (hg p)) + exact ⟨G,by simpa only [add_mul] using hG,hGF⟩ + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AtomicResolution.lean b/lean/OAI/Analysis/BoundedHochschild/AtomicResolution.lean new file mode 100644 index 0000000000000000000000000000000000000000..9c15e90d9a21561b4b356a41fe0d2e8a82eb3a80 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AtomicResolution.lean @@ -0,0 +1,105 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers +import OAI.Analysis.BoundedHochschild.CentralAtoms + +namespace OAI + +/-! Orthogonal atomic central resolution. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildAtomic +open BoundedHochschild HochschildTypeII FinitePathMain +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def AtomicCenter (M : Type u) [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] : Prop := + ∀ p : M, IsStarProjection p → (∀ a : M, Commute p a) → p ≠ 0 → + ∃ q : M, CentralAtom q ∧ q ≤ p + +lemma central_atoms_orthogonal {p q : M} (hp : CentralAtom p) (hq : CentralAtom q) (hne : p ≠ q) : + p*q=0 := by + have hpq : IsStarProjection (p*q) := hp.1.mul hq.1 (hp.2.1 q) + have hc : ∀ b : M, Commute (p*q) b := fun b => (hp.2.1 b).mul_left (hq.2.1 b) + have hpqp : p*q ≤ p := (hpq.le_iff_mul_eq_right hp.1).mpr + (by rw [← mul_assoc,hp.1.isIdempotentElem.eq]) + have hpqq : p*q ≤ q := (hpq.le_iff_mul_eq_left hq.1).mpr + (by rw [mul_assoc,hq.1.isIdempotentElem.eq]) + rcases hp.2.2.2 (p*q) hpq hc hpqp with hz | hpp + · exact hz + rcases hq.2.2.2 (p*q) hpq hc hpqq with hz | hqq + · exact hz + exact (hne (hpp.symm.trans hqq)).elim + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +include e in + +theorem central_atoms_total + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hatomic : AtomicCenter M) + (x : M) (hx : ∀ p : M, CentralAtom p → p*x=0) : x=0 := by + classical + let S : Set M := {p | CentralProjection p ∧ p*x=0} + have hzero : (0:M) ∈ S := ⟨⟨IsStarProjection.zero M,fun _ => Commute.zero_left _⟩,zero_mul _⟩ + obtain ⟨q,_hq0,hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain y hy => by + obtain ⟨q,hq,hqx,hupper⟩ := central_annihilator_chain e τ hτ htr hfaith + x c hchain ⟨y,hy⟩ (fun p hp => hc hp) + exact ⟨q,⟨hq,hqx⟩,hupper⟩) 0 hzero + have hq : CentralProjection q := hmax.1.1 + have hqx : q*x=0 := hmax.1.2 + have hone : q=1 := by + by_contra hne + have hr : CentralProjection (1-q) := + ⟨hq.1.one_sub,fun a => (Commute.one_left a).sub_left (hq.2 a)⟩ + obtain ⟨p,hp,hpq⟩ := hatomic (1-q) hr.1 hr.2 (sub_ne_zero.mpr (Ne.symm hne)) + have hqp : q*p=0 := projection_orthogonal_of_le_complement hq.1 hp.1 hpq + have hnew : q+p ∈ S := ⟨⟨hq.1.add hp.1 hqp,fun a => (hq.2 a).add_left (hp.2.1 a)⟩, + by rw [add_mul,hqx,hx p hp,zero_add]⟩ + have he : q+p=q := le_antisymm (hmax.2 hnew (le_add_of_nonneg_right hp.1.nonneg)) + (le_add_of_nonneg_right hp.1.nonneg) + exact hp.2.2.1 (add_eq_left.mp he) + simpa only [hone,one_mul] using hqx + +include e in + +theorem typeII_no_minimal + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hII : TypeII1 M) : + HochschildDiffuse.NoMinimalProjections M := by + intro p hp hp0 + by_contra hn + have hmin (q : M) (hq : IsStarProjection q) (hqp : q ≤ p) : q=0 ∨ q=p := by + by_cases hq0 : q=0 + · exact Or.inl hq0 + · right + by_contra hne + exact hn ⟨q,hq,hqp,hq0,hne⟩ + have hab : AbelianProjection p := by + refine ⟨hp,fun a b => ?_⟩ + apply HochschildCorners.commute_corner_of_projections e hp + (b:=p*b*p) _ (HochschildCorners.compress_mem_corner hp a) + intro q hq hqp + rcases hmin q hq hqp with hz | he + · rw [hz]; exact Commute.zero_left _ + · rw [he] + change p*(p*b*p)=(p*b*p)*p + rw [(HochschildCorners.compress_mem_corner hp b).1, + (HochschildCorners.compress_mem_corner hp b).2] + exact hp0 (no_abelian_projection e τ hτ htr hfaith hII hab) + +end HochschildAtomic + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AveragedBarFaces.lean b/lean/OAI/Analysis/BoundedHochschild/AveragedBarFaces.lean new file mode 100644 index 0000000000000000000000000000000000000000..8008eb1551122322c784c05b0059f8f99e145773 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AveragedBarFaces.lean @@ -0,0 +1,119 @@ +import OAI.Analysis.BoundedHochschild.BarInsertionFaces +import OAI.Analysis.BoundedHochschild.FiniteGroupPrefixAverages + +namespace OAI + +/-! Finite-group averages of the individual bar-insertion face formulas. +All unused vertex coordinates are integrated out with the normalized +finite-function sum identity. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M : Type u} [CStarAlgebra M] {G : Type v} [Group G] [Fintype G] + +lemma finiteGroupBarInsertion_coface {n : ℕ} (ρ : G →* unitary M) + (L : Cochain M (n + 1) →ₗ[ℂ] Cochain M (n + 2)) + (K : Cochain M n →ₗ[ℂ] Cochain M (n + 1)) + (i : Fin (n + 2)) (j : Fin (n + 1)) (p : Fin (n + 3)) + (f : Cochain M (n + 1)) + (h : ∀ u : Fin (n + 3) → unitary M, + barInsertion u i (L f) = K (barInsertion (p.removeNth u) j f)) : + finiteGroupBarInsertion ρ i (L f) = K (finiteGroupBarInsertion ρ j f) := by + have ht (g : Fin (n + 3) → G) : + barInsertion (fun k => ρ (g k)) i (L f) = + K (barInsertion (fun k => ρ (p.removeNth g k)) j f) := h (fun k => ρ (g k)) + unfold finiteGroupBarInsertion + simp_rw [ht] + rw [← map_sum, ← map_smul] + congr 1 + exact normalized_sum_removeNth p (fun g => barInsertion (fun k => ρ (g k)) j f) + +lemma finiteGroupBarInsertion_left_zero {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) : finiteGroupBarInsertion ρ 0 (leftCoboundary f) = f := by + simp only [finiteGroupBarInsertion, barInsertion_leftCoboundary_zero, + Finset.sum_const, Finset.card_univ] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, + inv_mul_cancel₀ (Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos)), one_smul] + +lemma finiteGroupBarInsertion_left_succ {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + finiteGroupBarInsertion ρ i.succ (leftCoboundary f) = + leftCoboundary (finiteGroupBarInsertion ρ i f) := by + apply finiteGroupBarInsertion_coface ρ (leftFaceLinear (n + 1)) (leftFaceLinear n) i.succ i 0 f + intro u + simpa only [leftFaceLinear, LinearMap.coe_mk, AddHom.coe_mk, Fin.removeNth_zero] using + barInsertion_leftCoboundary_succ u f i + +lemma finiteGroupBarInsertion_right_last {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) : + finiteGroupBarInsertion ρ (Fin.last (n + 1)) (rightCoboundary f) = + finiteGroupCochainAverage ρ f := by + unfold finiteGroupBarInsertion + simp only [barInsertion_rightCoboundary_last] + change (Fintype.card (Fin (n + 3) → G) : ℂ)⁻¹ • + (∑ g : Fin (n + 3) → G, + cochainUnitaryTransport (fun k => ρ (Fin.init g k)) f) = _ + rw [show (fun g : Fin (n + 3) → G => + cochainUnitaryTransport (fun k => ρ (Fin.init g k)) f) = + (fun g => cochainUnitaryTransport (fun k => ρ ((Fin.last (n + 2)).removeNth g k)) f) from by + funext g + rw [Fin.removeNth_last]] + exact normalized_sum_removeNth (Fin.last (n + 2)) + (fun g => cochainUnitaryTransport (fun k => ρ (g k)) f) + +lemma finiteGroupBarInsertion_right_castSucc {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + finiteGroupBarInsertion ρ i.castSucc (rightCoboundary f) = + rightCoboundary (finiteGroupBarInsertion ρ i f) := by + apply finiteGroupBarInsertion_coface ρ (rightFaceLinear (n + 1)) (rightFaceLinear n) + i.castSucc i (Fin.last (n + 2)) f + intro u + simpa only [rightFaceLinear, LinearMap.coe_mk, AddHom.coe_mk, Fin.removeNth_last] using + barInsertion_rightCoboundary_castSucc u f i + +lemma finiteGroupBarInsertion_middle_castSucc {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + finiteGroupBarInsertion ρ i.castSucc (middleCoboundary f i) = + finiteGroupPrefixAverage ρ (i.val + 1) f := by + unfold finiteGroupBarInsertion + simp only [barInsertion_middleCoboundary_castSucc] + exact normalized_sum_removeNth i.castSucc.succ + (fun g => cochainUnitaryTransport (unitaryPrefix (fun k => ρ (g k)) (i.val + 1)) f) + +lemma finiteGroupBarInsertion_middle_succ {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + finiteGroupBarInsertion ρ i.succ (middleCoboundary f i) = + finiteGroupPrefixAverage ρ (i.val + 1) f := by + unfold finiteGroupBarInsertion + simp only [barInsertion_middleCoboundary_succ] + exact normalized_sum_removeNth i.castSucc.succ + (fun g => cochainUnitaryTransport (unitaryPrefix (fun k => ρ (g k)) (i.val + 1)) f) + +lemma finiteGroupBarInsertion_middle_after {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 2)) (i : Fin (n + 2)) (j : Fin (n + 1)) + (hij : i.val ≤ j.val) : + finiteGroupBarInsertion ρ i.castSucc (middleCoboundary f j.succ) = + middleCoboundary (finiteGroupBarInsertion ρ i f) j := by + apply finiteGroupBarInsertion_coface ρ (middleFaceLinear j.succ) (middleFaceLinear j) + i.castSucc i j.succ.castSucc.succ f + intro u + exact barInsertion_middleCoboundary_after u f i j hij + +lemma finiteGroupBarInsertion_middle_before {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 2)) (i : Fin (n + 2)) (j : Fin (n + 1)) + (hji : j.val < i.val) : + finiteGroupBarInsertion ρ i.succ (middleCoboundary f j.castSucc) = + middleCoboundary (finiteGroupBarInsertion ρ i f) j := by + apply finiteGroupBarInsertion_coface ρ (middleFaceLinear j.castSucc) (middleFaceLinear j) + i.succ i j.castSucc.castSucc.succ f + intro u + exact barInsertion_middleCoboundary_before u f i j hji + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/AveragingOrbitFactorization.lean b/lean/OAI/Analysis/BoundedHochschild/AveragingOrbitFactorization.lean new file mode 100644 index 0000000000000000000000000000000000000000..adf5900db3ee40a4e91958d53248c8938e8dcd07 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/AveragingOrbitFactorization.lean @@ -0,0 +1,71 @@ +import OAI.Analysis.BoundedHochschild.FixedFactorizationLimits +import OAI.Analysis.BoundedHochschild.NormalFactorCandidates +import OAI.Analysis.BoundedHochschild.RightAveragingOrbit + +namespace OAI + +/-! All maps in a closed averaging orbit admit the same representation and +left factor as its initial map. Only the bounded right factor changes. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def weakNormalOperatorFamily (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (F : M → WeakDual ℂ X) : M → (NormalGNS e →WOT[ℂ] NormalGNS e) := + fun a => normalGNSWeak e (F a) + +lemma weakNormalOperatorFamily_continuous (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + Continuous (weakNormalOperatorFamily e) := by + apply continuous_pi + intro a + exact (normalGNSWeak_continuous e).comp (continuous_apply a) + +lemma weakNormalOperatorFamily_image (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : M →L[ℂ] M) (a : M) : + weakNormalOperatorFamily e (weakOperatorImage e T) a = + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e (T a)) := by + change ContinuousLinearMapWOT.ofCLM + (normalGNSRepresentation e (e (e.symm (T a)))) = _ + rw [e.apply_symm_apply] + +variable {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem weakRightAverageOrbit_fixed_factorization (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (T : M →L[ℂ] M) + (hT : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + (S : M →L[ℂ] M) (hS : weakOperatorImage e S ∈ weakRightAverageOrbit e T) : + ∃ V : NormalGNS e →L[ℂ] K, ‖V‖ ≤ ‖W‖ ∧ + ∀ a, normalGNSRepresentation e (S a) = L.adjoint.comp ((π a).comp V) := by + let B := {F : M → (NormalGNS e →WOT[ℂ] NormalGNS e) | + ∃ V : NormalGNS e →L[ℂ] K, ‖V‖ ≤ ‖W‖ ∧ + ∀ a, F a = ContinuousLinearMapWOT.ofCLM (L.adjoint.comp ((π a).comp V))} + have hclosed : IsClosed ((weakNormalOperatorFamily e) ⁻¹' B) := + (fixedFactorization_isClosed π L ‖W‖).preimage (weakNormalOperatorFamily_continuous e) + have hsub : weakOperatorImage e '' rightAverageOrbit T ⊆ + (weakNormalOperatorFamily e) ⁻¹' B := by + rintro F ⟨U, ⟨n, m, hm, rfl⟩, rfl⟩ + refine ⟨representedRightAverage π (normalGNSRepresentation e) m W, + representedRightAverage_norm_le π (normalGNSRepresentation e) m hm W, ?_⟩ + intro a + rw [weakNormalOperatorFamily_image] + exact congrArg ContinuousLinearMapWOT.ofCLM + (representedRightAverage_factorization π (normalGNSRepresentation e) T L W hT m a) + obtain ⟨V, hV, he⟩ := closure_minimal hsub hclosed hS + refine ⟨V, hV, fun a => ?_⟩ + have h := he a + rw [weakNormalOperatorFamily_image] at h + exact congrArg ContinuousLinearMapWOT.toCLM h + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/BarDifferential.lean b/lean/OAI/Analysis/BoundedHochschild/BarDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..e9302c3c7f1a1a1b8322941a5ed9143f450d2790 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/BarDifferential.lean @@ -0,0 +1,168 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CentralHomotopy + +namespace OAI + +/-! Bar-complex identities and the square-zero Hochschild differential. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +namespace BoundedHochschild + +lemma mergeInputs_mergeInputs {M : Type*} [Semigroup M] {n : ℕ} + (v : Fin (n+3) → M) (i : Fin (n+1)) (j : Fin (n+2)) (hj : j.val ≤ i.val) : + mergeInputs (mergeInputs v j) i = + mergeInputs (mergeInputs v i.succ) (Fin.castLT j (by omega)) := by + funext k + simp only [mergeInputs, Fin.lt_def, Fin.ext_iff, Fin.val_castSucc, Fin.val_succ, + Fin.val_castLT] + split_ifs <;> try simp_all only <;> try omega + all_goals try contradiction + all_goals try rfl + all_goals try simp only [mul_assoc] + all_goals congr 1 <;> apply Fin.ext <;> simp only [Fin.val_castSucc, Fin.val_succ] <;> omega + +variable {M : Type*} [CStarAlgebra M] + + + +def barDifferential {n : ℕ} (F : (Fin (n+1) → M) → M) : (Fin (n+2) → M) → M := + fun v => ∑ j : Fin (n+1), ((-1:ℂ)^j.val) • F (mergeInputs v j) + +lemma barDifferential_squared {n : ℕ} (F : (Fin (n+1) → M) → M) + (v : Fin (n+3) → M) : barDifferential (barDifferential F) v=0 := by + classical + simp only [barDifferential, Finset.smul_sum, smul_smul] + rw [Finset.sum_comm,← Finset.sum_product',Finset.univ_product_univ] + let P := Fin (n+1) × Fin (n+2) + let S : Finset P := {ij : P | ij.2.val ≤ ij.1.val} + rw [← Finset.sum_add_sum_compl S,← eq_neg_iff_add_eq_zero,← Finset.sum_neg_distrib] + let φ : ∀ ij : P, ij ∈ S → P := fun ij hij => + (Fin.castLT ij.2 (lt_of_le_of_lt (Finset.mem_filter.mp hij).right ij.1.isLt),ij.1.succ) + apply Finset.sum_bij φ + · intro ij hij + simp_rw [S,φ,Finset.compl_filter,Finset.mem_filter_univ,Fin.val_succ, + Fin.val_castLT] at hij ⊢ + omega + · rintro ⟨i,j⟩ hij ⟨i',j'⟩ hij' h + rw [Prod.mk_inj] + exact ⟨by simpa [φ] using congrArg Prod.snd h, + by simpa [φ,Fin.castSucc_castLT] using congrArg Fin.castSucc (congrArg Prod.fst h)⟩ + · rintro ⟨i',j'⟩ hij' + simp_rw [S,Finset.compl_filter,Finset.mem_filter_univ,not_le] at hij' + refine ⟨(j'.pred (by intro h; simp [h] at hij'),i'.castSucc),?_,?_⟩ + · simpa [S] using Nat.le_sub_one_of_lt hij' + · simp only [φ,Fin.castLT_castSucc,Fin.succ_pred] + · rintro ⟨i,j⟩ hij + dsimp only [φ] + rw [← neg_smul] + have hji : j.val ≤ i.val := (Finset.mem_filter.mp hij).2 + rw [mergeInputs_mergeInputs v i j hji] + congr 1 + simp only [Fin.val_succ,Fin.val_castLT,pow_succ,mul_neg,mul_one] + ring + +end BoundedHochschild + + + +open scoped BigOperators +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + +lemma mergeInputs_cons_zero {n : ℕ} (v : Fin (n+1) → M) (a : M) : + mergeInputs (Fin.cons a v) 0=Fin.cons (a*v 0) (fun i : Fin n => v i.succ) := by + ext i + refine Fin.cases ?_ (fun j => ?_) i + · simp [mergeInputs] + · simp [mergeInputs,Fin.succ_ne_zero] + +lemma mergeInputs_cons_succ {n : ℕ} (v : Fin (n+1) → M) (a : M) (j : Fin n) : + mergeInputs (Fin.cons a v) j.succ=Fin.cons a (mergeInputs v j) := by + ext i + refine Fin.cases ?_ (fun k => ?_) i + · simp [mergeInputs] + · simp [mergeInputs,Fin.castSucc_succ] + + + +def barEnvelope {n : ℕ} (f : Cochain M n) : (Fin (n+2) → M) → M := + fun v => v 0*f (fun i => v i.succ.castSucc)*v (Fin.last (n+1)) + +lemma barEnvelope_apply {n : ℕ} (f : Cochain M n) (a b : M) (v : Fin n → M) : + barEnvelope f (Fin.snoc (Fin.cons a v) b)=a*f v*b := by + simp only [barEnvelope,Fin.snoc_last] + have h0 : (Fin.snoc (Fin.cons a v) b : Fin (n+2) → M) 0=a := by + change (Fin.snoc (Fin.cons a v) b : Fin (n+2) → M) (0 : Fin (n+1)).castSucc=a + simp + have hv : (fun i : Fin n => (Fin.snoc (Fin.cons a v) b : Fin (n+2) → M) i.succ.castSucc)=v := by + ext i; simp only [Fin.snoc_castSucc,Fin.cons_succ] + rw [h0,hv] + +lemma barDifferential_envelope_apply {n : ℕ} (f : Cochain M n) (a b : M) + (v : Fin (n+1) → M) : + barDifferential (barEnvelope f) (Fin.snoc (Fin.cons a v) b)= + a*differentialValue f v*b := by + rw [barDifferential,Fin.sum_univ_castSucc] + simp only [mergeInputs_snoc_castSucc,Fin.val_castSucc] + rw [Fin.sum_univ_succ] + simp only [mergeInputs_cons_zero,mergeInputs_cons_succ,barEnvelope_apply, + Fin.val_zero,pow_zero,one_smul,Fin.val_succ,mergeInputs_snoc_last,Fin.val_last] + have hi : (fun i : Fin (n+1) => (Fin.cons a v : Fin (n+2) → M) i.castSucc)=Fin.cons a (fun i : Fin n => v i.castSucc) := by + ext i; refine Fin.cases ?_ (fun j => ?_) i + · simp + · simp only [Fin.castSucc_succ,Fin.cons_succ] + have hl : (Fin.cons a v : Fin (n+2) → M) (Fin.last (n+1))=v (Fin.last n) := by + change (Fin.cons a v : Fin (n+2) → M) (Fin.last n).succ=_ + simp + rw [hi,hl,barEnvelope_apply] + simp only [differentialValue,mul_add,add_mul,Finset.mul_sum,Finset.sum_mul, + mul_smul_comm,smul_mul_assoc,mul_assoc] + try abel + +lemma barDifferential_envelope {n : ℕ} (f : Cochain M n) : + barDifferential (barEnvelope f)=barEnvelope (differential f) := by + ext v + have hv : v=Fin.snoc (Fin.cons (v 0) (fun i : Fin (n+1) => v i.succ.castSucc)) (v (Fin.last (n+2))) := by + ext i + refine Fin.lastCases ?_ (fun j => ?_) i + · simp + · refine Fin.cases ?_ (fun k => ?_) j + · simp + · simp only [Fin.snoc_castSucc,Fin.cons_succ] + rw [hv,barDifferential_envelope_apply,barEnvelope_apply,differential_apply] + + + +theorem differential_squared {n : ℕ} (f : Cochain M n) : + differential (differential f)=0 := by + ext v + have h := barDifferential_squared (barEnvelope f) (Fin.snoc (Fin.cons (1:M) v) 1) + rw [barDifferential_envelope,barDifferential_envelope,barEnvelope_apply,one_mul,mul_one] at h + exact h + +lemma differential_is_cocycle {n : ℕ} (f : Cochain M n) (v : Fin (n+2) → M) : + differentialValue (differential f) v=0 := by + rw [← differential_apply,differential_squared] + rfl + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/BarInsertionFaces.lean b/lean/OAI/Analysis/BoundedHochschild/BarInsertionFaces.lean new file mode 100644 index 0000000000000000000000000000000000000000..29b3ae7bc0b07911dfe8e3a514d24f3d43d9e4e6 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/BarInsertionFaces.lean @@ -0,0 +1,108 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupBarOperators +import OAI.Analysis.BoundedHochschild.UnitInsertionFaces +import OAI.Analysis.BoundedHochschild.UnitaryPrefixDeletion + +namespace OAI + +/-! The elementary Hochschild-face formulas for bounded bar insertions. +The finite signed averaging identity is proved separately from these +pointwise operator identities. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma barInsertion_leftCoboundary_zero {n : ℕ} (u : Fin (n + 3) → unitary M) + (f : Cochain M (n + 1)) : barInsertion u 0 (leftCoboundary f) = f := by + unfold barInsertion + rw [cochainUnitaryTransport_leftCoboundary, unitaryPrefix_tail] + simp only [Fin.val_zero] + have hp : unitaryPrefix (Fin.tail u) 0 = (fun _ => 1) := by + funext j + simp [unitaryPrefix] + rw [hp, cochainUnitaryTransport_one, curryMid_leftCoboundary_zero] + +lemma barInsertion_leftCoboundary_succ {n : ℕ} (u : Fin (n + 3) → unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + barInsertion u i.succ (leftCoboundary f) = + leftCoboundary (barInsertion (Fin.tail u) i f) := by + unfold barInsertion + rw [cochainUnitaryTransport_leftCoboundary, unitaryPrefix_tail, + curryMid_leftCoboundary_succ] + simp only [Fin.val_succ] + +lemma barInsertion_rightCoboundary_last {n : ℕ} (u : Fin (n + 3) → unitary M) + (f : Cochain M (n + 1)) : + barInsertion u (Fin.last (n + 1)) (rightCoboundary f) = + cochainUnitaryTransport (Fin.init u) f := by + unfold barInsertion + rw [cochainUnitaryTransport_rightCoboundary] + change (rightCoboundary (cochainUnitaryTransport + (Fin.init (unitaryPrefix u (n + 2))) f)).curryMid (Fin.last (n + 1)) 1 = _ + rw [unitaryPrefix_init, curryMid_rightCoboundary_last] + have hp : unitaryPrefix (Fin.init u) (n + 2) = Fin.init u := by + funext j + simp only [unitaryPrefix, j.isLt, ite_true] + rw [hp] + +lemma barInsertion_rightCoboundary_castSucc {n : ℕ} (u : Fin (n + 3) → unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + barInsertion u i.castSucc (rightCoboundary f) = + rightCoboundary (barInsertion (Fin.init u) i f) := by + unfold barInsertion + rw [cochainUnitaryTransport_rightCoboundary] + change (rightCoboundary (cochainUnitaryTransport + (Fin.init (unitaryPrefix u (i.val + 1))) f)).curryMid i.castSucc 1 = _ + rw [unitaryPrefix_init, curryMid_rightCoboundary_castSucc] + +lemma barInsertion_middleCoboundary_castSucc {n : ℕ} + (u : Fin (n + 3) → unitary M) (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + barInsertion u i.castSucc (middleCoboundary f i) = + cochainUnitaryTransport (unitaryPrefix (i.castSucc.succ.removeNth u) (i.val + 1)) f := by + unfold barInsertion + simp only [Fin.val_castSucc] + rw [cochainUnitaryTransport_middleCoboundary, + unitaryPrefix_removeNth_after u i.castSucc.succ (i.val + 1) (by simp), + curryMid_middleCoboundary_castSucc] + +lemma barInsertion_middleCoboundary_succ {n : ℕ} + (u : Fin (n + 3) → unitary M) (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + barInsertion u i.succ (middleCoboundary f i) = + cochainUnitaryTransport (unitaryPrefix (i.castSucc.succ.removeNth u) (i.val + 1)) f := by + unfold barInsertion + rw [cochainUnitaryTransport_middleCoboundary, + unitaryPrefix_removeNth_before u i.castSucc.succ (i.succ.val + 1) (by simp), + curryMid_middleCoboundary_succ] + rfl + +lemma barInsertion_middleCoboundary_after {n : ℕ} + (u : Fin (n + 4) → unitary M) (f : Cochain M (n + 2)) + (i : Fin (n + 2)) (j : Fin (n + 1)) (hij : i.val ≤ j.val) : + barInsertion u i.castSucc (middleCoboundary f j.succ) = + middleCoboundary (barInsertion (j.succ.castSucc.succ.removeNth u) i f) j := by + unfold barInsertion + rw [cochainUnitaryTransport_middleCoboundary, + unitaryPrefix_removeNth_after u j.succ.castSucc.succ (i.castSucc.val + 1) + (by simp only [Fin.val_castSucc, Fin.val_succ]; omega), + curryMid_middleCoboundary_after _ i j hij] + simp only [Fin.val_castSucc] + +lemma barInsertion_middleCoboundary_before {n : ℕ} + (u : Fin (n + 4) → unitary M) (f : Cochain M (n + 2)) + (i : Fin (n + 2)) (j : Fin (n + 1)) (hji : j.val < i.val) : + barInsertion u i.succ (middleCoboundary f j.castSucc) = + middleCoboundary (barInsertion (j.castSucc.castSucc.succ.removeNth u) i f) j := by + unfold barInsertion + rw [cochainUnitaryTransport_middleCoboundary, + unitaryPrefix_removeNth_before u j.castSucc.castSucc.succ (i.succ.val + 1) + (by simp only [Fin.val_castSucc, Fin.val_succ]; omega), + curryMid_middleCoboundary_before _ i j hji] + simp only [Fin.val_succ, Nat.add_sub_cancel] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/BarInsertionFormula.lean b/lean/OAI/Analysis/BoundedHochschild/BarInsertionFormula.lean new file mode 100644 index 0000000000000000000000000000000000000000..d0112161bb755b74139ad123e3045189b6cc898f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/BarInsertionFormula.lean @@ -0,0 +1,57 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupBarOperators + +namespace OAI + +/-! An explicit input formula for the bounded bar-insertion operators. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +def barPrefixTuple {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (x : Fin n → M) : Fin n → M := + fun j => if j.castSucc < i then + (u j.castSucc.castSucc : M) * x j * star (u j.castSucc.succ : M) else x j + +lemma cochainUnitaryTuple_prefix_insert {n : ℕ} (u : Fin (n + 2) → unitary M) + (i : Fin (n + 1)) (x : Fin n → M) : + cochainUnitaryTuple (unitaryPrefix u (i.val + 1)) (i.insertNth 1 x) = + i.insertNth (u i.castSucc : M) (barPrefixTuple u i x) := by + symm + apply (Fin.insertNth_eq_iff).mpr + constructor + · simp [cochainUnitaryTuple, unitaryPrefix] + · ext j + change barPrefixTuple u i x j = + cochainUnitaryTuple (unitaryPrefix u (i.val + 1)) (i.insertNth 1 x) (i.succAbove j) + rw [show cochainUnitaryTuple (unitaryPrefix u (i.val + 1)) (i.insertNth 1 x) (i.succAbove j) = + (unitaryPrefix u (i.val + 1) (i.succAbove j).castSucc : M) * x j * + star (unitaryPrefix u (i.val + 1) (i.succAbove j).succ : M) by + simp only [cochainUnitaryTuple, Fin.insertNth_apply_succAbove]] + by_cases hji : j.castSucc < i + · rw [Fin.succAbove_of_castSucc_lt i j hji] + have ha : j.val < i.val + 1 := by have h := hji; simp only [Fin.lt_def, Fin.val_castSucc] at h; omega + have hb : j.val + 1 < i.val + 1 := by have h := hji; simp only [Fin.lt_def, Fin.val_castSucc] at h; omega + simp only [barPrefixTuple, hji, ite_true, unitaryPrefix, Fin.val_castSucc, Fin.val_succ, ha, hb] + · rw [Fin.succAbove_of_le_castSucc i j (le_of_not_gt hji)] + have ha : ¬j.val + 1 < i.val + 1 := by + have h := hji + simp only [Fin.lt_def, Fin.val_castSucc] at h + omega + have hb : ¬j.val + 1 + 1 < i.val + 1 := by omega + simp only [barPrefixTuple, hji, ite_false, unitaryPrefix, Fin.val_castSucc, Fin.val_succ, + ha, hb, OneMemClass.coe_one, star_one, one_mul, mul_one] + +lemma barInsertion_prefix_value {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) (x : Fin n → M) : + barInsertion u i f x = star (u 0 : M) * + f (i.insertNth (u i.castSucc : M) (barPrefixTuple u i x)) := by + rw [barInsertion_value, cochainUnitaryTuple_prefix_insert] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/BlockSpans.lean b/lean/OAI/Analysis/BoundedHochschild/BlockSpans.lean new file mode 100644 index 0000000000000000000000000000000000000000..34c6b4ff703aff396e14e7586f1f7c81c8e27dd7 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/BlockSpans.lean @@ -0,0 +1,388 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PolarApproximation + +namespace OAI + +/-! Signed block sums, good patterns and spans of word evaluations. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildBlockAssembly +noncomputable section +open Finset Filter Topology HochschildCollision HochschildBlockError HochschildBlockWords +variable {A : Type*} [CStarAlgebra A] +variable {α : Type*} [Fintype α] [DecidableEq α] + +def allSum (u : FreeGroup α →* A) {L : ℕ} (σ : Fin L → Bool) : A := + ∑ f : Fin L → α, u (wordOf σ f) + +lemma sum_badSum (u : FreeGroup α →* A) {L : ℕ} (σ : Fin L → Bool) : + (∑ q ∈ range (L+1), badSum u σ q) = + ∑ f : Fin L → α with ¬ ((FreeGroup.reduce (tupleWord σ f)).map Prod.fst).Nodup, + u (wordOf σ f) := by + classical + let s : Finset (Fin L → α) := univ.filter fun f => + ¬ ((FreeGroup.reduce (tupleWord σ f)).map Prod.fst).Nodup + have hlen (f : Fin L → α) (_hf : f ∈ s) : (wordOf σ f).toWord.length ∈ range (L+1) := by + have h := @FreeGroup.norm_mk_le α (tupleWord σ f) + rw [tupleWord_length] at h + exact mem_range.mpr (by exact Nat.lt_succ_of_le h) + rw [← sum_fiberwise_of_maps_to hlen (fun f => u (wordOf σ f))] + apply sum_congr rfl + intro q _ + unfold badSum + symm + apply sum_subtype + intro f + constructor + · intro h + exact ⟨(Finset.mem_filter.mp h).2, (Finset.mem_filter.mp (Finset.mem_filter.mp h).1).2⟩ + · intro h + exact Finset.mem_filter.mpr ⟨Finset.mem_filter.mpr ⟨Finset.mem_univ _,h.2⟩,h.1⟩ + +lemma map_allSum_eq_badSum (u : FreeGroup α →* A) (T : A →L[ℝ] A) + {L : ℕ} (σ : Fin L → Bool) + (hT : ∀ f : Fin L → α, + ((FreeGroup.reduce (tupleWord σ f)).map Prod.fst).Nodup → T (u (wordOf σ f)) = 0) : + T (allSum u σ) = T (∑ q ∈ range (L+1), badSum u σ q) := by + classical + rw [sum_badSum,allSum,map_sum,map_sum] + rw [sum_filter] + apply sum_congr rfl + intro f _ + split_ifs with h + · exact hT f h + · rfl + +variable [PartialOrder A] [StarOrderedRing A] +open scoped ComplexOrder + +lemma tendsto_map_allSum (τ : A →ₚ[ℂ] ℂ) + (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) + (h1 : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) + (hfree : ∀ r g, g ≠ 1 → τ (u r g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (T : A →L[ℝ] A) {L : ℕ} (hL : 0 < L) (σ : Fin L → Bool) + (hT : ∀ r (f : Fin L → Fin (r+1)), + ((FreeGroup.reduce (tupleWord σ f)).map Prod.fst).Nodup → T (u r (wordOf σ f)) = 0) : + Tendsto (fun r => T (normalizer (r+1) L • allSum (u r) σ)) atTop (nhds 0) := by + have he (r : ℕ) : T (normalizer (r+1) L • allSum (u r) σ) = + T (∑ q ∈ range (L+1),normalizer (r+1) L • badSum (u r) σ q) := by + rw [map_smul,map_allSum_eq_badSum (u r) T σ (hT r),← map_smul,smul_sum] + simp_rw [he] + simpa only [map_zero,Function.comp_def] using T.continuous.tendsto 0 |>.comp + (tendsto_total_badSum τ u h1 hu hfree htr hf hL σ) + +end +end HochschildBlockAssembly + +namespace HochschildWordEval +noncomputable section +open Finset HochschildCollision HochschildBlockError HochschildBlockAssembly HochschildFreeSums +variable {A : Type*} [CStarAlgebra A] + +def letter (s : A) (b : Bool) : A := if b then s else star s + +def eval (s : A) (σ : List Bool) : A := (σ.map (letter s)).prod + +@[simp] lemma eval_nil (s : A) : eval s [] = 1 := rfl +@[simp] lemma eval_cons (s : A) (b : Bool) (σ : List Bool) : + eval s (b::σ) = letter s b * eval s σ := rfl +@[simp] lemma eval_append (s : A) (σ ρ : List Bool) : + eval s (σ++ρ) = eval s σ * eval s ρ := by simp [eval,List.prod_append] + +lemma letter_smul (c : ℝ) (s : A) (b : Bool) : letter (c • s) b = c • letter s b := by + cases b <;> simp [letter,star_smul] + +lemma eval_smul (c : ℝ) (s : A) (σ : List Bool) : + eval (c • s) σ = c^σ.length • eval s σ := by + induction σ with + | nil => simp + | cons b σ ih => simp only [eval_cons,letter_smul,ih,List.length_cons,smul_mul_smul,pow_succ'] + +variable {α : Type*} [Fintype α] + +lemma letter_sum (s : α → A) (b : Bool) : letter (∑ i, s i) b = ∑ i, letter (s i) b := by + cases b <;> simp [letter,star_sum] + +omit [Fintype α] in +lemma wordOf_cons (b : Bool) (σ : List Bool) (f : Fin (σ.length+1) → α) : + wordOf (fun i => (b::σ)[i]) f = FreeGroup.mk [(f 0,b)] * + wordOf (fun i => σ[i]) (fun i => f i.succ) := by + simp only [wordOf,tupleWord,List.ofFn_succ,FreeGroup.mul_mk] + rfl + +omit [Fintype α] in +lemma map_singleton (u : FreeGroup α →* A) (hu : ∀ g, star (u g) = u g⁻¹) + (i : α) (b : Bool) : u (FreeGroup.mk [(i,b)]) = letter (u (FreeGroup.of i)) b := by + cases b + · simpa only [letter,Bool.false_eq_true,↓reduceIte,FreeGroup.of,FreeGroup.inv_mk,FreeGroup.invRev,List.map_cons,List.map_nil,List.reverse_cons,List.reverse_nil,List.nil_append,Bool.not_true] using (hu (FreeGroup.of i)).symm + · rfl + +lemma allSum_cons (u : FreeGroup α →* A) (hu : ∀ g, star (u g) = u g⁻¹) + (b : Bool) (σ : List Bool) : + allSum u (fun i => (b::σ)[i]) = + (∑ i, letter (u (FreeGroup.of i)) b) * allSum u (fun i => σ[i]) := by + classical + unfold allSum + calc + _ = ∑ p : α × (Fin σ.length → α), + u (wordOf (fun i => (b::σ)[i]) (Fin.cons p.1 p.2)) := + (Fintype.sum_equiv (Fin.consEquiv (fun _ : Fin (σ.length+1) => α)) _ _ (fun _ => rfl)).symm + _ = _ := by + rw [Fintype.sum_prod_type,sum_mul] + apply sum_congr rfl + intro i _ + rw [mul_sum] + apply sum_congr rfl + intro f _ + rw [wordOf_cons,map_mul,map_singleton u hu] + rfl + +lemma eval_sum_eq (u : FreeGroup α →* A) (hu : ∀ g, star (u g) = u g⁻¹) + (σ : List Bool) : eval (∑ i, u (FreeGroup.of i)) σ = allSum u (fun i => σ[i]) := by + classical + induction σ with + | nil => simp [allSum,wordOf,tupleWord,← FreeGroup.one_eq_mk] + | cons b σ ih => rw [eval_cons,letter_sum,ih,allSum_cons u hu] + +lemma eval_freeSum (u : FreeGroup α →* A) (hu : ∀ g, star (u g) = u g⁻¹) + (σ : List Bool) : + eval (freeSum u) σ = normalizer (Fintype.card α) σ.length • allSum u (fun i => σ[i]) := by + rw [freeSum,eval_smul,eval_sum_eq u hu] + rfl + +end +end HochschildWordEval + +namespace HochschildGoodPatterns +noncomputable section +open HochschildCatalanWords HochschildBlockWords HochschildWordEval + + +def Good (b : Bool) (σ : List Bool) : Prop := + ∀ (α : Type) [DecidableEq α] (w : List (α × Bool)), + w.map Prod.snd = σ → Ends b (FreeGroup.reduce w) + +def alt (b : Bool) : ℕ → List Bool + | 0 => [] + | n+1 => b :: alt (!b) n + +@[simp] lemma length_alt (b : Bool) (n : ℕ) : (alt b n).length = n := by + induction n generalizing b with + | zero => rfl + | succ n ih => simp [alt,ih] + +lemma signed_fst {α : Type*} (b : Bool) (l : List α) : (signed b l).map Prod.fst = l := by + induction l generalizing b with + | nil => rfl + | cons a l ih => simp [signed,ih] + +lemma signed_snd {α : Type*} (b : Bool) (l : List α) : + (signed b l).map Prod.snd = alt b l.length := by + induction l generalizing b with + | nil => rfl + | cons a l ih => simp [signed,alt,ih] + +lemma good_alt (b : Bool) (d : ℕ) : Good b (alt b (2*d+1)) := by + intro α _ w hw + have hlen : w.length = 2*d+1 := by + simpa only [List.length_map,length_alt] using congrArg List.length hw + have he : signed b (w.map Prod.fst) = w := by + apply (List.zip_of_prod (signed_fst b _) ?_).trans + · exact (List.zip_of_prod rfl rfl).symm + · rw [signed_snd,List.length_map,hlen,← hw] + rw [← he] + exact reduce_signed_odd_ends _ (by simp only [List.length_map,hlen]; omega) b + +lemma good_append {b : Bool} {σ ρ : List Bool} (hσ : Good b σ) (hρ : Good b ρ) : + Good b (σ++ρ) := by + intro α _ w hw + obtain ⟨l,k,rfl,hl,hk⟩ := List.map_eq_append_iff.mp hw + exact (reduce_append_odd_blocks l k (hσ α l hl) (hρ α k hk)).2 + +lemma good_length_pos {b : Bool} {σ : List Bool} (hσ : Good b σ) : 0 < σ.length := by + by_contra h + have he : σ = [] := List.length_eq_zero_iff.mp (by omega) + obtain ⟨⟨a,l,ha⟩,_⟩ := hσ Unit [] he.symm + simp at ha + +def invPattern (σ : List Bool) : List Bool := (σ.map Bool.not).reverse + +@[simp] lemma invPattern_invPattern (σ : List Bool) : invPattern (invPattern σ) = σ := by + simp [invPattern,List.map_reverse,List.map_map,Function.comp_def] + +lemma invRev_snd {α : Type*} (w : List (α × Bool)) : + (FreeGroup.invRev w).map Prod.snd = invPattern (w.map Prod.snd) := by + simp [FreeGroup.invRev,invPattern,List.map_reverse,List.map_map,Function.comp_def] + +lemma ends_invRev {α : Type*} {b : Bool} {w : List (α × Bool)} (hw : Ends b w) : + Ends (!b) (FreeGroup.invRev w) := by + rcases hw with ⟨⟨a,l,ha⟩,⟨k,c,hc⟩⟩ + constructor + · refine ⟨c,FreeGroup.invRev k,?_⟩ + rw [hc,FreeGroup.invRev_append] + simp [FreeGroup.invRev] + · refine ⟨FreeGroup.invRev l,a,?_⟩ + rw [ha,FreeGroup.invRev_cons] + rfl + +lemma good_inv {b : Bool} {σ : List Bool} (hσ : Good b σ) : Good (!b) (invPattern σ) := by + intro α _ w hw + have hg := hσ α (FreeGroup.invRev w) (by rw [invRev_snd,hw,invPattern_invPattern]) + have hh := ends_invRev hg + simpa only [FreeGroup.reduce_invRev,FreeGroup.invRev_invRev] using hh + +variable {A : Type*} [CStarAlgebra A] + +lemma letter_not (s : A) (b : Bool) : letter s (!b) = star (letter s b) := by + cases b <;> simp [letter] + +lemma eval_inv (s : A) (σ : List Bool) : eval s (invPattern σ) = star (eval s σ) := by + induction σ with + | nil => simp [invPattern] + | cons b σ ih => + simp only [invPattern,List.map_cons,List.reverse_cons] + rw [eval_append] + change eval s (invPattern σ) * eval s [!b] = _ + rw [ih,eval_cons,eval_nil,mul_one,letter_not,eval_cons,star_mul] + +lemma eval_alt (s : A) (b : Bool) (d : ℕ) : + eval s (alt b (2*d+1)) = letter s b * (letter s (!b) * letter s b)^d := by + induction d with + | zero => simp [alt] + | succ d ih => + have he : 2*(d+1)+1 = (2*d+1)+1+1 := by omega + rw [he,alt,alt,Bool.not_not,eval_cons,eval_cons,ih,pow_succ'] + simp only [mul_assoc] + +end +end HochschildGoodPatterns + +namespace HochschildBlockSpan +noncomputable section +open Filter Topology HochschildWordEval HochschildGoodPatterns +open scoped Polynomial +variable {A : Type*} [CStarAlgebra A] + + +def span (s : ℕ → A) (b : Bool) : Submodule ℝ (ℕ → A) := + Submodule.span ℝ {f | ∃ σ, Good b σ ∧ f = fun r => eval (s r) σ} + +lemma generator_mem (s : ℕ → A) {b : Bool} {σ : List Bool} (hσ : Good b σ) : + (fun r => eval (s r) σ) ∈ span s b := Submodule.subset_span ⟨σ,hσ,rfl⟩ + +lemma mul_mem (s : ℕ → A) (b : Bool) {x y : ℕ → A} (hx : x ∈ span s b) (hy : y ∈ span s b) : + x*y ∈ span s b := by + refine Submodule.span_induction₂ (p := fun x y _ _ => x*y ∈ span s b) ?_ ?_ ?_ ?_ ?_ ?_ ?_ hx hy + · rintro x y ⟨σ,hσ,rfl⟩ ⟨ρ,hρ,rfl⟩ + apply Submodule.subset_span + refine ⟨σ++ρ,good_append hσ hρ,?_⟩ + funext r + exact (eval_append (s r) σ ρ).symm + · intro y _ + simpa only [zero_mul] using (span s b).zero_mem + · intro x _ + simpa only [mul_zero] using (span s b).zero_mem + · intro x y z _ _ _ ihx ihy + rw [add_mul] + exact (span s b).add_mem ihx ihy + · intro x y z _ _ _ ihy ihz + rw [mul_add] + exact (span s b).add_mem ihy ihz + · intro c x y _ _ ih + rw [smul_mul_assoc] + exact (span s b).smul_mem c ih + · intro c x y _ _ ih + rw [mul_smul_comm] + exact (span s b).smul_mem c ih + +lemma pow_mem (s : ℕ → A) (b : Bool) {x : ℕ → A} (hx : x ∈ span s b) + (k : ℕ) (hk : 0 < k) : x^k ∈ span s b := by + obtain ⟨n,rfl⟩ := Nat.exists_eq_succ_of_ne_zero hk.ne' + induction n with + | zero => simpa using hx + | succ n ih => simpa only [pow_succ] using mul_mem s b (ih (Nat.succ_pos _)) hx + +lemma star_mem (s : ℕ → A) (b : Bool) {x : ℕ → A} (hx : x ∈ span s b) : + star x ∈ span s (!b) := by + induction hx using Submodule.span_induction with + | mem f hf => + obtain ⟨σ,hσ,rfl⟩ := hf + apply Submodule.subset_span + refine ⟨invPattern σ,good_inv hσ,?_⟩ + funext r + exact (eval_inv (s r) σ).symm + | zero => simp + | add x y hx hy ihx ihy => + rw [star_add] + exact (span s (!b)).add_mem ihx ihy + | smul c x hx ih => + rw [star_smul,star_trivial] + exact (span s (!b)).smul_mem c ih + +lemma polynomial_block_mem (s : ℕ → A) (p : ℝ[X]) : + (fun r => s r * Polynomial.aeval (star (s r)*s r) p) ∈ span s true := by + induction p using Polynomial.induction_on' with + | add p q hp hq => + simpa only [map_add,mul_add,Pi.add_def] using (span s true).add_mem hp hq + | monomial n c => + have hg := (span s true).smul_mem c (generator_mem s (good_alt true n)) + simpa only [Pi.smul_def,eval_alt,letter,Bool.not_true,↓reduceIte, + Bool.false_eq_true,Polynomial.aeval_monomial,← Algebra.smul_def,mul_smul_comm] using hg + +lemma polarApprox_mem (s : ℕ → A) (n : ℕ) : + (fun r => HochschildNewtonPolar.polarApprox (s r) n) ∈ span s true := + polynomial_block_mem s (HochschildNewtonPolar.polarPoly n) + +variable [PartialOrder A] [StarOrderedRing A] +open scoped ComplexOrder + +lemma tendsto_eval_of_good (τ : A →ₚ[ℂ] ℂ) + (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) + (h1 : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) + (hfree : ∀ r g, g ≠ 1 → τ (u r g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (T : A →L[ℝ] A) (b : Bool) + (hT : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends b g.toWord → T (u r g) = 0) + (σ : List Bool) (hσ : Good b σ) : + Tendsto (fun r => T (eval (HochschildFreeSums.freeSum (u r)) σ)) atTop (nhds 0) := by + simp_rw [eval_freeSum _ (hu _), Fintype.card_fin] + apply HochschildBlockAssembly.tendsto_map_allSum τ u h1 hu hfree htr hf T (good_length_pos hσ) + intro r f hnodup + apply hT r _ + · simpa only [HochschildBlockError.wordOf,FreeGroup.toWord_mk] using hnodup + · rw [HochschildBlockError.wordOf,FreeGroup.toWord_mk] + apply hσ (Fin (r+1)) + simp only [HochschildCollision.tupleWord,List.map_ofFn,Function.comp_def] + exact List.ofFn_get σ + +lemma tendsto_of_mem (τ : A →ₚ[ℂ] ℂ) + (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) + (h1 : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) + (hfree : ∀ r g, g ≠ 1 → τ (u r g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (T : A →L[ℝ] A) (b : Bool) + (hT : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends b g.toWord → T (u r g) = 0) + {x : ℕ → A} (hx : x ∈ span (fun r => HochschildFreeSums.freeSum (u r)) b) : + Tendsto (fun r => T (x r)) atTop (nhds 0) := by + induction hx using Submodule.span_induction with + | mem f hf' => + obtain ⟨σ,hσ,rfl⟩ := hf' + exact tendsto_eval_of_good τ u h1 hu hfree htr hf T b hT σ hσ + | zero => simp only [Pi.zero_apply,map_zero]; exact tendsto_const_nhds + | add x y hx hy ihx ihy => simpa only [Pi.add_apply,map_add,add_zero] using ihx.add ihy + | smul c x hx ih => simpa only [Pi.smul_apply,map_smul,smul_zero] using ih.const_smul c + +end +end HochschildBlockSpan +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CStarQuotients.lean b/lean/OAI/Analysis/BoundedHochschild/CStarQuotients.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0dce1eb728e1a7c035f085715426cef42a8ea9f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CStarQuotients.lean @@ -0,0 +1,170 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.BlockSpans + +namespace OAI + +/-! C-star quotients by star-closed ideals. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric + +namespace HochschildCStarQuotient +variable {A : Type*} [CStarAlgebra A] + +class StarClosed (I : Ideal A) : Prop where + star_mem {x : A} : x ∈ I → star x ∈ I + +variable (I : Ideal A) [I.IsTwoSided] + +lemma norm_mk_le (x : A) : ‖Ideal.Quotient.mk I x‖ ≤ ‖x‖ := + Submodule.Quotient.norm_mk_le I x + +lemma norm_mk_lt (x : A ⧸ I) {ε : ℝ} (hε : 0 < ε) : + ∃ a : A, Ideal.Quotient.mk I a = x ∧ ‖a‖ < ‖x‖ + ε := + QuotientAddGroup.exists_norm_mk_lt x hε + +instance quotientSeminormedRing : SeminormedRing (A ⧸ I) where + dist_eq := dist_eq_norm_neg_add + norm_mul_le x y := le_of_forall_pos_le_add fun ε hε => by + have := ((nhds_basis_ball.prod_nhds nhds_basis_ball).tendsto_iff nhds_basis_ball).mp + (continuous_mul.tendsto (‖x‖, ‖y‖)) ε hε + simp only [Set.mem_prod, Metric.mem_ball, and_imp, Prod.forall, Prod.exists] at this + rcases this with ⟨ε₁, ε₂, ⟨h₁, h₂⟩, h⟩ + obtain ⟨⟨a, rfl, ha⟩, ⟨b, rfl, hb⟩⟩ := norm_mk_lt I x h₁, norm_mk_lt I y h₂ + simp only [dist, abs_sub_lt_iff] at h + specialize h ‖a‖ ‖b‖ ⟨by linarith, by linarith [norm_mk_le I a]⟩ + ⟨by linarith, by linarith [norm_mk_le I b]⟩ + calc + _ ≤ ‖a‖ * ‖b‖ := (norm_mk_le I (a*b)).trans (norm_mul_le a b) + _ ≤ _ := (sub_lt_iff_lt_add'.mp h.1).le + +instance quotientNormedRing [IsClosed (I : Set A)] : NormedRing (A ⧸ I) := + { quotientSeminormedRing I, Submodule.Quotient.normedAddCommGroup I with } + +instance quotientNormedAlgebra : NormedAlgebra ℂ (A ⧸ I) := + { Submodule.Quotient.normedSpace I ℂ, Ideal.Quotient.algebra ℂ with } + +variable [StarClosed I] + +instance quotientStar : Star (A ⧸ I) where + star := Quotient.map' star fun a b hab => by + rw [Submodule.quotientRel_def] at hab ⊢ + simpa only [star_sub] using StarClosed.star_mem (I := I) hab + +@[simp] lemma star_mk (a : A) : star (Ideal.Quotient.mk I a) = Ideal.Quotient.mk I (star a) := rfl + +instance quotientStarRing : StarRing (A ⧸ I) where + star_involutive x := by + obtain ⟨a,rfl⟩ := Ideal.Quotient.mk_surjective x + simp + star_mul x y := by + obtain ⟨a,rfl⟩ := Ideal.Quotient.mk_surjective x + obtain ⟨b,rfl⟩ := Ideal.Quotient.mk_surjective y + simp only [← map_mul, star_mk, star_mul] + star_add x y := by + obtain ⟨a,rfl⟩ := Ideal.Quotient.mk_surjective x + obtain ⟨b,rfl⟩ := Ideal.Quotient.mk_surjective y + simp only [← map_add, star_mk, star_add] + +instance quotientStarModule : StarModule ℂ (A ⧸ I) where + star_smul r x := by + obtain ⟨a,rfl⟩ := Ideal.Quotient.mk_surjective x + change Ideal.Quotient.mk I (star (r • a)) = Ideal.Quotient.mk I (star r • star a) + rw [star_smul] + +lemma norm_star_le (x : A ⧸ I) : ‖star x‖ ≤ ‖x‖ := by + apply le_of_forall_pos_le_add + intro ε hε + obtain ⟨a,rfl,ha⟩ := norm_mk_lt I x hε + exact (norm_mk_le I (star a)).trans (by simpa only [norm_star] using ha.le) + +instance quotientNormedStarGroup : NormedStarGroup (A ⧸ I) where + norm_star_le := norm_star_le I + + +def starSubalgebra : NonUnitalStarSubalgebra ℂ A where + carrier := I + zero_mem' := I.zero_mem + add_mem' := I.add_mem + mul_mem' := fun _ hy => I.mul_mem_left _ hy + smul_mem' := fun r x hx => by + change r • x ∈ I + rw [Algebra.smul_def] + exact I.mul_mem_left _ hx + star_mem' := StarClosed.star_mem + +instance starSubalgebra_closed [h : IsClosed (I : Set A)] : + IsClosed (starSubalgebra I : Set A) := h + +omit [I.IsTwoSided] in + +lemma exists_cut [IsClosed (I : Set A)] (b : A) (hb : b ∈ I) {ε : ℝ} (hε : 0 < ε) : + ∃ e : A, e ∈ I ∧ star e = e ∧ ‖1-e‖ ≤ 1 ∧ ‖b-b*e‖ < ε := by + let oa := CStarAlgebra.spectralOrder A + let osa := CStarAlgebra.spectralOrderedRing A + let S := starSubalgebra I + let os := CStarAlgebra.spectralOrder S + let oss := CStarAlgebra.spectralOrderedRing S + let b' : S := ⟨b,hb⟩ + have hi := CStarAlgebra.increasingApproximateUnit S + have hd : ∀ᶠ e : S in CStarAlgebra.approximateUnit S, ‖b'-b'*e‖ < ε := by + have ht := ((tendsto_const_nhds (x := b')).sub (hi.tendsto_mul_left b')).norm + simpa only [sub_self, norm_zero] using ht.eventually (gt_mem_nhds (by simpa only [sub_self, norm_zero] using hε)) + obtain ⟨e,he₀,he₁,he₂⟩ := (hi.eventually_nonneg.and (hi.eventually_norm.and hd)).exists + have hepos : 0 ≤ (e:A) := by + simpa using (@NonUnitalStarRingHom.map_le_map_of_map_star S A _ os _ oss _ oa _ osa + (NonUnitalStarRingHom.ofClass (NonUnitalStarSubalgebraClass.subtype S)) 0 e he₀) + have henorm : ‖(e:A)‖ ≤ 1 := he₁ + have heone : (e:A) ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ hepos).mp henorm + refine ⟨e,e.property,hepos.isSelfAdjoint.star_eq,?_,he₂⟩ + exact (CStarAlgebra.norm_le_one_iff_of_nonneg (1-(e:A)) (sub_nonneg.mpr heone)).mpr + (sub_le_self _ hepos) + +lemma quotient_cstar [IsClosed (I : Set A)] (x : A ⧸ I) : + ‖x‖ * ‖x‖ ≤ ‖star x*x‖ := by + obtain ⟨a,rfl⟩ := Ideal.Quotient.mk_surjective x + rw [star_mk, ← map_mul] + apply QuotientAddGroup.le_norm_iff.mpr + intro t ht + apply le_of_forall_pos_le_add + intro ε hε + have hb : t-star a*a ∈ I := (Ideal.Quotient.eq).mp ht + obtain ⟨e,he,hes,hen,heb⟩ := exists_cut I (t-star a*a) hb hε + have hqe : Ideal.Quotient.mk I e = 0 := (Ideal.Quotient.eq_zero_iff_mem).mpr he + have hx : Ideal.Quotient.mk I (a*(1-e)) = Ideal.Quotient.mk I a := by + simp only [map_mul,map_sub,map_one,hqe,sub_zero,mul_one] + calc + ‖Ideal.Quotient.mk I a‖ * ‖Ideal.Quotient.mk I a‖ ≤ ‖a*(1-e)‖ * ‖a*(1-e)‖ := by + apply mul_self_le_mul_self (norm_nonneg _) + rw [← hx] + exact norm_mk_le I _ + _ = ‖(1-e)*(star a*a)*(1-e)‖ := by + rw [← CStarRing.norm_star_mul_self] + simp only [star_mul,star_sub,star_one,hes,mul_assoc] + _ = ‖(1-e)*t*(1-e)-(1-e)*((t-star a*a)-(t-star a*a)*e)‖ := by + congr 1 + noncomm_ring + _ ≤ ‖(1-e)*t*(1-e)‖ + ‖(1-e)*((t-star a*a)-(t-star a*a)*e)‖ := norm_sub_le _ _ + _ ≤ ‖t‖ + ε := by + apply add_le_add + · calc + _ ≤ ‖1-e‖*‖t‖*‖1-e‖ := (norm_mul_le _ _).trans + (mul_le_mul_of_nonneg_right (norm_mul_le _ _) (norm_nonneg _)) + _ ≤ 1*‖t‖*1 := by gcongr + _ = _ := by ring + · calc + _ ≤ ‖1-e‖*‖(t-star a*a)-(t-star a*a)*e‖ := norm_mul_le _ _ + _ ≤ 1*‖(t-star a*a)-(t-star a*a)*e‖ := + mul_le_mul_of_nonneg_right hen (norm_nonneg _) + _ ≤ ε := by simpa using heb.le + +instance quotientCStarAlgebra [IsClosed (I : Set A)] : CStarAlgebra (A ⧸ I) where + norm_mul_self_le := quotient_cstar I + +end HochschildCStarQuotient +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Catalan.lean b/lean/OAI/Analysis/BoundedHochschild/Catalan.lean new file mode 100644 index 0000000000000000000000000000000000000000..e80905fe3e880a4cb228ee8dee2499321d0aa3a9 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Catalan.lean @@ -0,0 +1,208 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.Haagerup +import OAI.Analysis.BoundedHochschild.HarmonicSums + +namespace OAI + +/-! Catalan functionals, cutoff decay and positive tracial moments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildCatalan +open Polynomial +noncomputable section + +lemma catalan_ratio (n : ℕ) : + ((n:ℝ)+2) * catalan (n+1) = (4*n+2) * catalan n := by + have h₁ := Nat.succ_mul_centralBinom_succ n + rw [← succ_mul_catalan_eq_centralBinom (n+1), + ← succ_mul_catalan_eq_centralBinom n] at h₁ + have h₂ : (n+1) * ((n+2)*catalan (n+1)) = + (n+1) * ((4*n+2)*catalan n) := by nlinarith [h₁] + have h₃ := Nat.eq_of_mul_eq_mul_left (by omega : 0 < n+1) h₂ + exact_mod_cast h₃ + +def catalanDifferential : ℝ[X] →ₗ[ℝ] ℝ[X] := + (LinearMap.mulLeft ℝ (X*(C 4-X))).comp derivative + + LinearMap.mulLeft ℝ (C 2-C 2*X) + +lemma catalanDifferential_apply (p : ℝ[X]) : + catalanDifferential p = X*(C 4-X)*derivative p + (C 2-C 2*X)*p := rfl + +lemma catalanDifferential_X_pow (n : ℕ) : + catalanDifferential (X^n) = (4*(n:ℝ)+2) • X^n - ((n:ℝ)+2) • X^(n+1) := by + cases n with + | zero => simp [catalanDifferential_apply, smul_eq_C_mul] + | succ n => + simp only [catalanDifferential_apply, derivative_X_pow, Nat.add_sub_cancel, + smul_eq_C_mul, Nat.cast_add, Nat.cast_one, map_add, map_mul, map_ofNat] + simp only [pow_succ] + ring + + + +lemma differential_moment_zero (L : ℝ[X] →ₗ[ℝ] ℝ) + (hL : ∀ n, L (X^n) = catalan n) (p : ℝ[X]) : + L (catalanDifferential p) = 0 := by + have h (n : ℕ) : L (catalanDifferential (X^n)) = 0 := by + rw [catalanDifferential_X_pow, map_sub, map_smul, map_smul, hL, hL] + simpa only [smul_eq_mul, sub_eq_zero] using (catalan_ratio n).symm + induction p using Polynomial.induction_on' with + | add p q hp hq => simp only [map_add, hp, hq, add_zero] + | monomial n c => + rw [← C_mul_X_pow_eq_monomial, ← smul_eq_C_mul, map_smul, map_smul, h, smul_zero] + +def cutoff : ℝ[X] := 1 - C (1/4) * X + +lemma catalanDifferential_cutoff_pow (n : ℕ) : + catalanDifferential (cutoff ^ n) = + (4*(n:ℝ)+8) • cutoff^(n+1) - (4*(n:ℝ)+6) • cutoff^n := by + have h : (4:ℝ[X]) * C (1/4:ℝ) = 1 := by + rw [← map_ofNat C 4, ← map_mul]; norm_num + cases n with + | zero => + simp [catalanDifferential_apply, cutoff, smul_eq_C_mul] + simp only [map_ofNat] + simp only [one_div] at h + linear_combination 2*X*h + | succ n => + simp only [catalanDifferential_apply, derivative_pow, Nat.add_sub_cancel, + smul_eq_C_mul, Nat.cast_add, Nat.cast_one, map_add, map_mul, map_ofNat] + simp only [cutoff, derivative_sub, derivative_one, derivative_mul, derivative_C, + derivative_X, zero_mul, mul_one, zero_add, zero_sub] + simp only [pow_succ] + norm_num + linear_combination ((1-X*C (1/4:ℝ))^n * + (2*X-X^2*((n:ℝ[X])+3)*C (1/4:ℝ)))*h + +lemma cutoff_recurrence (L : ℝ[X] →ₗ[ℝ] ℝ) (hL : ∀ n, L (X^n) = catalan n) + (n : ℕ) : + (2*(n:ℝ)+4)* L (cutoff^(n+1)) = (2*(n:ℝ)+3)* L (cutoff^n) := by + have h := differential_moment_zero L hL (cutoff^n) + rw [catalanDifferential_cutoff_pow, map_sub, map_smul, map_smul] at h + simp only [smul_eq_mul] at h + linarith + + +lemma cutoff_moment_sq_le (L : ℝ[X] →ₗ[ℝ] ℝ) (hL : ∀ n, L (X^n) = catalan n) + (n : ℕ) : ((n:ℝ)+2) * (L (cutoff^n))^2 ≤ 2 := by + induction n with + | zero => + have h := hL 0 + simp only [pow_zero, catalan_zero, Nat.cast_one] at h + simp [h] + | succ n ih => + have hrec := cutoff_recurrence L hL n + have hsq : (2*(n:ℝ)+4)^2 * (L (cutoff^(n+1)))^2 = + (2*(n:ℝ)+3)^2 * (L (cutoff^n))^2 := by + exact (_root_.mul_pow _ _ 2).symm.trans + ((congrArg (fun x : ℝ => x^2) hrec).trans (_root_.mul_pow _ _ 2)) + have hc : ((n:ℝ)+3)*(2*(n:ℝ)+3)^2 ≤ ((n:ℝ)+2)*(2*(n:ℝ)+4)^2 := by + nlinarith [Nat.cast_nonneg (α := ℝ) n] + have hp : 0 < (2*(n:ℝ)+4)^2 := by positivity + simp only [Nat.cast_add, Nat.cast_one] + apply (mul_le_mul_iff_right₀ hp).mp + calc + _ = ((n:ℝ)+3)*((2*(n:ℝ)+4)^2 * (L (cutoff^(n+1)))^2) := by ring + _ = ((n:ℝ)+3)*((2*(n:ℝ)+3)^2 * (L (cutoff^n))^2) := by rw [hsq] + _ ≤ (((n:ℝ)+2)*(2*(n:ℝ)+4)^2) * (L (cutoff^n))^2 := by + nlinarith [mul_le_mul_of_nonneg_right hc (sq_nonneg (L (cutoff^n)))] + _ = (2*(n:ℝ)+4)^2 * (((n:ℝ)+2) * (L (cutoff^n))^2) := by ring + _ ≤ (2*(n:ℝ)+4)^2 * 2 := mul_le_mul_of_nonneg_left ih hp.le + +open Filter Topology in + + +theorem cutoff_moment_tendsto_zero (L : ℝ[X] →ₗ[ℝ] ℝ) + (hL : ∀ n, L (X^n) = catalan n) : + Tendsto (fun n => L (cutoff^n)) atTop (𝓝 0) := by + have hb (n : ℕ) : (L (cutoff^n))^2 ≤ 2/((n:ℝ)+2) := by + exact (le_div_iff₀ (by positivity : 0 < (n:ℝ)+2)).mpr + (by simpa only [mul_comm] using cutoff_moment_sq_le L hL n) + have hsq : Tendsto (fun n => L (cutoff^n)^2) atTop (𝓝 0) := by + apply squeeze_zero (fun n => sq_nonneg _) hb + exact tendsto_const_nhds.div_atTop + (tendsto_atTop_add_const_right atTop 2 (tendsto_natCast_atTop_atTop (R := ℝ))) + apply tendsto_zero_iff_norm_tendsto_zero.mpr + simpa only [Real.sqrt_sq_eq_abs, Real.sqrt_zero, Real.norm_eq_abs] using hsq.sqrt + +section Trace +open scoped ComplexOrder +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) +open HochschildRigidity + + +def momentFunctional (a : A) : ℝ[X] →ₗ[ℝ] ℝ := + Complex.reLm.comp ((τ.toLinearMap.restrictScalars ℝ).comp (aeval a).toLinearMap) + +omit [StarOrderedRing A] in +lemma momentFunctional_apply (a : A) (p : ℝ[X]) : + momentFunctional τ a p = (τ (aeval a p)).re := rfl + +omit [StarOrderedRing A] in +lemma momentFunctional_X_pow (a : A) (n : ℕ) : + momentFunctional τ a (X^n) = (τ (a^n)).re := by + rw [momentFunctional_apply, aeval_X_pow] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma aeval_cutoff (a : A) : aeval a cutoff = 1 - (1/4:ℝ) • a := by + simp [cutoff, Algebra.smul_def] + +omit [StarOrderedRing A] in +open Filter Topology in +lemma cutoff_trace_tendsto_zero (a : A) (hm : ∀ n, (τ (a^n)).re = catalan n) : + Tendsto (fun n => (τ ((1 - (1/4:ℝ) • a)^n)).re) atTop (𝓝 0) := by + have h := cutoff_moment_tendsto_zero (momentFunctional τ a) + (fun n => by rw [momentFunctional_X_pow, hm]) + simpa only [momentFunctional_apply, map_pow, aeval_cutoff] using h + +open Filter Topology in +lemma cutoff_preGNS_tendsto_zero (a : A) (ha : IsSelfAdjoint a) + (hm : ∀ n, (τ (a^n)).re = catalan n) : + Tendsto (fun n => ‖τ.toPreGNS ((1 - (1/4:ℝ) • a)^n)‖) atTop (𝓝 0) := by + have hb : IsSelfAdjoint (1 - (1/4:ℝ) • a) := + (IsSelfAdjoint.one A).sub ((IsSelfAdjoint.all _).smul ha) + have hs (n : ℕ) : ‖τ.toPreGNS ((1 - (1/4:ℝ) • a)^n)‖^2 = + (τ ((1 - (1/4:ℝ) • a)^(2*n))).re := by + have h := congrArg Complex.re (τ.preGNS_norm_sq + (τ.toPreGNS ((1 - (1/4:ℝ) • a)^n))) + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS, star_pow, hb.star_eq, + ← pow_add, ← Complex.ofReal_pow, Complex.ofReal_re, two_mul] using h + have ht : Tendsto (fun n : ℕ => 2*n) atTop atTop := + tendsto_atTop_mono (fun n => by dsimp; omega) tendsto_id + have hc := (cutoff_trace_tendsto_zero τ a hm).comp ht + simp only [Function.comp_def, ← hs] at hc + simpa only [Real.sqrt_sq (norm_nonneg _), Real.sqrt_zero] using hc.sqrt + +open Filter Topology in + + +theorem eq_zero_of_mul_eq_zero_of_catalan (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) (a : A) (ha : IsSelfAdjoint a) + (hm : ∀ n, (τ (a^n)).re = catalan n) (e : A) (he : a*e = 0) : e = 0 := by + have hb : (1 - (1/4:ℝ) • a)*e = e := by + rw [sub_mul, one_mul, smul_mul_assoc, he, smul_zero, sub_zero] + have hbpow (n : ℕ) : (1 - (1/4:ℝ) • a)^n * e = e := by + induction n with + | zero => simp + | succ n ih => rw [pow_succ', mul_assoc, ih, hb] + have hn (n : ℕ) : ‖τ.toPreGNS e‖ ≤ + ‖e‖ * ‖τ.toPreGNS ((1 - (1/4:ℝ) • a)^n)‖ := by + nth_rw 1 [← hbpow n] + exact preGNS_norm_mul_right_le τ htr _ _ + have ht := (cutoff_preGNS_tendsto_zero τ a ha hm).const_mul ‖e‖ + simp only [mul_zero] at ht + have hz : ‖τ.toPreGNS e‖ = 0 := + le_antisymm (ge_of_tendsto ht (Eventually.of_forall hn)) (norm_nonneg _) + exact (preGNS_norm_eq_zero_iff τ hf e).mp hz + +end Trace + +end +end HochschildCatalan +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CatalanWords.lean b/lean/OAI/Analysis/BoundedHochschild/CatalanWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..cedd6494fa7a963dd0488da1531fb9710a45782d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CatalanWords.lean @@ -0,0 +1,470 @@ +import Mathlib + +namespace OAI + +/-! Binary-tree enumeration of return words and normalized Catalan moments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildCatalanWords +noncomputable section +open List BinaryTree +variable {α : Type*} + + +def word : BinaryTree α → List α + | .nil => [] + | .node a l r => a :: (word l ++ a :: word r) + +@[simp] lemma length_word (t : BinaryTree α) : (word t).length = 2*t.numNodes := by + induction t with + | nil => simp [word] + | node a l r hl hr => simp [word, hl, hr]; omega + + +def unorientedReduce [DecidableEq α] : List α → List α + | [] => [] + | a::l => match unorientedReduce l with + | [] => [a] + | b::k => if a=b then k else a::b::k + + +def signed : Bool → List α → List (α × Bool) + | _, [] => [] + | b, a::l => (a,b)::signed (!b) l + +@[simp] lemma signed_eq_nil (b : Bool) (l : List α) : signed b l = [] ↔ l = [] := by + cases l <;> simp [signed] + +lemma reduce_signed [DecidableEq α] (b : Bool) (l : List α) : + FreeGroup.reduce (signed b l) = signed b (unorientedReduce l) := by + induction l generalizing b with + | nil => rfl + | cons a l ih => + simp only [signed, FreeGroup.reduce.cons, ih, unorientedReduce] + cases h : unorientedReduce l with + | nil => simp [signed] + | cons c l => + simp only [signed] + by_cases hac : a=c + · simp [hac, Bool.not_not] + · simp [hac, signed] + +def render (p : BinaryTree α × List (α × BinaryTree α)) : List α := + word p.1 ++ p.2.flatMap (fun p => p.1 :: word p.2) + + +def parse [DecidableEq α] : List α → BinaryTree α × List (α × BinaryTree α) + | [] => (.nil, []) + | a::l => match parse l with + | (t,[]) => (.nil,[(a,t)]) + | (t,(b,u)::xs) => if a=b then (.node a t u,xs) else (.nil,(a,t)::(b,u)::xs) + +lemma render_parse [DecidableEq α] (l : List α) : render (parse l) = l := by + induction l with + | nil => rfl + | cons a l ih => + rw [parse] + cases hp : parse l with + | mk t xs => + rw [hp] at ih + cases xs with + | nil => simpa [render, word] using congrArg (a :: ·) ih + | cons p xs => + rcases p with ⟨b,u⟩ + by_cases hab : a=b + · simp only [hab] + simpa [render, word, List.append_assoc] using congrArg (b :: ·) ih + · simp only [hab, ite_false] + simpa [render, word, List.append_assoc] using congrArg (a :: ·) ih + +lemma unmatched_parse [DecidableEq α] (l : List α) : + (parse l).2.map Prod.fst = unorientedReduce l := by + induction l with + | nil => rfl + | cons a l ih => + rw [parse, unorientedReduce, ← ih] + cases hp : parse l with + | mk t xs => + cases xs with + | nil => rfl + | cons p xs => + rcases p with ⟨b,u⟩ + by_cases hab : a=b <;> simp [hab] + + +theorem exists_tree_of_reduce_signed_eq_nil [DecidableEq α] + (l : List α) (b : Bool) (hl : FreeGroup.reduce (signed b l) = []) : + ∃ t : BinaryTree α, word t = l := by + rw [reduce_signed, signed_eq_nil] at hl + have h := unmatched_parse l + rw [hl, List.map_eq_nil_iff] at h + refine ⟨(parse l).1, ?_⟩ + have hp := render_parse l + simpa only [render, h, flatMap_nil, append_nil] using hp + +lemma signed_append_even {l : List α} (hl : 2 ∣ l.length) (k : List α) (b : Bool) : + signed b (l++k) = signed b l ++ signed b k := by + induction l using List.twoStepInduction generalizing b with + | nil => simp [signed] + | singleton a => simp at hl + | cons_cons a c l ih _ => + have hl' : 2 ∣ l.length := by simpa using hl + simpa [signed] using congrArg ((a,b) :: (c,!b) :: ·) (ih hl' b) + +lemma signed_word_node (a : α) (l r : BinaryTree α) (b : Bool) : + signed b (word (.node a l r)) = + (a,b) :: (signed (!b) (word l) ++ (a,!b) :: signed b (word r)) := by + simp only [word, signed] + rw [signed_append_even (by simp)]; simp [signed] + +lemma reduce_signed_word [DecidableEq α] (t : BinaryTree α) (b : Bool) : + FreeGroup.reduce (signed b (word t)) = [] := by + induction t generalizing b with + | nil => simp [word, signed] + | node a l r hl hr => + rw [signed_word_node] + have happ : FreeGroup.reduce (signed (!b) (word l) ++ (a,!b) :: signed b (word r)) = + [(a,!b)] := by + rw [← FreeGroup.reduce_append_reduce_reduce, hl] + simp [FreeGroup.reduce.cons, hr] + simp only [FreeGroup.reduce.cons, happ, Bool.not_not, and_self, ite_true] + + +def labels : BinaryTree α → List α + | .nil => [] + | .node a l r => a :: (labels l ++ labels r) + +@[simp] lemma length_labels (t : BinaryTree α) : (labels t).length = t.numNodes := by + induction t with + | nil => rfl + | node a l r hl hr => simp [labels, hl, hr] + +@[simp] lemma mem_word_iff (a : α) (t : BinaryTree α) : a ∈ word t ↔ a ∈ labels t := by + induction t with + | nil => rfl + | node b l r hl hr => simp [word, labels, hl, hr, or_left_comm] + +lemma delimiter_split {a : α} {l r l' r' : List α} + (hl : a ∉ l) (hl' : a ∉ l') (he : l ++ a::r = l' ++ a::r') : + l=l' ∧ r=r' := by + induction l generalizing l' with + | nil => + cases l' with + | nil => simpa using he + | cons b l' => + have hab : a=b := List.head_eq_of_cons_eq he + subst b + simp at hl' + | cons b l ih => + cases l' with + | nil => + have hba : b=a := List.head_eq_of_cons_eq he + subst b + simp at hl + | cons c l' => + have hbc : b=c := List.head_eq_of_cons_eq he + subst c + have he' := List.tail_eq_of_cons_eq he + obtain ⟨rfl, rfl⟩ := ih (by simpa using fun h => hl (List.mem_cons_of_mem _ h)) + (by simpa using fun h => hl' (List.mem_cons_of_mem _ h)) he' + exact ⟨rfl,rfl⟩ + + +theorem word_injective_on_nodup {t u : BinaryTree α} + (ht : (labels t).Nodup) (hu : (labels u).Nodup) (he : word t = word u) : t=u := by + induction t generalizing u with + | nil => + cases u with + | nil => rfl + | node b l r => simp [word] at he + | node a l r ihl ihr => + cases u with + | nil => simp [word] at he + | node b l' r' => + simp only [word, List.cons.injEq] at he + obtain ⟨rfl, he⟩ := he + have ht' := List.nodup_cons.mp ht + have hu' := List.nodup_cons.mp hu + have htl := List.nodup_append.mp ht'.2 + have hul := List.nodup_append.mp hu'.2 + obtain ⟨hel, her⟩ := delimiter_split + (fun h => ht'.1 (List.mem_append_left _ ((mem_word_iff _ _).mp h))) + (fun h => hu'.1 (List.mem_append_left _ ((mem_word_iff _ _).mp h))) he + rw [ihl htl.1 hul.1 hel, ihr htl.2.1 hul.2.1 her] + + +def shape : BinaryTree α → BinaryTree Unit := BinaryTree.map (fun _ => ()) + +@[simp] lemma numNodes_shape (t : BinaryTree α) : (shape t).numNodes = t.numNodes := by + induction t with + | nil => rfl + | node a l r hl hr => simpa [shape, BinaryTree.map] using congrArg₂ (fun x y=> x+y) hl hr + + +def decorate : BinaryTree Unit → List α → BinaryTree α + | .nil, _ => .nil + | .node _ _ _, [] => .nil + | .node _ l r, a::as => .node a (decorate l (as.take l.numNodes)) + (decorate r (as.drop l.numNodes)) + +lemma decorate_spec (t : BinaryTree Unit) (as : List α) (h : as.length=t.numNodes) : + shape (decorate t as) = t ∧ labels (decorate t as) = as := by + induction t generalizing as with + | nil => simp only [BinaryTree.numNodes] at h; have := List.length_eq_zero_iff.mp h + subst as; exact ⟨rfl,rfl⟩ + | node a l r hl hr => + cases a + cases as with + | nil => simp at h + | cons a as => + have llen : l.numNodes ≤ as.length := by simp at h; omega + obtain ⟨hls,hll⟩ := hl (as.take l.numNodes) (by simp [llen]) + obtain ⟨hrs,hrl⟩ := hr (as.drop l.numNodes) (by simp; simp at h; omega) + constructor + · simp only [decorate, shape, BinaryTree.map] + change BinaryTree.node () (shape _) (shape _) = _ + rw [hls, hrs] + · simp only [decorate, labels, hll, hrl, List.take_append_drop] + +lemma decorate_shape_labels (t : BinaryTree α) : decorate (shape t) (labels t) = t := by + induction t with + | nil => rfl + | node a l r hl hr => + change BinaryTree.node a (decorate (shape l) ((labels l ++ labels r).take (shape l).numNodes)) + (decorate (shape r) ((labels l ++ labels r).drop (shape l).numNodes)) = _ + rw [numNodes_shape, ← length_labels, List.take_left, List.drop_left, hl, hr] + +abbrev Shapes (n : ℕ) := ↥(BinaryTree.treesOfNumNodesEq n) + +@[simp] lemma card_shapes (n : ℕ) : Fintype.card (Shapes n) = catalan n := by + rw [Fintype.card_coe, treesOfNumNodesEq_card_eq_catalan] + +@[simp] lemma nodes_shape (n : ℕ) (t : Shapes n) : t.val.numNodes = n := + BinaryTree.mem_treesOfNumNodesEq.mp t.property + +def listFunction {n : ℕ} (l : List α) (h : l.length=n) : Fin n → α := + fun i => l.get (i.cast h.symm) + +@[simp] lemma ofFn_listFunction {n : ℕ} (l : List α) (h : l.length=n) : + List.ofFn (listFunction l h) = l := by + subst n + exact List.ofFn_get l + +abbrev ReturnWords (α : Type*) [DecidableEq α] (n : ℕ) := + {f : Fin (2*n) → α // FreeGroup.reduce (signed false (List.ofFn f)) = []} + +def treeFrom {n : ℕ} (t : Shapes n) (f : Fin n → α) : BinaryTree α := + decorate t.val (List.ofFn f) + +@[simp] lemma shape_treeFrom {n : ℕ} (t : Shapes n) (f : Fin n → α) : + shape (treeFrom t f) = t.val := + (decorate_spec _ _ (by simp)).1 + +@[simp] lemma labels_treeFrom {n : ℕ} (t : Shapes n) (f : Fin n → α) : + labels (treeFrom t f) = List.ofFn f := + (decorate_spec _ _ (by simp)).2 + +@[simp] lemma nodes_treeFrom {n : ℕ} (t : Shapes n) (f : Fin n → α) : + (treeFrom t f).numNodes = n := by + rw [← numNodes_shape, shape_treeFrom, nodes_shape] + +variable [DecidableEq α] + +def fromTree {n : ℕ} (p : Shapes n × (Fin n → α)) : ReturnWords α n := + ⟨listFunction (word (treeFrom p.1 p.2)) (by simp), by + rw [ofFn_listFunction]; exact reduce_signed_word _ _⟩ + +@[simp] lemma ofFn_fromTree {n : ℕ} (p : Shapes n × (Fin n → α)) : + List.ofFn (fromTree p).val = word (treeFrom p.1 p.2) := by + exact ofFn_listFunction _ (by simp) + +lemma fromTree_surjective (n : ℕ) : Function.Surjective (@fromTree α _ n) := by + intro f + obtain ⟨t,ht⟩ := exists_tree_of_reduce_signed_eq_nil _ _ f.property + have hn : t.numNodes = n := by + have h := congrArg List.length ht + simp only [length_word, List.length_ofFn] at h + omega + let s : Shapes n := ⟨shape t, by simp [hn]⟩ + let g : Fin n → α := listFunction (labels t) (by simp [hn]) + refine ⟨(s,g), Subtype.ext ?_⟩ + apply List.ofFn_injective + rw [ofFn_fromTree] + change word (decorate (shape t) (List.ofFn g)) = List.ofFn f.val + rw [ofFn_listFunction, decorate_shape_labels, ht] + +def fromDistinctTree {n : ℕ} (p : Shapes n × (Fin n ↪ α)) : ReturnWords α n := + fromTree (p.1, p.2) + +lemma fromDistinctTree_injective (n : ℕ) : + Function.Injective (@fromDistinctTree α _ n) := by + rintro ⟨s,f⟩ ⟨t,g⟩ h + have hw : word (treeFrom s f) = word (treeFrom t g) := by + have h' := congrArg (fun x : ReturnWords α n => List.ofFn x.val) h + simpa only [fromDistinctTree, ofFn_fromTree] using h' + have he := word_injective_on_nodup + (by rw [labels_treeFrom]; exact List.nodup_ofFn_ofInjective f.injective) + (by rw [labels_treeFrom]; exact List.nodup_ofFn_ofInjective g.injective) hw + have hs : s=t := Subtype.ext (by simpa only [shape_treeFrom] using congrArg shape he) + have hf : f=g := by + apply DFunLike.ext + intro i + have hh : (f : Fin n → α) = g := List.ofFn_injective + (by simpa only [labels_treeFrom] using congrArg labels he) + exact congrFun hh i + subst t; subst g; rfl + + + +theorem returnWord_count_bounds [Fintype α] (n : ℕ) : + catalan n * (Fintype.card α).descFactorial n ≤ Fintype.card (ReturnWords α n) ∧ + Fintype.card (ReturnWords α n) ≤ catalan n * (Fintype.card α)^n := by + constructor + · have h := Fintype.card_le_of_injective _ (fromDistinctTree_injective (α:=α) n) + simpa only [Fintype.card_prod, card_shapes, Fintype.card_embedding_eq, + Fintype.card_fin] using h + · have h := Fintype.card_le_of_surjective _ (fromTree_surjective (α:=α) n) + simpa only [Fintype.card_prod, card_shapes, Fintype.card_fun, Fintype.card_fin] using h + +open Filter Topology Asymptotics in + +theorem normalized_returnWord_count_tendsto (n : ℕ) : + Tendsto (fun r : ℕ => (Fintype.card (ReturnWords (Fin r) n) : ℝ) / (r:ℝ)^n) + atTop (𝓝 (catalan n : ℝ)) := by + have hz : ∀ᶠ r : ℕ in atTop, (r:ℝ)^n ≠ 0 := by + filter_upwards [eventually_ge_atTop 1] with r hr + exact pow_ne_zero _ (by exact_mod_cast (show r≠0 by omega)) + have hd := (isEquivalent_iff_tendsto_one hz).mp (isEquivalent_descFactorial n) + have hlo : Tendsto (fun r : ℕ => (catalan n : ℝ) * (r.descFactorial n : ℝ) / (r:ℝ)^n) + atTop (𝓝 (catalan n : ℝ)) := by + simpa only [Pi.div_apply, mul_one, mul_div_assoc] using hd.const_mul (catalan n : ℝ) + refine tendsto_of_tendsto_of_tendsto_of_le_of_le' hlo tendsto_const_nhds ?_ ?_ + · exact Filter.Eventually.of_forall fun r => by + apply div_le_div_of_nonneg_right _ (by positivity) + exact_mod_cast (by simpa only [Fintype.card_fin] using + (returnWord_count_bounds (α:=Fin r) n).1 : + catalan n * r.descFactorial n ≤ Fintype.card (ReturnWords (Fin r) n)) + · filter_upwards [hz] with r hr + rw [div_le_iff₀ (lt_of_le_of_ne (by positivity) (Ne.symm hr))] + exact_mod_cast (by simpa only [Fintype.card_fin] using + (returnWord_count_bounds (α:=Fin r) n).2 : + Fintype.card (ReturnWords (Fin r) n) ≤ catalan n * r^n) + +end +end HochschildCatalanWords + +namespace HochschildCatalanMoments +open HochschildCatalanWords Finset +noncomputable section +variable {α A : Type*} [Fintype α] [Ring A] +variable (u : FreeGroup α →* A) + +def signedSum (b : Bool) (n : ℕ) : A := + ∑ f : Fin n → α, u (FreeGroup.mk (signed b (List.ofFn f))) + +lemma signedSum_succ (b : Bool) (n : ℕ) : + signedSum u b (n+1) = (∑ a : α, u (FreeGroup.mk [(a,b)])) * signedSum u (!b) n := by + unfold signedSum + rw [← (Fin.consEquiv (fun _ : Fin (n+1) => α)).sum_comp, Fintype.sum_prod_type] + rw [Finset.sum_mul] + apply Finset.sum_congr rfl + intro a _ + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro f _ + simp only [Fin.consEquiv, Equiv.coe_fn_mk, List.ofFn_succ, Fin.cons_zero, Fin.cons_succ, signed] + change u (FreeGroup.mk ([(a,b)] ++ signed (!b) (List.ofFn f))) = _ + rw [← FreeGroup.mul_mk, map_mul] + +@[simp] lemma signedSum_zero (b : Bool) : signedSum u b 0 = 1 := by + simp [signedSum, signed, ← FreeGroup.one_eq_mk] + +lemma signedSum_even (n : ℕ) : + signedSum u false (2*n) = + ((∑ a : α, u (FreeGroup.mk [(a,false)])) * (∑ a : α, u (FreeGroup.of a)))^n := by + induction n with + | zero => simp + | succ n ih => + rw [show 2*(n+1) = (2*n+1)+1 by omega, signedSum_succ, signedSum_succ] + simp only [Bool.not_false, Bool.not_true, ih, pow_succ'] + change (∑ a : α, u (FreeGroup.mk [(a,false)])) * + ((∑ a : α, u (FreeGroup.of a)) * + ((∑ a : α, u (FreeGroup.mk [(a,false)])) * (∑ a : α, u (FreeGroup.of a)))^n) = _ + exact (mul_assoc _ _ _).symm + +variable [StarRing A] (hu : ∀ g, star (u g) = u g⁻¹) +include hu + +lemma sum_star : (∑ a : α, u (FreeGroup.mk [(a,false)])) = star (∑ a : α, u (FreeGroup.of a)) := by + rw [star_sum] + apply Finset.sum_congr rfl + intro a _ + rw [hu] + rfl + +lemma sum_pow_expansion (n : ℕ) : + (star (∑ a : α, u (FreeGroup.of a)) * (∑ a : α, u (FreeGroup.of a)))^n = + signedSum u false (2*n) := by + rw [signedSum_even, sum_star u hu] + +variable [DecidableEq α] [Algebra ℂ A] (τ : A →ₗ[ℂ] ℂ) (hτ : τ 1 = 1) + (hfree : ∀ g : FreeGroup α, g ≠ 1 → τ (u g) = 0) + +omit hu [Fintype α] [StarRing A] in +include hτ hfree in +lemma trace_word (l : List (α × Bool)) : + τ (u (FreeGroup.mk l)) = if FreeGroup.reduce l = [] then 1 else 0 := by + have he : FreeGroup.reduce l = [] ↔ FreeGroup.mk l = 1 := + by simpa only [FreeGroup.toWord_mk] using + (@FreeGroup.toWord_eq_nil_iff α _ (FreeGroup.mk l)) + by_cases h : FreeGroup.reduce l = [] + · simp [h, he.mp h, hτ] + · rw [ite_eq_right h] + exact hfree _ (fun hg => h (he.mpr hg)) + +include hτ hfree in +lemma trace_sum_pow (n : ℕ) : + τ ((star (∑ a : α, u (FreeGroup.of a)) * (∑ a : α, u (FreeGroup.of a)))^n) = + (Fintype.card (ReturnWords α n) : ℂ) := by + rw [sum_pow_expansion u hu, signedSum, map_sum] + simp only [trace_word u τ hτ hfree] + simp [Fintype.card_subtype, ReturnWords] + + +def positiveSum : A := (Fintype.card α : ℂ)⁻¹ • + (star (∑ a : α, u (FreeGroup.of a)) * (∑ a : α, u (FreeGroup.of a))) + +include hτ hfree in +lemma trace_positiveSum_pow (n : ℕ) : + τ ((positiveSum u)^n) = + (Fintype.card (ReturnWords α n) : ℂ) / (Fintype.card α : ℂ)^n := by + rw [positiveSum, smul_pow, map_smul, trace_sum_pow u hu τ hτ hfree] + simp only [smul_eq_mul, inv_pow, div_eq_mul_inv, mul_comm] + +include hτ hfree in +lemma re_trace_positiveSum_pow (n : ℕ) : + (τ ((positiveSum u)^n)).re = + (Fintype.card (ReturnWords α n) : ℝ) / (Fintype.card α : ℝ)^n := by + rw [trace_positiveSum_pow u hu τ hτ hfree] + simp only [← Complex.ofReal_natCast, ← Complex.ofReal_pow, ← Complex.ofReal_div, Complex.ofReal_re] + +omit [Fintype α] hu [DecidableEq α] in +open Filter Topology in + +theorem normalized_moments_tendsto + (v : (r : ℕ) → FreeGroup (Fin r) →* A) + (hv : ∀ r g, star (v r g) = v r g⁻¹) + (hτ : τ 1 = 1) (hfree : ∀ r g, g ≠ 1 → τ (v r g) = 0) (n : ℕ) : + Tendsto (fun r : ℕ => (τ ((positiveSum (v r))^n)).re) + atTop (𝓝 (catalan n : ℝ)) := by + simp_rw [re_trace_positiveSum_pow _ (hv _) τ hτ (hfree _), Fintype.card_fin] + exact normalized_returnWord_count_tendsto n + +end +end HochschildCatalanMoments +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CenterAveragingReduction.lean b/lean/OAI/Analysis/BoundedHochschild/CenterAveragingReduction.lean new file mode 100644 index 0000000000000000000000000000000000000000..bd71a9aa11e7a8ce6a0b341259b45675dd5020fb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CenterAveragingReduction.lean @@ -0,0 +1,89 @@ +import OAI.Analysis.BoundedHochschild.TracialCoverReduction +import OAI.Analysis.BoundedHochschild.FiniteNormalState +import OAI.Analysis.BoundedHochschild.CentralTypeIIInheritance + +namespace OAI + +/-! +# The precise remaining center-valued trace input + +The construction of faithful normal scalar traces is reduced to the +center-valued trace theorem for finite von Neumann algebras (Blackadar, +III.2.5.7--8). Normal states and their central supports are constructed +without this input. Only the positive normal central averaging map remains +an explicit hypothesis; the global central partition is derived. +-/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +universe u + +/-- The part of a center-valued trace used by the scalar trace construction. -/ +structure NormalCentralAverage {N Y : Type u} [CStarAlgebra N] + [PartialOrder N] [StarOrderedRing N] [NormedAddCommGroup Y] + [NormedSpace ℂ Y] [CompleteSpace Y] (e : StrongDual ℂ Y ≃ₗᵢ⋆[ℂ] N) where + map : N →L[ℂ] N + normal : HasPreadjoint e map + positive : ∀ a : N, 0 ≤ a → 0 ≤ map a + unital : map 1 = 1 + central : ∀ a b : N, map a * b = b * map a + tracial : ∀ a b : N, map (a * b) = map (b * a) + faithful : ∀ a : N, map (star a * a) = 0 → a = 0 + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Center-valued trace existence, restricted to the finite type-II central +corners needed for this application. -/ +def FiniteCentralAveragingInput (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : Prop := + ∀ (p : M) (hp : IsStarProjection p), (∀ a : M, p * a = a * p) → + FiniteAlgebra (Corner p hp) → PopaTypeII.NoTypeICentralPart (Corner p hp) → + Nonempty (NormalCentralAverage (cornerPredualEquiv p hp e)) + +/-- A center-valued trace yields the exact local scalar-trace consequence +needed by the already proved global decomposition. -/ +theorem localTracialCutInput_of_center_averaging (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (haverage : FiniteCentralAveragingInput e) : LocalTracialCutInput M := by + intro z hz hzc hzfinite hzII hz0 + obtain ⟨p, hp, hpc, hpz, hp0, hstate⟩ := + exists_central_normal_state_subprojection e hz hzc hz0 + have hpfinite : FiniteAlgebra (Corner p hp) := + (finiteCorner_iff p hp).mp + (finiteCorner_mono hp hz hpz ((finiteCorner_iff z hz).mpr hzfinite)) + have hpII : PopaTypeII.NoTypeICentralPart (Corner p hp) := + noTypeICentralPart_smaller_centralCorner hp hz hpz hpc hzII + obtain ⟨E⟩ := haverage p hp hpc hpfinite hpII + obtain ⟨ψ, hψ, hψ1, hfaith⟩ := central_faithful_state_on_corner e hp hpc hstate + let eP := cornerPredualEquiv p hp e + obtain ⟨τ, hτ, hτ1, htr, hfaithτ⟩ := tracial_state_of_normal_center_average eP + ψ hψ hψ1 hfaith E.map E.normal E.positive E.unital E.central E.tracial E.faithful + exact ⟨p, hp, hpc, hpz, hp0, CornerPredual p hp e, + inferInstance, inferInstance, inferInstance, eP, τ, hτ, htr, hfaithτ, hτ1, hpII⟩ + +/-- All central partition and scalar-trace work is discharged; only the +center-valued averaging existence input remains in the structural reduction. -/ +theorem centralDecompositionInput_of_center_averaging (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (haverage : FiniteCentralAveragingInput e) : CentralDecompositionInput M := + centralDecompositionInput_of_local_tracial_cuts e + (localTracialCutInput_of_center_averaging e haverage) + +theorem primitive_of_center_averaging (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (haverage : FiniteCentralAveragingInput e) (hclassical : ClassicalVanishingInput.{u}) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := + primitive_of_published_inputs e (centralDecompositionInput_of_center_averaging e haverage) + hclassical f hf + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CenterCommutants.lean b/lean/OAI/Analysis/BoundedHochschild/CenterCommutants.lean new file mode 100644 index 0000000000000000000000000000000000000000..1731ed165c1b98da8af2da1424b918abf8c33e32 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CenterCommutants.lean @@ -0,0 +1,117 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.CentralQuantization + +namespace OAI + +/-! Central structure of matrix commutants. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +open BoundedHochschild HochschildComparison FinitePathMain HochschildCentralQuantization +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {n : ℕ} (E : MatrixSystem M n) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_commutant_coe (b : E.commutant) (hb : ∀ x : E.commutant, Commute b x) : + ∀ x : M, Commute (b:M) x := by + intro x + rw [← E.reconstruct x] + apply Commute.sum_right + intro i hi + apply Commute.sum_right + intro j hj + exact (b.property i j).mul_right (show Commute (b:M) (E.coefficient i j x) from + congrArg (fun z : E.commutant => (z:M)) (hb ⟨_,E.coefficient_mem i j x⟩).eq) + +lemma deflate_abelian (i : Fin n) {q : E.commutant} (hq : AbelianProjection q) : + AbelianProjection (E.entry i i*(q:M)) := by + have hqM : IsStarProjection (q:M) := + ⟨congrArg (fun z : E.commutant => (z:M)) hq.1.isIdempotentElem.eq, + congrArg (fun z : E.commutant => (z:M)) hq.1.isSelfAdjoint.star_eq⟩ + let p := E.entry i i*(q:M) + have hp : IsStarProjection p := (E.diagonal_proj i).mul hqM (q.property i i).symm + have hpe : p ≤ E.entry i i := (hp.le_iff_mul_eq_right (E.diagonal_proj i)).mpr + (by dsimp [p]; rw [← mul_assoc,(E.diagonal_proj i).isIdempotentElem.eq]) + have hep : E.entry i i*p=p := (hp.le_iff_mul_eq_right (E.diagonal_proj i)).mp hpe + have hpe' : p*E.entry i i=p := (hp.le_iff_mul_eq_left (E.diagonal_proj i)).mp hpe + have hcoef (a : M) : E.coefficient i i (p*a*p)=(q:M)*E.coefficient i i a*(q:M) := by + rw [← E.coefficient_of_commutant i q.property, E.coefficient_mul,E.coefficient_mul] + change E.coefficient i i (p*a*p)=E.coefficient i i ((p*E.entry i i*a)*E.entry i i*p) + rw [hpe',mul_assoc (p*a),hep] + refine ⟨hp,?_⟩ + intro a b + have hab := congrArg (fun x : E.commutant => (x:M)) + (hq.2 ⟨_,E.coefficient_mem i i a⟩ ⟨_,E.coefficient_mem i i b⟩).eq + change ((q:M)*E.coefficient i i a*(q:M))*((q:M)*E.coefficient i i b*(q:M))= + ((q:M)*E.coefficient i i b*(q:M))*((q:M)*E.coefficient i i a*(q:M)) at hab + rw [← hcoef,← hcoef,E.coefficient_mul,E.coefficient_mul] at hab + have hleft (x : M) : E.entry i i*(p*x*p)=p*x*p := by + calc + _ = (E.entry i i*p)*x*p := by simp only [mul_assoc] + _ = _ := by rw [hep] + have hright (x : M) : (p*x*p)*E.entry i i=p*x*p := by + calc + _ = (p*x)*(p*E.entry i i) := by simp only [mul_assoc] + _ = _ := by rw [hpe'] + rw [hright,hright] at hab + have hh := congrArg (fun x : M => E.entry i i*x*E.entry i i) hab + rw [E.coefficient_corner,E.coefficient_corner] at hh + change (p*a*p)*(p*b*p)=(p*b*p)*(p*a*p) + have hreduce (x y : M) : E.entry i i*((p*x*p)*(p*y*p))*E.entry i i=(p*x*p)*(p*y*p) := by + rw [← mul_assoc (E.entry i i),hleft,mul_assoc (p*x*p),hright] + simpa only [hreduce] using hh + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in +lemma commutant_typeII1 (hn : 0 (x:M)) ha) + · intro z hz + by_contra hzne + obtain ⟨q,hq,_hqz,hq0⟩ := hz.2 z hz.1 le_rfl hzne + have hab := E.deflate_abelian ⟨0,hn⟩ hq + have hh := HochschildTypeII.no_abelian_projection e τ hτ htr hfaith hII hab + have hc := E.coefficient_of_commutant ⟨0,hn⟩ q.property + rw [hh,E.coefficient_nil] at hc + exact hq0 (Subtype.ext hc.symm) + +omit [StarOrderedRing M] in +lemma centrallyCentered_expectation (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) + {x : M} (hx : CentrallyCentered τ x) : + CentrallyCentered (E.commutantTrace τ) ⟨E.expectation x,E.commute_expectation x⟩ := by + intro z hz + have hzM := E.central_commutant_coe z hz + change τ ((z:M)*E.expectation x)=0 + have he : (z:M)*E.expectation x=E.expectation ((z:M)*x) := by + change (z:M)*((n:ℂ)⁻¹ • ∑ i,∑ j,E.entry i j*x*E.entry j i)=_ + simp only [E.expectation_apply,mul_smul_comm,Finset.mul_sum] + congr 1 + apply Finset.sum_congr rfl + intro i hi + apply Finset.sum_congr rfl + intro j hj + rw [← mul_assoc,← mul_assoc,(hzM (E.entry i j)).eq] + simp only [mul_assoc] + rw [he,E.trace_expectation τ htr hn] + exact hx z hzM + +end MatrixSystem +end HochschildMatrixSystems + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CenterCorners.lean b/lean/OAI/Analysis/BoundedHochschild/CenterCorners.lean new file mode 100644 index 0000000000000000000000000000000000000000..9d9baa7a25a70610ea4660d8f17be5d825a07694 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CenterCorners.lean @@ -0,0 +1,498 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.CenterExpectations +import OAI.Analysis.BoundedHochschild.CenterEnergy + +namespace OAI + +/-! Local central quantization and center-valued traces on corners. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCentralQuantization +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems + FinitePathMain +universe u v +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable {I : Type v} [Fintype I] + +include e in +lemma exists_large_small_expectations + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hII : TypeII1 M) + (x : I → M) (hx : ∀ i, CentrallyCentered τ (x i)) {ε : ℝ} (hε : 0<ε) (N : ℕ) : + ∃ (n : ℕ) (E : MatrixSystem M n), N sq_nonneg _) + obtain ⟨N,hNall⟩ := exists_nat_gt (max (4*B/δ) (1/η₀)) + have hN : 4*B/δ < (N:ℝ) := (le_max_left _ _).trans_lt hNall + have hNη : 1/η₀ < (N:ℝ) := (le_max_right _ _).trans_lt hNall + obtain ⟨n,E,hnN,hE⟩ := exists_large_small_expectations e τ hτ h1 htr hfaith hII x hx hη N + have hn : 0 + (sq_le_sq₀ (norm_nonneg _) hη.le).mpr (hE i).le) + _ = _ := by simp + have hcard : (Fintype.card I:ℝ)*η^2<δ/4 := by + rw [hηsq] + have hh : (Fintype.card I:ℝ) + sq_nonneg ‖τ.toPreGNS (E.phaseCoefficient g (x j))‖) (Finset.mem_univ i) + exact hi.trans_lt (hg.trans_lt htotal) + refine ⟨E.rankOne g,E.rankOne_projection (Nat.ne_of_gt hn) g,?_,?_,?_⟩ + · intro hz + have ht := E.trace_rankOne τ htr h1 (Nat.ne_of_gt hn) g + rw [hz,map_zero] at ht + exact (inv_ne_zero (by exact_mod_cast (Nat.ne_of_gt hn) : (n:ℂ) ≠ 0)) ht.symm + · rw [E.trace_rankOne τ htr h1 (Nat.ne_of_gt hn) g] + have he : (n:ℂ)⁻¹=Complex.ofReal ((n:ℝ)⁻¹) := by simp + rw [he,Complex.ofReal_re] + have hh : 1/η₀ < (n:ℝ) := hNη.trans (by exact_mod_cast hnN) + exact (inv_lt_comm₀ hnR hη₀).mpr (by simpa only [one_div] using hh) + · intro i + rw [E.rankOne_compression_norm τ htr (Nat.ne_of_gt hn) g (x i), + E.trace_rankOne τ htr h1 (Nat.ne_of_gt hn) g] + have he : (n:ℂ)⁻¹=Complex.ofReal ((n:ℝ)⁻¹) := by simp + rw [he,Complex.ofReal_re,mul_comm δ] + exact mul_lt_mul_of_pos_left (hend i) (inv_pos.mpr hnR) + +include e in +theorem exists_small_corner + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hII : TypeII1 M) + (x : I → M) (hx : ∀ i, CentrallyCentered τ (x i)) {δ : ℝ} (hδ : 0<δ) : + ∃ q : M, IsStarProjection q ∧ q ≠ 0 ∧ + ∀ i, ‖τ.toPreGNS (q*x i*q)‖^2 < δ*(τ q).re := by + obtain ⟨q,hq,hq0,_,hxq⟩ := exists_small_corner_of_trace_limit e τ hτ h1 htr hfaith + hII x hx hδ (by norm_num : (0:ℝ)<1) + exact ⟨q,hq,hq0,hxq⟩ + +end HochschildCentralQuantization + +open scoped ComplexOrder +namespace HochschildCentralQuantization +open BoundedHochschild HochschildSakai HochschildRigidity FinitePathMain +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include e hτ htr hfaith in +lemma exists_central_positive_cut {a : M} (ha : IsSelfAdjoint a) + (hcentral : ∀ x : M, Commute a x) (ht : 0<(τ a).re) : + ∃ c : M, IsStarProjection c ∧ (∀ x : M, Commute c x) ∧ + 0≤c*a ∧ c*a ≠ 0 := by + obtain ⟨c,hc⟩ := exists_support_projection e τ (mul_hasPreadjoint e) hτ htr hfaith + a⁺ (CFC.posPart_nonneg a) + have hca : c*a=a⁺ := by + conv_lhs => rw [← CFC.posPart_sub_negPart a ha] + rw [mul_sub,hc.left,hc.annihilate a⁻ (CFC.posPart_mul_negPart a),sub_zero] + have hn : a⁺ ≠ 0 := by + intro hz + have he : a= -a⁻ := by + calc a = a⁺-a⁻ := (CFC.posPart_sub_negPart a ha).symm + _ = -a⁻ := by rw [hz,zero_sub] + have hh := τ.map_nonneg (CFC.negPart_nonneg a) + rw [he,map_neg,Complex.neg_re] at ht + have hhr : (0:ℝ) ≤ (τ a⁻).re := hh.1 + linarith + refine ⟨c,hc.proj,?_,by rw [hca]; exact CFC.posPart_nonneg a,by rwa [hca]⟩ + intro x + apply hc.commute (IsSelfAdjoint.of_nonneg (CFC.posPart_nonneg a)) + rw [CFC.posPart_def,cfcₙ_eq_cfc] + exact (hcentral x).cfc (by simpa only [ha.star_eq] using hcentral x) _ + +lemma centerExpectation_trace (a : M) : + τ (centerExpectation e τ hτ htr hfaith a)=τ a := by + simpa only [one_mul,centerExpectation_apply] using centerPart_trace e τ hτ htr hfaith a 1 + (fun x => Commute.one_left x) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_cut_compression {c q x : M} (hc : IsStarProjection c) + (hz : ∀ a : M, Commute c a) : (c*q)*x*(c*q)=c*(q*x*q) := by + calc + _ = c*((q*x)*c)*q := by simp only [mul_assoc] + _ = c*(c*(q*x))*q := by rw [← (hz (q*x)).eq] + _ = _ := by rw [← mul_assoc c c,hc.isIdempotentElem.eq]; simp only [mul_assoc] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_cut_energy {c q x : M} (hc : IsStarProjection c) + (hz : ∀ a : M, Commute c a) : + star ((c*q)*x*(c*q))*((c*q)*x*(c*q))=c*(star (q*x*q)*(q*x*q)) := by + rw [central_cut_compression hc hz,star_mul,hc.isSelfAdjoint.star_eq] + calc + _ = star (q*x*q)*(c*c)*(q*x*q) := by simp only [mul_assoc] + _ = c*(star (q*x*q)*(q*x*q)) := by + rw [hc.isIdempotentElem.eq,← (hz (star (q*x*q))).eq,mul_assoc] + +include e hτ htr hfaith in + +lemma exists_center_order_cut {I : Type*} [Fintype I] + (x : I → M) {q : M} (hq : IsStarProjection q) {δ : ℝ} + (hsmall : (∑ i, ‖τ.toPreGNS (q*x i*q)‖^2) < δ*(τ q).re) : + ∃ r : M, IsStarProjection r ∧ r ≠ 0 ∧ r ≤ q ∧ + (∑ i, centerExpectation e τ hτ htr hfaith (star (r*x i*r)*(r*x i*r))) ≤ + δ • centerExpectation e τ hτ htr hfaith r := by + classical + let E := centerExpectation e τ hτ htr hfaith + let b : I → M := fun i => star (q*x i*q)*(q*x i*q) + let a : M := δ • E q - ∑ i,E (b i) + have hEz (x y : M) : Commute (E x) y := centerPart_central e τ hτ htr hfaith x y + have hEp (x : M) (hx : 0≤x) : 0≤E x := centerExpectation_nonneg e τ hτ htr hfaith hx + have ha : IsSelfAdjoint a := by + apply IsSelfAdjoint.sub + · exact (IsSelfAdjoint.all δ).smul (IsSelfAdjoint.of_nonneg (hEp q hq.nonneg)) + · exact IsSelfAdjoint.of_nonneg (Finset.sum_nonneg (fun i _ => hEp _ (star_mul_self_nonneg _))) + have hac : ∀ y : M, Commute a y := by + intro y + apply Commute.sub_left + · exact (hEz q y).smul_left δ + · exact Commute.sum_left Finset.univ (fun i => E (b i)) y (fun i _ => hEz (b i) y) + have hat : 0<(τ a).re := by + have hreal : τ (δ • E q) = (δ:ℂ)*τ q := by + rw [← Complex.coe_smul,map_smul,smul_eq_mul,centerExpectation_trace] + have hb (i : I) : (τ (E (b i))).re=‖τ.toPreGNS (q*x i*q)‖^2 := by + rw [centerExpectation_trace] + exact trace_star_mul_self_re τ _ + dsimp only [a] + rw [map_sub,Complex.sub_re,hreal,Complex.mul_re,Complex.ofReal_re, + Complex.ofReal_im,zero_mul,sub_zero,map_sum,Complex.re_sum] + simp only [hb] + linarith + obtain ⟨c,hc,hcz,hca,hca0⟩ := exists_central_positive_cut e τ hτ htr hfaith ha hac hat + have hr : IsStarProjection (c*q) := hc.mul hq (hcz q) + have hcut : (∑ i,E (star ((c*q)*x i*(c*q))*((c*q)*x i*(c*q)))) ≤ δ • E (c*q) := by + have hid : δ • E (c*q) - ∑ i,E (star ((c*q)*x i*(c*q))*((c*q)*x i*(c*q))) = c*a := by + simp only [E,central_cut_energy hc hcz,centerExpectation_bimodule e τ hτ htr hfaith hcz, + a,b,mul_sub,mul_smul_comm,Finset.mul_sum] + exact sub_nonneg.mp (by rw [hid]; exact hca) + refine ⟨c*q,hr,?_,?_,hcut⟩ + · intro he + apply hca0 + have hEb : ∀ i, c*E (b i)=0 := by + intro i + rw [← centerExpectation_bimodule e τ hτ htr hfaith hcz] + have hcb : c*b i=0 := by + have hh := central_cut_energy (q := q) (x := x i) hc hcz + rw [he,zero_mul,mul_zero,star_zero,mul_zero] at hh + exact hh.symm + rw [hcb,map_zero] + change c*(δ • E q - ∑ i,E (b i))=0 + rw [mul_sub,mul_smul_comm,← centerExpectation_bimodule e τ hτ htr hfaith hcz, + he,map_zero,smul_zero,Finset.mul_sum] + simp only [hEb,Finset.sum_const_zero,sub_self] + · apply (hr.le_iff_mul_eq_left hq).mpr + rw [mul_assoc,hq.isIdempotentElem.eq] + +include e hτ htr hfaith in + +theorem exists_small_corner_center_order + (h1 : τ 1=1) (hII : TypeII1 M) + {I : Type*} [Fintype I] (x : I → M) (hx : ∀ i, CentrallyCentered τ (x i)) + {δ η : ℝ} (hδ : 0<δ) (hη : 0<η) : + ∃ r : M, IsStarProjection r ∧ r ≠ 0 ∧ (τ r).re<η ∧ + (∑ i, centerExpectation e τ hτ htr hfaith (star (r*x i*r)*(r*x i*r))) ≤ + δ • centerExpectation e τ hτ htr hfaith r := by + classical + let K : ℝ := Fintype.card I+1 + have hK : 0 (hqx i).le) + _ = _ := by simp + have hcard : (Fintype.card I:ℝ) r*b) hc + simp only [← mul_assoc,hr.isIdempotentElem.eq,hrp'] at h3 + rw [mul_sub,h3,sub_self] + obtain ⟨z,hz,hrz,hzcomp⟩ := central_separator e τ hτ htr hfaith hr hcomp hoff + refine ⟨z,hz,?_⟩ + have hzr : z*r=r := (hr.le_iff_mul_eq_right hz.1).mp hrz + rw [mul_sub,hzr,sub_eq_zero] at hzcomp + exact hzcomp + +include e hτ htr hfaith in +lemma corner_selfAdjoint_posPart_trace {p a : M} (hp : IsStarProjection p) + (ha : a ∈ corner p hp) (has : IsSelfAdjoint a) + (hac : ∀ b : M, Commute a (p*b*p)) (hat : CentrallyCentered τ a) : + τ a⁺=0 := by + obtain ⟨r,hr⟩ := BoundedHochschild.exists_support_projection e τ + (mul_hasPreadjoint e) hτ htr hfaith a⁺ (CFC.posPart_nonneg a) + have hrp : r≤p := support_le_corner hp (posPart_mem_corner hp ha) hr + have hrc : ∀ b : M, Commute r (p*b*p) := by + intro b + apply hr.commute (IsSelfAdjoint.of_nonneg (CFC.posPart_nonneg a)) + rw [CFC.posPart_def,cfcₙ_eq_cfc] + exact (hac b).cfc (by simpa only [has.star_eq] using hac b) _ + obtain ⟨z,hz,hzp⟩ := central_corner_projection_lift e τ hτ htr hfaith hp hr.proj hrp hrc + have hra : r*a=a⁺ := by + conv_lhs => rw [← CFC.posPart_sub_negPart a has] + rw [mul_sub,hr.left,hr.annihilate a⁻ (CFC.posPart_mul_negPart a),sub_zero] + have hza : z*a=a⁺ := by + calc z*a = z*(p*a) := by rw [ha.1] + _ = a⁺ := by rw [← mul_assoc,hzp,hra] + rw [← hza] + exact hat z hz.2 + +include e hτ htr hfaith in +lemma corner_selfAdjoint_centered_zero {p a : M} (hp : IsStarProjection p) + (ha : a ∈ corner p hp) (has : IsSelfAdjoint a) + (hac : ∀ b : M, Commute a (p*b*p)) (hat : CentrallyCentered τ a) : a=0 := by + have hpz := corner_selfAdjoint_posPart_trace e τ hτ htr hfaith hp ha has hac hat + have hnt : CentrallyCentered τ (-a) := by + intro z hz + rw [mul_neg,map_neg,hat z hz,neg_zero] + have hnz := corner_selfAdjoint_posPart_trace e τ hτ htr hfaith hp + ((corner p hp).neg_mem ha) has.neg (fun b => (hac b).neg_left) hnt + have hposzero (b : M) (hb : 0≤b) (hbt : τ b=0) : b=0 := by + have hs : CFC.sqrt b=0 := hfaith _ (by + rw [(IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg b)).star_eq, + CFC.sqrt_mul_sqrt_self b hb,hbt]) + calc b = CFC.sqrt b*CFC.sqrt b := (CFC.sqrt_mul_sqrt_self b hb).symm + _ = 0 := by rw [hs,mul_zero] + have hp0 := hposzero a⁺ (CFC.posPart_nonneg a) hpz + have hn0 := hposzero (-a)⁺ (CFC.posPart_nonneg (-a)) hnz + have hn0' : a⁻=0 := by simpa only [CFC.posPart_neg] using hn0 + calc a = a⁺-a⁻ := (CFC.posPart_sub_negPart a has).symm + _ = 0 := by rw [hp0,hn0',sub_self] + +include e hτ htr hfaith in +lemma corner_centered_zero {p a : M} (hp : IsStarProjection p) + (ha : a ∈ corner p hp) (hac : ∀ b : M, Commute a (p*b*p)) + (hat : CentrallyCentered τ a) : a=0 := by + have hE : centerExpectation e τ hτ htr hfaith a=0 := + (centerExpectation_zero_iff e τ hτ htr hfaith a).mpr hat + have hacs (b : M) : Commute (star a) (p*b*p) := by + have hh := (hac (star b)).star_star + simpa only [star_mul,hp.isSelfAdjoint.star_eq,star_star,mul_assoc] using hh + have hplus : a+star a=0 := by + apply corner_selfAdjoint_centered_zero e τ hτ htr hfaith hp + ((corner p hp).add_mem ha (show star a ∈ corner p hp from star_mem ha)) (IsSelfAdjoint.add_star_self a) + (fun b => (hac b).add_left (hacs b)) + apply (centerExpectation_zero_iff e τ hτ htr hfaith _).mp + rw [map_add,centerExpectation_star,hE,star_zero,add_zero] + have hstar : star a= -a := eq_neg_of_add_eq_zero_right hplus + have hIplus : Complex.I • a+star (Complex.I • a)=0 := by + have hIa : Complex.I • a ∈ corner p hp := (corner p hp).smul_mem _ ha + apply corner_selfAdjoint_centered_zero e τ hτ htr hfaith hp + ((corner p hp).add_mem hIa (show star (Complex.I • a) ∈ corner p hp from star_mem hIa)) + (IsSelfAdjoint.add_star_self (Complex.I • a)) + · intro b + apply Commute.add_left ((hac b).smul_left _) + rw [star_smul] + exact (hacs b).smul_left _ + · apply (centerExpectation_zero_iff e τ hτ htr hfaith _).mp + rw [map_add,centerExpectation_star,map_smul,hE,smul_zero,star_zero,add_zero] + simp only [star_smul,Complex.star_def,Complex.conj_I,hstar,smul_neg,neg_smul,neg_neg] at hIplus + have htwo : (2:ℂ) • (Complex.I • a)=0 := by rw [two_smul, hIplus] + exact (smul_eq_zero.mp ((smul_eq_zero.mp htwo).resolve_left two_ne_zero)).resolve_left Complex.I_ne_zero + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_corner_weight_mul {p z : M} (hp : IsStarProjection p) + (hz : ∀ b : M, Commute z b) (a : Corner p hp) : (p*z*p)*(a:M)=z*(a:M) := by + calc (p*z*p)*(a:M) = (p*z)*(p*(a:M)) := by rw [mul_assoc] + _ = (p*z)*(a:M) := by rw [a.property.1] + _ = (z*p)*(a:M) := by rw [(hz p).eq] + _ = z*(a:M) := by rw [mul_assoc,a.property.1] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_corner_weight {p z : M} (hp : IsStarProjection p) + (hz : ∀ b : M, Commute z b) : + ∀ a : Corner p hp, Commute (⟨p*z*p,compress_mem_corner hp z⟩ : Corner p hp) a := by + intro a + change (⟨p*z*p,compress_mem_corner hp z⟩ : Corner p hp)*a= + a*(⟨p*z*p,compress_mem_corner hp z⟩ : Corner p hp) + apply Subtype.ext + change (p*z*p)*(a:M)=(a:M)*(p*z*p) + rw [central_corner_weight_mul hp hz a,← mul_assoc,← mul_assoc,a.property.2, + ← (hz (a:M)).eq,mul_assoc,a.property.2] + +include e hτ htr hfaith in + +lemma ambient_centered_corner {p : M} (hp : IsStarProjection p) (hp0 : p≠0) + (a : Corner p hp) (ha : CentrallyCentered τ (a:M)) : + CentrallyCentered (cornerTrace p hp τ) a := by + let ec := cornerPredualEquiv p hp e + let tc := cornerTrace p hp τ + have hn : TraceInPredual ec tc := cornerTrace_normal p hp e τ hτ + have ht : ∀ a b : Corner p hp, tc (a*b)=tc (b*a) := cornerTrace_tracial p hp τ htr + have hf : ∀ a : Corner p hp, tc (star a*a)=0 → a=0 := cornerTrace_faithful p hp τ hfaith hp0 + let b : Corner p hp := centerPart ec tc hn ht hf a + have hbc : ∀ x : M, Commute (b:M) (p*x*p) := by + intro x + have hh := centerPart_central ec tc hn ht hf a ⟨p*x*p,compress_mem_corner hp x⟩ + exact congrArg (fun v : Corner p hp => (v:M)) hh.eq + have hbt : CentrallyCentered τ (b:M) := by + intro z hz + let zc : Corner p hp := ⟨p*z*p,compress_mem_corner hp z⟩ + have hh := centerPart_trace ec tc hn ht hf a zc (central_corner_weight hp hz) + change ((τ p).re : ℂ)⁻¹ * τ ((p*z*p)*(b:M))= + ((τ p).re : ℂ)⁻¹ * τ ((p*z*p)*(a:M)) at hh + rw [central_corner_weight_mul hp hz b,central_corner_weight_mul hp hz a,ha z hz,mul_zero] at hh + exact (mul_eq_zero.mp hh).resolve_left (inv_ne_zero (Complex.ofReal_ne_zero.mpr + (HochschildDiffuse.projection_trace_pos τ hfaith hp hp0).ne')) + have hb0 : (b:M)=0 := corner_centered_zero e τ hτ htr hfaith hp b.property hbc hbt + apply (centerExpectation_zero_iff ec tc hn ht hf a).mp + exact Subtype.ext hb0 + +def cornerExpectation {p : M} (hp : IsStarProjection p) (hp0 : p≠0) : + Corner p hp →L[ℂ] Corner p hp := + centerExpectation (cornerPredualEquiv p hp e) (cornerTrace p hp τ) + (cornerTrace_normal p hp e τ hτ) (cornerTrace_tracial p hp τ htr) + (cornerTrace_faithful p hp τ hfaith hp0) + +lemma cornerExpectation_weighted_trace {p : M} (hp : IsStarProjection p) (hp0 : p≠0) + (a : Corner p hp) {z : M} (hz : ∀ x : M, Commute z x) : + τ (z*(cornerExpectation e τ hτ htr hfaith hp hp0 a : M))=τ (z*(a:M)) := by + let zc : Corner p hp := ⟨p*z*p,compress_mem_corner hp z⟩ + have hh := centerPart_trace (cornerPredualEquiv p hp e) (cornerTrace p hp τ) + (cornerTrace_normal p hp e τ hτ) (cornerTrace_tracial p hp τ htr) + (cornerTrace_faithful p hp τ hfaith hp0) a zc (central_corner_weight hp hz) + change ((τ p).re : ℂ)⁻¹ * τ ((p*z*p)*(cornerExpectation e τ hτ htr hfaith hp hp0 a : M))= + ((τ p).re : ℂ)⁻¹ * τ ((p*z*p)*(a:M)) at hh + rw [central_corner_weight_mul hp hz,central_corner_weight_mul hp hz] at hh + exact mul_left_cancel₀ (inv_ne_zero (Complex.ofReal_ne_zero.mpr + (HochschildDiffuse.projection_trace_pos τ hfaith hp hp0).ne')) hh + +lemma centerExpectation_corner_tower {p : M} (hp : IsStarProjection p) (hp0 : p≠0) + (a : Corner p hp) : + centerExpectation e τ hτ htr hfaith (cornerExpectation e τ hτ htr hfaith hp hp0 a : M)= + centerExpectation e τ hτ htr hfaith (a:M) := by + apply central_trace_unique τ hfaith + (centerPart_central e τ hτ htr hfaith _) (centerPart_central e τ hτ htr hfaith _) + intro z hz + exact (centerPart_trace e τ hτ htr hfaith _ z hz).trans + ((cornerExpectation_weighted_trace e τ hτ htr hfaith hp hp0 a hz).trans + (centerPart_trace e τ hτ htr hfaith _ z hz).symm) + +lemma centerExpectation_monotone : Monotone (centerExpectation e τ hτ htr hfaith) := by + intro a b hab + apply sub_nonneg.mp + rw [← map_sub] + exact centerExpectation_nonneg e τ hτ htr hfaith (sub_nonneg.mpr hab) + +include e hτ htr hfaith in +lemma corner_typeII1 {p : M} (hp : IsStarProjection p) (hp0 : p≠0) + (hII : TypeII1 M) : TypeII1 (Corner p hp) := by + constructor + · exact HochschildMatrixSystems.finite_of_faithful_trace (cornerTrace p hp τ) + (cornerTrace_tracial p hp τ htr) (cornerTrace_faithful p hp τ hfaith hp0) + · intro z hz + by_contra hz0 + obtain ⟨q,hq,_hqz,hq0⟩ := hz.2 z hz.1 le_rfl hz0 + have hqm : IsStarProjection (q:M) := corner_projection_coe p hp hq.1 + have hcompress (a : M) : (q:M)*(p*a*p)*(q:M)=(q:M)*a*(q:M) := by + rw [← mul_assoc,← mul_assoc,q.property.2,mul_assoc,q.property.1] + have hqa : AbelianProjection (q:M) := by + refine ⟨hqm,fun a b => ?_⟩ + have hh := congrArg (fun v : Corner p hp => (v:M)) + (hq.2 ⟨p*a*p,compress_mem_corner hp a⟩ ⟨p*b*p,compress_mem_corner hp b⟩).eq + change ((q:M)*(p*a*p)*(q:M))*((q:M)*(p*b*p)*(q:M))= + ((q:M)*(p*b*p)*(q:M))*((q:M)*(p*a*p)*(q:M)) at hh + change (q:M)*a*(q:M)*((q:M)*b*(q:M))=(q:M)*b*(q:M)*((q:M)*a*(q:M)) + simpa only [hcompress] using hh + exact hq0 (Subtype.ext (HochschildTypeII.no_abelian_projection e τ hτ htr hfaith hII hqa)) + +end HochschildCentralQuantization + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CenterEnergy.lean b/lean/OAI/Analysis/BoundedHochschild/CenterEnergy.lean new file mode 100644 index 0000000000000000000000000000000000000000..4f65337afe65a406da9146ed33f4654dba0c198a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CenterEnergy.lean @@ -0,0 +1,192 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.CenterCommutants + +namespace OAI + +/-! Matrix displacement and central energy estimates. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCentralQuantization +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems + HochschildQuantization HochschildCentralComparison FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +include e in +lemma exists_colored_matrix_displacement + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hII : TypeII1 M) + (a : M) (hacenter : CentrallyCentered τ a) (ha : 0<‖τ.toPreGNS a‖) : + ∃ (m : ℕ) (F : MatrixSystem M m) (z : Fin m → M), 0 < m ∧ + (∀ i, CentralProjection (z i)) ∧ IsStarProjection (∑ i,z i*F.entry i i) ∧ + ‖τ.toPreGNS a‖/16 < + ‖τ.toPreGNS ((∑ i,z i*F.entry i i)*a-a*(∑ i,z i*F.entry i i))‖ := by + obtain ⟨p,hp,hpdisp⟩ := exists_central_projection_displacement e τ hτ h1 htr hfaith hacenter ha + let t := ‖τ.toPreGNS a‖ + let ε : ℝ := t/(64*(‖a‖+1)) + have hε : 0<ε := div_pos ha (by positivity) + obtain ⟨m,F,z,hm,hz,hq,_hqp,happrox⟩ := exists_central_matrix_projection_approx e τ hτ htr hfaith + h1 hII hp hε + refine ⟨m,F,z,hm,hz,hq,?_⟩ + let q := ∑ i,z i*F.entry i i + have herr : ‖τ.toPreGNS (p*a-a*p)‖ ≤ ‖τ.toPreGNS (q*a-a*q)‖+2*‖a‖*ε := by + calc + _ = ‖τ.toPreGNS (q*a-a*q)+τ.toPreGNS ((p-q)*a-a*(p-q))‖ := by + rw [← map_add]; congr 2; noncomm_ring + _ ≤ ‖τ.toPreGNS (q*a-a*q)‖+‖τ.toPreGNS ((p-q)*a-a*(p-q))‖ := norm_add_le _ _ + _ ≤ ‖τ.toPreGNS (q*a-a*q)‖+2*‖a‖*ε := + add_le_add_right ((commutator_gns_le τ htr a (p-q)).trans + (mul_le_mul_of_nonneg_left happrox.le (by positivity))) _ + have hsmall : 2*‖a‖*ε ≤ t/32 := by + have heq : ε*(64*(‖a‖+1))=t := div_mul_cancel₀ _ (by positivity) + nlinarith [hε.le] + change t/16 < ‖τ.toPreGNS (q*a-a*q)‖ + change t/8 < _ at hpdisp + linarith + +end HochschildCentralQuantization + +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +open BoundedHochschild HochschildRigidity HochschildSakai HochschildQuantization + HochschildCentralQuantization FinitePathMain +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {n : ℕ} (E : MatrixSystem M n) +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +include e in + +theorem exists_central_energy_decreasing_extension + (hn : 0 (hb x).sub_left (hc x))),sub_self] + +include e hτ htr hfaith in +lemma exists_unique_center_part (a : M) : + ∃ b : M, ‖b‖≤‖a‖ ∧ (∀ x : M, Commute b x) ∧ + ∀ z : M, (∀ x : M, Commute z x) → τ (z*b)=τ (z*a) := by + obtain ⟨b,hbn,hbc,hb⟩ := exists_central_average e τ (mul_hasPreadjoint e) hτ htr hfaith a + exact ⟨b,hbn,hbc,fun z hz => trace_weighted_orbit_closure e τ hτ htr hfaith a b z hz hb⟩ + +def centerPart (a : M) : M := (exists_unique_center_part e τ hτ htr hfaith a).choose + +lemma centerPart_norm (a : M) : ‖centerPart e τ hτ htr hfaith a‖≤‖a‖ := + (exists_unique_center_part e τ hτ htr hfaith a).choose_spec.1 + +lemma centerPart_central (a x : M) : Commute (centerPart e τ hτ htr hfaith a) x := + (exists_unique_center_part e τ hτ htr hfaith a).choose_spec.2.1 x + +lemma centerPart_trace (a z : M) (hz : ∀ x : M, Commute z x) : + τ (z*centerPart e τ hτ htr hfaith a)=τ (z*a) := + (exists_unique_center_part e τ hτ htr hfaith a).choose_spec.2.2 z hz + +lemma centerPart_add (a b : M) : centerPart e τ hτ htr hfaith (a+b)= + centerPart e τ hτ htr hfaith a+centerPart e τ hτ htr hfaith b := by + apply central_trace_unique τ hfaith + (centerPart_central e τ hτ htr hfaith (a+b)) + (fun x => (centerPart_central e τ hτ htr hfaith a x).add_left + (centerPart_central e τ hτ htr hfaith b x)) + intro z hz + rw [centerPart_trace e τ hτ htr hfaith _ z hz,mul_add,map_add,mul_add,map_add, + centerPart_trace e τ hτ htr hfaith _ z hz,centerPart_trace e τ hτ htr hfaith _ z hz] + +lemma centerPart_smul (t : ℂ) (a : M) : centerPart e τ hτ htr hfaith (t • a)= + t • centerPart e τ hτ htr hfaith a := by + apply central_trace_unique τ hfaith + (centerPart_central e τ hτ htr hfaith (t • a)) + (fun x => (centerPart_central e τ hτ htr hfaith a x).smul_left t) + intro z hz + rw [centerPart_trace e τ hτ htr hfaith _ z hz,mul_smul_comm,map_smul,mul_smul_comm,map_smul, + centerPart_trace e τ hτ htr hfaith _ z hz] + +def centerExpectation : M →L[ℂ] M := + LinearMap.mkContinuous + { toFun := centerPart e τ hτ htr hfaith + map_add' := centerPart_add e τ hτ htr hfaith + map_smul' := centerPart_smul e τ hτ htr hfaith } + 1 (fun a => by + change ‖centerPart e τ hτ htr hfaith a‖≤1*‖a‖ + simpa only [one_mul] using centerPart_norm e τ hτ htr hfaith a) + +@[simp] lemma centerExpectation_apply (a : M) : + centerExpectation e τ hτ htr hfaith a=centerPart e τ hτ htr hfaith a := rfl + +lemma centerExpectation_fix {a : M} (ha : ∀ x : M, Commute a x) : + centerExpectation e τ hτ htr hfaith a=a := by + apply central_trace_unique τ hfaith (centerPart_central e τ hτ htr hfaith a) ha + exact centerPart_trace e τ hτ htr hfaith a + +lemma centerExpectation_bimodule {z : M} (hz : ∀ x : M, Commute z x) (a : M) : + centerExpectation e τ hτ htr hfaith (z*a)=z*centerExpectation e τ hτ htr hfaith a := by + apply central_trace_unique τ hfaith + (centerPart_central e τ hτ htr hfaith (z*a)) + (fun x => (hz x).mul_left (centerPart_central e τ hτ htr hfaith a x)) + intro w hw + rw [centerPart_trace e τ hτ htr hfaith _ w hw,← mul_assoc,← mul_assoc] + exact (centerPart_trace e τ hτ htr hfaith a (w*z) (fun x => (hw x).mul_left (hz x))).symm + +lemma centered_sub_expectation (a : M) : + CentrallyCentered τ (a-centerExpectation e τ hτ htr hfaith a) := by + intro z hz + rw [mul_sub,map_sub,centerExpectation_apply,centerPart_trace e τ hτ htr hfaith _ z hz,sub_self] + +lemma centerExpectation_idempotent (a : M) : + centerExpectation e τ hτ htr hfaith (centerExpectation e τ hτ htr hfaith a)= + centerExpectation e τ hτ htr hfaith a := + centerExpectation_fix e τ hτ htr hfaith (centerPart_central e τ hτ htr hfaith a) + +lemma centerExpectation_zero_iff (a : M) : + centerExpectation e τ hτ htr hfaith a=0 ↔ CentrallyCentered τ a := by + constructor + · intro ha z hz + have h := centerPart_trace e τ hτ htr hfaith a z hz + change τ (z*centerExpectation e τ hτ htr hfaith a)=_ at h + rw [ha,mul_zero,map_zero] at h + exact h.symm + · intro ha + apply central_trace_unique τ hfaith (centerPart_central e τ hτ htr hfaith a) + (fun x => Commute.zero_left x) + intro z hz + rw [mul_zero,map_zero,centerPart_trace e τ hτ htr hfaith _ z hz,ha z hz] + +lemma centerExpectation_star (a : M) : + centerExpectation e τ hτ htr hfaith (star a)=star (centerExpectation e τ hτ htr hfaith a) := by + apply central_trace_unique τ hfaith + (centerPart_central e τ hτ htr hfaith (star a)) + (central_star (centerPart_central e τ hτ htr hfaith a)) + intro z hz + rw [centerPart_trace e τ hτ htr hfaith _ z hz] + have h := congrArg star (centerPart_trace e τ hτ htr hfaith a (star z) (central_star hz)) + rw [← map_star τ,← map_star τ,star_mul,star_mul,star_star] at h + rw [htr z (star a),htr z (star (centerPart e τ hτ htr hfaith a))] + exact h.symm + +lemma centerExpectation_trace_adjoint (a b : M) : + τ (star b*centerExpectation e τ hτ htr hfaith a)= + τ (star (centerExpectation e τ hτ htr hfaith b)*a) := by + rw [← centerExpectation_star e τ hτ htr hfaith] + calc + _ = τ (centerExpectation e τ hτ htr hfaith a*star b) := htr _ _ + _ = τ (centerExpectation e τ hτ htr hfaith a* + centerExpectation e τ hτ htr hfaith (star b)) := + (centerPart_trace e τ hτ htr hfaith (star b) _ + (centerPart_central e τ hτ htr hfaith a)).symm + _ = τ (centerExpectation e τ hτ htr hfaith (star b)* + centerExpectation e τ hτ htr hfaith a) := htr _ _ + _ = _ := centerPart_trace e τ hτ htr hfaith a _ + (centerPart_central e τ hτ htr hfaith (star b)) + +lemma centerExpectation_normal : HasPreadjoint e (centerExpectation e τ hτ htr hfaith) := by + obtain ⟨P,_hP,hPa⟩ := exists_preadjoint_of_trace_adjoint e e τ τ + (mul_hasPreadjoint e) (mul_hasPreadjoint e) hτ hτ hfaith + (centerExpectation e τ hτ htr hfaith) (centerExpectation e τ hτ htr hfaith) + (centerExpectation_trace_adjoint e τ hτ htr hfaith) + intro z + exact ⟨P z,fun a => hPa a z⟩ + +lemma centerExpectation_norm_le : ‖centerExpectation e τ hτ htr hfaith‖≤1 := by + apply ContinuousLinearMap.opNorm_le_bound _ (by norm_num) + intro a + change ‖centerPart e τ hτ htr hfaith a‖≤1*‖a‖ + simpa only [one_mul] using centerPart_norm e τ hτ htr hfaith a + +lemma centerExpectation_nonneg {a : M} (ha : 0≤a) : + 0≤centerExpectation e τ hτ htr hfaith a := by + obtain ⟨b,hbn,hbc,hb⟩ := exists_central_average e τ (mul_hasPreadjoint e) hτ htr hfaith a + have he : centerExpectation e τ hτ htr hfaith a=b := by + apply central_trace_unique τ hfaith (centerPart_central e τ hτ htr hfaith a) hbc + intro z hz + rw [centerPart_trace e τ hτ htr hfaith _ z hz] + exact (trace_weighted_orbit_closure e τ hτ htr hfaith a b z hz hb).symm + rw [he] + obtain ⟨c,hc,hcn,hct⟩ := HochschildCentralComparison.orbit_sequence τ hb + have ht := predual_tendsto_of_preGNS e τ (mul_hasPreadjoint e) hτ hfaith ‖a‖ hcn hct + have hpos : ∀ n, 0≤c n := by + have hh : convexHull ℝ (Set.range (fun u : unitary M => conjugate u a)) ⊆ {b : M | 0≤b} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩ + exact star_right_conjugate_nonneg ha (u:M) + · intro x hx y hy r s hr hs _hrs + exact add_nonneg (smul_nonneg hr hx) (smul_nonneg hs hy) + exact fun n => hh (hc n) + exact nonneg_of_bounded_predual_limit e ‖a‖ (norm_nonneg _) + (Filter.Eventually.of_forall hcn) (Filter.Eventually.of_forall hpos) ht + +end HochschildCentralQuantization + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CenterPowers.lean b/lean/OAI/Analysis/BoundedHochschild/CenterPowers.lean new file mode 100644 index 0000000000000000000000000000000000000000..517cac50e0c547f1bcfce4323070ca13f25f823a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CenterPowers.lean @@ -0,0 +1,190 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.RelativeCenter + +namespace OAI + +/-! Center-valued weak cancellation for unitary powers. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +open BoundedHochschild HochschildCorners HochschildCentralQuantization HochschildRigidity +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {n : ℕ} (E : MatrixSystem M n) + +def diagonalInflate (i : Fin n) : Corner (E.entry i i) (E.diagonal_proj i) →⋆ₐ[ℂ] M where + toFun x := E.coefficient i i (x:M) + map_zero' := E.coefficient_nil i i + map_add' x y := by + change E.coefficient i i ((x:M)+(y:M))=E.coefficient i i (x:M)+E.coefficient i i (y:M) + simp only [coefficient,mul_add,add_mul,Finset.sum_add_distrib] + map_one' := E.coefficient_diagonal_base i + map_mul' x y := by + rw [E.coefficient_mul] + change E.coefficient i i ((x:M)*(y:M))=E.coefficient i i ((x:M)*E.entry i i*(y:M)) + rw [x.property.2] + commutes' c := by + change E.coefficient i i (c • E.entry i i)=algebraMap ℂ M c + simp only [coefficient,mul_smul_comm,smul_mul_assoc,← Finset.smul_sum,E.entry_mul, + ite_true,E.sum_diagonal,Algebra.algebraMap_eq_smul_one] + map_star' x := (E.coefficient_star i i (x:M)).symm + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coefficient_compress (i : Fin n) (a : M) : + E.coefficient i i (E.entry i i*a*E.entry i i)=E.coefficient i i a := by + unfold coefficient + apply Finset.sum_congr rfl + intro k hk + rw [← mul_assoc,← mul_assoc,E.entry_mul,ite_eq_left rfl,mul_assoc,E.entry_mul,ite_eq_left rfl] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coefficient_diagonal_norm (i : Fin n) (a : M) : ‖E.coefficient i i a‖≤‖a‖ := by + let p := E.entry i i + let hp := E.diagonal_proj i + let x : Corner p hp := ⟨p*a*p,compress_mem_corner hp a⟩ + have hh := NonUnitalStarAlgHom.norm_apply_le (E.diagonalInflate i) x + change ‖E.coefficient i i (p*a*p)‖≤‖p*a*p‖ at hh + rw [E.coefficient_compress] at hh + have hn := hp.norm_le p + exact hh.trans ((norm_mul_le _ _).trans ((mul_le_mul_of_nonneg_right (norm_mul_le _ _) (norm_nonneg _)).trans + (by calc + ‖p‖*‖a‖*‖p‖ ≤ 1*‖a‖*1 := by gcongr + _ = ‖a‖ := by ring))) + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma center_coefficient_diagonal (i : Fin n) (a : M) : + centerExpectation e τ hτ htr hfaith (E.coefficient i i a)= + (n:ℂ) • centerExpectation e τ hτ htr hfaith (a*E.entry i i) := by + have ht (k : Fin n) : centerExpectation e τ hτ htr hfaith (E.entry k i*a*E.entry i k)= + centerExpectation e τ hτ htr hfaith (a*E.entry i i) := by + rw [centerExpectation_cyclic e τ hτ htr hfaith,← mul_assoc,E.entry_mul,ite_eq_left rfl, + centerExpectation_cyclic e τ hτ htr hfaith] + simp only [coefficient,map_sum,ht,Finset.sum_const,Finset.card_univ,Fintype.card_fin, + Nat.cast_smul_eq_nsmul] + +lemma center_diagonal_norm (hn : n≠0) (i : Fin n) (a : M) : + ‖centerExpectation e τ hτ htr hfaith (a*E.entry i i)‖≤‖a‖/(n:ℝ) := by + have hnR : (0:ℝ) Pi.single i k) + (single_frequency_injective k hk) + (fun i => τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a*E.entry i i))) + simpa only [diagonalRoot,Finset.mul_sum,mul_smul_comm,map_sum,map_smul] using hh + +lemma center_root_energy_bound (h1 : τ 1=1) (hn : n≠0) + (a : M) (k : ZMod m) (hk : k≠0) : + (∑ g : Fin n → ZMod m, ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a*E.diagonalRoot k g))‖^2) ≤ + (Fintype.card (Fin n → ZMod m):ℝ)*(‖a‖^2/(n:ℝ)) := by + have hnR : (n:ℝ)≠0 := by exact_mod_cast hn + have hb (i : Fin n) : ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a*E.entry i i))‖≤ + (n:ℝ)⁻¹*‖a‖ := by + simpa only [div_eq_inv_mul] using (preGNS_norm_le τ h1 _).trans + (E.center_diagonal_norm e τ hτ htr hfaith hn i a) + rw [E.center_root_parseval e τ hτ htr hfaith a k hk] + apply mul_le_mul_of_nonneg_left _ (Nat.cast_nonneg _) + calc + _ ≤ ∑ _i : Fin n,((n:ℝ)⁻¹*‖a‖)^2 := Finset.sum_le_sum (fun i hi => + (sq_le_sq₀ (norm_nonneg _) (mul_nonneg (inv_nonneg.mpr (Nat.cast_nonneg n)) (norm_nonneg _))).mpr (hb i)) + _ = _ := by + simp only [Finset.sum_const,Finset.card_univ,Fintype.card_fin,nsmul_eq_mul] + field_simp + +lemma exists_root_center_energy {I : Type*} [Fintype I] + (h1 : τ 1=1) (hn : n≠0) (a : I → M) (k : I → ZMod m) (hk : ∀ i, k i≠0) : + ∃ g : Fin n → ZMod m, + (∑ i,‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a i*E.diagonalRoot (k i) g))‖^2)≤ + (∑ i,‖a i‖^2)/(n:ℝ) := by + classical + have hh := Finset.sum_le_sum (fun i (_ : i∈(Finset.univ : Finset I)) => + E.center_root_energy_bound e τ hτ htr hfaith h1 hn (a i) (k i) (hk i)) + rw [Finset.sum_comm,← Finset.mul_sum,← Finset.sum_div] at hh + by_contra hg + push Not at hg + have hstrict : (Fintype.card (Fin n → ZMod m):ℝ)*((∑ i,‖a i‖^2)/(n:ℝ)) < + ∑ g : Fin n → ZMod m, ∑ i,‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a i*E.diagonalRoot (k i) g))‖^2 := by + rw [← nsmul_eq_mul,← Finset.card_univ,← Finset.sum_const] + exact Finset.sum_lt_sum_of_nonempty Finset.univ_nonempty (fun _ _ => hg _) + exact (not_lt_of_ge hh) hstrict + +end MatrixSystem +end HochschildMatrixSystems + +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +open BoundedHochschild HochschildRigidity HochschildSakai FinitePathMain HochschildCentralQuantization +universe u v +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable {I : Type v} [Fintype I] + +include e in +theorem exists_unitary_center_weak_powers + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hII : TypeII1 M) + (a : I → M) (k : I → ℤ) (hk : ∀ i, k i ≠ 0) {ε : ℝ} (hε : 0<ε) : + ∃ u : unitary M, ∀ i, ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a i*(u^(k i) : unitary M) : M))‖<ε := by + classical + let m : ℕ := 1+ ∑ i,(k i).natAbs + have hm : 0 < m := by dsimp [m]; omega + let : NeZero m := ⟨Nat.ne_of_gt hm⟩ + have hkm (i : I) : (k i : ZMod m) ≠ 0 := by + intro hz + have hd := (ZMod.intCast_zmod_eq_zero_iff_dvd (k i) m).mp hz + have hh := Int.natAbs_le_of_dvd_ne_zero hd (hk i) + simp only [Int.natAbs_natCast] at hh + have hi := Finset.single_le_sum (fun j (_ : j ∈ (Finset.univ : Finset I)) => + Nat.zero_le (k j).natAbs) (Finset.mem_univ i) + dsimp [m] at hh + omega + let B : ℝ := ∑ i,‖a i‖^2 + have hB : 0 ≤ B := Finset.sum_nonneg (fun _ _ => sq_nonneg _) + have hε2 : 0<ε^2 := sq_pos_of_pos hε + obtain ⟨n,hnR⟩ := exists_nat_gt (B/ε^2) + have hn : 0 (k i : ZMod m)) hkm + refine ⟨E.rootUnitary g,fun i => ?_⟩ + have hsum : B/(n:ℝ)<ε^2 := by + apply (div_lt_iff₀ hnRpos).mpr + have hh := (div_lt_iff₀ hε2).mp hnR + nlinarith + have hi := Finset.single_le_sum (fun j (_ : j ∈ (Finset.univ : Finset I)) => + sq_nonneg ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a j*E.diagonalRoot (k j : ZMod m) g))‖) (Finset.mem_univ i) + have hh : ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a i*E.diagonalRoot (k i : ZMod m) g))‖^2<ε^2 := hi.trans_lt (hg.trans_lt hsum) + change ‖τ.toPreGNS (centerExpectation e τ hτ htr hfaith (a i*((E.rootUnitary g)^(k i) : unitary M).val))‖<ε + rw [E.rootUnitary_zpow] + exact (sq_lt_sq₀ (norm_nonneg _) hε.le).mp hh + +end HochschildMatrixSystems + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralAtoms.lean b/lean/OAI/Analysis/BoundedHochschild/CentralAtoms.lean new file mode 100644 index 0000000000000000000000000000000000000000..78d2e3930ad86268e55d3c94707d445fc5df82d1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralAtoms.lean @@ -0,0 +1,146 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Central atoms and their factor corners. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildAtomic +open BoundedHochschild BoundedHochschild.WeakAlgebra HochschildSakai +open HochschildCorners HochschildMatrixSystems.MatrixSystem +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def center : StarSubalgebra ℂ M where + carrier := {a | ∀ b : M, Commute a b} + zero_mem' := fun _ => Commute.zero_left _ + one_mem' := fun _ => Commute.one_left _ + add_mem' := fun ha hb x => (ha x).add_left (hb x) + mul_mem' := fun ha hb x => (ha x).mul_left (hb x) + algebraMap_mem' c := fun x => Algebra.commutes c x + star_mem' := fun ha x => by + have h := congrArg star (ha (star x)).eq + change star _*x=x*star _ + simpa only [star_mul,star_star] using h.symm + +instance center_closed : IsClosed (center (M:=M) : Set M) := by + change IsClosed {a : M | ∀ b : M, a*b=b*a} + simp only [Set.ofPred_forall] + exact isClosed_iInter fun b => isClosed_eq + (continuous_id.mul continuous_const) (continuous_const.mul continuous_id) + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +lemma centerClosure_eq + (P : X →L⋆[ℂ] X) (hP : ∀ a z, e.symm (star a) z=star (e.symm a (P z))) : + WeakAlgebra.closure e center (mul_hasPreadjoint e) (mul_right_hasPreadjoint e) P hP=center := by + apply le_antisymm + · intro x hx b + have hclosed : IsClosed {f : WeakDual ℂ X | + (weakEquiv e).symm (b*weakEquiv e f) = (weakEquiv e).symm (weakEquiv e f*b)} := + isClosed_eq (normal_continuous e _ (mul_hasPreadjoint e b)) + (normal_continuous e _ (mul_right_hasPreadjoint e b)) + have hs : (linearClosure e center : Set (WeakDual ℂ X)) ⊆ + {f | (weakEquiv e).symm (b*weakEquiv e f) = (weakEquiv e).symm (weakEquiv e f*b)} := by + apply closure_minimal _ hclosed + rintro f ⟨a,ha,rfl⟩ + change (weakEquiv e).symm (b*weakEquiv e ((weakEquiv e).symm a)) = + (weakEquiv e).symm (weakEquiv e ((weakEquiv e).symm a)*b) + simpa only [LinearEquiv.apply_symm_apply] using congrArg (weakEquiv e).symm (ha b).eq.symm + have hh := (weakEquiv e).symm.injective (hs hx) + change x*b=b*x + simpa only [LinearEquiv.apply_symm_apply] using hh.symm + · intro x hx + exact mem_linearClosure e center hx + +def CenterPredual := X ⧸ WeakSubspace.preannihilator (linearClosure e center) +instance : NormedAddCommGroup (CenterPredual e) := inferInstanceAs + (NormedAddCommGroup (X ⧸ WeakSubspace.preannihilator (linearClosure e center))) +instance : NormedSpace ℂ (CenterPredual e) := inferInstanceAs + (NormedSpace ℂ (X ⧸ WeakSubspace.preannihilator (linearClosure e center))) +instance : CompleteSpace (CenterPredual e) := inferInstanceAs + (CompleteSpace (X ⧸ WeakSubspace.preannihilator (linearClosure e center))) + +def centerPredualEquiv : StrongDual ℂ (CenterPredual e) ≃ₗᵢ⋆[ℂ] (center (M:=M)) := by + let H := exists_abstract_star_preadjoint e + let P := Classical.choose H + have hP := (Classical.choose_spec H).2 + exact (predualEquiv e center (mul_hasPreadjoint e) (mul_right_hasPreadjoint e) P hP).trans + (subalgebraIsoOfEq _ _ (centerClosure_eq e P hP)) + +include e in + +theorem scalar_center_of_projections + (hp : ∀ p : M, IsStarProjection p → (∀ b : M, Commute p b) → p=0 ∨ p=1) : + ∀ a : M, (∀ b : M, Commute a b) → ∃ c : ℂ, a=c • (1:M) := by + intro a ha + let Z := center (M:=M) + let S : Submodule ℂ Z := Submodule.span ℂ {(1:Z)} + have hfinite : FiniteDimensional ℂ S := FiniteDimensional.span_singleton ℂ (1:Z) + let := hfinite + have hclosed : IsClosed (S : Set Z) := Submodule.closed_of_finiteDimensional S + have hpro : Submodule.span ℂ {p : Z | IsStarProjection p} ≤ S := by + apply Submodule.span_le.mpr + intro p hpZ + have hpM : IsStarProjection (p:M) := ⟨congrArg (fun z : Z => (z:M)) hpZ.isIdempotentElem.eq, + congrArg (fun z : Z => (z:M)) hpZ.isSelfAdjoint.star_eq⟩ + rcases hp p hpM p.property with hz | ho + · have he : p=0 := Subtype.ext hz + rw [he]; exact S.zero_mem + · have he : p=1 := Subtype.ext ho + rw [he]; exact Submodule.subset_span (Set.mem_singleton _) + have hall : (⊤ : Submodule ℂ Z) ≤ S := by + rw [← projection_span_dense (centerPredualEquiv e)] + exact Submodule.topologicalClosure_minimal _ hpro hclosed + have had : (⟨a,ha⟩ : Z) ∈ S := hall (Submodule.mem_top) + obtain ⟨c,hc⟩ := Submodule.mem_span_singleton.mp had + exact ⟨c,(congrArg (fun z : Z => (z:M)) hc).symm⟩ + +def CentralAtom (p : M) : Prop := + IsStarProjection p ∧ (∀ b : M, Commute p b) ∧ p ≠ 0 ∧ + ∀ q : M, IsStarProjection q → (∀ b : M, Commute q b) → q ≤ p → q=0 ∨ q=p + +omit [PartialOrder M] [StarOrderedRing M] in +lemma corner_central_coe {p : M} (hp : IsStarProjection p) + (hpc : ∀ b : M, Commute p b) (a : Corner p hp) + (ha : ∀ b : Corner p hp, Commute a b) : ∀ b : M, Commute (a:M) b := by + intro b + have he := congrArg (fun z : Corner p hp => (z:M)) + (ha ⟨p*b*p,compress_mem_corner hp b⟩).eq + change (a:M)*(p*b*p)=(p*b*p)*(a:M) at he + have hl : (a:M)*(p*b*p)=(a:M)*b := by + rw [← mul_assoc,← mul_assoc,a.property.2,mul_assoc,← (hpc b).eq, + ← mul_assoc,a.property.2] + have hr : (p*b*p)*(a:M)=b*(a:M) := by + rw [mul_assoc,a.property.1,(hpc b).eq,mul_assoc,a.property.1] + change (a:M)*b=b*(a:M) + exact hl.symm.trans (he.trans hr) + +include e in +theorem central_atom_corner_factor {p : M} (hp : CentralAtom p) : + ∀ a : Corner p hp.1, (∀ b : Corner p hp.1, Commute a b) → + ∃ c : ℂ, a=c • (1 : Corner p hp.1) := by + apply scalar_center_of_projections (cornerPredualEquiv p hp.1 e) + intro q hq hqc + rcases hp.2.2.2 q (corner_projection_coe p hp.1 hq) + (corner_central_coe hp.1 hp.2.1 q hqc) (corner_projection_le p hp.1 hq) with h0 | h1 + · exact Or.inl (Subtype.ext h0) + · exact Or.inr (Subtype.ext h1) + +end HochschildAtomic + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralBlockSpans.lean b/lean/OAI/Analysis/BoundedHochschild/CentralBlockSpans.lean new file mode 100644 index 0000000000000000000000000000000000000000..fdf2641064f4b20bd0b910597b53b8ff09358c19 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralBlockSpans.lean @@ -0,0 +1,63 @@ +import OAI.Analysis.BoundedHochschild.CentralBlockUnitaries + +namespace OAI + +/-! Matrix coefficients in the span of finite block unitary groups. -/ + +noncomputable section + +open scoped BigOperators + +namespace BoundedHochschild +namespace KadisonRingrose + +variable {M I G : Type*} [CStarAlgebra M] [Fintype I] [Group G] + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (hc : ∀ i a, p i * a = a * p i) + (ho : ∀ i j, i ≠ j → p i * p j = 0) + (hs : ∑ i, p i = 1) (ρ : G →* unitary M) + +def centralBlockSpan : Submodule ℂ M := Submodule.span ℂ + (Set.range (fun a : I → G => (centralBlockHom p hp hc ho hs ρ a : M))) + +lemma centralBlock_unitary_mem_span (a : I → G) : + centralBlock p (fun i => (ρ (a i) : M)) ∈ centralBlockSpan p hp hc ho hs ρ := + Submodule.subset_span ⟨a, rfl⟩ + +lemma centralBlock_component_mem_span (j : I) (g z : G) (hz : (ρ z : M) = -1) : + p j * (ρ g : M) ∈ centralBlockSpan p hp hc ho hs ρ := by + classical + let a : I → G := fun _ => g + let b : I → G := Function.update a j (z * g) + have hdiff : centralBlock p (fun i => (ρ (a i) : M)) - + centralBlock p (fun i => (ρ (b i) : M)) = (2 : ℂ) • (p j * (ρ g : M)) := by + rw [centralBlock, centralBlock, ← Finset.sum_sub_distrib, Finset.sum_eq_single j] + · simp only [a, b, Function.update_self, map_mul, Submonoid.coe_mul, hz, + neg_one_mul, mul_neg, sub_neg_eq_add, two_smul] + · intro k _ hkj + simp only [b, Function.update_of_ne hkj, sub_self] + · simp + have h := (centralBlockSpan p hp hc ho hs ρ).sub_mem + (centralBlock_unitary_mem_span p hp hc ho hs ρ a) + (centralBlock_unitary_mem_span p hp hc ho hs ρ b) + rw [hdiff] at h + have h' := (centralBlockSpan p hp hc ho hs ρ).smul_mem (2⁻¹ : ℂ) h + simpa only [smul_smul, inv_mul_cancel₀ (by norm_num : (2 : ℂ) ≠ 0), one_smul] using h' + +lemma centralBlock_mul_mem_span (j : I) (z : G) (hz : (ρ z : M) = -1) + {a : M} (ha : a ∈ Submodule.span ℂ (Set.range (fun g : G => (ρ g : M)))) : + p j * a ∈ centralBlockSpan p hp hc ho hs ρ := by + let S := (centralBlockSpan p hp hc ho hs ρ).comap + (ContinuousLinearMap.mul ℂ M (p j)).toLinearMap + have hle : Submodule.span ℂ (Set.range (fun g : G => (ρ g : M))) ≤ S := by + apply Submodule.span_le.mpr + rintro _ ⟨g, rfl⟩ + exact centralBlock_component_mem_span p hp hc ho hs ρ j g z hz + exact hle ha + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralBlockUnitaries.lean b/lean/OAI/Analysis/BoundedHochschild/CentralBlockUnitaries.lean new file mode 100644 index 0000000000000000000000000000000000000000..dbc66fe5dad97319b3ef2d852e9c48ba3a8d1d8d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralBlockUnitaries.lean @@ -0,0 +1,81 @@ +import OAI.Analysis.BoundedHochschild.FiniteUnitaryPrimitives + +namespace OAI + +/-! Finite groups assembled across finite central partitions. -/ + +noncomputable section + +open scoped BigOperators + +namespace BoundedHochschild +namespace KadisonRingrose + +variable {M I G : Type*} [CStarAlgebra M] [Fintype I] + [Group G] + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (hc : ∀ i a, p i * a = a * p i) + (ho : ∀ i j, i ≠ j → p i * p j = 0) + (hs : ∑ i, p i = 1) + +def centralBlock (a : I → M) : M := ∑ i, p i * a i + +include hp hc ho in +lemma centralBlock_mul (a b : I → M) : + centralBlock p a * centralBlock p b = centralBlock p (fun i => a i * b i) := by + classical + have ht (i j : I) : (p i * a i) * (p j * b j) = + if i = j then p i * (a i * b i) else 0 := by + have he : (p i * a i) * (p j * b j) = (p i * p j) * (a i * b j) := by + calc + _ = p i * (a i * p j) * b j := by noncomm_ring + _ = p i * (p j * a i) * b j := by rw [hc j (a i)] + _ = _ := by noncomm_ring + rw [he] + by_cases hij : i = j + · subst j + rw [ite_eq_left rfl, (hp i).isIdempotentElem.eq] + · rw [ite_eq_right hij, ho i j hij, zero_mul] + simp [centralBlock, Finset.sum_mul, Finset.mul_sum, ht] + +include hp hc in +lemma centralBlock_star (a : I → M) : + star (centralBlock p a) = centralBlock p (fun i => star (a i)) := by + simp only [centralBlock, star_sum, star_mul] + apply Finset.sum_congr rfl + intro i _ + rw [(hp i).isSelfAdjoint.star_eq, hc] + +include hs in +lemma centralBlock_one : centralBlock p (fun _ => 1) = 1 := by + simpa only [centralBlock, mul_one] using hs + +variable (ρ : G →* unitary M) + +include hp hc ho hs in +lemma centralBlock_mem_unitary (a : I → G) : + centralBlock p (fun i => (ρ (a i) : M)) ∈ unitary M := by + constructor + · rw [centralBlock_star p hp hc, centralBlock_mul p hp hc ho] + simpa only [Unitary.coe_star_mul_self] using centralBlock_one p hs + · rw [centralBlock_star p hp hc, centralBlock_mul p hp hc ho] + have hm (i : I) : (ρ (a i) : M) * star (ρ (a i) : M) = 1 := + Unitary.mul_star_self_of_mem (ρ (a i)).property + simpa only [hm] using centralBlock_one p hs + +def centralBlockHom : (I → G) →* unitary M where + toFun a := ⟨centralBlock p (fun i => (ρ (a i) : M)), + centralBlock_mem_unitary p hp hc ho hs ρ a⟩ + map_one' := Subtype.ext (by + simpa only [Pi.one_apply, map_one, Submonoid.coe_one] using centralBlock_one p hs) + map_mul' a b := Subtype.ext (by + simpa only [Pi.mul_apply, map_mul, Submonoid.coe_mul] using + (centralBlock_mul p hp hc ho (fun i => (ρ (a i) : M)) + (fun i => (ρ (b i) : M))).symm) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralColumnCuts.lean b/lean/OAI/Analysis/BoundedHochschild/CentralColumnCuts.lean new file mode 100644 index 0000000000000000000000000000000000000000..1addd43231dd42ca1a172521024e9089bfb62683 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralColumnCuts.lean @@ -0,0 +1,60 @@ +import OAI.Analysis.BoundedHochschild.TypeICentralPieces +import OAI.Analysis.BoundedHochschild.OrthogonalProjectionSums + +namespace OAI + +/-! Extracting homogeneous central pieces from finite column families. -/ + +noncomputable section + +open scoped ComplexOrder BigOperators + +namespace BoundedHochschild +namespace KadisonRingrose + +open FinitePathMain HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +/-- If a central cut annihilates the residual of a finite abelian column +family, the cut is a finite homogeneous type I summand. -/ +theorem homogeneousCorner_of_annihilated_residual {p z : M} (hp : AbelianProjection p) + (hz : CentralProjection z) (hz0 : z ≠ 0) {n : ℕ} + (v : Fin n → PartialIso M) (hi : ∀ i, (v i).initial = p) + (ho : ∀ i j, i ≠ j → (v i).final * (v j).final = 0) + (hann : z * (1 - ∑ i, (v i).final) = 0) : HomogeneousTypeICorner z := by + classical + have hn : 0 < n := by + by_contra hn + have hn0 : n = 0 := by omega + subst n + exact hz0 (by simpa using hann) + let w (i : Fin n) := centralCutPartialIso z hz.1 (fun a => (hz.2 a).eq) (v i) + have hzp : IsStarProjection (z * p) := hz.1.mul hp.1 (hz.2 p) + have hzpp : z * p ≤ p := (hzp.le_iff_mul_eq_left hp.1).mpr + (by rw [mul_assoc, hp.1.isIdempotentElem.eq]) + have hpz : z * p ≤ z := (hzp.le_iff_mul_eq_right hz.1).mpr + (by rw [← mul_assoc, hz.1.isIdempotentElem.eq]) + have hwi (i : Fin n) : (w i).initial = z * p := by + simp only [w, centralCutPartialIso_initial, hi] + have hwf (i : Fin n) : (w i).final ≤ z := by + apply ((w i).final_proj.le_iff_mul_eq_right hz.1).mpr + simp only [w, centralCutPartialIso_final] + rw [← mul_assoc, hz.1.isIdempotentElem.eq] + have hwo (i j : Fin n) (hij : i ≠ j) : (w i).final * (w j).final = 0 := by + simp only [w, centralCutPartialIso_final] + rw [central_idempotent_mul z hz.1.isIdempotentElem.eq (fun a => (hz.2 a).eq), + ho i j hij, mul_zero] + have hws : ∑ i, (w i).final = z := by + simp only [w, centralCutPartialIso_final, ← Finset.mul_sum] + rw [mul_sub, mul_one, sub_eq_zero] at hann + exact hann.symm + exact homogeneousCorner_of_columns hz.1 (HochschildTypeII.abelian_of_le hp hzp hzpp) + hpz ⟨0, hn⟩ w hwi hwf hwo hws + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralComparison.lean b/lean/OAI/Analysis/BoundedHochschild/CentralComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..3d3434fcf0a274d2d8789d698ad110a78d66c61d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralComparison.lean @@ -0,0 +1,161 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.Frames +import OAI.Analysis.BoundedHochschild.CentralSeparation + +namespace OAI + +/-! Comparison of projections using central weighted traces. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCentralComparison +open BoundedHochschild HochschildRigidity HochschildComparison FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma orthogonal_of_le_sub {p r t : M} + (hp : IsStarProjection p) (hr : IsStarProjection r) (ht : IsStarProjection t) + (hrp : r ≤ p) (htr : t ≤ p-r) : r*t=0 := by + have hpr := (hr.le_iff_sub hp).mp hrp + have hh := (ht.le_iff_mul_eq_right hpr).mp htr + calc + r*t = r*((p-r)*t) := by rw [hh] + _ = (r*p-r*r)*t := by noncomm_ring + _ = 0 := by rw [(hr.le_iff_mul_eq_left hp).mp hrp,hr.isIdempotentElem.eq,sub_self,zero_mul] + +include e hτ htr hfaith in +lemma exists_maximal_partialIso {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) : + ∃ v : PartialIso M, v.initial ≤ p ∧ v.final ≤ q ∧ + ∀ a : M, (q-v.final)*a*(p-v.initial)=0 := by + classical + let S : Set (PartialIso M) := {v | v.initial ≤ p ∧ v.final ≤ q} + have hz : (0 : PartialIso M) ∈ S := + ⟨by simpa using hp.nonneg,by simpa using hq.nonneg⟩ + obtain ⟨v,_hz,hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain y hy => by + obtain ⟨s,hsp,hsq,hsup⟩ := PartialIso.chain_upper e τ (HochschildSakai.mul_hasPreadjoint e) + hτ htr hfaith hp hq c hchain ⟨y,hy⟩ (fun z hz => hc hz) + exact ⟨s,⟨hsp,hsq⟩,hsup⟩) 0 hz + have hvp : v.initial ≤ p := hmax.1.1 + have hvq : v.final ≤ q := hmax.1.2 + refine ⟨v,hvp,hvq,fun a => ?_⟩ + by_contra ha + have hp' := (v.initial_proj.le_iff_sub hp).mp hvp + have hq' := (v.final_proj.le_iff_sub hq).mp hvq + obtain ⟨w,hw0,hwp,hwq⟩ := partialIso_of_nonzero_corner e hq' hp' + ((q-v.final)*a*(p-v.initial)) ha + (by rw [← mul_assoc,← mul_assoc,hq'.isIdempotentElem.eq]) + (by rw [mul_assoc,hp'.isIdempotentElem.eq]) + have hi := orthogonal_of_le_sub hp v.initial_proj w.initial_proj hvp hwp + have hf := orthogonal_of_le_sub hq v.final_proj w.final_proj hvq hwq + have hs : v.orthogonalSum w hi hf ∈ S := by + constructor + · rw [PartialIso.orthogonalSum_initial] + calc + v.initial+w.initial ≤ v.initial+(p-v.initial) := add_le_add_right hwp _ + _ = p := by abel + · rw [PartialIso.orthogonalSum_final] + calc + v.final+w.final ≤ v.final+(q-v.final) := add_le_add_right hwq _ + _ = q := by abel + have hle := v.le_orthogonalSum w hi hf + have he := le_antisymm (hmax.2 hs hle) hle + have hvw : (v : M)+w=v := congrArg (fun z : PartialIso M => (z : M)) he + exact hw0 (add_eq_left.mp hvw) + +include e hτ htr hfaith in + +theorem central_comparison {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) : + ∃ (z : M) (v : PartialIso M), CentralProjection z ∧ v.initial ≤ p ∧ v.final ≤ q ∧ + z*v.final=z*q ∧ (1-z)*v.initial=(1-z)*p := by + obtain ⟨v,hvp,hvq,horth⟩ := exists_maximal_partialIso e τ hτ htr hfaith hp hq + have hp' := (v.initial_proj.le_iff_sub hp).mp hvp + have hq' := (v.final_proj.le_iff_sub hq).mp hvq + have horth' : ∀ a : M, (p-v.initial)*a*(q-v.final)=0 := by + intro a + have hh := congrArg star (horth (star a)) + simpa only [star_mul,star_star,star_zero,hp'.isSelfAdjoint.star_eq, + hq'.isSelfAdjoint.star_eq,mul_assoc] using hh + obtain ⟨z,hz,hpz,hzq⟩ := central_separator e τ hτ htr hfaith hp' hq' horth' + have hzp : z*(p-v.initial)=p-v.initial := (hp'.le_iff_mul_eq_right hz.1).mp hpz + refine ⟨z,v,hz,hvp,hvq,?_,?_⟩ + · exact (sub_eq_zero.mp (by simpa only [mul_sub] using hzq)).symm + · have hh : (1-z)*(p-v.initial)=0 := by rw [sub_mul,one_mul,hzp,sub_self] + exact (sub_eq_zero.mp (by simpa only [mul_sub] using hh)).symm + +omit [StarOrderedRing M] in +include htr in +lemma central_weighted_trace_partialIso (v : PartialIso M) (z : M) + (hz : ∀ a : M, Commute z a) : τ (z*v.initial)=τ (z*v.final) := by + change τ (z*(star (v:M)*(v:M)))=τ (z*((v:M)*star (v:M))) + calc + _ = τ ((z*star (v:M))*(v:M)) := by rw [mul_assoc] + _ = τ ((v:M)*(z*star (v:M))) := htr _ _ + _ = τ (z*((v:M)*star (v:M))) := by rw [← mul_assoc,← (hz (v:M)).eq,mul_assoc] + +include e hτ htr hfaith in + +theorem subequivalent_of_central_trace_le {p q : M} + (hp : IsStarProjection p) (hq : IsStarProjection q) + (ht : ∀ z : M, CentralProjection z → (τ (z*p)).re ≤ (τ (z*q)).re) : + ∃ v : PartialIso M, v.initial=p ∧ v.final ≤ q := by + obtain ⟨v,hvp,hvq,horth⟩ := exists_maximal_partialIso e τ hτ htr hfaith hp hq + have hp' := (v.initial_proj.le_iff_sub hp).mp hvp + have hq' := (v.final_proj.le_iff_sub hq).mp hvq + have horth' : ∀ a : M, (p-v.initial)*a*(q-v.final)=0 := by + intro a + have hh := congrArg star (horth (star a)) + simpa only [star_mul,star_star,star_zero,hp'.isSelfAdjoint.star_eq, + hq'.isSelfAdjoint.star_eq,mul_assoc] using hh + obtain ⟨z,hz,hpz,hzq⟩ := central_separator e τ hτ htr hfaith hp' hq' horth' + have hzp : z*(p-v.initial)=p-v.initial := (hp'.le_iff_mul_eq_right hz.1).mp hpz + have ht' := ht z hz + have he := central_weighted_trace_partialIso τ htr v z hz.2 + have hzqt : τ (z*q)=τ (z*v.final) := by + have hh := congrArg τ hzq + simpa only [mul_sub,map_sub,map_zero,sub_eq_zero] using hh + have hzero : τ (p-v.initial)=0 := by + apply Complex.ext + · change (τ (p-v.initial)).re=0 + have heq : (τ (p-v.initial)).re=(τ (z*p)).re-(τ (z*v.initial)).re := by + rw [← hzp,mul_sub,map_sub,Complex.sub_re] + have hn := Complex.re_le_re (τ.map_nonneg hp'.nonneg) + change 0 ≤ (τ (p-v.initial)).re at hn + rw [hzqt,← he] at ht' + rw [heq] + linarith + · exact (τ.map_nonneg hp'.nonneg).2.symm + have hpzero : p-v.initial=0 := hfaith _ (by + simpa only [hp'.isSelfAdjoint.star_eq,hp'.isIdempotentElem.eq] using hzero) + exact ⟨v,(sub_eq_zero.mp hpzero).symm,hvq⟩ + +include e hτ htr hfaith in +theorem equivalent_of_central_trace_eq {p q : M} + (hp : IsStarProjection p) (hq : IsStarProjection q) + (ht : ∀ z : M, CentralProjection z → τ (z*p)=τ (z*q)) : + ∃ v : M, star v*v=p ∧ v*star v=q := by + obtain ⟨v,hv,hvq⟩ := subequivalent_of_central_trace_le e τ hτ htr hfaith hp hq + (fun z hz => le_of_eq (congrArg Complex.re (ht z hz))) + have he : τ v.initial=τ v.final := htr _ _ + have ht1 : τ p=τ q := by + simpa only [one_mul] using ht 1 ⟨IsStarProjection.one M,fun a => Commute.one_left a⟩ + have hback : q ≤ v.final := by + apply HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith hq v.final_proj + (Or.inr hvq) + rw [← he,hv,ht1] + exact ⟨v,hv,le_antisymm hvq hback⟩ + +end HochschildCentralComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralHomotopy.lean b/lean/OAI/Analysis/BoundedHochschild/CentralHomotopy.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc8daf12424bc69791fd8024cb96cb00c66390fa --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralHomotopy.lean @@ -0,0 +1,652 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.Cochains +import OAI.Analysis.BoundedHochschild.CollisionBounds + +namespace OAI + +/-! The Hochschild differential and homotopies for central idempotents. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open Filter Topology +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + + +def centralCut {n : ℕ} (z : M) (f : Cochain M n) : Cochain M n := + f.compContinuousLinearMap (fun _ => ContinuousLinearMap.mul ℂ M z) + +@[simp] lemma centralCut_apply {n : ℕ} (z : M) (f : Cochain M n) (v : Fin n → M) : + centralCut z f v = f (fun i => z*v i) := rfl + +lemma norm_centralCut_le {n : ℕ} (z : M) (hz : ‖z‖ ≤ 1) (f : Cochain M n) : + ‖centralCut z f‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro v + apply (f.le_opNorm _).trans + apply mul_le_mul_of_nonneg_left _ (norm_nonneg _) + apply Finset.prod_le_prod₀ (fun _ _ => norm_nonneg _) + intro i _ + exact (norm_mul_le _ _).trans (by nlinarith [norm_nonneg (v i)]) + +lemma central_mul_assoc (z : M) (hz : ∀ a, z*a=a*z) (a b : M) : + a*(z*b) = z*(a*b) := by rw [← mul_assoc, ← hz, mul_assoc] + +lemma central_idempotent_mul (z : M) (hi : z*z=z) (hz : ∀ a, z*a=a*z) (a b : M) : + (z*a)*(z*b) = z*(a*b) := by + rw [mul_assoc, central_mul_assoc z hz, ← mul_assoc z z, hi] + +lemma mergeInputs_central (z : M) (hi : z*z=z) (hz : ∀ a, z*a=a*z) + {n : ℕ} (v : Fin (n+1) → M) (j : Fin n) : + mergeInputs (fun i => z*v i) j = fun i => z*mergeInputs v j i := by + funext i + simp only [mergeInputs] + split_ifs <;> first | rfl | exact central_idempotent_mul z hi hz _ _ + + + +theorem differential_centralCut {n : ℕ} (z : M) (hi : z*z=z) (hz : ∀ a, z*a=a*z) + (f : Cochain M n) (hr : ∀ v, z*f v=f v) (v : Fin (n+1) → M) : + differentialValue (centralCut z f) v = differentialValue f (fun i => z*v i) := by + simp only [differentialValue, centralCut_apply, mergeInputs_central z hi hz] + congr 2 + · rw [mul_assoc, ← central_mul_assoc z hz, hr] + · rw [← mul_assoc, ← hz, hr] + +lemma centralCut_cocycle {n : ℕ} (z : M) (hi : z*z=z) (hz : ∀ a, z*a=a*z) + (f : Cochain M n) (hr : ∀ v, z*f v=f v) + (hf : ∀ v, differentialValue f v = 0) : + ∀ v, differentialValue (centralCut z f) v = 0 := by + intro v + rw [differential_centralCut z hi hz f hr] + exact hf _ + +end BoundedHochschild + + + +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + +def leftCoboundary {n : ℕ} (f : Cochain M n) : Cochain M (n+1) := + (((ContinuousLinearMap.compContinuousMultilinearMapL ℂ (fun _ : Fin n => M) M M).flip f).comp + (ContinuousLinearMap.mul ℂ M)).uncurryLeft + +@[simp] lemma leftCoboundary_apply {n : ℕ} (f : Cochain M n) (v : Fin (n+1) → M) : + leftCoboundary f v = v 0 * f (fun i => v i.succ) := rfl + +def rightCoboundary {n : ℕ} (f : Cochain M n) : Cochain M (n+1) := + ((ContinuousLinearMap.mul ℂ M).compContinuousMultilinearMap f).uncurryRight + +@[simp] lemma rightCoboundary_apply {n : ℕ} (f : Cochain M n) (v : Fin (n+1) → M) : + rightCoboundary f v = f (fun i => v i.castSucc) * v (Fin.last n) := rfl + +def middleCoboundary {n : ℕ} (f : Cochain M (n+1)) (j : Fin (n+1)) : Cochain M (n+2) := + (((ContinuousMultilinearMap.curryMidEquiv ℂ (fun _ : Fin (n+1) => M) M j).symm.toContinuousLinearEquiv.toContinuousLinearMap).comp + ((ContinuousLinearMap.compL ℂ M M (Cochain M n) (f.curryMid j)).comp + (ContinuousLinearMap.mul ℂ M))).uncurryMid j.castSucc + +@[simp] lemma middleCoboundary_apply {n : ℕ} (f : Cochain M (n+1)) (j : Fin (n+1)) + (v : Fin (n+2) → M) : middleCoboundary f j v = f (mergeInputs v j) := by + change f (j.insertNth (v j.castSucc * v (j.castSucc.succAbove j)) + (fun i => v (j.castSucc.succAbove (j.succAbove i)))) = _ + congr 1 + apply (Fin.insertNth_eq_iff).mpr + constructor + · simp [mergeInputs, Fin.succAbove_of_le_castSucc] + · funext i + change v (j.castSucc.succAbove (j.succAbove i)) = mergeInputs v j (j.succAbove i) + by_cases h : i.castSucc < j + · rw [Fin.succAbove_of_castSucc_lt _ _ h] + have h' : i.castSucc.castSucc < j.castSucc := by simpa using h + rw [Fin.succAbove_of_castSucc_lt _ _ h'] + simp [mergeInputs, h] + · have hj : j ≤ i.castSucc := le_of_not_gt h + rw [Fin.succAbove_of_le_castSucc _ _ hj] + have h' : j.castSucc ≤ i.succ.castSucc := by + simp only [Fin.le_def, Fin.val_castSucc, Fin.val_succ] at * + omega + rw [Fin.succAbove_of_le_castSucc _ _ h'] + have hh : ¬i.succ < j := by + simp only [Fin.lt_def, Fin.val_succ, Fin.le_def, Fin.val_castSucc] at * + omega + have hn : i.succ ≠ j := by + intro he; have he' := congrArg Fin.val he + simp only [Fin.val_succ] at he' + have := j.isLt + simp only [Fin.le_def, Fin.val_castSucc] at hj + omega + simp [mergeInputs, hh, hn] + +def differential : {n : ℕ} → Cochain M n → Cochain M (n+1) + | 0, f => leftCoboundary f - rightCoboundary f + | n+1, f => leftCoboundary f + ∑ j : Fin (n+1), ((-1:ℂ)^(j.val+1)) • middleCoboundary f j + + ((-1:ℂ)^(n+1+1)) • rightCoboundary f + +@[simp] theorem differential_apply {n : ℕ} (f : Cochain M n) (v : Fin (n+1) → M) : + differential f v = differentialValue f v := by + cases n with + | zero => simp [differential, differentialValue, sub_eq_add_neg] + | succ n => simp only [differential, differentialValue, add_apply, sum_apply, smul_apply, + leftCoboundary_apply, rightCoboundary_apply, middleCoboundary_apply] + +end BoundedHochschild + + + +namespace BoundedHochschild +variable {M : Type*} + +def tupleInsert {n : ℕ} (p : Fin (n+1)) (a : M) (v : Fin n → M) (i : Fin (n+1)) : M := + if h : i.val < p.val then v ⟨i.val, by omega⟩ + else if h : i = p then a else v ⟨i.val-1, by have := i.isLt; have := p.isLt; omega⟩ + +lemma tupleInsert_eq {n : ℕ} (p : Fin (n+1)) (a : M) (v : Fin n → M) : + tupleInsert p a v = p.insertNth a v := by + apply (Fin.eq_insertNth_iff).mpr + constructor + · simp [tupleInsert] + · funext i + change tupleInsert p a v (p.succAbove i) = v i + by_cases h : i.castSucc < p + · rw [Fin.succAbove_of_castSucc_lt _ _ h] + dsimp [tupleInsert] + rw [dite_eq_left (show i.val < p.val from h)] + · rw [Fin.succAbove_of_le_castSucc _ _ (le_of_not_gt h)] + dsimp [tupleInsert] + rw [dite_eq_right (by change ¬i.val < p.val at h; omega), + ite_eq_right (by intro he; have hv := congrArg Fin.val he; dsimp at hv; change ¬i.val < p.val at h; omega)] + +lemma tupleInsert_lt {n : ℕ} (p : Fin (n+1)) (a : M) (v : Fin n → M) + (i : Fin (n+1)) (h : i.val < p.val) : + Fin.insertNth (α := fun _ => M) p a v i = v ⟨i.val, by omega⟩ := by + rw [← tupleInsert_eq] + simp only [tupleInsert, dite_eq_left h] + +lemma tupleInsert_gt {n : ℕ} (p : Fin (n+1)) (a : M) (v : Fin n → M) + (i : Fin (n+1)) (h : p.val < i.val) : + Fin.insertNth (α := fun _ => M) p a v i = v ⟨i.val-1, by have := i.isLt; omega⟩ := by + rw [← tupleInsert_eq] + simp only [tupleInsert, dite_eq_right (by omega : ¬i.val < p.val), + dite_eq_right (by intro he; have := congrArg Fin.val he; omega : i ≠ p)] + +lemma merge_insert_same [Mul M] {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) (q : M) + (hq : q*v r=v r) : mergeInputs (r.castSucc.insertNth q v) r = v := by + funext i + simp only [mergeInputs] + split_ifs with h h + · rw [tupleInsert_lt _ _ _ _ (by simpa only [Fin.val_castSucc, Fin.lt_def] using h)] + rfl + · subst i + rw [Fin.insertNth_apply_same, tupleInsert_gt _ _ _ _ (by simp)] + simpa using hq + · rw [tupleInsert_gt _ _ _ _ (by simpa only [Fin.val_castSucc,Fin.val_succ] using + (show r.val < i.val+1 by omega))] + rfl + +lemma merge_insert_before [Mul M] {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) + (q : M) (j : Fin n) (hjr : j.val+1 < r.val) : + mergeInputs (r.castSucc.insertNth q v) (r.succAbove j) = + (⟨r.val-1, by omega⟩ : Fin (n+1)).insertNth q (mergeInputs v j) := by + have hs : r.succAbove j=j.castSucc := by + exact Fin.succAbove_of_castSucc_lt _ _ (by simpa only [Fin.lt_def, Fin.val_castSucc] using (show j.val < r.val by omega)) + rw [hs] + funext i + simp only [mergeInputs, ← tupleInsert_eq, tupleInsert, Fin.lt_def, Fin.val_castSucc, + Fin.val_succ, Fin.ext_iff] + split_ifs <;> try omega + all_goals first | rfl | congr 1 + all_goals exact Fin.ext (by dsimp; omega) + +lemma merge_insert_after [Mul M] {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) + (q : M) (j : Fin n) (hjr : r.val ≤ j.val) : + mergeInputs (r.castSucc.insertNth q v) (r.succAbove j) = + (⟨r.val, by omega⟩ : Fin (n+1)).insertNth q (mergeInputs v j) := by + have hs : r.succAbove j=j.succ := by + exact Fin.succAbove_of_le_castSucc _ _ (by simpa only [Fin.le_def, Fin.val_castSucc] using hjr) + rw [hs] + funext i + simp only [mergeInputs, ← tupleInsert_eq, tupleInsert, Fin.lt_def, Fin.val_castSucc, + Fin.val_succ, Fin.ext_iff] + split_ifs <;> try omega + all_goals first | rfl | congr 1 + all_goals first | rfl | (apply Fin.ext; dsimp; omega) | + (apply congrArg v; apply Fin.ext; dsimp; omega) + +lemma tail_insert {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) (q : M) + (hr : 0 < r.val) : + (fun i : Fin (n+1) => (r.castSucc.insertNth (α := fun _ => M) q v) i.succ) = + (⟨r.val-1, by omega⟩ : Fin (n+1)).insertNth (α := fun _ => M) q (fun i => v i.succ) := by + funext i + simp only [← tupleInsert_eq, tupleInsert, Fin.val_succ, Fin.val_castSucc, Fin.ext_iff] + split_ifs <;> try omega + all_goals first | rfl | congr 1 + all_goals exact Fin.ext (by dsimp; omega) + +lemma init_insert {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) (q : M) : + (fun i : Fin (n+1) => (r.castSucc.insertNth (α := fun _ => M) q v) i.castSucc) = + r.insertNth (α := fun _ => M) q (fun i => v i.castSucc) := by + funext i + simp only [← tupleInsert_eq, tupleInsert, Fin.val_castSucc, Fin.ext_iff] + split_ifs <;> rfl + +lemma last_insert {n : ℕ} (v : Fin (n+1) → M) (r : Fin (n+1)) (q : M) : + (r.castSucc.insertNth (α := fun _ => M) q v) (Fin.last (n+1)) = v (Fin.last n) := by + rw [tupleInsert_gt _ _ _ _ (by simp only [Fin.val_castSucc,Fin.val_last]; omega)] + rfl + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + + +def centralJTerm {n : ℕ} (z q : M) (f : Cochain M (n+1)) (i : Fin n) : Cochain M n := + (f.curryMid i.castSucc q).compContinuousLinearMap (fun j => + if j < i then ContinuousLinearMap.mul ℂ M z + else if j = i then ContinuousLinearMap.mul ℂ M q + else ContinuousLinearMap.id ℂ M) + +@[simp] lemma centralJTerm_apply {n : ℕ} (z q : M) (f : Cochain M (n+1)) + (i : Fin n) (v : Fin n → M) : + centralJTerm z q f i v = f (i.castSucc.insertNth q (fun j => + if j < i then z*v j else if j = i then q*v j else v j)) := by + change f (i.castSucc.insertNth q (fun j => (if j < i then ContinuousLinearMap.mul ℂ M z + else if j = i then ContinuousLinearMap.mul ℂ M q else ContinuousLinearMap.id ℂ M) (v j))) = _ + apply congrArg (fun w => f (i.castSucc.insertNth q w)) + funext j + split_ifs <;> rfl + +def centralJ {n : ℕ} (z q : M) (f : Cochain M (n+1)) : Cochain M n := + ∑ i : Fin n, ((-1:ℂ)^(i.val+1)) • centralJTerm z q f i + +lemma norm_centralJTerm_le {n : ℕ} (z q : M) (hz : ‖z‖ ≤ 1) (hq : ‖q‖ ≤ 1) + (f : Cochain M (n+1)) (i : Fin n) : ‖centralJTerm z q f i‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro v + rw [centralJTerm_apply] + apply (f.norm_map_insertNth_le _ _).trans + calc + ‖f‖ * ‖q‖ * (∏ j, ‖if j < i then z*v j else if j = i then q*v j else v j‖) ≤ + ‖f‖ * 1 * (∏ j, ‖v j‖) := by + apply mul_le_mul + · exact mul_le_mul_of_nonneg_left hq (norm_nonneg _) + · apply Finset.prod_le_prod₀ (fun _ _ => norm_nonneg _) + intro j _ + split_ifs + · exact (norm_mul_le _ _).trans (by nlinarith [norm_nonneg (v j)]) + · exact (norm_mul_le _ _).trans (by nlinarith [norm_nonneg (v j)]) + · rfl + · positivity + · positivity + _ = _ := by ring + +lemma norm_centralJ_le {n : ℕ} (z q : M) (hz : ‖z‖ ≤ 1) (hq : ‖q‖ ≤ 1) + (f : Cochain M (n+1)) : ‖centralJ z q f‖ ≤ n*‖f‖ := by + apply (norm_sum_le _ _).trans + calc + ∑ i : Fin n, ‖((-1:ℂ)^(i.val+1)) • centralJTerm z q f i‖ ≤ + ∑ _ : Fin n, ‖f‖ := by + apply Finset.sum_le_sum + intro i _ + simpa only [norm_smul, norm_pow, norm_neg, norm_one, one_pow, one_mul] + using norm_centralJTerm_le z q hz hq f i + _ = _ := by simp + +lemma centralJ_range {n : ℕ} (z q : M) (f : Cochain M (n+1)) + (hr : ∀ v, z*f v=f v) (v : Fin n → M) : z*centralJ z q f v=centralJ z q f v := by + simp only [centralJ, sum_apply, smul_apply, centralJTerm_apply, Finset.mul_sum, + mul_smul_comm, hr] + +lemma centralJTerm_eq_zero_lt {n : ℕ} (z q : M) (hzq : q*z=0) + (f : Cochain M (n+1)) (i r : Fin n) (hir : i < r) (v : Fin n → M) + (hv : ∀ j, j < r → z*v j=v j) : centralJTerm z q f i v=0 := by + have hqi : q*v i=0 := by rw [← hv i hir, ← mul_assoc, hzq, zero_mul] + rw [centralJTerm_apply] + apply f.map_coord_zero ((i.castSucc).succAbove i) + simp only [Fin.insertNth_apply_succAbove, lt_self_iff_false, ite_false, ite_true, hqi] + +lemma centralJTerm_eq_zero_gt {n : ℕ} (z q : M) (hzq : z*q=0) + (f : Cochain M (n+1)) (i r : Fin n) (hri : r < i) (v : Fin n → M) + (hv : q*v r=v r) : centralJTerm z q f i v=0 := by + have hzr : z*v r=0 := by rw [← hv, ← mul_assoc, hzq, zero_mul] + rw [centralJTerm_apply] + apply f.map_coord_zero ((i.castSucc).succAbove r) + simp only [Fin.insertNth_apply_succAbove, hri, ite_true, hzr] + + + +lemma centralJ_first_q {n : ℕ} (z q : M) (hzq : z*q=0) (hqz : q*z=0) + (f : Cochain M (n+1)) (r : Fin n) (v : Fin n → M) + (hv : ∀ j, j < r → z*v j=v j) (hvr : q*v r=v r) : + centralJ z q f v = ((-1:ℂ)^(r.val+1)) • f (r.castSucc.insertNth q v) := by + classical + rw [centralJ, sum_apply, Finset.sum_eq_single r] + · simp only [smul_apply, centralJTerm_apply] + apply congrArg (fun w => ((-1:ℂ)^(r.val+1)) • f (r.castSucc.insertNth q w)) + funext j + split_ifs with h h + · exact hv j h + · subst j; exact hvr + · rfl + · intro i _ hir + rw [smul_apply] + have hi : centralJTerm z q f i v=0 := by + rcases lt_or_gt_of_ne hir with h | h + · exact centralJTerm_eq_zero_lt z q hqz f i r h v hv + · exact centralJTerm_eq_zero_gt z q hzq f i r h v hvr + rw [hi, smul_zero] + · simp + +lemma centralJ_all_z {n : ℕ} (z q : M) (hqz : q*z=0) + (f : Cochain M (n+1)) (v : Fin n → M) (hv : ∀ j, z*v j=v j) : + centralJ z q f v=0 := by + rw [centralJ, sum_apply] + apply Finset.sum_eq_zero + intro i _ + simp only [smul_apply] + have hi : centralJTerm z q f i v=0 := by + have hqi : q*v i=0 := by rw [← hv i, ← mul_assoc, hqz, zero_mul] + rw [centralJTerm_apply] + apply f.map_coord_zero ((i.castSucc).succAbove i) + simp only [Fin.insertNth_apply_succAbove, lt_self_iff_false, ite_false, ite_true, hqi] + rw [hi, smul_zero] + +end BoundedHochschild + + + +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + +lemma centralJ_merge_before {n : ℕ} (z q : M) (hzq : z*q=0) (hqz : q*z=0) + (f : Cochain M (n+1)) (v : Fin (n+1) → M) (r : Fin (n+1)) + (hv : ∀ i, i < r → z*v i=v i) (hvr : q*v r=v r) (j : Fin n) + (hjr : j.val+1 < r.val) : + centralJ z q f (mergeInputs v j) = ((-1:ℂ)^r.val) • + f (mergeInputs (r.castSucc.insertNth (α := fun _ => M) q v) (r.succAbove j)) := by + rw [merge_insert_before v r q j hjr] + let r' : Fin n := ⟨r.val-1, by omega⟩ + have hh : ∀ i, i < r' → z*mergeInputs v j i=mergeInputs v j i := by + intro i hi + simp only [mergeInputs] + split_ifs with h h + · exact hv i.castSucc (by simp only [Fin.lt_def, Fin.val_castSucc] at *; omega) + · subst i + rw [← mul_assoc, hv j.castSucc (by simp only [Fin.lt_def, Fin.val_castSucc]; omega)] + · exact hv i.succ (by simp only [r', Fin.lt_def,Fin.val_succ] at *; omega) + have hq : q*mergeInputs v j r'=mergeInputs v j r' := by + have hlo : ¬r' < j := by simp only [r', Fin.lt_def]; omega + have hne : r' ≠ j := by intro h; have hh := congrArg Fin.val h; dsimp [r'] at hh; omega + have he : r'.succ=r := Fin.ext (by dsimp [r']; omega) + simp only [mergeInputs, hlo, hne, ite_false, he] + exact hvr + rw [centralJ_first_q z q hzq hqz f r' _ hh hq] + have he : r'.val+1=r.val := by dsimp [r']; omega + rw [he] + rfl + +lemma centralJ_merge_after {n : ℕ} (z q : M) (hzq : z*q=0) (hqz : q*z=0) + (f : Cochain M (n+1)) (v : Fin (n+1) → M) (r : Fin (n+1)) + (hv : ∀ i, i < r → z*v i=v i) (hvr : q*v r=v r) (j : Fin n) + (hjr : r.val ≤ j.val) : + centralJ z q f (mergeInputs v j) = ((-1:ℂ)^(r.val+1)) • + f (mergeInputs (r.castSucc.insertNth (α := fun _ => M) q v) (r.succAbove j)) := by + rw [merge_insert_after v r q j hjr] + let r' : Fin n := ⟨r.val, by omega⟩ + have hh : ∀ i, i < r' → z*mergeInputs v j i=mergeInputs v j i := by + intro i hi + have hh : i M) q v) (r.succAbove j))=0 := by + have hjr' : j.succ=r := Fin.ext hjr + have hlt : j.castSucc M) q v) (r.succAbove j))) = + - (((-1:ℂ)^(j.val+1)) • centralJ z q f (mergeInputs v j)) := by + rcases lt_trichotomy (j.val+1) r.val with h | h | h + · rw [centralJ_merge_before z q hzq hqz f v r hv hvr j h] + rw [Fin.succAbove_of_castSucc_lt _ _ (by simp only [Fin.lt_def,Fin.val_castSucc]; omega)] + simp only [Fin.val_castSucc, smul_smul, ← neg_smul] + congr 1 + rw [pow_succ] + ring + · obtain ⟨h₁,h₂⟩ := centralJ_merge_boundary z q hzq hz f v r hv hvr j h + rw [h₁,h₂,smul_zero,smul_zero,smul_zero,neg_zero] + · have hrj : r.val ≤ j.val := by omega + rw [centralJ_merge_after z q hzq hqz f v r hv hvr j hrj] + rw [Fin.succAbove_of_le_castSucc _ _ (by simpa only [Fin.le_def,Fin.val_castSucc] using hrj)] + simp only [Fin.val_succ, smul_smul, ← neg_smul, pow_succ] + congr 1 + ring + +lemma centralJ_left_cancellation {n : ℕ} (z q : M) (hzq : z*q=0) (hqz : q*z=0) + (hz : ∀ a, z*a=a*z) (f : Cochain M (n+1)) (hr : ∀ w, z*f w=f w) + (v : Fin (n+1) → M) (r : Fin (n+1)) + (hv : ∀ i, i < r → z*v i=v i) (hvr : q*v r=v r) : + ((-1:ℂ)^(r.val+1)) • ((r.castSucc.insertNth (α := fun _ => M) q v) 0 * + f (fun i => (r.castSucc.insertNth (α := fun _ => M) q v) i.succ)) = + -(v 0 * centralJ z q f (fun i => v i.succ)) := by + by_cases hro : r.val=0 + · have hre : r=0 := Fin.ext hro + subst r + have hqf : ∀ w, q*f w=0 := by intro w; rw [← hr w, ← mul_assoc, hqz, zero_mul] + have hvrz : v 0*z=0 := by + rw [← hvr, mul_assoc, ← hz (v 0), ← mul_assoc, hqz, zero_mul] + have hrj := centralJ_range z q f hr (fun i => v i.succ) + have hh : v 0*centralJ z q f (fun i => v i.succ)=0 := by + rw [← hrj, ← mul_assoc, hvrz, zero_mul] + simp only [Fin.castSucc_zero, Fin.insertNth_apply_same, hqf, smul_zero, hh, neg_zero] + · have hro : 0 (r.castSucc.insertNth (α := fun _ => M) q v) i.castSucc) * + (r.castSucc.insertNth (α := fun _ => M) q v) (Fin.last (n+1)))) = + - (((-1:ℂ)^(n+1)) • (centralJ z q f (fun i => v i.castSucc)*v (Fin.last n))) := by + rw [init_insert, last_insert] + by_cases hrl : r.val=n + · have hre : r=Fin.last n := Fin.ext hrl + subst r + have hv' : ∀ i : Fin n, z*v i.castSucc=v i.castSucc := by + intro i; exact hv _ (by simpa only [Fin.lt_def,Fin.val_last,Fin.val_castSucc] using i.isLt) + rw [centralJ_all_z z q hqz f _ hv', zero_mul, smul_zero, neg_zero] + have hh : z*v (Fin.last n)=0 := by rw [← hvr, ← mul_assoc, hzq, zero_mul] + have he : f ((Fin.last n).insertNth q (fun i => v i.castSucc))*v (Fin.last n)=0 := by + rw [← hr, hz, mul_assoc, hh, mul_zero] + rw [he, smul_zero, smul_zero] + · let r' : Fin n := ⟨r.val, by omega⟩ + have hv' : ∀ i, i ((-1:ℂ)^(r.val+1)) • a) + (hf (r.castSucc.insertNth (α := fun _ => M) q v)) + simp only [smul_zero, differentialValue, smul_add] at h + rw [centralJ_left_cancellation z q hzq hqz hz f hr v r hv hvr, + centralJ_right_cancellation z q hzq hqz hz f hr v r hv hvr, + Fin.sum_univ_succAbove _ r, smul_add, merge_insert_same v r q hvr, + smul_smul, ← mul_pow, neg_mul_neg, one_mul, one_pow, one_smul, Finset.smul_sum] at h + have hi : ∑ j : Fin n, ((-1:ℂ)^(r.val+1)) • + (((-1:ℂ)^((r.succAbove j).val+1)) • + f (mergeInputs (r.castSucc.insertNth (α := fun _ => M) q v) (r.succAbove j))) = + -(∑ j : Fin n, ((-1:ℂ)^(j.val+1)) • centralJ z q f (mergeInputs v j)) := by + simp only [centralJ_inner_cancellation z q hzq hqz hz f v r hv hvr, Finset.sum_neg_distrib] + rw [hi] at h + have h' : f v - differentialValue (centralJ z q f) v = 0 := by + convert h using 1 + simp only [differentialValue] + abel + exact (sub_eq_zero.mp h').symm + +lemma differential_centralJ_all_z {n : ℕ} (z q : M) (hqz : q*z=0) + (f : Cochain M (n+1)) (v : Fin (n+1) → M) (hv : ∀ i, z*v i=v i) : + differentialValue (centralJ z q f) v=0 := by + have hl : centralJ z q f (fun i : Fin n => v i.succ)=0 := centralJ_all_z z q hqz f _ (fun _ => hv _) + have hr : centralJ z q f (fun i : Fin n => v i.castSucc)=0 := centralJ_all_z z q hqz f _ (fun _ => hv _) + have hm (j : Fin n) : centralJ z q f (mergeInputs v j)=0 := by + apply centralJ_all_z z q hqz f + intro i + simp only [mergeInputs] + split_ifs + · exact hv _ + · rw [← mul_assoc, hv] + · exact hv _ + simp only [differentialValue, hl,hr,hm,mul_zero,zero_mul,smul_zero,Finset.sum_const_zero,add_zero] + + + +theorem differential_centralJ {n : ℕ} (z : M) (hzz : z*z=z) (hz : ∀ a, z*a=a*z) + (f : Cochain M (n+1)) (hr : ∀ w, z*f w=f w) + (hf : ∀ w, differentialValue f w=0) (v : Fin (n+1) → M) : + differentialValue (centralJ z (1-z) f) v = f v - centralCut z f v := by + classical + let q := 1-z + have hzq : z*q=0 := by dsimp [q]; rw [mul_sub,mul_one,hzz,sub_self] + have hqz : q*z=0 := by dsimp [q]; rw [sub_mul,one_mul,hzz,sub_self] + have hqq : q*q=q := by dsimp [q]; rw [mul_sub,sub_mul,sub_mul,one_mul,mul_one,one_mul,hzz]; abel + let D := differential (centralJ z q f) - f + centralCut z f + have hall (w : Fin (n+1) → M) (hw : ∀ i, z*w i=w i ∨ q*w i=w i) : D w=0 := by + by_cases hzall : ∀ i, z*w i=w i + · have he : (fun i => z*w i)=w := funext hzall + simp only [D,add_apply,sub_apply,differential_apply, + differential_centralJ_all_z z q hqz f w hzall, centralCut_apply, he] + abel + · let bad : Finset (Fin (n+1)) := Finset.univ.filter (fun i => z*w i≠w i) + have hb : bad.Nonempty := by + push Not at hzall + obtain ⟨i,hi⟩ := hzall + exact ⟨i, by simp [bad,hi]⟩ + let r := bad.min' hb + have hrb : r∈bad := Finset.min'_mem bad hb + have hzr : z*w r≠w r := (Finset.mem_filter.mp hrb).2 + have hqr : q*w r=w r := (hw r).resolve_left hzr + have hprefix : ∀ i, i z*v i) + (fun i => q*v i)=v := by + funext i + change z*v i+(1-z)*v i=v i + rw [sub_mul,one_mul] + abel + have hd : D v=0 := by + rw [← hvsum, D.map_add_univ] + apply Finset.sum_eq_zero + intro s _ + apply hall + intro i + by_cases his : i∈s + · left + simp only [Finset.piecewise,his,ite_true,← mul_assoc,hzz] + · right + simp only [Finset.piecewise,his,ite_false,← mul_assoc,hqq] + change differentialValue (centralJ z q f) v = _ + simp only [D,add_apply,sub_apply,differential_apply] at hd + apply eq_sub_iff_add_eq.mpr + calc + _ = (differentialValue (centralJ z q f) v - f v + centralCut z f v) + f v := by abel + _ = f v := by rw [hd,zero_add] + + +theorem central_cocycle_correction {n : ℕ} (z : M) (hp : IsStarProjection z) + (hz : ∀ a, z*a=a*z) (f : Cochain M (n+1)) (hr : ∀ w, z*f w=f w) + (hf : ∀ w, differentialValue f w=0) : + ∃ g : Cochain M n, ‖g‖ ≤ n*‖f‖ ∧ (∀ w, z*g w=g w) ∧ + ∀ w, differentialValue g w = f w-centralCut z f w := by + have hq : IsStarProjection (1-z) := hp.one_sub + exact ⟨centralJ z (1-z) f, norm_centralJ_le z (1-z) (IsStarProjection.norm_le z hp) + (IsStarProjection.norm_le (1-z) hq) f, centralJ_range z (1-z) f hr, + differential_centralJ z hp.isIdempotentElem.eq hz f hr hf⟩ + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralIsometries.lean b/lean/OAI/Analysis/BoundedHochschild/CentralIsometries.lean new file mode 100644 index 0000000000000000000000000000000000000000..ff02b11f83820590a29efb12d346c242dcdf0f3d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralIsometries.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.CentralComparison + +namespace OAI + +/-! Central cuts and extensions of partial isometries. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildCentralComparison +open BoundedHochschild HochschildComparison FinitePathMain HochschildMatrixSystems +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_mul_pair {z : M} (hz : CentralProjection z) (a b : M) : + (z*a)*(z*b)=z*(a*b) := by + calc + _ = z*(a*z)*b := by simp only [mul_assoc] + _ = z*(z*a)*b := by rw [← (hz.2 a).eq] + _ = z*(a*b) := by rw [← mul_assoc z z,hz.1.isIdempotentElem.eq,mul_assoc] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_mul_sandwich {z : M} (hz : CentralProjection z) (a : M) : z*a*z=z*a := by + rw [mul_assoc,← (hz.2 a).eq,← mul_assoc,hz.1.isIdempotentElem.eq] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralProjection_mul {z t : M} (hz : CentralProjection z) (ht : CentralProjection t) : + CentralProjection (z*t) := ⟨hz.1.mul ht.1 (hz.2 t),fun a => (hz.2 a).mul_left (ht.2 a)⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralProjection_one_sub {z : M} (hz : CentralProjection z) : CentralProjection (1-z) := + ⟨hz.1.one_sub,fun a => (Commute.one_left a).sub_left (hz.2 a)⟩ + +namespace PartialIso + +def centralCut (v : PartialIso M) (z : M) (hz : CentralProjection z) : PartialIso M where + val := z*v + mul_star_mul := by + have hs : star (z*(v:M))=z*star (v:M) := by + rw [star_mul,hz.1.isSelfAdjoint.star_eq,← (hz.2 (star (v:M))).eq] + rw [hs,central_mul_pair hz,central_mul_pair hz,v.mul_star_mul] + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma centralCut_coe (v : PartialIso M) (z : M) (hz : CentralProjection z) : + ((centralCut v z hz : PartialIso M):M)=z*(v:M) := rfl + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralCut_initial (v : PartialIso M) (z : M) (hz : CentralProjection z) : + (centralCut v z hz).initial=z*v.initial := by + change star (z*(v:M))*(z*(v:M))=z*(star (v:M)*(v:M)) + rw [star_mul,hz.1.isSelfAdjoint.star_eq,← (hz.2 (star (v:M))).eq,central_mul_pair hz] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralCut_final (v : PartialIso M) (z : M) (hz : CentralProjection z) : + (centralCut v z hz).final=z*v.final := by + change (z*(v:M))*star (z*(v:M))=z*((v:M)*star (v:M)) + rw [star_mul,hz.1.isSelfAdjoint.star_eq,← (hz.2 (star (v:M))).eq,central_mul_pair hz] + +lemma centralCut_initial_le (v : PartialIso M) (z : M) (hz : CentralProjection z) : + (centralCut v z hz).initial ≤ v.initial := by + apply ((centralCut v z hz).initial_proj.le_iff_mul_eq_left v.initial_proj).mpr + rw [centralCut_initial,mul_assoc,v.initial_proj.isIdempotentElem.eq] + +lemma centralCut_final_le (v : PartialIso M) (z : M) (hz : CentralProjection z) : + (centralCut v z hz).final ≤ v.final := by + apply ((centralCut v z hz).final_proj.le_iff_mul_eq_left v.final_proj).mpr + rw [centralCut_final,mul_assoc,v.final_proj.isIdempotentElem.eq] + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include e hτ htr hfaith in + +theorem unitary_extension (v : PartialIso M) : + ∃ u : unitary M, (u:M)*v.initial=v ∧ (u:M)*v.initial*star (u:M)=v.final := by + have hcompl : ∀ z : M, CentralProjection z → τ (z*(1-v.initial))=τ (z*(1-v.final)) := by + intro z hz + rw [mul_sub,mul_sub,map_sub,map_sub,central_weighted_trace_partialIso τ htr v z hz.2] + obtain ⟨w,hwi,hwf⟩ := subequivalent_of_central_trace_le e τ hτ htr hfaith + v.initial_proj.one_sub v.final_proj.one_sub + (fun z hz => le_of_eq (congrArg Complex.re (hcompl z hz))) + have hwf' : w.final=1-v.final := by + apply le_antisymm hwf + apply HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith + v.final_proj.one_sub w.final_proj (Or.inr hwf) + have hwtr : τ w.initial=τ w.final := htr _ _ + rw [← hwtr,hwi,map_sub,map_sub] + have hvtr : τ v.initial=τ v.final := htr _ _ + rw [hvtr] + have hi : v.initial*w.initial=0 := by + rw [hwi,mul_sub,mul_one,v.initial_proj.isIdempotentElem.eq,sub_self] + have hf : v.final*w.final=0 := by + rw [hwf',mul_sub,mul_one,v.final_proj.isIdempotentElem.eq,sub_self] + let s := v.orthogonalSum w hi hf + have hsi : s.initial=1 := by rw [PartialIso.orthogonalSum_initial,hwi,add_sub_cancel] + have hsf : s.final=1 := by rw [PartialIso.orthogonalSum_final,hwf',add_sub_cancel] + let u : unitary M := ⟨s,⟨hsi,hsf⟩⟩ + have huv : (u:M)*v.initial=v := (v.le_orthogonalSum w hi hf).2 + refine ⟨u,huv,?_⟩ + have hvstar : v.initial*star (u:M)=star (v:M) := by + simpa only [star_mul,v.initial_proj.isSelfAdjoint.star_eq] using congrArg star huv + calc + (u:M)*v.initial*star (u:M) = ((u:M)*v.initial)*(v.initial*star (u:M)) := by + rw [← mul_assoc,mul_assoc (u:M) v.initial v.initial,v.initial_proj.isIdempotentElem.eq] + _ = v.final := by rw [huv,hvstar]; rfl +end PartialIso + +end HochschildCentralComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralLinearPatch.lean b/lean/OAI/Analysis/BoundedHochschild/CentralLinearPatch.lean new file mode 100644 index 0000000000000000000000000000000000000000..464ac218db2aaddfb706ba6a9794eaff6f611804 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralLinearPatch.lean @@ -0,0 +1,111 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Central spectral cuts and simultaneous linear norm control. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildCentralQuantization +open BoundedHochschild HochschildSakai HochschildRigidity FinitePathMain HochschildMatrixSystems +universe u v +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) +variable {I : Type v} [Fintype I] + +include e hτ htr hfaith in +lemma exists_central_norm_cut (h1 : τ 1=1) (b : I → M) + (hb : ∀ i x, Commute (b i) x) {ε : ℝ} (hε : 0<ε) + (hs : (∑ i, ‖τ.toPreGNS (b i)‖^2)<ε^2) : + ∃ c : M, IsStarProjection c ∧ c ≠ 0 ∧ (∀ x : M, Commute c x) ∧ + ∀ i, ‖c*b i‖≤ε := by + classical + let a : M := (ε^2) • (1:M) - ∑ i, star (b i)*b i + have ha : IsSelfAdjoint a := by + apply IsSelfAdjoint.sub + · exact (IsSelfAdjoint.all (ε^2)).smul (IsSelfAdjoint.one M) + · exact IsSelfAdjoint.of_nonneg (Finset.sum_nonneg (fun i _ => star_mul_self_nonneg _)) + have hac : ∀ x : M, Commute a x := by + intro x + apply Commute.sub_left + · exact (Commute.one_left x).smul_left (ε^2) + · exact Commute.sum_left Finset.univ _ x (fun i _ => + (central_star (hb i) x).mul_left (hb i x)) + have hat : 0<(τ a).re := by + have hh : τ ((ε^2) • (1:M))=((ε^2:ℝ):ℂ) := by + rw [← Complex.coe_smul,map_smul,h1,smul_eq_mul,mul_one] + dsimp only [a] + rw [map_sub,Complex.sub_re,hh,map_sum,Complex.re_sum] + simp only [trace_star_mul_self_re,Complex.ofReal_re] + linarith + obtain ⟨c,hc,hcz,hca,hca0⟩ := exists_central_positive_cut e τ hτ htr hfaith ha hac hat + have hc0 : c≠0 := by intro hz; apply hca0; rw [hz,zero_mul] + have hid (i : I) : star (c*b i)*(c*b i)=c*(star (b i)*b i) := by + rw [star_mul,hc.isSelfAdjoint.star_eq] + calc + _ = star (b i)*(c*c)*b i := by simp only [mul_assoc] + _ = c*(star (b i)*b i) := by + rw [hc.isIdempotentElem.eq,← (hcz (star (b i))).eq,mul_assoc] + have hsum : (∑ i,star (c*b i)*(c*b i))≤(ε^2) • c := by + apply sub_nonneg.mp + convert hca using 1 + dsimp [a] + simp only [mul_sub,mul_smul_comm,mul_one,Finset.mul_sum,hid] + refine ⟨c,hc,hc0,hcz,fun i => ?_⟩ + have hi : star (c*b i)*(c*b i) ≤ (ε^2) • (1:M) := by + calc + _ ≤ ∑ j,star (c*b j)*(c*b j) := Finset.single_le_sum + (fun j _ => star_mul_self_nonneg _) (Finset.mem_univ i) + _ ≤ (ε^2) • c := hsum + _ ≤ (ε^2) • (1:M) := smul_le_smul_of_nonneg_left hc.le_one (sq_nonneg ε) + have hn : ‖star (c*b i)*(c*b i)‖≤ε^2 := by + apply (CStarAlgebra.norm_le_iff_le_algebraMap _ (sq_nonneg ε) + (star_mul_self_nonneg _)).mpr + simpa only [Algebra.algebraMap_eq_smul_one] using hi + rw [CStarRing.norm_star_mul_self] at hn + nlinarith [norm_nonneg (c*b i)] + +include e hτ htr hfaith in +theorem exists_unitary_central_linear_patch (h1 : τ 1=1) (hII : TypeII1 M) + (a : I → M) (k : I → ℤ) (hk : ∀ i, k i ≠ 0) {ε : ℝ} (hε : 0<ε) : + ∃ u : unitary M, ∃ c : M, IsStarProjection c ∧ c ≠ 0 ∧ + (∀ x : M, Commute c x) ∧ ∀ i, + ‖c*centerExpectation e τ hτ htr hfaith (a i*(u^(k i) : unitary M) : M)‖≤ε := by + classical + let K : ℝ := Fintype.card I+1 + have hK : 0 centerExpectation e τ hτ htr hfaith + (a i*(u^(k i) : unitary M) : M) + have hb (i : I) (x : M) : Commute (b i) x := centerPart_central e τ hτ htr hfaith _ x + have hs : (∑ i, ‖τ.toPreGNS (b i)‖^2)<ε^2 := by + have hh : (∑ i, ‖τ.toPreGNS (b i)‖^2)≤(Fintype.card I:ℝ)*(ε/K)^2 := by + calc + _ ≤ ∑ _i : I,(ε/K)^2 := Finset.sum_le_sum (fun i _ => + le_of_lt ((sq_lt_sq₀ (norm_nonneg _) (div_pos hε hK).le).mpr (hu i))) + _ = _ := by simp + have hcast : (0:ℝ)≤Fintype.card I := by positivity + have hlt : (Fintype.card I:ℝ) simp only [E.entry_mul,h,ite_true,ite_false,mul_zero,zero_mul] + sum_diagonal := by + rw [← Finset.sum_mul,← Finset.mul_sum,E.sum_diagonal,mul_one,Unitary.mul_star_self_of_mem u.prop] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma commute_colored_diagonal (z : Fin n → M) (hz : ∀ i, CentralProjection (z i)) + (a : M) (ha : ∀ i, Commute a (E.entry i i)) : Commute a (∑ i,z i*E.entry i i) := by + apply Commute.sum_right + intro i hi + exact ((hz i).2 a).symm.mul_right (ha i) +end MatrixSystem + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include e hτ htr hfaith in + +theorem exists_central_matrix_projection_approx (h1 : τ 1=1) (hII : TypeII1 M) + {p : M} (hp : IsStarProjection p) {ε : ℝ} (hε : 0<ε) : + ∃ (n : ℕ) (E : HochschildMatrixSystems.MatrixSystem M n) (z : Fin n → M), 0.eq,mul_assoc (u:M)] + refine ⟨n,E,R.color,hn,R.color_central,hs ▸ R.val.final_proj,hs ▸ R.final_le,?_⟩ + rw [hs] + have hproj := (R.val.final_proj.le_iff_sub hp).mp R.final_le + have he : ‖τ.toPreGNS (p-R.val.final)‖^2=(τ (p-R.val.final)).re := by + have hh := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS (p-R.val.final))) + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS,← Complex.ofReal_pow,Complex.ofReal_re, + hproj.isSelfAdjoint.star_eq,hproj.isIdempotentElem.eq] using hh + have hb : ‖τ.toPreGNS (p-R.val.final)‖^2 ≤ (n:ℝ)⁻¹ := by + rw [he] + have htt : (n:ℝ)*(τ (p-R.val.final)).re ≤ 1 := by simpa only [h1,Complex.one_re] using hR + rw [← one_div (n:ℝ)] + apply (le_div_iff₀ hnRpos).mpr + nlinarith + nlinarith [hb.trans_lt hinv,norm_nonneg (τ.toPreGNS (p-R.val.final))] + +end HochschildCentralComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/CentralPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..eececdeb6b66bc118807ecfd6e746a7e82e2ec5a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralPrimitives.lean @@ -0,0 +1,256 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CentralHomotopy +import OAI.Analysis.BoundedHochschild.PathStages + +namespace OAI + +/-! Central cut primitives and restriction through expected embeddings. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open Filter Topology +namespace BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +lemma central_differential_values {n : ℕ} (p : M) (hp : ∀ a, p*a=a*p) + (f g : Cochain M n) (hfg : ∀ x, p*f x=g x) (x : Fin (n+1) → M) : + p*differentialValue f x=differentialValue g x := by + simp only [differentialValue,mul_add,Finset.mul_sum,mul_smul_comm] + congr 2 + · rw [← mul_assoc,hp (x 0),mul_assoc,hfg] + · apply Finset.sum_congr rfl + intro j _ + rw [hfg] + · rw [← mul_assoc,hfg] + +lemma norm_sum_supported_cochains {n : ℕ} (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i*p j=0) (g : I → Cochain M n) + (hleft : ∀ i x, p i*g i x=g i x) (hright : ∀ i x, g i x*p i=g i x) + (C : ℝ) (hC : 0 ≤ C) (hg : ∀ i, ‖g i‖ ≤ C) (s : Finset I) : + ‖∑ i ∈ s, g i‖ ≤ C := by + classical + apply ContinuousMultilinearMap.opNorm_le_bound hC + intro x + rw [sum_apply] + apply supported_sum_norm_le p (fun i => g i x) hp horth + (fun i => hleft i x) (fun i => hright i x) s (C*∏ j,‖x j‖) + (mul_nonneg hC (Finset.prod_nonneg (fun _ _ => norm_nonneg _))) + intro i _ + exact (g i).le_opNorm x |>.trans (mul_le_mul_of_nonneg_right (hg i) + (Finset.prod_nonneg (fun _ _ => norm_nonneg _))) + + + +theorem primitive_of_central_pieces + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (hcentral : ∀ i a, p i*a=a*p i) + (horth : ∀ i j, i ≠ j → p i*p j=0) + (htotal : ∀ x : M, (∀ i, p i*x=0) → x=0) + {n : ℕ} (f : Cochain M (n+1)) (g : I → Cochain M n) + (hleft : ∀ i x, p i*g i x=g i x) + (hdf : ∀ i x, differentialValue (g i) x=p i*f x) + (C : ℝ) (hC : 0 ≤ C) (hg : ∀ i, ‖g i‖ ≤ C) : + ∃ G : Cochain M n, ‖G‖ ≤ C ∧ ∀ x, differentialValue G x=f x := by + classical + let F : Finset I → Cochain M n := fun s => ∑ i ∈ s, g i + have hF (s : Finset I) : ‖F s‖ ≤ C := + norm_sum_supported_cochains p hp horth g hleft + (fun i x => by rw [← hcentral,hleft]) C hC hg s + let U : Ultrafilter (Finset I) := Ultrafilter.of atTop + have hU : (U : Filter (Finset I)) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨G,hG,ht⟩ := bounded_cochain_ultralimit e U F C hC hF + have hproj (i : I) (x : Fin n → M) : p i*G x=g i x := by + have hlim := (hL (p i)).tendsto e (ht x) + have hex : (fun s => p i*F s x) =ᶠ[U] (fun _ => g i x) := by + apply hU + filter_upwards [eventually_ge_atTop ({i} : Finset I)] with s hs + have hi : i ∈ s := hs (Finset.mem_singleton_self i) + change p i*(∑ j ∈ s,g j) x=g i x + rw [sum_apply,Finset.mul_sum] + rw [Finset.sum_eq_single i] + · exact hleft i x + · intro j _ hji + calc + p i*g j x=p i*(p j*g j x) := by rw [hleft] + _=0 := by rw [← mul_assoc,horth i j hji.symm,zero_mul] + · exact fun hh => (hh hi).elim + apply predual_tendsto_unique e hlim + intro z + exact tendsto_const_nhds.congr' (hex.mono fun _ h => congrArg (fun a : M => e.symm a z) h.symm) + refine ⟨G,hG,fun x => sub_eq_zero.mp (htotal _ fun i => ?_)⟩ + rw [mul_sub,central_differential_values (p i) (hcentral i) G (g i) (hproj i),hdf,sub_self] + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +def centralOutput {n : ℕ} (p : M) (f : Cochain M n) : Cochain M n := + (ContinuousLinearMap.mul ℂ M p).compContinuousMultilinearMap f + +@[simp] lemma centralOutput_apply {n : ℕ} (p : M) (f : Cochain M n) (x : Fin n → M) : + centralOutput p f x=p*f x := rfl + +lemma norm_centralOutput_le {n : ℕ} (p : M) (hp : ‖p‖ ≤ 1) (f : Cochain M n) : + ‖centralOutput p f‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + exact (norm_mul_le p (f x)).trans ((mul_le_mul_of_nonneg_right hp (norm_nonneg _)).trans + (by simpa only [one_mul] using f.le_opNorm x)) + + + +theorem primitive_of_central_cut_primitives + (hL : ∀ a : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M a)) + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (hcentral : ∀ i a, p i*a=a*p i) + (horth : ∀ i j, i ≠ j → p i*p j=0) + (htotal : ∀ x : M, (∀ i, p i*x=0) → x=0) + {n : ℕ} (f : Cochain M (n+1)) (hf : ∀ x, differentialValue f x=0) + (b : I → Cochain M n) (hb : ∀ i x, p i*b i x=b i x) + (hdb : ∀ i x, differentialValue (b i) x=centralCut (p i) (centralOutput (p i) f) x) + (C : ℝ) (hC : 0 ≤ C) (hbn : ∀ i, ‖b i‖ ≤ C) : + ∃ G : Cochain M n, ‖G‖ ≤ C+n*‖f‖ ∧ ∀ x, differentialValue G x=f x := by + have hsupport (i : I) (x : Fin (n+1) → M) : + p i*centralOutput (p i) f x=centralOutput (p i) f x := by + simp only [centralOutput_apply,← mul_assoc,(hp i).isIdempotentElem.eq] + have hcoc (i : I) (x : Fin (n+2) → M) : differentialValue (centralOutput (p i) f) x=0 := by + rw [← central_differential_values (p i) (hcentral i) f (centralOutput (p i) f) + (fun _ => rfl),hf,mul_zero] + choose a han has had using fun i => + central_cocycle_correction (p i) (hp i) (hcentral i) (centralOutput (p i) f) + (hsupport i) (hcoc i) + let g : I → Cochain M n := fun i => b i+a i + have hgn (i : I) : ‖g i‖ ≤ C+n*‖f‖ := by + calc + ‖g i‖ ≤ ‖b i‖+‖a i‖ := norm_add_le _ _ + _ ≤ C+n*‖centralOutput (p i) f‖ := add_le_add (hbn i) (han i) + _ ≤ C+n*‖f‖ := add_le_add_right + (mul_le_mul_of_nonneg_left (norm_centralOutput_le (p i) ((hp i).norm_le) f) + (Nat.cast_nonneg _)) C + apply primitive_of_central_pieces e hL p hp hcentral horth htotal f g + (fun i x => by simp only [g,add_apply,mul_add,hb,has]) _ _ (by positivity) hgn + intro i x + simp only [g,differentialValue_add,hdb,had] + rw [add_sub_cancel,centralOutput_apply] + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M N : Type*} [CStarAlgebra M] [CStarAlgebra N] + + + +structure ExpectedEmbedding (N M : Type*) [CStarAlgebra N] [CStarAlgebra M] where + includeMap : N →L[ℂ] M + expectMap : M →L[ℂ] N + include_mul : ∀ a b, includeMap (a*b)=includeMap a*includeMap b + include_one : includeMap 1=1 + include_star : ∀ a, includeMap (star a)=star (includeMap a) + include_norm : ∀ a, ‖includeMap a‖=‖a‖ + expect_norm : ∀ a, ‖expectMap a‖ ≤ ‖a‖ + retract : ∀ a, expectMap (includeMap a)=a + left_module : ∀ a x, expectMap (includeMap a*x)=a*expectMap x + right_module : ∀ x a, expectMap (x*includeMap a)=expectMap x*a + +namespace ExpectedEmbedding +variable (E : ExpectedEmbedding N M) + +def restrict {n : ℕ} (f : Cochain M n) : Cochain N n := + E.expectMap.compContinuousMultilinearMap (f.compContinuousLinearMap (fun _ => E.includeMap)) + +def extend {n : ℕ} (g : Cochain N n) : Cochain M n := + E.includeMap.compContinuousMultilinearMap (g.compContinuousLinearMap (fun _ => E.expectMap)) + +@[simp] lemma restrict_apply {n : ℕ} (f : Cochain M n) (x : Fin n → N) : + E.restrict f x=E.expectMap (f (fun i => E.includeMap (x i))) := rfl +@[simp] lemma extend_apply {n : ℕ} (g : Cochain N n) (x : Fin n → M) : + E.extend g x=E.includeMap (g (fun i => E.expectMap (x i))) := rfl + +lemma restrict_norm {n : ℕ} (f : Cochain M n) : ‖E.restrict f‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + change ‖E.expectMap (f (fun i => E.includeMap (x i)))‖ ≤ _ + exact (E.expect_norm _).trans (by + simpa only [E.include_norm] using (f.le_opNorm (fun i => E.includeMap (x i)))) + +lemma extend_norm {n : ℕ} (g : Cochain N n) : ‖E.extend g‖ ≤ ‖g‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + rw [extend_apply,E.include_norm] + exact (g.le_opNorm _).trans (mul_le_mul_of_nonneg_left + (Finset.prod_le_prod₀ (fun _ _ => norm_nonneg _) (fun _ _ => E.expect_norm _)) (norm_nonneg _)) + +lemma merge_include {n : ℕ} (x : Fin (n+1) → N) (j : Fin n) : + mergeInputs (fun i => E.includeMap (x i)) j = + fun i => E.includeMap (mergeInputs x j i) := by + funext i + simp only [mergeInputs] + split_ifs <;> simp only [E.include_mul] + + + +lemma differential_restrict {n : ℕ} (f : Cochain M n) (x : Fin (n+1) → N) : + differentialValue (E.restrict f) x = + E.expectMap (differentialValue f (fun i => E.includeMap (x i))) := by + simp only [differentialValue,restrict_apply,map_add,map_sum,map_smul, + E.left_module,E.right_module,E.merge_include] + +lemma restrict_cocycle {n : ℕ} (f : Cochain M n) + (hf : ∀ x, differentialValue f x=0) : + ∀ x, differentialValue (E.restrict f) x=0 := by + intro x + rw [E.differential_restrict,hf,map_zero] + + + +lemma differential_extend_on_include {n : ℕ} (g : Cochain N n) (x : Fin (n+1) → N) : + differentialValue (E.extend g) (fun i => E.includeMap (x i))= + E.includeMap (differentialValue g x) := by + simp only [differentialValue,extend_apply,E.merge_include,E.retract,map_add,map_sum, + map_smul,E.include_mul] + + + +theorem finite_exactness {n : ℕ} (f : Cochain M (n+1)) (g : Cochain N n) + (hg : ∀ x, differentialValue g x=E.restrict f x) + (S : Set M) (hS : ∀ a ∈ S, ∃ b, E.includeMap b=a) + (hfS : ∀ x : Fin (n+1) → M, (∀ i, x i ∈ S) → + ∃ b, E.includeMap b=f x) + (x : Fin (n+1) → M) (hx : ∀ i, x i ∈ S) : + differentialValue (E.extend g) x=f x := by + classical + choose y hy using fun i => hS (x i) (hx i) + have hxy : (fun i => E.includeMap (y i))=x := funext hy + obtain ⟨a,ha⟩ := hfS x hx + rw [← hxy,E.differential_extend_on_include,hg,restrict_apply,hxy,← ha,E.retract] + +end ExpectedEmbedding +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralProjectionPartitions.lean b/lean/OAI/Analysis/BoundedHochschild/CentralProjectionPartitions.lean new file mode 100644 index 0000000000000000000000000000000000000000..6bac321e8d0c45c9143a6888c14fd9a2692bd0c8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralProjectionPartitions.lean @@ -0,0 +1,192 @@ +import OAI.Analysis.BoundedHochschild.CentralProjectionSuprema +import OAI.Analysis.BoundedHochschild.PathStages + +namespace OAI + +/-! +# Maximal central partitions + +Orthogonal central projections have a supremum obtained from their finite +sums. A maximal family of projections satisfying any prescribed property +therefore has an actual complementary central projection. This construction +does not use a trace or a countability hypothesis. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {M X I : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The supremum of an arbitrary orthogonal central family preserves its common +annihilators. In particular, its complement completes the family to a partition. -/ +theorem exists_orthogonal_central_supremum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (hc : ∀ i a, p i * a = a * p i) + (horth : ∀ i j, i ≠ j → p i * p j = 0) : + ∃ q : M, IsStarProjection q ∧ (∀ a : M, q * a = a * q) ∧ + (∀ i, p i * q = p i) ∧ + (∀ a : M, (∀ i, p i * a = 0) → q * a = 0) := by + classical + let s (t : Finset I) : M := ∑ i ∈ t, p i + let U : Ultrafilter (Finset I) := Ultrafilter.of atTop + have hU : (U : Filter (Finset I)) ≤ atTop := Ultrafilter.of_le atTop + have hn (t : Finset I) : ‖s t‖ ≤ 1 := + supported_sum_norm_le p p hp horth + (fun i => (hp i).isIdempotentElem.eq) + (fun i => (hp i).isIdempotentElem.eq) t 1 (by norm_num) + (fun i _ => (hp i).norm_le) + obtain ⟨q, _, ht⟩ := exists_predual_ultralimit e U s 1 hn + have hfixed (i : I) : p i * q = p i := by + have hm := HochschildSakai.predual_tendsto_mul_left e (p i) ht + have heq : (fun t => p i * s t) =ᶠ[U] (fun _ => p i) := by + apply hU + filter_upwards [eventually_ge_atTop ({i} : Finset I)] with t hit + have hi : i ∈ t := hit (Finset.mem_singleton_self i) + simp only [s, Finset.mul_sum] + rw [Finset.sum_eq_single i] + · exact (hp i).isIdempotentElem.eq + · intro j _ hji + exact horth i j hji.symm + · exact fun h => (h hi).elim + apply predual_tendsto_unique e hm + intro z + exact tendsto_const_nhds.congr' (heq.mono fun _ h => + congrArg (fun a : M => e.symm a z) h.symm) + have hqc (a : M) : q * a = a * q := by + have hl := HochschildSakai.predual_tendsto_mul_left e a ht + have hr := HochschildSakai.predual_tendsto_mul_right e a ht + have heq : (fun t => a * s t) = (fun t => s t * a) := by + funext t + simp only [s, Finset.mul_sum, Finset.sum_mul] + exact Finset.sum_congr rfl (fun i _ => (hc i a).symm) + rw [heq] at hl + exact predual_tendsto_unique e hr hl + have hq : IsStarProjection q := by + constructor + · have hm := HochschildSakai.predual_tendsto_mul_right e q ht + have heq : (fun t => s t * q) = s := by + funext t + simp only [s, Finset.sum_mul, hfixed] + rw [heq] at hm + exact predual_tendsto_unique e hm ht + · have hs := HochschildSakai.predual_tendsto_star e ht + have heq : (fun t => star (s t)) = s := by + funext t + simp only [s, star_sum, fun i => (hp i).isSelfAdjoint.star_eq] + rw [heq] at hs + exact predual_tendsto_unique e hs ht + refine ⟨q, hq, hqc, hfixed, ?_⟩ + intro a ha + have hm := HochschildSakai.predual_tendsto_mul_right e a ht + have heq : (fun t => s t * a) = (fun _ => (0 : M)) := by + funext t + simp only [s, Finset.sum_mul, ha, Finset.sum_const_zero] + rw [heq] at hm + exact predual_tendsto_unique e hm (predual_tendsto_const e 0 (U : Filter (Finset I))) + +/-- A maximal family satisfying `P`, together with its actual central complement. -/ +structure MaximalCentralPartition (M : Type u) [CStarAlgebra M] + [PartialOrder M] [StarOrderedRing M] (P : M → Prop) where + Index : Type u + projection : Index → M + isProjection : ∀ i, IsStarProjection (projection i) + central : ∀ i a, projection i * a = a * projection i + nonzero : ∀ i, projection i ≠ 0 + property : ∀ i, P (projection i) + orthogonal : ∀ i j, i ≠ j → projection i * projection j = 0 + complement : M + complement_isProjection : IsStarProjection complement + complement_central : ∀ a, complement * a = a * complement + complement_orthogonal : ∀ i, projection i * complement = 0 + total : ∀ a, complement * a = 0 → (∀ i, projection i * a = 0) → a = 0 + maximal : ∀ q : M, IsStarProjection q → (∀ a, q * a = a * q) → + q ≤ complement → P q → q = 0 + +/-- Zorn's lemma and bounded weak-star limits provide a maximal central partition. -/ +theorem exists_maximal_central_partition (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (P : M → Prop) : Nonempty (MaximalCentralPartition M P) := by + classical + let A : Set (Set M) := {S | (∀ p ∈ S, IsStarProjection p ∧ + (∀ a : M, p * a = a * p) ∧ p ≠ 0 ∧ P p) ∧ + ∀ p ∈ S, ∀ q ∈ S, p ≠ q → p * q = 0} + obtain ⟨S, hS⟩ := zorn_subset A (fun c hc hchain => by + refine ⟨⋃₀ c, ⟨?_, ?_⟩, fun s hs => Set.subset_sUnion_of_mem hs⟩ + · intro p hp + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + exact (hc hs).1 p hps + · intro p hp q hq hpq + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + obtain ⟨t, ht, hqt⟩ := Set.mem_sUnion.mp hq + rcases hchain.total hs ht with hst | hts + · exact (hc ht).2 p (hst hps) q hqt hpq + · exact (hc hs).2 p hps q (hts hqt) hpq) + let p : S → M := Subtype.val + have hp (i : S) : IsStarProjection (p i) := (hS.1.1 i i.property).1 + have hc (i : S) (a : M) : p i * a = a * p i := (hS.1.1 i i.property).2.1 a + have hn (i : S) : p i ≠ 0 := (hS.1.1 i i.property).2.2.1 + have hP (i : S) : P (p i) := (hS.1.1 i i.property).2.2.2 + have ho (i j : S) (hij : i ≠ j) : p i * p j = 0 := + hS.1.2 i i.property j j.property (fun h => hij (Subtype.ext h)) + obtain ⟨q, hq, hqc, hfixed, hann⟩ := exists_orthogonal_central_supremum e p hp hc ho + have hcomp (i : S) : p i * (1 - q) = 0 := by + rw [mul_sub, mul_one, hfixed, sub_self] + refine ⟨{ + Index := S + projection := p + isProjection := hp + central := hc + nonzero := hn + property := hP + orthogonal := ho + complement := 1 - q + complement_isProjection := hq.one_sub + complement_central := fun a => by + simp only [sub_mul, mul_sub, one_mul, mul_one, hqc] + complement_orthogonal := hcomp + total := ?_ + maximal := ?_ }⟩ + · intro a hca hpa + have hqa := hann a hpa + simpa only [sub_mul, one_mul, hqa, sub_zero] using hca + · intro r hr hrc hrq hPr + by_contra hr0 + have hrr : ∀ i : S, p i * r = 0 := by + have hqr : (1 - q) * r = r := (hr.le_iff_mul_eq_right hq.one_sub).mp hrq + intro i + calc + p i * r = p i * ((1 - q) * r) := by rw [hqr] + _ = 0 := by rw [← mul_assoc, hcomp, zero_mul] + have hnew : insert r S ∈ A := by + constructor + · intro a ha + rcases Set.mem_insert_iff.mp ha with rfl | ha + · exact ⟨hr, hrc, hr0, hPr⟩ + · exact hS.1.1 a ha + · intro a ha b hb hab + rcases Set.mem_insert_iff.mp ha with har | ha + · subst a + rcases Set.mem_insert_iff.mp hb with hbr | hb + · exact (hab hbr.symm).elim + · exact (hrc b).trans (hrr ⟨b, hb⟩) + · rcases Set.mem_insert_iff.mp hb with hbr | hb + · subst b + exact hrr ⟨a, ha⟩ + · exact hS.1.2 a ha b hb hab + have hsubset : insert r S ⊆ S := hS.2 hnew (Set.subset_insert r S) + have hrS : r ∈ S := hsubset (Set.mem_insert r S) + exact hr0 (by simpa only [p, hr.isIdempotentElem.eq] using hrr ⟨r, hrS⟩) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralProjectionSuprema.lean b/lean/OAI/Analysis/BoundedHochschild/CentralProjectionSuprema.lean new file mode 100644 index 0000000000000000000000000000000000000000..f4669b7e9d2c297645e1f919d5f2d5967fb9b659 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralProjectionSuprema.lean @@ -0,0 +1,116 @@ +import OAI.Analysis.BoundedHochschild.NormalMultiplication + +namespace OAI + +/-! +# Suprema of chains of central projections + +A nonempty chain of central projections has a central projection supremum. +A bounded weak-star cluster point is a projection because multiplication by +each member of the chain eventually stabilizes. The same limiting argument +preserves annihilation of any fixed element. No trace is used. +-/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A chain of central projections has a least projection upper bound, preserving +any common right annihilator. -/ +theorem exists_central_projection_chain_supremum_with_limit + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (S : Set M) (hne : S.Nonempty) (hchain : IsChain (· ≤ ·) S) + (hproj : ∀ q ∈ S, IsStarProjection q) + (hcentral : ∀ q ∈ S, ∀ a : M, q * a = a * q) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ + (∀ q ∈ S, q ≤ p) ∧ + (∀ r : M, IsStarProjection r → (∀ q ∈ S, q ≤ r) → p ≤ r) ∧ + (∀ a : M, (∀ q ∈ S, q * a = 0) → p * a = 0) ∧ + ∃ U : Ultrafilter S, (U : Filter S) ≤ atTop ∧ + PredualTendsto e (fun q : S => (q : M)) (U : Filter S) p := by + classical + let : Nonempty S := hne.to_subtype + let : IsDirectedOrder S := ⟨fun a b => by + rcases hchain.total a.property b.property with hab | hba + · exact ⟨b, hab, le_rfl⟩ + · exact ⟨a, le_rfl, hba⟩⟩ + let U : Ultrafilter S := Ultrafilter.of atTop + have hU : (U : Filter S) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨p, _hpnorm, ht⟩ := exists_predual_ultralimit e U + (fun q : S => (q : M)) 1 (fun q => (hproj q q.property).norm_le) + have hfixed (q : S) : (q : M) * p = q := by + have hm := HochschildSakai.predual_tendsto_mul_left e (q : M) ht + have heq : (fun r : S => (q : M) * r) =ᶠ[U] (fun _ => (q : M)) := by + apply hU + filter_upwards [eventually_ge_atTop q] with r hqr + exact ((hproj q q.property).le_iff_mul_eq_left (hproj r r.property)).mp hqr + apply predual_tendsto_unique e hm + intro z + exact tendsto_const_nhds.congr' (heq.mono fun _ hr => congrArg (fun a : M => e.symm a z) hr.symm) + have hpcentral (a : M) : p * a = a * p := by + have hl := HochschildSakai.predual_tendsto_mul_left e a ht + have hr := HochschildSakai.predual_tendsto_mul_right e a ht + have heq : (fun q : S => a * (q : M)) = (fun q : S => (q : M) * a) := by + funext q + exact (hcentral q q.property a).symm + rw [heq] at hl + exact predual_tendsto_unique e hr hl + have hp : IsStarProjection p := by + constructor + · have hm := HochschildSakai.predual_tendsto_mul_right e p ht + have heq : (fun q : S => (q : M) * p) = (fun q : S => (q : M)) := + funext hfixed + rw [heq] at hm + exact predual_tendsto_unique e hm ht + · have hs := HochschildSakai.predual_tendsto_star e ht + have heq : (fun q : S => star (q : M)) = (fun q : S => (q : M)) := by + funext q + exact (hproj q q.property).isSelfAdjoint.star_eq + rw [heq] at hs + exact predual_tendsto_unique e hs ht + refine ⟨p, hp, hpcentral, ?_, ?_, ?_, U, hU, ht⟩ + · intro q hq + exact ((hproj q hq).le_iff_mul_eq_left hp).mpr (hfixed ⟨q, hq⟩) + · intro r hr hub + apply (hp.le_iff_mul_eq_left hr).mpr + have hm := HochschildSakai.predual_tendsto_mul_right e r ht + have heq : (fun q : S => (q : M) * r) = (fun q : S => (q : M)) := by + funext q + exact ((hproj q q.property).le_iff_mul_eq_left hr).mp (hub q q.property) + rw [heq] at hm + exact predual_tendsto_unique e hm ht + · intro a ha + have hm := HochschildSakai.predual_tendsto_mul_right e a ht + have heq : (fun q : S => (q : M) * a) = (fun _ : S => (0 : M)) := by + funext q + exact ha q q.property + rw [heq] at hm + exact predual_tendsto_unique e hm (predual_tendsto_const e 0 (U : Filter S)) + +/-- A chain of central projections has a least projection upper bound, preserving +any common right annihilator. -/ +theorem exists_central_projection_chain_supremum + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (S : Set M) (hne : S.Nonempty) (hchain : IsChain (· ≤ ·) S) + (hproj : ∀ q ∈ S, IsStarProjection q) + (hcentral : ∀ q ∈ S, ∀ a : M, q * a = a * q) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ + (∀ q ∈ S, q ≤ p) ∧ + (∀ r : M, IsStarProjection r → (∀ q ∈ S, q ≤ r) → p ≤ r) ∧ + (∀ a : M, (∀ q ∈ S, q * a = 0) → p * a = 0) := by + obtain ⟨p, hp, hc, hu, hl, ha, _⟩ := + exists_central_projection_chain_supremum_with_limit e S hne hchain hproj hcentral + exact ⟨p, hp, hc, hu, hl, ha⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralQuantization.lean b/lean/OAI/Analysis/BoundedHochschild/CentralQuantization.lean new file mode 100644 index 0000000000000000000000000000000000000000..d24ce356173ac4779835adb1b27f213c02e4e145 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralQuantization.lean @@ -0,0 +1,118 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.CentralMatrices + +namespace OAI + +/-! Central centering and projection displacement. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCentralQuantization +open BoundedHochschild HochschildComparison HochschildDixmier HochschildRigidity + HochschildSakai HochschildQuantization HochschildCentralComparison FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +def CentrallyCentered (a : M) : Prop := ∀ z : M, (∀ x : M, Commute z x) → τ (z*a)=0 + +omit [PartialOrder M] [StarOrderedRing M] in +lemma central_star {b : M} (hb : ∀ x : M, Commute b x) : ∀ x : M, Commute (star b) x := by + intro x + have hh := congrArg star (hb (star x)).eq + change star b*x=x*star b + simpa only [star_mul,star_star] using hh.symm + +include e in +lemma trace_weighted_orbit_closure + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (a b z : M) (hz : ∀ x : M, Commute z x) + (hb : gnsVector τ b ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun u : unitary M => conjugate u a)))) : τ (z*b)=τ (z*a) := by + obtain ⟨c,hc,hcn,hct⟩ := orbit_sequence τ hb + have ht := trace_predual_tendsto e τ hτ (predual_tendsto_mul_left e z + (predual_tendsto_of_preGNS e τ (mul_hasPreadjoint e) hτ hfaith ‖a‖ hcn hct)) + have he : ∀ n, τ (z*c n)=τ (z*a) := fun n => central_trace_orbit τ htr a z hz (hc n) + apply tendsto_nhds_unique ht + simpa only [he] using (tendsto_const_nhds : Tendsto (fun _ : ℕ => τ (z*a)) atTop (𝓝 _)) + +include e in +lemma zero_mem_orbit_closure + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {a : M} (ha : CentrallyCentered τ a) : + gnsVector τ (0:M) ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun u : unitary M => conjugate u a))) := by + obtain ⟨b,_hbn,hbc,hb⟩ := exists_central_average e τ (mul_hasPreadjoint e) hτ htr hfaith a + have hb0 : b=0 := by + apply hfaith + rw [trace_weighted_orbit_closure e τ hτ htr hfaith a b (star b) (central_star hbc) hb] + exact ha (star b) (central_star hbc) + simpa only [hb0] using hb + +include e in +lemma norm_le_of_conjugations + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {a : M} (ha : CentrallyCentered τ a) (ε : ℝ) + (hu : ∀ u : unitary M, ‖τ.toPreGNS (conjugate u a-a)‖ ≤ ε) : + ‖τ.toPreGNS a‖ ≤ ε := by + have hk : gnsVector τ '' convexHull ℝ + (Set.range (fun u : unitary M => conjugate u a)) ⊆ + Metric.closedBall (gnsVector τ a) ε := by + rw [LinearMap.image_convexHull] + apply convexHull_min _ (convex_closedBall _ _) + rintro _ ⟨_,⟨u,rfl⟩,rfl⟩ + simpa only [Metric.mem_closedBall,dist_eq_norm,← map_sub,gnsVector_norm] using hu u + have hh := closure_minimal hk Metric.isClosed_closedBall + (zero_mem_orbit_closure e τ hτ htr hfaith ha) + simpa only [Metric.mem_closedBall,dist_eq_norm,map_zero,zero_sub,norm_neg,gnsVector_norm] using hh + +include e in +lemma norm_le_of_projection_commutators + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {a : M} (ha : CentrallyCentered τ a) (K : ℝ) (hK : 0 ≤ K) + (hp : ∀ p : M, IsStarProjection p → ‖τ.toPreGNS (p*a-a*p)‖ ≤ K) : + ‖τ.toPreGNS a‖ ≤ 4*K := by + apply norm_le_of_conjugations e τ hτ htr hfaith ha (4*K) + intro u + have : Nontrivial M := ⟨⟨1,0,by + intro hz + have hh : (1:ℂ)=0 := h1.symm.trans ((congrArg τ hz).trans (map_zero τ)) + exact one_ne_zero hh⟩⟩ + have hh := contraction_bound_of_projections e (commutatorGNS τ a) (2*‖a‖) K + (by positivity) hK (commutatorGNS_bound τ h1 a) hp (u:M) + (CStarRing.norm_coe_unitary u).le + have he : conjugate u a-a=((u:M)*a-a*(u:M))*star (u:M) := by + simp only [conjugate_apply,sub_mul,mul_assoc,Unitary.mul_star_self_of_mem u.prop,mul_one] + rw [he,show star (u:M)=((star u:unitary M):M) from rfl,preGNS_norm_unitary_right τ htr] + exact hh + +include e in +lemma exists_central_projection_displacement + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {a : M} (ha : CentrallyCentered τ a) (ha0 : 0<‖τ.toPreGNS a‖) : + ∃ p : M, IsStarProjection p ∧ ‖τ.toPreGNS a‖/8 < ‖τ.toPreGNS (p*a-a*p)‖ := by + by_contra hn + push Not at hn + have hh := norm_le_of_projection_commutators e τ hτ h1 htr hfaith ha + (‖τ.toPreGNS a‖/8) (by positivity) hn + linarith + +end HochschildCentralQuantization + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralRanks.lean b/lean/OAI/Analysis/BoundedHochschild/CentralRanks.lean new file mode 100644 index 0000000000000000000000000000000000000000..c832440d964fc0c3c2ebd6977c2c15fd653cfb32 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralRanks.lean @@ -0,0 +1,217 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.MatrixSeeds +import OAI.Analysis.BoundedHochschild.CentralIsometries + +namespace OAI + +/-! Central ranks and approximation by diagonal projections. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildCentralComparison +open BoundedHochschild HochschildComparison FinitePathMain HochschildMatrixSystems +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma central_projection_mul_le_left {z p : M} (hz : CentralProjection z) (hp : IsStarProjection p) : + z*p ≤ z := by + exact ((hz.1.mul hp (hz.2 p)).le_iff_mul_eq_left hz.1).mpr (central_mul_sandwich hz p) + +lemma central_projection_mul_le_right {z p : M} (hz : CentralProjection z) (hp : IsStarProjection p) : + z*p ≤ p := by + apply ((hz.1.mul hp (hz.2 p)).le_iff_mul_eq_left hp).mpr + rw [mul_assoc,hp.isIdempotentElem.eq] + +lemma central_projection_mul_mono {z p q : M} (hz : CentralProjection z) + (hp : IsStarProjection p) (hq : IsStarProjection q) (hpq : p ≤ q) : z*p ≤ z*q := by + apply ((hz.1.mul hp (hz.2 p)).le_iff_mul_eq_left (hz.1.mul hq (hz.2 q))).mpr + rw [central_mul_pair hz,(hp.le_iff_mul_eq_left hq).mp hpq] + +variable (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + +omit [StarOrderedRing M] in +include htr in +lemma central_diagonal_trace {n : ℕ} (E : MatrixSystem M n) (z : M) + (hz : ∀ a : M, Commute z a) (i j : Fin n) : + τ (z*E.entry i i)=τ (z*E.entry j j) := by + calc + _ = τ ((z*E.entry i j)*E.entry j i) := by rw [mul_assoc,E.entry_mul,ite_eq_left rfl] + _ = τ (E.entry j i*(z*E.entry i j)) := htr _ _ + _ = τ (z*(E.entry j i*E.entry i j)) := by rw [← mul_assoc,← (hz _).eq,mul_assoc] + _ = _ := by rw [E.entry_mul,ite_eq_left rfl] + +omit [StarOrderedRing M] in +include htr in +lemma central_diagonal_trace_mul {n : ℕ} (E : MatrixSystem M n) (z : M) + (hz : ∀ a : M, Commute z a) (i : Fin n) : + (n:ℝ)*(τ (z*E.entry i i)).re=(τ z).re := by + have hh := congrArg (fun a : M => (τ (z*a)).re) E.sum_diagonal + rw [Finset.mul_sum,map_sum,Complex.re_sum,mul_one] at hh + simpa only [central_diagonal_trace τ htr E z hz _ i,Finset.sum_const, + Finset.card_univ,Fintype.card_fin,nsmul_eq_mul] using hh + +structure CentralRank {n : ℕ} (E : MatrixSystem M n) (p : M) (m : ℕ) where + val : PartialIso M + color : Fin n → M + color_central : ∀ i, CentralProjection (color i) + color_zero : ∀ i, m ≤ i.val → color i=0 + initial_eq : val.initial=∑ i,color i*E.entry i i + final_le : val.final ≤ p + active : M + active_central : CentralProjection active + active_le_color : ∀ i, i.val < m → active ≤ color i + error_bound : (n:ℝ)*(τ ((1-active)*(p-val.final))).re ≤ (τ (1-active)).re + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hτ : TraceInPredual e τ) (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma centralRank_zero {n : ℕ} (E : MatrixSystem M n) {p : M} (hp : IsStarProjection p) : + Nonempty (CentralRank τ E p 0) := by + refine ⟨⟨0,fun _ => 0,fun _ => ⟨IsStarProjection.zero M,fun a => Commute.zero_left a⟩, + fun _ _ => rfl,?_,?_,1,⟨IsStarProjection.one M,fun a => Commute.one_left a⟩, + (fun i hi => (Nat.not_lt_zero i.val hi).elim),?_⟩⟩ + · simp + · simpa using hp.nonneg + · simp + +namespace CentralRank +variable {n : ℕ} {E : MatrixSystem M n} {p : M} {m : ℕ} + +omit [StarOrderedRing M] in +lemma initial_mul_later (R : CentralRank τ E p m) (j : Fin n) (hj : m ≤ j.val) : + R.val.initial*E.entry j j=0 := by + rw [R.initial_eq,Finset.sum_mul] + apply Finset.sum_eq_zero + intro i hi + rw [mul_assoc,E.entry_mul] + by_cases hij : i=j + · subst i + rw [R.color_zero j hj,zero_mul] + · rw [ite_eq_right hij,mul_zero] + +include e hτ htr hfaith in +lemma step (hp : IsStarProjection p) (R : CentralRank τ E p m) (hm : m R.color i*E.entry i i) (Finset.mem_univ j)] + simp only [Function.update_self,hzj,zero_mul,add_zero] + congr 1 + apply Finset.sum_congr rfl + intro i hi + rw [Function.update_of_ne (Finset.ne_of_mem_erase hi)] + exact hsum.symm + · intro i hi + by_cases hij : i=j + · subst i; simp only [Function.update_self,le_refl] + · rw [Function.update_of_ne hij] + exact hdc.trans (R.active_le_color i (by + have hne : i.val≠m := fun hh => hij (Fin.ext hh) + omega)) + +include htr in +lemma terminal_error (hp : IsStarProjection p) (R : CentralRank τ E p n) : + (n:ℝ)*(τ (p-R.val.final)).re ≤ (τ 1).re := by + have hci : R.active*R.val.initial=R.active := by + rw [R.initial_eq,Finset.mul_sum] + have hh : ∀ i : Fin n, R.active*(R.color i*E.entry i i)=R.active*E.entry i i := by + intro i + rw [← mul_assoc,(R.active_central.1.le_iff_mul_eq_left (R.color_central i).1).mp + (R.active_le_color i i.isLt)] + simp only [hh,← Finset.mul_sum,E.sum_diagonal,mul_one] + have hct : τ (R.active*R.val.final)=τ R.active := by + rw [← central_weighted_trace_partialIso τ htr R.val R.active R.active_central.2,hci] + have hcr : (τ (R.active*(p-R.val.final))).re ≤ 0 := by + rw [mul_sub,map_sub,Complex.sub_re,hct] + have hh := Complex.re_le_re (τ.monotone (central_projection_mul_le_left R.active_central hp)) + change (τ (R.active*p)).re ≤ (τ R.active).re at hh + linarith + have he : p-R.val.final=(1-R.active)*(p-R.val.final)+R.active*(p-R.val.final) := by noncomm_ring + rw [he,map_add,Complex.add_re,mul_add] + have hc0 := mul_nonpos_of_nonneg_of_nonpos (Nat.cast_nonneg n : (0:ℝ)≤n) hcr + have hbound : (τ (1-R.active)).re ≤ (τ 1).re := + Complex.re_le_re (τ.monotone R.active_central.1.one_sub.le_one) + linarith [R.error_bound] +end CentralRank + +include e hτ htr hfaith in +theorem exists_central_rank {n : ℕ} (E : MatrixSystem M n) {p : M} (hp : IsStarProjection p) : + ∃ R : CentralRank τ E p n, (n:ℝ)*(τ (p-R.val.final)).re ≤ (τ 1).re := by + have hh : ∀ m : ℕ, m ≤ n → Nonempty (CentralRank τ E p m) := by + intro m + induction m with + | zero => intro _; exact centralRank_zero τ E hp + | succ m ih => + intro hm + obtain ⟨R⟩ := ih (by omega) + exact R.step τ htr e hτ hfaith hp (by omega) + obtain ⟨R⟩ := hh n le_rfl + exact ⟨R,R.terminal_error τ htr hp⟩ + +end HochschildCentralComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralRowCompression.lean b/lean/OAI/Analysis/BoundedHochschild/CentralRowCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5466d1885c507b7f6c80714a44db5fe60095e6f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralRowCompression.lean @@ -0,0 +1,97 @@ +import OAI.Analysis.BoundedHochschild.CentralSupportNormalizedRows +import OAI.Analysis.BoundedHochschild.InfiniteRepresentedFamilies + +namespace OAI + +/-! The row exhausting a central support compresses the averaging operator +through the original projection corner. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M H K : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma centralSupportRow_compression_term + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + {p z : M} (hp : IsStarProjection p) (hz : IsStarProjection z) (hpz : p ≤ z) + (S : Set (PartialIso M)) (hS : ∀ v ∈ S, v.final ≤ p ∧ v.initial ≤ z) + (W : H →L[ℂ] K) (i : Option S) (ξ : H) : + π (centralSupportRow z S i) (W ((σ (centralSupportRow z S i)).adjoint (σ z ξ))) = + π (centralSupportRow z S i) + (π p (W (σ p ((σ (centralSupportRow z S i)).adjoint ξ)))) := by + cases i with + | none => + have hright : (σ (1 - z)).adjoint.comp (σ z) = 0 := by + rw [← ContinuousLinearMap.star_eq_adjoint, ← map_star, + hz.one_sub.isSelfAdjoint.star_eq] + change σ (1 - z) * σ z = 0 + rw [← map_mul, hz.one_sub_mul_self, map_zero] + have hleft : (π (1 - z)).comp (π p) = 0 := by + change π (1 - z) * π p = 0 + rw [← map_mul, sub_mul, one_mul, (hp.le_iff_mul_eq_right hz).mp hpz, + sub_self, map_zero] + have hr := congrArg (fun A : H →L[ℂ] H => A ξ) hright + have hl := congrArg (fun A : K →L[ℂ] K => A (W (σ p ((σ (1-z)).adjoint ξ)))) hleft + change (σ (1 - z)).adjoint (σ z ξ) = 0 at hr + change π (1 - z) (π p (W (σ p ((σ (1-z)).adjoint ξ)))) = 0 at hl + change π (1 - z) (W ((σ (1-z)).adjoint (σ z ξ))) = _ + rw [hr, map_zero, map_zero] + exact hl.symm + | some v => + have hpv : p * (v.val : M) = v.val := by + calc + _ = p * (v.val.final * (v.val : M)) := by rw [v.val.final_mul] + _ = v.val := by rw [← mul_assoc, + (v.val.final_proj.le_iff_mul_eq_right hp).mp (hS v v.property).1, + v.val.final_mul] + have hvz : (v.val : M) * z = v.val := by + calc + _ = ((v.val : M) * v.val.initial) * z := by rw [v.val.mul_initial] + _ = v.val := by rw [mul_assoc, + (v.val.initial_proj.le_iff_mul_eq_left hz).mp (hS v v.property).2, + v.val.mul_initial] + have hvp : star (v.val : M) * p = star (v.val : M) := by + simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star hpv + have hσ (a b c : M) (h : a * b = c) (η : H) : σ a (σ b η) = σ c η := + congrArg (fun A : H →L[ℂ] H => A η) ((map_mul σ a b).symm.trans (congrArg σ h)) + have hπ (a b c : M) (h : a * b = c) (η : K) : π a (π b η) = π c η := + congrArg (fun A : K →L[ℂ] K => A η) ((map_mul π a b).symm.trans (congrArg π h)) + have hs : (σ (star (v.val : M))).adjoint = σ (v.val : M) := by + rw [← ContinuousLinearMap.star_eq_adjoint, ← map_star, star_star] + simp only [centralSupportRow, hs, hσ _ _ _ hvz, hσ _ _ _ hpv, hπ _ _ _ hvp] + +theorem centralSupportRow_compression_norm_le + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + {p z : M} (hp : IsStarProjection p) (hz : IsStarProjection z) (hpz : p ≤ z) + (S : Set (PartialIso M)) (hS : ∀ v ∈ S, v.final ≤ p ∧ v.initial ≤ z) + (hm : ∀ s : Finset (Option S), + ∑ i ∈ s, centralSupportRow z S i * star (centralSupportRow z S i) ≤ 1) + (W : H →L[ℂ] K) : + ‖(infiniteRepresentedRightAverage π σ (centralSupportRow z S) hm W).comp (σ z)‖ ≤ + ‖(π p).comp (W.comp (σ p))‖ := by + have he : (infiniteRepresentedRightAverage π σ (centralSupportRow z S) hm W).comp (σ z) = + infiniteRepresentedRightAverage π σ (centralSupportRow z S) hm + ((π p).comp (W.comp (σ p))) := by + ext ξ + have h₁ := infiniteRepresentedRightAverage_hasSum π σ (centralSupportRow z S) hm W (σ z ξ) + have h₂ := infiniteRepresentedRightAverage_hasSum π σ (centralSupportRow z S) hm + ((π p).comp (W.comp (σ p))) ξ + have hf := funext (fun i => centralSupportRow_compression_term π σ hp hz hpz S hS W i ξ) + simp only [ContinuousLinearMap.comp_apply] at h₂ ⊢ + rw [hf] at h₁ + exact h₁.unique h₂ + rw [he] + exact infiniteRepresentedRightAverage_norm_le π σ (centralSupportRow z S) hm _ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralSeparation.lean b/lean/OAI/Analysis/BoundedHochschild/CentralSeparation.lean new file mode 100644 index 0000000000000000000000000000000000000000..8f86b72ffc4ae96401c4bc36043bd3f8ddcceee6 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralSeparation.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.TypeIIDefinitions + +namespace OAI + +/-! Central separation from tracial conjugacy orbits. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCentralComparison +open BoundedHochschild HochschildRigidity HochschildDixmier HochschildSakai FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +lemma orbit_sequence {a b : M} + (hb : gnsVector τ b ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun u : unitary M => conjugate u a)))) : + ∃ c : ℕ → M, (∀ n, c n ∈ convexHull ℝ (Set.range (fun u : unitary M => conjugate u a))) ∧ + (∀ n, ‖c n‖ ≤ ‖a‖) ∧ GNSTendsto τ c atTop b := by + obtain ⟨y,hy,ht⟩ := mem_closure_iff_seq_limit.mp hb + choose c hc he using hy + refine ⟨c,hc,fun n => ?_,?_⟩ + · simpa only [Metric.mem_closedBall,dist_zero_right] using orbit_hull_bounded a (hc n) + · have hh := tendsto_iff_norm_sub_tendsto_zero.mp ht + simpa only [GNSTendsto,← he,← map_sub,gnsVector_norm] using hh + +omit [StarOrderedRing M] in +include htr in +lemma central_trace_orbit (a z : M) (hz : ∀ x : M, Commute z x) : + convexHull ℝ (Set.range (fun u : unitary M => conjugate u a)) ⊆ + {b : M | τ (z*b)=τ (z*a)} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩ + change τ (z*((u:M)*a*star (u:M)))=τ (z*a) + have he : z*((u:M)*a*star (u:M))=(u:M)*(z*a)*star (u:M) := by + rw [← mul_assoc,← mul_assoc,(hz (u:M)).eq,mul_assoc (u:M) z a] + rw [he,htr,← mul_assoc,Unitary.star_mul_self_of_mem u.prop,one_mul] + · intro x hx y hy r s _hr _hs hrs + change τ (z*(r • x+s • y))=τ (z*a) + rw [mul_add,mul_smul_comm,mul_smul_comm,map_add, + τ.map_smul_of_tower,τ.map_smul_of_tower,hx,hy,← add_smul,hrs,one_smul] + +include e hτ htr hfaith in + +theorem central_separator {p q : M} (hp : IsStarProjection p) (_hq : IsStarProjection q) + (hpq : ∀ a : M, p*a*q=0) : + ∃ z : M, CentralProjection z ∧ p ≤ z ∧ z*q=0 := by + let L := mul_hasPreadjoint e + obtain ⟨b,_hbn,hbc,hb⟩ := exists_central_average e τ L hτ htr hfaith p + obtain ⟨c,hc,hcn,hct⟩ := orbit_sequence τ hb + have hctw := predual_tendsto_of_preGNS e τ L hτ hfaith ‖p‖ hcn hct + have hpos : ∀ n, 0 ≤ c n := by + have hh : convexHull ℝ (Set.range (fun u : unitary M => conjugate u p)) ⊆ {a : M | 0 ≤ a} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩ + exact star_right_conjugate_nonneg hp.nonneg (u:M) + · intro a ha b hb r s hr hs _hrs + exact add_nonneg (smul_nonneg hr ha) (smul_nonneg hs hb) + exact fun n => hh (hc n) + have hbpos : 0 ≤ b := nonneg_of_bounded_predual_limit e ‖p‖ (norm_nonneg _) + (Eventually.of_forall hcn) (Eventually.of_forall hpos) hctw + obtain ⟨z,hz⟩ := exists_support_projection e b hbpos + have hzc : CentralProjection z := ⟨hz.proj,fun a => hz.commute (IsSelfAdjoint.of_nonneg hbpos) (hbc a)⟩ + have hcz : ∀ n, τ ((1-z)*c n)=τ ((1-z)*p) := fun n => + central_trace_orbit τ htr p (1-z) + (fun a => (Commute.one_left a).sub_left (hzc.2 a)) (hc n) + have htb : τ ((1-z)*b)=τ ((1-z)*p) := by + have hh := trace_predual_tendsto e τ hτ (predual_tendsto_mul_left e (1-z) hctw) + apply tendsto_nhds_unique hh + simpa only [hcz] using (tendsto_const_nhds : Tendsto (fun _ : ℕ => τ ((1-z)*p)) atTop (𝓝 _)) + have hzbp : τ ((1-z)*p)=0 := by + rw [sub_mul,one_mul,hz.left,sub_self,map_zero] at htb + exact htb.symm + have hr : IsStarProjection ((1-z)*p) := + hzc.1.one_sub.mul hp ((Commute.one_left p).sub_left (hzc.2 p)) + have hzero : (1-z)*p=0 := by + apply hfaith + exact (by simpa only [hr.isSelfAdjoint.star_eq,hr.isIdempotentElem.eq] using hzbp) + have hpz : p ≤ z := (hp.le_iff_mul_eq_right hzc.1).mpr (by + rw [sub_mul,one_mul,sub_eq_zero] at hzero; exact hzero.symm) + have hcbq : ∀ n, c n*q=0 := by + have hh : convexHull ℝ (Set.range (fun u : unitary M => conjugate u p)) ⊆ {a : M | a*q=0} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩ + change (u:M)*p*star (u:M)*q=0 + rw [mul_assoc,mul_assoc,← mul_assoc p,hpq,mul_zero] + · intro a ha b hb r s _hr _hs _hrs + change (r • a+s • b)*q=0 + rw [add_mul,smul_mul_assoc,smul_mul_assoc,ha,hb,smul_zero,smul_zero,add_zero] + exact fun n => hh (hc n) + have hbq : b*q=0 := by + apply predual_tendsto_unique e (predual_tendsto_mul_right e q hctw) + simpa only [hcbq] using predual_tendsto_const e (0:M) (atTop : Filter ℕ) + exact ⟨z,hzc,hpz,hz.annihilate q hbq⟩ + +end HochschildCentralComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralSupportCuts.lean b/lean/OAI/Analysis/BoundedHochschild/CentralSupportCuts.lean new file mode 100644 index 0000000000000000000000000000000000000000..089a8ba69354e33fe50283e910c11fda4d715ac0 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralSupportCuts.lean @@ -0,0 +1,58 @@ +import OAI.Analysis.BoundedHochschild.AbelianSupportEquivalence + +namespace OAI + +/-! Central cuts of projection supports. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open FinitePathMain HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma IsCentralSupport.eq_zero_iff {p z : M} (hp : IsStarProjection p) + (h : IsCentralSupport p z) : p = 0 ↔ z = 0 := by + constructor + · intro hp0 + have hz := h.2.2 1 ⟨IsStarProjection.one M, fun _ => Commute.one_left _⟩ (by simp [hp0]) + simpa only [one_mul] using hz + · intro hz0 + exact le_antisymm (hz0 ▸ h.2.1) hp.nonneg + +lemma IsCentralSupport.centralCut {p t z : M} (hp : IsStarProjection p) + (h : IsCentralSupport p t) (hz : CentralProjection z) : + IsCentralSupport (z * p) (z * t) := by + have hzp := hz.1.mul hp (hz.2 p) + have hzt : CentralProjection (z * t) := + ⟨hz.1.mul h.1.1 (hz.2 t), fun a => (hz.2 a).mul_left (h.1.2 a)⟩ + refine ⟨hzt, (hzp.le_iff_mul_eq_left hzt.1).mpr ?_, ?_⟩ + · calc + z * p * (z * t) = z * (p * t) := + central_idempotent_mul z hz.1.isIdempotentElem.eq (fun a => (hz.2 a).eq) p t + _ = z * p := by rw [(hp.le_iff_mul_eq_left h.1.1).mp h.2.1] + · intro c hc hcp + have hcz : CentralProjection (c * z) := + ⟨hc.1.mul hz.1 (hc.2 z), fun a => (hc.2 a).mul_left (hz.2 a)⟩ + have hh := h.2.2 (c * z) hcz (by simpa only [mul_assoc] using hcp) + simpa only [mul_assoc] using hh + +lemma IsCentralSupport.centralCut_one {p z : M} (hp : IsStarProjection p) + (h : IsCentralSupport p 1) (hz : CentralProjection z) : + IsCentralSupport (z * p) z := by + simpa only [mul_one] using h.centralCut hp hz + +lemma IsCentralSupport.central_cut_nonzero {p z : M} (hp : IsStarProjection p) + (h : IsCentralSupport p 1) (hz : CentralProjection z) (hz0 : z ≠ 0) : z * p ≠ 0 := + fun hp0 => hz0 (((h.centralCut_one hp hz).eq_zero_iff (hz.1.mul hp (hz.2 p))).mp hp0) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralSupportNormalizedRows.lean b/lean/OAI/Analysis/BoundedHochschild/CentralSupportNormalizedRows.lean new file mode 100644 index 0000000000000000000000000000000000000000..f91b6640f73a659f72a0d8fa63dc19d88058fa76 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralSupportNormalizedRows.lean @@ -0,0 +1,93 @@ +import OAI.Analysis.BoundedHochschild.CentralSupportRows + +namespace OAI + +/-! Complete the row covering a central support by the complementary central +projection. The resulting row has square sum one in the given predual. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def centralSupportRow (z : M) (S : Set (PartialIso M)) : Option S → M + | none => 1 - z + | some v => star (v.val : M) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralSupportRow_square (z : M) (hz : IsStarProjection z) + (S : Set (PartialIso M)) (i : Option S) : + centralSupportRow z S i * star (centralSupportRow z S i) = + Option.elim i (1 - z) (fun v => v.val.initial) := by + cases i with + | none => + change (1 - z) * star (1 - z) = 1 - z + rw [hz.one_sub.isSelfAdjoint.star_eq, hz.one_sub.isIdempotentElem.eq] + | some v => simp only [centralSupportRow, star_star, PartialIso.initial, Option.elim_some] + +theorem centralSupportRow_normalized (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {z : M} (hz : IsStarProjection z) (S : Set (PartialIso M)) + (hvz : ∀ v ∈ S, v.initial ≤ z) + (horth : ∀ v ∈ S, ∀ w ∈ S, v ≠ w → v.initial * w.initial = 0) + (ht : PredualTendsto e (fun s : Finset S => ∑ v ∈ s, v.val.initial) atTop z) : + (∀ s : Finset (Option S), + ∑ i ∈ s, centralSupportRow z S i * star (centralSupportRow z S i) ≤ 1) ∧ + PredualTendsto e (fun s : Finset (Option S) => + ∑ i ∈ s, centralSupportRow z S i * star (centralSupportRow z S i)) atTop 1 := by + classical + let q : Option S → M := fun i => Option.elim i (1 - z) (fun v => v.val.initial) + have hq (i : Option S) : IsStarProjection (q i) := by + cases i with + | none => exact hz.one_sub + | some v => exact v.val.initial_proj + have ho (i j : Option S) (hij : i ≠ j) : q i * q j = 0 := by + cases i with + | none => + cases j with + | none => exact (hij rfl).elim + | some v => + change (1 - z) * v.val.initial = 0 + rw [sub_mul, one_mul, (v.val.initial_proj.le_iff_mul_eq_right hz).mp + (hvz v v.property), sub_self] + | some v => + cases j with + | none => + change v.val.initial * (1 - z) = 0 + rw [mul_sub, mul_one, (v.val.initial_proj.le_iff_mul_eq_left hz).mp + (hvz v v.property), sub_self] + | some w => + exact horth v v.property w w.property + (fun h => hij (congrArg some (Subtype.ext h))) + obtain ⟨Q, hQ, hiQ, _, htQ⟩ := exists_orthogonal_projection_sum e q hq ho + have hzQ : z ≤ Q := by + apply (hz.le_iff_mul_eq_left hQ).mpr + have hh := orthogonal_projection_sum_annihilator e (fun v : S => v.val.initial) + (1 - Q) z ht (fun v => by + rw [mul_sub, mul_one, (v.val.initial_proj.le_iff_mul_eq_left hQ).mp + (hiQ (some v)), sub_self]) + rw [mul_sub, mul_one, sub_eq_zero] at hh + exact hh.symm + have hQ1 : Q = 1 := by + have hzfix := (hz.le_iff_mul_eq_right hQ).mp hzQ + have hcfix := (hz.one_sub.le_iff_mul_eq_right hQ).mp (hiQ none) + have he : Q * (z + (1 - z)) = z + (1 - z) := by rw [mul_add, hzfix, hcfix] + simpa only [add_sub_cancel, mul_one] using he + have he (i : Option S) := centralSupportRow_square z hz S i + constructor + · intro s + simpa only [he] using (orthogonal_projection_finset_sum q hq ho s).le_one + · simpa only [he, hQ1] using htQ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralSupportRows.lean b/lean/OAI/Analysis/BoundedHochschild/CentralSupportRows.lean new file mode 100644 index 0000000000000000000000000000000000000000..135c94ea49dd181d509ed26870ea25d206cd401d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralSupportRows.lean @@ -0,0 +1,91 @@ +import OAI.Analysis.BoundedHochschild.AbelianCentralSupport +import OAI.Analysis.BoundedHochschild.OrthogonalProjectionSums + +namespace OAI + +/-! Orthogonal initial projections of partial isometries with final projections +under a given projection exhaust its central support. Only trace-free +comparison and normal projection sums are used. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem exists_central_support_row (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p z : M} (hp : IsStarProjection p) (hz : IsCentralSupport p z) : + ∃ S : Set (PartialIso M), + (∀ v ∈ S, v.final ≤ p ∧ v.initial ≤ z) ∧ + (∀ v ∈ S, ∀ w ∈ S, v ≠ w → v.initial * w.initial = 0) ∧ + PredualTendsto e (fun s : Finset S => ∑ v ∈ s, v.val.initial) atTop z := by + classical + let A : Set (Set (PartialIso M)) := {S | + (∀ v ∈ S, v.final ≤ p ∧ v.initial ≤ z) ∧ + (∀ v ∈ S, ∀ w ∈ S, v ≠ w → v.initial * w.initial = 0)} + obtain ⟨S, hS⟩ := zorn_subset A (fun c hc hchain => by + refine ⟨⋃₀ c, ⟨?_, ?_⟩, fun s hs => Set.subset_sUnion_of_mem hs⟩ + · intro v hv + obtain ⟨s, hs, hvs⟩ := Set.mem_sUnion.mp hv + exact (hc hs).1 v hvs + · intro v hv w hw hvw + obtain ⟨s, hs, hvs⟩ := Set.mem_sUnion.mp hv + obtain ⟨t, ht, hwt⟩ := Set.mem_sUnion.mp hw + rcases hchain.total hs ht with hst | hts + · exact (hc ht).2 v (hst hvs) w hwt hvw + · exact (hc hs).2 v hvs w (hts hwt) hvw) + have horth (v w : S) (hvw : v ≠ w) : v.val.initial * w.val.initial = 0 := + hS.1.2 v v.property w w.property (fun h => hvw (Subtype.ext h)) + obtain ⟨q, hq, hvq, hql, ht⟩ := exists_orthogonal_projection_sum e + (fun v : S => v.val.initial) (fun v => v.val.initial_proj) horth + have hqz : q ≤ z := hql z hz.1.1 (fun v => (hS.1.1 v v.property).2) + have heq : q = z := by + by_contra hne + have hr : IsStarProjection (z - q) := (hq.le_iff_sub hz.1.1).mp hqz + obtain ⟨a, ha⟩ := central_support_full e hp hz hr + (sub_le_self _ hq.nonneg) (sub_ne_zero.mpr (Ne.symm hne)) + obtain ⟨w, hw0, hwi, hwf⟩ := partialIso_of_nonzero_corner e hp hr + (p * a * (z - q)) ha + (by rw [← mul_assoc, ← mul_assoc, hp.isIdempotentElem.eq]) + (by rw [mul_assoc, hr.isIdempotentElem.eq]) + have hqw : q * w.initial = 0 := + HochschildCentralComparison.orthogonal_of_le_sub hz.1.1 hq w.initial_proj hqz hwi + have hvw (v : PartialIso M) (hv : v ∈ S) : v.initial * w.initial = 0 := by + have hvq' := hvq ⟨v, hv⟩ + calc + _ = (v.initial * q) * w.initial := by + rw [(v.initial_proj.le_iff_mul_eq_left hq).mp hvq'] + _ = 0 := by rw [mul_assoc, hqw, mul_zero] + have hnew : insert w S ∈ A := by + refine ⟨?_, ?_⟩ + · intro v hv + rcases hv with rfl | hv + · exact ⟨hwf, hwi.trans (sub_le_self _ hq.nonneg)⟩ + · exact hS.1.1 v hv + · intro v hv t ht hvt + rcases hv with rfl | hv <;> rcases ht with rfl | ht + · exact (hvt rfl).elim + · exact PartialIso.orthogonal_initial_symm (hvw t ht) + · exact hvw v hv + · exact hS.1.2 v hv t ht hvt + have hwS : w ∈ S := hS.2 hnew (Set.subset_insert w S) (Set.mem_insert w S) + have hii : w.initial = 0 := by + simpa only [w.initial_proj.isIdempotentElem.eq] using hvw w hwS + apply hw0 + have hh := w.mul_initial + rw [hii, mul_zero] at hh + exact hh.symm + exact ⟨S, hS.1.1, hS.1.2, heq ▸ ht⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralTypeIIInheritance.lean b/lean/OAI/Analysis/BoundedHochschild/CentralTypeIIInheritance.lean new file mode 100644 index 0000000000000000000000000000000000000000..b06b90bb0498ea6002f12ddd9bc0e0c8380784ca --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralTypeIIInheritance.lean @@ -0,0 +1,103 @@ +import OAI.Analysis.BoundedHochschild.CornerEquivalences +import OAI.Analysis.BoundedHochschild.FiniteCentralDecomposition + +namespace OAI + +/-! +# Type II inheritance by central corners + +An abelian subcorner remains abelian in the ambient algebra. Consequently the +type I condition on a corner lifts to its ambient projection, and absence of a +type I central part passes to central corners. No trace is used. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +omit [PartialOrder M] [StarOrderedRing M] in +/-- Abelianness of a projection in a corner is its ambient abelianness. -/ +lemma abelianProjection_corner_to_ambient {p : M} (hp : IsStarProjection p) + (q : Corner p hp) (hq : IsStarProjection q) + (hab : PopaTypeII.AbelianProjection hq) : + PopaTypeII.AbelianProjection (corner_projection_coe p hp hq) := by + let lift (a : PopaCorner.algebra (corner_projection_coe p hp hq)) : + PopaCorner.algebra hq := + ⟨⟨(a : M), by + constructor + · calc + p * (a : M) = p * ((q : M) * (a : M)) := by rw [a.property.1] + _ = (a : M) := by rw [← mul_assoc, q.property.1, a.property.1] + · calc + (a : M) * p = ((a : M) * (q : M)) * p := by rw [a.property.2] + _ = (a : M) := by rw [mul_assoc, q.property.2, a.property.2]⟩, + Subtype.ext a.property.1, Subtype.ext a.property.2⟩ + intro a b + apply Subtype.ext + exact congrArg (fun t : PopaCorner.algebra hq => ((t : Corner p hp) : M)) + (hab (lift a) (lift b)).eq + +/-- A type I corner of a corner is type I at its ambient projection. -/ +lemma typeICorner_corner_to_ambient {p : M} (hp : IsStarProjection p) + (z : Corner p hp) (hz : IsStarProjection z) + (hI : PopaTypeII.TypeICorner hz) : + PopaTypeII.TypeICorner (corner_projection_coe p hp hz) := by + intro r hr hrz hr0 + have hrp : r ≤ p := hrz.trans (corner_projection_le p hp hz) + let rC : Corner p hp := ⟨r, projection_mem_corner hp hr hrp⟩ + have hrC : IsStarProjection rC := + ⟨Subtype.ext hr.isIdempotentElem.eq, Subtype.ext hr.isSelfAdjoint.star_eq⟩ + have hrCz : rC ≤ z := hrz + have hrC0 : rC ≠ 0 := fun h => hr0 (congrArg Subtype.val h) + obtain ⟨q, hq, hqr, hq0, hqa⟩ := hI rC hrC hrCz hrC0 + refine ⟨(q : M), corner_projection_coe p hp hq, hqr, ?_, + abelianProjection_corner_to_ambient hp q hq hqa⟩ + exact fun h => hq0 (Subtype.ext h) + +/-- The absence of a type I central part passes to a central corner. -/ +theorem noTypeICentralPart_centralCorner {p : M} (hp : IsStarProjection p) + (hc : ∀ a : M, p * a = a * p) + (hM : PopaTypeII.NoTypeICentralPart M) : + PopaTypeII.NoTypeICentralPart (Corner p hp) := by + intro z hz hzc hz0 hI + apply hM (z : M) (corner_projection_coe p hp hz) + · intro a + exact centralCorner_central hp hc z (fun b => (hzc b).eq) a + · exact fun h => hz0 (Subtype.ext h) + · exact typeICorner_corner_to_ambient hp z hz hI + +/-- A smaller ambient central corner inherits the type II condition from a +larger corner. Centrality of the larger projection is not needed. -/ +theorem noTypeICentralPart_smaller_centralCorner {p q : M} + (hp : IsStarProjection p) (hq : IsStarProjection q) (hpq : p ≤ q) + (hcp : ∀ a : M, p * a = a * p) + (hQ : PopaTypeII.NoTypeICentralPart (Corner q hq)) : + PopaTypeII.NoTypeICentralPart (Corner p hp) := by + let pQ : Corner q hq := ⟨p, projection_mem_corner hq hp hpq⟩ + have hpQ : IsStarProjection pQ := + ⟨Subtype.ext hp.isIdempotentElem.eq, Subtype.ext hp.isSelfAdjoint.star_eq⟩ + have hpc : ∀ a : Corner q hq, pQ * a = a * pQ := by + intro a + exact Subtype.ext (hcp (a : M)) + exact noTypeICentralPart_map_equiv (nestedCornerEquiv hq pQ hpQ) + (noTypeICentralPart_centralCorner hpQ hpc hQ) + +/-- Central-corner inheritance with both ambient centrality witnesses. -/ +theorem noTypeICentralPart_centralCorner_mono {p q : M} + (hp : IsStarProjection p) (hq : IsStarProjection q) + (hcp : ∀ a : M, p * a = a * p) (_hcq : ∀ a : M, q * a = a * q) + (hpq : p ≤ q) (hQ : PopaTypeII.NoTypeICentralPart (Corner q hq)) : + PopaTypeII.NoTypeICentralPart (Corner p hp) := + noTypeICentralPart_smaller_centralCorner hp hq hpq hcp hQ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CentralVanishing.lean b/lean/OAI/Analysis/BoundedHochschild/CentralVanishing.lean new file mode 100644 index 0000000000000000000000000000000000000000..88de142543b911ad1309021f0cd9f6fdb535e334 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CentralVanishing.lean @@ -0,0 +1,109 @@ +import OAI.Analysis.BoundedHochschild.Conditional +import OAI.Analysis.BoundedHochschild.OperatorTransport + +namespace OAI + +/-! +# Vanishing for central partitions into proved cases + +This is an unconditional application of the tracial argument and the full +operator algebra homotopy. Its structural hypothesis gives actual central +corners, each either faithfully normally tracial of type II₁ or explicitly +isomorphic to a full operator algebra. It makes no cohomological assumptions. +It does not assert that every von Neumann algebra has such a partition. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners +open scoped ComplexOrder + +universe u + +/-- An actual presentation as a full algebra of Hilbert-space operators. -/ +def FullOperatorAlgebra (N : Type u) [CStarAlgebra N] : Prop := + ∃ (H : Type u) (_ : NormedAddCommGroup H) (_ : InnerProductSpace ℂ H) + (_ : CompleteSpace H), Nonempty ((H →L[ℂ] H) ≃⋆ₐ[ℂ] N) + +theorem FullOperatorAlgebra.primitive {N : Type u} [CStarAlgebra N] + (hN : FullOperatorAlgebra N) {n : ℕ} (f : Cochain N (n + 2)) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain N (n + 1), ‖g‖ ≤ ‖f‖ ∧ + ∀ x, differentialValue g x = f x := by + rcases hN with ⟨H, hH, hHI, hHC, ⟨φ⟩⟩ + let := hH + let := hHI + let := hHC + exact primitive_of_full_operator_equiv φ f hf + +/-- A central partition into two classes for which the primitive is proved. -/ +structure TracialOperatorPartition (M : Type u) [CStarAlgebra M] + [PartialOrder M] [StarOrderedRing M] where + Index : Type u + projection : Index → M + isProjection : ∀ i, IsStarProjection (projection i) + central : ∀ i a, projection i * a = a * projection i + orthogonal : ∀ i j, i ≠ j → projection i * projection j = 0 + total : ∀ x : M, (∀ i, projection i * x = 0) → x = 0 + cases : ∀ i, TracialTypeII (Corner (projection i) (isProjection i)) ∨ + FullOperatorAlgebra (Corner (projection i) (isProjection i)) + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Uniform primitives assemble across an arbitrary, possibly uncountable center. -/ +theorem primitive_of_tracial_operator_partition + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (D : TracialOperatorPartition M) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ‖g‖ ≤ 12 * ‖f‖ + ((n + 1 : ℕ) : ℝ) * ‖f‖ ∧ + ∀ x, differentialValue g x = f x := by + classical + have hpieces (i : D.Index) : + ∃ b : Cochain (Corner (D.projection i) (D.isProjection i)) (n + 1), + ‖b‖ ≤ 12 * ‖f‖ ∧ ∀ x, differentialValue b x = + CentralCorner.restrict (D.projection i) (D.isProjection i) (D.central i) f x := by + let F := CentralCorner.restrict (D.projection i) (D.isProjection i) (D.central i) f + have hF : ∀ x, differentialValue F x = 0 := + CentralCorner.restrict_cocycle _ _ _ f hf + have hFn : ‖F‖ ≤ ‖f‖ := CentralCorner.restrict_norm _ _ _ f + rcases D.cases i with htracial | hoperator + · obtain ⟨b, hbn, hb⟩ := htracial.primitive F hF + exact ⟨b, hbn.trans (mul_le_mul_of_nonneg_left hFn (by norm_num)), hb⟩ + · obtain ⟨b, hbn, hb⟩ := hoperator.primitive F hF + refine ⟨b, (hbn.trans hFn).trans ?_, hb⟩ + nlinarith [norm_nonneg f] + choose b hbn hb using hpieces + exact primitive_of_central_cut_primitives e (HochschildSakai.mul_hasPreadjoint e) + D.projection D.isProjection D.central D.orthogonal D.total f hf + (fun i => CentralCorner.extend (D.projection i) (D.isProjection i) (D.central i) (b i)) + (fun i => CentralCorner.extend_supported _ _ _ _) + (fun i => CentralCorner.extend_primitive _ _ _ f (b i) (hb i)) + (12 * ‖f‖) (by positivity) + (fun i => (CentralCorner.extend_norm _ _ _ _).trans (hbn i)) + +/-- Actual-image cohomology vanishes under this structural, non-cohomological hypothesis. -/ +theorem vanishing_of_tracial_operator_partition [WStarAlgebra M] + (D : TracialOperatorPartition M) (k : ℕ) (hk : 2 ≤ k) : + Subsingleton (Cohomology M k) := by + apply (cohomology_subsingleton_iff M k).mpr + obtain ⟨Y, hY, hYS, hYC, ⟨e⟩⟩ := WStarAlgebra.exists_predual (M := M) + let := hY + let := hYS + let := hYC + obtain ⟨n, rfl⟩ := Nat.exists_eq_add_of_le' hk + intro f hf + obtain ⟨g, _, hg⟩ := primitive_of_tracial_operator_partition e D f + ((differential_eq_zero_iff f).mp hf) + refine ⟨g, ?_⟩ + ext x + simpa only [incomingDifferential_succ, differential_apply] using hg x + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/ClassicalVanishingReduction.lean b/lean/OAI/Analysis/BoundedHochschild/ClassicalVanishingReduction.lean new file mode 100644 index 0000000000000000000000000000000000000000..dcbd835ddc4183a893f251001ff833f0ea9c079e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/ClassicalVanishingReduction.lean @@ -0,0 +1,84 @@ +import OAI.Analysis.BoundedHochschild.InfiniteCentralReduction + +namespace OAI + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners + +universe u + +def ProperlyInfiniteVanishingInput : Prop := + ∀ (N : Type u) [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N], + WStarAlgebra N → NoFiniteCentralSummand N → + ∀ (n : ℕ) (f : Cochain N (n + 2)), (∀ x, differentialValue f x = 0) → + ∃ g : Cochain N (n + 1), ∀ x, differentialValue g x = f x + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma primitive_from_central_corner {p : M} (hp : IsStarProjection p) + (hc : ∀ a : M, p * a = a * p) {n : ℕ} (f : Cochain M (n + 1)) + (hf : ∀ x, differentialValue f x = 0) (b : Cochain (Corner p hp) n) + (hb : ∀ x, differentialValue b x = CentralCorner.restrict p hp hc f x) : + ∃ g : Cochain M n, ∀ x, differentialValue g x = p * f x := by + have hs (x : Fin (n + 1) → M) : p * centralOutput p f x = centralOutput p f x := by + simp only [centralOutput_apply, ← mul_assoc, hp.isIdempotentElem.eq] + have hpf (x : Fin (n + 2) → M) : differentialValue (centralOutput p f) x = 0 := by + rw [← central_differential_values p hc f (centralOutput p f) (fun _ => rfl), hf, mul_zero] + obtain ⟨a, _, _, ha⟩ := central_cocycle_correction p hp hc (centralOutput p f) hs hpf + refine ⟨CentralCorner.extend p hp hc b + a, fun x => ?_⟩ + rw [differentialValue_add, CentralCorner.extend_primitive p hp hc f b hb, ha] + change _ = centralOutput p f x + abel + +theorem classical_primitive_of_properlyInfinite_input + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hproper : ProperlyInfiniteVanishingInput.{u}) + (hno : NoTypeII1Summand M) {n : ℕ} (f : Cochain M (n + 2)) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := by + obtain ⟨p, hp, hc, hfin, hcomp⟩ := exists_finite_central_cut_noFiniteSummand e + have hcc (a : M) : (1 - p) * a = a * (1 - p) := by + simp only [sub_mul, mul_sub, one_mul, mul_one, hc] + obtain ⟨b, _, hb⟩ := finite_noTypeII1_primitive (cornerPredualEquiv p hp e) hfin + (noTypeII1_centralCorner hno hp hc) (CentralCorner.restrict p hp hc f) + (CentralCorner.restrict_cocycle p hp hc f hf) + let N := Corner (1 - p) hp.one_sub + let eN := cornerPredualEquiv (1 - p) hp.one_sub e + let : WStarAlgebra N := ⟨⟨CornerPredual (1 - p) hp.one_sub e, + inferInstance, inferInstance, inferInstance, ⟨eN⟩⟩⟩ + obtain ⟨c, hcoc⟩ := hproper N inferInstance hcomp n + (CentralCorner.restrict (1 - p) hp.one_sub hcc f) + (CentralCorner.restrict_cocycle _ _ _ f hf) + obtain ⟨g, hg⟩ := primitive_from_central_corner hp hc f hf b hb + obtain ⟨h, hh⟩ := primitive_from_central_corner hp.one_sub hcc f hf c hcoc + refine ⟨g + h, fun x => ?_⟩ + rw [differentialValue_add, hg, hh] + noncomm_ring + +theorem classicalVanishing_of_properlyInfinite (hproper : ProperlyInfiniteVanishingInput.{u}) : + ClassicalVanishingInput.{u} := by + intro M hM hPO hSO hW hno n f hf + let := hW + obtain ⟨X, hX, hXS, hXC, ⟨e⟩⟩ := WStarAlgebra.exists_predual (M := M) + let := hX + let := hXS + let := hXC + exact classical_primitive_of_properlyInfinite_input e hproper hno f hf + +theorem primitive_of_properlyInfinite_input (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hproper : ProperlyInfiniteVanishingInput.{u}) {n : ℕ} (f : Cochain M (n + 2)) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := + primitive_of_classical_vanishing e (classicalVanishing_of_properlyInfinite hproper) f hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CochainAverages.lean b/lean/OAI/Analysis/BoundedHochschild/CochainAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..215786b8c96e1aa0e36c0bee15d72b59ba3b5d9d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CochainAverages.lean @@ -0,0 +1,193 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CochainLimits +import OAI.Analysis.BoundedHochschild.CollisionBounds + +namespace OAI + +/-! Cesaro averaging and fixed cocycles. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open Filter Topology +namespace HochschildCesaro +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + +noncomputable def avg (P : E →L[ℂ] E) (f : E) (n : ℕ) : E := + (n+1 : ℂ)⁻¹ • ∑ j ∈ Finset.range (n+1), P^[j] f + +lemma iterate_norm_le (P : E →L[ℂ] E) (hP : ∀ x, ‖P x‖ ≤ ‖x‖) + (f : E) (j : ℕ) : ‖P^[j] f‖ ≤ ‖f‖ := by + induction j with + | zero => exact le_rfl + | succ j ih => simpa only [Function.iterate_succ_apply'] using (hP (P^[j] f)).trans ih + +lemma norm_avg_le (P : E →L[ℂ] E) (hP : ∀ x, ‖P x‖ ≤ ‖x‖) + (f : E) (n : ℕ) : ‖avg P f n‖ ≤ ‖f‖ := by + have hn : (0 : ℝ) < n+1 := by positivity + have hs : ‖∑ j ∈ Finset.range (n+1), P^[j] f‖ ≤ (n+1 : ℝ) * ‖f‖ := by + calc + _ ≤ ∑ j ∈ Finset.range (n+1), ‖P^[j] f‖ := norm_sum_le _ _ + _ ≤ ∑ _ ∈ Finset.range (n+1), ‖f‖ := + Finset.sum_le_sum fun j _ => iterate_norm_le P hP f j + _ = _ := by simp [nsmul_eq_mul] + calc + ‖avg P f n‖ = (n+1 : ℝ)⁻¹ * ‖∑ j ∈ Finset.range (n+1), P^[j] f‖ := by + rw [avg, norm_smul, norm_inv, ← Nat.cast_add_one, Complex.norm_natCast, Nat.cast_add_one] + _ ≤ (n+1 : ℝ)⁻¹ * ((n+1 : ℝ) * ‖f‖) := mul_le_mul_of_nonneg_left hs (by positivity) + _ = ‖f‖ := by rw [← mul_assoc, inv_mul_cancel₀ hn.ne', one_mul] + +lemma sum_defect (P : E →L[ℂ] E) (f : E) (n : ℕ) : + P (∑ j ∈ Finset.range n, P^[j] f) - (∑ j ∈ Finset.range n, P^[j] f) = P^[n] f - f := by + induction n with + | zero => simp + | succ n ih => + rw [Finset.sum_range_succ, map_add] + rw [show P (P^[n] f) = P^[n+1] f by rw [Function.iterate_succ_apply']] + calc + _ = (P (∑ j ∈ Finset.range n, P^[j] f) - (∑ j ∈ Finset.range n, P^[j] f)) + (P^[n+1] f - P^[n] f) := by abel + _ = _ := by rw [ih]; abel + +lemma avg_defect (P : E →L[ℂ] E) (f : E) (n : ℕ) : + P (avg P f n) - avg P f n = (n+1 : ℂ)⁻¹ • (P^[n+1] f - f) := by + simp only [avg,map_smul,← smul_sub,sum_defect] + +lemma avg_defect_tendsto (P : E →L[ℂ] E) (hP : ∀ x, ‖P x‖ ≤ ‖x‖) (f : E) : + Tendsto (fun n => P (avg P f n) - avg P f n) atTop (𝓝 0) := by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + have H : Tendsto (fun n : ℕ => (n+1 : ℝ)⁻¹ * (2*‖f‖)) atTop (𝓝 0) := by + simpa using (tendsto_one_div_add_atTop_nhds_zero_nat (𝕜 := ℝ)).mul_const (2*‖f‖) + apply squeeze_zero (fun _ => norm_nonneg _) (fun n => ?_) H + rw [avg_defect,norm_smul] + have hn : ‖(n+1:ℂ)⁻¹‖ = (n+1 : ℝ)⁻¹ := by + rw [norm_inv, ← Nat.cast_add_one, Complex.norm_natCast, Nat.cast_add_one] + rw [hn] + apply mul_le_mul_of_nonneg_left _ (by positivity) + exact (norm_sub_le _ _).trans (by linarith [iterate_norm_le P hP f (n+1)]) + +end HochschildCesaro + +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] +lemma residual_cesaro {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x = 0) (j : ℕ) : + ∀ v x, residualCLM x (translateLast (HochschildCesaro.avg (averageLastCLM p u hp hs) f j) v) = + ((-1:ℂ)^(n+1)) • f x := by + intro v x + let L : Cochain M (n+1) →L[ℂ] M := (residualCLM x).comp (translateLastCLM v) + change L (HochschildCesaro.avg (averageLastCLM p u hp hs) f j) = _ + rw [HochschildCesaro.avg,map_smul,map_sum] + have hL (k : ℕ) : L ((averageLastCLM p u hp hs)^[k] f) = ((-1:ℂ)^(n+1)) • f x := + residual_iterate p u hp hs f hf k v x + simp only [hL,Finset.sum_const,Finset.card_range,← Nat.cast_smul_eq_nsmul ℂ, Nat.cast_add_one,smul_smul] + rw [← mul_assoc,inv_mul_cancel₀ (show (j+1:ℂ) ≠ 0 by exact_mod_cast Nat.succ_ne_zero j),one_mul] + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +lemma averageLast_apply {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : Summable p) (F : Cochain M (n+1)) (x : Fin (n+1) → M) : + averageLast p u F x = ∑' j, (p j : ℂ) • translateLast F (u j) x := by + exact (ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M x).map_tsum + (summable_averageLast p u hp hs F) + +lemma predual_tendsto_average {n : ℕ} + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (p : ℕ → ℝ) (u : ℕ → unitary M) (hp : ∀ i, 0 ≤ p i) (hs : Summable p) + {F : I → Cochain M (n+1)} {G : Cochain M (n+1)} {l : Filter I} [l.NeBot] + (C : ℝ) (hF : ∀ i, ‖F i‖ ≤ C) + (ht : ∀ x, PredualTendsto e (fun i => F i x) l (G x)) : + ∀ x, PredualTendsto e (fun i => averageLast p u (F i) x) l (averageLast p u G x) := by + intro x + simp_rw [averageLast_apply p u hp hs] + apply predual_tendsto_tsum e (fun j => p j * (C * ∏ k, ‖x k‖)) (hs.mul_right _) + · intro i j + rw [norm_smul,Complex.norm_real,Real.norm_eq_abs,abs_of_nonneg (hp j)] + apply mul_le_mul_of_nonneg_left _ (hp j) + exact ((translateLast (F i) (u j)).le_opNorm x).trans + (mul_le_mul_of_nonneg_right ((norm_translateLast_le _ _).trans (hF i)) + (Finset.prod_nonneg fun k _ => norm_nonneg _)) + · intro j + apply predual_tendsto_smul e _ (p j : ℂ) + simp only [translateLast_apply] + exact (hR (star (u j : M))).tendsto e (ht _) + +lemma predual_tendsto_residual {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + {F : I → Cochain M (n+1)} {G : Cochain M (n+1)} {l : Filter I} + (ht : ∀ x, PredualTendsto e (fun i => F i x) l (G x)) (x : Fin (n+1) → M) : + PredualTendsto e (fun i => residualCLM x (F i)) l (residualCLM x G) := by + simp only [residualCLM_apply] + apply predual_tendsto_add e + · apply predual_tendsto_add e + · exact (hL (x 0)).tendsto e (ht _) + · apply predual_tendsto_sum e l Finset.univ + intro j _ + exact predual_tendsto_smul e (ht _) _ + · exact predual_tendsto_smul e (ht _) _ + + + +theorem exists_average_fixed_cocycle {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (p : ℕ → ℝ) (u : ℕ → unitary M) (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) + (f : Cochain M (n+1)) (hf : ∀ x : Fin (n+2) → M, differentialValue f x = 0) : + ∃ G : Cochain M (n+1), ‖G‖ ≤ ‖f‖ ∧ averageLast p u G = G ∧ + (∀ x, residualCLM x G = ((-1:ℂ)^(n+1)) • f x) ∧ + ∃ U : Ultrafilter ℕ, (U : Filter ℕ) ≤ atTop ∧ + ∀ x, PredualTendsto e + (fun j => HochschildCesaro.avg (averageLastCLM p u hp hs) f j x) U (G x) := by + let P : Cochain M (n+1) →L[ℂ] Cochain M (n+1) := averageLastCLM p u hp hs + let F : ℕ → Cochain M (n+1) := fun j => HochschildCesaro.avg P f j + let U : Ultrafilter ℕ := Ultrafilter.of atTop + have hU : (U : Filter ℕ) ≤ atTop := Ultrafilter.of_le atTop + have hP (g : Cochain M (n+1)) : ‖P g‖ ≤ ‖g‖ := norm_averageLast_le p u hp hs g + have hF (j : ℕ) : ‖F j‖ ≤ ‖f‖ := HochschildCesaro.norm_avg_le P hP f j + obtain ⟨G,hG,ht⟩ := bounded_cochain_ultralimit e U F ‖f‖ (norm_nonneg _) hF + have hfix : averageLast p u G = G := by + ext x + have hpa := predual_tendsto_average e hR p u hp hs.summable ‖f‖ hF ht x + have hsub := predual_tendsto_sub e hpa (ht x) + have hn : Tendsto (fun j => P (F j)-F j) (U : Filter ℕ) (𝓝 0) := + (HochschildCesaro.avg_defect_tendsto P hP f).mono_left hU + have hxn : Tendsto (fun j => (P (F j)-F j) x) (U : Filter ℕ) (𝓝 0) := by + convert + ((ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M x).continuous.tendsto 0).comp hn using 1 + · rfl + · simp + + have hz := predual_tendsto_of_norm e hxn + have he := predual_tendsto_unique e hsub hz + exact sub_eq_zero.mp he + refine ⟨G,hG,hfix,?_,U,hU,ht⟩ + intro x + have hr := predual_tendsto_residual e hL ht x + have hid (j : ℕ) : residualCLM x (F j) = ((-1:ℂ)^(n+1)) • f x := by + simpa only [translateLast_one] using residual_cesaro p u hp hs f hf j 1 x + apply predual_tendsto_unique e hr + simp only [hid] + exact predual_tendsto_const e (((-1:ℂ)^(n+1)) • f x) (U : Filter ℕ) + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CochainLimitDifferential.lean b/lean/OAI/Analysis/BoundedHochschild/CochainLimitDifferential.lean new file mode 100644 index 0000000000000000000000000000000000000000..961ff094dc0e05d999d4346adf3512fdfaf71ef8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CochainLimitDifferential.lean @@ -0,0 +1,37 @@ +import OAI.Analysis.BoundedHochschild.NormalMultiplication +import OAI.Analysis.BoundedHochschild.PrimitiveAverages + +namespace OAI + +/-! +# Weak-star limits and the Hochschild differential + +Separate weak-star continuity of multiplication, obtained from the predual, +lets the bounded Hochschild differential pass through pointwise weak-star +limits. No additional normality assumption on the cochains is required. +-/ + +noncomputable section + +namespace BoundedHochschild + +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +/-- The differential preserves pointwise convergence against the predual. -/ +theorem predual_tendsto_differential_of_predual + {n : ℕ} {F : I → Cochain M n} {G : Cochain M n} {l : Filter I} + (h : ∀ x, PredualTendsto e (fun i => F i x) l (G x)) + (x : Fin (n + 1) → M) : + PredualTendsto e (fun i => differentialValue (F i) x) l (differentialValue G x) := by + let : PartialOrder M := CStarAlgebra.spectralOrder M + let : StarOrderedRing M := CStarAlgebra.spectralOrderedRing M + exact predual_tendsto_differential e (HochschildSakai.mul_hasPreadjoint e) + (HochschildSakai.mul_right_hasPreadjoint e) h x + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CochainLimits.lean b/lean/OAI/Analysis/BoundedHochschild/CochainLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..79230dd8ae0500f8738d9b25855625a763131c62 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CochainLimits.lean @@ -0,0 +1,298 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.Cochains + +namespace OAI + +/-! Weak-star cochain limits, averaging operators and preadjoints. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open Filter Topology +namespace BoundedHochschild +variable {M X I : Type*} [NormedAddCommGroup M] [NormedSpace ℂ M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + + +def PredualTendsto (a : I → M) (l : Filter I) (b : M) : Prop := + ∀ z : X, Tendsto (fun i => e.symm (a i) z) l (𝓝 (e.symm b z)) + +lemma predual_tendsto_unique {a : I → M} {l : Filter I} [l.NeBot] {b c : M} + (hb : PredualTendsto e a l b) (hc : PredualTendsto e a l c) : b = c := by + apply e.symm.injective + ext z + exact tendsto_nhds_unique (hb z) (hc z) + +lemma predual_tendsto_const (m : M) (l : Filter I) : + PredualTendsto e (fun _ => m) l m := fun _ => tendsto_const_nhds + +lemma predual_tendsto_add {a b : I → M} {l : Filter I} {c d : M} + (ha : PredualTendsto e a l c) (hb : PredualTendsto e b l d) : + PredualTendsto e (fun i => a i+b i) l (c+d) := by + intro z + simpa only [map_add,add_apply] using (ha z).add (hb z) + +lemma predual_tendsto_smul {a : I → M} {l : Filter I} {b : M} + (ha : PredualTendsto e a l b) (c : ℂ) : + PredualTendsto e (fun i => c • a i) l (c • b) := by + intro z + simpa only [LinearIsometryEquiv.map_smulₛₗ,smul_apply,smul_eq_mul] + using (ha z).const_mul (starRingEnd ℂ c) + +lemma exists_predual_ultralimit (u : Ultrafilter I) (a : I → M) (C : ℝ) + (hb : ∀ i, ‖a i‖ ≤ C) : + ∃ b : M, ‖b‖ ≤ C ∧ PredualTendsto e a u b := by + let j : I → WeakDual ℂ X := fun i => StrongDual.toWeakDual (e.symm (a i)) + have hmem : (u.map j : Filter (WeakDual ℂ X)) ≤ + 𝓟 (WeakDual.toStrongDual ⁻¹' Metric.closedBall (0 : StrongDual ℂ X) C) := by + rw [Ultrafilter.coe_map,Filter.map_le_iff_le_comap, Filter.comap_principal] + apply Filter.le_principal_iff.mpr + exact Filter.Eventually.of_forall fun i => by + simpa [j,Metric.mem_closedBall] using hb i + obtain ⟨b,hb',ht⟩ := (WeakDual.isCompact_closedBall (0 : StrongDual ℂ X) C).ultrafilter_le_nhds (u.map j) hmem + refine ⟨e (WeakDual.toStrongDual b),?_,?_⟩ + · simpa only [LinearIsometryEquiv.norm_map,Set.mem_preimage, + Metric.mem_closedBall,dist_zero_right] using hb' + · intro z + have hjt : Tendsto j (u : Filter I) (𝓝 b) := by + simpa only [Ultrafilter.coe_map, Filter.Tendsto] using ht + have hz := (WeakDual.eval_continuous z).tendsto b |>.comp hjt + change Tendsto (fun i => e.symm (a i) z) (u : Filter I) (𝓝 (b z)) at hz + simpa only [LinearIsometryEquiv.symm_apply_apply, WeakDual.toStrongDual_apply] using hz + + + +theorem bounded_cochain_ultralimit {n : ℕ} (u : Ultrafilter I) + (F : I → Cochain M n) (C : ℝ) (hC : 0 ≤ C) (hF : ∀ i, ‖F i‖ ≤ C) : + ∃ G : Cochain M n, ‖G‖ ≤ C ∧ + ∀ x, PredualTendsto e (fun i => F i x) u (G x) := by + classical + have hex (x : Fin n → M) : ∃ b : M, ‖b‖ ≤ C * ∏ k, ‖x k‖ ∧ + PredualTendsto e (fun i => F i x) u b := + exists_predual_ultralimit e u (fun i => F i x) _ (fun i => + (F i).le_opNorm x |>.trans (mul_le_mul_of_nonneg_right (hF i) + (Finset.prod_nonneg (fun k _ => norm_nonneg (x k))))) + choose b hb ht using hex + let G₀ : MultilinearMap ℂ (fun _ : Fin n => M) M := + { toFun := b + map_update_add' := fun x k a c => by + apply predual_tendsto_unique e (ht (Function.update x k (a+c))) + simpa only [ContinuousMultilinearMap.map_update_add] using + predual_tendsto_add e (ht (Function.update x k a)) (ht (Function.update x k c)) + map_update_smul' := fun x k c a => by + apply predual_tendsto_unique e (ht (Function.update x k (c • a))) + simpa only [ContinuousMultilinearMap.map_update_smul] using + predual_tendsto_smul e (ht (Function.update x k a)) c } + exact ⟨G₀.mkContinuous C hb, G₀.mkContinuous_norm_le hC hb, ht⟩ + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M : Type*} [CStarAlgebra M] + +noncomputable def translateLastCLM {n : ℕ} (u : unitary M) : + Cochain M (n+1) →L[ℂ] Cochain M (n+1) := + LinearMap.mkContinuous + { toFun := fun f => translateLast f u + map_add' := fun f g => translateLast_add f g u + map_smul' := fun c f => translateLast_smul c f u } + 1 (fun f => by change ‖translateLast f u‖ ≤ 1 * ‖f‖; simpa only [one_mul] using norm_translateLast_le f u) + +@[simp] theorem translateLast_one {n : ℕ} (f : Cochain M (n+1)) : + translateLast f 1 = f := by + ext x + simp only [translateLast_apply,Submonoid.coe_one,star_one,mul_one] + congr 1 + funext i + refine Fin.lastCases ?_ (fun j => ?_) i <;> simp + +@[simp] theorem translateLast_mul {n : ℕ} (f : Cochain M (n+1)) (u v : unitary M) : + translateLast (translateLast f v) u = translateLast f (u*v) := by + ext x + simp only [translateLast_apply,Fin.snoc_last,Fin.snoc_castSucc,Submonoid.coe_mul, + star_mul,mul_assoc] + +noncomputable def averageLastCLM {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) : + Cochain M (n+1) →L[ℂ] Cochain M (n+1) := + LinearMap.mkContinuous + { toFun := averageLast p u + map_add' := fun f g => by + simp only [averageLast,translateLast_add,smul_add] + exact Summable.tsum_add (summable_averageLast p u hp hs.summable f) + (summable_averageLast p u hp hs.summable g) + map_smul' := fun c f => by + simp only [averageLast,translateLast_smul,smul_comm (p _ : ℂ) c, + tsum_const_smul'',RingHom.id_apply] } + 1 (fun f => by change ‖averageLast p u f‖ ≤ 1 * ‖f‖; simpa only [one_mul] using norm_averageLast_le p u hp hs f) + +@[simp] theorem averageLastCLM_apply {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) (f : Cochain M (n+1)) : + averageLastCLM p u hp hs f = averageLast p u f := rfl + + + +noncomputable def residualCLM {n : ℕ} (x : Fin (n+1) → M) : Cochain M (n+1) →L[ℂ] M := + (ContinuousLinearMap.mul ℂ M (x 0)).comp + (ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M + (Fin.snoc (fun i : Fin n => x i.succ) 1)) + + ∑ j : Fin n, ((-1:ℂ)^(j.val+1)) • + ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M + (Fin.snoc (mergeInputs x j) 1) + + ((-1:ℂ)^(n+1)) • ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M x + +@[simp] theorem residualCLM_apply {n : ℕ} (x : Fin (n+1) → M) (F : Cochain M (n+1)) : + residualCLM x F = + x 0 * F (Fin.snoc (fun i : Fin n => x i.succ) 1) + + ∑ j : Fin n, ((-1:ℂ)^(j.val+1)) • F (Fin.snoc (mergeInputs x j) 1) + + ((-1:ℂ)^(n+1)) • F x := by + simp [residualCLM] + +lemma residual_eq_differential {n : ℕ} (x : Fin (n+1) → M) (F : Cochain M (n+1)) : + residualCLM x F = differentialValue (insertLast F 1) x + + ((-1:ℂ)^(n+1)) • + (F x - insertLast F 1 (fun i : Fin n => x i.castSucc) * x (Fin.last n)) := by + simp only [residualCLM_apply,differentialValue,insertLast_apply,smul_sub] + abel + +lemma insertLast_translateLast {n : ℕ} (f : Cochain M (n+1)) (u : unitary M) : + insertLast (translateLast f u) 1 = lastHomotopy f (u:M) (star (u:M)) := by + ext x + simp [translateLast_apply] + +lemma residual_translate_cocycle {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x = 0) + (u : unitary M) (x : Fin (n+1) → M) : + residualCLM x (translateLast f u) = ((-1:ℂ)^(n+1)) • f x := by + rw [residual_eq_differential,insertLast_translateLast, + lastHomotopy_cocycle f hf (u:M) (star (u:M)) (Unitary.mul_star_self_of_mem u.property)] + simp only [translateLast_apply,smul_add,smul_sub] + abel + + + +lemma residual_average_invariant {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) (F : Cochain M (n+1)) + (c : (Fin (n+1) → M) → M) + (hF : ∀ v x, residualCLM x (translateLast F v) = c x) : + ∀ v x, residualCLM x (translateLast (averageLast p u F) v) = c x := by + intro v x + let L : Cochain M (n+1) →L[ℂ] M := (residualCLM x).comp (translateLastCLM v) + have he : L (averageLast p u F) = ∑' i, (p i : ℂ) • c x := by + rw [averageLast,L.map_tsum (summable_averageLast p u hp hs.summable F)] + congr 1 + funext i + simp only [map_smul,L,ContinuousLinearMap.comp_apply] + change (p i:ℂ) • residualCLM x (translateLast (translateLast F (u i)) v) = _ + rw [translateLast_mul,hF] + change L (averageLast p u F) = _ + rw [he] + have hsc : HasSum (fun i => (p i : ℂ)) 1 := by simpa only [Complex.ofReal_one] using Complex.hasSum_ofReal.mpr hs + simpa only [one_smul] using (hsc.smul_const (c x)).tsum_eq + +lemma residual_iterate {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ i, 0 ≤ p i) (hs : HasSum p 1) (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x = 0) (j : ℕ) : + ∀ v x, residualCLM x (translateLast ((averageLastCLM p u hp hs)^[j] f) v) = + ((-1:ℂ)^(n+1)) • f x := by + induction j with + | zero => exact fun v x => residual_translate_cocycle f hf v x + | succ j ih => + rw [Function.iterate_succ_apply'] + exact residual_average_invariant p u hp hs _ _ ih + +end BoundedHochschild + + + +open Filter Topology +namespace BoundedHochschild +variable {M X I J : Type*} [NormedAddCommGroup M] [NormedSpace ℂ M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +lemma predual_tendsto_of_norm {a : I → M} {l : Filter I} {b : M} + (h : Tendsto a l (𝓝 b)) : PredualTendsto e a l b := by + intro z + exact (((ContinuousLinearMap.apply ℂ ℂ) z).continuous.tendsto _).comp + (e.symm.continuous.tendsto _ |>.comp h) + +lemma predual_tendsto_neg {a : I → M} {l : Filter I} {b : M} + (h : PredualTendsto e a l b) : PredualTendsto e (fun i => -a i) l (-b) := by + intro z + simpa only [map_neg,neg_apply] using (h z).neg + +lemma predual_tendsto_sub {a b : I → M} {l : Filter I} {c d : M} + (ha : PredualTendsto e a l c) (hb : PredualTendsto e b l d) : + PredualTendsto e (fun i => a i-b i) l (c-d) := by + simpa only [sub_eq_add_neg] using predual_tendsto_add e ha (predual_tendsto_neg e hb) + +lemma predual_tendsto_sum {a : I → J → M} {b : J → M} (l : Filter I) (s : Finset J) + (h : ∀ j ∈ s, PredualTendsto e (fun i => a i j) l (b j)) : + PredualTendsto e (fun i => ∑ j ∈ s, a i j) l (∑ j ∈ s, b j) := by + intro z + simpa only [map_sum,sum_apply] using + tendsto_finsetSum s (fun j hj => h j hj z) + +lemma predual_norm_le {a : I → M} {l : Filter I} [l.NeBot] {b : M} (C : ℝ) + (hC : 0 ≤ C) (ha : ∀ᶠ i in l, ‖a i‖ ≤ C) (h : PredualTendsto e a l b) : ‖b‖ ≤ C := by + rw [← e.symm.norm_map b] + apply ContinuousLinearMap.opNorm_le_bound _ hC + intro z + apply le_of_tendsto (h z).norm + filter_upwards [ha] with i hi + calc + ‖e.symm (a i) z‖ ≤ ‖e.symm (a i)‖ * ‖z‖ := (e.symm (a i)).le_opNorm z + _ ≤ C * ‖z‖ := mul_le_mul_of_nonneg_right (by simpa using hi) (norm_nonneg _) + +lemma predual_tendsto_tsum [CompleteSpace M] {a : I → J → M} {b : J → M} + {l : Filter I} [l.NeBot] (C : J → ℝ) (hC : Summable C) + (ha : ∀ i j, ‖a i j‖ ≤ C j) + (h : ∀ j, PredualTendsto e (fun i => a i j) l (b j)) : + PredualTendsto e (fun i => ∑' j, a i j) l (∑' j, b j) := by + have hCb (j : J) : ‖b j‖ ≤ C j := + predual_norm_le e (C j) (by obtain ⟨i,_⟩ := (Eventually.of_forall (fun _i : I => True.intro) : ∀ᶠ _i in l, True).exists; exact (norm_nonneg (a i j)).trans (ha i j)) + (Eventually.of_forall fun i => ha i j) (h j) + have hsa (i : I) : Summable (a i) := hC.of_norm_bounded (ha i) + have hsb : Summable b := hC.of_norm_bounded hCb + intro z + let ev : M →L⋆[ℂ] ℂ := ((ContinuousLinearMap.apply ℂ ℂ) z).comp + e.symm.toContinuousLinearEquiv.toContinuousLinearMap + change Tendsto (fun i => ev (∑' j, a i j)) l (𝓝 (ev (∑' j, b j))) + simp_rw [ev.map_tsum (hsa _),ev.map_tsum hsb] + apply tendsto_tsum_of_dominated_convergence (hC.mul_right ‖z‖) (fun j => h j z) + exact Eventually.of_forall fun i j => calc + ‖ev (a i j)‖ ≤ ‖e.symm (a i j)‖ * ‖z‖ := (e.symm (a i j)).le_opNorm z + _ ≤ C j * ‖z‖ := mul_le_mul_of_nonneg_right (by simpa using ha i j) (norm_nonneg _) + + + +def HasPreadjoint (L : M →L[ℂ] M) : Prop := + ∀ z : X, ∃ z' : X, ∀ a : M, e.symm (L a) z = e.symm a z' + +lemma HasPreadjoint.tendsto {L : M →L[ℂ] M} (hL : HasPreadjoint e L) + {a : I → M} {l : Filter I} {b : M} (h : PredualTendsto e a l b) : + PredualTendsto e (fun i => L (a i)) l (L b) := by + intro z + obtain ⟨z',hz'⟩ := hL z + simpa only [hz'] using h z' + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CochainTransportFaces.lean b/lean/OAI/Analysis/BoundedHochschild/CochainTransportFaces.lean new file mode 100644 index 0000000000000000000000000000000000000000..e72b45f2a3976ee7a9fd3b92df7277b17b502dbb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CochainTransportFaces.lean @@ -0,0 +1,60 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainAverages + +namespace OAI + +/-! Interaction of independent unitary transports with Hochschild faces. +Deleting a boundary unitary gives the transport of the corresponding face. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma cochainUnitaryTransport_leftCoboundary {n : ℕ} + (u : Fin (n + 2) → unitary M) (f : Cochain M n) : + cochainUnitaryTransport u (leftCoboundary f) = + leftCoboundary (cochainUnitaryTransport (Fin.tail u) f) := by + ext x + have ht : (fun i : Fin n => cochainUnitaryTuple u x i.succ) = + cochainUnitaryTuple (Fin.tail u) (Fin.tail x) := by + ext i + simp only [cochainUnitaryTuple, Fin.tail, Fin.castSucc_succ] + simp only [cochainUnitaryTransport_apply, leftCoboundary_apply] + rw [ht] + change star (u 0 : M) * + (((u 0 : M) * x 0 * star (u (0 : Fin (n + 1)).succ : M)) * + f (cochainUnitaryTuple (Fin.tail u) (Fin.tail x))) * (u (Fin.last (n + 1)) : M) = + x 0 * (star (u (0 : Fin (n + 1)).succ : M) * + f (cochainUnitaryTuple (Fin.tail u) (Fin.tail x)) * (u (Fin.last (n + 1)) : M)) + calc + _ = (star (u 0 : M) * (u 0 : M)) * (x 0 * + (star (u (0 : Fin (n + 1)).succ : M) * + f (cochainUnitaryTuple (Fin.tail u) (Fin.tail x)) * (u (Fin.last (n + 1)) : M))) := by + simp only [mul_assoc] + _ = _ := by rw [Unitary.star_mul_self_of_mem (u 0).property, one_mul] + +lemma cochainUnitaryTransport_rightCoboundary {n : ℕ} + (u : Fin (n + 2) → unitary M) (f : Cochain M n) : + cochainUnitaryTransport u (rightCoboundary f) = + rightCoboundary (cochainUnitaryTransport (fun i => u i.castSucc) f) := by + ext x + have ht : (fun i : Fin n => cochainUnitaryTuple u x i.castSucc) = + cochainUnitaryTuple (fun i => u i.castSucc) (fun i => x i.castSucc) := by + ext i + simp only [cochainUnitaryTuple, Fin.castSucc_succ] + simp only [cochainUnitaryTransport_apply, rightCoboundary_apply] + rw [ht] + change star (u 0 : M) * + (f (cochainUnitaryTuple (fun i => u i.castSucc) (fun i => x i.castSucc)) * + ((u (Fin.last n).castSucc : M) * x (Fin.last n) * star (u (Fin.last (n + 1)) : M))) * + (u (Fin.last (n + 1)) : M) = + (star (u 0 : M) * f (cochainUnitaryTuple (fun i => u i.castSucc) (fun i => x i.castSucc)) * + (u (Fin.last n).castSucc : M)) * x (Fin.last n) + simp only [mul_assoc, Unitary.star_mul_self_of_mem (u (Fin.last (n + 1))).property, mul_one] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CochainTransportMiddle.lean b/lean/OAI/Analysis/BoundedHochschild/CochainTransportMiddle.lean new file mode 100644 index 0000000000000000000000000000000000000000..da5bc0fc1c87ccbef29a1776b24db6f67ad6c9b3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CochainTransportMiddle.lean @@ -0,0 +1,65 @@ +import OAI.Analysis.BoundedHochschild.CochainTransportFaces + +namespace OAI + +/-! Interior Hochschild faces delete the unitary at the multiplied +boundary. Its two adjacent factors cancel exactly. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma cochainUnitaryTuple_merge {n : ℕ} (u : Fin (n + 3) → unitary M) + (x : Fin (n + 2) → M) (k : Fin (n + 1)) : + mergeInputs (cochainUnitaryTuple u x) k = + cochainUnitaryTuple (k.castSucc.succ.removeNth u) (mergeInputs x k) := by + let p : Fin (n + 3) := k.castSucc.succ + have hbefore (j : Fin (n + 2)) (hj : j.val < p.val) : p.removeNth u j = u j.castSucc := by + rw [Fin.removeNth, Fin.succAbove_of_castSucc_lt _ _ hj] + have hafter (j : Fin (n + 2)) (hj : p.val ≤ j.val) : p.removeNth u j = u j.succ := by + rw [Fin.removeNth, Fin.succAbove_of_le_castSucc _ _ hj] + change mergeInputs (cochainUnitaryTuple u x) k = cochainUnitaryTuple (p.removeNth u) (mergeInputs x k) + ext i + by_cases hik : i < k + · have hi : i.val < k.val := hik + simp only [mergeInputs, ite_eq_left hik, cochainUnitaryTuple] + rw [hbefore i.castSucc (by dsimp [p]; omega), + hbefore i.succ (by dsimp [p]; omega)] + rfl + · by_cases hie : i = k + · subst i + simp only [mergeInputs, lt_self_iff_false, ite_false, ite_true, cochainUnitaryTuple] + rw [hbefore k.castSucc (by dsimp [p]; simp), hafter k.succ (by dsimp [p]; simp)] + simp only [Fin.castSucc_succ, mul_assoc] + rw [← mul_assoc (star (u k.castSucc.succ : M)) (u k.castSucc.succ : M), + Unitary.star_mul_self_of_mem (u k.castSucc.succ).property, one_mul] + · have hi : k.val < i.val := by + have hne : i.val ≠ k.val := fun h => hie (Fin.ext h) + omega + simp only [mergeInputs, ite_eq_right hik, ite_eq_right hie, cochainUnitaryTuple] + rw [hafter i.castSucc (by dsimp [p]; omega), + hafter i.succ (by dsimp [p]; omega)] + rfl + +lemma cochainUnitaryTransport_middleCoboundary {n : ℕ} + (u : Fin (n + 3) → unitary M) (f : Cochain M (n + 1)) (k : Fin (n + 1)) : + cochainUnitaryTransport u (middleCoboundary f k) = + middleCoboundary (cochainUnitaryTransport (k.castSucc.succ.removeNth u) f) k := by + ext x + simp only [cochainUnitaryTransport_apply, middleCoboundary_apply, cochainUnitaryTuple_merge] + have hzero : k.castSucc.succ ≠ (0 : Fin (n + 3)) := Fin.succ_ne_zero _ + have hlast : k.castSucc.succ ≠ Fin.last (n + 2) := by + intro h + have hv := congrArg Fin.val h + simp only [Fin.val_succ, Fin.val_castSucc, Fin.val_last] at hv + omega + simp only [Fin.removeNth, Fin.succAbove_ne_zero_zero hzero, + Fin.succAbove_ne_last_last hlast] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Cochains.lean b/lean/OAI/Analysis/BoundedHochschild/Cochains.lean new file mode 100644 index 0000000000000000000000000000000000000000..3c83de6ff4f6849a2d840ba0eb5f437282d81997 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Cochains.lean @@ -0,0 +1,251 @@ +import Mathlib + +namespace OAI + +/-! Bounded Hochschild cochains, last-input translation and averaging. -/ + +noncomputable section + + +namespace BoundedHochschild + +abbrev Cochain (M : Type*) [NormedAddCommGroup M] [NormedSpace ℂ M] (n : ℕ) := + ContinuousMultilinearMap ℂ (fun _ : Fin n => M) M + + +def mergeInputs {M : Type*} [Mul M] {n : ℕ} + (v : Fin (n + 1) → M) (j : Fin n) : Fin n → M := + fun i => if i < j then v i.castSucc + else if i = j then v i.castSucc * v i.succ else v i.succ + + + +noncomputable def differentialValue {M : Type*} [NormedRing M] [NormedAlgebra ℂ M] + {n : ℕ} (f : Cochain M n) (v : Fin (n + 1) → M) : M := + v 0 * f (fun i => v i.succ) + + ∑ j : Fin n, ((-1 : ℂ) ^ (j.val + 1)) • f (mergeInputs v j) + + ((-1 : ℂ) ^ (n + 1)) • (f (fun i => v i.castSucc) * v (Fin.last n)) + +section AlgebraicAveraging +variable {M : Type*} [NormedRing M] [NormedAlgebra ℂ M] + +@[simp] theorem differentialValue_add {n : ℕ} (f g : Cochain M n) + (v : Fin (n + 1) → M) : + differentialValue (f + g) v = differentialValue f v + differentialValue g v := by + simp only [differentialValue, add_apply, mul_add, add_mul, + smul_add, Finset.sum_add_distrib] + abel + +@[simp] theorem differentialValue_smul {n : ℕ} (c : ℂ) (f : Cochain M n) + (v : Fin (n + 1) → M) : + differentialValue (c • f) v = c • differentialValue f v := by + simp only [differentialValue, smul_apply, smul_mul_assoc, + mul_smul_comm, smul_add, Finset.smul_sum, smul_smul] + congr 2 + · apply Finset.sum_congr rfl + intro j _ + rw [mul_comm c] + · rw [mul_comm c] + + +noncomputable def insertLast {n : ℕ} (f : Cochain M (n + 1)) (u : M) : Cochain M n := + ((ContinuousLinearMap.apply ℂ M) u).compContinuousMultilinearMap f.curryRight + +@[simp] theorem insertLast_apply {n : ℕ} (f : Cochain M (n + 1)) (u : M) + (v : Fin n → M) : insertLast f u v = f (Fin.snoc v u) := rfl + +theorem norm_insertLast_le {n : ℕ} (f : Cochain M (n + 1)) (u : M) : + ‖insertLast f u‖ ≤ ‖f‖ * ‖u‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (by positivity) + intro v + simpa [mul_assoc, mul_left_comm, mul_comm] using f.norm_map_snoc_le v u + +end AlgebraicAveraging + +section TupleIdentities +variable {M : Type*} + +theorem snoc_succ_tuple {n : ℕ} (v : Fin (n + 1) → M) (u : M) : + (fun i : Fin (n + 1) => (Fin.snoc v u : Fin (n + 2) → M) i.succ) = + Fin.snoc (fun i : Fin n => v i.succ) u := by + funext i + refine Fin.lastCases ?_ (fun j => ?_) i + · simp + · simp only [← Fin.castSucc_succ, Fin.snoc_castSucc] + +theorem snoc_castSucc_tuple {n : ℕ} (v : Fin n → M) (u : M) : + (fun i : Fin n => (Fin.snoc v u : Fin (n + 1) → M) i.castSucc) = v := by + funext i + exact Fin.snoc_castSucc (α := fun _ => M) u v i + +@[simp] theorem mergeInputs_snoc_castSucc [Mul M] {n : ℕ} (v : Fin (n + 1) → M) + (u : M) (j : Fin n) : + mergeInputs (Fin.snoc v u) j.castSucc = Fin.snoc (mergeInputs v j) u := by + funext i + refine Fin.lastCases ?_ (fun k => ?_) i + · have hlt : ¬ Fin.last n < j.castSucc := by + simp only [Fin.lt_def, Fin.val_last, Fin.val_castSucc] + omega + have heq : Fin.last n ≠ j.castSucc := by + intro h + have hv := congrArg Fin.val h + simp only [Fin.val_last, Fin.val_castSucc] at hv + omega + simp [mergeInputs, hlt, heq] + · simp [mergeInputs, ← Fin.castSucc_succ] + +@[simp] theorem mergeInputs_snoc_last [Mul M] {n : ℕ} (v : Fin (n + 1) → M) (u : M) : + mergeInputs (Fin.snoc v u) (Fin.last n) = + Fin.snoc (fun i : Fin n => v i.castSucc) (v (Fin.last n) * u) := by + funext i + refine Fin.lastCases ?_ (fun j => ?_) i + · simp [mergeInputs] + · simp [mergeInputs] + +end TupleIdentities + +section CocycleIdentity +variable {M : Type*} [NormedRing M] [NormedAlgebra ℂ M] + + +theorem differentialValue_snoc {n : ℕ} (f : Cochain M (n + 1)) + (v : Fin (n + 1) → M) (u : M) : + differentialValue f (Fin.snoc v u) = + v 0 * f (Fin.snoc (fun i : Fin n => v i.succ) u) + + (∑ j : Fin n, ((-1 : ℂ) ^ (j.val + 1)) • f (Fin.snoc (mergeInputs v j) u)) + + ((-1 : ℂ) ^ (n + 1)) • + f (Fin.snoc (fun i : Fin n => v i.castSucc) (v (Fin.last n) * u)) + + ((-1 : ℂ) ^ (n + 2)) • (f v * u) := by + rw [differentialValue, snoc_succ_tuple, snoc_castSucc_tuple, Fin.sum_univ_castSucc] + simp only [mergeInputs_snoc_castSucc, Fin.val_castSucc, mergeInputs_snoc_last, + Fin.val_last, Fin.snoc_last] + have hzero : (Fin.snoc v u : Fin (n + 2) → M) 0 = v 0 := by + exact Fin.snoc_castSucc (α := fun _ => M) u v 0 + rw [hzero] + abel + + +noncomputable def rightMultiply {n : ℕ} (f : Cochain M n) (u : M) : Cochain M n := + ((ContinuousLinearMap.mul ℂ M).flip u).compContinuousMultilinearMap f + +@[simp] theorem rightMultiply_apply {n : ℕ} (f : Cochain M n) (u : M) + (v : Fin n → M) : rightMultiply f u v = f v * u := rfl + + +noncomputable def lastHomotopy {n : ℕ} (f : Cochain M (n + 1)) (u v : M) : Cochain M n := + rightMultiply (insertLast f u) v + +@[simp] theorem lastHomotopy_apply {n : ℕ} (f : Cochain M (n + 1)) (u v : M) + (x : Fin n → M) : lastHomotopy f u v x = f (Fin.snoc x u) * v := rfl + +theorem norm_rightMultiply_le {n : ℕ} (f : Cochain M n) (u : M) : + ‖rightMultiply f u‖ ≤ ‖f‖ * ‖u‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (by positivity) + intro v + calc + ‖rightMultiply f u v‖ ≤ ‖f v‖ * ‖u‖ := norm_mul_le _ _ + _ ≤ (‖f‖ * ∏ i, ‖v i‖) * ‖u‖ := + mul_le_mul_of_nonneg_right (f.le_opNorm v) (norm_nonneg _) + _ = (‖f‖ * ‖u‖) * ∏ i, ‖v i‖ := by ring + +theorem norm_lastHomotopy_le {n : ℕ} (f : Cochain M (n + 1)) (u v : M) : + ‖lastHomotopy f u v‖ ≤ ‖f‖ * ‖u‖ * ‖v‖ := by + exact (norm_rightMultiply_le _ _).trans + (mul_le_mul_of_nonneg_right (norm_insertLast_le _ _) (norm_nonneg _)) + + + +theorem lastHomotopy_cocycle {n : ℕ} (f : Cochain M (n + 1)) + (hf : ∀ x : Fin (n + 2) → M, differentialValue f x = 0) + (u u' : M) (hu : u * u' = 1) (x : Fin (n + 1) → M) : + differentialValue (lastHomotopy f u u') x = + ((-1 : ℂ) ^ (n + 1)) • + (f x - f (Fin.snoc (fun i : Fin n => x i.castSucc) (x (Fin.last n) * u)) * u' + + (lastHomotopy f u u' (fun i : Fin n => x i.castSucc)) * x (Fin.last n)) := by + have hz := congrArg (fun y : M => y * u') (hf (Fin.snoc x u)) + rw [differentialValue_snoc] at hz + simp only [add_mul, Finset.sum_mul, smul_mul_assoc, mul_assoc, hu, mul_one, + zero_mul] at hz + have hp : (-1 : ℂ) ^ (n + 2) = -((-1 : ℂ) ^ (n + 1)) := by + rw [show n + 2 = (n + 1) + 1 by omega, pow_succ] + ring + rw [hp, neg_smul] at hz + simp only [differentialValue, lastHomotopy_apply, mul_assoc, smul_add, smul_sub] + apply eq_of_sub_eq_zero + rw [sub_eq_add_neg] + have hz' := hz + abel_nf at hz' ⊢ + simpa only [add_assoc, add_left_comm, add_comm] using hz' + +end CocycleIdentity + +section UnitaryAveraging +variable {M : Type*} [CStarAlgebra M] + +noncomputable def translateLast {n : ℕ} (f : Cochain M (n + 1)) (u : unitary M) : + Cochain M (n + 1) := + rightMultiply + (f.compContinuousLinearMap (fun i : Fin (n + 1) => + if i = Fin.last n then (ContinuousLinearMap.mul ℂ M).flip (u : M) + else ContinuousLinearMap.id ℂ M)) (star (u : M)) + +@[simp] theorem translateLast_apply {n : ℕ} (f : Cochain M (n + 1)) (u : unitary M) + (x : Fin (n + 1) → M) : + translateLast f u x = + f (Fin.snoc (fun i : Fin n => x i.castSucc) (x (Fin.last n) * u)) * star (u : M) := by + change f (fun i => (if i = Fin.last n then (ContinuousLinearMap.mul ℂ M).flip (u : M) + else ContinuousLinearMap.id ℂ M) (x i)) * star (u : M) = _ + congr 2 + funext i + refine Fin.lastCases ?_ (fun j => ?_) i <;> simp + +theorem norm_translateLast_le {n : ℕ} (f : Cochain M (n + 1)) (u : unitary M) : + ‖translateLast f u‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + rw [translateLast_apply] + have hnorm (z : M) : ‖z * star (u : M)‖ = ‖z‖ := + CStarRing.norm_mul_coe_unitary z (star u) + rw [hnorm] + calc + _ ≤ ‖f‖ * (∏ i : Fin n, ‖x i.castSucc‖) * ‖x (Fin.last n) * (u : M)‖ := + f.norm_map_snoc_le _ _ + _ = ‖f‖ * ∏ i, ‖x i‖ := by + rw [CStarRing.norm_mul_coe_unitary, Fin.prod_univ_castSucc, mul_assoc] + +@[simp] theorem translateLast_add {n : ℕ} (f g : Cochain M (n + 1)) (u : unitary M) : + translateLast (f + g) u = translateLast f u + translateLast g u := by + ext x + simp [add_mul] + +@[simp] theorem translateLast_smul {n : ℕ} (c : ℂ) (f : Cochain M (n + 1)) (u : unitary M) : + translateLast (c • f) u = c • translateLast f u := by + ext x + simp + + +noncomputable def averageLast {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (f : Cochain M (n + 1)) : Cochain M (n + 1) := + ∑' j, (p j : ℂ) • translateLast f (u j) + +theorem summable_averageLast {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ j, 0 ≤ p j) (hs : Summable p) (f : Cochain M (n + 1)) : + Summable (fun j => (p j : ℂ) • translateLast f (u j)) := by + refine (hs.mul_right ‖f‖).of_norm_bounded (fun j => ?_) + rw [norm_smul, Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg (hp j)] + exact mul_le_mul_of_nonneg_left (norm_translateLast_le _ _) (hp j) + +theorem norm_averageLast_le {n : ℕ} (p : ℕ → ℝ) (u : ℕ → unitary M) + (hp : ∀ j, 0 ≤ p j) (hs : HasSum p 1) (f : Cochain M (n + 1)) : + ‖averageLast p u f‖ ≤ ‖f‖ := by + have hbound (j : ℕ) : ‖(p j : ℂ) • translateLast f (u j)‖ ≤ p j * ‖f‖ := by + rw [norm_smul, Complex.norm_real, Real.norm_eq_abs, abs_of_nonneg (hp j)] + exact mul_le_mul_of_nonneg_left (norm_translateLast_le _ _) (hp j) + simpa [averageLast] using tsum_of_norm_bounded (hs.mul_right ‖f‖) hbound + +end UnitaryAveraging + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CocycleNormalParts.lean b/lean/OAI/Analysis/BoundedHochschild/CocycleNormalParts.lean new file mode 100644 index 0000000000000000000000000000000000000000..f66ed7a8dab0c920cc74a753646e18c022f02c1e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CocycleNormalParts.lean @@ -0,0 +1,353 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.BarDifferential +import OAI.Analysis.BoundedHochschild.NormalOperators + +namespace OAI + +/-! Normal corrections and first- and last-input normal cocycles. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +namespace BoundedHochschild +open HochschildNormalPart +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + +def normalLast {n : ℕ} (f : Cochain M (n+1)) : Cochain M (n+1) := + ((operatorNormalPart e).compContinuousMultilinearMap f.curryRight).uncurryRight + +@[simp] lemma normalLast_apply {n : ℕ} (f : Cochain M (n+1)) (v : Fin (n+1) → M) : + normalLast e f v=operatorNormalPart e (f.curryRight (fun i => v i.castSucc)) (v (Fin.last n)) := rfl + +@[simp] lemma normalLast_snoc {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) (a : M) : + normalLast e f (Fin.snoc v a)=operatorNormalPart e (f.curryRight v) a := by + simp + +lemma normalLast_normal {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) : + HasPreadjoint e ((normalLast e f).curryRight v) := by + have h : (normalLast e f).curryRight v=operatorNormalPart e (f.curryRight v) := by + ext a + simp only [ContinuousMultilinearMap.curryRight_apply,normalLast_snoc] + rw [h] + exact operatorNormalPart_normal e (f.curryRight v) + + + +lemma normalLast_identity {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ v,differentialValue f v=0) (v : Fin (n+1) → M) (a : M) : + v 0*normalLast e f (Fin.snoc (fun i : Fin n => v i.succ) a)+ + (∑ j : Fin n,((-1:ℂ)^(j.val+1)) • normalLast e f (Fin.snoc (mergeInputs v j) a))+ + ((-1:ℂ)^(n+1)) • normalLast e f (Fin.snoc (fun i : Fin n => v i.castSucc) (v (Fin.last n)*a))+ + ((-1:ℂ)^(n+2)) • (f v*a)=0 := by + let L := ContinuousLinearMap.mul ℂ M + have h : (L (v 0)).comp (f.curryRight (fun i : Fin n => v i.succ))+ + (∑ j : Fin n,((-1:ℂ)^(j.val+1)) • f.curryRight (mergeInputs v j))+ + ((-1:ℂ)^(n+1)) • (f.curryRight (fun i : Fin n => v i.castSucc)).comp (L (v (Fin.last n)))+ + ((-1:ℂ)^(n+2)) • L (f v)=0 := by + ext b + have h := hf (Fin.snoc v b) + rw [differentialValue_snoc] at h + simpa only [L,add_apply,sum_apply,smul_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.mul_apply',ContinuousMultilinearMap.curryRight_apply,zero_apply] using h + have h' := congrArg (fun T : M →L[ℂ] M => operatorNormalPart e T a) h + dsimp only [L] at h' + simp only [map_add,map_sum,map_smul,map_zero,zero_apply, + operatorNormalPart_comp_normal e _ _ ((HochschildSakai.abstract_multiplication_normal e).1 (v 0)), + operatorNormalPart_comp_left, + operatorNormalPart_fixes e _ ((HochschildSakai.abstract_multiplication_normal e).1 (f v)), + add_apply,sum_apply,smul_apply,ContinuousLinearMap.comp_apply] at h' + simpa only [normalLast_snoc,ContinuousLinearMap.mul_apply'] using h' + + +def reducedNormalCocycle {n : ℕ} (f : Cochain M (n+1)) : Cochain M (n+1) := + normalLast e f-rightCoboundary (insertLast (normalLast e f) 1) + +def normalCorrection {n : ℕ} (f : Cochain M (n+1)) : Cochain M n := + ((-1:ℂ)^(n+1)) • insertLast (normalLast e f) 1 + +lemma sign_square (k : ℕ) : (-1:ℂ)^k*(-1:ℂ)^k=1 := by + rw [← mul_pow] + simp + +lemma sign_succ (k : ℕ) : (-1:ℂ)^(k+1) = -((-1:ℂ)^k) := by + rw [pow_succ] + ring + +lemma normal_correction_identity {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ v,differentialValue f v=0) (v : Fin (n+1) → M) : + f v=reducedNormalCocycle e f v+differentialValue (normalCorrection e f) v := by + let F := normalLast e f + let h := insertLast F 1 + let s := (-1:ℂ)^(n+1) + have he := normalLast_identity e f hf v 1 + have hs : (-1:ℂ)^(n+2) = -s := sign_succ (n+1) + have hv : Fin.snoc (fun i : Fin n => v i.castSucc) (v (Fin.last n))=v := Fin.snoc_init_self v + simp only [mul_one,hv,hs] at he + have hA : differentialValue h v+s • (F v-rightCoboundary h v)-s • f v=0 := by + change v 0*F (Fin.snoc (fun i : Fin n => v i.succ) 1)+ + (∑ j : Fin n,((-1:ℂ)^(j.val+1)) • F (Fin.snoc (mergeInputs v j) 1))+ + s • F v+(-s) • f v=0 at he + dsimp only [h] + simp only [differentialValue,insertLast_apply,rightCoboundary_apply,smul_sub,neg_smul] at * + linear_combination (norm := module) he + have hB : differentialValue h v+s • (F v-rightCoboundary h v)=s • f v := sub_eq_zero.mp hA + have hC := congrArg (fun b : M => s • b) hB + simp only [smul_add,smul_smul,show s*s=1 from sign_square (n+1),one_smul] at hC + rw [normalCorrection,differentialValue_smul] + change f v=(F v-rightCoboundary h v)+s • differentialValue h v + exact hC.symm.trans (add_comm _ _) + +lemma reducedNormalCocycle_normal {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) : + HasPreadjoint e ((reducedNormalCocycle e f).curryRight v) := by + intro z + obtain ⟨z₁,hz₁⟩ := normalLast_normal e f v z + obtain ⟨z₂,hz₂⟩ := (HochschildSakai.abstract_multiplication_normal e).1 + (insertLast (normalLast e f) 1 v) z + refine ⟨z₁-z₂,?_⟩ + intro a + simp only [reducedNormalCocycle,ContinuousMultilinearMap.curryRight_apply, + sub_apply,rightCoboundary_apply,Fin.snoc_castSucc,Fin.snoc_last] + change e.symm (normalLast e f (Fin.snoc v a) - insertLast (normalLast e f) 1 v*a) z = + e.symm a (z₁-z₂) + rw [map_sub,sub_apply,map_sub] + exact congrArg₂ (·-·) (hz₁ a) (hz₂ a) + +lemma differentialValue_sub {n : ℕ} (f g : Cochain M n) (v : Fin (n+1) → M) : + differentialValue (f-g) v=differentialValue f v-differentialValue g v := by + rw [sub_eq_add_neg,show -g=(-1:ℂ) • g by simp,differentialValue_add,differentialValue_smul] + simp [sub_eq_add_neg] + +lemma rightCoboundary_differential {n : ℕ} (h : Cochain M n) + (v : Fin (n+1) → M) (a : M) : + differentialValue (rightCoboundary h) (Fin.snoc v a)= + (differentialValue h v-((-1:ℂ)^(n+1)) • rightCoboundary h v)*a := by + rw [differentialValue_snoc,sign_succ (n+1)] + simp only [rightCoboundary_apply,Fin.snoc_castSucc,Fin.snoc_last,differentialValue, + add_mul,sub_mul,Finset.sum_mul,smul_mul_assoc,mul_assoc,neg_smul] + abel + +lemma reducedNormalCocycle_cocycle {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ v,differentialValue f v=0) (x : Fin (n+2) → M) : + differentialValue (reducedNormalCocycle e f) x=0 := by + let v : Fin (n+1) → M := fun i => x i.castSucc + let a := x (Fin.last (n+1)) + have hx : x=Fin.snoc v a := (Fin.snoc_init_self x).symm + rw [hx,reducedNormalCocycle,differentialValue_sub,rightCoboundary_differential,differentialValue_snoc] + have h := normalLast_identity e f hf v a + have hv := normal_correction_identity e f hf v + rw [reducedNormalCocycle,sub_apply,normalCorrection,differentialValue_smul] at hv + have hs : (-1:ℂ)^(n+2) = -((-1:ℂ)^(n+1)) := sign_succ (n+1) + rw [hs] at h ⊢ + rw [hv] at h + simp only [add_mul,sub_mul,smul_mul_assoc,smul_add,smul_sub,neg_smul,smul_smul, + neg_mul,sign_square,one_smul] at h ⊢ + linear_combination (norm := module) h + +lemma normalLast_norm {n : ℕ} (f : Cochain M (n+1)) : ‖normalLast e f‖≤4*‖f‖ := by + have hN : ‖operatorNormalPart e‖≤4 := + LinearMap.mkContinuous_norm_le _ (by norm_num) (normalOperator_norm e) + rw [normalLast,ContinuousMultilinearMap.uncurryRight_norm] + calc + _ ≤ ‖operatorNormalPart e‖*‖f.curryRight‖ := + ContinuousLinearMap.norm_compContinuousMultilinearMap_le _ _ + _ ≤ 4*‖f‖ := by rw [ContinuousMultilinearMap.curryRight_norm]; gcongr + +lemma rightCoboundary_norm {n : ℕ} (f : Cochain M n) : ‖rightCoboundary f‖≤‖f‖ := by + rw [rightCoboundary,ContinuousMultilinearMap.uncurryRight_norm] + calc + _ ≤ ‖ContinuousLinearMap.mul ℂ M‖*‖f‖ := + ContinuousLinearMap.norm_compContinuousMultilinearMap_le _ _ + _ ≤ 1*‖f‖ := mul_le_mul_of_nonneg_right (ContinuousLinearMap.opNorm_mul_le ℂ M) (norm_nonneg _) + _ = _ := one_mul _ + +lemma insertLast_one_norm {n : ℕ} (f : Cochain M (n+1)) : ‖insertLast f 1‖≤‖f‖ := by + have h : ‖(1:M)‖≤1 := by + rcases subsingleton_or_nontrivial M with h|h + · simp [Subsingleton.elim (1:M) 0] + · simp + exact (norm_insertLast_le f 1).trans ((mul_le_mul_of_nonneg_left h (norm_nonneg _)).trans_eq (mul_one _)) + +lemma reducedNormalCocycle_norm {n : ℕ} (f : Cochain M (n+1)) : + ‖reducedNormalCocycle e f‖≤8*‖f‖ := by + have h := (rightCoboundary_norm (insertLast (normalLast e f) 1)).trans (insertLast_one_norm _) + have hN := normalLast_norm e f + exact (norm_sub_le _ _).trans (by linarith) + +lemma normalCorrection_norm {n : ℕ} (f : Cochain M (n+1)) : ‖normalCorrection e f‖≤4*‖f‖ := by + simpa only [normalCorrection,norm_smul,norm_pow,norm_neg,norm_one,one_pow,one_mul] + using (insertLast_one_norm (normalLast e f)).trans (normalLast_norm e f) + + + +theorem ordinary_to_last_normal {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ v,differentialValue f v=0) : + ∃ F : Cochain M (n+1), ∃ h : Cochain M n, + (∀ v,differentialValue F v=0) ∧ + (∀ v : Fin n → M,HasPreadjoint e (F.curryRight v)) ∧ + ∀ v,f v=F v+differentialValue h v := + ⟨reducedNormalCocycle e f,normalCorrection e f,reducedNormalCocycle_cocycle e f hf, + reducedNormalCocycle_normal e f,normal_correction_identity e f hf⟩ + +end BoundedHochschild + + + +namespace BoundedHochschild +open HochschildNormalPart +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +def reverseArguments {n : ℕ} (f : Cochain M n) : Cochain M n := + ContinuousMultilinearMap.domDomCongr Fin.revPerm f + +lemma reverseArguments_apply {n : ℕ} (f : Cochain M n) (v : Fin n → M) : + reverseArguments f v=f (v ∘ Fin.rev) := rfl + +@[simp] lemma reverseArguments_norm {n : ℕ} (f : Cochain M n) : ‖reverseArguments f‖=‖f‖ := + ContinuousMultilinearMap.norm_domDomCongr ℂ M M _ _ + +def firstSliceN {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) : M →L[ℂ] M := + (reverseArguments f).curryRight (v ∘ Fin.rev) + +@[simp] lemma firstSliceN_apply {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) (a : M) : + firstSliceN f v a=f (Fin.cons a v) := by + change reverseArguments f (Fin.snoc (v ∘ Fin.rev) a)=_ + rw [reverseArguments_apply,Fin.snoc_comp_rev] + have hv : (v ∘ Fin.rev) ∘ Fin.rev=v := by + ext i + simp + rw [hv] + + +def normalFirst {n : ℕ} (f : Cochain M (n+1)) : Cochain M (n+1) := + reverseArguments (normalLast e (reverseArguments f)) + +@[simp] lemma normalFirst_cons {n : ℕ} (f : Cochain M (n+1)) (a : M) (v : Fin n → M) : + normalFirst e f (Fin.cons a v)=operatorNormalPart e (firstSliceN f v) a := by + rw [normalFirst,reverseArguments_apply,Fin.cons_comp_rev,normalLast_snoc] + rfl + +lemma normalFirst_norm {n : ℕ} (f : Cochain M (n+1)) : ‖normalFirst e f‖≤4*‖f‖ := by + simpa only [normalFirst,reverseArguments_norm] using normalLast_norm e (reverseArguments f) + +lemma normalFirst_normal {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) : + HasPreadjoint e (firstSliceN (normalFirst e f) v) := by + have he : firstSliceN (normalFirst e f) v=operatorNormalPart e (firstSliceN f v) := by + ext a + simp + rw [he] + exact operatorNormalPart_normal e _ + +lemma differentialValue_cons {n : ℕ} (f : Cochain M (n+1)) + (a : M) (v : Fin (n+1) → M) : + differentialValue f (Fin.cons a v)=a*f v-f (Fin.cons (a*v 0) (fun i : Fin n => v i.succ))+ + (∑ j : Fin n,((-1:ℂ)^(j.val+2)) • f (Fin.cons a (mergeInputs v j)))+ + ((-1:ℂ)^(n+2)) • (f (Fin.cons a (fun i : Fin n => v i.castSucc))*v (Fin.last n)) := by + have hinit : (fun i : Fin (n+1) => (Fin.cons a v : Fin (n+2) → M) i.castSucc)= + Fin.cons a (fun i : Fin n => v i.castSucc) := by + ext i; refine Fin.cases ?_ (fun j => ?_) i + · simp + · simp only [Fin.castSucc_succ,Fin.cons_succ] + have hlast : (Fin.cons a v : Fin (n+2) → M) (Fin.last (n+1))=v (Fin.last n) := by + change (Fin.cons a v : Fin (n+2) → M) (Fin.last n).succ=_ + simp + simp only [differentialValue,Fin.cons_zero,Fin.cons_succ,hinit,hlast, + Fin.sum_univ_succ,mergeInputs_cons_zero,mergeInputs_cons_succ, + Fin.val_zero,zero_add,pow_one,neg_smul,one_smul,Fin.val_succ,Nat.add_assoc] + abel + +lemma normalFirst_identity {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ z,differentialValue f z=0) (a : M) (v : Fin (n+1) → M) : + a*f v-normalFirst e f (Fin.cons (a*v 0) (fun i : Fin n => v i.succ))+ + (∑ j : Fin n,((-1:ℂ)^(j.val+2)) • normalFirst e f (Fin.cons a (mergeInputs v j)))+ + ((-1:ℂ)^(n+2)) • (normalFirst e f (Fin.cons a (fun i : Fin n => v i.castSucc))*v (Fin.last n))=0 := by + let R := (ContinuousLinearMap.mul ℂ M).flip + have hop : R (f v)-(firstSliceN f (fun i : Fin n => v i.succ)).comp (R (v 0))+ + (∑ j : Fin n,((-1:ℂ)^(j.val+2)) • firstSliceN f (mergeInputs v j))+ + ((-1:ℂ)^(n+2)) • (R (v (Fin.last n))).comp (firstSliceN f (fun i : Fin n => v i.castSucc))=0 := by + ext b + simpa only [R,sub_apply,add_apply,sum_apply,smul_apply,ContinuousLinearMap.comp_apply, + ContinuousLinearMap.flip_apply,ContinuousLinearMap.mul_apply',firstSliceN_apply,zero_apply, + differentialValue_cons] using hf (Fin.cons b v) + have h := congrArg (fun T : M →L[ℂ] M => operatorNormalPart e T a) hop + dsimp only [R] at h + simp only [map_sub,map_add,map_sum,map_smul,map_zero,sub_apply,add_apply,sum_apply,smul_apply,zero_apply, + operatorNormalPart_fixes e _ ((HochschildSakai.abstract_multiplication_normal e).2 _), + operatorNormalPart_comp_right,operatorNormalPart_comp_normal e _ _ + ((HochschildSakai.abstract_multiplication_normal e).2 _), + ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.mul_apply',← normalFirst_cons] at h + exact h + + +def firstNormalCorrectionN {n : ℕ} (f : Cochain M (n+1)) : Cochain M n := + (normalFirst e f).curryLeft 1 + +def firstNormalRemainderN {n : ℕ} (f : Cochain M (n+1)) : Cochain M (n+1) := + f-differential (firstNormalCorrectionN e f) + +@[simp] lemma firstNormalCorrectionN_apply {n : ℕ} (f : Cochain M (n+1)) (v : Fin n → M) : + firstNormalCorrectionN e f v=normalFirst e f (Fin.cons 1 v) := rfl + +lemma firstNormalRemainderN_apply {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ z,differentialValue f z=0) (v : Fin (n+1) → M) : + firstNormalRemainderN e f v=normalFirst e f v- + v 0*normalFirst e f (Fin.cons 1 (fun i : Fin n => v i.succ)) := by + have h := normalFirst_identity e f hf 1 v + have hv : Fin.cons (v 0) (fun i : Fin n => v i.succ)=v := Fin.cons_self_tail v + simp only [one_mul,hv] at h + simp only [firstNormalRemainderN,sub_apply,differential_apply,differentialValue, + firstNormalCorrectionN_apply] + have hsign (j : Fin n) : (-1:ℂ)^(j.val+2) = -((-1:ℂ)^(j.val+1)) := sign_succ _ + rw [sign_succ (n+1)] at h + simp only [hsign,neg_smul,Finset.sum_neg_distrib] at h + linear_combination (norm := module) h + +lemma firstNormalRemainderN_cocycle {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ z,differentialValue f z=0) (z : Fin (n+2) → M) : + differentialValue (firstNormalRemainderN e f) z=0 := by + rw [firstNormalRemainderN,differentialValue_sub,hf,differential_is_cocycle,sub_self] + +lemma firstNormalRemainderN_identity {n : ℕ} (f : Cochain M (n+1)) (v : Fin (n+1) → M) : + f v=firstNormalRemainderN e f v+differentialValue (firstNormalCorrectionN e f) v := by + simp only [firstNormalRemainderN,sub_apply,differential_apply,sub_add_cancel] + +lemma firstNormalCorrectionN_norm {n : ℕ} (f : Cochain M (n+1)) : + ‖firstNormalCorrectionN e f‖≤4*‖f‖ := by + have h1 : ‖(1:M)‖≤1 := by + rcases subsingleton_or_nontrivial M with h|h + · simp [Subsingleton.elim (1:M) 0] + · simp + calc + _≤‖(normalFirst e f).curryLeft‖*‖(1:M)‖ := ContinuousLinearMap.le_opNorm _ _ + _≤‖normalFirst e f‖ := by rw [ContinuousMultilinearMap.curryLeft_norm]; nlinarith [norm_nonneg (normalFirst e f)] + _≤_ := normalFirst_norm e f + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CollisionBounds.lean b/lean/OAI/Analysis/BoundedHochschild/CollisionBounds.lean new file mode 100644 index 0000000000000000000000000000000000000000..5939789adcef3994ff9b198c647fb7c2e48224e0 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CollisionBounds.lean @@ -0,0 +1,493 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CatalanWords +import OAI.Analysis.BoundedHochschild.Haagerup + +namespace OAI + +/-! Repeated indices, block words, range counts and normalized collision errors. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildCollision +noncomputable section +open Finset +variable {α : Type*} [DecidableEq α] + + +def count (a : α) (l : List (α × Bool)) : ℕ := (l.map Prod.fst).count a + +@[simp] lemma count_cons (a c : α) (b : Bool) (l : List (α × Bool)) : + count a ((c,b)::l) = (if c=a then 1 else 0) + count a l := by + by_cases h : c=a <;> simp [count, h, Nat.add_comm] + +lemma count_parity (a : α) (l : List (α × Bool)) : + Multiplicative.toAdd ((FreeGroup.lift + (fun c : α => Multiplicative.ofAdd (if c=a then (1 : ZMod 2) else 0))) + (FreeGroup.mk l)) = (count a l : ZMod 2) := by + induction l with + | nil => simp [count, ← FreeGroup.one_eq_mk] + | cons p l ih => + rcases p with ⟨c,b⟩ + change Multiplicative.toAdd ((FreeGroup.lift _) + (FreeGroup.mk ([(c,b)] ++ l))) = _ + rw [← FreeGroup.mul_mk, map_mul, toAdd_mul, ih, count_cons, Nat.cast_add] + congr 1 + cases b + · change Multiplicative.toAdd ((FreeGroup.lift _) + (FreeGroup.of c)⁻¹) = _ + rw [map_inv, toAdd_inv, FreeGroup.lift_apply_of] + by_cases h : c=a <;> simp [h] + · change Multiplicative.toAdd ((FreeGroup.lift _) (FreeGroup.of c)) = _ + rw [FreeGroup.lift_apply_of] + by_cases h : c=a <;> simp [h] + + +lemma combined_count_ne_one {l k : List (α × Bool)} (h : FreeGroup.mk l = FreeGroup.mk k) + (a : α) : count a l + count a k ≠ 1 := by + have hp : (count a l : ZMod 2) = (count a k : ZMod 2) := by + simpa only [count_parity] using congrArg (fun g => Multiplicative.toAdd + ((FreeGroup.lift (fun c : α => Multiplicative.ofAdd + (if c=a then (1 : ZMod 2) else 0))) g)) h + intro hc + have hc' : count a l=1 ∧ count a k=0 ∨ count a l=0 ∧ count a k=1 := by omega + rcases hc' with ⟨hl,hk⟩|⟨hl,hk⟩ <;> simp [hl,hk] at hp + +lemma count_reduce_le (a : α) (l : List (α × Bool)) : + count a (FreeGroup.reduce l) ≤ count a l := by + exact (((FreeGroup.reduce.red (L:=l)).sublist).map Prod.fst).count_le a + +lemma exists_repeat_of_not_nodup (l : List α) (h : ¬ l.Nodup) : + ∃ a, 2 ≤ l.count a := by + by_contra! hn + apply h + rw [List.nodup_iff_count_le_one] + intro a + exact Nat.le_of_lt_succ (hn a) + +variable [Fintype α] + +lemma sum_count (l : List (α × Bool)) : ∑ a : α, count a l = l.length := by + induction l with + | nil => simp [count] + | cons p l ih => + rcases p with ⟨a,b⟩ + simp only [count_cons, sum_add_distrib, ih, List.length_cons] + simp [Nat.add_comm] + + + +theorem range_card_le_of_repeated_reduction {l k : List (α × Bool)} {L : ℕ} + (hl : l.length=L) (hk : k.length=L) + (he : FreeGroup.mk l = FreeGroup.mk k) + (hbad : ¬ ((FreeGroup.reduce l).map Prod.fst).Nodup) : + ((l.map Prod.fst ++ k.map Prod.fst).toFinset).card + 1 ≤ L := by + obtain ⟨a, ha⟩ := exists_repeat_of_not_nodup _ hbad + change 2 ≤ count a (FreeGroup.reduce l) at ha + have hal : 2 ≤ count a l := ha.trans (count_reduce_le a l) + have hred : FreeGroup.reduce l = FreeGroup.reduce k := congrArg FreeGroup.toWord he + have hak : 2 ≤ count a k := by rw [hred] at ha; exact ha.trans (count_reduce_le a k) + let s := (l.map Prod.fst ++ k.map Prod.fst).toFinset + have has : a∈s := by + simp only [s, List.mem_toFinset, List.mem_append] + left + exact List.count_pos_iff.mp (show 0 < count a l by omega) + have hs (b : α) (hb : b∈s) : 2 ≤ count b l + count b k := by + have hpos : 0 < count b l + count b k := by + change 0 < (l.map Prod.fst).count b + (k.map Prod.fst).count b + rw [← List.count_append] + exact List.count_pos_iff.mpr (List.mem_toFinset.mp hb) + have hne := combined_count_ne_one he b + omega + have hsum : ∑ b ∈ s, (count b l + count b k) = 2*L := by + rw [sum_subset (subset_univ s)] + · rw [sum_add_distrib, sum_count, sum_count, hl, hk]; omega + · intro b _ hb + have hb' : b ∉ l.map Prod.fst ∧ b ∉ k.map Prod.fst := by + simpa only [s, List.mem_toFinset, List.mem_append, not_or] using hb + simp [count, List.count_eq_zero.mpr hb'.1, List.count_eq_zero.mpr hb'.2] + have hlower : 2*s.card + 2 ≤ ∑ b ∈ s, (count b l + count b k) := by + calc + 2*s.card+2 = ∑ b ∈ s, (2 + if b=a then 2 else 0) := by + simp [sum_add_distrib, has, Nat.mul_comm] + _ ≤ _ := sum_le_sum fun b hb => by + by_cases hba : b=a + · subst b; simp; omega + · simpa [hba] using hs b hb + rw [hsum] at hlower + change s.card + 1 ≤ L + omega + +end +end HochschildCollision + +namespace HochschildBlockWords +noncomputable section +open List FreeGroup HochschildCatalanWords +variable {α : Type*} + +@[simp] lemma length_signed (b : Bool) (l : List α) : (signed b l).length = l.length := by + induction l generalizing b with + | nil => rfl + | cons a l ih => simp [signed, ih] + +def Ends (b : Bool) (w : List (α × Bool)) : Prop := + (∃ a l, w = (a,b)::l) ∧ (∃ l a, w = l ++ [(a,b)]) + +lemma signed_odd_ends (l : List α) (hl : l.length % 2 = 1) (b : Bool) : + Ends b (signed b l) := by + induction l using List.twoStepInduction generalizing b with + | nil => simp at hl + | singleton a => exact ⟨⟨a, [], rfl⟩, ⟨[], a, rfl⟩⟩ + | cons_cons a c l ih _ => + have hl' : l.length % 2 = 1 := by simp only [List.length_cons] at hl; omega + obtain ⟨_, ⟨k,d,hk⟩⟩ := ih hl' b + exact ⟨⟨a, (c,!b) :: signed b l, by simp [signed]⟩, + ⟨(a,b)::(c,!b)::k, d, by simp [signed, hk]⟩⟩ + +variable [DecidableEq α] + +lemma reduce_signed_odd_ends (l : List α) (hl : l.length % 2 = 1) (b : Bool) : + Ends b (reduce (signed b l)) := by + have hr := (reduce.red (L:=signed b l)).length + rw [reduce_signed, length_signed, length_signed] at hr + obtain ⟨n,hn⟩ := hr + have hp : (unorientedReduce l).length % 2 = 1 := by omega + rw [reduce_signed] + exact signed_odd_ends _ hp b + +omit [DecidableEq α] in +lemma ends_append {l k : List (α × Bool)} {b : Bool} (hl : Ends b l) (hk : Ends b k) : + Ends b (l++k) := by + obtain ⟨⟨a,v,rfl⟩,_⟩ := hl + obtain ⟨_,⟨w,c,rfl⟩⟩ := hk + exact ⟨⟨a,v++(w++[(c,b)]),rfl⟩, + ⟨((a,b)::v)++w,c, by simp [List.append_assoc]⟩⟩ + +omit [DecidableEq α] in +lemma reduced_append_of_ends {l k : List (α × Bool)} {b : Bool} + (hl : IsReduced l) (hk : IsReduced k) (hel : Ends b l) (hek : Ends b k) : + IsReduced (l++k) := by + obtain ⟨_,⟨v,a,rfl⟩⟩ := hel + obtain ⟨⟨c,w,rfl⟩,_⟩ := hek + change List.IsChain _ _ + rw [List.append_assoc, List.singleton_append, List.isChain_append_cons_cons] + exact ⟨hl,fun _ => rfl,hk⟩ + + + +theorem reduce_append_odd_blocks (l k : List (α × Bool)) {b : Bool} + (hl : Ends b (reduce l)) (hk : Ends b (reduce k)) : + reduce (l++k) = reduce l ++ reduce k ∧ Ends b (reduce (l++k)) := by + have hr : IsReduced (reduce l ++ reduce k) := reduced_append_of_ends + (IsReduced.of_reduce_eq (by simp)) (IsReduced.of_reduce_eq (by simp)) hl hk + have he : reduce (l++k) = reduce l ++ reduce k := by + rw [← reduce_append_reduce_reduce, hr.reduce_eq] + exact ⟨he,he ▸ ends_append hl hk⟩ + +end +end HochschildBlockWords + +namespace HochschildIndexedHaagerup +noncomputable section +open Finset +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable {G : Type*} [Group G] [DecidableEq G] +variable (τ : A →ₚ[ℂ] ℂ) (u : G →* A) +variable (hτ : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) +variable (hfree : ∀ g : G, g ≠ 1 → τ (u g) = 0) +include hτ hu hfree + + + +lemma norm_sum_sq {I : Type*} [Fintype I] (g : I → G) : + ‖τ.toPreGNS (∑ i, u (g i))‖^2 = + Fintype.card {p : I × I // g p.1 = g p.2} := by + classical + have hi : inner ℂ (τ.toPreGNS (∑ i, u (g i))) + (τ.toPreGNS (∑ i, u (g i))) = + (Fintype.card {p : I × I // g p.1 = g p.2} : ℂ) := by + simp only [map_sum, sum_inner, inner_sum, + HochschildTracePolynomial.inner_word τ u hτ hu hfree] + simp only [Fintype.card_subtype, Finset.card_filter, Nat.cast_sum, apply_ite, + Nat.cast_one, Nat.cast_zero, Fintype.sum_prod_type] + exact Finset.sum_comm + apply Complex.ofReal_injective + simpa [inner_self_eq_norm_sq_to_K, Complex.ofReal_pow] using hi + +end +end HochschildIndexedHaagerup + +namespace HochschildIndexedHaagerup +noncomputable section +open Finset HochschildTransfer +variable {α : Type*} [Fintype α] [DecidableEq α] +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (u : FreeGroup α →* A) +variable (hτ : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) +variable (hfree : ∀ g : FreeGroup α, g ≠ 1 → τ (u g) = 0) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) +variable (hfaith : ∀ a : A, τ (star a*a) = 0 → a = 0) +include hτ hu hfree htr hfaith + +lemma norm_sum_le {I : Type*} [Fintype I] (g : I → FreeGroup α) (q : ℕ) + (hq : ∀ i, (g i).toWord.length = q) : + ‖∑ i, u (g i)‖ ≤ (q+1:ℝ) * + Real.sqrt (Fintype.card {p : I × I // g p.1 = g p.2}) := by + classical + let p : Polynomial α := ∑ i, MonoidAlgebra.single (g i) (1:ℂ) + have hp : ∀ x ∈ p.coeff.support, x.toWord.length = q := by + intro x hx + have hx' : (∑ i : I, if g i = x then (1:ℂ) else 0) ≠ 0 := by + simpa only [p, MonoidAlgebra.coeff_sum, Finsupp.finsetSum_apply, + MonoidAlgebra.coeff_single, Finsupp.single_apply] using Finsupp.mem_support_iff.mp hx + obtain ⟨i,_,hi⟩ := Finset.exists_ne_zero_of_sum_ne_zero hx' + have he : g i = x := by by_contra h; simp [h] at hi + simpa only [← he] using hq i + have he : MonoidAlgebra.lift ℂ A (FreeGroup α) u p = ∑ i, u (g i) := by + simp only [p,map_sum,MonoidAlgebra.lift_single,one_smul] + have h := norm_eval_homogeneous_le τ u hτ hu hfree htr hfaith p q hp + rw [he] at h + have hn := norm_sum_sq τ u hτ hu hfree g + have he' : ‖τ.toPreGNS (∑ i, u (g i))‖ = + Real.sqrt (Fintype.card {p : I × I // g p.1 = g p.2}) := by + rw [← hn, Real.sqrt_sq (norm_nonneg _)] + simpa only [he'] using h + +end +end HochschildIndexedHaagerup + +namespace HochschildRangeCount +noncomputable section +open Finset +variable {α : Type*} [Fintype α] [DecidableEq α] + +abbrev SmallRange (n k : ℕ) := + {f : Fin n → α // (Finset.univ.image f).card ≤ k} + +def composeSmall {n k : ℕ} (p : (Fin k → α) × (Fin n → Fin k)) : SmallRange (α:=α) n k := + ⟨p.1 ∘ p.2, (card_le_card (by + intro a ha + obtain ⟨i,_,rfl⟩ := mem_image.mp ha + exact mem_image.mpr ⟨p.2 i, mem_univ _, rfl⟩ : + univ.image (p.1 ∘ p.2) ⊆ univ.image p.1)).trans + (card_image_le.trans (by simp))⟩ + +omit [Fintype α] in +lemma composeSmall_surjective [Nonempty α] (n k : ℕ) : + Function.Surjective (composeSmall (α:=α) (n:=n) (k:=k)) := by + classical + let : Inhabited α := Classical.inhabited_of_nonempty ‹Nonempty α› + intro h + let s := Finset.univ.image h.val + obtain ⟨e⟩ := Function.Embedding.nonempty_of_card_le + (show Fintype.card ↥s ≤ Fintype.card (Fin k) by simpa only [Fintype.card_coe, Fintype.card_fin] using h.property) + let f : Fin k → α := Function.extend e Subtype.val (fun _ => default) + let g : Fin n → Fin k := fun i => e ⟨h.val i, by simp [s]⟩ + refine ⟨(f,g), Subtype.ext ?_⟩ + funext i + exact e.injective.extend_apply Subtype.val (fun _ => default) ⟨h.val i, by simp [s]⟩ + + +theorem card_smallRange_le [Nonempty α] (n k : ℕ) : + Fintype.card (SmallRange (α:=α) n k) ≤ (Fintype.card α)^k * k^n := by + have h := Fintype.card_le_of_surjective _ (composeSmall_surjective (α:=α) n k) + simpa only [Fintype.card_prod, Fintype.card_fun, Fintype.card_fin] using h + +end +end HochschildRangeCount + +namespace HochschildCollision +noncomputable section +open Finset HochschildRangeCount +variable {α : Type*} [Fintype α] [DecidableEq α] + +def tupleWord {L : ℕ} (σ : Fin L → Bool) (f : Fin L → α) : List (α × Bool) := + List.ofFn fun i => (f i, σ i) + +omit [Fintype α] [DecidableEq α] in +@[simp] lemma tupleWord_length {L : ℕ} (σ : Fin L → Bool) (f : Fin L → α) : + (tupleWord σ f).length = L := by simp [tupleWord] + +omit [Fintype α] [DecidableEq α] in +@[simp] lemma tupleWord_map {L : ℕ} (σ : Fin L → Bool) (f : Fin L → α) : + (tupleWord σ f).map Prod.fst = List.ofFn f := by simp [tupleWord, List.map_ofFn, Function.comp_def] + +abbrev BadPairs {L : ℕ} (σ : Fin L → Bool) := + {p : (Fin L → α) × (Fin L → α) // + FreeGroup.mk (tupleWord σ p.1) = FreeGroup.mk (tupleWord σ p.2) ∧ + ¬ ((FreeGroup.reduce (tupleWord σ p.1)).map Prod.fst).Nodup} + +omit [Fintype α] in +lemma ofFn_toFinset {n : ℕ} (f : Fin n → α) : + (List.ofFn f).toFinset = univ.image f := by + ext a + simp + +def pairToSmall {L : ℕ} (σ : Fin L → Bool) (p : BadPairs (α:=α) σ) : + SmallRange (α:=α) (L+L) (L-1) := by + refine ⟨Fin.append p.val.1 p.val.2, ?_⟩ + have h := range_card_le_of_repeated_reduction + (tupleWord_length σ p.val.1) (tupleWord_length σ p.val.2) p.property.1 p.property.2 + rw [tupleWord_map,tupleWord_map, ← List.ofFn_fin_append, ofFn_toFinset] at h + omega + +lemma pairToSmall_injective {L : ℕ} (σ : Fin L → Bool) : + Function.Injective (pairToSmall (α:=α) σ) := by + intro p q hpq + have h : Fin.append p.val.1 p.val.2 = Fin.append q.val.1 q.val.2 := + congrArg Subtype.val hpq + apply Subtype.ext + apply Prod.ext + · funext i + simpa only [Fin.append_left] using congrFun h (Fin.castAdd L i) + · funext i + simpa only [Fin.append_right] using congrFun h (Fin.natAdd L i) + + + +theorem card_badPairs_le [Nonempty α] {L : ℕ} (σ : Fin L → Bool) : + Fintype.card (BadPairs (α:=α) σ) ≤ (Fintype.card α)^(L-1) * (L-1)^(2*L) := by + have h := Fintype.card_le_of_injective (pairToSmall (α:=α) σ) (pairToSmall_injective (α:=α) σ) + exact h.trans (by simpa only [two_mul] using card_smallRange_le (α:=α) (L+L) (L-1)) + +end +end HochschildCollision + +namespace HochschildBlockError +noncomputable section +open Finset HochschildCollision HochschildIndexedHaagerup +variable {α : Type*} [Fintype α] [DecidableEq α] + +abbrev BadTerms {L : ℕ} (σ : Fin L → Bool) (q : ℕ) := + {f : Fin L → α // (FreeGroup.mk (tupleWord σ f)).toWord.length = q ∧ + ¬ ((FreeGroup.reduce (tupleWord σ f)).map Prod.fst).Nodup} + +def wordOf {L : ℕ} (σ : Fin L → Bool) (f : Fin L → α) : FreeGroup α := + FreeGroup.mk (tupleWord σ f) + +def pairToBad {L : ℕ} (σ : Fin L → Bool) (q : ℕ) + (p : {p : BadTerms (α:=α) σ q × BadTerms (α:=α) σ q // + wordOf σ p.1.val = wordOf σ p.2.val}) : BadPairs (α:=α) σ := + ⟨(p.val.1.val,p.val.2.val),p.property,p.val.1.property.2⟩ + +omit [Fintype α] in +lemma pairToBad_injective {L : ℕ} (σ : Fin L → Bool) (q : ℕ) : + Function.Injective (pairToBad (α:=α) σ q) := by + intro p z hpz + apply Subtype.ext + apply Prod.ext + · apply Subtype.ext + exact congrArg (fun p : BadPairs (α:=α) σ => p.val.1) hpz + · apply Subtype.ext + exact congrArg (fun p : BadPairs (α:=α) σ => p.val.2) hpz + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (u : FreeGroup α →* A) +variable (hτ : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) +variable (hfree : ∀ g : FreeGroup α, g ≠ 1 → τ (u g) = 0) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) +variable (hfaith : ∀ a : A, τ (star a*a) = 0 → a = 0) + + +def badSum {L : ℕ} (σ : Fin L → Bool) (q : ℕ) : A := + ∑ f : BadTerms (α:=α) σ q, u (wordOf σ f.val) + +include hτ hu hfree htr hfaith in +lemma badSum_norm_le [Nonempty α] {L : ℕ} (σ : Fin L → Bool) (q : ℕ) : + ‖badSum u σ q‖ ≤ (q+1:ℝ) * + Real.sqrt ((Fintype.card α:ℝ)^(L-1) * (L-1:ℕ)^(2*L)) := by + have hb := norm_sum_le τ u hτ hu hfree htr hfaith + (fun f : BadTerms (α:=α) σ q => wordOf σ f.val) q (fun f => f.property.1) + have hc := Fintype.card_le_of_injective (pairToBad (α:=α) σ q) (pairToBad_injective σ q) + have hc' := hc.trans (card_badPairs_le (α:=α) σ) + have hreal : (Fintype.card {p : BadTerms (α:=α) σ q × BadTerms (α:=α) σ q // + wordOf σ p.1.val = wordOf σ p.2.val} : ℝ) ≤ + (Fintype.card α:ℝ)^(L-1)*(L-1:ℕ)^(2*L) := by exact_mod_cast hc' + exact hb.trans (mul_le_mul_of_nonneg_left (Real.sqrt_le_sqrt hreal) (by positivity)) + + +def normalizer (r L : ℕ) : ℝ := (Real.sqrt r)⁻¹ ^ L + +lemma normalizer_nonneg (r L : ℕ) : 0 ≤ normalizer r L := by unfold normalizer; positivity + +lemma normalizer_sq (r L : ℕ) : normalizer r L ^ 2 = ((r:ℝ)^L)⁻¹ := by + unfold normalizer + rw [← pow_mul, Nat.mul_comm L 2, pow_mul, inv_pow, + Real.sq_sqrt (by positivity), inv_pow] + +lemma normalizer_cancel {r L : ℕ} (hr : 0 < r) (hL : 0 < L) : + normalizer r L ^ 2 * (r:ℝ)^(L-1) = (r:ℝ)⁻¹ := by + rw [normalizer_sq] + have hr' : (r:ℝ) ≠ 0 := by exact_mod_cast hr.ne' + have hp : (r:ℝ)^L = (r:ℝ)^(L-1) * r := by + simpa only [pow_succ] using congrArg (fun n : ℕ => (r:ℝ)^n) (show L = (L-1)+1 by omega) + rw [hp] + field_simp + +include hτ hu hfree htr hfaith in + + +theorem normalized_badSum_sq_le [Nonempty α] {L : ℕ} (hL : 0 < L) + (σ : Fin L → Bool) (q : ℕ) : + ‖normalizer (Fintype.card α) L • badSum u σ q‖^2 ≤ + ((q+1:ℝ)^2 * (L-1:ℕ)^(2*L)) / Fintype.card α := by + have hn := badSum_norm_le τ u hτ hu hfree htr hfaith σ q + have hc : 0 ≤ (Fintype.card α:ℝ)^(L-1) * (L-1:ℕ)^(2*L) := by positivity + have hn' : ‖badSum u σ q‖^2 ≤ + (q+1:ℝ)^2 * ((Fintype.card α:ℝ)^(L-1)*(L-1:ℕ)^(2*L)) := by + have h := sq_le_sq₀ (norm_nonneg (badSum u σ q)) (by positivity : + 0 ≤ (q+1:ℝ)*Real.sqrt ((Fintype.card α:ℝ)^(L-1)*(L-1:ℕ)^(2*L))) + have h' := h.mpr hn + simpa only [mul_pow, Real.sq_sqrt hc] using h' + calc + _ = normalizer (Fintype.card α) L ^ 2 * ‖badSum u σ q‖^2 := by + rw [norm_smul, Real.norm_of_nonneg (normalizer_nonneg _ _),mul_pow] + _ ≤ normalizer (Fintype.card α) L ^ 2 * + ((q+1:ℝ)^2 * ((Fintype.card α:ℝ)^(L-1)*(L-1:ℕ)^(2*L))) := + mul_le_mul_of_nonneg_left hn' (sq_nonneg _) + _ = (normalizer (Fintype.card α) L ^ 2 * (Fintype.card α:ℝ)^(L-1)) * + ((q+1:ℝ)^2*(L-1:ℕ)^(2*L)) := by ring + _ = _ := by rw [normalizer_cancel Fintype.card_pos hL]; ring + +end + +noncomputable section +open Filter +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) +variable (hτ : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) +variable (hfree : ∀ r (g : FreeGroup (Fin (r+1))), g ≠ 1 → τ (u r g) = 0) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) +variable (hfaith : ∀ a : A, τ (star a*a) = 0 → a = 0) +include hτ hu hfree htr hfaith + + +theorem tendsto_normalized_badSum {L : ℕ} (hL : 0 < L) (σ : Fin L → Bool) (q : ℕ) : + Tendsto (fun r => normalizer (r+1) L • badSum (u r) σ q) atTop (𝓝 0) := by + have hsq : Tendsto (fun r => ‖normalizer (r+1) L • badSum (u r) σ q‖^2) + atTop (𝓝 0) := by + have hb (r : ℕ) : ‖normalizer (r+1) L • badSum (u r) σ q‖^2 ≤ + ((q+1:ℝ)^2 * (L-1:ℕ)^(2*L)) / ((r:ℝ)+1) := by + simpa only [Fintype.card_fin, Nat.cast_add, Nat.cast_one] using + normalized_badSum_sq_le τ (u r) hτ (hu r) (hfree r) htr hfaith hL σ q + exact squeeze_zero (fun r => sq_nonneg _) hb + (tendsto_const_nhds.div_atTop + (tendsto_atTop_add_const_right atTop 1 (tendsto_natCast_atTop_atTop (R := ℝ)))) + apply tendsto_zero_iff_norm_tendsto_zero.mpr + simpa only [Real.sqrt_sq (norm_nonneg _), Real.sqrt_zero] using hsq.sqrt + + +theorem tendsto_total_badSum {L : ℕ} (hL : 0 < L) (σ : Fin L → Bool) : + Tendsto (fun r => ∑ q ∈ Finset.range (L+1), + normalizer (r+1) L • badSum (u r) σ q) atTop (𝓝 0) := by + simpa only [Finset.sum_const_zero] using + tendsto_finsetSum (Finset.range (L+1)) + (fun q _ => tendsto_normalized_badSum τ u hτ hu hfree htr hfaith hL σ q) + +end +end HochschildBlockError +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/ColumnRowEstimates.lean b/lean/OAI/Analysis/BoundedHochschild/ColumnRowEstimates.lean new file mode 100644 index 0000000000000000000000000000000000000000..4d4ac9d3a38a58ac043faca887b15413448e54b7 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/ColumnRowEstimates.lean @@ -0,0 +1,78 @@ +import OAI.Analysis.BoundedHochschild.MatrixAmplification + +namespace OAI + +/-! Finite row and column estimates inside a properly infinite algebra. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] {n : ℕ} +variable (c : Fin n → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + +/-- A row, realized inside the algebra by orthogonal isometries. -/ +def columnRow (x : Fin n → M) : M := ∑ i, x i * star (c i : M) + +/-- A column, realized inside the algebra by orthogonal isometries. -/ +def columnColumn (y : Fin n → M) : M := ∑ i, (c i : M) * y i + +include hi ho in +lemma columnRow_mul_column (x y : Fin n → M) : + columnRow c x * columnColumn c y = ∑ i, x i * y i := by + classical + calc + _ = ∑ i, ∑ j, x i * (star (c i : M) * (c j : M)) * y j := by + simp only [columnRow, columnColumn] + rw [Finset.sum_mul] + simp only [Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + apply Finset.sum_congr rfl + intro j _ + simp only [mul_assoc] + _ = _ := by simp [column_star_mul c hi ho] + +include hi ho in +lemma columnRow_mul_star (x : Fin n → M) : + columnRow c x * star (columnRow c x) = ∑ i, x i * star (x i) := by + have hs : star (columnRow c x) = columnColumn c (fun i => star (x i)) := by + simp only [columnRow, columnColumn, star_sum, star_mul, star_star] + rw [hs, columnRow_mul_column c hi ho] + +include hi ho in +lemma star_column_mul_column (y : Fin n → M) : + star (columnColumn c y) * columnColumn c y = ∑ i, star (y i) * y i := by + have hs : star (columnColumn c y) = columnRow c (fun i => star (y i)) := by + simp only [columnRow, columnColumn, star_sum, star_mul] + rw [hs, columnRow_mul_column c hi ho] + +include hi ho in +lemma columnRow_norm_sq (x : Fin n → M) : + ‖columnRow c x‖ ^ 2 = ‖∑ i, x i * star (x i)‖ := by + rw [sq, ← CStarRing.norm_self_mul_star, columnRow_mul_star c hi ho] + +include hi ho in +lemma columnColumn_norm_sq (y : Fin n → M) : + ‖columnColumn c y‖ ^ 2 = ‖∑ i, star (y i) * y i‖ := by + rw [sq, ← CStarRing.norm_star_mul_self, star_column_mul_column c hi ho] + +include hi ho in +/-- The finite row-column inequality, using only the particular isometries +available in the properly infinite case. -/ +lemma finite_row_column_estimate (x y : Fin n → M) : + ‖∑ i, x i * y i‖ ^ 2 ≤ ‖∑ i, x i * star (x i)‖ * ‖∑ i, star (y i) * y i‖ := by + rw [← columnRow_mul_column c hi ho] + calc + _ ≤ (‖columnRow c x‖ * ‖columnColumn c y‖) ^ 2 := + pow_le_pow_left₀ (norm_nonneg _) (norm_mul_le _ _) 2 + _ = _ := by rw [mul_pow, columnRow_norm_sq c hi ho, columnColumn_norm_sq c hi ho] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CommutantQuantization.lean b/lean/OAI/Analysis/BoundedHochschild/CommutantQuantization.lean new file mode 100644 index 0000000000000000000000000000000000000000..edb54a2ea86225b9038cfba43f319ed20e593350 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CommutantQuantization.lean @@ -0,0 +1,192 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MatrixCommutants +import OAI.Analysis.BoundedHochschild.MatrixDisplacement + +namespace OAI + +/-! Small matrix expectations and coefficient energy bounds. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildQuantization +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems +universe u v +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable {I : Type v} [Fintype I] + +def matrixEnergy (x : I → M) {n : ℕ} (E : MatrixSystem M n) : ℝ := + ∑ i, ‖τ.toPreGNS (E.expectation (x i))‖^2 + +lemma matrixEnergy_nonneg (x : I → M) {n : ℕ} (E : MatrixSystem M n) : + 0 ≤ matrixEnergy τ x E := Finset.sum_nonneg (fun _ _ => sq_nonneg _) + +lemma matrixEnergy_drop (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (x : I → M) {n m : ℕ} (E : MatrixSystem M n) (F : MatrixSystem E.commutant m) + (hn : n ≠ 0) (hm : m ≠ 0) (i : I) {δ : ℝ} + (hi : ‖τ.toPreGNS ((E.extend F).expectation (x i))‖^2+δ < + ‖τ.toPreGNS (E.expectation (x i))‖^2) : + matrixEnergy τ x (E.extend F)+δ < matrixEnergy τ x E := by + classical + have hh : (∑ j ∈ Finset.univ.erase i, ‖τ.toPreGNS ((E.extend F).expectation (x j))‖^2) ≤ + ∑ j ∈ Finset.univ.erase i, ‖τ.toPreGNS (E.expectation (x j))‖^2 := by + apply Finset.sum_le_sum + intro j hj + have hp := E.extension_pythagoras F τ htr hn hm (x j) + nlinarith [sq_nonneg ‖τ.toPreGNS (E.expectation (x j)-(E.extend F).expectation (x j))‖] + have hE := Finset.sum_erase_add Finset.univ + (fun j => ‖τ.toPreGNS (E.expectation (x j))‖^2) (Finset.mem_univ i) + have hF := Finset.sum_erase_add Finset.univ + (fun j => ‖τ.toPreGNS ((E.extend F).expectation (x j))‖^2) (Finset.mem_univ i) + dsimp only [matrixEnergy] + linarith + +include e in + + +theorem exists_small_matrix_expectations + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (x : I → M) (hx : ∀ i, τ (x i)=0) {ε : ℝ} (hε : 0<ε) : + ∃ (n : ℕ) (E : MatrixSystem M n), 0 + exact ⟨f,le_rfl,by simp,residual_translate_cocycle f hf⟩ + | @insert u s hu ih => + obtain ⟨F,hF,hfix,hr⟩ := ih + obtain ⟨G,hG,hfixG,hrG⟩ := exists_translate_fixed_preserving e hL hR + u (s : Set (unitary M)) (fun v _ => hcomm u v) F hfix _ hr + refine ⟨G,hG.trans hF,?_,hrG⟩ + intro v hv + exact hfixG v (by simpa only [Finset.mem_insert,Set.mem_insert_iff,Finset.mem_coe] using hv) + +theorem exists_commuting_invariant {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (hcomm : ∀ u v : unitary M, Commute u v) + (f : Cochain M (n+1)) (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ G : Cochain M (n+1), ‖G‖≤‖f‖ ∧ + (∀ v, translateLast G v=G) ∧ + ∀ x, residualCLM x G=((-1:ℂ)^(n+1)) • f x := by + classical + choose F hF hfix hr using exists_finite_commuting_invariant e hL hR hcomm f hf + let U : Ultrafilter (Finset (unitary M)) := Ultrafilter.of atTop + have hU : (U : Filter (Finset (unitary M)))≤atTop := Ultrafilter.of_le _ + obtain ⟨G,hG,ht⟩ := bounded_cochain_ultralimit e U F ‖f‖ (norm_nonneg _) hF + refine ⟨G,hG,?_,?_⟩ + · intro v + ext x + have hlim := predual_tendsto_translate e hR ht v x + have he : (fun s => translateLast (F s) v x)=ᶠ[U] (fun s => F s x) := by + apply hU + filter_upwards [eventually_ge_atTop ({v} : Finset (unitary M))] with s hs + rw [hfix s v (hs (Finset.mem_singleton_self v))] + have hlim' : PredualTendsto e (fun s => translateLast (F s) v x) U (G x) := by + intro z + exact (ht x z).congr' (he.mono (fun s h => congrArg (fun a : M => e.symm a z) h.symm)) + exact predual_tendsto_unique e hlim hlim' + · intro x + have hlim := predual_tendsto_residual e hL ht x + have he (s : Finset (unitary M)) : residualCLM x (F s)=((-1:ℂ)^(n+1)) • f x := by + simpa only [translateLast_one] using hr s 1 x + simp only [he] at hlim + exact predual_tendsto_unique e hlim + (predual_tendsto_const e (((-1:ℂ)^(n+1)) • f x) (U : Filter (Finset (unitary M)))) + +lemma right_module_of_all_translates {n : ℕ} (F : Cochain M (n+1)) + (hfix : ∀ v : unitary M, translateLast F v=F) : + ∀ (a : Fin n → M) (x : M), F (Fin.snoc a x)=F (Fin.snoc a 1)*x := by + intro a x + let L := F.curryRight a + have hu (u : unitary M) : L (u:M)=L 1*(u:M) := by + have h := congrArg (fun H : Cochain M (n+1) => H (Fin.snoc a 1)) (hfix u) + simp only [translateLast_apply,Fin.snoc_last,Fin.snoc_castSucc,one_mul] at h + have hh := congrArg (fun y : M => y*(u:M)) h + simpa only [L,ContinuousMultilinearMap.curryRight_apply,mul_assoc,Unitary.star_mul_self_of_mem u.prop,mul_one] using hh + have hx : x ∈ Submodule.span ℂ (unitary M : Set M) := by + rw [CStarAlgebra.span_unitary]; trivial + change L x=L 1*x + induction hx using Submodule.span_induction with + | mem y hy => exact hu ⟨y,hy⟩ + | zero => simp + | add y z hy hz ihy ihz => simp only [map_add,ihy,ihz,mul_add] + | smul r y hy ih => simp only [map_smul,ih,mul_smul_comm] + +include e in + +theorem primitive_of_commutative [CompleteSpace X] [PartialOrder M] [StarOrderedRing M] + (hcomm : ∀ a b : M, a*b=b*a) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤‖f‖ ∧ ∀ x, differentialValue g x=f x := by + have hc (u v : unitary M) : Commute u v := by + apply Subtype.ext + exact hcomm (u:M) (v:M) + obtain ⟨F,hF,hfix,hr⟩ := exists_commuting_invariant e + (HochschildSakai.mul_hasPreadjoint e) (HochschildSakai.mul_right_hasPreadjoint e) hc f hf + exact primitive_from_average f F hF hr (right_module_of_all_translates F hfix) + +theorem primitive_of_commutative_wstar [WStarAlgebra M] + (hcomm : ∀ a b : M, a*b=b*a) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤‖f‖ ∧ ∀ x, differentialValue g x=f x := by + obtain ⟨Y,hY,hN,hC,⟨d⟩⟩ := WStarAlgebra.exists_predual (M:=M) + let := hY + let := hN + let := hC + let : PartialOrder M := CStarAlgebra.spectralOrder M + let : StarOrderedRing M := CStarAlgebra.spectralOrderedRing M + exact primitive_of_commutative d hcomm f hf + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CommutingAverages.lean b/lean/OAI/Analysis/BoundedHochschild/CommutingAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..18676a8dde713f743a694e8920733db9a5327e7f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CommutingAverages.lean @@ -0,0 +1,120 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Translation averages preserving commuting invariance. -/ + +noncomputable section + +open Filter Topology +namespace BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +lemma predual_tendsto_translate {n : ℕ} + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + {F : I → Cochain M (n+1)} {G : Cochain M (n+1)} {l : Filter I} + (ht : ∀ x, PredualTendsto e (fun i => F i x) l (G x)) (u : unitary M) + (x : Fin (n+1) → M) : + PredualTendsto e (fun i => translateLast (F i) u x) l (translateLast G u x) := by + simp only [translateLast_apply] + exact (hR (star (u:M))).tendsto e (ht _) + +lemma translate_iterate_eq {n : ℕ} (u : unitary M) (F : Cochain M (n+1)) (j : ℕ) : + (translateLastCLM u)^[j] F=translateLast F (u^j) := by + induction j with + | zero => simp + | succ j ih => + rw [Function.iterate_succ_apply',ih] + change translateLast (translateLast F (u^j)) u = _ + rw [translateLast_mul,pow_succ'] + +lemma residual_translate_cesaro {n : ℕ} (u : unitary M) (F : Cochain M (n+1)) + (c : (Fin (n+1) → M) → M) + (hr : ∀ v x, residualCLM x (translateLast F v)=c x) (j : ℕ) : + ∀ v x, residualCLM x (translateLast (HochschildCesaro.avg (translateLastCLM u) F j) v)=c x := by + intro v x + let L : Cochain M (n+1) →L[ℂ] M := (residualCLM x).comp (translateLastCLM v) + change L (HochschildCesaro.avg (translateLastCLM u) F j)=c x + rw [HochschildCesaro.avg,map_smul,map_sum] + have hL (k : ℕ) : L ((translateLastCLM u)^[k] F)=c x := by + rw [translate_iterate_eq] + change residualCLM x (translateLast (translateLast F (u^k)) v)=c x + rw [translateLast_mul,hr] + simp only [hL,Finset.sum_const,Finset.card_range,← Nat.cast_smul_eq_nsmul ℂ, + Nat.cast_add_one,smul_smul] + rw [inv_mul_cancel₀ (show (j+1:ℂ)≠0 by exact_mod_cast Nat.succ_ne_zero j),one_smul] + +lemma translate_cesaro_fixed {n : ℕ} (u v : unitary M) (huv : Commute u v) + (F : Cochain M (n+1)) (hF : translateLast F v=F) (j : ℕ) : + translateLast (HochschildCesaro.avg (translateLastCLM u) F j) v= + HochschildCesaro.avg (translateLastCLM u) F j := by + have hi (k : ℕ) : translateLast ((translateLastCLM u)^[k] F) v= + (translateLastCLM u)^[k] F := by + rw [translate_iterate_eq,translateLast_mul,← (huv.pow_left k).eq, + ← translateLast_mul,hF] + change (translateLastCLM v) (HochschildCesaro.avg (translateLastCLM u) F j)=_ + rw [HochschildCesaro.avg,map_smul,map_sum] + congr 1 + apply Finset.sum_congr rfl + intro k _ + exact hi k + +theorem exists_translate_fixed_preserving {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (u : unitary M) (S : Set (unitary M)) (hcomm : ∀ v ∈ S, Commute u v) + (F : Cochain M (n+1)) (hfix : ∀ v ∈ S, translateLast F v=F) + (c : (Fin (n+1) → M) → M) + (hr : ∀ v x, residualCLM x (translateLast F v)=c x) : + ∃ G : Cochain M (n+1), ‖G‖≤‖F‖ ∧ + (∀ v ∈ insert u S, translateLast G v=G) ∧ + ∀ v x, residualCLM x (translateLast G v)=c x := by + let P : Cochain M (n+1) →L[ℂ] Cochain M (n+1) := translateLastCLM u + let A := fun j => HochschildCesaro.avg P F j + let U : Ultrafilter ℕ := Ultrafilter.of atTop + have hU : (U : Filter ℕ)≤atTop := Ultrafilter.of_le _ + have hP (g : Cochain M (n+1)) : ‖P g‖≤‖g‖ := norm_translateLast_le g u + have hA (j : ℕ) : ‖A j‖≤‖F‖ := HochschildCesaro.norm_avg_le P hP F j + obtain ⟨G,hG,ht⟩ := bounded_cochain_ultralimit e U A ‖F‖ (norm_nonneg _) hA + refine ⟨G,hG,?_,?_⟩ + · intro v hv + rcases hv with hv | hv + · subst v + ext x + have hlim := predual_tendsto_sub e (predual_tendsto_translate e hR ht u x) (ht x) + have hn : Tendsto (fun j => P (A j)-A j) (U : Filter ℕ) (𝓝 0) := + (HochschildCesaro.avg_defect_tendsto P hP F).mono_left hU + have hxn : Tendsto (fun j => (P (A j)-A j) x) (U : Filter ℕ) (𝓝 0) := by + convert ((ContinuousMultilinearMap.apply ℂ (fun _ : Fin (n+1) => M) M x).continuous.tendsto 0).comp hn using 1 + · rfl + · simp + exact sub_eq_zero.mp (predual_tendsto_unique e hlim (predual_tendsto_of_norm e hxn)) + · ext x + have hlim := predual_tendsto_translate e hR ht v x + have he (j : ℕ) : translateLast (A j) v=A j := + translate_cesaro_fixed u v (hcomm v hv) F (hfix v hv) j + simp only [he] at hlim + exact predual_tendsto_unique e hlim (ht x) + · intro v x + have hlim := predual_tendsto_residual e hL + (fun y => predual_tendsto_translate e hR ht v y) x + have he (j : ℕ) : residualCLM x (translateLast (A j) v)=c x := + residual_translate_cesaro u F c hr j v x + simp only [he] at hlim + exact predual_tendsto_unique e hlim (predual_tendsto_const e (c x) (U : Filter ℕ)) + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CommutingExtensions.lean b/lean/OAI/Analysis/BoundedHochschild/CommutingExtensions.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5362e69a6e331653b5ccd762d3fbe06219609f4 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CommutingExtensions.lean @@ -0,0 +1,109 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers +import OAI.Analysis.BoundedHochschild.CommutingAverages + +namespace OAI + +/-! Extending commuting invariance through finite averages. -/ + +noncomputable section + +open Filter Topology +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) +variable {T : Type*} (u : T → unitary M) (S : Set (unitary M)) + +include e in +lemma exists_finite_commuting_extension {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (hcomm : ∀ t t', Commute (u t) (u t')) + (hS : ∀ t v, v ∈ S → Commute (u t) v) + (F : Cochain M (n+1)) (hfix : ∀ v ∈ S, translateLast F v=F) + (c : (Fin (n+1) → M) → M) + (hr : ∀ v x, residualCLM x (translateLast F v)=c x) (s : Finset T) : + ∃ G : Cochain M (n+1), ‖G‖≤‖F‖ ∧ + (∀ v ∈ S, translateLast G v=G) ∧ + (∀ t ∈ s, translateLast G (u t)=G) ∧ + ∀ v x, residualCLM x (translateLast G v)=c x := by + classical + induction s using Finset.induction_on with + | empty => exact ⟨F,le_rfl,hfix,by simp,hr⟩ + | @insert t s ht ih => + obtain ⟨H,hH,hHS,hHs,hHr⟩ := ih + let B : Set (unitary M) := S ∪ u '' (s : Set T) + have hB : ∀ v ∈ B, Commute (u t) v := by + intro v hv + rcases hv with hv | ⟨t',ht',rfl⟩ + · exact hS t v hv + · exact hcomm t t' + have hHB : ∀ v ∈ B, translateLast H v=H := by + intro v hv + rcases hv with hv | ⟨t',ht',rfl⟩ + · exact hHS v hv + · exact hHs t' ht' + obtain ⟨G,hG,hGB,hGr⟩ := exists_translate_fixed_preserving e hL hR (u t) B hB H hHB c hHr + refine ⟨G,hG.trans hH,?_,?_,hGr⟩ + · intro v hv + exact hGB v (Set.mem_insert_of_mem _ (Or.inl hv)) + · intro t' ht' + rcases Finset.mem_insert.mp ht' with rfl | ht' + · exact hGB (u t') (Set.mem_insert _ _) + · exact hGB (u t') (Set.mem_insert_of_mem _ (Or.inr ⟨t',ht',rfl⟩)) + +include e in +theorem exists_commuting_extension {n : ℕ} + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (hcomm : ∀ t t', Commute (u t) (u t')) + (hS : ∀ t v, v ∈ S → Commute (u t) v) + (F : Cochain M (n+1)) (hfix : ∀ v ∈ S, translateLast F v=F) + (c : (Fin (n+1) → M) → M) + (hr : ∀ v x, residualCLM x (translateLast F v)=c x) : + ∃ G : Cochain M (n+1), ‖G‖≤‖F‖ ∧ + (∀ v ∈ S, translateLast G v=G) ∧ + (∀ t, translateLast G (u t)=G) ∧ + ∀ v x, residualCLM x (translateLast G v)=c x := by + classical + choose A hA hAS hAu hAr using exists_finite_commuting_extension e u S hL hR hcomm hS F hfix c hr + let U : Ultrafilter (Finset T) := Ultrafilter.of atTop + have hU : (U : Filter (Finset T))≤atTop := Ultrafilter.of_le _ + obtain ⟨G,hG,ht⟩ := bounded_cochain_ultralimit e U A ‖F‖ (norm_nonneg _) hA + refine ⟨G,hG,?_,?_,?_⟩ + · intro v hv + ext x + have hlim := predual_tendsto_translate e hR ht v x + have he (s : Finset T) : translateLast (A s) v=A s := hAS s v hv + simp only [he] at hlim + exact predual_tendsto_unique e hlim (ht x) + · intro t + ext x + have hlim := predual_tendsto_translate e hR ht (u t) x + have he : (fun s => translateLast (A s) (u t) x)=ᶠ[U] (fun s => A s x) := by + apply hU + filter_upwards [eventually_ge_atTop ({t} : Finset T)] with s hs + rw [hAu s t (hs (Finset.mem_singleton_self t))] + have hlim' : PredualTendsto e (fun s => translateLast (A s) (u t) x) U (G x) := by + intro z + exact (ht x z).congr' (he.mono (fun s h => congrArg (fun a : M => e.symm a z) h.symm)) + exact predual_tendsto_unique e hlim hlim' + · intro v x + have hlim := predual_tendsto_residual e hL + (fun y => predual_tendsto_translate e hR ht v y) x + simp only [hAr] at hlim + exact predual_tendsto_unique e hlim (predual_tendsto_const e (c x) (U : Filter (Finset T))) + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompactAverages.lean b/lean/OAI/Analysis/BoundedHochschild/CompactAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..a7d1c8c5dd50f0ffeb503e3c655d064ef5009335 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompactAverages.lean @@ -0,0 +1,95 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Compact unitary averaging of Hochschild cochains. -/ + +noncomputable section + +namespace BoundedHochschild +open Filter Topology MeasureTheory MeasureTheory.Measure +variable {M : Type*} [CStarAlgebra M] + +lemma continuous_translateLast {n : ℕ} (f : Cochain M (n+1)) : + Continuous (translateLast f) := by + let A : unitary M → (Fin (n+1) → M →L[ℂ] M) := fun u i => + if i=Fin.last n then (ContinuousLinearMap.mul ℂ M).flip (u:M) + else ContinuousLinearMap.id ℂ M + have hA : Continuous A := by + apply continuous_pi + intro i + by_cases hi : i=Fin.last n + · simp only [A,ite_eq_left hi] + fun_prop + · simp only [A,ite_eq_right hi] + exact continuous_const + change Continuous fun u : unitary M => + (ContinuousLinearMap.compContinuousMultilinearMapL ℂ (fun _ : Fin (n+1) => M) M M) + ((ContinuousLinearMap.mul ℂ M).flip (star (u:M))) + ((ContinuousMultilinearMap.compContinuousLinearMapLRight f) (A u)) + exact ((ContinuousLinearMap.compContinuousMultilinearMapL ℂ (fun _ : Fin (n+1) => M) M M).continuous.comp + ((ContinuousLinearMap.mul ℂ M).flip.continuous.comp continuous_subtype_val.star)).clm_apply + ((ContinuousMultilinearMap.compContinuousLinearMapLRight (E:=fun _ : Fin (n+1) => M) f).cont.comp hA) + +section Compact +variable {G : Type*} [Group G] [TopologicalSpace G] [IsTopologicalGroup G] + [CompactSpace G] [T2Space G] [MeasurableSpace G] [BorelSpace G] +variable (ρ : G →* unitary M) (hρ : Continuous ρ) +variable (μ : Measure G) [IsProbabilityMeasure μ] [IsMulLeftInvariant μ] + +include hρ in +omit [IsTopologicalGroup G] [T2Space G] [IsMulLeftInvariant μ] in +lemma integrable_translateLast {n : ℕ} (f : Cochain M (n+1)) : + Integrable (fun u => translateLast f (ρ u)) μ := + ((continuous_translateLast f).comp hρ).integrable_of_hasCompactSupport + (HasCompactSupport.of_compactSpace _) + +def compactAverage {n : ℕ} (f : Cochain M (n+1)) : Cochain M (n+1) := + ∫ u, translateLast f (ρ u) ∂μ + +omit [TopologicalSpace G] [IsTopologicalGroup G] [CompactSpace G] [T2Space G] + [BorelSpace G] [IsMulLeftInvariant μ] in +lemma norm_compactAverage_le {n : ℕ} (f : Cochain M (n+1)) : + ‖compactAverage ρ μ f‖≤‖f‖ := by + simpa [compactAverage] using norm_integral_le_of_norm_le_const + (μ:=μ) (ae_of_all _ (fun u => norm_translateLast_le f (ρ u))) + +include hρ in +omit [T2Space G] in +lemma compactAverage_fixed {n : ℕ} (f : Cochain M (n+1)) (v : G) : + translateLast (compactAverage ρ μ f) (ρ v)=compactAverage ρ μ f := by + change (translateLastCLM (ρ v)) (∫ u, translateLast f (ρ u) ∂μ)=_ + rw [← (translateLastCLM (ρ v)).integral_comp_comm (integrable_translateLast ρ hρ μ f)] + change (∫ u, translateLast (translateLast f (ρ u)) (ρ v) ∂μ)=_ + simp only [translateLast_mul,← map_mul] + exact integral_mul_left_eq_self (μ:=μ) (fun u => translateLast f (ρ u)) v + +include hρ in +omit [IsTopologicalGroup G] [T2Space G] [IsMulLeftInvariant μ] in +lemma compactAverage_residual {n : ℕ} (F : Cochain M (n+1)) + (c : (Fin (n+1) → M) → M) + (hr : ∀ v x, residualCLM x (translateLast F v)=c x) : + ∀ v x, residualCLM x (translateLast (compactAverage ρ μ F) v)=c x := by + intro v x + let L : Cochain M (n+1) →L[ℂ] M := (residualCLM x).comp (translateLastCLM v) + change L (∫ u, translateLast F (ρ u) ∂μ)=c x + rw [← L.integral_comp_comm (integrable_translateLast ρ hρ μ F)] + have he (u : G) : L (translateLast F (ρ u))=c x := by + change residualCLM x (translateLast (translateLast F (ρ u)) v)=c x + rw [translateLast_mul,hr] + simp [he] + +end Compact +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompactConvexCenter.lean b/lean/OAI/Analysis/BoundedHochschild/CompactConvexCenter.lean new file mode 100644 index 0000000000000000000000000000000000000000..60a0807d9dcc85e530dd30d39e03b096335e2992 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompactConvexCenter.lean @@ -0,0 +1,75 @@ +import Mathlib.Analysis.Normed.Module.Convex +import Mathlib.Analysis.Convex.Combination +import Mathlib.Analysis.Complex.Basic +import Mathlib.Topology.Order.Compact + +namespace OAI + +/-! A compact nontrivial set has a convex average strictly closer than its diameter. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {E : Type u} [NormedAddCommGroup E] [NormedSpace ℂ E] + +/-- The elementary normal-structure argument needed for the isometric +fixed-point theorem. -/ +theorem compact_convex_center (K : Set E) (hK : IsCompact K) (hnt : K.Nontrivial) : + ∃ z ∈ convexHull ℝ K, ∃ r : ℝ, r < Metric.diam K ∧ + ∀ y ∈ K, ‖z - y‖ ≤ r := by + classical + have hne : K.Nonempty := hnt.nonempty + have hD : 0 < Metric.diam K := Metric.diam_pos hnt hK.isBounded + obtain ⟨s, hs⟩ := hK.elim_finite_subcover + (fun x : K => Metric.ball x.val (Metric.diam K)) + (fun _ => Metric.isOpen_ball) (fun x hx => + Set.mem_iUnion.mpr ⟨⟨x, hx⟩, Metric.mem_ball_self hD⟩) + have hsne : s.Nonempty := by + obtain ⟨y, hy⟩ := hne + obtain ⟨x, hxs, _⟩ := Set.mem_iUnion₂.mp (hs hy) + exact ⟨x, hxs⟩ + have hN : 0 < (s.card : ℝ) := by exact_mod_cast Finset.card_pos.mpr hsne + let z : E := s.centerMass (fun _ => (1 : ℝ)) (fun x => x.val) + have hz : z ∈ convexHull ℝ K := by + apply s.centerMass_mem_convexHull (fun _ _ => zero_le_one) _ (fun x _ => x.property) + simpa using hN + have hzclose (y : E) (hy : y ∈ K) : ‖z - y‖ < Metric.diam K := by + obtain ⟨a, has, hay⟩ := Set.mem_iUnion₂.mp (hs hy) + have hsum : (∑ x ∈ s, ‖x.val - y‖) < (s.card : ℝ) * Metric.diam K := by + calc + (∑ x ∈ s, ‖x.val - y‖) < ∑ _x ∈ s, Metric.diam K := by + apply Finset.sum_lt_sum + · intro x _ + simpa only [dist_eq_norm] using Metric.dist_le_diam_of_mem hK.isBounded x.property hy + · refine ⟨a, has, ?_⟩ + simpa only [Metric.mem_ball, dist_eq_norm, norm_sub_rev] using hay + _ = (s.card : ℝ) * Metric.diam K := by simp + have heq : z - y = (s.card : ℝ)⁻¹ • ∑ x ∈ s, (x.val - y) := by + dsimp [z, Finset.centerMass] + simp only [Finset.sum_const, nsmul_eq_mul, mul_one, one_smul, Finset.sum_sub_distrib, + smul_sub] + rw [← Nat.cast_smul_eq_nsmul ℝ, smul_smul, inv_mul_cancel₀ hN.ne', one_smul] + rw [heq, norm_smul, Real.norm_eq_abs, abs_of_pos (inv_pos.mpr hN)] + calc + (s.card : ℝ)⁻¹ * ‖∑ x ∈ s, (x.val - y)‖ ≤ + (s.card : ℝ)⁻¹ * ∑ x ∈ s, ‖x.val - y‖ := + mul_le_mul_of_nonneg_left (norm_sum_le _ _) (inv_nonneg.mpr hN.le) + _ < (s.card : ℝ)⁻¹ * ((s.card : ℝ) * Metric.diam K) := + mul_lt_mul_of_pos_left hsum (inv_pos.mpr hN) + _ = Metric.diam K := by rw [← mul_assoc, inv_mul_cancel₀ hN.ne', one_mul] + obtain ⟨y, hy, hmax⟩ := hK.exists_isMaxOn hne + (show ContinuousOn (fun y : E => ‖z - y‖) K from (continuous_const.sub continuous_id).norm.continuousOn) + exact ⟨z, hz, ‖z - y‖, hzclose y hy, fun a ha => hmax ha⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompactFamilyAverages.lean b/lean/OAI/Analysis/BoundedHochschild/CompactFamilyAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..f29241701ba541fbc5cb8dfe0188f5357c95c2d1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompactFamilyAverages.lean @@ -0,0 +1,59 @@ +import OAI.Analysis.BoundedHochschild.FiniteModuleAverages + +namespace OAI + +/-! Compactness and restriction of joint averaging orbits. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {I J : Type*} + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma weakFamilyAverageOrbit_component (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) (i : I) {F : I → M → WeakDual ℂ X} + (hF : F ∈ weakFamilyAverageOrbit e T) : F i ∈ weakRightAverageOrbit e (T i) := by + have hc : IsClosed {G : I → M → WeakDual ℂ X | G i ∈ weakRightAverageOrbit e (T i)} := + isClosed_closure.preimage (continuous_apply i) + apply closure_minimal _ hc hF + rintro G ⟨k, m, hm, rfl⟩ + exact subset_closure ⟨_, finiteRightAverage_mem_orbit m hm _, rfl⟩ + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma weakFamilyAverageOrbit_nonempty (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) : (weakFamilyAverageOrbit e T).Nonempty := by + refine ⟨_, subset_closure ⟨1, (fun _ : Fin 1 => (1 : M)), by simp, rfl⟩⟩ + +theorem weakFamilyAverageOrbit_isCompact (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (T : I → M →L[ℂ] M) (C : I → ℝ) + (hT : ∀ i, CompletelyBoundedEstimate (T i) (C i)) : + IsCompact (weakFamilyAverageOrbit e T) := + (isCompact_pi_infinite (fun i => weakRightAverageOrbit_isCompact e hno (T i) (hT i))).of_isClosed_subset + isClosed_closure (fun _ hF i => weakFamilyAverageOrbit_component e T i hF) + +theorem weakFamilyAverageOrbit_restriction_lift (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (T : I → M →L[ℂ] M) (C : I → ℝ) + (hT : ∀ i, CompletelyBoundedEstimate (T i) (C i)) (f : J → I) + {F : J → M → WeakDual ℂ X} (hF : F ∈ weakFamilyAverageOrbit e (T ∘ f)) : + ∃ G ∈ weakFamilyAverageOrbit e T, G ∘ f = F := by + let r (G : I → M → WeakDual ℂ X) : J → M → WeakDual ℂ X := G ∘ f + have hc : Continuous r := continuous_pi (fun j => continuous_apply (f j)) + have hclosed : IsClosed (r '' weakFamilyAverageOrbit e T) := + ((weakFamilyAverageOrbit_isCompact e hno T C hT).image hc).isClosed + have hsub : finiteFamilyAverageOrbit e (T ∘ f) ⊆ r '' weakFamilyAverageOrbit e T := by + rintro G ⟨k, m, hm, rfl⟩ + refine ⟨fun i => weakOperatorImage e (finiteRightAverage m (T i)), + subset_closure ⟨k, m, hm, rfl⟩, rfl⟩ + exact closure_minimal hsub hclosed hF + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompactInvariantSets.lean b/lean/OAI/Analysis/BoundedHochschild/CompactInvariantSets.lean new file mode 100644 index 0000000000000000000000000000000000000000..053e1dc155106f6d208a014bf68185f89676bf3a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompactInvariantSets.lean @@ -0,0 +1,94 @@ +import Mathlib.Topology.Compactness.Compact +import Mathlib.Order.Zorn +import Mathlib.Topology.Separation.Hausdorff + +namespace OAI + +/-! Minimal compact invariant subsets and their open covers. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u v + +variable {A : Type u} [TopologicalSpace A] [T2Space A] +variable {G : Type v} [Group G] + +omit [Group G] in +/-- A nonempty compact invariant set contains a minimal nonempty closed +invariant subset. -/ +theorem exists_minimal_compact_invariant (T : G → A → A) + (C : Set A) (hC : IsCompact C) (hne : C.Nonempty) + (hinv : ∀ g, Set.MapsTo (T g) C C) : + ∃ K : Set A, K ⊆ C ∧ K.Nonempty ∧ IsClosed K ∧ + (∀ g, Set.MapsTo (T g) K K) ∧ + ∀ L : Set A, L ⊆ K → L.Nonempty → IsClosed L → + (∀ g, Set.MapsTo (T g) L L) → K ⊆ L := by + classical + let S : Set (Set A) := {K | K ⊆ C ∧ K.Nonempty ∧ IsClosed K ∧ + ∀ g, Set.MapsTo (T g) K K} + have hCS : C ∈ S := ⟨Set.Subset.rfl, hne, hC.isClosed, hinv⟩ + obtain ⟨K, hKC, hK⟩ := zorn_superset_nonempty S (fun c hc hchain hcne => by + have : Nonempty c := hcne.to_subtype + have hn : (⋂₀ c).Nonempty := + IsCompact.nonempty_sInter_of_directed_nonempty_isCompact_isClosed + (fun L hL J hJ => by + rcases hchain.total hL hJ with h | h + · exact ⟨L, hL, Set.Subset.rfl, h⟩ + · exact ⟨J, hJ, h, Set.Subset.rfl⟩) + (fun L hL => (hc hL).2.1) + (fun L hL => hC.of_isClosed_subset (hc hL).2.2.1 (hc hL).1) + (fun L hL => (hc hL).2.2.1) + refine ⟨⋂₀ c, ⟨?_, hn, ?_, ?_⟩, fun L hL => Set.sInter_subset_of_mem hL⟩ + · obtain ⟨L, hL⟩ := hcne + exact (Set.sInter_subset_of_mem hL).trans (hc hL).1 + · exact isClosed_sInter (fun L hL => (hc hL).2.2.1) + · intro g x hx + apply Set.mem_sInter.mpr + intro L hL + exact (hc hL).2.2.2 g (Set.mem_sInter.mp hx L hL)) C hCS + refine ⟨K, hKC, hK.1.2.1, hK.1.2.2.1, hK.1.2.2.2, ?_⟩ + intro L hLK hLn hLc hLi + exact hK.2 ⟨hLK.trans hKC, hLn, hLc, hLi⟩ hLK + +omit [T2Space A] in +/-- Every orbit in a minimal compact invariant set meets each nonempty +relatively open part of that set. -/ +theorem minimal_invariant_open_cover (T : G → A → A) + (hcont : ∀ g, Continuous (T g)) + (hone : ∀ x, T 1 x = x) (hmul : ∀ g h x, T (g * h) x = T g (T h x)) + (K : Set A) (hKc : IsClosed K) (hinv : ∀ g, Set.MapsTo (T g) K K) + (hmin : ∀ L : Set A, L ⊆ K → L.Nonempty → IsClosed L → + (∀ g, Set.MapsTo (T g) L L) → K ⊆ L) + (U : Set A) (hU : IsOpen U) (hne : (K ∩ U).Nonempty) : + K ⊆ ⋃ g, (T g) ⁻¹' U := by + classical + intro x hx + by_contra hnot + have hxnone : ∀ g, T g x ∉ U := by simpa only [Set.mem_iUnion, Set.mem_preimage, not_exists] using hnot + let L : Set A := K ∩ ⋂ g, (T g) ⁻¹' Uᶜ + have hLK : L ⊆ K := Set.inter_subset_left + have hLn : L.Nonempty := ⟨x, hx, Set.mem_iInter.mpr hxnone⟩ + have hLc : IsClosed L := hKc.inter (isClosed_iInter (fun g => hU.isClosed_compl.preimage (hcont g))) + have hLi : ∀ g, Set.MapsTo (T g) L L := by + intro g y hy + refine ⟨hinv g hy.1, Set.mem_iInter.mpr (fun h => ?_)⟩ + change T h (T g y) ∉ U + rw [← hmul] + exact Set.mem_iInter.mp hy.2 (h * g) + obtain ⟨y, hyK, hyU⟩ := hne + have hyL := hmin L hLK hLn hLc hLi hyK + have hyout := Set.mem_iInter.mp hyL.2 1 + apply hyout + simpa only [hone] using hyU + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompleteAdditivity.lean b/lean/OAI/Analysis/BoundedHochschild/CompleteAdditivity.lean new file mode 100644 index 0000000000000000000000000000000000000000..fd26e92e56b27e2913f01ddc0ccfab2b915c62cf --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompleteAdditivity.lean @@ -0,0 +1,142 @@ +import OAI.Analysis.BoundedHochschild.ProjectionPositivity + +namespace OAI + +/-! +# Complete additivity on orthogonal projections + +This is the complete-additivity condition of Ringrose, Section 4 (Takesaki's +normality criterion), expressed through the net of finite partial sums. +-/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Preservation of arbitrary orthogonal projection sums. The index universe +need only contain the set of projections of the algebra. -/ +def CompletelyAdditive (F : StrongDual ℂ M) : Prop := + ∀ (I : Type u) (p : I → M), (∀ i, IsStarProjection (p i)) → + (∀ i j, i ≠ j → p i * p j = 0) → + ∀ P : M, IsStarProjection P → (∀ i, p i ≤ P) → + (∀ r : M, IsStarProjection r → (∀ i, p i ≤ r) → P ≤ r) → + Tendsto (fun s : Finset I => ∑ i ∈ s, F (p i)) atTop (𝓝 (F P)) + +lemma normal_completelyAdditive (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {F : StrongDual ℂ M} (hF : F ∈ normalDual e) : CompletelyAdditive F := by + classical + intro I p hp horth P hP hu hl + obtain ⟨Q, hQ, hqu, hql, ht⟩ := exists_orthogonal_projection_sum e p hp horth + have hQP : Q = P := le_antisymm (hql P hP hu) (hl Q hQ hqu) + subst Q + obtain ⟨z, hz⟩ := (mem_normalDual e F).mp hF + have hconv : Tendsto (fun s : Finset I => F (∑ i ∈ s, p i)) atTop (𝓝 (F P)) := by + simpa only [hz] using (ht z).star + simpa only [map_sum] using hconv + +omit [StarOrderedRing M] in +lemma CompletelyAdditive.add {F G : StrongDual ℂ M} (hF : CompletelyAdditive F) + (hG : CompletelyAdditive G) : CompletelyAdditive (F + G) := by + classical + intro I p hp ho P hP hu hl + simpa only [add_apply, Finset.sum_add_distrib] using + (hF I p hp ho P hP hu hl).add (hG I p hp ho P hP hu hl) + +omit [StarOrderedRing M] in +lemma CompletelyAdditive.sub {F G : StrongDual ℂ M} (hF : CompletelyAdditive F) + (hG : CompletelyAdditive G) : CompletelyAdditive (F - G) := by + classical + intro I p hp ho P hP hu hl + simpa only [sub_apply, Finset.sum_sub_distrib] using + (hF I p hp ho P hP hu hl).sub (hG I p hp ho P hP hu hl) + +/-- A completely additive hermitian functional has a maximal positive +projection corner inside any given projection (Ringrose, Lemma 4.1). Here +positivity is first recorded on subprojections. -/ +theorem exists_nonnegative_projection_corner (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (F : StrongDual ℂ M) (hF : CompletelyAdditive F) {E : M} (hE : IsStarProjection E) : + ∃ p : M, IsStarProjection p ∧ p ≤ E ∧ (F E).re ≤ (F p).re ∧ + ∀ q : M, IsStarProjection q → q ≤ p → 0 ≤ (F q).re := by + classical + let A : Set (Set M) := {S | (∀ p ∈ S, IsStarProjection p ∧ p ≤ E ∧ (F p).re < 0) ∧ + ∀ p ∈ S, ∀ q ∈ S, p ≠ q → p * q = 0} + obtain ⟨S, hS⟩ := zorn_subset A (fun c hc hchain => by + refine ⟨⋃₀ c, ⟨?_, ?_⟩, fun s hs => Set.subset_sUnion_of_mem hs⟩ + · intro p hp + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + exact (hc hs).1 p hps + · intro p hp q hq hpq + obtain ⟨s, hs, hps⟩ := Set.mem_sUnion.mp hp + obtain ⟨t, ht, hqt⟩ := Set.mem_sUnion.mp hq + rcases hchain.total hs ht with hst | hts + · exact (hc ht).2 p (hst hps) q hqt hpq + · exact (hc hs).2 p hps q (hts hqt) hpq) + let f : S → M := Subtype.val + have hp (i : S) : IsStarProjection (f i) := (hS.1.1 i i.property).1 + have ho (i j : S) (hij : i ≠ j) : f i * f j = 0 := + hS.1.2 i i.property j j.property (fun h => hij (Subtype.ext h)) + obtain ⟨P, hP, hPu, hPl, _⟩ := exists_orthogonal_projection_sum e f hp ho + have hPE : P ≤ E := hPl E hE (fun i => (hS.1.1 i i.property).2.1) + have hsum := hF S f hp ho P hP hPu hPl + have hPneg : (F P).re ≤ 0 := by + apply le_of_tendsto (Complex.continuous_re.tendsto _ |>.comp hsum) + apply Eventually.of_forall + intro s + change (∑ i ∈ s, F (f i)).re ≤ 0 + change Complex.reCLM (∑ i ∈ s, F (f i)) ≤ 0 + rw [map_sum] + exact Finset.sum_nonpos (fun i _ => (hS.1.1 i i.property).2.2.le) + have hEP : IsStarProjection (E - P) := (hP.le_iff_sub hE).mp hPE + refine ⟨E - P, hEP, ?_, ?_, ?_⟩ + · exact sub_le_self E hP.nonneg + · rw [map_sub, Complex.sub_re] + linarith + · intro q hq hqEP + by_contra hqneg + have hqn : (F q).re < 0 := lt_of_not_ge hqneg + have hqE : q ≤ E := hqEP.trans (sub_le_self E hP.nonneg) + have hPq : P * q = 0 := HochschildCentralComparison.orthogonal_of_le_sub hE hP hq hPE hqEP + have hfq (i : S) : f i * q = 0 := by + calc + f i * q = (f i * P) * q := by rw [((hp i).le_iff_mul_eq_left hP).mp (hPu i)] + _ = 0 := by rw [mul_assoc, hPq, mul_zero] + have hqf (i : S) : q * f i = 0 := by + simpa only [star_mul, (hp i).isSelfAdjoint.star_eq, hq.isSelfAdjoint.star_eq, + star_zero] using congrArg star (hfq i) + have hnew : insert q S ∈ A := by + constructor + · intro a ha + rcases Set.mem_insert_iff.mp ha with rfl | ha + · exact ⟨hq, hqE, hqn⟩ + · exact hS.1.1 a ha + · intro a ha b hb hab + rcases Set.mem_insert_iff.mp ha with har | ha + · subst a + rcases Set.mem_insert_iff.mp hb with hbr | hb + · exact (hab hbr.symm).elim + · exact hqf ⟨b, hb⟩ + · rcases Set.mem_insert_iff.mp hb with hbr | hb + · subst b + exact hfq ⟨a, ha⟩ + · exact hS.1.2 a ha b hb hab + have hsubset : insert q S ⊆ S := hS.2 hnew (Set.subset_insert q S) + have hqin : q ∈ S := hsubset (Set.mem_insert q S) + have hq0 : q = 0 := by simpa only [f, hq.isIdempotentElem.eq] using hfq ⟨q, hqin⟩ + simp only [hq0, map_zero, Complex.zero_re, lt_self_iff_false] at hqn + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedArithmetic.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedArithmetic.lean new file mode 100644 index 0000000000000000000000000000000000000000..8d5fda721a033e90811caa19c8a56de9518916f8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedArithmetic.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.MatrixRightAveraging + +namespace OAI + +/-! Finite linear combinations and left multiplication in the input and +output preserve the complete bounds needed to combine finitely many maps. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma completelyBounded_add {T U : M →L[ℂ] M} {C D : ℝ} + (hT : CompletelyBoundedEstimate T C) (hU : CompletelyBoundedEstimate U D) : + CompletelyBoundedEstimate (T + U) (C + D) := by + refine ⟨add_nonneg hT.1 hU.1, fun n A => ?_⟩ + have he : A.map (T + U) = A.map T + A.map U := by ext i j; rfl + rw [he] + exact (norm_add_le _ _).trans (by linarith [hT.2 n A, hU.2 n A]) + +lemma completelyBounded_sum {I : Type*} [Fintype I] + (T : I → M →L[ℂ] M) (C : I → ℝ) (hT : ∀ i, CompletelyBoundedEstimate (T i) (C i)) : + CompletelyBoundedEstimate (∑ i, T i) (∑ i, C i) := by + classical + refine ⟨Finset.sum_nonneg (fun i _ => (hT i).1), fun n A => ?_⟩ + have he : A.map (∑ i, T i : M →L[ℂ] M) = ∑ i, A.map (T i) := by + ext j k + simp only [CStarMatrix.map_apply, sum_apply, cstar_finite_sum_apply] + rw [he] + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_mul] using Finset.sum_le_sum (fun i _ => (hT i).2 n A)) + +def leftSandwichMap (a b : M) (T : M →L[ℂ] M) : M →L[ℂ] M := + (ContinuousLinearMap.mul ℂ M a).comp (T.comp (ContinuousLinearMap.mul ℂ M b)) + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma leftSandwichMap_apply (a b : M) (T : M →L[ℂ] M) (x : M) : + leftSandwichMap a b T x = a * T (b * x) := rfl + +omit [PartialOrder M] [StarOrderedRing M] in +lemma matrix_scalar_mul_apply {n : ℕ} (a : M) (A : CStarMatrix (Fin n) (Fin n) M) + (i j : Fin n) : (matrixScalarHom n a * A) i j = a * A i j := by + simp only [CStarMatrix.mul_apply, matrixScalarHom_apply, ite_mul, zero_mul] + simp + +lemma completelyBounded_leftSandwich (a b : M) {T : M →L[ℂ] M} {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : + CompletelyBoundedEstimate (leftSandwichMap a b T) (‖a‖ * C * ‖b‖) := by + refine ⟨mul_nonneg (mul_nonneg (norm_nonneg _) hT.1) (norm_nonneg _), fun n A => ?_⟩ + have he : A.map (leftSandwichMap a b T) = + matrixScalarHom n a * ((matrixScalarHom n b * A).map T) := by + ext i j + simp only [CStarMatrix.map_apply, leftSandwichMap_apply, matrix_scalar_mul_apply] + rw [he] + have ha : ‖matrixScalarHom n a‖ ≤ ‖a‖ := NonUnitalStarAlgHom.norm_apply_le _ _ + have hb : ‖matrixScalarHom n b‖ ≤ ‖b‖ := NonUnitalStarAlgHom.norm_apply_le _ _ + calc + _ ≤ ‖matrixScalarHom n a‖ * ‖(matrixScalarHom n b * A).map T‖ := norm_mul_le _ _ + _ ≤ ‖a‖ * (C * (‖b‖ * ‖A‖)) := by + apply mul_le_mul ha _ (norm_nonneg _) (norm_nonneg _) + exact (hT.2 n _).trans (mul_le_mul_of_nonneg_left + ((norm_mul_le _ _).trans (mul_le_mul_of_nonneg_right hb (norm_nonneg _))) hT.1) + _ = _ := by ring + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedFactorization.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedFactorization.lean new file mode 100644 index 0000000000000000000000000000000000000000..06bfa96a888ba3416044ac3daf5ef432256d4283 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedFactorization.lean @@ -0,0 +1,121 @@ +import OAI.Analysis.BoundedHochschild.PaulsenEntries +import OAI.Analysis.BoundedHochschild.StinespringEmbedding + +namespace OAI + +/-! Factor a completely contractive map through an actual star representation. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +open HochschildMatrixDilation + +universe u v +variable {A : Type u} {H : Type v} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +structure OperatorFactorization (T : A →ₗ[ℂ] (H →L[ℂ] H)) (C : ℝ) where + K : Type (max u v) + [normed : NormedAddCommGroup K] + [innerSpace : InnerProductSpace ℂ K] + [complete : CompleteSpace K] + representation : A →⋆ₐ[ℂ] (K →L[ℂ] K) + leftMap : H →L[ℂ] K + rightMap : H →L[ℂ] K + bound : ‖leftMap‖ * ‖rightMap‖ ≤ C + factorization : ∀ a, T a = leftMap.adjoint.comp ((representation a).comp rightMap) + +attribute [instance] OperatorFactorization.normed OperatorFactorization.innerSpace + OperatorFactorization.complete + +variable [Nontrivial A] [Nontrivial H] + +theorem factorization_of_complete_contraction (T : A →ₗ[ℂ] (H →L[ℂ] H)) + (hT : ∀ n (X : CStarMatrix (Fin n) (Fin n) A), ‖X.map T‖ ≤ ‖X‖) : + Nonempty (OperatorFactorization T 1) := by + obtain ⟨f, hf, _⟩ := NaimarkZFC.exists_norming_state (1 : A) + have hf1 : f 1 = 1 := ((NaimarkZFC.isState_iff f).mp hf).1 + obtain ⟨Φ, hΦ1, hΦ⟩ := exists_paulsen_extension f.toLinearMap hf1 T hT + let V := stinespringEmbedding Φ + let π := (stinespringRepresentation Φ).comp (matrixScalarHom 2) + let J₀ := (doubleCoordinate (H := H) 0).toContinuousLinearMap + let J₁ := (doubleCoordinate (H := H) 1).toContinuousLinearMap + let E := singleCStarMatrix (0 : Fin 2) 1 (1 : A) + let L := V.comp J₀ + let R := (stinespringRepresentation Φ E).comp (V.comp J₁) + have hV : ‖V‖ ≤ 1 := by + simpa only [V, hΦ1, CStarRing.norm_one, Real.sqrt_one] using stinespringEmbedding_norm_le Φ + have hJ (i : Fin 2) : ‖(doubleCoordinate (H := H) i).toContinuousLinearMap‖ ≤ 1 := by + apply ContinuousLinearMap.opNorm_le_bound _ zero_le_one + intro ξ + simp + have hL : ‖L‖ ≤ 1 := by + exact (ContinuousLinearMap.opNorm_comp_le V J₀).trans + (by simpa only [one_mul] using mul_le_mul hV (hJ 0) (norm_nonneg J₀) zero_le_one) + have hR : ‖R‖ ≤ 1 := by + have hE : ‖stinespringRepresentation Φ E‖ ≤ 1 := + (NonUnitalStarAlgHom.norm_apply_le _ _).trans single_offDiagonal_norm_le_one + have hVJ : ‖V.comp J₁‖ ≤ 1 := (ContinuousLinearMap.opNorm_comp_le _ _).trans + (by simpa only [one_mul] using mul_le_mul hV (hJ 1) (norm_nonneg J₁) zero_le_one) + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + (by simpa only [one_mul] using mul_le_mul hE hVJ (norm_nonneg (V.comp J₁)) zero_le_one) + refine ⟨{ + K := StinespringSpace Φ + representation := π + leftMap := L + rightMap := R + bound := ?_ + factorization := ?_ }⟩ + · simpa only [one_mul] using mul_le_mul hL hR (norm_nonneg R) zero_le_one + · intro a + rw [← paulsenExtension_entry f.toLinearMap T Φ hΦ a, stinespring_factorization, + single_offDiagonal_factor a, map_mul] + dsimp only [L, R, π, V, E, StarAlgHom.comp_apply] + rw [ContinuousLinearMap.adjoint_comp] + rfl + +theorem factorization_of_complete_bound (T : A →ₗ[ℂ] (H →L[ℂ] H)) + {C : ℝ} (hC : 0 < C) + (hT : ∀ n (X : CStarMatrix (Fin n) (Fin n) A), ‖X.map T‖ ≤ C * ‖X‖) : + Nonempty (OperatorFactorization T C) := by + let U : A →ₗ[ℂ] (H →L[ℂ] H) := (C : ℂ)⁻¹ • T + have hU : ∀ n (X : CStarMatrix (Fin n) (Fin n) A), ‖X.map U‖ ≤ ‖X‖ := by + intro n X + have he : X.map U = (C : ℂ)⁻¹ • X.map T := by + apply CStarMatrix.ext + intro i j + rfl + rw [he, norm_smul, norm_inv, Complex.norm_real, Real.norm_eq_abs, abs_of_pos hC] + calc + C⁻¹ * ‖X.map T‖ ≤ C⁻¹ * (C * ‖X‖) := + mul_le_mul_of_nonneg_left (hT n X) (inv_nonneg.mpr hC.le) + _ = ‖X‖ := by rw [← mul_assoc, inv_mul_cancel₀ hC.ne', one_mul] + obtain ⟨F⟩ := factorization_of_complete_contraction U hU + refine ⟨{ + K := F.K + representation := F.representation + leftMap := F.leftMap + rightMap := (C : ℂ) • F.rightMap + bound := ?_ + factorization := ?_ }⟩ + · rw [norm_smul, Complex.norm_real, Real.norm_eq_abs, abs_of_pos hC] + calc + ‖F.leftMap‖ * (C * ‖F.rightMap‖) = C * (‖F.leftMap‖ * ‖F.rightMap‖) := by ring + _ ≤ C * 1 := mul_le_mul_of_nonneg_left F.bound hC.le + _ = C := mul_one C + · intro a + calc + T a = (C : ℂ) • U a := by simp [U, hC.ne'] + _ = F.leftMap.adjoint.comp + ((F.representation a).comp ((C : ℂ) • F.rightMap)) := by + rw [F.factorization] + simp only [ContinuousLinearMap.comp_smul] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedLastSlices.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedLastSlices.lean new file mode 100644 index 0000000000000000000000000000000000000000..9fad4026cc1a90c5fbb8deba533a4536c64352be --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedLastSlices.lean @@ -0,0 +1,97 @@ +import OAI.Analysis.BoundedHochschild.RightModuleProjection +import OAI.Analysis.BoundedHochschild.Cochains + +namespace OAI + +/-! Uniformly completely bounded last slices and their module-averaged +primitive. Only the last variable needs a complete bound for this step. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +def LastSliceEstimate {n : ℕ} (f : Cochain M (n + 1)) (C : ℝ) : Prop := + 0 ≤ C ∧ ∀ v : Fin n → M, + CompletelyBoundedEstimate (f.curryRight v) (C * ∏ i, ‖v i‖) + +def cbCurryRight {n : ℕ} (f : Cochain M (n + 1)) {C : ℝ} + (hf : LastSliceEstimate f C) : + MultilinearMap ℂ (fun _ : Fin n => M) (CompletelyBoundedMap M) := + f.curryRight.toMultilinearMap.codRestrict completelyBoundedSubmodule + (fun v => ⟨C * ∏ i, ‖v i‖, hf.2 v⟩) + +@[simp] lemma cbCurryRight_val {n : ℕ} (f : Cochain M (n + 1)) {C : ℝ} + (hf : LastSliceEstimate f C) (v : Fin n → M) : + (cbCurryRight f hf v).val = f.curryRight v := rfl + +@[simp] lemma cbCurryRight_apply {n : ℕ} (f : Cochain M (n + 1)) {C : ℝ} + (hf : LastSliceEstimate f C) (v : Fin n → M) (u : M) : + (cbCurryRight f hf v).val u = f (Fin.snoc v u) := rfl + +@[simp] lemma cbLeftSandwich_apply (a b : M) (T : CompletelyBoundedMap M) (u : M) : + (cbLeftSandwich a b T).val u = a * T.val (b * u) := rfl + +def averagedLastMultilinear (P : RightModuleAveragingProjection (M := M)) + {n : ℕ} (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) : + MultilinearMap ℂ (fun _ : Fin n => M) M := + ((ContinuousLinearMap.apply ℂ M (1 : M)).toLinearMap.comp P.map).compMultilinearMap + (cbCurryRight f hf) + +@[simp] lemma averagedLastMultilinear_apply + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) (v : Fin n → M) : + averagedLastMultilinear P f hf v = P.map (cbCurryRight f hf v) 1 := rfl + +lemma averagedLastMultilinear_bound [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) (v : Fin n → M) : + ‖averagedLastMultilinear P f hf v‖ ≤ C * ∏ i, ‖v i‖ := by + rw [averagedLastMultilinear_apply] + calc + _ ≤ ‖P.map (cbCurryRight f hf v)‖ * ‖(1 : M)‖ := (P.map _).le_opNorm _ + _ = ‖P.map (cbCurryRight f hf v)‖ := by rw [norm_one, mul_one] + _ ≤ _ := P.bound _ _ (hf.2 v) + +def averagedLastCochain [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) : Cochain M n := + (averagedLastMultilinear P f hf).mkContinuous C (averagedLastMultilinear_bound P f hf) + +@[simp] lemma averagedLastCochain_apply [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) (v : Fin n → M) : + averagedLastCochain P f hf v = P.map (cbCurryRight f hf v) 1 := rfl + +lemma averagedLastCochain_norm [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hf : LastSliceEstimate f C) : + ‖averagedLastCochain P f hf‖ ≤ C := + MultilinearMap.mkContinuous_norm_le _ hf.1 _ + +lemma completelyBounded_id : + CompletelyBoundedEstimate (ContinuousLinearMap.id ℂ M) 1 := by + refine ⟨zero_le_one, fun n A => ?_⟩ + have h : A.map (ContinuousLinearMap.id ℂ M) = A := by ext i j; rfl + rw [h, one_mul] + +def cbIdentity : CompletelyBoundedMap M := + ⟨ContinuousLinearMap.id ℂ M, 1, completelyBounded_id⟩ + +def cbLeftMul (a : M) : CompletelyBoundedMap M := cbLeftSandwich a 1 cbIdentity + +@[simp] lemma cbLeftMul_apply (a x : M) : (cbLeftMul a).val x = a * x := by + simp [cbLeftMul, cbLeftSandwich, cbIdentity, leftSandwichMap] + +lemma moduleProjection_leftMul (P : RightModuleAveragingProjection (M := M)) + (a : M) : P.map (cbLeftMul a) = (cbLeftMul a).val := by + apply P.fixes + intro x y + simp only [cbLeftMul_apply, mul_assoc] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedMapSpace.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedMapSpace.lean new file mode 100644 index 0000000000000000000000000000000000000000..adb30f5e1643a07d88dd8df5374144ff3d2c82da --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedMapSpace.lean @@ -0,0 +1,57 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedArithmetic + +namespace OAI + +/-! The complex vector space of completely bounded maps. No completeness or +choice of a particular complete norm is needed for the averaging projection. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma completelyBounded_zero : CompletelyBoundedEstimate (0 : M →L[ℂ] M) 0 := by + refine ⟨le_rfl, fun n A => ?_⟩ + have he : A.map (0 : M →L[ℂ] M) = 0 := by ext i j; rfl + rw [he, norm_zero, zero_mul] + +lemma completelyBounded_smul (z : ℂ) {T : M →L[ℂ] M} {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : + CompletelyBoundedEstimate (z • T) (‖z‖ * C) := by + refine ⟨mul_nonneg (norm_nonneg z) hT.1, fun n A => ?_⟩ + have he : A.map (z • T) = z • A.map T := by ext i j; rfl + rw [he, norm_smul, mul_assoc] + exact mul_le_mul_of_nonneg_left (hT.2 n A) (norm_nonneg z) + +lemma completelyBounded_mono {T : M →L[ℂ] M} {C D : ℝ} + (hT : CompletelyBoundedEstimate T C) (hCD : C ≤ D) : CompletelyBoundedEstimate T D := + ⟨hT.1.trans hCD, fun n A => (hT.2 n A).trans + (mul_le_mul_of_nonneg_right hCD (norm_nonneg A))⟩ + +def completelyBoundedSubmodule : Submodule ℂ (M →L[ℂ] M) where + carrier := {T | ∃ C, CompletelyBoundedEstimate T C} + zero_mem' := ⟨0, completelyBounded_zero⟩ + add_mem' := by + rintro T U ⟨C, hC⟩ ⟨D, hD⟩ + exact ⟨C+D, completelyBounded_add hC hD⟩ + smul_mem' := by + rintro z T ⟨C, hC⟩ + exact ⟨‖z‖*C, completelyBounded_smul z hC⟩ + +abbrev CompletelyBoundedMap (M : Type*) [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] := + completelyBoundedSubmodule (M := M) + +def completelyBoundedBound (T : CompletelyBoundedMap M) : ℝ := Classical.choose T.property + +lemma completelyBoundedBound_spec (T : CompletelyBoundedMap M) : + CompletelyBoundedEstimate T.val (completelyBoundedBound T) := Classical.choose_spec T.property + +def cbLeftSandwich (a b : M) (T : CompletelyBoundedMap M) : CompletelyBoundedMap M := + ⟨leftSandwichMap a b T.val, _, completelyBounded_leftSandwich a b (completelyBoundedBound_spec T)⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..3b440d4230c88e1efd7d492f6abc1a6b2c6407c3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedPrimitives.lean @@ -0,0 +1,80 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedLastSlices + +namespace OAI + +/-! The module projection contracts the Hochschild complex on cochains with +uniformly completely bounded last slices. The argument is the one-sided +module homotopy underlying completely bounded cohomology vanishing. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma cb_cocycle_last_relation {n : ℕ} (f : Cochain M (n + 1)) {C : ℝ} + (hs : LastSliceEstimate f C) + (hf : ∀ x, differentialValue f x = 0) (v : Fin (n + 1) → M) : + cbLeftSandwich (v 0) 1 (cbCurryRight f hs (fun i => v i.succ)) + + (∑ j : Fin n, ((-1 : ℂ) ^ (j.val + 1)) • cbCurryRight f hs (mergeInputs v j)) + + ((-1 : ℂ) ^ (n + 1)) • + cbLeftSandwich 1 (v (Fin.last n)) (cbCurryRight f hs (fun i => v i.castSucc)) + + ((-1 : ℂ) ^ (n + 2)) • cbLeftMul (f v) = 0 := by + apply Subtype.ext + ext u + have h := hf (Fin.snoc v u) + rw [differentialValue_snoc] at h + simpa [cbLeftSandwich, leftSandwichMap, cbCurryRight_val] using h + +lemma averagedLastCochain_differential [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hs : LastSliceEstimate f C) + (hf : ∀ x, differentialValue f x = 0) (v : Fin (n + 1) → M) : + differentialValue (averagedLastCochain P f hs) v = + ((-1 : ℂ) ^ (n + 1)) • f v := by + have h := congrArg (fun T : CompletelyBoundedMap M => P.map T 1) + (cb_cocycle_last_relation f hs hf v) + simp only [map_add, map_sum, map_smul, add_apply, + sum_apply, smul_apply, + P.covariance, leftSandwichMap_apply, one_mul, mul_one, + moduleProjection_leftMul, cbLeftMul_apply, map_zero, zero_apply] at h + have hm := P.module (cbCurryRight f hs (fun i => v i.castSucc)) 1 (v (Fin.last n)) + rw [one_mul] at hm + rw [hm] at h + have hp : (-1 : ℂ) ^ (n + 2) = -((-1 : ℂ) ^ (n + 1)) := by + rw [show n + 2 = n + 1 + 1 by omega, pow_succ] + ring + rw [hp, neg_smul] at h + apply eq_of_sub_eq_zero + simpa only [differentialValue, averagedLastCochain_apply, sub_eq_add_neg] using h + +theorem primitive_of_lastSliceEstimate [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) {n : ℕ} + (f : Cochain M (n + 1)) {C : ℝ} (hs : LastSliceEstimate f C) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ C ∧ ∀ x, differentialValue g x = f x := by + let g := ((-1 : ℂ) ^ (n + 1)) • averagedLastCochain P f hs + refine ⟨g, ?_, fun x => ?_⟩ + · simpa only [g, norm_smul, norm_pow, norm_neg, norm_one, one_pow, one_mul] using + averagedLastCochain_norm P f hs + · change differentialValue (((-1 : ℂ) ^ (n + 1)) • averagedLastCochain P f hs) x = f x + rw [differentialValue_smul, averagedLastCochain_differential P f hs hf, + smul_smul, ← mul_pow, neg_mul_neg, one_mul, one_pow, one_smul] + +universe u +variable {N X : Type u} [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem properlyInfinite_primitive_of_lastSliceEstimate [Nontrivial N] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] N) (hno : NoFiniteCentralSummand N) {n : ℕ} + (f : Cochain N (n + 1)) {C : ℝ} (hs : LastSliceEstimate f C) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain N n, ‖g‖ ≤ C ∧ ∀ x, differentialValue g x = f x := by + obtain ⟨P⟩ := exists_rightModuleAveragingProjection e hno + exact primitive_of_lastSliceEstimate P f hs hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedRows.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedRows.lean new file mode 100644 index 0000000000000000000000000000000000000000..61e61b1cea602dae3c59924e5d7612f06b9f325b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyBoundedRows.lean @@ -0,0 +1,103 @@ +import OAI.Analysis.BoundedHochschild.FiniteRightAveraging + +namespace OAI + +/-! +# The finite-row consequence of complete boundedness + +The definition uses the usual entrywise amplifications on actual C*-matrix +algebras. In the properly infinite case, the proved isometry columns turn +this definition into precisely the row estimate needed for right averaging. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u + +variable {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +/-- A uniform bound on all entrywise matrix amplifications of a linear map. -/ +def CompletelyBoundedEstimate (T : M →L[ℂ] M) (C : ℝ) : Prop := + 0 ≤ C ∧ ∀ (n : ℕ) (A : CStarMatrix (Fin n) (Fin n) M), ‖A.map T‖ ≤ C * ‖A‖ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma left_isometry_norm {v : M} (hv : star v * v = 1) (a : M) : ‖v * a‖ = ‖a‖ := by + have h : star (v * a) * (v * a) = star a * a := by + rw [star_mul] + calc + _ = star a * (star v * v) * a := by simp only [mul_assoc] + _ = star a * a := by rw [hv, mul_one] + have hn : ‖v * a‖ ^ 2 = ‖a‖ ^ 2 := by + simpa only [CStarRing.norm_star_mul_self, ← sq] using congrArg norm h + nlinarith [norm_nonneg (v * a), norm_nonneg a] + +variable {n : ℕ} (c : Fin n → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + +omit [PartialOrder M] [StarOrderedRing M] in +include hi ho in +lemma columnRow_mul_isometry (x : Fin n → M) (j : Fin n) : + columnRow c x * (c j : M) = x j := by + classical + calc + _ = ∑ i, x i * (star (c i : M) * (c j : M)) := by + simp only [columnRow, Finset.sum_mul, mul_assoc] + _ = x j := by simp [column_star_mul c hi ho] + +omit [PartialOrder M] [StarOrderedRing M] in +include hi ho in +lemma columnCompression_row (x : Fin n → M) (k i j : Fin n) : + columnCompression c ((c k : M) * columnRow c x) i j = if i = k then x j else 0 := by + change star (c i : M) * ((c k : M) * columnRow c x) * (c j : M) = _ + calc + _ = (star (c i : M) * (c k : M)) * (columnRow c x * (c j : M)) := by + simp only [mul_assoc] + _ = _ := by rw [column_star_mul c hi ho, columnRow_mul_isometry c hi ho]; split_ifs <;> simp + +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Complete boundedness implies the finite-row estimate used by the module +projection, via the actual finite matrix amplifications already constructed. -/ +theorem finiteRowBound_of_completelyBounded (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : HasFiniteRowBound T C := by + refine ⟨hT.1, ?_⟩ + intro n x + cases n with + | zero => simp + | succ n => + obtain ⟨c, hi, ho, hs⟩ := exists_properlyInfinite_matrix_columns e hno (n + 1) + let k : Fin (n + 1) := ⟨0, Nat.zero_lt_succ n⟩ + have hmap : (columnCompression c ((c k : M) * columnRow c x)).map T = + columnCompression c ((c k : M) * columnRow c (fun i => T (x i))) := by + ext i j + rw [CStarMatrix.map_apply, columnCompression_row c hi ho, columnCompression_row c hi ho] + split_ifs <;> simp + have hb := hT.2 (n + 1) (columnCompression c ((c k : M) * columnRow c x)) + rw [hmap, columnCompression_norm c hi ho hs, columnCompression_norm c hi ho hs, + left_isometry_norm (hi k), left_isometry_norm (hi k)] at hb + have hb2 := pow_le_pow_left₀ (norm_nonneg _) hb 2 + rw [mul_pow, columnRow_norm_sq c hi ho, columnRow_norm_sq c hi ho] at hb2 + exact hb2 + +/-- The finite elementary averages in the module projection are bounded by +any complete bound for the original linear map. -/ +theorem finiteRightAverage_norm_of_completelyBounded + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (m : Fin (n + 1) → M) (hm : ∑ i, m i * star (m i) = 1) + (T : M →L[ℂ] M) {C : ℝ} (hT : CompletelyBoundedEstimate T C) : + ‖finiteRightAverage m T‖ ≤ C := by + obtain ⟨c, hi, ho, _⟩ := exists_properlyInfinite_matrix_columns e hno (n + 1) + exact finiteRightAverage_norm_of_rowBound c hi ho m hm T + (finiteRowBound_of_completelyBounded e hno T hT) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveCompression.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..38a6b6348adb6904c48fc52f7ec074f70d461beb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveCompression.lean @@ -0,0 +1,56 @@ +import OAI.Analysis.BoundedHochschild.PositiveKernelMatrices + +namespace OAI + +/-! Hilbert-space compression preserves complete positivity. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H K I : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] [Fintype I] + +lemma operatorMatrix_nonneg_of_quadratic + (B : CStarMatrix I I (H →L[ℂ] H)) + (hB : ∀ ξ : I → H, 0 ≤ ∑ i, ∑ j, inner ℂ (ξ i) (B i j (ξ j))) : 0 ≤ B := by + let ρ := WeakPureInfiniteness.matrixOperatorHom (n := I) (H := H) + apply (NonUnitalStarAlgHom.map_le_map_iff ρ + WeakPureInfiniteness.matrixOperator_injective).mp + rw [map_zero, ContinuousLinearMap.nonneg_iff_isPositive, + ContinuousLinearMap.isPositive_iff_complex] + intro ξ + have hp : 0 ≤ inner ℂ ξ (ρ B ξ) := by + change 0 ≤ inner ℂ ξ (WeakPureInfiniteness.matrixOperator B ξ) + simpa only [WeakPureInfiniteness.matrixOperator_apply, PiLp.inner_apply, inner_sum] + using hB ξ + have hq : 0 ≤ inner ℂ (ρ B ξ) ξ := by + rw [← inner_conj_symm (𝕜 := ℂ) (ρ B ξ) ξ] + exact star_nonneg_iff.mpr hp + exact ⟨Complex.ext (by simp) hq.2, hq.1⟩ + +def compressCompletelyPositive (φ : CompletelyPositiveMap A (K →L[ℂ] K)) + (V : H →L[ℂ] K) : CompletelyPositiveMap A (H →L[ℂ] H) where + toFun a := V.adjoint.comp ((φ a).comp V) + map_add' a b := by ext ξ; simp + map_smul' z a := by ext ξ; simp + map_cstarMatrix_nonneg' n B hB := by + apply operatorMatrix_nonneg_of_quadratic + intro ξ + change 0 ≤ ∑ i, ∑ j, inner ℂ (ξ i) (V.adjoint (φ (B i j) (V (ξ j)))) + simp only [ContinuousLinearMap.adjoint_inner_right] + exact operatorMatrix_quadratic_nonneg (B.map φ) (φ.map_cstarMatrix_nonneg B hB) + (fun i => V (ξ i)) + +@[simp] lemma compressCompletelyPositive_apply + (φ : CompletelyPositiveMap A (K →L[ℂ] K)) (V : H →L[ℂ] K) (a : A) : + compressCompletelyPositive φ V a = V.adjoint.comp ((φ a).comp V) := rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveLimits.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..2479e4ac6d4467ee209085cff210ecb8de497e88 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveLimits.lean @@ -0,0 +1,65 @@ +import OAI.Analysis.BoundedHochschild.CompletelyPositiveCompression +import OAI.Analysis.FactorGeneration.OperatorLimits + +namespace OAI + +/-! Bounded pointwise weak-operator ultralimits of completely positive maps. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H ι : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_completelyPositive_ultralimit (ω : Ultrafilter ι) + (φ : ι → CompletelyPositiveMap A (H →L[ℂ] H)) {C : ℝ} (hC : 0 ≤ C) + (hφ : ∀ i a, ‖φ i a‖ ≤ C * ‖a‖) : + ∃ Φ : CompletelyPositiveMap A (H →L[ℂ] H), + (∀ a, ‖Φ a‖ ≤ C * ‖a‖) ∧ ∀ a ξ η, + Tendsto (fun i => inner ℂ η (φ i a ξ)) (ω : Filter ι) + (𝓝 (inner ℂ η (Φ a ξ))) := by + have hex (a : A) := Generator.Tracial.exists_weak_operator_ultralimit ω + (fun i => φ i a) (C * ‖a‖) (mul_nonneg hC (norm_nonneg a)) (fun i => hφ i a) + choose T hT ht using hex + have hadd (a b : A) : T (a + b) = T a + T b := by + apply ContinuousLinearMap.ext + intro ξ + apply ext_inner_left ℂ + intro η + apply tendsto_nhds_unique (ht (a + b) ξ η) + simpa only [map_add, add_apply, inner_add_right] using (ht a ξ η).add (ht b ξ η) + have hsmul (z : ℂ) (a : A) : T (z • a) = z • T a := by + apply ContinuousLinearMap.ext + intro ξ + apply ext_inner_left ℂ + intro η + apply tendsto_nhds_unique (ht (z • a) ξ η) + simpa only [map_smul, smul_apply, inner_smul_right, smul_eq_mul] using + (ht a ξ η).const_mul z + let L : A →ₗ[ℂ] (H →L[ℂ] H) := + { toFun := T, map_add' := hadd, map_smul' := hsmul } + have hpos (n : ℕ) (B : CStarMatrix (Fin n) (Fin n) A) (hB : 0 ≤ B) : + 0 ≤ B.map L := by + apply operatorMatrix_nonneg_of_quadratic + intro ξ + have hl : Tendsto (fun i => ∑ j, ∑ k, inner ℂ (ξ j) (φ i (B j k) (ξ k))) + (ω : Filter ι) (𝓝 (∑ j, ∑ k, inner ℂ (ξ j) (T (B j k) (ξ k)))) := by + apply tendsto_finsetSum + intro j _ + apply tendsto_finsetSum + intro k _ + exact ht (B j k) (ξ k) (ξ j) + change 0 ≤ ∑ j, ∑ k, inner ℂ (ξ j) (T (B j k) (ξ k)) + exact ge_of_tendsto hl (Eventually.of_forall fun i => + operatorMatrix_quadratic_nonneg (B.map (φ i)) ((φ i).map_cstarMatrix_nonneg B hB) ξ) + exact ⟨{ L with map_cstarMatrix_nonneg' := hpos }, hT, ht⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveNorm.lean b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveNorm.lean new file mode 100644 index 0000000000000000000000000000000000000000..7488cc3a68fa49a83b580b4d6c3d8be256fbb7f7 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompletelyPositiveNorm.lean @@ -0,0 +1,59 @@ +import OAI.Analysis.BoundedHochschild.StinespringEmbedding + +namespace OAI + +/-! The norm bound supplied by the constructed Stinespring factorization. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma stinespringEmbedding_norm_le (φ : CompletelyPositiveMap A (H →L[ℂ] H)) : + ‖stinespringEmbedding φ‖ ≤ Real.sqrt ‖φ 1‖ := + (stinespringEmbedding φ).opNorm_le_bound (Real.sqrt_nonneg _) + (stinespringVector_bound φ) + +theorem completelyPositive_norm_apply_le (φ : CompletelyPositiveMap A (H →L[ℂ] H)) + (a : A) : ‖φ a‖ ≤ ‖φ 1‖ * ‖a‖ := by + have hV := stinespringEmbedding_norm_le φ + calc + ‖φ a‖ = ‖(stinespringEmbedding φ).adjoint.comp + ((stinespringRepresentation φ a).comp (stinespringEmbedding φ))‖ := + congrArg norm (stinespring_factorization φ a) + _ ≤ ‖(stinespringEmbedding φ).adjoint‖ * + (‖stinespringRepresentation φ a‖ * ‖stinespringEmbedding φ‖) := by + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_left (ContinuousLinearMap.opNorm_comp_le _ _) (norm_nonneg _)) + _ ≤ Real.sqrt ‖φ 1‖ * (‖a‖ * Real.sqrt ‖φ 1‖) := by + rw [LinearIsometryEquiv.norm_map] + gcongr + exact NonUnitalStarAlgHom.norm_apply_le (stinespringRepresentation φ) a + _ = ‖φ 1‖ * ‖a‖ := by + calc + _ = (Real.sqrt ‖φ 1‖) ^ 2 * ‖a‖ := by ring + _ = _ := by rw [Real.sq_sqrt (norm_nonneg (φ 1))] + +def completelyPositiveContinuous (φ : CompletelyPositiveMap A (H →L[ℂ] H)) : + A →L[ℂ] (H →L[ℂ] H) := + φ.toLinearMap.mkContinuous ‖φ 1‖ (completelyPositive_norm_apply_le φ) + +@[simp] lemma completelyPositiveContinuous_apply + (φ : CompletelyPositiveMap A (H →L[ℂ] H)) (a : A) : + completelyPositiveContinuous φ a = φ a := rfl + +lemma completelyPositiveContinuous_norm_le + (φ : CompletelyPositiveMap A (H →L[ℂ] H)) : + ‖completelyPositiveContinuous φ‖ ≤ ‖φ 1‖ := + (completelyPositiveContinuous φ).opNorm_le_bound (norm_nonneg _) + (completelyPositive_norm_apply_le φ) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CompressedAveragingNorms.lean b/lean/OAI/Analysis/BoundedHochschild/CompressedAveragingNorms.lean new file mode 100644 index 0000000000000000000000000000000000000000..8000504d0833ec36bc2696173e80e22918625a0b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CompressedAveragingNorms.lean @@ -0,0 +1,92 @@ +import OAI.Analysis.BoundedHochschild.MinimalRepresentedAverages + +namespace OAI + +/-! Compressions by operators in the two commutants have constant norm on a +minimal represented averaging family. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +variable {M H K : Type*} [CStarAlgebra M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def weakCompression (P : K →L[ℂ] K) (Q : H →L[ℂ] H) (W : H →WOT[ℂ] K) : + H →WOT[ℂ] K := + (ContinuousLinearMapWOT.ofCLM P).comp (W.comp (ContinuousLinearMapWOT.ofCLM Q)) + +omit [CompleteSpace H] [CompleteSpace K] in +lemma weakCompression_continuous (P : K →L[ℂ] K) (Q : H →L[ℂ] H) : + Continuous (weakCompression P Q) := + (ContinuousLinearMapWOT.continuous_postcomp _).comp + (ContinuousLinearMapWOT.continuous_precomp _) + +omit [CompleteSpace H] [CompleteSpace K] in +lemma weakCompression_sublevel_convex (P : K →L[ℂ] K) (Q : H →L[ℂ] H) (c : ℝ) : + Convex ℝ {W : H →WOT[ℂ] K | ‖(weakCompression P Q W).toCLM‖ ≤ c} := by + let f : (H →WOT[ℂ] K) →ₗ[ℝ] (H →L[ℂ] K) := + { toFun := fun W => (weakCompression P Q W).toCLM + map_add' := by intros; ext; simp [weakCompression] + map_smul' := by intros; ext; simp [weakCompression] } + have hs : f ⁻¹' Metric.closedBall 0 c = + {W : H →WOT[ℂ] K | ‖(weakCompression P Q W).toCLM‖ ≤ c} := by + ext W + change dist ((weakCompression P Q W).toCLM) 0 ≤ c ↔ _ + rw [dist_zero_right] + rfl + rw [← hs] + exact (convex_closedBall (0 : H →L[ℂ] K) c).linear_preimage f + +lemma representedRightAverage_compress (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (P : K →L[ℂ] K) (Q : H →L[ℂ] H) + (hP : ∀ a, P.comp (π a) = (π a).comp P) + (hQ : ∀ a, Q.comp (σ a) = (σ a).comp Q) + {I : Type*} [Fintype I] (m : I → M) (W : H →L[ℂ] K) : + P.comp ((representedRightAverage π σ m W).comp Q) = + representedRightAverage π σ m (P.comp (W.comp Q)) := by + have hp (a : M) (ξ : K) : P (π a ξ) = π a (P ξ) := + congrArg (fun A : K →L[ℂ] K => A ξ) (hP a) + have hq (a : M) (ξ : H) : (σ a).adjoint (Q ξ) = Q ((σ a).adjoint ξ) := by + have hh := congrArg (fun A : H →L[ℂ] H => A ξ) (hQ (star a)).symm + simpa only [map_star, ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.comp_apply] using hh + ext ξ + simp only [ContinuousLinearMap.comp_apply, representedRightAverage, + operatorRowAverage_apply, map_sum, hp, hq] + +theorem compressed_norm_eq_on_minimal_family (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (F : Set (H →WOT[ℂ] K)) + (hclosed : IsClosed F) (hconv : Convex ℝ F) + (hinv : RepresentedRightAverageInvariant π σ F) + (hmin : ∀ G : Set (H →WOT[ℂ] K), G ⊆ F → G.Nonempty → IsClosed G → + Convex ℝ G → RepresentedRightAverageInvariant π σ G → F ⊆ G) + (P : K →L[ℂ] K) (Q : H →L[ℂ] H) + (hP : ∀ a, P.comp (π a) = (π a).comp P) + (hQ : ∀ a, Q.comp (σ a) = (σ a).comp Q) + {U V : H →WOT[ℂ] K} (hU : U ∈ F) (hV : V ∈ F) : + ‖(weakCompression P Q U).toCLM‖ = ‖(weakCompression P Q V).toCLM‖ := by + have hle (A B : H →WOT[ℂ] K) (hA : A ∈ F) (hB : B ∈ F) : + ‖(weakCompression P Q A).toCLM‖ ≤ ‖(weakCompression P Q B).toCLM‖ := by + let c := ‖(weakCompression P Q B).toCLM‖ + let G := F ∩ (weakCompression P Q ⁻¹' rectangularWeakBall c) + have hGc : IsClosed G := hclosed.inter + ((rectangularWeakBall_isClosed c).preimage (weakCompression_continuous P Q)) + have hGv : Convex ℝ G := hconv.inter (weakCompression_sublevel_convex P Q c) + have hGi : RepresentedRightAverageInvariant π σ G := by + intro n m hm W hW + refine ⟨hinv n m hm hW.1, ?_⟩ + change ‖P.comp ((representedRightAverage π σ m W.toCLM).comp Q)‖ ≤ c + rw [representedRightAverage_compress π σ P Q hP hQ] + exact (representedRightAverage_norm_le π σ m hm _).trans hW.2 + exact (hmin G (fun _ h => h.1) ⟨B, hB, show ‖(weakCompression P Q B).toCLM‖ ≤ c from le_rfl⟩ hGc hGv hGi hA).2 + exact le_antisymm (hle U V hU hV) (hle V U hV hU) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Conditional.lean b/lean/OAI/Analysis/BoundedHochschild/Conditional.lean new file mode 100644 index 0000000000000000000000000000000000000000..0e42399002349826ece8c841b4a9e1f6e9a62df6 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Conditional.lean @@ -0,0 +1,140 @@ +import OAI.Analysis.BoundedHochschild.PublishedInputs +import OAI.Analysis.TracialCohomology.Vanishing + +namespace OAI + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners +open scoped ComplexOrder + +universe u + +/-- The finite condition used in the von Neumann type decomposition. -/ +def FiniteAlgebra (N : Type u) [CStarAlgebra N] : Prop := + ∀ v : N, star v * v = 1 → v * star v = 1 + +/-- There is no nonzero finite central corner with no type I central part. -/ +def NoTypeII1Summand (N : Type u) [CStarAlgebra N] + [PartialOrder N] [StarOrderedRing N] : Prop := + ∀ (z : N) (hz : IsStarProjection z), (∀ a : N, z * a = a * z) → + FiniteAlgebra (Corner z hz) → + PopaTypeII.NoTypeICentralPart (Corner z hz) → z = 0 + +/-- Precisely the trace data needed by the proved tracial primitive theorem. -/ +def TracialTypeII (N : Type u) [CStarAlgebra N] + [PartialOrder N] [StarOrderedRing N] : Prop := + ∃ (X : Type u) (_ : NormedAddCommGroup X) (_ : NormedSpace ℂ X) + (_ : CompleteSpace X) (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] N) (τ : N →ₚ[ℂ] ℂ), + TraceInPredual e τ ∧ (∀ a b : N, τ (a * b) = τ (b * a)) ∧ + (∀ a : N, τ (star a * a) = 0 → a = 0) ∧ τ 1 = 1 ∧ + PopaTypeII.NoTypeICentralPart N + +/-- The structural input supplies one exceptional corner and tracial II₁ corners. -/ +structure CentralDecomposition (M : Type u) [CStarAlgebra M] + [PartialOrder M] [StarOrderedRing M] where + Index : Type u + projection : Option Index → M + isProjection : ∀ i, IsStarProjection (projection i) + central : ∀ i a, projection i * a = a * projection i + orthogonal : ∀ i j, i ≠ j → projection i * projection j = 0 + total : ∀ x : M, (∀ i, projection i * x = 0) → x = 0 + exceptional : NoTypeII1Summand (Corner (projection none) (isProjection none)) + tracial : ∀ i, TracialTypeII (Corner (projection (some i)) (isProjection (some i))) + +/-- Blackadar's central type decomposition, specialized to the application. -/ +def CentralDecompositionInput (M : Type u) [CStarAlgebra M] + [PartialOrder M] [StarOrderedRing M] : Prop := + Nonempty (CentralDecomposition M) + +def ClassicalVanishingInput : Prop := + ∀ (N : Type u) [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N], + WStarAlgebra N → NoTypeII1Summand N → + ∀ (n : ℕ) (f : Cochain N (n + 2)), + (∀ x, differentialValue f x = 0) → + ∃ g : Cochain N (n + 1), ∀ x, differentialValue g x = f x + +theorem TracialTypeII.primitive {N : Type u} [CStarAlgebra N] + [PartialOrder N] [StarOrderedRing N] (hN : TracialTypeII N) + {n : ℕ} (f : Cochain N (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain N (n + 1), ‖g‖ ≤ 12 * ‖f‖ ∧ + ∀ x, differentialValue g x = f x := by + rcases hN with ⟨X, hX, hXS, hXC, e, τ, hτ, htr, hfaith, h1, hII⟩ + let := hX + let := hXS + let := hXC + exact source_tracial_ordinary_primitive e τ hτ htr hfaith h1 hII f hf + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The manuscript's global assembly, conditional only on the two cited inputs. -/ +theorem primitive_of_published_inputs (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hdecomp : CentralDecompositionInput M) (hclassical : ClassicalVanishingInput.{u}) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := by + classical + obtain ⟨D⟩ := hdecomp + let p := D.projection + let hp := D.isProjection + let hc := D.central + let e0 := cornerPredualEquiv (p none) (hp none) e + let : WStarAlgebra (Corner (p none) (hp none)) := + ⟨⟨CornerPredual (p none) (hp none) e, inferInstance, inferInstance, + inferInstance, ⟨e0⟩⟩⟩ + let f0 := CentralCorner.restrict (p none) (hp none) (hc none) f + obtain ⟨b0, hb0⟩ := hclassical _ inferInstance D.exceptional n f0 + (CentralCorner.restrict_cocycle _ _ _ f hf) + let C : ℝ := max ‖b0‖ (12 * ‖f‖) + have hpieces (i : Option D.Index) : + ∃ b : Cochain (Corner (p i) (hp i)) (n + 1), ‖b‖ ≤ C ∧ + ∀ x, differentialValue b x = CentralCorner.restrict (p i) (hp i) (hc i) f x := by + cases i with + | none => exact ⟨b0, le_max_left _ _, hb0⟩ + | some i => + obtain ⟨b, hbn, hb⟩ := (D.tracial i).primitive + (CentralCorner.restrict (p (some i)) (hp (some i)) (hc (some i)) f) + (CentralCorner.restrict_cocycle _ _ _ f hf) + exact ⟨b, hbn.trans ((mul_le_mul_of_nonneg_left + (CentralCorner.restrict_norm _ _ _ f) (by norm_num)).trans (le_max_right _ _)), hb⟩ + choose b hbn hb using hpieces + obtain ⟨g, _, hg⟩ := primitive_of_central_cut_primitives e + (HochschildSakai.mul_hasPreadjoint e) p hp hc D.orthogonal D.total f hf + (fun i => CentralCorner.extend (p i) (hp i) (hc i) (b i)) + (fun i => CentralCorner.extend_supported _ _ _ _) + (fun i => CentralCorner.extend_primitive _ _ _ f (b i) (hb i)) + C ((norm_nonneg b0).trans (le_max_left _ _)) + (fun i => (CentralCorner.extend_norm _ _ _ _).trans (hbn i)) + exact ⟨g, hg⟩ + +/-- Theorem 1.1, including vanishing of the actual-image cohomology quotient. -/ +theorem vanishing_of_published_inputs [WStarAlgebra M] + (hdecomp : CentralDecompositionInput M) (hclassical : ClassicalVanishingInput.{u}) + (k : ℕ) (hk : 2 ≤ k) : + (∀ f : Cochain M k, differential f = 0 → + ∃ g : Cochain M (k - 1), incomingDifferential M k g = f) ∧ + Subsingleton (Cohomology M k) := by + have h : ∀ f : Cochain M k, differential f = 0 → + ∃ g : Cochain M (k - 1), incomingDifferential M k g = f := by + obtain ⟨Y, hY, hYS, hYC, ⟨e⟩⟩ := WStarAlgebra.exists_predual (M := M) + let := hY + let := hYS + let := hYC + obtain ⟨n, rfl⟩ := Nat.exists_eq_add_of_le' hk + intro f hf + obtain ⟨g, hg⟩ := primitive_of_published_inputs e hdecomp hclassical f + ((differential_eq_zero_iff f).mp hf) + refine ⟨g, ?_⟩ + ext x + simpa only [incomingDifferential_succ, differential_apply] using hg x + exact ⟨h, (cohomology_subsingleton_iff M k).mpr h⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CornerCochains.lean b/lean/OAI/Analysis/BoundedHochschild/CornerCochains.lean new file mode 100644 index 0000000000000000000000000000000000000000..70a24d39256bd3db90efaa8d30974e414f31cffb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CornerCochains.lean @@ -0,0 +1,165 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Restriction and extension of cochains along central corners. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder +namespace HochschildAtomic +open BoundedHochschild HochschildCorners +universe u +variable {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + +def cornerInclude : Corner p hp →L[ℂ] M where + toFun := fun a => a + map_add' := fun _ _ => rfl + map_smul' := fun _ _ => rfl + cont := continuous_subtype_val + +def centralCornerMap : M →L[ℂ] Corner p hp := + LinearMap.mkContinuous + { toFun := fun a => ⟨p*a,⟨by rw [← mul_assoc,hp.isIdempotentElem.eq],by + rw [mul_assoc,← (hc a).eq,← mul_assoc,hp.isIdempotentElem.eq]⟩⟩ + map_add' := fun a b => Subtype.ext (mul_add p a b) + map_smul' := fun c a => Subtype.ext (mul_smul_comm c p a) } + 1 (fun a => by + change ‖p*a‖≤1*‖a‖ + exact (norm_mul_le _ _).trans (mul_le_mul_of_nonneg_right hp.norm_le (norm_nonneg _))) + +@[simp] lemma centralCornerMap_coe {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : M) : ((centralCornerMap p hp hc a):M)=p*a := rfl +@[simp] lemma cornerInclude_coe {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (a : Corner p hp) : + cornerInclude p hp a=(a:M) := rfl + +lemma centralCornerMap_norm {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : M) : ‖centralCornerMap p hp hc a‖≤‖a‖ := by + change ‖p*a‖≤‖a‖ + exact (norm_mul_le _ _).trans (by simpa using + (mul_le_mul_of_nonneg_right hp.norm_le (norm_nonneg a))) + +lemma centralCornerMap_mul {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a b : M) : + centralCornerMap p hp hc (a*b)=centralCornerMap p hp hc a*centralCornerMap p hp hc b := by + apply Subtype.ext + exact (central_idempotent_mul p hp.isIdempotentElem.eq (fun a => (hc a).eq) a b).symm + +lemma centralCornerMap_left {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : Corner p hp) (b : M) : + centralCornerMap p hp hc ((a:M)*b)=a*centralCornerMap p hp hc b := by + apply Subtype.ext + change p*((a:M)*b)=(a:M)*(p*b) + rw [← mul_assoc,a.property.1,← mul_assoc,a.property.2] + +lemma centralCornerMap_right {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : M) (b : Corner p hp) : + centralCornerMap p hp hc (a*(b:M))=centralCornerMap p hp hc a*b := by + apply Subtype.ext + exact (mul_assoc p a (b:M)).symm + +lemma cornerInclude_left {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : M) (b : Corner p hp) : + a*cornerInclude p hp b=cornerInclude p hp (centralCornerMap p hp hc a*b) := by + change a*(b:M)=(p*a)*(b:M) + rw [(hc a).eq,mul_assoc,b.property.1] + +lemma cornerInclude_right {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + (a : Corner p hp) (b : M) : + cornerInclude p hp a*b=cornerInclude p hp (a*centralCornerMap p hp hc b) := by + change (a:M)*b=(a:M)*(p*b) + rw [← mul_assoc,a.property.2] + +def cornerRestrict {n : ℕ} (f : Cochain M n) : Cochain (Corner p hp) n := + (centralCornerMap p hp hc).compContinuousMultilinearMap + (f.compContinuousLinearMap (fun _ => cornerInclude p hp)) + +def cornerExtend {n : ℕ} (g : Cochain (Corner p hp) n) : Cochain M n := + (cornerInclude p hp).compContinuousMultilinearMap + (g.compContinuousLinearMap (fun _ => centralCornerMap p hp hc)) + +@[simp] lemma cornerRestrict_apply {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + {n : ℕ} (f : Cochain M n) (x : Fin n → Corner p hp) : + cornerRestrict p hp hc f x=centralCornerMap p hp hc (f (fun i => (x i:M))) := rfl +@[simp] lemma cornerExtend_apply {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + {n : ℕ} (g : Cochain (Corner p hp) n) (x : Fin n → M) : + cornerExtend p hp hc g x=cornerInclude p hp (g (fun i => centralCornerMap p hp hc (x i))) := rfl + +lemma cornerRestrict_norm {n : ℕ} (f : Cochain M n) : ‖cornerRestrict p hp hc f‖≤‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + exact (centralCornerMap_norm p hp hc _).trans (f.le_opNorm (fun i => (x i:M))) + +lemma cornerExtend_norm {n : ℕ} (g : Cochain (Corner p hp) n) : ‖cornerExtend p hp hc g‖≤‖g‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + change ‖g (fun i => centralCornerMap p hp hc (x i))‖≤_ + exact (g.le_opNorm _).trans (mul_le_mul_of_nonneg_left + (Finset.prod_le_prod₀ (fun _ _ => norm_nonneg _) (fun _ _ => centralCornerMap_norm p hp hc _)) + (norm_nonneg _)) + +lemma merge_corner_include {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) + {n : ℕ} (x : Fin (n+1) → Corner p hp) (j : Fin n) : + mergeInputs (fun i => (x i:M)) j=fun i => ((mergeInputs (M:=Corner p hp) x j i):M) := by + funext i + simp only [mergeInputs] + split_ifs <;> rfl + +lemma merge_corner_map {n : ℕ} (x : Fin (n+1) → M) (j : Fin n) : + mergeInputs (fun i => centralCornerMap p hp hc (x i)) j= + fun i => centralCornerMap p hp hc (mergeInputs x j i) := by + funext i + simp only [mergeInputs] + split_ifs <;> first | rfl | exact (centralCornerMap_mul p hp hc _ _).symm + +lemma differential_cornerRestrict {n : ℕ} (f : Cochain M n) (x : Fin (n+1) → Corner p hp) : + differentialValue (cornerRestrict p hp hc f) x= + centralCornerMap p hp hc (differentialValue f (fun i => (x i:M))) := by + simp only [differentialValue,cornerRestrict_apply,map_add,map_sum,map_smul, + centralCornerMap_left,centralCornerMap_right,merge_corner_include] + +lemma differential_cornerExtend {n : ℕ} (g : Cochain (Corner p hp) n) (x : Fin (n+1) → M) : + differentialValue (cornerExtend p hp hc g) x= + cornerInclude p hp (differentialValue g (fun i => centralCornerMap p hp hc (x i))) := by + simp only [differentialValue,cornerExtend_apply,merge_corner_map,map_add,map_sum,map_smul, + cornerInclude_left p hp hc,cornerInclude_right p hp hc] + +lemma cornerExtend_support {M : Type u} [CStarAlgebra M] [PartialOrder M] + [StarOrderedRing M] (p : M) (hp : IsStarProjection p) (hc : ∀ a : M, Commute p a) + {n : ℕ} (g : Cochain (Corner p hp) n) (x : Fin n → M) : + p*cornerExtend p hp hc g x=cornerExtend p hp hc g x := + (g (fun i => centralCornerMap p hp hc (x i))).property.1 + +lemma cornerExtend_primitive {n : ℕ} (f : Cochain M (n+1)) (g : Cochain (Corner p hp) n) + (hg : ∀ x, differentialValue g x=cornerRestrict p hp hc f x) : + ∀ x, differentialValue (cornerExtend p hp hc g) x=centralCut p (centralOutput p f) x := by + intro x + rw [differential_cornerExtend,hg] + rfl + +end HochschildAtomic + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CornerEquivalences.lean b/lean/OAI/Analysis/BoundedHochschild/CornerEquivalences.lean new file mode 100644 index 0000000000000000000000000000000000000000..382523d1fc1392b8d6066bb4750e1db2fc7b56dd --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CornerEquivalences.lean @@ -0,0 +1,139 @@ +import OAI.Analysis.BoundedHochschild.Conditional + +namespace OAI + +/-! +# Structural transport for actual corners and algebra equivalences + +Nested corners flatten to the corresponding ambient corner. Type I corners +and the absence of a type I central part are invariant under an actual star +algebra equivalence. These facts are algebraic and require no trace. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +section Nested +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +/-- A corner within a corner is the corner of its ambient projection. -/ +def nestedCornerEquiv {p : M} (hp : IsStarProjection p) + (q : Corner p hp) (hq : IsStarProjection q) : + Corner q hq ≃⋆ₐ[ℂ] Corner (q : M) (corner_projection_coe p hp hq) where + toFun a := ⟨((a : Corner p hp) : M), + congrArg Subtype.val a.property.1, congrArg Subtype.val a.property.2⟩ + invFun b := ⟨⟨(b : M), by + constructor + · calc + p * (b : M) = p * ((q : M) * (b : M)) := by rw [b.property.1] + _ = (b : M) := by rw [← mul_assoc, q.property.1, b.property.1] + · calc + (b : M) * p = ((b : M) * (q : M)) * p := by rw [b.property.2] + _ = (b : M) := by rw [mul_assoc, q.property.2, b.property.2]⟩, + Subtype.ext b.property.1, Subtype.ext b.property.2⟩ + left_inv a := Subtype.ext (Subtype.ext rfl) + right_inv b := Subtype.ext rfl + map_add' _ _ := rfl + map_mul' _ _ := rfl + map_smul' _ _ := rfl + map_star' _ := rfl + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma nestedCornerEquiv_apply {p : M} (hp : IsStarProjection p) + (q : Corner p hp) (hq : IsStarProjection q) (a : Corner q hq) : + ((nestedCornerEquiv hp q hq a : Corner (q : M) (corner_projection_coe p hp hq)) : M) = + ((a : Corner p hp) : M) := rfl + +end Nested + +section Transport +variable {M N : Type*} [CStarAlgebra M] [CStarAlgebra N] + [PartialOrder M] [StarOrderedRing M] [PartialOrder N] [StarOrderedRing N] + +/-- An algebra equivalence induces an equivalence between corresponding corners. -/ +def popaCornerEquiv (φ : M ≃⋆ₐ[ℂ] N) {p : M} (hp : IsStarProjection p) : + PopaCorner.algebra hp ≃⋆ₐ[ℂ] PopaCorner.algebra (hp.map φ) where + toFun a := ⟨φ (a : M), by + constructor + · change φ p * φ (a : M) = φ (a : M) + rw [← map_mul, a.property.1] + · change φ (a : M) * φ p = φ (a : M) + rw [← map_mul, a.property.2]⟩ + invFun b := ⟨φ.symm (b : N), by + constructor + · apply φ.injective + change φ (p * φ.symm (b : N)) = φ (φ.symm (b : N)) + rw [map_mul, φ.apply_symm_apply] + exact b.property.1 + · apply φ.injective + change φ (φ.symm (b : N) * p) = φ (φ.symm (b : N)) + rw [map_mul, φ.apply_symm_apply] + exact b.property.2⟩ + left_inv a := Subtype.ext (φ.symm_apply_apply (a : M)) + right_inv b := Subtype.ext (φ.apply_symm_apply (b : N)) + map_add' a b := Subtype.ext (map_add φ (a : M) (b : M)) + map_mul' a b := Subtype.ext (map_mul φ (a : M) (b : M)) + map_smul' c a := Subtype.ext (map_smul φ c (a : M)) + map_star' a := Subtype.ext (map_star φ (a : M)) + +/-- Abelianness of a projection is transported by a star algebra equivalence. -/ +lemma abelianProjection_map_equiv (φ : M ≃⋆ₐ[ℂ] N) {p : M} + (hp : IsStarProjection p) (hab : PopaTypeII.AbelianProjection hp) : + PopaTypeII.AbelianProjection (hp.map φ) := by + let E := popaCornerEquiv φ hp + intro a b + simpa only [E.apply_symm_apply] using (hab (E.symm a) (E.symm b)).map E + +/-- The type I condition is invariant under changing the algebra presentation. -/ +lemma typeICorner_map_equiv (φ : M ≃⋆ₐ[ℂ] N) {z : M} + (hz : IsStarProjection z) (hI : PopaTypeII.TypeICorner hz) : + PopaTypeII.TypeICorner (hz.map φ) := by + intro p hp hpz hp0 + have hpp : IsStarProjection (φ.symm p) := hp.map φ.symm + have hle : φ.symm p ≤ z := by + simpa only [φ.symm_apply_apply] using OrderHomClass.mono φ.symm hpz + have hp0' : φ.symm p ≠ 0 := by + intro hzero + apply hp0 + simpa only [φ.apply_symm_apply, map_zero] using congrArg φ hzero + obtain ⟨q, hq, hqp, hq0, hqa⟩ := hI (φ.symm p) hpp hle hp0' + refine ⟨φ q, hq.map φ, ?_, ?_, abelianProjection_map_equiv φ hq hqa⟩ + · simpa only [φ.apply_symm_apply] using OrderHomClass.mono φ hqp + · intro hzero + apply hq0 + simpa only [φ.symm_apply_apply, map_zero] using congrArg φ.symm hzero + +/-- Absence of a type I central part needs no trace for transport. -/ +theorem noTypeICentralPart_map_equiv (φ : M ≃⋆ₐ[ℂ] N) + (hM : PopaTypeII.NoTypeICentralPart M) : PopaTypeII.NoTypeICentralPart N := by + intro z hz hzc hz0 hI + have hzM : IsStarProjection (φ.symm z) := hz.map φ.symm + have hzcM : PopaCenter.Central (φ.symm z) := by + intro a + apply φ.injective + change φ (φ.symm z * a) = φ (a * φ.symm z) + rw [map_mul, map_mul, φ.apply_symm_apply] + exact (hzc (φ a)).eq + have hz0M : φ.symm z ≠ 0 := by + intro hzero + apply hz0 + simpa only [φ.apply_symm_apply, map_zero] using congrArg φ hzero + exact hM (φ.symm z) hzM hzcM hz0M (typeICorner_map_equiv φ.symm hz hI) + +/-- The type I central condition is a property of the star algebra. -/ +theorem noTypeICentralPart_equiv (φ : M ≃⋆ₐ[ℂ] N) : + PopaTypeII.NoTypeICentralPart M ↔ PopaTypeII.NoTypeICentralPart N := + ⟨noTypeICentralPart_map_equiv φ, noTypeICentralPart_map_equiv φ.symm⟩ + +end Transport + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CornerUnitaryExtension.lean b/lean/OAI/Analysis/BoundedHochschild/CornerUnitaryExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..7f846fdf229b948f572a02ccdd44e76b9330eb9b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CornerUnitaryExtension.lean @@ -0,0 +1,66 @@ +import OAI.Analysis.BoundedHochschild.Corners + +namespace OAI + +/-! Extending corner unitaries by the identity on the complementary corner. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma corner_complement_left {p : M} (hp : IsStarProjection p) (a : Corner p hp) : + (1 - p) * (a : M) = 0 := by + rw [sub_mul, one_mul, a.property.1, sub_self] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma corner_complement_right {p : M} (hp : IsStarProjection p) (a : Corner p hp) : + (a : M) * (1 - p) = 0 := by + rw [mul_sub, mul_one, a.property.2, sub_self] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma cornerUnitaryExtension_mem {p : M} (hp : IsStarProjection p) (u : unitary (Corner p hp)) : + (((u : Corner p hp) : M) + (1 - p)) ∈ unitary M := by + let a : M := ((u : Corner p hp) : M) + have hstar : star a * a = p := congrArg Subtype.val (Unitary.coe_star_mul_self u) + have hmul : a * star a = p := congrArg Subtype.val (Unitary.coe_mul_star_self u) + have hleft : (1 - p) * a = 0 := corner_complement_left hp (u : Corner p hp) + have hright : a * (1 - p) = 0 := corner_complement_right hp (u : Corner p hp) + have hstarleft : (1 - p) * star a = 0 := corner_complement_left hp (star (u : Corner p hp)) + have hstarright : star a * (1 - p) = 0 := corner_complement_right hp (star (u : Corner p hp)) + constructor + · change star (a + (1 - p)) * (a + (1 - p)) = 1 + rw [star_add, hp.one_sub.isSelfAdjoint.star_eq, add_mul, mul_add, mul_add, + hstar, hstarright, hleft, hp.one_sub.isIdempotentElem.eq] + abel + · change (a + (1 - p)) * star (a + (1 - p)) = 1 + rw [star_add, hp.one_sub.isSelfAdjoint.star_eq, add_mul, mul_add, mul_add, + hmul, hright, hstarleft, hp.one_sub.isIdempotentElem.eq] + abel + +def cornerUnitaryExtension {p : M} (hp : IsStarProjection p) : + unitary (Corner p hp) →* unitary M where + toFun u := ⟨_, cornerUnitaryExtension_mem hp u⟩ + map_one' := Subtype.ext (by change p + (1 - p) = 1; abel) + map_mul' u v := by + apply Subtype.ext + change (((u : Corner p hp) : M) * ((v : Corner p hp) : M)) + (1 - p) = + (((u : Corner p hp) : M) + (1 - p)) * (((v : Corner p hp) : M) + (1 - p)) + rw [add_mul, mul_add, mul_add, corner_complement_right hp, corner_complement_left hp, + hp.one_sub.isIdempotentElem.eq] + abel + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma cornerUnitaryExtension_apply {p : M} (hp : IsStarProjection p) + (u : unitary (Corner p hp)) : + (cornerUnitaryExtension hp u : M) = ((u : Corner p hp) : M) + (1 - p) := rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Corners.lean b/lean/OAI/Analysis/BoundedHochschild/Corners.lean new file mode 100644 index 0000000000000000000000000000000000000000..e0358e6084781aafe8886be96af240d1c7a2200c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Corners.lean @@ -0,0 +1,609 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MatrixSystems +import OAI.Analysis.BoundedHochschild.MatrixCommutants +import OAI.Analysis.BoundedHochschild.WeakAlgebras + +namespace OAI + +/-! Spectral corners, corner preduals and factor structure. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open Filter Topology +open scoped ComplexOrder +namespace HochschildCorners +open BoundedHochschild HochschildRigidity HochschildSakai +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def corner (p : M) (hp : IsStarProjection p) : NonUnitalStarSubalgebra ℂ M where + carrier := {a | p*a=a ∧ a*p=a} + zero_mem' := by simp + add_mem' := by + rintro a b ⟨ha,ha'⟩ ⟨hb,hb'⟩ + exact ⟨by rw [mul_add,ha,hb],by rw [add_mul,ha',hb']⟩ + mul_mem' := by + rintro a b ⟨ha,ha'⟩ ⟨hb,hb'⟩ + exact ⟨by rw [← mul_assoc,ha],by rw [mul_assoc,hb']⟩ + smul_mem' := by + intro c a ha + exact ⟨by rw [mul_smul_comm,ha.1],by rw [smul_mul_assoc,ha.2]⟩ + star_mem' := by + intro a ha + exact ⟨by simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star ha.2, + by simpa only [star_mul,hp.isSelfAdjoint.star_eq] using congrArg star ha.1⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma mem_corner {p a : M} {hp : IsStarProjection p} : + a ∈ corner p hp ↔ p*a=a ∧ a*p=a := Iff.rfl + +instance corner_closed (p : M) (hp : IsStarProjection p) : IsClosed (corner p hp : Set M) := by + exact (isClosed_eq (continuous_const.mul continuous_id) continuous_id).inter + (isClosed_eq (continuous_id.mul continuous_const) continuous_id) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma self_mem_corner {p : M} (hp : IsStarProjection p) : p ∈ corner p hp := + ⟨hp.isIdempotentElem.eq,hp.isIdempotentElem.eq⟩ + +lemma projection_mem_corner {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hqp : q ≤ p) : q ∈ corner p hp := + ⟨(hq.le_iff_mul_eq_right hp).mp hqp,(hq.le_iff_mul_eq_left hp).mp hqp⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma compress_mem_corner {p : M} (hp : IsStarProjection p) (a : M) : + p*a*p ∈ corner p hp := by + exact ⟨by rw [← mul_assoc,← mul_assoc,hp.isIdempotentElem.eq], + by rw [mul_assoc,hp.isIdempotentElem.eq]⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma posPart_mem_corner {p a : M} (hp : IsStarProjection p) (ha : a ∈ corner p hp) : + a⁺ ∈ corner p hp := by + exact cfcₙ_mem (𝕜' := ℂ) (·⁺ : ℝ → ℝ) ha + +omit [PartialOrder M] [StarOrderedRing M] in +lemma negPart_mem_corner {p a : M} (hp : IsStarProjection p) (ha : a ∈ corner p hp) : + a⁻ ∈ corner p hp := by + exact cfcₙ_mem (𝕜' := ℂ) (·⁻ : ℝ → ℝ) ha + +lemma support_le_corner {p a q : M} (hp : IsStarProjection p) (ha : a ∈ corner p hp) + (hq : IsSupportProjection a q) : q ≤ p := by + apply (hq.proj.le_iff_mul_eq_left hp).mpr + have hh := hq.annihilate (1-p) (by rw [mul_sub,mul_one,ha.2,sub_self]) + rw [mul_sub,mul_one,sub_eq_zero] at hh + exact hh.symm + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) +include e in +lemma exists_corner_dyadic_projection {p a : M} (hp : IsStarProjection p) + (ha : a ∈ corner p hp) (ha0 : 0 ≤ a) (ha1 : a ≤ p) : + ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ 0 ≤ (2:ℝ) • a-q ∧ (2:ℝ) • a-q ≤ p := by + let b : M := a-(1/2:ℝ) • p + let c : M := b⁺ + let d : M := b⁻ + have hbsa : IsSelfAdjoint b := (IsSelfAdjoint.of_nonneg ha0).sub + (IsSelfAdjoint.of_nonneg (smul_nonneg (by norm_num : (0:ℝ) ≤ 1/2) hp.nonneg)) + have hbmem : b ∈ corner p hp := by + apply (corner p hp).sub_mem ha + simpa only [Complex.coe_smul] using (corner p hp).smul_mem ((1/2:ℝ):ℂ) (self_mem_corner hp) + have hcmem := posPart_mem_corner hp hbmem + have hdmem := negPart_mem_corner hp hbmem + have hb : c-d=b := CFC.posPart_sub_negPart b hbsa + have hc0 : 0 ≤ c := CFC.posPart_nonneg b + have hd0 : 0 ≤ d := CFC.negPart_nonneg b + obtain ⟨q,hq⟩ := exists_support_projection e c hc0 + have hqp : q ≤ p := support_le_corner hp hcmem hq + have hqd : q*d=0 := hq.annihilate d (CFC.posPart_mul_negPart b) + have hdq : d*q=0 := by + simpa only [star_mul,(IsSelfAdjoint.of_nonneg hd0).star_eq, + hq.proj.isSelfAdjoint.star_eq,star_zero] using congrArg star hqd + have hcq : b*q=c := by rw [← hb,sub_mul,hq.right,hdq,sub_zero] + have hqc : q*b=c := by rw [← hb,mul_sub,hq.left,hqd,sub_zero] + have haq : Commute a q := by + change a*q=q*a + have hh := hcq.trans hqc.symm + dsimp [b] at hh + simpa only [sub_mul,mul_sub,smul_mul_assoc,mul_smul_comm, + (hq.proj.le_iff_mul_eq_left hp).mp hqp, + (hq.proj.le_iff_mul_eq_right hp).mp hqp,sub_left_inj] using hh + have hap : Commute a p := ha.2.trans ha.1.symm + have har : 0 ≤ a*(p-q) := (hap.sub_right haq).mul_nonneg ha0 (sub_nonneg.mpr hqp) + have hal : 0 ≤ (p-a)*q := + ((show Commute p q from (hq.proj.commute_of_le hp hqp).symm).sub_left haq).mul_nonneg + (sub_nonneg.mpr ha1) hq.proj.nonneg + have hqa : a*q=c+(1/2:ℝ) • q := by + dsimp [b] at hcq + rw [sub_mul,smul_mul_assoc,(hq.proj.le_iff_mul_eq_right hp).mp hqp] at hcq + exact sub_eq_iff_eq_add.mp hcq + have hlow : 0 ≤ a-(1/2:ℝ) • q := by + have he : a-(1/2:ℝ) • q=c+a*(p-q) := by + rw [mul_sub,ha.2,hqa] + module + rw [he] + exact add_nonneg hc0 har + have hhigh : 0 ≤ (1/2:ℝ) • p-(a-(1/2:ℝ) • q) := by + have he : (1/2:ℝ) • p-(a-(1/2:ℝ) • q)=(p-a)*q+d := by + rw [sub_mul,(hq.proj.le_iff_mul_eq_right hp).mp hqp,hqa] + have haa : a=c-d+(1/2:ℝ) • p := sub_eq_iff_eq_add.mp hb.symm + conv_lhs => rw [haa] + module + rw [he] + exact add_nonneg hal hd0 + refine ⟨q,hq.proj,hqp,?_,?_⟩ + · have hh := smul_nonneg (by norm_num : (0:ℝ) ≤ 2) hlow + convert hh using 1; module + · apply sub_nonneg.mp + have hh := smul_nonneg (by norm_num : (0:ℝ) ≤ 2) hhigh + convert hh using 1; module + +omit [PartialOrder M] [StarOrderedRing M] in +lemma real_smul_mem_corner {p a : M} (hp : IsStarProjection p) + (ha : a ∈ corner p hp) (r : ℝ) : r • a ∈ corner p hp := by + exact ⟨by rw [mul_smul_comm,ha.1],by rw [smul_mul_assoc,ha.2]⟩ + +include e in + + +theorem dual_zero_on_corner (F : StrongDual ℂ M) {p : M} + (hp : IsStarProjection p) + (hF : ∀ q : M, IsStarProjection q → q ≤ p → F q=0) + {a : M} (ha : a ∈ corner p hp) : F a=0 := by + have hbound : ∀ n : ℕ, ∀ b : M, b ∈ corner p hp → 0 ≤ b → b ≤ p → + ‖F b‖ ≤ (1/2:ℝ)^n * ‖F‖ := by + intro n + induction n with + | zero => + intro b hb hb0 hbp + simpa only [pow_zero,one_mul] using (F.le_opNorm b).trans + (mul_le_of_le_one_right (norm_nonneg _) + ((CStarAlgebra.norm_le_one_iff_of_nonneg _ hb0).mpr (hbp.trans hp.le_one))) + | succ n ih => + intro b hb hb0 hbp + obtain ⟨q,hq,hqp,h0,h1⟩ := exists_corner_dyadic_projection e hp hb hb0 hbp + have hmem : (2:ℝ) • b-q ∈ corner p hp := + (corner p hp).sub_mem (real_smul_mem_corner hp hb 2) (projection_mem_corner hp hq hqp) + have hh := ih ((2:ℝ) • b-q) hmem h0 h1 + have he : F ((2:ℝ) • b-q)=(2:ℝ) • F b := by + simp only [map_sub,← Complex.coe_smul,map_smul,hF q hq hqp,sub_zero] + rw [he,norm_smul,Real.norm_eq_abs,abs_of_pos (by norm_num : (0:ℝ)<2)] at hh + rw [pow_succ] + nlinarith + have hz (b : M) (hb : b ∈ corner p hp) (hb0 : 0 ≤ b) (hbp : b ≤ p) : F b=0 := by + apply norm_eq_zero.mp + apply le_antisymm _ (norm_nonneg _) + have ht : Tendsto (fun n : ℕ => (1/2:ℝ)^n * ‖F‖) atTop (𝓝 0) := by + simpa only [zero_mul] using + (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : (0:ℝ)≤1/2) + (by norm_num : (1/2:ℝ)<1)).mul_const ‖F‖ + exact ge_of_tendsto ht (Eventually.of_forall fun n => hbound n b hb hb0 hbp) + have hpos (b : M) (hb : b ∈ corner p hp) (hb0 : 0 ≤ b) : F b=0 := by + let r : ℝ := ‖b‖+1 + have hr : 0 < r := by dsimp [r]; positivity + let c : M := r⁻¹ • b + have hc0 : 0 ≤ c := smul_nonneg (inv_nonneg.mpr hr.le) hb0 + have hcmem : c ∈ corner p hp := real_smul_mem_corner hp hb _ + have hcn : ‖c‖ ≤ 1 := by + dsimp [c] + rw [norm_smul,Real.norm_eq_abs,abs_of_pos (inv_pos.mpr hr)] + exact (inv_mul_le_one₀ hr).mpr (by dsimp [r]; linarith) + have hc1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ hc0).mp hcn + have hcp : c ≤ p := by + have hh := star_left_conjugate_nonneg (sub_nonneg.mpr hc1) p + rw [hp.isSelfAdjoint.star_eq,mul_sub,mul_one,sub_mul,hp.isIdempotentElem.eq, + hcmem.1,hcmem.2] at hh + exact sub_nonneg.mp hh + have hh := hz c hcmem hc0 hcp + dsimp [c] at hh + simp only [← Complex.coe_smul,map_smul] at hh + exact (smul_eq_zero.mp hh).resolve_left (by exact_mod_cast inv_ne_zero hr.ne') + let C : M →L[ℂ] M := (ContinuousLinearMap.mul ℂ M p).comp + ((ContinuousLinearMap.mul ℂ M).flip p) + let G : StrongDual ℂ M := F.comp C + have hG : G=0 := by + have hker : (⊤ : Submodule ℂ M) ≤ G.ker := by + rw [← CStarAlgebra.span_nonneg] + apply Submodule.span_le.mpr + intro b hb + change F (p*(b*p))=0 + rw [← mul_assoc] + apply hpos _ (compress_mem_corner hp b) + simpa only [hp.isSelfAdjoint.star_eq] using star_left_conjugate_nonneg hb p + ext b + exact hker Submodule.mem_top + have hh := congrArg (fun K : StrongDual ℂ M => K a) hG + change F (p*(a*p))=0 at hh + rwa [ha.2,ha.1] at hh + +include e in +lemma commute_corner_of_projections {p b : M} (hp : IsStarProjection p) + (hb : ∀ q : M, IsStarProjection q → q ≤ p → Commute q b) + {a : M} (ha : a ∈ corner p hp) : Commute a b := by + change a*b=b*a + apply sub_eq_zero.mp + apply SeparatingDual.eq_zero_of_forall_dual_eq_zero (R := ℂ) + intro F + let D : M →L[ℂ] M := (ContinuousLinearMap.mul ℂ M).flip b- + ContinuousLinearMap.mul ℂ M b + have h := dual_zero_on_corner e (F.comp D) hp (fun q hq hqp => by + change F (q*b-b*q)=0 + rw [(hb q hq hqp).eq,sub_self,map_zero]) ha + exact h + +end HochschildCorners + + + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCorners +open BoundedHochschild BoundedHochschild.WeakAlgebra HochschildRigidity HochschildSakai +universe u +variable {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable (p : M) (hp : IsStarProjection p) + +abbrev Corner := corner p hp + +instance cornerOne : One (Corner p hp) := ⟨⟨p,self_mem_corner hp⟩⟩ +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma corner_coe_one : ((1 : Corner p hp):M)=p := rfl + +instance cornerRing : Ring (Corner p hp) where + one_mul a := Subtype.ext a.property.1 + mul_one a := Subtype.ext a.property.2 + natCast := fun n => ⟨n • p,(corner p hp).nsmul_mem (self_mem_corner hp) n⟩ + natCast_zero := Subtype.ext (zero_nsmul _) + natCast_succ n := Subtype.ext (succ_nsmul _ _) + intCast := fun z => ⟨z • p,(corner p hp).toNonUnitalSubring.toAddSubgroup.zsmul_mem (self_mem_corner hp) z⟩ + intCast_ofNat n := Subtype.ext (natCast_zsmul _ _) + intCast_negSucc n := Subtype.ext (negSucc_zsmul _ _) + +instance cornerAlgebra : Algebra ℂ (Corner p hp) where + algebraMap := + { toFun := fun c => c • (1 : Corner p hp) + map_zero' := zero_smul _ _ + map_one' := one_smul _ _ + map_add' := fun _ _ => add_smul _ _ _ + map_mul' := fun c d => by + ext + change (c*d) • p=(c • p)*(d • p) + rw [smul_mul_smul_comm,hp.isIdempotentElem.eq] } + commutes' c a := by + ext + change (c • p)*(a:M)=(a:M)*(c • p) + rw [smul_mul_assoc,mul_smul_comm,a.property.1,a.property.2] + smul_def' c a := by + ext + change c • (a:M)=(c • p)*(a:M) + rw [smul_mul_assoc,a.property.1] + +instance cornerNormedRing : NormedRing (Corner p hp) where + dist_eq a b := by + change dist (a:M) (b:M)=‖-(a:M)+(b:M)‖ + rw [dist_comm,dist_eq_norm,sub_eq_add_neg,add_comm] + norm_mul_le a b := norm_mul_le (a:M) (b:M) +instance cornerNormedAlgebra : NormedAlgebra ℂ (Corner p hp) where + norm_smul_le c a := norm_smul_le c (a:M) +instance cornerCStarAlgebra : CStarAlgebra (Corner p hp) where + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma corner_coe_mul (a b : Corner p hp) : ((a*b : Corner p hp):M)=(a:M)*(b:M) := rfl +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma corner_coe_star (a : Corner p hp) : ((star a : Corner p hp):M)=star (a:M) := rfl +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma corner_coe_smul (c : ℂ) (a : Corner p hp) : ((c • a : Corner p hp):M)=c • (a:M) := rfl +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma corner_coe_zero : ((0 : Corner p hp):M)=0 := rfl + +example : PartialOrder (Corner p hp) := inferInstance +instance cornerStarOrderedRing : StarOrderedRing (Corner p hp) := + StarOrderedRing.of_nonneg_iff' (fun {a b} h c => show (c:M)+(a:M) ≤ (c:M)+(b:M) from add_le_add le_rfl (show (a:M) ≤ (b:M) from h)) + (fun a => by + constructor + · intro ha + have haM : (0:M) ≤ (a:M) := ha + have hs : CFC.sqrt (a:M) ∈ corner p hp := by + rw [CFC.sqrt_eq_real_sqrt (a:M) haM] + exact cfcₙ_mem (𝕜' := ℂ) Real.sqrt a.property + refine ⟨⟨CFC.sqrt (a:M),hs⟩,Subtype.ext ?_⟩ + change (a:M)=star (CFC.sqrt (a:M))*CFC.sqrt (a:M) + rw [(IsSelfAdjoint.of_nonneg (CFC.sqrt_nonneg _)).star_eq,CFC.sqrt_mul_sqrt_self (a:M) haM] + · rintro ⟨b,rfl⟩ + exact star_mul_self_nonneg (b:M)) + +section Predual +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +def weakCorner : Submodule ℂ (WeakDual ℂ X) where + carrier := {f | weakEquiv e f ∈ corner p hp} + zero_mem' := by + change weakEquiv e 0 ∈ corner p hp + rw [map_zero] + exact (corner p hp).zero_mem + add_mem' := by + intro a b ha hb + change weakEquiv e (a+b) ∈ corner p hp + rw [map_add] + exact (corner p hp).add_mem ha hb + smul_mem' := by + intro c a ha + change weakEquiv e (c • a) ∈ corner p hp + rw [LinearEquiv.map_smulₛₗ] + exact (corner p hp).smul_mem (star c) ha + +lemma weakCorner_closed : IsClosed (weakCorner p hp e : Set (WeakDual ℂ X)) := by + have hL := mul_hasPreadjoint e p + have hR := mul_right_hasPreadjoint e p + have hLeft := isClosed_eq (normal_continuous e _ hL) (continuous_id : Continuous (id : WeakDual ℂ X → _)) + have hRight := isClosed_eq (normal_continuous e _ hR) (continuous_id : Continuous (id : WeakDual ℂ X → _)) + change IsClosed {f | (weakEquiv e).symm (p*weakEquiv e f)=f} at hLeft + change IsClosed {f | (weakEquiv e).symm (weakEquiv e f*p)=f} at hRight + convert hLeft.inter hRight using 1 + ext f + change (p*weakEquiv e f=weakEquiv e f ∧ weakEquiv e f*p=weakEquiv e f) ↔ + ((weakEquiv e).symm (p*weakEquiv e f)=f ∧ (weakEquiv e).symm (weakEquiv e f*p)=f) + constructor + · rintro ⟨h,h'⟩ + exact ⟨by rw [h,LinearEquiv.symm_apply_apply],by rw [h',LinearEquiv.symm_apply_apply]⟩ + · rintro ⟨h,h'⟩ + exact ⟨by simpa only [LinearEquiv.apply_symm_apply] using congrArg (weakEquiv e) h, + by simpa only [LinearEquiv.apply_symm_apply] using congrArg (weakEquiv e) h'⟩ + +def CornerPredual := X ⧸ WeakSubspace.preannihilator (weakCorner p hp e) +instance : NormedAddCommGroup (CornerPredual p hp e) := inferInstanceAs + (NormedAddCommGroup (X ⧸ WeakSubspace.preannihilator (weakCorner p hp e))) +instance : NormedSpace ℂ (CornerPredual p hp e) := inferInstanceAs + (NormedSpace ℂ (X ⧸ WeakSubspace.preannihilator (weakCorner p hp e))) +instance : CompleteSpace (CornerPredual p hp e) := inferInstanceAs + (CompleteSpace (X ⧸ WeakSubspace.preannihilator (weakCorner p hp e))) + +def cornerStrongEquiv : WeakSubspace.strong (weakCorner p hp e) ≃ₗᵢ⋆[ℂ] Corner p hp where + toFun f := ⟨e f.val,by + have hf := (WeakSubspace.mem_strong (weakCorner p hp e) f.val).mp f.property + exact hf⟩ + invFun a := ⟨e.symm a.val,by + rw [WeakSubspace.mem_strong] + change e (e.symm a.val) ∈ corner p hp + simpa only [LinearIsometryEquiv.apply_symm_apply] using a.property⟩ + left_inv f := Subtype.ext (e.symm_apply_apply f.val) + right_inv a := Subtype.ext (e.apply_symm_apply a.val) + map_add' f g := Subtype.ext (map_add e f.val g.val) + map_smul' c f := Subtype.ext (e.map_smulₛₗ c f.val) + norm_map' f := e.norm_map f.val + +def cornerPredualEquiv : StrongDual ℂ (CornerPredual p hp e) ≃ₗᵢ⋆[ℂ] Corner p hp := + (WeakSubspace.quotientDualEquiv (weakCorner p hp e) (weakCorner_closed p hp e)).trans + (cornerStrongEquiv p hp e) + +lemma cornerPredualEquiv_apply (F : StrongDual ℂ (CornerPredual p hp e)) (z : X) : + e.symm ((cornerPredualEquiv p hp e F : Corner p hp):M) z=F (Submodule.Quotient.mk z) := by + change e.symm (e (F.comp (WeakSubspace.preannihilator (weakCorner p hp e)).mkQL)) z=_ + rw [e.symm_apply_apply] + rfl + +lemma cornerPredualEquiv_symm_mk (a : Corner p hp) (z : X) : + (cornerPredualEquiv p hp e).symm a (Submodule.Quotient.mk z)=e.symm (a:M) z := by + have h := (cornerPredualEquiv p hp e).apply_symm_apply a + have hh := congrArg (fun b : Corner p hp => e.symm (b:M) z) h + rw [cornerPredualEquiv_apply] at hh + exact hh + +end Predual +end HochschildCorners + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCorners +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (p : M) (hp : IsStarProjection p) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma corner_projection_coe {q : Corner p hp} (hq : IsStarProjection q) : + IsStarProjection (q:M) := ⟨congrArg (fun a : Corner p hp => (a:M)) hq.isIdempotentElem.eq, + congrArg (fun a : Corner p hp => (a:M)) hq.isSelfAdjoint.star_eq⟩ + +lemma corner_projection_le {q : Corner p hp} (hq : IsStarProjection q) : (q:M) ≤ p := + ((corner_projection_coe p hp hq).le_iff_mul_eq_left hp).mpr q.property.2 + +lemma corner_no_minimal (hdiff : HochschildDiffuse.NoMinimalProjections M) : + HochschildDiffuse.NoMinimalProjections (Corner p hp) := by + intro q hq hq0 + obtain ⟨r,hr,hrq,hr0,hrne⟩ := hdiff (q:M) (corner_projection_coe p hp hq) + (fun h => hq0 (Subtype.ext h)) + have hrp := hrq.trans (corner_projection_le p hp hq) + have hrc : r ∈ corner p hp := ⟨(hr.le_iff_mul_eq_right hp).mp hrp, + (hr.le_iff_mul_eq_left hp).mp hrp⟩ + refine ⟨⟨r,hrc⟩,⟨Subtype.ext hr.isIdempotentElem.eq,Subtype.ext hr.isSelfAdjoint.star_eq⟩, + hrq,?_,?_⟩ + · exact fun h => hr0 (congrArg (fun a : Corner p hp => (a:M)) h) + · exact fun h => hrne (congrArg (fun a : Corner p hp => (a:M)) h) + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +def cornerTrace : Corner p hp →ₚ[ℂ] ℂ where + toLinearMap := ((τ p).re : ℂ)⁻¹ • (τ.toLinearMap.comp (corner p hp).subtype) + monotone' := fun _ _ h => mul_le_mul_of_nonneg_left (τ.monotone h) + (inv_nonneg.mpr (Complex.zero_le_real.mpr + (Complex.nonneg_iff.mp (τ.map_nonneg hp.nonneg)).1)) + +@[simp] lemma cornerTrace_apply (a : Corner p hp) : + cornerTrace p hp τ a = ((τ p).re : ℂ)⁻¹ * τ (a:M) := rfl + +lemma cornerTrace_one (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hp0 : p ≠ 0) : + cornerTrace p hp τ 1=1 := by + rw [cornerTrace_apply,corner_coe_one,projection_trace_real τ p hp] + exact inv_mul_cancel₀ (Complex.ofReal_ne_zero.mpr + (HochschildDiffuse.projection_trace_pos τ hfaith hp hp0).ne') + +lemma cornerTrace_tracial (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (a b : Corner p hp) : cornerTrace p hp τ (a*b)=cornerTrace p hp τ (b*a) := by + simp only [cornerTrace_apply,corner_coe_mul,htr a.val b.val] + +lemma cornerTrace_faithful (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (hp0 : p ≠ 0) + (a : Corner p hp) (ha : cornerTrace p hp τ (star a*a)=0) : a=0 := by + have hne : ((τ p).re : ℂ) ≠ 0 := Complex.ofReal_ne_zero.mpr + (HochschildDiffuse.projection_trace_pos τ hfaith hp hp0).ne' + have hh := (mul_eq_zero.mp ha).resolve_left (inv_ne_zero hne) + exact Subtype.ext (hfaith a.val hh) + +lemma cornerTrace_normal (hτ : TraceInPredual e τ) : + TraceInPredual (cornerPredualEquiv p hp e) (cornerTrace p hp τ) := by + obtain ⟨z,hz⟩ := hτ + let zq : CornerPredual p hp e := Submodule.Quotient.mk z + refine ⟨((τ p).re : ℂ)⁻¹ • zq,fun a => ?_⟩ + rw [map_smul] + change _ = star (((τ p).re : ℂ)⁻¹ * (cornerPredualEquiv p hp e).symm a (Submodule.Quotient.mk z)) + rw [cornerPredualEquiv_symm_mk] + rw [cornerTrace_apply,hz a.val,star_mul,star_inv₀] + simp only [Complex.star_def,Complex.conj_ofReal] + exact mul_comm _ _ + +end HochschildCorners + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildCorners +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (p : M) (hp : IsStarProjection p) + +lemma corner_factor_of_matrix_diagonal {n : ℕ} (E : MatrixSystem M n) (i : Fin n) + (hip : E.entry i i ≤ p) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1:M)) : + ∀ b : Corner p hp, (∀ x : Corner p hp, Commute b x) → ∃ c : ℂ, b=c • (1 : Corner p hp) := by + intro b hb + let r := E.entry i i + have hr := E.diagonal_proj i + have hpr : p*r=r := (hr.le_iff_mul_eq_right hp).mp hip + have hrp : r*p=r := (hr.le_iff_mul_eq_left hp).mp hip + have hrmem : r ∈ corner p hp := ⟨hpr,hrp⟩ + have hbr : Commute (b:M) r := congrArg (fun a : Corner p hp => (a:M)) (hb ⟨r,hrmem⟩).eq + let d : E.commutant := ⟨E.coefficient i i (b:M),E.coefficient_mem i i b⟩ + have hd : ∀ c : E.commutant, Commute d c := by + intro c + have hrc : r*(c:M)=(c:M)*r := (c.property i i).eq.symm + have hrrc : r*(r*(c:M))=r*(c:M) := by rw [← mul_assoc,hr.isIdempotentElem.eq] + have hrcr : (r*(c:M))*r=r*(c:M) := by rw [hrc,mul_assoc,hr.isIdempotentElem.eq] + have hcpm : r*(c:M) ∈ corner p hp := ⟨by rw [← mul_assoc,hpr],by + rw [hrc,mul_assoc,hrp]⟩ + have hbc : (b:M)*(r*(c:M))=(r*(c:M))*(b:M) := + congrArg (fun a : Corner p hp => (a:M)) (hb ⟨_,hcpm⟩).eq + apply Subtype.ext + change E.coefficient i i (b:M)*(c:M)=(c:M)*E.coefficient i i (b:M) + calc + _ = E.coefficient i i (b:M)*E.coefficient i i (r*(c:M)) := by + rw [E.coefficient_of_commutant i c.property] + _ = E.coefficient i i ((b:M)*r*(r*(c:M))) := E.coefficient_mul i _ _ + _ = E.coefficient i i ((r*(c:M))*r*(b:M)) := by + rw [mul_assoc (b:M) r,hrrc,hbc,hrcr] + _ = E.coefficient i i (r*(c:M))*E.coefficient i i (b:M) := (E.coefficient_mul i _ _).symm + _ = _ := by rw [E.coefficient_of_commutant i c.property] + obtain ⟨c,hc⟩ := E.factor_of_commutant _ rfl hfactor d hd + have hdc : E.coefficient i i (b:M)=c • (1:M) := congrArg (fun a : E.commutant => (a:M)) hc + have hbrc : (b:M)*r=c • r := by + have hh := E.coefficient_corner i (b:M) + rw [hdc, mul_smul_comm,smul_mul_assoc,mul_one,hr.isIdempotentElem.eq] at hh + rw [← hbr.eq,mul_assoc,hr.isIdempotentElem.eq] at hh + exact hh.symm + let a := (b:M)-c • p + have hap : a*p=a := by dsimp [a]; rw [sub_mul,b.property.2,smul_mul_assoc,hp.isIdempotentElem.eq] + have har : a*r=0 := by dsimp [a]; rw [sub_mul,hbrc,smul_mul_assoc,hpr,sub_self] + have hra : r*a=0 := by dsimp [a]; rw [mul_sub,← hbr.eq,hbrc,mul_smul_comm,hrp,sub_self] + have haxr (x : M) : a*x*r=0 := by + have hmem : p*x*r ∈ corner p hp := ⟨by rw [← mul_assoc,← mul_assoc,hp.isIdempotentElem.eq],by + rw [mul_assoc,hrp]⟩ + have hbX : (b:M)*(p*x*r)=(p*x*r)*(b:M) := + congrArg (fun y : Corner p hp => (y:M)) (hb ⟨_,hmem⟩).eq + have hac : a*(p*x*r)=(p*x*r)*a := by + dsimp [a] + rw [sub_mul,mul_sub,hbX,smul_mul_assoc,mul_smul_comm,hmem.1,hmem.2] + calc + a*x*r = a*(p*x*r) := by rw [← mul_assoc,← mul_assoc,hap] + _ = (p*x*r)*a := hac + _ = 0 := by rw [mul_assoc,hra,mul_zero] + have ha0 : a=0 := by + calc + a = ∑ j, a*E.entry j j := by rw [← Finset.mul_sum,E.sum_diagonal,mul_one] + _ = ∑ j, (a*E.entry j i*r)*E.entry i j := by + apply Finset.sum_congr rfl + intro j hj + dsimp [r] + rw [mul_assoc a (E.entry j i),E.entry_mul,ite_eq_left rfl,mul_assoc,E.entry_mul,ite_eq_left rfl] + _ = 0 := by simp only [haxr,zero_mul,Finset.sum_const_zero] + refine ⟨c,Subtype.ext (sub_eq_zero.mp ha0)⟩ + +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +include e hp in +lemma exists_matrix_diagonal_below + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) (hp0 : p ≠ 0) : + ∃ (n : ℕ) (E : MatrixSystem M n) (i : Fin n), E.entry i i ≤ p := by + classical + have hnorm : 0<‖τ.toPreGNS p‖ := lt_of_le_of_ne (norm_nonneg _) + (fun h => hp0 ((preGNS_norm_eq_zero_iff τ hfaith p).mp h.symm)) + obtain ⟨n,E,s,hn,hs,hsp,herr⟩ := exists_matrix_projection_approx e τ hτ htr + hfaith hdiff h1 hfactor hp hnorm + have hsn : s.Nonempty := by + by_contra h + have hz : s=∅ := Finset.not_nonempty_iff_eq_empty.mp h + simp only [hz,Finset.sum_empty,sub_zero] at herr + exact lt_irrefl _ herr + obtain ⟨i,hi⟩ := hsn + refine ⟨n,E,i,le_trans ?_ hsp⟩ + exact Finset.single_le_sum (fun j hj => (E.diagonal_proj j).nonneg) hi + +include e hp in +lemma corner_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) (hp0 : p ≠ 0) : + ∀ b : Corner p hp, (∀ x : Corner p hp, Commute b x) → ∃ c : ℂ, b=c • (1 : Corner p hp) := by + obtain ⟨n,E,i,hi⟩ := exists_matrix_diagonal_below p hp e τ hτ h1 htr hfaith hfactor hdiff hp0 + exact corner_factor_of_matrix_diagonal p hp E i hi hfactor + +end HochschildCorners +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableColumnRegrouping.lean b/lean/OAI/Analysis/BoundedHochschild/CountableColumnRegrouping.lean new file mode 100644 index 0000000000000000000000000000000000000000..b559e4d9cbaaa969b9155d12e5de86685f7a0595 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableColumnRegrouping.lean @@ -0,0 +1,108 @@ +import OAI.Analysis.BoundedHochschild.InfiniteMatrixColumns + +namespace OAI + +/-! Finite unital matrix columns by regrouping a countable column system. -/ + +noncomputable section + +open Filter + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma projection_eq_one_of_column_bounds (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) atTop 1) + {p : M} (hp : IsStarProjection p) (h : ∀ i, (c i).final ≤ p) : p = 1 := by + have hh := orthogonal_projection_sum_annihilator e (fun i => (c i).final) (1 - p) 1 ht + (fun i => by + rw [mul_sub, mul_one, ((c i).final_proj.le_iff_mul_eq_left hp).mp (h i), sub_self]) + rw [one_mul, sub_eq_zero] at hh + exact hh.symm + +/-- Splitting countably many columns into `n` infinite classes gives `n` +unital orthogonal isometries. The proof uses actual sums of transitions. -/ +theorem finite_columns_of_countable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) atTop 1) + (n : ℕ) [NeZero n] : + ∃ v : Fin n → PartialIso M, (∀ j, (v j).initial = 1) ∧ + (∀ j k, j ≠ k → (v j).final * (v k).final = 0) ∧ ∑ j, (v j).final = 1 := by + classical + let σ := (Nat.divModEquiv n).symm + let a (j : Fin n) (i : ℕ) := columnTransition (c (σ (i, j))) (c i) + ((hi _).trans (hi _).symm) + have hai (j i) : (a j i).initial = (c i).final := columnTransition_initial .. + have haf (j i) : (a j i).final = (c (σ (i, j))).final := columnTransition_final .. + have haI (j : Fin n) (i k : ℕ) (hik : i ≠ k) : + (a j i).initial * (a j k).initial = 0 := by + rw [hai, hai] + exact ho i k hik + have haF (j : Fin n) (i k : ℕ) (hik : i ≠ k) : + (a j i).final * (a j k).final = 0 := by + rw [haf, haf] + exact ho _ _ (fun h => hik (congrArg Prod.fst (σ.injective h))) + choose v hvi hvf hvi_min hvf_min using fun j => exists_countable_partialIso_sum e + (a j) (haI j) (haF j) + have hinit (j : Fin n) : (v j).initial = 1 := by + apply projection_eq_one_of_column_bounds e c ht (v j).initial_proj + intro i + rw [← hai j i] + exact hvi j i + have hcross (j k : Fin n) (hjk : j ≠ k) (i l : ℕ) : + (a j i).final * (a k l).final = 0 := by + rw [haf, haf] + exact ho _ _ (fun h => hjk (congrArg Prod.snd (σ.injective h))) + have horth (j k : Fin n) (hjk : j ≠ k) : (v j).final * (v k).final = 0 := by + have hfirst (i : ℕ) : (a j i).final * (v k).final = 0 := by + have hb : (v k).final ≤ 1 - (a j i).final := by + apply hvf_min k _ (a j i).final_proj.one_sub + intro l + apply projection_le_complement_of_mul_zero (a k l).final_proj (a j i).final_proj + simpa only [star_mul, (a j i).final_proj.isSelfAdjoint.star_eq, + (a k l).final_proj.isSelfAdjoint.star_eq, star_zero] using + congrArg star (hcross j k hjk i l) + exact HochschildTypeII.projection_orthogonal_of_le_complement (a j i).final_proj + (v k).final_proj hb + have hb : (v j).final ≤ 1 - (v k).final := hvf_min j _ (v k).final_proj.one_sub + (fun i => projection_le_complement_of_mul_zero (a j i).final_proj (v k).final_proj (hfirst i)) + have h := ((v j).final_proj.le_iff_mul_eq_left (v k).final_proj.one_sub).mp hb + rw [mul_sub, mul_one] at h + exact sub_eq_self.mp h + have hp : IsStarProjection (∑ j, (v j).final) := + orthogonal_projection_finset_sum (fun j => (v j).final) (fun j => (v j).final_proj) + horth Finset.univ + have hsum : (∑ j, (v j).final) = 1 := by + apply projection_eq_one_of_column_bounds e c ht hp + intro i + let t := Nat.divModEquiv n i + have hti : σ t = i := (Nat.divModEquiv n).symm_apply_apply i + have hh : (c i).final ≤ (v t.2).final := by + have h := hvf t.2 t.1 + rw [haf] at h + change (c (σ t)).final ≤ _ at h + simpa only [hti] using h + exact hh.trans (Finset.single_le_sum (fun j _ => (v j).final_proj.nonneg) (Finset.mem_univ t.2)) + exact ⟨v, hinit, horth, hsum⟩ + +/-- Arbitrary finite unital column systems inside a properly infinite algebra. -/ +theorem exists_properlyInfinite_matrix_columns (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (n : ℕ) [NeZero n] : + ∃ v : Fin n → PartialIso M, (∀ j, (v j).initial = 1) ∧ + (∀ j k, j ≠ k → (v j).final * (v k).final = 0) ∧ ∑ j, (v j).final = 1 := by + obtain ⟨c, hi, ho, ht⟩ := exists_countable_isometries e hno + exact finite_columns_of_countable e c hi ho ht n + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableDiagonalOperators.lean b/lean/OAI/Analysis/BoundedHochschild/CountableDiagonalOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..42ae0b0b5dc7d433ef5f2ca50ff232ed0635c05c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableDiagonalOperators.lean @@ -0,0 +1,112 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixSubalgebra +import OAI.Analysis.BoundedHochschild.PathStages + +namespace OAI + +/-! Bounded diagonal operators for a countable orthogonal column system. +Their commutation with the generated matrix algebra identifies the diagonal +corner as abelian, without a scalar trace or separability assumption. -/ + +noncomputable section + +open Filter + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma countableColumn_star_mul (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (i j : ℕ) : + star (c i : M) * (c j : M) = if i = j then 1 else 0 := by + split_ifs with h + · subst j; exact hi i + · exact PartialIso.star_mul_eq_zero_of_final_orthogonal (ho i j h) + +def finiteColumnDiagonal (c : ℕ → PartialIso M) (s : Finset ℕ) (a : M) : M := + ∑ i ∈ s, (c i : M) * a * star (c i : M) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteColumnDiagonal_norm_le (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (s : Finset ℕ) (a : M) : + ‖finiteColumnDiagonal c s a‖ ≤ ‖a‖ := by + apply supported_sum_norm_le (fun i => (c i).final) _ (fun i => (c i).final_proj) ho + · intro i + change ((c i : M) * star (c i : M)) * ((c i : M) * a * star (c i : M)) = _ + calc + _ = ((c i : M) * star (c i : M) * (c i : M)) * a * star (c i : M) := by + simp only [mul_assoc] + _ = _ := by rw [(c i).mul_star_mul] + · intro i + change ((c i : M) * a * star (c i : M)) * ((c i : M) * star (c i : M)) = _ + calc + _ = (c i : M) * a * (star (c i : M) * (c i : M)) * star (c i : M) := by + simp only [mul_assoc] + _ = _ := by rw [show star (c i : M) * (c i : M) = 1 from hi i, mul_one] + · exact norm_nonneg a + · intro i _ + calc + ‖(c i : M) * a * star (c i : M)‖ ≤ ‖(c i : M) * a‖ * ‖star (c i : M)‖ := norm_mul_le _ _ + _ ≤ (1 * ‖a‖) * 1 := by + gcongr + · exact (norm_mul_le _ _).trans (mul_le_mul_of_nonneg_right (c i).norm_le_one (norm_nonneg _)) + · simpa using (c i).norm_le_one + _ = ‖a‖ := by ring + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteColumnDiagonal_mul_column (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (s : Finset ℕ) (a : M) + {i : ℕ} (his : i ∈ s) : finiteColumnDiagonal c s a * (c i : M) = (c i : M) * a := by + classical + simp only [finiteColumnDiagonal, Finset.sum_mul, mul_assoc] + simp [countableColumn_star_mul c hi ho, his] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma column_star_mul_finiteColumnDiagonal (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (s : Finset ℕ) (a : M) + {i : ℕ} (his : i ∈ s) : star (c i : M) * finiteColumnDiagonal c s a = a * star (c i : M) := by + classical + simp only [finiteColumnDiagonal, Finset.mul_sum, ← mul_assoc] + simp [countableColumn_star_mul c hi ho, his] + +theorem exists_countable_diagonal_operator (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (a : M) : + ∃ D : M, ‖D‖ ≤ ‖a‖ ∧ (∀ i, D * (c i : M) = (c i : M) * a) ∧ + ∀ i, star (c i : M) * D = a * star (c i : M) := by + classical + let U : Ultrafilter (Finset ℕ) := Ultrafilter.of atTop + have hU : (U : Filter (Finset ℕ)) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨D, hD, ht⟩ := exists_predual_ultralimit e U (fun s => finiteColumnDiagonal c s a) + ‖a‖ (fun s => finiteColumnDiagonal_norm_le c hi ho s a) + refine ⟨D, hD, ?_, ?_⟩ + · intro i + have h := HochschildSakai.predual_tendsto_mul_right e (c i : M) ht + have he : (fun s => finiteColumnDiagonal c s a * (c i : M)) =ᶠ[U] + (fun _ => (c i : M) * a) := by + apply hU + filter_upwards [eventually_ge_atTop ({i} : Finset ℕ)] with s hs + exact finiteColumnDiagonal_mul_column c hi ho s a (hs (Finset.mem_singleton_self i)) + apply predual_tendsto_unique e h + intro z + exact tendsto_const_nhds.congr' (he.mono (fun _ hs => congrArg (fun x : M => e.symm x z) hs.symm)) + · intro i + have h := HochschildSakai.predual_tendsto_mul_left e (star (c i : M)) ht + have he : (fun s => star (c i : M) * finiteColumnDiagonal c s a) =ᶠ[U] + (fun _ => a * star (c i : M)) := by + apply hU + filter_upwards [eventually_ge_atTop ({i} : Finset ℕ)] with s hs + exact column_star_mul_finiteColumnDiagonal c hi ho s a (hs (Finset.mem_singleton_self i)) + apply predual_tendsto_unique e h + intro z + exact tendsto_const_nhds.congr' (he.mono (fun _ hs => congrArg (fun x : M => e.symm x z) hs.symm)) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixAverage.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixAverage.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ba9ebceaf5d39a4126a69aa8fcda0bedb440efb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixAverage.lean @@ -0,0 +1,136 @@ +import OAI.Analysis.BoundedHochschild.MatrixSectionAveraging +import OAI.Analysis.BoundedHochschild.MatrixAverageLimits +import OAI.Analysis.BoundedHochschild.AlgebraicMatrixPrimitives + +namespace OAI + +/-! A fixed contractive map of the cochain complex into the matrix-unit +multimodular cochains, obtained from the actual finite-group averages. +Its action on cohomology is not asserted here. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + +def matrixAverageUltrafilter : Ultrafilter ℕ := Ultrafilter.of atTop + +private lemma matrix_average_limit_exists (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M n) : + ∃ A : Cochain M n, ‖A‖ ≤ ‖f‖ ∧ ∀ x, + PredualTendsto e (fun k => matrixSectionAverage c hi ho f k x) matrixAverageUltrafilter (A x) := + bounded_cochain_ultralimit e matrixAverageUltrafilter (matrixSectionAverage c hi ho f) + ‖f‖ (norm_nonneg _) (matrixSectionAverage_norm c hi ho f) + +def countableMatrixAverage (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M n) : Cochain M n := + Classical.choose (matrix_average_limit_exists e c hi ho f) + +lemma countableMatrixAverage_norm (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M n) : + ‖countableMatrixAverage e c hi ho f‖ ≤ ‖f‖ := + (Classical.choose_spec (matrix_average_limit_exists e c hi ho f)).1 + +lemma countableMatrixAverage_tendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M n) (x : Fin n → M) : + PredualTendsto e (fun k => matrixSectionAverage c hi ho f k x) + matrixAverageUltrafilter (countableMatrixAverage e c hi ho f x) := + (Classical.choose_spec (matrix_average_limit_exists e c hi ho f)).2 x + +lemma countableMatrixAverage_add (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f g : Cochain M n) : + countableMatrixAverage e c hi ho (f + g) = countableMatrixAverage e c hi ho f + countableMatrixAverage e c hi ho g := by + ext x + apply predual_tendsto_unique e (countableMatrixAverage_tendsto e c hi ho (f + g) x) + simpa only [matrixSectionAverage_add, add_apply] using predual_tendsto_add e + (countableMatrixAverage_tendsto e c hi ho f x) (countableMatrixAverage_tendsto e c hi ho g x) + +lemma countableMatrixAverage_smul (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (z : ℂ) (f : Cochain M n) : + countableMatrixAverage e c hi ho (z • f) = z • countableMatrixAverage e c hi ho f := by + ext x + apply predual_tendsto_unique e (countableMatrixAverage_tendsto e c hi ho (z • f) x) + simpa only [matrixSectionAverage_smul, smul_apply] using predual_tendsto_smul e + (countableMatrixAverage_tendsto e c hi ho f x) z + +def countableMatrixAverageCLM (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (n : ℕ) : + Cochain M n →L[ℂ] Cochain M n := + LinearMap.mkContinuous + { toFun := countableMatrixAverage e c hi ho + map_add' := countableMatrixAverage_add e c hi ho + map_smul' := countableMatrixAverage_smul e c hi ho } + 1 (fun f => by + change ‖countableMatrixAverage e c hi ho f‖ ≤ 1 * ‖f‖ + simpa only [one_mul] using countableMatrixAverage_norm e c hi ho f) + +variable [CompleteSpace X] + +lemma countableMatrixAverage_multimodular (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : + MultimodularOver (countableMatrixAlgebra c) (countableMatrixAverage e c hi ho f) := by + apply multimodular_of_matrixUnits c hi ho + intro i j + apply multimodularAt_of_predualTendsto e (matrixSectionAverage c hi ho f) + (countableMatrixAverage e c hi ho f) _ (countableMatrixAverage_tendsto e c hi ho f) + apply Ultrafilter.of_le atTop + filter_upwards [eventually_gt_atTop (max i j)] with k hk + exact matrixSectionAverage_module c hi ho f k + ⟨i, lt_of_le_of_lt (le_max_left i j) hk⟩ ⟨j, lt_of_le_of_lt (le_max_right i j) hk⟩ + +lemma countableMatrixAverage_differential (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : + countableMatrixAverage e c hi ho (differential f) = differential (countableMatrixAverage e c hi ho f) := by + ext x + apply predual_tendsto_unique e (countableMatrixAverage_tendsto e c hi ho (differential f) x) + simpa only [matrixSectionAverage_differential, differential_apply] using + predual_tendsto_differential_of_predual e (countableMatrixAverage_tendsto e c hi ho f) x + +lemma countableMatrixAverage_cocycle (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) + (hf : ∀ x, differentialValue f x = 0) : + ∀ x, differentialValue (countableMatrixAverage e c hi ho f) x = 0 := by + have hd : differential f = 0 := by + ext x + simpa only [differential_apply, zero_apply] using hf x + have he := countableMatrixAverage_differential e c hi ho f + rw [hd, show countableMatrixAverage e c hi ho (0 : Cochain M (n + 2)) = 0 from + map_zero (countableMatrixAverageCLM e c hi ho (n + 2))] at he + intro x + simpa only [differential_apply, zero_apply] using + congrArg (fun F : Cochain M (n + 2) => F x) he.symm + +variable [PartialOrder M] [StarOrderedRing M] + +theorem primitive_of_countableMatrixAverage [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) atTop 1) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = countableMatrixAverage e c hi ho f x := + primitive_of_algebraic_matrix_multimodular e hno c hi ho ht _ + (countableMatrixAverage_multimodular e c hi ho f) (countableMatrixAverage_cocycle e c hi ho f hf) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixBarOperators.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixBarOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad397c84d156a7da9f87086854a695b4b5c87955 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixBarOperators.lean @@ -0,0 +1,103 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixAverage +import OAI.Analysis.BoundedHochschild.FiniteGroupBarOperators + +namespace OAI + +/-! The degree-bounded weak-star limits of the finite matrix-section +bar operators. These use the same groups and ultrafilter as the matrix +cochain projection. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + +def matrixSectionBarOperator (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) (k : ℕ) : Cochain M n := + finiteGroupBarOperator (matrixSectionGroup c hi ho k).representation f + +lemma matrixSectionBarOperator_norm (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) (k : ℕ) : ‖matrixSectionBarOperator c hi ho f k‖ ≤ (n + 1 : ℝ) * ‖f‖ := + finiteGroupBarOperator_norm _ f + +lemma matrixSectionBarOperator_add (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f g : Cochain M (n + 1)) (k : ℕ) : + matrixSectionBarOperator c hi ho (f + g) k = matrixSectionBarOperator c hi ho f k + matrixSectionBarOperator c hi ho g k := + finiteGroupBarOperator_add _ f g + +lemma matrixSectionBarOperator_smul (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (z : ℂ) (f : Cochain M (n + 1)) (k : ℕ) : + matrixSectionBarOperator c hi ho (z • f) k = z • matrixSectionBarOperator c hi ho f k := + finiteGroupBarOperator_smul _ z f + +private lemma matrix_bar_limit_exists (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : + ∃ H : Cochain M n, ‖H‖ ≤ (n + 1 : ℝ) * ‖f‖ ∧ ∀ x, + PredualTendsto e (fun k => matrixSectionBarOperator c hi ho f k x) + matrixAverageUltrafilter (H x) := + bounded_cochain_ultralimit e matrixAverageUltrafilter (matrixSectionBarOperator c hi ho f) + ((n + 1 : ℝ) * ‖f‖) (by positivity) (matrixSectionBarOperator_norm c hi ho f) + +def countableMatrixBarOperator (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : Cochain M n := + Classical.choose (matrix_bar_limit_exists e c hi ho f) + +lemma countableMatrixBarOperator_norm (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : + ‖countableMatrixBarOperator e c hi ho f‖ ≤ (n + 1 : ℝ) * ‖f‖ := + (Classical.choose_spec (matrix_bar_limit_exists e c hi ho f)).1 + +lemma countableMatrixBarOperator_tendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) (x : Fin n → M) : + PredualTendsto e (fun k => matrixSectionBarOperator c hi ho f k x) + matrixAverageUltrafilter (countableMatrixBarOperator e c hi ho f x) := + (Classical.choose_spec (matrix_bar_limit_exists e c hi ho f)).2 x + +lemma countableMatrixBarOperator_add (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f g : Cochain M (n + 1)) : + countableMatrixBarOperator e c hi ho (f + g) = countableMatrixBarOperator e c hi ho f + countableMatrixBarOperator e c hi ho g := by + ext x + apply predual_tendsto_unique e (countableMatrixBarOperator_tendsto e c hi ho (f + g) x) + simpa only [matrixSectionBarOperator_add, add_apply] using predual_tendsto_add e + (countableMatrixBarOperator_tendsto e c hi ho f x) (countableMatrixBarOperator_tendsto e c hi ho g x) + +lemma countableMatrixBarOperator_smul (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (z : ℂ) (f : Cochain M (n + 1)) : + countableMatrixBarOperator e c hi ho (z • f) = z • countableMatrixBarOperator e c hi ho f := by + ext x + apply predual_tendsto_unique e (countableMatrixBarOperator_tendsto e c hi ho (z • f) x) + simpa only [matrixSectionBarOperator_smul, smul_apply] using predual_tendsto_smul e + (countableMatrixBarOperator_tendsto e c hi ho f x) z + +def countableMatrixBarOperatorCLM (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (n : ℕ) : + Cochain M (n + 1) →L[ℂ] Cochain M n := + LinearMap.mkContinuous + { toFun := countableMatrixBarOperator e c hi ho + map_add' := countableMatrixBarOperator_add e c hi ho + map_smul' := countableMatrixBarOperator_smul e c hi ho } + (n + 1) (fun f => by + change ‖countableMatrixBarOperator e c hi ho f‖ ≤ (n + 1 : ℝ) * ‖f‖ + exact countableMatrixBarOperator_norm e c hi ho f) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixCorners.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixCorners.lean new file mode 100644 index 0000000000000000000000000000000000000000..878291ef6a06b5036e7bbde03bf100f389ef46aa --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixCorners.lean @@ -0,0 +1,112 @@ +import OAI.Analysis.BoundedHochschild.CountableDiagonalOperators + +namespace OAI + +/-! The diagonal corner of the von Neumann algebra generated by a countable +matrix system is abelian. The proof uses diagonal operators and weak-star +closed commutation relations. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma countableMatrixClosure_commute (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) {D : M} + (hD : ∀ i j, Commute ((c i : M) * star (c j : M)) D) + {x : M} (hx : x ∈ countableMatrixClosure e c) : Commute x D := by + have hA : countableMatrixAlgebra c ≤ StarSubalgebra.centralizer ℂ ({D} : Set M) := by + apply StarAlgebra.adjoin_le + rintro a ⟨⟨i, j⟩, rfl⟩ + apply (StarSubalgebra.mem_centralizer_iff ℂ).mpr + intro g hg + have hgD : g = D := Set.mem_singleton_iff.mp hg + subst g + refine ⟨(hD i j).eq.symm, ?_⟩ + simpa only [star_mul, star_star] using congrArg star (hD j i).eq + have hclosed : IsClosed {F : WeakDual ℂ X | + (WeakAlgebra.weakEquiv e).symm (WeakAlgebra.weakEquiv e F * D) = + (WeakAlgebra.weakEquiv e).symm (D * WeakAlgebra.weakEquiv e F)} := + isClosed_eq + (WeakAlgebra.normal_continuous e _ ((HochschildSakai.abstract_multiplication_normal e).2 D)) + (WeakAlgebra.normal_continuous e _ ((HochschildSakai.abstract_multiplication_normal e).1 D)) + have hclosure : (WeakAlgebra.linearClosure e (countableMatrixAlgebra c) : Set (WeakDual ℂ X)) ⊆ + {F | (WeakAlgebra.weakEquiv e).symm (WeakAlgebra.weakEquiv e F * D) = + (WeakAlgebra.weakEquiv e).symm (D * WeakAlgebra.weakEquiv e F)} := by + apply closure_minimal _ hclosed + rintro F ⟨a, ha, rfl⟩ + have hcomm := ((StarSubalgebra.mem_centralizer_iff ℂ).mp (hA ha) D (Set.mem_singleton D)).1 + change (WeakAlgebra.weakEquiv e).symm + (WeakAlgebra.weakEquiv e ((WeakAlgebra.weakEquiv e).symm a) * D) = + (WeakAlgebra.weakEquiv e).symm + (D * WeakAlgebra.weakEquiv e ((WeakAlgebra.weakEquiv e).symm a)) + simpa only [LinearEquiv.apply_symm_apply] using congrArg (WeakAlgebra.weakEquiv e).symm hcomm.symm + have h := (WeakAlgebra.weakEquiv e).symm.injective (hclosure hx) + change x * D = D * x + simpa only [LinearEquiv.apply_symm_apply] using h + +lemma countableMatrixClosure_coefficient_central (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {x : M} (hx : x ∈ countableMatrixClosure e c) (i : ℕ) (a : M) : + Commute (star (c i : M) * x * (c i : M)) a := by + obtain ⟨D, _, hDc, hcD⟩ := exists_countable_diagonal_operator e c hi ho a + have hD (j k : ℕ) : Commute ((c j : M) * star (c k : M)) D := by + change ((c j : M) * star (c k : M)) * D = D * ((c j : M) * star (c k : M)) + calc + _ = (c j : M) * (a * star (c k : M)) := by rw [mul_assoc, hcD k] + _ = ((c j : M) * a) * star (c k : M) := by rw [mul_assoc] + _ = _ := by rw [← hDc j, mul_assoc] + have hxD := countableMatrixClosure_commute e c hD hx + change (star (c i : M) * x * (c i : M)) * a = a * (star (c i : M) * x * (c i : M)) + calc + _ = star (c i : M) * x * ((c i : M) * a) := by simp only [mul_assoc] + _ = star (c i : M) * x * (D * (c i : M)) := by rw [hDc i] + _ = star (c i : M) * (x * D) * (c i : M) := by simp only [mul_assoc] + _ = star (c i : M) * (D * x) * (c i : M) := by rw [hxD.eq] + _ = (star (c i : M) * D) * x * (c i : M) := by simp only [mul_assoc] + _ = (a * star (c i : M)) * x * (c i : M) := by rw [hcD i] + _ = _ := by simp only [mul_assoc] + +theorem countableMatrixClosure_diagonal_abelian (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (i : ℕ) : + FinitePathMain.AbelianProjection + (⟨(c i).final, countableMatrixClosure_transition e c i i⟩ : countableMatrixClosure e c) := by + let p : countableMatrixClosure e c := + ⟨(c i).final, countableMatrixClosure_transition e c i i⟩ + have hp : IsStarProjection p := + ⟨Subtype.ext (c i).final_proj.isIdempotentElem.eq, + Subtype.ext (c i).final_proj.isSelfAdjoint.star_eq⟩ + refine ⟨hp, fun x y => ?_⟩ + have hm (a b : M) : ((c i).final * a * (c i).final) * ((c i).final * b * (c i).final) = + (c i : M) * ((star (c i : M) * a * (c i : M)) * + (star (c i : M) * b * (c i : M))) * star (c i : M) := by + change (((c i : M) * star (c i : M)) * a * ((c i : M) * star (c i : M))) * + (((c i : M) * star (c i : M)) * b * ((c i : M) * star (c i : M))) = _ + calc + _ = (c i : M) * (star (c i : M) * a * (c i : M)) * + (star (c i : M) * (c i : M)) * + (star (c i : M) * b * (c i : M)) * star (c i : M) := by simp only [mul_assoc] + _ = _ := by + rw [show star (c i : M) * (c i : M) = 1 from hi i, mul_one] + simp only [mul_assoc] + apply Subtype.ext + change ((c i).final * (x : M) * (c i).final) * ((c i).final * (y : M) * (c i).final) = + ((c i).final * (y : M) * (c i).final) * ((c i).final * (x : M) * (c i).final) + rw [hm, hm, (countableMatrixClosure_coefficient_central e c hi ho x.property i + (star (c i : M) * (y : M) * (c i : M))).eq] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixGroups.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixGroups.lean new file mode 100644 index 0000000000000000000000000000000000000000..f2491d0c520e4b9d3f8e7f38de2da1dd3257dfd6 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixGroups.lean @@ -0,0 +1,63 @@ +import OAI.Analysis.BoundedHochschild.FiniteCornerGroups +import OAI.Analysis.BoundedHochschild.CountableMatrixSubalgebra + +namespace OAI + +/-! Finite unitary groups inside the constructed matrix subalgebra whose +linear spans contain any prescribed finite section of its matrix units. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] in +theorem finite_group_spans_matrix_section (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (n : ℕ) : + ∃ (G : Type u) (_ : Group G) (_ : Finite G) (ρ : G →* unitary M), + (∀ g, (ρ g : M) ∈ countableMatrixClosure e c) ∧ + ∀ i j : Fin n, (c i.val : M) * star (c j.val : M) ∈ + Submodule.span ℂ (Set.range (fun g => (ρ g : M))) := by + let d : Fin n → PartialIso M := fun i => c i.val + have hd : ∀ i, (d i).initial = 1 := fun i => hi i.val + have hdo : ∀ i j, i ≠ j → (d i).final * (d j).final = 0 := by + intro i j hij + exact ho i.val j.val (fun h => hij (Fin.ext h)) + let hp := finiteColumnProjection_isProjection d hdo + let E := finiteColumnMatrixSystem d hd hdo + refine ⟨E.signedPermutationGroup, inferInstance, inferInstance, finiteCornerGroupHom hp E, ?_, ?_⟩ + · apply finiteCornerGroupHom_mem + intro i j + change (c i.val : M) * star (c j.val : M) ∈ countableMatrixClosure e c + exact countableMatrixClosure_transition e c i.val j.val + · intro i j + exact corner_matrixUnit_mem_group_span hp E i j + +omit [PartialOrder M] [StarOrderedRing M] in +theorem finite_group_spans_matrix_subset (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (s : Finset ℕ) : + ∃ (G : Type u) (_ : Group G) (_ : Finite G) (ρ : G →* unitary M), + (∀ g, (ρ g : M) ∈ countableMatrixClosure e c) ∧ + ∀ i ∈ s, ∀ j ∈ s, (c i : M) * star (c j : M) ∈ + Submodule.span ℂ (Set.range (fun g => (ρ g : M))) := by + obtain ⟨G, hG, hGF, ρ, hρ, hspan⟩ := finite_group_spans_matrix_section e c hi ho (s.sup id + 1) + let := hG + let := hGF + refine ⟨G, hG, hGF, ρ, hρ, ?_⟩ + intro i hiS j hjS + have hiN : i < s.sup id + 1 := Nat.lt_succ_of_le (Finset.le_sup (f := id) hiS) + have hjN : j < s.sup id + 1 := Nat.lt_succ_of_le (Finset.le_sup (f := id) hjS) + exact hspan ⟨i, hiN⟩ ⟨j, hjN⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixHomotopy.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixHomotopy.lean new file mode 100644 index 0000000000000000000000000000000000000000..14dfcd9da00a3b0baa8e97f853e10d72bffffa3b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixHomotopy.lean @@ -0,0 +1,52 @@ +import OAI.Analysis.BoundedHochschild.MatrixBarLimits +import OAI.Analysis.BoundedHochschild.FiniteBarHomotopy + +namespace OAI + +/-! The explicit countable matrix average induces the identity in bounded +Hochschild cohomology. The uniform finite-group bar bounds allow its +homotopy to pass through the fixed weak-star ultralimit. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem countableMatrixBarOperator_homotopy (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 2)) : + differential (countableMatrixBarOperator e c hi ho f) + + countableMatrixBarOperator e c hi ho (differential f) = + f - countableMatrixAverage e c hi ho f := by + have hz : countableMatrixBarDefect e c hi ho f = 0 := by + apply countableMatrixBarDefect_eq_zero_of_eventually + filter_upwards [] with k + unfold matrixSectionBarDefect matrixSectionBarOperator matrixSectionAverage + rw [finiteGroupBarOperator_homotopy, sub_self] + exact sub_eq_zero.mp hz + +theorem countableMatrixBarOperator_cocycle (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + differential (countableMatrixBarOperator e c hi ho f) = + f - countableMatrixAverage e c hi ho f := by + have hd : differential f = 0 := by + ext x + simpa only [differential_apply, zero_apply] using hf x + have hzero : countableMatrixBarOperator e c hi ho (0 : Cochain M (n + 3)) = 0 := + map_zero (countableMatrixBarOperatorCLM e c hi ho (n + 2)) + have h := countableMatrixBarOperator_homotopy e c hi ho f + simpa only [hd, hzero, add_zero] using h + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..a8895a40613bb23949ac3cecb78a9aeb73bb4fd1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixPrimitives.lean @@ -0,0 +1,47 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixTypeI +import OAI.Analysis.BoundedHochschild.MultimodularMatrixBound + +namespace OAI + +/-! The type-I matrix subalgebra and the final cohomological step for its +multimodular cocycles. Reduction of an ordinary cocycle to such a representative +is a separate obligation; no such reduction is assumed to be proved here. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem exists_typeI_countable_matrix_closure (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) : + ∃ c : ℕ → PartialIso M, (∀ i, (c i).initial = 1) ∧ + (∀ i j, i ≠ j → (c i).final * (c j).final = 0) ∧ + PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1 ∧ + FinitePathMain.TypeICentralSummand (1 : countableMatrixClosure e c) := by + obtain ⟨c, hi, ho, ht⟩ := exists_countable_isometries e hno + exact ⟨c, hi, ho, ht, countableMatrixClosure_typeI e c hi ho ht⟩ + +theorem primitive_of_countableMatrix_multimodular [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + {n : ℕ} (f : Cochain M (n + 1)) + (hf : MultimodularOver (countableMatrixClosure e c) f) + (hcocycle : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + obtain ⟨P⟩ := exists_rightModuleAveragingProjection e hno + apply primitive_of_multimodular_columns P f hf _ hcocycle + intro m + exact countableMatrixClosure_columns e c hi ho ht (m + 1) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixProjection.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixProjection.lean new file mode 100644 index 0000000000000000000000000000000000000000..4ab93258919f516536160d0f84bca5aa8fd82e7c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixProjection.lean @@ -0,0 +1,50 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixAverage +import OAI.Analysis.BoundedHochschild.MultimodularTransport + +namespace OAI + +/-! The countable matrix average fixes multimodular cochains and is +therefore an idempotent contraction commuting with the differential. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + +lemma matrixSectionAverage_fixes (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) + (hf : MultimodularOver (countableMatrixAlgebra c) f) (k : ℕ) : + matrixSectionAverage c hi ho f k = f := + finiteGroupCochainAverage_fixes _ _ f hf (matrixSectionGroup c hi ho k).mem + +lemma countableMatrixAverage_fixes (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) + (hf : MultimodularOver (countableMatrixAlgebra c) f) : countableMatrixAverage e c hi ho f = f := by + ext x + apply predual_tendsto_unique e (countableMatrixAverage_tendsto e c hi ho f x) + have he : (fun k => matrixSectionAverage c hi ho f k x) = fun _ => f x := by + funext k + rw [matrixSectionAverage_fixes c hi ho f hf] + rw [he] + exact predual_tendsto_const e _ _ + +variable [CompleteSpace X] + +lemma countableMatrixAverage_idempotent (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} (f : Cochain M (n + 1)) : + countableMatrixAverage e c hi ho (countableMatrixAverage e c hi ho f) = + countableMatrixAverage e c hi ho f := + countableMatrixAverage_fixes e c hi ho _ (countableMatrixAverage_multimodular e c hi ho f) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSpan.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSpan.lean new file mode 100644 index 0000000000000000000000000000000000000000..511ed3a559d8bd617f1b18e91bf2496b7bef25a7 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSpan.lean @@ -0,0 +1,101 @@ +import OAI.Analysis.BoundedHochschild.CountableDiagonalOperators + +namespace OAI + +/-! The algebraic countable matrix algebra consists of finite linear +combinations of its matrix units and the ambient identity. -/ + +noncomputable section + +open scoped Pointwise + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] + +def countableMatrixUnit (c : ℕ → PartialIso M) (i j : ℕ) : M := + (c i : M) * star (c j : M) + +@[simp] lemma countableMatrixUnit_star (c : ℕ → PartialIso M) (i j : ℕ) : + star (countableMatrixUnit c i j) = countableMatrixUnit c j i := by + simp [countableMatrixUnit] + +lemma countableMatrixUnit_mul (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (i j k l : ℕ) : + countableMatrixUnit c i j * countableMatrixUnit c k l = + if j = k then countableMatrixUnit c i l else 0 := by + calc + _ = (c i : M) * (star (c j : M) * (c k : M)) * star (c l : M) := by + simp only [countableMatrixUnit, mul_assoc] + _ = _ := by rw [countableColumn_star_mul c hi ho]; split_ifs <;> simp [countableMatrixUnit] + +def countableMatrixWordMonoid (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) : Submonoid M where + carrier := {a | a = 0 ∨ a = 1 ∨ ∃ i j, a = countableMatrixUnit c i j} + one_mem' := Or.inr (Or.inl rfl) + mul_mem' := by + rintro a b (rfl | rfl | ⟨i, j, rfl⟩) hb + · exact Or.inl (zero_mul b) + · simpa only [one_mul] using hb + · rcases hb with rfl | rfl | ⟨k, l, rfl⟩ + · exact Or.inl (mul_zero _) + · exact Or.inr (Or.inr ⟨i, j, mul_one _⟩) + · rw [countableMatrixUnit_mul c hi ho] + split_ifs + · exact Or.inr (Or.inr ⟨i, l, rfl⟩) + · exact Or.inl rfl + +lemma countableMatrixWordMonoid_star (c : ℕ → PartialIso M) (hi ho) + {a : M} (ha : a ∈ countableMatrixWordMonoid c hi ho) : + star a ∈ countableMatrixWordMonoid c hi ho := by + rcases ha with rfl | rfl | ⟨i, j, rfl⟩ + · exact Or.inl (star_zero M) + · exact Or.inr (Or.inl (star_one M)) + · exact Or.inr (Or.inr ⟨j, i, countableMatrixUnit_star c i j⟩) + +theorem countableMatrixAlgebra_eq_span (c : ℕ → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) : + (countableMatrixAlgebra c).toSubalgebra.toSubmodule = + Submodule.span ℂ ({1} ∪ Set.range (fun p : ℕ × ℕ => countableMatrixUnit c p.1 p.2)) := by + let S := Set.range (fun p : ℕ × ℕ => countableMatrixUnit c p.1 p.2) + let P := Submodule.span ℂ ({1} ∪ S) + have hS : S ⊆ countableMatrixWordMonoid c hi ho := by + rintro a ⟨⟨i, j⟩, rfl⟩ + exact Or.inr (Or.inr ⟨i, j, rfl⟩) + have hgen : S ∪ star S ⊆ countableMatrixWordMonoid c hi ho := by + intro a ha + rcases ha with ha | ha + · exact hS ha + · have ha' : star a ∈ S := by simpa only [Set.mem_star] using ha + have hstar := countableMatrixWordMonoid_star c hi ho (hS ha') + change star (star a) = 0 ∨ star (star a) = 1 ∨ + ∃ i j, star (star a) = countableMatrixUnit c i j at hstar + change a = 0 ∨ a = 1 ∨ ∃ i j, a = countableMatrixUnit c i j + simpa only [star_star] using hstar + have hwords : Submonoid.closure (S ∪ star S) ≤ countableMatrixWordMonoid c hi ho := + Submonoid.closure_le.mpr hgen + apply le_antisymm + · change (StarAlgebra.adjoin ℂ S).toSubalgebra.toSubmodule ≤ P + rw [StarAlgebra.adjoin_eq_span] + apply Submodule.span_le.mpr + intro a ha + rcases hwords ha with rfl | rfl | ⟨i, j, rfl⟩ + · exact P.zero_mem + · exact Submodule.subset_span (Or.inl (Set.mem_singleton 1)) + · exact Submodule.subset_span (Or.inr ⟨(i, j), rfl⟩) + · apply Submodule.span_le.mpr + intro a ha + rcases ha with ha | ha + · have ha1 : a = 1 := Set.mem_singleton_iff.mp ha + subst a + exact (countableMatrixAlgebra c).one_mem + · exact StarAlgebra.subset_adjoin ℂ S ha + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSubalgebra.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSubalgebra.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c7b450bfe90cbe92397ffdeeacc12866900eaa2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixSubalgebra.lean @@ -0,0 +1,75 @@ +import OAI.Analysis.BoundedHochschild.SubalgebraMatrixColumns +import OAI.Analysis.BoundedHochschild.WeakAlgebras + +namespace OAI + +/-! The von Neumann algebra generated by a countable matrix system contains +all finite unital isometry columns. The ambient countable columns themselves +need not belong to this generated algebra. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def countableMatrixAlgebra (c : ℕ → PartialIso M) : StarSubalgebra ℂ M := + StarAlgebra.adjoin ℂ (Set.range (fun p : ℕ × ℕ => (c p.1 : M) * star (c p.2 : M))) + +def matrixClosureStarPreadjoint (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : X →L⋆[ℂ] X := + (HochschildSakai.exists_abstract_star_preadjoint e).choose + +omit [PartialOrder M] [StarOrderedRing M] in +lemma matrixClosureStarPreadjoint_spec (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a : M) (z : X) : + e.symm (star a) z = star (e.symm a (matrixClosureStarPreadjoint e z)) := + (HochschildSakai.exists_abstract_star_preadjoint e).choose_spec.2 a z + +def countableMatrixClosure (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (c : ℕ → PartialIso M) : + StarSubalgebra ℂ M := + WeakAlgebra.closure e (countableMatrixAlgebra c) + (HochschildSakai.abstract_multiplication_normal e).1 + (HochschildSakai.abstract_multiplication_normal e).2 + (matrixClosureStarPreadjoint e) (matrixClosureStarPreadjoint_spec e) + +instance countableMatrixClosure_closed (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) : IsClosed (countableMatrixClosure e c : Set M) := by + unfold countableMatrixClosure + infer_instance + +instance countableMatrixClosure_wstar (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) : WStarAlgebra (countableMatrixClosure e c) := by + unfold countableMatrixClosure + infer_instance + +omit [PartialOrder M] [StarOrderedRing M] in +lemma countableMatrixClosure_transition (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (i j : ℕ) : + (c i : M) * star (c j : M) ∈ countableMatrixClosure e c := by + apply WeakAlgebra.mem_linearClosure e (countableMatrixAlgebra c) + exact StarAlgebra.subset_adjoin ℂ _ ⟨(i, j), rfl⟩ + +theorem countableMatrixClosure_columns (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + (n : ℕ) [NeZero n] : + ∃ v : Fin n → PartialIso M, (∀ j, (v j).initial = 1) ∧ + (∀ j k, j ≠ k → (v j).final * (v k).final = 0) ∧ + (∑ j, (v j).final = 1) ∧ ∀ j, (v j : M) ∈ countableMatrixClosure e c := by + obtain ⟨Y, hY, hYS, hYC, ⟨eR⟩⟩ := + WStarAlgebra.exists_predual (M := countableMatrixClosure e c) + let := hY + let := hYS + let := hYC + exact finite_columns_in_subalgebra e (countableMatrixClosure e c) eR c hi ho ht + (countableMatrixClosure_transition e c) n + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/CountableMatrixTypeI.lean b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixTypeI.lean new file mode 100644 index 0000000000000000000000000000000000000000..39b0f4591d62e573f428da6681a875100be9c09d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/CountableMatrixTypeI.lean @@ -0,0 +1,76 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixCorners +import OAI.Analysis.BoundedHochschild.TypeICentralSupport + +namespace OAI + +/-! The generated countable matrix algebra is type I: its abelian diagonal +has full central support, since all diagonal projections are equivalent and +their sum is the ambient unit. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison FinitePathMain + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem countableMatrixClosure_typeI (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) : + TypeICentralSummand (1 : countableMatrixClosure e c) := by + let R := countableMatrixClosure e c + let p : R := ⟨(c 0).final, countableMatrixClosure_transition e c 0 0⟩ + have hp : AbelianProjection p := countableMatrixClosure_diagonal_abelian e c hi ho 0 + refine ⟨⟨IsStarProjection.one R, fun _ => Commute.one_left _⟩, ?_⟩ + intro q hq _ hq0 + have hqp : IsStarProjection (q * p) := hq.1.mul hp.1 (hq.2 p) + have hle_p : q * p ≤ p := (hqp.le_iff_mul_eq_left hp.1).mpr (by + rw [mul_assoc, hp.1.isIdempotentElem.eq]) + have hle_q : q * p ≤ q := (hqp.le_iff_mul_eq_right hq.1).mpr (by + rw [← mul_assoc, hq.1.isIdempotentElem.eq]) + refine ⟨q * p, HochschildTypeII.abelian_of_le hp hqp hle_p, hle_q, ?_⟩ + intro hzero + have hz : (q : M) * (c 0).final = 0 := congrArg Subtype.val hzero + have hqstar : star (q : M) = (q : M) := congrArg Subtype.val hq.1.isSelfAdjoint.star_eq + have hqdiag (i : ℕ) : (q : M) * (c i).final = 0 := by + let t : R := ⟨(c i : M) * star (c 0 : M), countableMatrixClosure_transition e c i 0⟩ + have hcomm : (q : M) * (t : M) = (t : M) * (q : M) := + congrArg Subtype.val (hq.2 t).eq + have htp : (t : M) * (c 0).final = (t : M) := by + change ((c i : M) * star (c 0 : M)) * ((c 0 : M) * star (c 0 : M)) = _ + calc + _ = (c i : M) * (star (c 0 : M) * (c 0 : M)) * star (c 0 : M) := by + simp only [mul_assoc] + _ = _ := by rw [show star (c 0 : M) * (c 0 : M) = 1 from hi 0, mul_one] + have hqt : (q : M) * (t : M) = 0 := by + calc + _ = (q : M) * ((t : M) * (c 0).final) := by rw [htp] + _ = ((t : M) * (q : M)) * (c 0).final := by rw [← mul_assoc, hcomm] + _ = (t : M) * ((q : M) * (c 0).final) := by rw [mul_assoc] + _ = 0 := by rw [hz, mul_zero] + have htt : (t : M) * ((c 0 : M) * star (c i : M)) = (c i).final := by + change ((c i : M) * star (c 0 : M)) * ((c 0 : M) * star (c i : M)) = _ + calc + _ = (c i : M) * (star (c 0 : M) * (c 0 : M)) * star (c i : M) := by + simp only [mul_assoc] + _ = _ := by rw [show star (c 0 : M) * (c 0 : M) = 1 from hi 0, mul_one] + rfl + rw [← htt, ← mul_assoc, hqt, zero_mul] + have hann := orthogonal_projection_sum_annihilator e (fun i => (c i).final) (q : M) 1 ht + (fun i => by + simpa only [star_mul, (c i).final_proj.isSelfAdjoint.star_eq, hqstar, star_zero] using + congrArg star (hqdiag i)) + apply hq0 + apply Subtype.ext + change (q : M) = 0 + simpa only [one_mul] using hann + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/DiffuseProjections.lean b/lean/OAI/Analysis/BoundedHochschild/DiffuseProjections.lean new file mode 100644 index 0000000000000000000000000000000000000000..baec41c3d259c9f5a2e5e3b885b5e98f061ce0ab --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/DiffuseProjections.lean @@ -0,0 +1,238 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.Dixmier +import OAI.Analysis.BoundedHochschild.FiniteConstraints +import OAI.Analysis.BoundedHochschild.RareScales + +namespace OAI + +/-! Diffuse projections of prescribed trace and conjugation estimates. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open Filter Topology +open scoped ComplexOrder +namespace HochschildDiffuse +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + (τ : M →ₚ[ℂ] ℂ) + + + +def NoMinimalProjections (M : Type*) [CStarAlgebra M] [PartialOrder M] : Prop := + ∀ p : M, IsStarProjection p → p ≠ 0 → + ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ q ≠ 0 ∧ q ≠ p + +lemma projection_trace_pos (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {p : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) : 0 < (τ p).re := by + have hpos : 0 ≤ τ p := τ.map_nonneg hp.nonneg + have hre : 0 ≤ (τ p).re := Complex.nonneg_iff.mp hpos |>.1 + apply lt_of_le_of_ne hre + intro hz + have he : τ p=0 := Complex.ext hz.symm (Complex.nonneg_iff.mp hpos).2.symm + apply hp0 + apply hfaith p + simpa only [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] using he + + + +theorem exists_half_subprojection (hdiff : NoMinimalProjections M) + {p : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) : + ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ q ≠ 0 ∧ (τ q).re ≤ (τ p).re/2 := by + obtain ⟨q,hq,hqp,hq0,hqne⟩ := hdiff p hp hp0 + by_cases ht : (τ q).re ≤ (τ p).re/2 + · exact ⟨q,hq,hqp,hq0,ht⟩ + · refine ⟨p-q,(hq.le_iff_sub hp).mp hqp,sub_le_self _ hq.nonneg,?_,?_⟩ + · intro he + exact hqne (sub_eq_zero.mp he).symm + · rw [map_sub,Complex.sub_re] + linarith + + + +theorem exists_small_subprojection (hdiff : NoMinimalProjections M) + {p : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) (ε : ℝ) (hε : 0 < ε) : + ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ q ≠ 0 ∧ (τ q).re < ε := by + have hrec : ∀ n : ℕ, ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ q ≠ 0 ∧ + (τ q).re ≤ (1/2 : ℝ)^n*(τ p).re := by + intro n + induction n with + | zero => exact ⟨p,hp,le_rfl,hp0,by simp only [pow_zero,one_mul,le_refl]⟩ + | succ n ih => + obtain ⟨q,hq,hqp,hq0,hqn⟩ := ih + obtain ⟨r,hr,hrq,hr0,hrt⟩ := exists_half_subprojection τ hdiff hq hq0 + refine ⟨r,hr,hrq.trans hqp,hr0,?_⟩ + rw [pow_succ] + nlinarith + have ht : Tendsto (fun n : ℕ => (1/2 : ℝ)^n*(τ p).re) atTop (𝓝 0) := by + simpa only [zero_mul] using + (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : (0 : ℝ) ≤ 1/2) + (by norm_num : (1/2 : ℝ) < 1)).mul_const (τ p).re + obtain ⟨n,hn⟩ := (ht.eventually (gt_mem_nhds hε)).exists + obtain ⟨q,hq,hqp,hq0,hqn⟩ := hrec n + exact ⟨q,hq,hqp,hq0,hqn.trans_lt hn⟩ + +lemma projection_le_of_comparable_trace_le + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hcomp : p ≤ q ∨ q ≤ p) (ht : (τ p).re ≤ (τ q).re) : p ≤ q := by + rcases hcomp with h|h + · exact h + · have hz : p-q=0 := by + by_contra hn + have hh := projection_trace_pos τ hfaith ((hq.le_iff_sub hp).mp h) hn + rw [map_sub,Complex.sub_re] at hh + linarith + exact (sub_eq_zero.mp hz).le + +section Dual +open BoundedHochschild HochschildRigidity +variable {X : Type*} [NormedAddCommGroup X] [NormedSpace ℂ X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include e hL hτ htr hfaith in +theorem projection_chain_upper {p : M} (hp : IsStarProjection p) (t : ℝ) + (c : Set M) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) + (hs : ∀ q ∈ c, IsStarProjection q ∧ q ≤ p ∧ (τ q).re ≤ t) : + ∃ s : M, IsStarProjection s ∧ s ≤ p ∧ (τ s).re ≤ t ∧ ∀ q ∈ c, q ≤ s := by + classical + let T : Set ℝ := (fun q : M => (τ q).re) '' c + have hTne : T.Nonempty := Set.Nonempty.image _ hne + have hTbd : BddAbove T := ⟨t,by rintro _ ⟨q,hq,rfl⟩; exact (hs q hq).2.2⟩ + obtain ⟨v,hvm,_hvL,hvt,hv⟩ := (isLUB_csSup hTne hTbd).exists_seq_monotone_tendsto hTne + choose a ha hav using hv + change ∀ n, (τ (a n)).re=v n at hav + have ham : Monotone a := by + intro m n hmn + apply projection_le_of_comparable_trace_le τ hfaith (hs _ (ha m)).1 (hs _ (ha n)).1 + (hc.total (ha m) (ha n)) + rw [hav,hav] + exact hvm hmn + obtain ⟨s,hsp,ht,hns,hsl⟩ := exists_monotone_projection_limit e τ hL hτ htr hfaith + a (fun n => (hs _ (ha n)).1) ham + have htrace : (τ s).re=sSup T := by + have htd := trace_predual_tendsto e τ hτ + (predual_tendsto_of_preGNS e τ hL hτ hfaith 1 + (fun n => (hs _ (ha n)).1.norm_le _) ht) + apply tendsto_nhds_unique (Complex.continuous_re.tendsto _ |>.comp htd) + simpa only [Function.comp_def,hav] using hvt + refine ⟨s,hsp,hsl p hp (fun n => (hs _ (ha n)).2.1),?_,?_⟩ + · rw [htrace] + apply csSup_le hTne + rintro _ ⟨q,hq,rfl⟩ + exact (hs q hq).2.2 + · intro q hq + by_cases hex : ∃ n, q ≤ a n + · obtain ⟨n,hn⟩ := hex + exact hn.trans (hns n) + · have hanq : ∀ n, a n ≤ q := by + intro n + exact (hc.total (ha n) hq).resolve_right (fun h => hex ⟨n,h⟩) + apply projection_le_of_comparable_trace_le τ hfaith (hs q hq).1 hsp + (Or.inr (hsl q (hs q hq).1 hanq)) + rw [htrace] + exact le_csSup hTbd ⟨q,hq,rfl⟩ +include e hL hτ htr hfaith in + + +theorem exists_projection_of_trace (hdiff : NoMinimalProjections M) + {p : M} (hp : IsStarProjection p) (t : ℝ) (ht0 : 0 ≤ t) (htp : t ≤ (τ p).re) : + ∃ q : M, IsStarProjection q ∧ q ≤ p ∧ (τ q).re=t := by + classical + let S : Set M := {q | IsStarProjection q ∧ q ≤ p ∧ (τ q).re ≤ t} + have h0 : (0 : M) ∈ S := ⟨IsStarProjection.zero M,hp.nonneg,by simpa only [map_zero,Complex.zero_re]⟩ + obtain ⟨q,_hq0,hqm⟩ := zorn_le_nonempty₀ S (fun c hc hchain y hy => by + obtain ⟨s,hsp,hsp_le,hst,hsup⟩ := projection_chain_upper τ e hL hτ htr hfaith + hp t c hchain ⟨y,hy⟩ (fun z hz => hc hz) + exact ⟨s,⟨hsp,hsp_le,hst⟩,hsup⟩) 0 h0 + have hq : IsStarProjection q := hqm.1.1 + have hqp : q ≤ p := hqm.1.2.1 + have hqt : (τ q).re ≤ t := hqm.1.2.2 + refine ⟨q,hq,hqp,le_antisymm hqt ?_⟩ + by_contra hle + have hlt : (τ q).re (τ a).re) (sub_eq_zero.mp he) + linarith + obtain ⟨r,hr,hrpq,hr0,hrt⟩ := exists_small_subprojection τ hdiff hpq hpq0 + (t-(τ q).re) (sub_pos.mpr hlt) + have hqr : q*r=0 := by + have hh := (hr.le_iff_mul_eq_right hpq).mp hrpq + calc + q*r=q*((p-q)*r) := by rw [hh] + _=(q*p-q*q)*r := by noncomm_ring + _=0 := by rw [(hq.le_iff_mul_eq_left hp).mp hqp,hq.isIdempotentElem.eq,sub_self,zero_mul] + have hsum : q+r ∈ S := by + refine ⟨hq.add hr hqr,?_,?_⟩ + · calc + q+r ≤ q+(p-q) := add_le_add_right hrpq q + _=p := by abel + · rw [map_add,Complex.add_re] + linarith + have hback : q+r ≤ q := hqm.2 hsum (le_add_of_nonneg_right hr.nonneg) + apply hr0 + apply le_antisymm _ hr.nonneg + apply le_of_add_le_add_left (a := q) + simpa only [add_zero] using hback + +end Dual + +end HochschildDiffuse + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildDixmier +open BoundedHochschild HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) + +include e hL hτ in + + +theorem norm_sub_trace_le_of_conjugations (h1 : τ 1=1) + (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ x : M, τ (star x*x)=0 → x=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (a : M) (ε : ℝ) + (hu : ∀ u : unitary M, ‖τ.toPreGNS (conjugate u a-a)‖ ≤ ε) : + ‖τ.toPreGNS (a-(τ a) • (1 : M))‖ ≤ ε := by + have hk : gnsVector τ '' convexHull ℝ + (Set.range (fun u : unitary M => conjugate u a)) ⊆ + Metric.closedBall (gnsVector τ a) ε := by + rw [LinearMap.image_convexHull] + apply convexHull_min _ (convex_closedBall _ _) + rintro _ ⟨_,⟨u,rfl⟩,rfl⟩ + simpa only [Metric.mem_closedBall,dist_eq_norm,← map_sub,gnsVector_norm] using hu u + have hh := closure_minimal hk Metric.isClosed_closedBall + (scalar_mem_orbit_closure e τ hL hτ h1 htr hfaith hfactor a) + rw [Metric.mem_closedBall,dist_eq_norm] at hh + rw [← map_sub,gnsVector_norm] at hh + simpa only [map_sub,norm_sub_rev] using hh + +end HochschildDixmier +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/DiffuseSubfactor.lean b/lean/OAI/Analysis/BoundedHochschild/DiffuseSubfactor.lean new file mode 100644 index 0000000000000000000000000000000000000000..f56679b54526fd924cac5dcad62951771c83d90e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/DiffuseSubfactor.lean @@ -0,0 +1,247 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.WitnessClosure + +namespace OAI + +/-! Countably generated diffuse subfactors obtained from matrix witnesses and small projections. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildLocalization +open BoundedHochschild HochschildMatrixSystems +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem exists_countable_matrix_witnesses + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (D : Set M) (hD : D.Countable) : + ∃ S : Set M, S.Countable ∧ D ⊆ S ∧ wordSet S ⊆ S ∧ + ∀ a ∈ S, ∀ k : ℕ, ∃ (n : ℕ) (E : MatrixSystem M n), 0 a-(τ a) • (1:M)) + (by intro i; simp [map_sub,map_smul,h1]) + (show 0 < (1:ℝ)/((k:ℝ)+1) by positivity) + exact ⟨n,E,hn,hE ()⟩ + choose n E hn hE using hchoice + let W (a : M) (k : ℕ) : Set M := Set.range (fun ij : Fin (n a k) × Fin (n a k) => (E a k).entry ij.1 ij.2) + obtain ⟨S,hS,hDS,hword,hW⟩ := exists_countable_witness_closure D hD W (fun _ _ => Set.countable_range _) + refine ⟨S,hS,hDS,hword,?_⟩ + intro a ha k + refine ⟨n a k,E a k,hn a k,?_,hE a k⟩ + intro i j + exact hW a ha k ⟨⟨i,j⟩,rfl⟩ + +end HochschildLocalization + +open Filter Topology +open scoped ComplexOrder +namespace HochschildLocalization +open BoundedHochschild HochschildMatrixSystems HochschildPatching +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ a : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M a)) + (hR : ∀ a : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip a)) + (P : X →L⋆[ℂ] X) (hP : ∀ a z, e.symm (star a) z=star (e.symm a (P z))) + +theorem weakClosure_factor_of_matrix_witnesses + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (S : Set M) (hword : wordSet S ⊆ S) + (hmat : ∀ a ∈ S, ∀ k : ℕ, ∃ (n : ℕ) (E : MatrixSystem M n), 0 z-(star (τ (x:M))) • b) hh.symm + have hmem (a : M) (ha : a ∈ S) : a ∈ N := + WeakAlgebra.mem_linearClosure e A (StarAlgebra.subset_adjoin ℂ S ha) + have hgen (a : M) (ha : a ∈ S) : τ (star y*a)=0 := by + have hid : τ (star y*a)=τ ((a-(τ a) • (1:M))*star y) := by + rw [htr] + simp only [sub_mul,smul_mul_assoc,one_mul,map_sub,map_smul,hys,smul_zero,sub_zero] + have hbound (k : ℕ) : ‖τ (star y*a)‖ ≤ (1/((k:ℝ)+1))*‖τ.toPreGNS (star y)‖ := by + obtain ⟨n,E,hn,he,hsmall⟩ := hmat a ha k + have hfix : E.expectation (star y)=star y := by + apply E.expectation_eq_self (Nat.ne_of_gt hn) + intro i j + exact congrArg Subtype.val (hc ⟨E.entry i j,hmem _ (he i j)⟩).eq + rw [hid,← hfix,← E.trace_adjoint τ htr,hfix] + exact (norm_trace_mul_le_gns τ htr _ _).trans + (mul_le_mul_of_nonneg_right hsmall.le (norm_nonneg _)) + apply norm_eq_zero.mp + apply le_antisymm _ (norm_nonneg _) + have ht := (tendsto_one_div_add_atTop_nhds_zero_nat (𝕜 := ℝ)).mul_const ‖τ.toPreGNS (star y)‖ + exact ge_of_tendsto' (by simpa using ht) hbound + have hA (a : M) (ha : a ∈ A) : τ (star y*a)=0 := by + have hm : a ∈ Submodule.span ℂ (wordSet S) := by + dsimp only [wordSet] + rw [← StarAlgebra.adjoin_eq_span] + exact ha + clear ha + induction hm using Submodule.span_induction with + | mem a ha => exact hgen a (hword ha) + | zero => simp + | add a b _ _ ha hb => simp only [mul_add,map_add,ha,hb,add_zero] + | smul c a _ ha => simp only [mul_smul_comm,map_smul,ha,smul_zero] + have heval : ∀ f ∈ WeakAlgebra.linearClosure e A, f (traceVector e τ hL hτ y)=0 := by + apply closure_minimal _ (isClosed_eq (WeakDual.eval_continuous (𝕜 := ℂ) _) continuous_const) + rintro f ⟨a,ha,rfl⟩ + change e.symm a (traceVector e τ hL hτ y)=0 + rw [traceVector_spec,hA a ha,star_zero] + have hyzero : y=0 := by + apply hfaith + apply star_eq_zero.mp + rw [← traceVector_spec e τ hL hτ y y] + exact heval ((WeakAlgebra.weakEquiv e).symm y) yN.property + refine ⟨τ (x:M),?_⟩ + apply Subtype.ext + exact sub_eq_zero.mp hyzero + +end HochschildLocalization + +open scoped ComplexOrder +namespace HochschildLocalization +open BoundedHochschild HochschildComparison HochschildDiffuse +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem diffuse_of_small_projections + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hsmall : ∀ ε : ℝ, 0<ε → ∃ q : M, IsStarProjection q ∧ q ≠ 0 ∧ (τ q).re<ε) : + NoMinimalProjections M := by + intro p hp hp0 + obtain ⟨q,hq,hq0,hqt⟩ := hsmall (τ p).re (projection_trace_pos τ hfaith hp hp0) + obtain ⟨a,ha⟩ := exists_nonzero_corner e τ (HochschildSakai.mul_hasPreadjoint e) + hτ htr hfaith h1 hfactor hp hq hp0 hq0 + obtain ⟨v,hv,hi,hf⟩ := partialIso_of_nonzero_corner e hp hq (p*a*q) ha + (by rw [← mul_assoc,← mul_assoc,hp.isIdempotentElem.eq]) + (by rw [mul_assoc,hq.isIdempotentElem.eq]) + refine ⟨v.final,v.final_proj,hf,?_,?_⟩ + · intro hz + apply hv + apply hfaith + rw [htr] + change τ v.final=0 + rw [hz,map_zero] + · intro hz + have hle : (τ v.initial).re ≤ (τ q).re := Complex.re_le_re (τ.monotone hi) + have ht : τ v.final=τ v.initial := htr _ _ + rw [hz] at ht + rw [← ht] at hle + linarith + +theorem exists_small_projection_sequence + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hdiff : NoMinimalProjections M) : + ∃ q : ℕ → M, (∀ k, IsStarProjection (q k)) ∧ (∀ k, q k ≠ 0) ∧ + ∀ k, (τ (q k)).re=1/((k:ℝ)+1) := by + have hex (k : ℕ) : ∃ q : M, IsStarProjection q ∧ q ≤ 1 ∧ (τ q).re=1/((k:ℝ)+1) := by + apply exists_projection_of_trace τ e (HochschildSakai.mul_hasPreadjoint e) + hτ htr hfaith hdiff (IsStarProjection.one M) _ (by positivity) + rw [h1,Complex.one_re] + exact (div_le_one (by positivity)).mpr (by linarith [Nat.cast_nonneg (α := ℝ) k]) + choose q hq hq1 ht using hex + refine ⟨q,hq,?_,ht⟩ + intro k hz + have hp : 0 < (1:ℝ)/((k:ℝ)+1) := by positivity + have hh := ht k + rw [hz,map_zero,Complex.zero_re] at hh + linarith + +end HochschildLocalization + +open Filter Topology +open scoped ComplexOrder +namespace HochschildLocalization +open BoundedHochschild HochschildMatrixSystems HochschildPatching +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ a : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M a)) + (hR : ∀ a : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip a)) + (P : X →L⋆[ℂ] X) (hP : ∀ a z, e.symm (star a) z=star (e.symm a (P z))) + +theorem exists_countably_generated_diffuse_subfactor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (D : Set M) (hD : D.Countable) : + ∃ S : Set M, S.Countable ∧ D ⊆ S ∧ + (∀ x : WeakAlgebra.closure e (StarAlgebra.adjoin ℂ S) hL hR P hP, + (∀ b, Commute x b) → ∃ c : ℂ, x=c • 1) ∧ + HochschildDiffuse.NoMinimalProjections + (WeakAlgebra.closure e (StarAlgebra.adjoin ℂ S) hL hR P hP) := by + classical + obtain ⟨q,hq,hq0,hqt⟩ := exists_small_projection_sequence e τ hτ h1 htr hfaith hdiff + obtain ⟨S,hS,hDS,hword,hmat⟩ := exists_countable_matrix_witnesses e τ hτ h1 htr hfaith + hfactor hdiff (D ∪ Set.range q) (hD.union (Set.countable_range _)) + have hfN := weakClosure_factor_of_matrix_witnesses e τ hL hR P hP hτ h1 htr hfaith S hword hmat + refine ⟨S,hS,fun a ha => hDS (Or.inl ha),hfN,?_⟩ + let A := StarAlgebra.adjoin ℂ S + let N := WeakAlgebra.closure e A hL hR P hP + let Y := X ⧸ WeakSubspace.preannihilator (WeakAlgebra.linearClosure e A) + let eN : StrongDual ℂ Y ≃ₗᵢ⋆[ℂ] N := WeakAlgebra.predualEquiv e A hL hR P hP + let τN : N →ₚ[ℂ] ℂ := WeakAlgebra.inheritedTrace e τ A hL hR P hP + have hτN := WeakAlgebra.inheritedTrace_normal e τ A hL hR P hP hτ + have htrN := WeakAlgebra.inheritedTrace_tracial e τ A hL hR P hP htr + have hfaithN := WeakAlgebra.inheritedTrace_faithful e τ A hL hR P hP hfaith + apply diffuse_of_small_projections eN τN hτN h1 htrN hfaithN hfN + intro ε hε + obtain ⟨k,hk⟩ := ((tendsto_one_div_add_atTop_nhds_zero_nat (𝕜 := ℝ)).eventually + (gt_mem_nhds hε)).exists + have hmem : q k ∈ N := WeakAlgebra.mem_linearClosure e A + (StarAlgebra.subset_adjoin ℂ S (hDS (Or.inr ⟨k,rfl⟩))) + refine ⟨⟨q k,hmem⟩,⟨Subtype.ext (hq k).isIdempotentElem.eq, + Subtype.ext (hq k).isSelfAdjoint.star_eq⟩,?_,?_⟩ + · intro hz + exact hq0 k (congrArg Subtype.val hz) + · change (τ (q k)).re<ε + rwa [hqt] + +end HochschildLocalization + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Dixmier.lean b/lean/OAI/Analysis/BoundedHochschild/Dixmier.lean new file mode 100644 index 0000000000000000000000000000000000000000..ecb79de4e44b03ac5a1c40d08e26472b337d26f8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Dixmier.lean @@ -0,0 +1,263 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.NormalModulus + +namespace OAI + +/-! Hilbert-space averaging and central elements in unitary orbit closures. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open Filter Topology +open scoped ComplexOrder +namespace HochschildDixmier +open BoundedHochschild HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) + +def gnsVector : M →ₗ[ℝ] τ.GNS := + (UniformSpace.Completion.toComplₗᵢ.toLinearMap.comp τ.toPreGNS.toLinearMap).restrictScalars ℝ + +lemma gnsVector_norm (a : M) : ‖gnsVector τ a‖=‖τ.toPreGNS a‖ := + UniformSpace.Completion.norm_coe _ + +include e hL hτ in + + +theorem isClosed_gns_ball (C : ℝ) : + IsClosed (gnsVector τ '' Metric.closedBall (0 : M) C) := by + apply isSeqClosed_iff_isClosed.mp + intro y z hy hz + choose a ha hay using hy + have hnorm : ∀ n, ‖a n‖ ≤ C := fun n => by simpa only [Metric.mem_closedBall,dist_zero_right] using ha n + have hc : CauchySeq (fun n => τ.toPreGNS (a n)) := by + apply Metric.cauchySeq_iff.mpr + intro ε hε + obtain ⟨N,hN⟩ := Metric.cauchySeq_iff.mp hz.cauchySeq ε hε + refine ⟨N,fun m hm n hn => ?_⟩ + rw [dist_eq_norm,← map_sub,← gnsVector_norm τ, map_sub,hay m,hay n,← dist_eq_norm] + exact hN m hm n hn + obtain ⟨b,hb,ht⟩ := exists_bounded_preGNS_limit e τ hL hτ C hnorm hc + have ht' : Tendsto (fun n => gnsVector τ (a n)) atTop (𝓝 (gnsVector τ b)) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + simpa only [← map_sub,gnsVector_norm] using ht + have he : gnsVector τ b=z := tendsto_nhds_unique ht' (by simpa only [hay] using hz) + exact ⟨b,by simpa only [Metric.mem_closedBall,dist_zero_right] using hb,he⟩ + +def conjugate (u : unitary M) : M →ₗ[ℝ] M where + toFun a := (u : M)*a*star (u : M) + map_add' := by intro a b; simp only [mul_add,add_mul] + map_smul' := by intro r a; simp only [mul_smul_comm,smul_mul_assoc,RingHom.id_apply] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma conjugate_apply (u : unitary M) (a : M) : + conjugate u a=(u : M)*a*star (u : M) := rfl + +omit [PartialOrder M] [StarOrderedRing M] in +lemma conjugate_norm (u : unitary M) (a : M) : ‖conjugate u a‖=‖a‖ := by + change ‖(u : M)*a*(star u : unitary M)‖=‖a‖ + rw [CStarRing.norm_mul_coe_unitary,CStarRing.norm_coe_unitary_mul] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma conjugate_mul (u v : unitary M) (a : M) : conjugate u (conjugate v a)=conjugate (u*v) a := by + simp only [conjugate_apply,Submonoid.coe_mul,star_mul,mul_assoc] + +lemma conjugate_gns_norm (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (u : unitary M) (a : M) : + ‖gnsVector τ (conjugate u a)‖=‖gnsVector τ a‖ := by + rw [gnsVector_norm,gnsVector_norm] + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + apply Complex.ofReal_injective + rw [Complex.ofReal_pow,Complex.ofReal_pow,τ.preGNS_norm_sq,τ.preGNS_norm_sq] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS,conjugate_apply,star_mul,star_star] + have he : (u : M)*(star a*star (u : M))*((u : M)*a*star (u : M))= + (u : M)*(star a*a)*star (u : M) := by + calc + _ = (u : M)*(star a*((star (u : M)*(u : M))*a))*star (u : M) := by noncomm_ring + _ = _ := by rw [Unitary.star_mul_self_of_mem u.prop,one_mul] + rw [he,htr,← mul_assoc,Unitary.star_mul_self_of_mem u.prop,one_mul] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma conjugate_hull (a : M) (u : unitary M) : + conjugate u '' convexHull ℝ (Set.range (fun v : unitary M => conjugate v a)) ⊆ + convexHull ℝ (Set.range (fun v : unitary M => conjugate v a)) := by + rw [LinearMap.image_convexHull] + apply convexHull_mono + rintro _ ⟨_,⟨v,rfl⟩,rfl⟩ + exact ⟨u*v,(conjugate_mul u v a).symm⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma orbit_hull_bounded (a : M) : + convexHull ℝ (Set.range (fun v : unitary M => conjugate v a)) ⊆ + Metric.closedBall (0 : M) ‖a‖ := by + apply convexHull_min _ (convex_closedBall _ _) + rintro _ ⟨v,rfl⟩ + simp only [Metric.mem_closedBall,dist_zero_right,conjugate_norm,le_refl] + +include e hL hτ in + + +theorem orbit_closure_lift (a : M) {z : τ.GNS} + (hz : z ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a)))) : + ∃ b : M, ‖b‖ ≤ ‖a‖ ∧ gnsVector τ b=z := by + have hsub : closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a))) ⊆ + gnsVector τ '' Metric.closedBall (0 : M) ‖a‖ := + closure_minimal (Set.image_mono (orbit_hull_bounded a)) (isClosed_gns_ball e τ hL hτ ‖a‖) + obtain ⟨b,hb,hbz⟩ := hsub hz + exact ⟨b,by simpa only [Metric.mem_closedBall,dist_zero_right] using hb,hbz⟩ + +lemma conjugate_mem_orbit_closure (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (a b : M) + (hb : gnsVector τ b ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a)))) (u : unitary M) : + gnsVector τ (conjugate u b) ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a))) := by + obtain ⟨y,hy,hyt⟩ := mem_closure_iff_seq_limit.mp hb + choose c hc hcy using hy + have ht : Tendsto (fun n => gnsVector τ (conjugate u (c n))) atTop + (𝓝 (gnsVector τ (conjugate u b))) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + simp only [← map_sub,conjugate_gns_norm τ htr] + have hh := (tendsto_iff_norm_sub_tendsto_zero.mp hyt) + simpa only [← hcy,← map_sub] using hh + apply isClosed_closure.mem_of_tendsto ht + exact Filter.Eventually.of_forall fun n => subset_closure + ⟨conjugate u (c n),conjugate_hull a u ⟨c n,hc n,rfl⟩,rfl⟩ + +lemma orbit_gns_convex (a : M) : + Convex ℝ (closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a)))) := by + exact ((convex_convexHull ℝ _).linear_image (gnsVector τ)).closure + +section Hilbert +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H] + +lemma exists_min_norm {K : Set H} (hne : K.Nonempty) (hcl : IsClosed K) (hc : Convex ℝ K) : + ∃ z ∈ K, ∀ w ∈ K, ‖z‖ ≤ ‖w‖ := by + obtain ⟨z,hz,hmin⟩ := exists_norm_eq_iInf_of_complete_convex hne hcl.isComplete hc 0 + refine ⟨z,hz,fun w hw => ?_⟩ + simp only [zero_sub,norm_neg] at hmin + rw [hmin] + apply ciInf_le (f := fun w : K => ‖(w : H)‖) _ ⟨w,hw⟩ + exact ⟨(0 : ℝ),by rintro _ ⟨v,rfl⟩; exact norm_nonneg _⟩ + +omit [CompleteSpace H] in +lemma min_norm_unique {K : Set H} (hc : Convex ℝ K) {z w : H} (hz : z ∈ K) (hw : w ∈ K) + (hmin : ∀ y ∈ K, ‖z‖ ≤ ‖y‖) (he : ‖w‖=‖z‖) : w=z := by + have hm := hmin ((1/2 : ℝ) • z+(1/2 : ℝ) • w) + (hc hz hw (by norm_num) (by norm_num) (by norm_num)) + rw [← smul_add,norm_smul,Real.norm_eq_abs,abs_of_pos (by norm_num : (0 : ℝ)<1/2)] at hm + have hsq : (2*‖z‖)^2 ≤ ‖z+w‖^2 := by + apply (sq_le_sq₀ (by positivity) (norm_nonneg _)).mpr + linarith + have hp := parallelogram_law_with_norm ℝ z w + rw [he] at hp + have hz0 : ‖z-w‖=0 := by nlinarith [sq_nonneg ‖z-w‖,norm_nonneg (z-w)] + exact (sub_eq_zero.mp (norm_eq_zero.mp hz0)).symm +end Hilbert + +include e hL hτ in + + +theorem exists_central_average (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ x : M, τ (star x*x)=0 → x=0) (a : M) : + ∃ b : M, ‖b‖ ≤ ‖a‖ ∧ (∀ x : M, Commute b x) ∧ + gnsVector τ b ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a))) := by + let := InnerProductSpace.rclikeToReal ℂ τ.GNS + let K := closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a))) + have hne : K.Nonempty := ⟨gnsVector τ (conjugate 1 a), + subset_closure ⟨conjugate 1 a,subset_convexHull ℝ _ ⟨1,rfl⟩,rfl⟩⟩ + obtain ⟨z,hz,hmin⟩ := exists_min_norm hne isClosed_closure (orbit_gns_convex τ a) + obtain ⟨b,hb,hbz⟩ := orbit_closure_lift e τ hL hτ a hz + have hbmem : gnsVector τ b ∈ K := hbz ▸ hz + have hfix : ∀ u : unitary M, conjugate u b=b := by + intro u + have he : gnsVector τ (conjugate u b)=gnsVector τ b := by + apply min_norm_unique (orbit_gns_convex τ a) hbmem + (conjugate_mem_orbit_closure τ htr a b hbmem u) + · intro y hy; rw [hbz]; exact hmin y hy + · exact conjugate_gns_norm τ htr u b + apply sub_eq_zero.mp + apply (preGNS_norm_eq_zero_iff τ hfaith _).mp + rw [← gnsVector_norm τ,map_sub,he,sub_self,norm_zero] + have hucomm : ∀ u : unitary M, Commute b (u : M) := by + intro u + have he := congrArg (fun x : M => x*(u : M)) (hfix u) + simp only [conjugate_apply,mul_assoc,Unitary.star_mul_self_of_mem u.prop,mul_one] at he + exact he.symm + refine ⟨b,hb,?_,hbmem⟩ + intro x + have hx : x ∈ Submodule.span ℂ (unitary M : Set M) := by + rw [CStarAlgebra.span_unitary]; trivial + induction hx using Submodule.span_induction with + | mem y hy => exact hucomm ⟨y,hy⟩ + | zero => exact Commute.zero_right b + | add y z hy hz ihy ihz => exact ihy.add_right ihz + | smul r y hy ih => exact ih.smul_right r + +omit [StarOrderedRing M] in +lemma trace_conjugate (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (u : unitary M) (a : M) : τ (conjugate u a)=τ a := by + rw [conjugate_apply,htr,← mul_assoc,Unitary.star_mul_self_of_mem u.prop,one_mul] + +omit [StarOrderedRing M] in +lemma trace_orbit_hull (htr : ∀ x y : M, τ (x*y)=τ (y*x)) (a : M) : + convexHull ℝ (Set.range (fun v : unitary M => conjugate v a)) ⊆ {b : M | τ b=τ a} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩; exact trace_conjugate τ htr u a + · intro x hx y hy r t _hr _ht hrt + change τ (r • x+t • y)=τ a + rw [map_add,τ.map_smul_of_tower,τ.map_smul_of_tower,hx,hy,← add_smul,hrt,one_smul] + +lemma trace_orbit_closure (h1 : τ 1=1) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) (a b : M) + (hb : gnsVector τ b ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a)))) : τ b=τ a := by + obtain ⟨y,hy,hyt⟩ := mem_closure_iff_seq_limit.mp hb + choose c hc hcy using hy + have hcτ : ∀ n, τ (c n)=τ a := fun n => trace_orbit_hull τ htr a (hc n) + have ht : Tendsto (fun n => ‖τ.toPreGNS (c n-b)‖) atTop (𝓝 0) := by + have hh := tendsto_iff_norm_sub_tendsto_zero.mp hyt + simpa only [← hcy,← map_sub,gnsVector_norm] using hh + have htτ : Tendsto (fun n => ‖τ (c n-b)‖) atTop (𝓝 0) := + squeeze_zero (fun _ => norm_nonneg _) (fun n => HochschildUltrapower.norm_trace_le τ h1 (c n-b)) ht + have hzero : ‖τ a-τ b‖=0 := tendsto_nhds_unique tendsto_const_nhds + (by simpa only [map_sub,hcτ] using htτ) + exact (sub_eq_zero.mp (norm_eq_zero.mp hzero)).symm + +include e hL hτ in + + +theorem scalar_mem_orbit_closure (h1 : τ 1=1) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ x : M, τ (star x*x)=0 → x=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) (a : M) : + gnsVector τ ((τ a) • (1 : M)) ∈ closure (gnsVector τ '' convexHull ℝ + (Set.range (fun v : unitary M => conjugate v a))) := by + obtain ⟨b,_hb,hbc,hbK⟩ := exists_central_average e τ hL hτ htr hfaith a + obtain ⟨c,hc⟩ := hfactor b hbc + have hbτ := trace_orbit_closure τ h1 htr a b hbK + have hca : c=τ a := by simpa only [hc,map_smul,h1,smul_eq_mul,mul_one] using hbτ + simpa only [hc,hca] using hbK + +end HochschildDixmier +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/DoubleCoordinates.lean b/lean/OAI/Analysis/BoundedHochschild/DoubleCoordinates.lean new file mode 100644 index 0000000000000000000000000000000000000000..3529fb35360cc7f8609aa4cf09d063ed039ce1b1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/DoubleCoordinates.lean @@ -0,0 +1,55 @@ +import OAI.Analysis.BoundedHochschild.PaulsenExtension + +namespace OAI + +/-! Coordinate isometries in the doubled Hilbert space and extraction of +operator matrix entries. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +open HochschildMatrixDilation + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def doubleCoordinate (i : Fin 2) : H →ₗᵢ[ℂ] HilbertDouble H where + toFun ξ := PiLp.single 2 i ξ + map_add' ξ η := PiLp.single_add 2 i + map_smul' z ξ := by + apply PiLp.ext + intro j + simp [PiLp.single_apply] + norm_map' ξ := by simp + +omit [CompleteSpace H] in +lemma doubleCoordinate_inner (i : Fin 2) (ξ : H) (η : HilbertDouble H) : + inner ℂ (doubleCoordinate i ξ) η = inner ℂ ξ (η i) := by + fin_cases i + all_goals + simp [doubleCoordinate, PiLp.inner_apply, PiLp.single_apply] + +@[simp] lemma doubleCoordinate_adjoint (i : Fin 2) (η : HilbertDouble H) : + (doubleCoordinate i).toContinuousLinearMap.adjoint η = η i := by + apply ext_inner_left ℂ + intro ξ + rw [ContinuousLinearMap.adjoint_inner_right] + exact doubleCoordinate_inner i ξ η + +lemma doubleCoordinate_extract (i j : Fin 2) (Q : Mat (H →L[ℂ] H)) : + (doubleCoordinate i).toContinuousLinearMap.adjoint.comp + ((doubleMatrixHom (H := H) Q).comp + (doubleCoordinate j).toContinuousLinearMap) = Q i j := by + apply ContinuousLinearMap.ext + intro ξ + rw [ContinuousLinearMap.comp_apply, ContinuousLinearMap.comp_apply, + doubleCoordinate_adjoint] + exact WeakPureInfiniteness.matrixOperator_single Q i j ξ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/EncodedMapFamilies.lean b/lean/OAI/Analysis/BoundedHochschild/EncodedMapFamilies.lean new file mode 100644 index 0000000000000000000000000000000000000000..ce5ce9b6035a5f59a7e6e8647dcda0913ad59422 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/EncodedMapFamilies.lean @@ -0,0 +1,48 @@ +import OAI.Analysis.BoundedHochschild.LeftSandwichAverages + +namespace OAI + +/-! Orthogonal isometry columns encode finitely many maps into a single map. +Each map is recovered using only input and output left multiplication. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {n : ℕ} + +def encodeMapFamily (c : Fin n → PartialIso M) (T : Fin n → M →L[ℂ] M) : M →L[ℂ] M := + ∑ i, leftSandwichMap (c i : M) (star (c i : M)) (T i) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma extract_encodeMapFamily (c : Fin n → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (T : Fin n → M →L[ℂ] M) (j : Fin n) : + leftSandwichMap (star (c j : M)) (c j : M) (encodeMapFamily c T) = T j := by + ext x + simp only [leftSandwichMap_apply, encodeMapFamily, sum_apply] + rw [Finset.mul_sum] + rw [Finset.sum_eq_single j] + · simp only [← mul_assoc, column_star_mul c hi ho, ite_true, one_mul] + · intro i _ hij + rw [← mul_assoc, column_star_mul c hi ho j i] + simp only [Ne.symm hij, ite_false, zero_mul] + · intro h + exact (h (Finset.mem_univ j)).elim + +lemma encodeMapFamily_completelyBounded (c : Fin n → PartialIso M) + (T : Fin n → M →L[ℂ] M) (C : Fin n → ℝ) + (hT : ∀ i, CompletelyBoundedEstimate (T i) (C i)) : + CompletelyBoundedEstimate (encodeMapFamily c T) + (∑ i, ‖(c i : M)‖ * C i * ‖star (c i : M)‖) := + completelyBounded_sum _ _ (fun i => completelyBounded_leftSandwich _ _ (hT i)) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/ExponentialLifts.lean b/lean/OAI/Analysis/BoundedHochschild/ExponentialLifts.lean new file mode 100644 index 0000000000000000000000000000000000000000..c313836307cbd3ad5c3d264ea77074ce7330ccc1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/ExponentialLifts.lean @@ -0,0 +1,134 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PathWords + +namespace OAI + +/-! Self-adjoint and exponential lifts in tracial ultrapowers. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +namespace HochschildUltrapower +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1=1) (ω : Ultrafilter ℕ) + (htr : ∀ a b : A, τ (a*b)=τ (b*a)) + + + +theorem exists_selfAdjoint_lift (h : selfAdjoint (Ultrapower τ h1 ω htr)) : + ∃ a : selfAdjoint (ℕ →ᵇ A), quotientHom τ h1 ω htr (a : ℕ →ᵇ A) = (h : Ultrapower τ h1 ω htr) := by + obtain ⟨x,hx⟩ := Ideal.Quotient.mk_surjective (h : Ultrapower τ h1 ω htr) + refine ⟨selfAdjointPart ℝ x,?_⟩ + change quotientHom τ h1 ω htr x = (h : Ultrapower τ h1 ω htr) at hx + rw [selfAdjointPart_apply_coe,← Complex.coe_smul,map_smul,map_add,map_star,hx,h.property] + simp only [← two_smul ℂ,smul_smul,← Complex.ofReal_ofNat,← Complex.ofReal_mul, + invOf_mul_self,Complex.ofReal_one,one_smul] + + + +theorem exists_expUnitary_lift (h : selfAdjoint (Ultrapower τ h1 ω htr)) : + ∃ u : unitary (ℕ →ᵇ A), quotientHom τ h1 ω htr (u : ℕ →ᵇ A) = + (selfAdjoint.expUnitary h : Ultrapower τ h1 ω htr) := by + obtain ⟨a,ha⟩ := exists_selfAdjoint_lift τ h1 ω htr h + refine ⟨selfAdjoint.expUnitary a,?_⟩ + let : NormedAlgebra ℚ (ℕ →ᵇ A) := .restrictScalars ℚ ℂ _ + let : NormedAlgebra ℚ (Ultrapower τ h1 ω htr) := .restrictScalars ℚ ℂ _ + rw [selfAdjoint.expUnitary_coe,selfAdjoint.expUnitary_coe, + NormedSpace.map_exp _ ?_,map_smul,ha] + exact map_continuous (quotientHom τ h1 ω htr) + + +def sequenceEval (j : ℕ) : (ℕ →ᵇ A) →⋆ₐ[ℂ] A where + toFun a := a j + map_zero' := rfl + map_one' := rfl + map_add' _ _ := rfl + map_mul' _ _ := rfl + commutes' _ := rfl + map_star' _ := rfl + + + +theorem exists_expUnitary_coordinates {D : Type*} + (h : D → selfAdjoint (Ultrapower τ h1 ω htr)) : + ∃ u : ℕ → D → unitary A, ∀ d, + quotientFamily τ h1 ω htr (fun j => FreeGroup.lift (u j)) (FreeGroup.of d) = + (selfAdjoint.expUnitary (h d) : Ultrapower τ h1 ω htr) := by + choose v hv using fun d => exists_expUnitary_lift τ h1 ω htr (h d) + let u : ℕ → D → unitary A := fun j d => + Unitary.map { (sequenceEval (A := A) j).toMonoidHom with + map_star' := fun _ => rfl } (v d) + refine ⟨u,fun d => ?_⟩ + rw [← hv d] + apply congrArg (quotientHom τ h1 ω htr) + ext j + simp only [boundedHom_apply,FreeGroup.lift_apply_of,u,Unitary.coe_map] + rfl + +end HochschildUltrapower + + + +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildPaths +open HochschildUltrapower HochschildRare +variable {M C D : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + (τ : M →ₚ[ℂ] ℂ) (h1 : τ 1=1) (ω : Ultrafilter ℕ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + + + +theorem simultaneous_paths_of_free_exponentials + (v : C → unitary M) (h : D → selfAdjoint (Ultrapower τ h1 ω htr)) + (B : Subalgebra ℂ (Ultrapower τ h1 ω htr)) (b : C → Bˣ) + (hb : ∀ c, ((b c : B) : Ultrapower τ h1 ω htr)=constant τ h1 ω htr (v c : M)) + (hu : ∀ g : FreeGroup D, g ≠ 1 → + quotientTrace τ h1 ω htr + (freshEvaluation (fun d => Unitary.toUnits (selfAdjoint.expUnitary (h d))) g)=0) + (hfree : HochschildFreeMoments.FreeCoefficients B + (freshEvaluation (fun d => Unitary.toUnits (selfAdjoint.expUnitary (h d)))) + (quotientTrace τ h1 ω htr).toLinearMap) + {T : Type*} [Finite T] (r n : T → ℕ) + (w : ∀ t, Fin (r t) × Fin (n t) → (C ⊕ D) × Bool) + (q : ∀ t, FreeGroup (Fin (r t))) (hq : ∀ t, q t ≠ 1) + (hletters : ∀ t, ∃ (s : Fin (r t) → Fin (n t)) (a : Fin (r t) → D), + (∀ i, (w t (i,s i)).1=Sum.inr (a i)) ∧ + (∀ i z, (w t z).1=Sum.inr (a i) → z=(i,s i))) + (ε : ℝ) (hε : 0 < ε) : + ∃ u : D → unitary M, ∀ t, + ‖τ (FreeGroup.lift (pathValue (Sum.elim v u) (w t)) (q t) : M)‖ < ε := by + obtain ⟨u,hu'⟩ := exists_expUnitary_coordinates τ h1 ω htr h + have he : freshUnits τ h1 ω htr u = + fun d => Unitary.toUnits (selfAdjoint.expUnitary (h d)) := by + funext d + apply Units.ext + exact hu' d + have hhu : ∀ g : FreeGroup D, g ≠ 1 → + quotientTrace τ h1 ω htr (freshEvaluation (freshUnits τ h1 ω htr u) g)=0 := by + simpa only [he] using hu + have hhfree : HochschildFreeMoments.FreeCoefficients B + (freshEvaluation (freshUnits τ h1 ω htr u)) + (quotientTrace τ h1 ω htr).toLinearMap := by + simpa only [he] using hfree + obtain ⟨j,hj⟩ := simultaneous_paths_of_free_lifts τ h1 ω htr v u B b hb + hhu hhfree r n w q hq hletters ε hε + exact ⟨u j,hj⟩ + +end HochschildPaths +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FactorCandidateCompactness.lean b/lean/OAI/Analysis/BoundedHochschild/FactorCandidateCompactness.lean new file mode 100644 index 0000000000000000000000000000000000000000..68fbb9632c99d41c8c332bf76a1eeeddbeb2639d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FactorCandidateCompactness.lean @@ -0,0 +1,116 @@ +import OAI.Analysis.BoundedHochschild.WeakRepresentationAverages + +namespace OAI + +/-! Compact sets of factorization operators whose coefficient maps take +values in the original algebra. The range condition is retained explicitly. -/ + +noncomputable section + +open Topology +open scoped InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {M H K : Type*} [CStarAlgebra M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def representationWeakBall (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (C : ℝ) : + Set (H →WOT[ℂ] H) := + {A | ∃ a : M, ‖a‖ ≤ C ∧ ContinuousLinearMapWOT.ofCLM (σ a) = A} + +def factorCandidates (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) (D : ℝ) : Set (H →WOT[ℂ] K) := + rectangularWeakBall D ∩ {W | ∀ a, weakFactorValue π L a W ∈ + representationWeakBall σ (‖L‖ * D * ‖a‖)} + +lemma factorCandidates_isClosed (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hσ : ∀ C, IsClosed (representationWeakBall σ C)) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) (D : ℝ) : + IsClosed (factorCandidates σ π L D) := by + apply (rectangularWeakBall_isClosed D).inter + simp only [Set.ofPred_forall] + exact isClosed_iInter fun a => + (hσ (‖L‖ * D * ‖a‖)).preimage (weakFactorValue_continuous π L a) + +theorem factorCandidates_isCompact (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hσ : ∀ C, IsClosed (representationWeakBall σ C)) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) (D : ℝ) : + IsCompact (factorCandidates σ π L D) := + (rectangularWeakBall_isCompact D).of_isClosed_subset + (factorCandidates_isClosed σ hσ π L D) (fun _ h => h.1) + +lemma weakFactorValue_norm_le (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) + (a : M) (W : H →WOT[ℂ] K) : + ‖(weakFactorValue π L a W).toCLM‖ ≤ ‖L‖ * ‖a‖ * ‖W.toCLM‖ := by + change ‖L.adjoint.comp ((π a).comp W.toCLM)‖ ≤ _ + calc + _ ≤ ‖L.adjoint‖ * (‖π a‖ * ‖W.toCLM‖) := + (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_mul_of_nonneg_left (ContinuousLinearMap.opNorm_comp_le _ _) (norm_nonneg _)) + _ = ‖L‖ * (‖π a‖ * ‖W.toCLM‖) := by rw [LinearIsometryEquiv.norm_map] + _ ≤ ‖L‖ * (‖a‖ * ‖W.toCLM‖) := by + gcongr + exact NonUnitalStarAlgHom.norm_apply_le π a + _ = _ := by ring + +lemma mem_factorCandidates_of_range (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hσ : Function.Injective σ) (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (L : H →L[ℂ] K) {D : ℝ} {W : H →WOT[ℂ] K} + (hW : ‖W.toCLM‖ ≤ D) + (hrange : ∀ a, ∃ x : M, σ x = (weakFactorValue π L a W).toCLM) : + W ∈ factorCandidates σ π L D := by + refine ⟨hW, fun a => ?_⟩ + obtain ⟨x, hx⟩ := hrange a + refine ⟨x, ?_, congrArg ContinuousLinearMapWOT.ofCLM hx⟩ + calc + ‖x‖ = ‖σ x‖ := (NonUnitalStarAlgHom.norm_map σ hσ x).symm + _ = ‖(weakFactorValue π L a W).toCLM‖ := congrArg norm hx + _ ≤ ‖L‖ * ‖a‖ * ‖W.toCLM‖ := weakFactorValue_norm_le π L a W + _ ≤ ‖L‖ * ‖a‖ * D := mul_le_mul_of_nonneg_left hW (mul_nonneg (norm_nonneg _) (norm_nonneg _)) + _ = ‖L‖ * D * ‖a‖ := by ring + +theorem factorCandidates_realize (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hσ : Function.Injective σ) (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (L : H →L[ℂ] K) {D : ℝ} (hD : 0 ≤ D) {W : H →WOT[ℂ] K} + (hW : W ∈ factorCandidates σ π L D) : + ∃ T : M →L[ℂ] M, ‖T‖ ≤ ‖L‖ * D ∧ + ∀ a, σ (T a) = L.adjoint.comp ((π a).comp W.toCLM) := by + choose t ht he using hW.2 + have he' (a : M) : σ (t a) = L.adjoint.comp ((π a).comp W.toCLM) := + congrArg ContinuousLinearMapWOT.toCLM (he a) + have hadd (a b : M) : t (a + b) = t a + t b := by + apply hσ + rw [map_add, he', he', he'] + apply ContinuousLinearMap.ext + intro ξ + simp only [ContinuousLinearMap.comp_apply, add_apply, map_add] + have hsmul (z : ℂ) (a : M) : t (z • a) = z • t a := by + apply hσ + rw [map_smul, he', he'] + apply ContinuousLinearMap.ext + intro ξ + simp only [ContinuousLinearMap.comp_apply, smul_apply, map_smul] + let tlin : M →ₗ[ℂ] M := { toFun := t, map_add' := hadd, map_smul' := hsmul } + let T := tlin.mkContinuous (‖L‖ * D) ht + exact ⟨T, tlin.mkContinuous_norm_le (mul_nonneg (norm_nonneg _) hD) ht, he'⟩ + +theorem factorCandidates_invariant (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (hσ : Function.Injective σ) (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (L : H →L[ℂ] K) {D : ℝ} (hD : 0 ≤ D) {I : Type*} [Fintype I] + (m : I → M) (hm : ∑ i, m i * star (m i) = 1) : + Set.MapsTo (weakRepresentedRightAverage π σ m) + (factorCandidates σ π L D) (factorCandidates σ π L D) := by + intro W hW + obtain ⟨T, _, hT⟩ := factorCandidates_realize σ hσ π L hD hW + apply mem_factorCandidates_of_range σ hσ π L + · exact (representedRightAverage_norm_le π σ m hm W.toCLM).trans hW.1 + · intro a + exact ⟨finiteRightAverage m T a, representedRightAverage_factorization π σ T L W.toCLM hT m a⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FactorFinitePaths.lean b/lean/OAI/Analysis/BoundedHochschild/FactorFinitePaths.lean new file mode 100644 index 0000000000000000000000000000000000000000..7f1cb1e194e27c9de31637b5d1e1126d2b85e359 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FactorFinitePaths.lean @@ -0,0 +1,82 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.FreeHaarFamilies + +namespace OAI + +/-! Simultaneous fresh-path tests in diffuse finite factors. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open scoped BigOperators ComplexConjugate InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildUltrapower +open BoundedHochschild HochschildRigidity HochschildPatching HochschildComparison +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in + + +theorem finitePathTests_of_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) : HochschildRare.FinitePathTests τ := by + classical + intro C D T _ _ _ hD v r n w q hq hletters ε hε + let ω : Ultrafilter ℕ := Ultrafilter.of (atTop : Filter ℕ) + have hω : (ω : Filter ℕ) ≤ atTop := Ultrafilter.of_le _ + obtain ⟨u,hu⟩ := exists_finite_graded_family e τ hτ h1 htr hfaith hfactor hdiff ω hω v (Finset.univ : Finset D) + have hd : gradedDegree (C := C) (Finset.univ : Finset D)=HochschildPaths.freshProjection := by + apply FreeGroup.ext_hom + intro x + cases x <;> simp [gradedDegree,HochschildPaths.freshProjection] + have ht (t : T) : Tendsto + (fun j => τ (FreeGroup.lift (HochschildRare.pathValue (Sum.elim v (u j)) (w t)) (q t) : M)) + (ω : Filter ℕ) (nhds 0) := by + obtain ⟨s,a,hpos,huniq⟩ := hletters t + have hne := HochschildPaths.freshProjection_pathHom_ne_one (w t) s a hpos huniq (q t) (hq t) + have hz := hu (HochschildPaths.pathHom (w t) (q t)) (by rwa [hd]) + have hc := tendsto_sequenceTrace τ h1 ω + (boundedHom (fun j => mixedFamily v (u j)) (HochschildPaths.pathHom (w t) (q t))) + change Tendsto (fun j => τ (FreeGroup.lift (Sum.elim v (u j)) (HochschildPaths.pathHom (w t) (q t)) : M)) + (ω : Filter ℕ) (nhds (quotientTrace τ h1 ω htr + (quotientFamily τ h1 ω htr (fun j => mixedFamily v (u j)) (HochschildPaths.pathHom (w t) (q t))))) at hc + rw [hz] at hc + simpa only [HochschildPaths.lift_pathValue_formal] using hc + have he : ∀ᶠ j in (ω : Filter ℕ), ∀ t, + ‖τ (FreeGroup.lift (HochschildRare.pathValue (Sum.elim v (u j)) (w t)) (q t) : M)‖ < ε := by + apply eventually_all.mpr + intro t + have hh := (ht t).eventually (Metric.ball_mem_nhds (0:ℂ) hε) + simpa only [Metric.mem_ball,dist_zero_right] using hh + obtain ⟨j,hj⟩ := he.exists + exact ⟨u j,hj⟩ + +end HochschildUltrapower +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FactorPrimitive.lean b/lean/OAI/Analysis/BoundedHochschild/FactorPrimitive.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b90421d94e9129be083bceb297d1533c032f498 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FactorPrimitive.lean @@ -0,0 +1,145 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.DiffuseSubfactor + +namespace OAI + +/-! Bounded Hochschild primitives on diffuse finite factors, with and without separable predual. -/ + +noncomputable section + +open scoped ComplexOrder +namespace BoundedHochschild +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + [TopologicalSpace.SeparableSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem primitive_of_separable_normal_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) + (hnormal : ∀ a : Fin n → M, HasPreadjoint e (f.curryRight a)) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x=f x := by + exact primitive_of_separable_normal_finite_paths e τ h1 htr hfaith + (HochschildSakai.mul_hasPreadjoint e) (HochschildSakai.mul_right_hasPreadjoint e) + hτ (HochschildUltrapower.finitePathTests_of_factor e τ hτ h1 htr hfaith hfactor hdiff) + f hf hnormal + +theorem primitive_of_separable_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖ ≤ 12*‖f‖ ∧ ∀ x, differentialValue g x=f x := by + let F := reducedNormalCocycle e f + let h := normalCorrection e f + obtain ⟨g,hg,hgf⟩ := primitive_of_separable_normal_factor e τ hτ h1 htr hfaith + hfactor hdiff F (reducedNormalCocycle_cocycle e f hf) (reducedNormalCocycle_normal e f) + refine ⟨g+h,?_,?_⟩ + · have hF := reducedNormalCocycle_norm e f + have hh := normalCorrection_norm e f + exact (norm_add_le _ _).trans (by dsimp [F,h] at *; linarith) + · intro x + rw [differentialValue_add,hgf] + exact (normal_correction_identity e f hf x).symm + +end BoundedHochschild + +open scoped ComplexOrder +namespace BoundedHochschild +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem primitive_of_normal_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) + (hnormal : ∀ a : Fin n → M, HasPreadjoint e (f.curryRight a)) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x=f x := by + classical + let hL := HochschildSakai.mul_hasPreadjoint e + let hR := HochschildSakai.mul_right_hasPreadjoint e + obtain ⟨P,_hPn,hP⟩ := HochschildSakai.exists_abstract_star_preadjoint e + apply primitive_of_finite_exactness e hL hR f ‖f‖ (norm_nonneg _) + intro E + let images : Finset M := Finset.univ.image (fun x : Fin (n+1) → E => f (fun i => x i)) + let D : Set M := (E : Set M) ∪ (images : Set M) + have hD : D.Countable := E.countable_toSet.union images.countable_toSet + obtain ⟨S,hS,hDS,hfactorN,hdiffN⟩ := HochschildLocalization.exists_countably_generated_diffuse_subfactor + e τ hL hR P hP hτ h1 htr hfaith hfactor hdiff D hD + let A := StarAlgebra.adjoin ℂ S + let N := WeakAlgebra.closure e A hL hR P hP + let Y := X ⧸ WeakSubspace.preannihilator (WeakAlgebra.linearClosure e A) + let eN : StrongDual ℂ Y ≃ₗᵢ⋆[ℂ] N := WeakAlgebra.predualEquiv e A hL hR P hP + let τN : N →ₚ[ℂ] ℂ := WeakAlgebra.inheritedTrace e τ A hL hR P hP + let : TopologicalSpace.SeparableSpace A := separable_starAdjoin S hS + let : TopologicalSpace.SeparableSpace Y := + WeakAlgebra.separablePredual_of_separable e τ A hL hR P hP hτ hfaith + have h1N : τN 1=1 := h1 + have htrN : ∀ a b : N, τN (a*b)=τN (b*a) := fun a b => htr a.val b.val + have hLN : ∀ a : N, HasPreadjoint eN (ContinuousLinearMap.mul ℂ N a) := + WeakAlgebra.inherited_left_normal e A hL hR P hP + have hτN : TraceInPredual eN τN := + WeakAlgebra.inheritedTrace_normal e τ A hL hR P hP hτ + have hfaithN : ∀ a : N, τN (star a*a)=0 → a=0 := + WeakAlgebra.inheritedTrace_faithful e τ A hL hR P hP hfaith + have hmem (a : M) (ha : a ∈ D) : a ∈ N := + WeakAlgebra.mem_linearClosure e A (StarAlgebra.subset_adjoin ℂ S (hDS ha)) + have hpaths := HochschildUltrapower.finitePathTests_of_factor eN τN hτN h1N htrN hfaithN hfactorN hdiffN + apply finite_exactness_of_separable_subalgebra e eN τ τN h1N htr htrN hL hLN + hτ hτN hfaith hfaithN N.subtype (fun _ => rfl) hpaths + f hf hnormal (E : Set M) + · intro a ha + exact ⟨⟨a,hmem a (Or.inl ha)⟩,rfl⟩ + · intro x hx + have hm : f x ∈ images := by + apply Finset.mem_image.mpr + refine ⟨fun i => ⟨x i,hx i⟩,Finset.mem_univ _,?_⟩ + rfl + exact ⟨⟨f x,hmem _ (Or.inr hm)⟩,rfl⟩ + +theorem primitive_of_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖ ≤ 12*‖f‖ ∧ ∀ x, differentialValue g x=f x := by + let F := reducedNormalCocycle e f + let h := normalCorrection e f + obtain ⟨g,hg,hgf⟩ := primitive_of_normal_factor e τ hτ h1 htr hfaith + hfactor hdiff F (reducedNormalCocycle_cocycle e f hf) (reducedNormalCocycle_normal e f) + refine ⟨g+h,?_,?_⟩ + · have hF := reducedNormalCocycle_norm e f + have hh := normalCorrection_norm e f + exact (norm_add_le _ _).trans (by dsimp [F,h] at *; linarith) + · intro x + rw [differentialValue_add,hgf] + exact (normal_correction_identity e f hf x).symm + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FactorizedProjectionDefects.lean b/lean/OAI/Analysis/BoundedHochschild/FactorizedProjectionDefects.lean new file mode 100644 index 0000000000000000000000000000000000000000..8448f454dccc096aed686a0d9e7ee3a02bebc10a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FactorizedProjectionDefects.lean @@ -0,0 +1,36 @@ +import OAI.Analysis.BoundedHochschild.RepresentedRightAverages + +namespace OAI + +/-! The right-module defect at a projection is an off-diagonal coefficient +of the fixed operator factorization. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M H K : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma factorized_projection_defect (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (L W : H →L[ℂ] K) (T : M →L[ℂ] M) + (hT : ∀ a, σ (T a) = L.adjoint.comp ((π a).comp W)) + (a : M) {p f : M} (hp : IsStarProjection p) (hf : IsStarProjection f) (hfp : f ≤ p) : + (σ (T a * p - T (a * p) * p)).comp (σ f) = + (L.adjoint.comp (π a)).comp ((1 - π p).comp (W.comp (σ f))) := by + have hpf : (σ p).comp (σ f) = σ f := by + change σ p * σ f = σ f + rw [← map_mul, (hf.le_iff_mul_eq_right hp).mp hfp] + rw [map_sub, map_mul, map_mul, hT, hT, map_mul] + ext ξ + have hpf' := congrArg (fun A : H →L[ℂ] H => A ξ) hpf + change σ p (σ f ξ) = σ f ξ at hpf' + simp only [mul_apply_eq_comp, sub_apply, ContinuousLinearMap.comp_apply, map_sub, one_apply_eq_self, + hpf'] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteBarCancellation.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteBarCancellation.lean new file mode 100644 index 0000000000000000000000000000000000000000..a787a0573cd05da83a722942d862cd17c343f965 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteBarCancellation.lean @@ -0,0 +1,151 @@ +import OAI.Analysis.BoundedHochschild.AveragedBarFaces + +namespace OAI + +/-! Finite signed cancellation of the averaged bar-insertion faces. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M G : Type*} [CStarAlgebra M] [Group G] [Fintype G] + +private def faceShuffle (n : ℕ) : + (Fin (n + 2) × Fin (n + 1)) ≃ (Fin (n + 2) × Fin (n + 1)) where + toFun p := (p.1.succAbove p.2, p.2.predAbove p.1) + invFun p := (p.1.succAbove p.2, p.2.predAbove p.1) + left_inv p := by + exact Prod.ext (Fin.succAbove_succAbove_predAbove p.1 p.2) + (Fin.predAbove_predAbove_succAbove p.1 p.2) + right_inv p := by + exact Prod.ext (Fin.succAbove_succAbove_predAbove p.1 p.2) + (Fin.predAbove_predAbove_succAbove p.1 p.2) + +private lemma sum_faceShuffle {n : ℕ} (F : Fin (n + 2) → Fin (n + 1) → Cochain M (n + 2)) : + (∑ j : Fin (n + 2), ∑ k : Fin (n + 1), F (j.succAbove k) (k.predAbove j)) = + ∑ i : Fin (n + 2), ∑ q : Fin (n + 1), F i q := by + simpa only [Fintype.sum_prod_type] using + Fintype.sum_equiv (faceShuffle n) + (fun p => F (p.1.succAbove p.2) (p.2.predAbove p.1)) + (fun p => F p.1 p.2) (fun _ => rfl) + +private lemma bar_middle_adjacent (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 2)) (j : Fin (n + 2)) : + ((-1 : ℂ) ^ (j.val + j.val + 1)) • + finiteGroupBarInsertion ρ j.castSucc (middleCoboundary f j) + + ((-1 : ℂ) ^ (j.val + 1 + j.val + 1)) • + finiteGroupBarInsertion ρ j.succ (middleCoboundary f j) = 0 := by + rw [finiteGroupBarInsertion_middle_castSucc, finiteGroupBarInsertion_middle_succ] + have h : j.val + 1 + j.val + 1 = (j.val + j.val + 1) + 1 := by omega + have hp : (-1 : ℂ) ^ (j.val + 1 + j.val + 1) = + -((-1 : ℂ) ^ (j.val + j.val + 1)) := by + rw [h, pow_succ] + ring + rw [hp, neg_smul, add_neg_cancel] + +private lemma bar_middle_off_face (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 2)) (j : Fin (n + 2)) (k : Fin (n + 1)) : + finiteGroupBarInsertion ρ (j.castSucc.succAbove (j.succAbove k)) + (middleCoboundary f j) = + middleCoboundary (finiteGroupBarInsertion ρ (j.succAbove k) f) (k.predAbove j) := by + by_cases hkj : k.castSucc < j + · have hj0 : j ≠ 0 := by + intro hj + subst j + exact (not_lt_zero hkj) + let q : Fin (n + 1) := j.pred hj0 + have hq : q.succ = j := Fin.succ_pred _ _ + have hi : j.succAbove k = k.castSucc := Fin.succAbove_of_castSucc_lt _ _ hkj + have hp : k.predAbove j = q := Fin.predAbove_of_castSucc_lt _ _ hkj + have ht : j.castSucc.succAbove (j.succAbove k) = k.castSucc.castSucc := by + rw [hi, Fin.succAbove_of_castSucc_lt] + exact hkj + rw [ht, hi, hp, ← hq] + exact finiteGroupBarInsertion_middle_after ρ f k.castSucc q (by + have hv : k.val < j.val := hkj + dsimp [q] + omega) + · have hjk : j.val ≤ k.val := le_of_not_gt hkj + have hjlast : j ≠ Fin.last (n + 1) := by + intro hj + subst j + have hk := k.isLt + simp only [Fin.val_last] at hjk + omega + let q : Fin (n + 1) := j.castPred hjlast + have hq : q.castSucc = j := Fin.castSucc_castPred _ _ + have hi : j.succAbove k = k.succ := Fin.succAbove_of_le_castSucc _ _ (le_of_not_gt hkj) + have hp : k.predAbove j = q := Fin.predAbove_of_le_castSucc _ _ (le_of_not_gt hkj) + have ht : j.castSucc.succAbove (j.succAbove k) = k.succ.succ := by + rw [hi, Fin.succAbove_of_le_castSucc] + simp only [Fin.le_def, Fin.val_castSucc, Fin.val_succ] + omega + rw [ht, hi, hp, ← hq] + exact finiteGroupBarInsertion_middle_before ρ f k.succ q (by + dsimp [q] + omega) + +private lemma bar_middle_row (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 2)) (j : Fin (n + 2)) : + (∑ i : Fin (n + 3), ((-1 : ℂ) ^ (i.val + j.val + 1)) • + finiteGroupBarInsertion ρ i (middleCoboundary f j)) = + ∑ k : Fin (n + 1), + ((-1 : ℂ) ^ ((j.castSucc.succAbove (j.succAbove k)).val + j.val + 1)) • + finiteGroupBarInsertion ρ (j.castSucc.succAbove (j.succAbove k)) + (middleCoboundary f j) := by + rw [Fin.sum_univ_succAbove _ j.castSucc, Fin.sum_univ_succAbove _ j] + simp only [Fin.succAbove_castSucc_self, Fin.val_castSucc, Fin.val_succ] + rw [← add_assoc, bar_middle_adjacent, zero_add] + +private lemma bar_middle_off_parity {n : ℕ} (j : Fin (n + 2)) (k : Fin (n + 1)) : + (j.castSucc.succAbove (j.succAbove k)).val + j.val + 1 = + (j.succAbove k).val + (k.predAbove j).val + 2 := by + by_cases hkj : k.castSucc < j + · rw [Fin.succAbove_of_castSucc_lt j k hkj, + Fin.predAbove_of_castSucc_lt k j hkj, + Fin.succAbove_of_castSucc_lt j.castSucc k.castSucc hkj] + change k.val + j.val + 1 = k.val + (j.val - 1) + 2 + have hv : k.val < j.val := hkj + omega + · have hjk := le_of_not_gt hkj + rw [Fin.succAbove_of_le_castSucc j k hjk, + Fin.predAbove_of_le_castSucc k j hjk, + Fin.succAbove_of_le_castSucc j.castSucc k.succ (by + simp only [Fin.le_def, Fin.val_castSucc, Fin.val_succ] at * + omega)] + change (k.val + 1 + 1) + j.val + 1 = (k.val + 1) + j.val + 2 + omega + +private lemma bar_middle_off_signed (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 2)) (j : Fin (n + 2)) (k : Fin (n + 1)) : + ((-1 : ℂ) ^ ((j.castSucc.succAbove (j.succAbove k)).val + j.val + 1)) • + finiteGroupBarInsertion ρ (j.castSucc.succAbove (j.succAbove k)) + (middleCoboundary f j) = + -(((-1 : ℂ) ^ ((j.succAbove k).val + (k.predAbove j).val + 1)) • + middleCoboundary (finiteGroupBarInsertion ρ (j.succAbove k) f) (k.predAbove j)) := by + rw [bar_middle_off_face, bar_middle_off_parity] + have hp : (-1 : ℂ) ^ ((j.succAbove k).val + (k.predAbove j).val + 2) = + -((-1 : ℂ) ^ ((j.succAbove k).val + (k.predAbove j).val + 1)) := by + rw [show (j.succAbove k).val + (k.predAbove j).val + 2 = + ((j.succAbove k).val + (k.predAbove j).val + 1) + 1 by omega, pow_succ] + ring + rw [hp, neg_smul] + +lemma finite_bar_middle_double_sum (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 2)) : + (∑ j : Fin (n + 2), ∑ i : Fin (n + 3), + ((-1 : ℂ) ^ (i.val + j.val + 1)) • finiteGroupBarInsertion ρ i (middleCoboundary f j)) = + -(∑ i : Fin (n + 2), ∑ q : Fin (n + 1), + ((-1 : ℂ) ^ (i.val + q.val + 1)) • + middleCoboundary (finiteGroupBarInsertion ρ i f) q) := by + simp_rw [bar_middle_row, bar_middle_off_signed] + simp only [Finset.sum_neg_distrib] + congr 1 + exact sum_faceShuffle (fun i q => ((-1 : ℂ) ^ (i.val + q.val + 1)) • + middleCoboundary (finiteGroupBarInsertion ρ i f) q) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteBarHomotopy.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteBarHomotopy.lean new file mode 100644 index 0000000000000000000000000000000000000000..5607171c1217693418e67fa083d0bfed567ed4e5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteBarHomotopy.lean @@ -0,0 +1,117 @@ +import OAI.Analysis.BoundedHochschild.FiniteBarCancellation + +namespace OAI + +/-! The bounded finite-group bar homotopy from the identity to the full +cochain average. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M G : Type*} [CStarAlgebra M] [Group G] [Fintype G] + +lemma finiteGroupBarOperator_sum {I : Type*} {n : ℕ} (ρ : G →* unitary M) + (s : Finset I) (f : I → Cochain M (n + 1)) : + finiteGroupBarOperator ρ (∑ i ∈ s, f i) = ∑ i ∈ s, finiteGroupBarOperator ρ (f i) := + map_sum (finiteGroupBarOperatorCLM ρ n) f s + +lemma finiteGroupBarOperator_leftCoboundary {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) : + finiteGroupBarOperator ρ (leftCoboundary f) = + f - leftCoboundary (finiteGroupBarOperator ρ f) := by + have he : leftCoboundary (finiteGroupBarOperator ρ f) = + ∑ i : Fin (n + 1), ((-1 : ℂ) ^ i.val) • + leftCoboundary (finiteGroupBarInsertion ρ i f) := by + change leftFaceLinear n (∑ i : Fin (n + 1), ((-1 : ℂ) ^ i.val) • + finiteGroupBarInsertion ρ i f) = _ + rw [map_sum] + simp only [map_smul] + rfl + rw [he] + change (∑ i : Fin (n + 2), ((-1 : ℂ) ^ i.val) • + finiteGroupBarInsertion ρ i (leftCoboundary f)) = _ + rw [Fin.sum_univ_succ] + simp only [Fin.val_zero, pow_zero, one_smul, finiteGroupBarInsertion_left_zero, + Fin.val_succ, finiteGroupBarInsertion_left_succ] + rw [sub_eq_add_neg, ← Finset.sum_neg_distrib] + congr 1 + apply Finset.sum_congr rfl + intro i _ + rw [pow_succ, mul_neg, mul_one, neg_smul] + +lemma finiteGroupBarOperator_rightCoboundary {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) : + finiteGroupBarOperator ρ (rightCoboundary f) = + rightCoboundary (finiteGroupBarOperator ρ f) + + ((-1 : ℂ) ^ (n + 1)) • finiteGroupCochainAverage ρ f := by + have he : rightCoboundary (finiteGroupBarOperator ρ f) = + ∑ i : Fin (n + 1), ((-1 : ℂ) ^ i.val) • + rightCoboundary (finiteGroupBarInsertion ρ i f) := by + change rightFaceLinear n (∑ i : Fin (n + 1), ((-1 : ℂ) ^ i.val) • + finiteGroupBarInsertion ρ i f) = _ + rw [map_sum] + simp only [map_smul] + rfl + rw [he] + change (∑ i : Fin (n + 2), ((-1 : ℂ) ^ i.val) • + finiteGroupBarInsertion ρ i (rightCoboundary f)) = _ + rw [Fin.sum_univ_castSucc] + simp only [Fin.val_castSucc, Fin.val_last, finiteGroupBarInsertion_right_castSucc, + finiteGroupBarInsertion_right_last] + +lemma finiteGroupBarOperator_middleSum {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 2)) : + finiteGroupBarOperator ρ (∑ j : Fin (n + 2), ((-1 : ℂ) ^ (j.val + 1)) • middleCoboundary f j) = + -(∑ q : Fin (n + 1), ((-1 : ℂ) ^ (q.val + 1)) • + middleCoboundary (finiteGroupBarOperator ρ f) q) := by + have he (q : Fin (n + 1)) : middleCoboundary (finiteGroupBarOperator ρ f) q = + ∑ i : Fin (n + 2), ((-1 : ℂ) ^ i.val) • + middleCoboundary (finiteGroupBarInsertion ρ i f) q := by + change middleFaceLinear q (∑ i : Fin (n + 2), ((-1 : ℂ) ^ i.val) • + finiteGroupBarInsertion ρ i f) = _ + rw [map_sum] + simp only [map_smul] + rfl + simp_rw [he] + rw [finiteGroupBarOperator_sum] + simp_rw [finiteGroupBarOperator_smul] + simp only [finiteGroupBarOperator, + Finset.smul_sum, smul_smul, ← pow_add] + have hleft (j : Fin (n + 2)) (i : Fin (n + 3)) : j.val + 1 + i.val = i.val + j.val + 1 := by omega + have hright (q : Fin (n + 1)) (i : Fin (n + 2)) : q.val + 1 + i.val = i.val + q.val + 1 := by omega + simp only [hleft, hright] + rw [Finset.sum_comm (f := fun q : Fin (n + 1) => fun i : Fin (n + 2) => + ((-1 : ℂ) ^ (i.val + q.val + 1)) • middleCoboundary (finiteGroupBarInsertion ρ i f) q)] + exact finite_bar_middle_double_sum ρ f + +/-- The explicit degree-bounded finite-group operator is a cochain homotopy. -/ +theorem finiteGroupBarOperator_homotopy {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 2)) : + differential (finiteGroupBarOperator ρ f) + finiteGroupBarOperator ρ (differential f) = + f - finiteGroupCochainAverage ρ f := by + change (leftCoboundary (finiteGroupBarOperator ρ f) + + (∑ q : Fin (n + 1), ((-1 : ℂ) ^ (q.val + 1)) • + middleCoboundary (finiteGroupBarOperator ρ f) q) + + ((-1 : ℂ) ^ (n + 2)) • rightCoboundary (finiteGroupBarOperator ρ f)) + + finiteGroupBarOperator ρ (leftCoboundary f + + (∑ j : Fin (n + 2), ((-1 : ℂ) ^ (j.val + 1)) • middleCoboundary f j) + + ((-1 : ℂ) ^ (n + 3)) • rightCoboundary f) = _ + rw [finiteGroupBarOperator_add, finiteGroupBarOperator_add, + finiteGroupBarOperator_smul, finiteGroupBarOperator_leftCoboundary, + finiteGroupBarOperator_middleSum, finiteGroupBarOperator_rightCoboundary, + smul_add, smul_smul] + have hsign : (-1 : ℂ) ^ (n + 3) = -((-1 : ℂ) ^ (n + 2)) := by + rw [show n + 3 = (n + 2) + 1 by omega, pow_succ] + ring + have hprod : (-1 : ℂ) ^ (n + 3) * (-1 : ℂ) ^ (n + 2) = -1 := by + rw [hsign, neg_mul, ← mul_pow] + norm_num + rw [hprod, hsign, neg_smul, neg_one_smul] + abel + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteCentralDecomposition.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteCentralDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..4fb97d96bdedc62654f42c5a6da0a8e2e2484725 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteCentralDecomposition.lean @@ -0,0 +1,208 @@ +import OAI.Analysis.BoundedHochschild.CentralProjectionSuprema +import OAI.Analysis.BoundedHochschild.Conditional + +namespace OAI + +/-! The maximal finite central cut, constructed without an assumed trace. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Finiteness of a corner, expressed in the ambient algebra. -/ +def FiniteCorner (p : M) : Prop := + ∀ a : M, p * a = a → a * p = a → star a * a = p → a * star a = p + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteCorner_iff (p : M) (hp : IsStarProjection p) : + FiniteCorner p ↔ FiniteAlgebra (HochschildCorners.Corner p hp) := by + constructor + · intro h a ha + apply Subtype.ext + exact h a a.property.1 a.property.2 (congrArg Subtype.val ha) + · intro h a hL hR ha + let b : HochschildCorners.Corner p hp := ⟨a, hL, hR⟩ + exact congrArg Subtype.val (h b (Subtype.ext ha)) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteCorner_zero : FiniteCorner (0 : M) := by + intro a hL _ _ + have ha : a = 0 := by simpa using hL.symm + simp [ha] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteCorner_of_finiteAlgebra (hfinite : FiniteAlgebra M) + (p : M) (hp : IsStarProjection p) : FiniteCorner p := by + intro a hL hR haa + have hsL : star a * p = star a := by + simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star hL + have hsR : p * star a = star a := by + simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star hR + have hca : (1 - p) * a = 0 := by rw [sub_mul, one_mul, hL, sub_self] + have hac : a * (1 - p) = 0 := by rw [mul_sub, mul_one, hR, sub_self] + have hcsa : (1 - p) * star a = 0 := by rw [sub_mul, one_mul, hsR, sub_self] + have hsac : star a * (1 - p) = 0 := by rw [mul_sub, mul_one, hsL, sub_self] + have hin : star (a + (1 - p)) * (a + (1 - p)) = 1 := by + simp only [star_add, star_sub, star_one, hp.isSelfAdjoint.star_eq, + add_mul, mul_add, hsac, hca, zero_add, add_zero, haa, + hp.one_sub.isIdempotentElem.eq] + abel + have hout := hfinite (a + (1 - p)) hin + simp only [star_add, star_sub, star_one, hp.isSelfAdjoint.star_eq, + add_mul, mul_add, hac, hcsa, zero_add, add_zero, + hp.one_sub.isIdempotentElem.eq] at hout + have hp1 : p + (1 - p) = 1 := by abel + exact add_right_cancel (hout.trans hp1.symm) + +lemma finiteCorner_compressed_final {p q : M} (hp : IsStarProjection p) + (hq : IsStarProjection q) (hc : ∀ b : M, q * b = b * q) + (hqp : q ≤ p) (hfinite : FiniteCorner q) + (a : M) (haa : star a * a = p) : q * (a * star a) = q := by + have hL : q * (q * a) = q * a := by rw [← mul_assoc, hq.isIdempotentElem.eq] + have hR : (q * a) * q = q * a := by rw [mul_assoc, ← hc a, hL] + have hstar : star (q * a) = q * star a := by + rw [star_mul, hq.isSelfAdjoint.star_eq, hc] + have hin : star (q * a) * (q * a) = q := by + rw [hstar, central_idempotent_mul q hq.isIdempotentElem.eq hc, haa] + exact (hq.le_iff_mul_eq_left hp).mp hqp + have hout := hfinite (q * a) hL hR hin + rw [hstar, central_idempotent_mul q hq.isIdempotentElem.eq hc] at hout + exact hout + +lemma finiteCorner_orthogonal_sum {p q : M} (hp : IsStarProjection p) + (hq : IsStarProjection q) (hcp : ∀ a : M, p * a = a * p) + (hcq : ∀ a : M, q * a = a * q) (hpq : p * q = 0) + (hfp : FiniteCorner p) (hfq : FiniteCorner q) : FiniteCorner (p + q) := by + have hs := hp.add hq hpq + intro a hL _ haa + have hp' := finiteCorner_compressed_final hs hp hcp + (le_add_of_nonneg_right hq.nonneg) hfp a haa + have hq' := finiteCorner_compressed_final hs hq hcq + (le_add_of_nonneg_left hp.nonneg) hfq a haa + calc + a * star a = (p + q) * (a * star a) := by rw [← mul_assoc, hL] + _ = p + q := by rw [add_mul, hp', hq'] + +lemma finiteCorner_chain_sup (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (S : Set M) (hne : S.Nonempty) (hchain : IsChain (· ≤ ·) S) + (hS : ∀ q ∈ S, IsStarProjection q ∧ (∀ a : M, q * a = a * q) ∧ FiniteCorner q) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ + FiniteCorner p ∧ ∀ q ∈ S, q ≤ p := by + obtain ⟨p, hp, hcp, hupper, _, hann⟩ := exists_central_projection_chain_supremum + e S hne hchain (fun q hq => (hS q hq).1) (fun q hq => (hS q hq).2.1) + refine ⟨p, hp, hcp, ?_, hupper⟩ + intro a hL _ haa + have hzero : p * (p - a * star a) = 0 := by + apply hann + intro q hq + rw [mul_sub, ( (hS q hq).1.le_iff_mul_eq_left hp).mp (hupper q hq), + finiteCorner_compressed_final hp (hS q hq).1 (hS q hq).2.1 + (hupper q hq) (hS q hq).2.2 a haa, sub_self] + rw [mul_sub, hp.isIdempotentElem.eq, ← mul_assoc, hL] at hzero + exact (sub_eq_zero.mp hzero).symm + +/-- Every W*-algebra has a finite central cut with no finite central subprojection +in its complement. This part of the classical type decomposition needs no trace. -/ +theorem exists_maximal_finite_central_cut (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ FiniteCorner p ∧ + ∀ q : M, IsStarProjection q → (∀ a : M, q * a = a * q) → + FiniteCorner q → q ≤ 1 - p → q = 0 := by + classical + let S : Set M := {p | IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ FiniteCorner p} + have hz : (0 : M) ∈ S := ⟨IsStarProjection.zero M, fun a => by simp, finiteCorner_zero⟩ + obtain ⟨p, _, hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain a ha => by + obtain ⟨s, hs, hcs, hfs, hupper⟩ := finiteCorner_chain_sup e c ⟨a, ha⟩ hchain + (fun q hq => hc hq) + exact ⟨s, ⟨hs, hcs, hfs⟩, hupper⟩) 0 hz + have hp := hmax.1.1 + have hcp := hmax.1.2.1 + have hfp := hmax.1.2.2 + refine ⟨p, hp, hcp, hfp, ?_⟩ + intro q hq hcq hfq hqp + have hpq : p * q = 0 := by + have h := (hq.le_iff_mul_eq_right hp.one_sub).mp hqp + rw [sub_mul, one_mul] at h + exact sub_eq_self.mp h + have hs : p + q ∈ S := ⟨hp.add hq hpq, + fun a => by rw [add_mul, mul_add, hcp, hcq], + finiteCorner_orthogonal_sum hp hq hcp hcq hpq hfp hfq⟩ + have hle : p ≤ p + q := le_add_of_nonneg_right hq.nonneg + have he : p + q = p := le_antisymm (hmax.2 hs hle) hle + exact add_eq_left.mp he + +omit [PartialOrder M] [StarOrderedRing M] in +lemma centralCorner_central {p : M} (hp : IsStarProjection p) + (hc : ∀ a : M, p * a = a * p) (q : HochschildCorners.Corner p hp) + (hqc : ∀ b : HochschildCorners.Corner p hp, q * b = b * q) : + ∀ a : M, (q : M) * a = a * (q : M) := by + intro a + have h := congrArg Subtype.val (hqc (CentralCorner.compressMap p hp hc a)) + change (q : M) * (p * a) = (p * a) * (q : M) at h + calc + (q : M) * a = ((q : M) * p) * a := by rw [q.property.2] + _ = (q : M) * (p * a) := mul_assoc _ _ _ + _ = (p * a) * (q : M) := h + _ = a * (p * (q : M)) := by rw [hc a, mul_assoc] + _ = a * (q : M) := by rw [q.property.1] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteCorner_trans {p : M} (hp : IsStarProjection p) + (q : HochschildCorners.Corner p hp) (hfinite : FiniteCorner q) : + FiniteCorner (q : M) := by + intro a hL hR haa + have hpL : p * a = a := by + calc + p * a = p * ((q : M) * a) := by rw [hL] + _ = a := by rw [← mul_assoc, q.property.1, hL] + have hpR : a * p = a := by + calc + a * p = (a * (q : M)) * p := by rw [hR] + _ = a := by rw [mul_assoc, q.property.2, hR] + let b : HochschildCorners.Corner p hp := ⟨a, hpL, hpR⟩ + exact congrArg Subtype.val + (hfinite b (Subtype.ext hL) (Subtype.ext hR) (Subtype.ext haa)) + +/-- Finiteness passes to every subprojection, without a centrality hypothesis. -/ +lemma finiteCorner_mono {p q : M} (hp : IsStarProjection p) + (hq : IsStarProjection q) (hpq : p ≤ q) (hfinite : FiniteCorner q) : + FiniteCorner p := by + let pC : HochschildCorners.Corner q hq := + ⟨p, (hp.le_iff_mul_eq_right hq).mp hpq, (hp.le_iff_mul_eq_left hq).mp hpq⟩ + have hpC : IsStarProjection pC := + ⟨Subtype.ext hp.isIdempotentElem.eq, Subtype.ext hp.isSelfAdjoint.star_eq⟩ + exact finiteCorner_trans hq pC + (finiteCorner_of_finiteAlgebra ((finiteCorner_iff q hq).mp hfinite) pC hpC) + +/-- The complementary corner of a maximal finite central cut has no II₁ summand. -/ +theorem exists_finite_central_cut_noTypeII1 (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + ∃ (p : M) (hp : IsStarProjection p), (∀ a : M, p * a = a * p) ∧ + FiniteAlgebra (HochschildCorners.Corner p hp) ∧ + NoTypeII1Summand (HochschildCorners.Corner (1 - p) hp.one_sub) := by + obtain ⟨p, hp, hc, hf, hmax⟩ := exists_maximal_finite_central_cut e + refine ⟨p, hp, hc, (finiteCorner_iff p hp).mp hf, ?_⟩ + intro q hq hqc hqfinite _ + have hqM : IsStarProjection (q : M) := + ⟨congrArg Subtype.val hq.isIdempotentElem.eq, + congrArg Subtype.val hq.isSelfAdjoint.star_eq⟩ + have hc' : ∀ a : M, (1 - p) * a = a * (1 - p) := by + intro a + simp only [sub_mul, mul_sub, one_mul, mul_one, hc] + have hqcM := centralCorner_central hp.one_sub hc' q hqc + have hqfiniteM : FiniteCorner (q : M) := + finiteCorner_trans hp.one_sub q ((finiteCorner_iff q hq).mpr hqfinite) + have hqle : (q : M) ≤ 1 - p := + (hqM.le_iff_mul_eq_right hp.one_sub).mpr q.property.1 + exact Subtype.ext (hmax (q : M) hqM hqcM hqfiniteM hqle) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteCoefficientExtension.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteCoefficientExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..a039199b79d3af0669e486d369a1ddc87ec05af5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteCoefficientExtension.lean @@ -0,0 +1,54 @@ +import OAI.Analysis.BoundedHochschild.FiniteCompressionExtension + +namespace OAI + +/-! Finite collections of Hilbert-space coefficients admit simultaneous +contractive completely positive extensions. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] [Nontrivial H] + +theorem exists_finite_coefficient_extension (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (hstar : ∀ a ∈ S, star a ∈ S) (φ : S →ₗ[ℂ] (H →L[ℂ] H)) + (hφ1 : φ ⟨1, h1⟩ = 1) + (hφ : ∀ n (X : operatorSystemMatrices S n), + 0 ≤ (X : CStarMatrix (Fin n) (Fin n) A) → + 0 ≤ operatorSystemAmplification S φ n X) (s : Finset H) : + ∃ Ψ : CompletelyPositiveMap A (H →L[ℂ] H), + (∀ a, ‖Ψ a‖ ≤ ‖a‖) ∧ ∀ (a : S) (ξ : H), ξ ∈ s → ∀ η ∈ s, + inner ℂ η (Ψ (a : A) ξ) = inner ℂ η (φ a ξ) := by + classical + obtain ⟨ζ, hζ⟩ := exists_ne (0 : H) + let t := insert ζ s + let E := Submodule.span ℂ (t : Set H) + let : FiniteDimensional ℂ E := FiniteDimensional.span_finset ℂ t + let ζE : E := ⟨ζ, Submodule.subset_span (Finset.mem_insert_self ζ s)⟩ + let : Nontrivial E := ⟨⟨ζE, 0, fun h => hζ (congrArg Subtype.val h)⟩⟩ + let b := stdOrthonormalBasis ℂ E + let V : EuclideanSpace ℂ (Fin (Module.finrank ℂ E)) →ₗᵢ[ℂ] H := + E.subtypeₗᵢ.comp b.repr.symm.toLinearIsometry + let i₀ : Fin (Module.finrank ℂ E) := ⟨0, Module.finrank_pos⟩ + obtain ⟨Ψ, hΨ, hcoeff⟩ := exists_finite_compression_extension S h1 hstar φ hφ1 i₀ V + (hφ (Module.finrank ℂ E)) + refine ⟨Ψ, hΨ, fun a ξ hξ η hη => ?_⟩ + let ξE : E := ⟨ξ, Submodule.subset_span (Finset.mem_insert_of_mem hξ)⟩ + let ηE : E := ⟨η, Submodule.subset_span (Finset.mem_insert_of_mem hη)⟩ + have hξE : V (b.repr ξE) = ξ := by + change ((b.repr.symm (b.repr ξE) : E) : H) = ξ + rw [b.repr.symm_apply_apply] + have hηE : V (b.repr ηE) = η := by + change ((b.repr.symm (b.repr ηE) : E) : H) = η + rw [b.repr.symm_apply_apply] + simpa only [hξE, hηE] using hcoeff a (b.repr ξE) (b.repr ηE) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteColumnCorners.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteColumnCorners.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca86d797b8cca968b41752dbeab8e673ac7c6ff4 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteColumnCorners.lean @@ -0,0 +1,72 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixSpan +import OAI.Analysis.BoundedHochschild.SignedMatrixUnitaries +import OAI.Analysis.BoundedHochschild.MatrixAmplification + +namespace OAI + +/-! Finite initial sections of a countable matrix system form full matrix +systems in their actual (possibly proper) corners. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison HochschildCorners HochschildMatrixSystems + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + {n : ℕ} (c : Fin n → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + +def finiteColumnProjection : M := ∑ i, (c i).final + +omit [PartialOrder M] [StarOrderedRing M] in +include ho in +lemma finiteColumnProjection_isProjection : IsStarProjection (finiteColumnProjection c) := + orthogonal_projection_finset_sum (fun i => (c i).final) (fun i => (c i).final_proj) + ho Finset.univ + +omit [PartialOrder M] [StarOrderedRing M] in +include hi ho in +lemma finiteColumnProjection_mul_column (j : Fin n) : + finiteColumnProjection c * (c j : M) = (c j : M) := by + classical + simp only [finiteColumnProjection, PartialIso.final, Finset.sum_mul, mul_assoc] + simp [column_star_mul c hi ho] + +omit [PartialOrder M] [StarOrderedRing M] in +include hi ho in +lemma column_star_mul_finiteColumnProjection (j : Fin n) : + star (c j : M) * finiteColumnProjection c = star (c j : M) := by + have h := congrArg star (finiteColumnProjection_mul_column c hi ho j) + simpa only [star_mul, finiteColumnProjection, star_sum, PartialIso.final, star_star] using h + +def finiteColumnMatrixSystem : + MatrixSystem (Corner (finiteColumnProjection c) (finiteColumnProjection_isProjection c ho)) n where + entry i j := ⟨(c i : M) * star (c j : M), by + constructor + · rw [← mul_assoc, finiteColumnProjection_mul_column c hi ho] + · rw [mul_assoc, column_star_mul_finiteColumnProjection c hi ho]⟩ + star_entry i j := Subtype.ext (by + change star ((c i : M) * star (c j : M)) = (c j : M) * star (c i : M) + simp only [star_mul, star_star]) + entry_mul i j k l := by + apply Subtype.ext + change ((c i : M) * star (c j : M)) * ((c k : M) * star (c l : M)) = _ + calc + _ = (c i : M) * (star (c j : M) * (c k : M)) * star (c l : M) := by + simp only [mul_assoc] + _ = _ := by rw [column_star_mul c hi ho]; split_ifs <;> simp + sum_diagonal := by + apply Subtype.ext + rw [AddSubmonoidClass.coe_finsetSum] + rfl + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma finiteColumnMatrixSystem_entry (i j : Fin n) : + ((finiteColumnMatrixSystem c hi ho).entry i j : M) = (c i : M) * star (c j : M) := rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteCompressionExtension.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteCompressionExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..b6eb996b6c70ec37dbf547cda279e1e71a5f194f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteCompressionExtension.lean @@ -0,0 +1,64 @@ +import OAI.Analysis.BoundedHochschild.FinitePositiveExtension +import OAI.Analysis.BoundedHochschild.OperatorSystemCompression +import OAI.Analysis.BoundedHochschild.CompletelyPositiveNorm + +namespace OAI + +/-! Extend a finite compression and then regard it as a map on the original +Hilbert space. All coefficients on that finite subspace are retained. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +theorem exists_finite_compression_extension (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (hstar : ∀ a ∈ S, star a ∈ S) (φ : S →ₗ[ℂ] (H →L[ℂ] H)) + (hφ1 : φ ⟨1, h1⟩ = 1) {n : ℕ} (i₀ : Fin n) + (V : EuclideanSpace ℂ (Fin n) →ₗᵢ[ℂ] H) + (hφ : ∀ X : operatorSystemMatrices S n, + 0 ≤ (X : CStarMatrix (Fin n) (Fin n) A) → + 0 ≤ operatorSystemAmplification S φ n X) : + ∃ Ψ : CompletelyPositiveMap A (H →L[ℂ] H), + (∀ a, ‖Ψ a‖ ≤ ‖a‖) ∧ ∀ (a : S) ξ η, + inner ℂ (V η) (Ψ (a : A) (V ξ)) = inner ℂ (V η) (φ a (V ξ)) := by + let ψ := compressOperatorSystem S φ V.toContinuousLinearMap + obtain ⟨Φ, hΦ⟩ := exists_finite_completelyPositive_extension S h1 hstar i₀ ψ + (fun X hX => compressOperatorSystem_positive S φ _ X (hφ X hX)) + have hΦ1 : Φ 1 = 1 := (hΦ ⟨1, h1⟩).trans (compressOperatorSystem_one S h1 φ hφ1 V) + let Ψ := compressCompletelyPositive Φ V.toContinuousLinearMap.adjoint + have hV : ‖V.toContinuousLinearMap‖ ≤ 1 := by + apply V.toContinuousLinearMap.opNorm_le_bound zero_le_one + intro ξ + simp only [LinearIsometry.coe_toContinuousLinearMap, V.norm_map, one_mul] + exact le_rfl + have hΨ1 : Ψ 1 = V.toContinuousLinearMap.comp V.toContinuousLinearMap.adjoint := by + change V.toContinuousLinearMap.adjoint.adjoint.comp + ((Φ 1).comp V.toContinuousLinearMap.adjoint) = _ + rw [ContinuousLinearMap.adjoint_adjoint, hΦ1] + rfl + have hn : ‖Ψ 1‖ ≤ 1 := by + rw [hΨ1] + refine (ContinuousLinearMap.opNorm_comp_le _ _).trans ?_ + rw [LinearIsometryEquiv.norm_map] + nlinarith [norm_nonneg V.toContinuousLinearMap] + have hVV (ξ : EuclideanSpace ℂ (Fin n)) : V.toContinuousLinearMap.adjoint (V ξ) = ξ := by + exact congrArg (fun T => T ξ) V.adjoint_comp_self + refine ⟨Ψ, fun a => (completelyPositive_norm_apply_le Ψ a).trans ?_, ?_⟩ + · simpa only [one_mul] using mul_le_mul_of_nonneg_right hn (norm_nonneg a) + · intro a ξ η + change inner ℂ (V η) (V.toContinuousLinearMap.adjoint.adjoint + (Φ (a : A) (V.toContinuousLinearMap.adjoint (V ξ)))) = _ + rw [ContinuousLinearMap.adjoint_inner_right, hVV, hVV, hΦ a] + change inner ℂ η (V.toContinuousLinearMap.adjoint (φ a (V ξ))) = _ + exact ContinuousLinearMap.adjoint_inner_right _ _ _ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteConstraints.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteConstraints.lean new file mode 100644 index 0000000000000000000000000000000000000000..4b11b07507d3c66f076b4f722ea1fa651f4b0e8d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteConstraints.lean @@ -0,0 +1,412 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.NormalModulus + +namespace OAI + +/-! Finite cocycle constraints and exactness for bounded primitives. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma IsSupportProjection.smul {a p : M} (hp : IsSupportProjection a p) + (r : ℝ) (hr : r ≠ 0) : IsSupportProjection (r • a) p := by + refine ⟨hp.proj,?_,?_,?_⟩ + · rw [mul_smul_comm,hp.left] + · rw [smul_mul_assoc,hp.right] + · intro x hx + apply hp.annihilate x + rw [smul_mul_assoc,smul_eq_zero] at hx + exact hx.resolve_left hr + +omit [StarOrderedRing M] in +include htr in +lemma trace_mul_pow_swap (a b : M) (n : ℕ) : τ ((a*b)^n)=τ ((b*a)^n) := by + cases n with + | zero => simp only [pow_zero] + | succ n => rw [pow_succ,← mul_assoc,htr,mul_pow_mul,← mul_assoc,← pow_succ'] + +omit [StarOrderedRing M] in +lemma trace_one_sub_pow {a b : M} (h : ∀ n : ℕ, τ (a^n)=τ (b^n)) (n : ℕ) : + τ ((1-a)^n)=τ ((1-b)^n) := by + have hn (k : ℕ) : τ ((-a)^k)=τ ((-b)^k) := by + rw [show -a=(-1:ℂ) • a by simp,show -b=(-1:ℂ) • b by simp, + smul_pow,smul_pow,map_smul,map_smul,h] + rw [sub_eq_add_neg,sub_eq_add_neg,(Commute.one_left (-a)).add_pow, + (Commute.one_left (-b)).add_pow,map_sum,map_sum] + apply Finset.sum_congr rfl + intro k _hk + simp only [one_pow,one_mul,← nsmul_eq_mul',map_nsmul,hn] + +include e hL hτ htr hfaith in +lemma support_trace_eq_of_moments (a b p q : M) (ha : 0 ≤ a) (hb : 0 ≤ b) + (ha1 : a ≤ 1) (hb1 : b ≤ 1) (hp : IsSupportProjection a p) + (hq : IsSupportProjection b q) (ht : ∀ n : ℕ, τ (a^n)=τ (b^n)) : τ p=τ q := by + obtain ⟨p',hp',hpt⟩ := exists_support_contraction e τ hL hτ htr hfaith a ha ha1 + obtain ⟨q',hq',hqt⟩ := exists_support_contraction e τ hL hτ htr hfaith b hb hb1 + have hp'p : p'=p := hp'.unique hp + have hq'q : q'=q := hq'.unique hq + subst p'; subst q' + have hpa : ∀ n : ℕ, ‖1-(1-a)^n‖ ≤ 2 := fun n => + (norm_sub_le _ _).trans (by + have h := norm_pow_pos_contraction (1-a) (sub_nonneg.mpr ha1) (sub_le_self _ ha) n + have h1 : ‖(1:M)‖ ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ zero_le_one).mpr le_rfl + linarith) + have hqa : ∀ n : ℕ, ‖1-(1-b)^n‖ ≤ 2 := fun n => + (norm_sub_le _ _).trans (by + have h := norm_pow_pos_contraction (1-b) (sub_nonneg.mpr hb1) (sub_le_self _ hb) n + have h1 : ‖(1:M)‖ ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ zero_le_one).mpr le_rfl + linarith) + apply tendsto_nhds_unique (trace_predual_tendsto e τ hτ + (hpt.predual e τ hL hτ hfaith 2 hpa)) + convert trace_predual_tendsto e τ hτ (hqt.predual e τ hL hτ hfaith 2 hqa) using 1 + ext n + simp only [map_sub,trace_one_sub_pow τ ht] + +include e hL hτ htr hfaith in + + +theorem support_trace_star_mul_self (x p q : M) + (hp : IsSupportProjection (star x*x) p) (hq : IsSupportProjection (x*star x) q) : + τ p=τ q := by + let r : ℝ := (‖x‖^2+1)⁻¹ + have hd : 0 < ‖x‖^2+1 := by positivity + have hr : 0 < r := inv_pos.mpr hd + have hpos : 0 ≤ r • (star x*x) := smul_nonneg hr.le (star_mul_self_nonneg x) + have hpos' : 0 ≤ r • (x*star x) := smul_nonneg hr.le (mul_star_self_nonneg x) + have hnorm : ‖r • (star x*x)‖ ≤ 1 := by + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hr,CStarRing.norm_star_mul_self] + exact (inv_mul_le_one₀ hd).mpr (by linarith) + have hnorm' : ‖r • (x*star x)‖ ≤ 1 := by + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hr,CStarRing.norm_self_mul_star] + exact (inv_mul_le_one₀ hd).mpr (by linarith) + apply support_trace_eq_of_moments e τ hL hτ htr hfaith _ _ p q hpos hpos' + ((CStarAlgebra.norm_le_one_iff_of_nonneg _ hpos).mp hnorm) + ((CStarAlgebra.norm_le_one_iff_of_nonneg _ hpos').mp hnorm') + (hp.smul r hr.ne') (hq.smul r hr.ne') + intro n + simp only [smul_pow,← Complex.coe_smul,map_smul,trace_mul_pow_swap τ htr (star x) x] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma IsSupportProjection.star_mul_self_right {x p : M} + (hp : IsSupportProjection (star x*x) p) : x*p=x := by + have h : star (x*(1-p))*(x*(1-p))=0 := by + rw [star_mul,star_sub,star_one,hp.proj.isSelfAdjoint.star_eq] + calc + (1-p)*star x*(x*(1-p)) = (1-p)*((star x*x)*(1-p)) := by simp only [mul_assoc] + _ = 0 := by rw [mul_sub,mul_one,hp.right,sub_self,mul_zero] + have hz := (CStarRing.star_mul_self_eq_zero_iff _).mp h + simpa only [mul_sub,mul_one,sub_eq_zero,eq_comm] using hz + +omit [PartialOrder M] [StarOrderedRing M] in +lemma IsSupportProjection.mul_star_self_left {x p : M} + (hp : IsSupportProjection (x*star x) p) : p*x=x := by + have hh : star x*p=star x := IsSupportProjection.star_mul_self_right + (x := star x) (by simpa only [star_star] using hp) + simpa only [star_mul,star_star,hp.proj.isSelfAdjoint.star_eq] using congrArg Star.star hh + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +lemma IsSupportProjection.left_le {x r p : M} + (hr : IsSupportProjection (x*star x) r) (hp : IsStarProjection p) (hpx : p*x=x) : + r ≤ p := by + apply hr.le_of_support hp + have hx : star x*p=star x := by + simpa only [star_mul,star_star,hp.isSelfAdjoint.star_eq] using congrArg Star.star hpx + rw [mul_assoc,hx] + +lemma IsSupportProjection.right_le {x r p : M} + (hr : IsSupportProjection (star x*x) r) (hp : IsStarProjection p) (hxp : x*p=x) : + r ≤ p := by + apply hr.le_of_support hp + rw [mul_assoc,hxp] + +include e hL hτ htr hfaith in + + +theorem exists_projection_join (p q : M) (hp : IsStarProjection p) (hq : IsStarProjection q) : + ∃ s : M, IsStarProjection s ∧ p ≤ s ∧ q ≤ s ∧ + (∀ z : M, IsStarProjection z → p ≤ z → q ≤ z → s ≤ z) ∧ + (τ s).re ≤ (τ p).re+(τ q).re := by + let x := (1-p)*q + obtain ⟨r,hr⟩ := exists_support_projection e τ hL hτ htr hfaith (x*star x) + (mul_star_self_nonneg x) + obtain ⟨t,ht⟩ := exists_support_projection e τ hL hτ htr hfaith (star x*x) + (star_mul_self_nonneg x) + have hpx : (1-p)*x=x := by dsimp [x]; rw [← mul_assoc,hp.one_sub.isIdempotentElem.eq] + have hxq : x*q=x := by dsimp [x]; rw [mul_assoc,hq.isIdempotentElem.eq] + have hrp : r ≤ 1-p := hr.left_le hp.one_sub hpx + have htq : t ≤ q := ht.right_le hq hxq + have hpr : p*r=0 := by + have hh := (hr.proj.le_iff_mul_eq_right hp.one_sub).mp hrp + simpa only [sub_mul,one_mul,sub_eq_self] using hh + have hrp0 : r*p=0 := by + simpa only [star_mul,hp.isSelfAdjoint.star_eq,hr.proj.isSelfAdjoint.star_eq,star_zero] + using congrArg Star.star hpr + have hs : IsStarProjection (p+r) := hp.add hr.proj hpr + have hp_le : p ≤ p+r := (hp.le_iff_mul_eq_left hs).mpr (by + rw [mul_add,hp.isIdempotentElem.eq,hpr,add_zero]) + have hrq : r*q=(1-p)*q := by + have hh := hr.mul_star_self_left + dsimp [x] at hh + rw [← mul_assoc,mul_sub,mul_one,hrp0,sub_zero] at hh + exact hh + have hq_le : q ≤ p+r := (hq.le_iff_mul_eq_right hs).mpr (by + rw [add_mul,hrq,sub_mul,one_mul,add_sub_cancel]) + refine ⟨p+r,hs,hp_le,hq_le,?_,?_⟩ + · intro z hz hpz hqz + have hzp : z*p=p := (hp.le_iff_mul_eq_right hz).mp hpz + have hzq : z*q=q := (hq.le_iff_mul_eq_right hz).mp hqz + have hzx : z*x=x := by + dsimp [x] + rw [← mul_assoc,mul_sub,mul_one,sub_mul,hzq,hzp,sub_mul,one_mul] + have hrz : r ≤ z := hr.left_le hz hzx + apply (hs.le_iff_mul_eq_right hz).mpr + rw [mul_add,hzp,(hr.proj.le_iff_mul_eq_right hz).mp hrz] + · have hrt : τ r=τ t := (support_trace_star_mul_self e τ hL hτ htr hfaith x t r ht hr).symm + rw [map_add,Complex.add_re,hrt] + exact add_le_add le_rfl (Complex.re_le_re (τ.monotone htq)) + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +include e hL hτ htr hfaith in +lemma exists_monotone_projection_limit (a : ℕ → M) (ha : ∀ n, IsStarProjection (a n)) + (ham : Monotone a) : + ∃ p : M, IsStarProjection p ∧ GNSTendsto τ a atTop p ∧ (∀ n, a n ≤ p) ∧ + ∀ q : M, IsStarProjection q → (∀ n, a n ≤ q) → p ≤ q := by + obtain ⟨p,_hp,ht⟩ := exists_bounded_preGNS_limit e τ hL hτ 1 + (fun n => (ha n).norm_le _) + (monotone_contractions_preGNS_cauchy τ a (fun n => (ha n).nonneg) + (fun n => (ha n).le_one) ham) + change GNSTendsto τ a atTop p at ht + have hstar : star p=p := by + apply GNSTendsto.unique τ hfaith (ht.star τ htr) + simpa only [(ha _).isSelfAdjoint.star_eq] using ht + have hmul : p*p=p := by + apply GNSTendsto.unique τ hfaith (ht.mul τ htr ht 1 (fun n => (ha n).norm_le _)) + simpa only [(ha _).isIdempotentElem.eq] using ht + have hp : IsStarProjection p := ⟨hmul,hstar⟩ + refine ⟨p,hp,ht,?_,?_⟩ + · intro n + apply ((ha n).le_iff_mul_eq_left hp).mpr + apply GNSTendsto.unique τ hfaith + ((GNSTendsto.const τ (a n) (atTop : Filter ℕ)).mul τ htr ht 1 + (fun _ => (ha n).norm_le _)) + change Tendsto (fun m => ‖τ.toPreGNS (a n*a m-a n)‖) atTop (𝓝 0) + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop n] with m hm + simp only [((ha n).le_iff_mul_eq_left (ha m)).mp (ham hm),sub_self,map_zero,norm_zero] + · intro q hq haq + apply (hp.le_iff_mul_eq_left hq).mpr + apply GNSTendsto.unique τ hfaith + (ht.mul τ htr (GNSTendsto.const τ q atTop) 1 (fun n => (ha n).norm_le _)) + simpa only [((ha _).le_iff_mul_eq_left hq).mp (haq _)] using ht + +include e hL hτ htr hfaith in +lemma exists_projection_finjoin (a : ℕ → M) (ha : ∀ n, IsStarProjection (a n)) (n : ℕ) : + ∃ p : M, IsStarProjection p ∧ (∀ i < n, a i ≤ p) ∧ + (∀ q : M, IsStarProjection q → (∀ i < n, a i ≤ q) → p ≤ q) ∧ + (τ p).re ≤ ∑ i ∈ Finset.range n, (τ (a i)).re := by + induction n with + | zero => + refine ⟨0,IsStarProjection.zero M,by simp,?_,by simp⟩ + intro q hq _h + exact hq.nonneg + | succ n ih => + obtain ⟨p,hp,had,hl,ht⟩ := ih + obtain ⟨q,hq,hpq,hanq,hql,hqt⟩ := exists_projection_join e τ hL hτ htr hfaith p (a n) hp (ha n) + refine ⟨q,hq,?_,?_,?_⟩ + · intro i hi + rcases Nat.lt_or_eq_of_le (Nat.le_of_lt_succ hi) with h|rfl + · exact (had i h).trans hpq + · exact hanq + · intro z hz haz + apply hql z hz (hl z hz (fun i hi => haz i (Nat.lt_succ_of_lt hi))) + exact haz n (Nat.lt_succ_self n) + · rw [Finset.sum_range_succ] + exact hqt.trans (add_le_add ht le_rfl) + +include e hL hτ htr hfaith in + + +theorem exists_projection_countable_join (a : ℕ → M) (ha : ∀ n, IsStarProjection (a n)) + (C : ℝ) (hC : ∀ n : ℕ, (∑ i ∈ Finset.range n, (τ (a i)).re) ≤ C) : + ∃ p : M, IsStarProjection p ∧ (∀ n, a n ≤ p) ∧ + (∀ q : M, IsStarProjection q → (∀ n, a n ≤ q) → p ≤ q) ∧ (τ p).re ≤ C := by + classical + choose b hb had hl ht using exists_projection_finjoin e τ hL hτ htr hfaith a ha + have hbm : Monotone b := by + intro n m hnm + exact hl n (b m) (hb m) (fun i hi => had m i (hi.trans_le hnm)) + obtain ⟨p,hp,hpt,hbp,hpl⟩ := exists_monotone_projection_limit e τ hL hτ htr hfaith b hb hbm + refine ⟨p,hp,?_,?_,?_⟩ + · intro n + exact (had (n+1) n (Nat.lt_succ_self n)).trans (hbp (n+1)) + · intro q hq haq + exact hpl q hq (fun n => hl n q hq (fun i _hi => haq i)) + · exact le_of_tendsto + ((Complex.continuous_re.tendsto (τ p)).comp + (trace_predual_tendsto e τ hτ (hpt.predual e τ hL hτ hfaith 1 + (fun n => (hb n).norm_le _)))) + (Filter.Eventually.of_forall (fun n => (ht n).trans (hC n))) + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +lemma trace_star_mul_self_re (x : M) : (τ (star x*x)).re=‖τ.toPreGNS x‖^2 := by + have h := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS x)) + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS,← Complex.ofReal_pow,Complex.ofReal_re] + using h.symm + +include e hL hτ htr hfaith in + + +theorem exists_spectral_cut (x : M) (α : ℝ) (hα : 0 < α) : + ∃ p : M, IsStarProjection p ∧ ‖x-x*p‖ ≤ α ∧ + (τ p).re ≤ ‖τ.toPreGNS x‖^2 / α^2 := by + let a := star x*x + let b := a-(α^2) • (1:M) + let c := b⁺ + let d := b⁻ + have hsa : IsSelfAdjoint a := IsSelfAdjoint.of_nonneg (star_mul_self_nonneg x) + have hsb : IsSelfAdjoint b := hsa.sub (IsSelfAdjoint.of_nonneg + (smul_nonneg (sq_nonneg α) zero_le_one)) + have hc : 0 ≤ c := CFC.posPart_nonneg b + have hd : 0 ≤ d := CFC.negPart_nonneg b + have hcd : c*d=0 := CFC.posPart_mul_negPart b + have had : a=c-d+(α^2) • 1 := by + have hh := CFC.posPart_sub_negPart b hsb + dsimp [c,d,b] at * + rw [hh,sub_add_cancel] + obtain ⟨p,hp⟩ := exists_support_projection e τ hL hτ htr hfaith c hc + have hpd : p*d=0 := hp.annihilate d hcd + have hdp : d*p=0 := by + simpa only [star_mul,hp.proj.isSelfAdjoint.star_eq,(IsSelfAdjoint.of_nonneg hd).star_eq, + star_zero] using congrArg Star.star hpd + have hap : a*p=c+(α^2) • p := by + rw [had,add_mul,sub_mul,hp.right,hdp,smul_mul_assoc,one_mul,sub_zero] + have hcomp : a*(1-p)=(α^2) • (1-p)-d := by + rw [mul_sub,mul_one,hap,had,smul_sub] + abel + let z := x*(1-p) + have hzz : star z*z=(α^2) • (1-p)-d := by + dsimp [z] + rw [star_mul,star_sub,star_one,hp.proj.isSelfAdjoint.star_eq] + calc + (1-p)*star x*(x*(1-p)) = (1-p)*(a*(1-p)) := by dsimp [a]; simp only [mul_assoc] + _ = (α^2) • (1-p)-d := by + rw [hcomp,mul_sub,mul_smul_comm,hp.proj.one_sub.isIdempotentElem.eq, + sub_mul,one_mul,hpd,sub_zero] + have hzzle : star z*z ≤ (α^2) • (1:M) := by + rw [hzz] + exact (sub_le_self _ hd).trans (smul_le_smul_of_nonneg_left hp.proj.one_sub.le_one (sq_nonneg α)) + have hz : ‖z‖ ≤ α := by + have hh : ‖star z*z‖ ≤ α^2 := (CStarAlgebra.norm_le_iff_le_algebraMap _ (sq_nonneg α) + (star_mul_self_nonneg z)).mpr (by simpa only [Algebra.algebraMap_eq_smul_one] using hzzle) + rw [CStarRing.norm_star_mul_self] at hh + nlinarith [norm_nonneg z] + have htd : (α^2) • p ≤ a := by + have hpos : 0 ≤ a-a*p := by + have heq : a-a*p=star z*z := by rw [hzz,← hcomp,mul_sub,mul_one] + rw [heq] + exact star_mul_self_nonneg z + have hh : (α^2) • p ≤ a*p := by rw [hap]; exact le_add_of_nonneg_left hc + exact hh.trans (sub_nonneg.mp hpos) + have htrace : (τ ((α^2) • p)).re ≤ (τ a).re := Complex.re_le_re (τ.monotone htd) + have hsmall : (τ p).re ≤ ‖τ.toPreGNS x‖^2 / α^2 := by + rw [← Complex.coe_smul,map_smul,smul_eq_mul,Complex.mul_re,Complex.ofReal_re, + Complex.ofReal_im,zero_mul,sub_zero] at htrace + rw [le_div_iff₀ (sq_pos_of_pos hα),mul_comm] + simpa only [a,trace_star_mul_self_re τ] using htrace + refine ⟨p,hp.proj,?_,hsmall⟩ + simpa only [z,mul_sub,mul_one] using hz + +include e hL hτ htr hfaith in + + +theorem exists_small_two_sided_support (x : M) (α : ℝ) (hα : 0 < α) : + ∃ y p : M, IsStarProjection p ∧ p*y=y ∧ y*p=y ∧ ‖y‖ ≤ ‖x‖ ∧ + ‖x-y‖ ≤ α ∧ (τ p).re ≤ 2*(‖τ.toPreGNS x‖^2 / α^2) := by + obtain ⟨r,hr,hdiff,hsmall⟩ := exists_spectral_cut e τ hL hτ htr hfaith x α hα + let y := x*r + obtain ⟨q,hq⟩ := exists_support_projection e τ hL hτ htr hfaith (y*star y) + (mul_star_self_nonneg y) + obtain ⟨t,ht⟩ := exists_support_projection e τ hL hτ htr hfaith (star y*y) + (star_mul_self_nonneg y) + have hyr : y*r=y := by dsimp [y]; rw [mul_assoc,hr.isIdempotentElem.eq] + have htrle : t ≤ r := ht.right_le hr hyr + have hqtrace : (τ q).re ≤ (τ r).re := by + rw [← support_trace_star_mul_self e τ hL hτ htr hfaith y t q ht hq] + exact Complex.re_le_re (τ.monotone htrle) + obtain ⟨p,hp,hrp,hqp,_hmin,hptrace⟩ := + exists_projection_join e τ hL hτ htr hfaith r q hr hq.proj + refine ⟨y,p,hp,?_,?_,?_,hdiff,?_⟩ + · calc + p*y = p*(q*y) := by rw [hq.mul_star_self_left] + _ = y := by rw [← mul_assoc,(hq.proj.le_iff_mul_eq_right hp).mp hqp,hq.mul_star_self_left] + · calc + y*p = (y*r)*p := by rw [hyr] + _ = y := by rw [mul_assoc,(hr.le_iff_mul_eq_left hp).mp hrp,hyr] + · exact (norm_mul_le x r).trans (by nlinarith [norm_nonneg x,hr.norm_le r]) + · linarith + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteCornerGroups.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteCornerGroups.lean new file mode 100644 index 0000000000000000000000000000000000000000..3ffd9860bc8d6c9f0bc9529a0f01293b33b443d0 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteCornerGroups.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.FiniteColumnCorners +import OAI.Analysis.BoundedHochschild.CornerUnitaryExtension + +namespace OAI + +/-! Finite signed-permutation groups in proper corners, extended by the +identity on the complement. Their spans contain every corner matrix unit. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners HochschildMatrixSystems + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + {p : M} (hp : IsStarProjection p) {n : ℕ} (E : MatrixSystem (Corner p hp) n) + +def finiteCornerGroupHom : E.signedPermutationGroup →* unitary M := + (cornerUnitaryExtension hp).comp E.signedPermutationGroup.subtype + +omit [PartialOrder M] [StarOrderedRing M] in +lemma corner_matrixUnit_mem_group_span (i j : Fin n) : + (E.entry i j : M) ∈ Submodule.span ℂ + (Set.range (fun g : E.signedPermutationGroup => (finiteCornerGroupHom hp E g : M))) := by + classical + let P := Submodule.span ℂ + (Set.range (fun g : E.signedPermutationGroup => (finiteCornerGroupHom hp E g : M))) + let σ := Equiv.swap j i + let g₀ : E.signedPermutationGroup := + ⟨E.signedPermutationUnitary σ (fun _ => false), ⟨(σ, fun _ => false), rfl⟩⟩ + let g₁ : E.signedPermutationGroup := + ⟨E.signedPermutationUnitary σ (fun k => decide (k = j)), + ⟨(σ, fun k => decide (k = j)), rfl⟩⟩ + have hm (g : E.signedPermutationGroup) : (finiteCornerGroupHom hp E g : M) ∈ P := + Submodule.subset_span ⟨g, rfl⟩ + have hdiff : (finiteCornerGroupHom hp E g₀ : M) - (finiteCornerGroupHom hp E g₁ : M) = + (2 : ℂ) • (E.entry i j : M) := by + change ((E.signedPermutation σ (fun _ => false) : M) + (1 - p)) - + ((E.signedPermutation σ (fun k => decide (k = j)) : M) + (1 - p)) = _ + calc + _ = ((E.signedPermutation σ (fun _ => false) - + E.signedPermutation σ (fun k => decide (k = j)) : Corner p hp) : M) := by + change (_ + (1 - p)) - (_ + (1 - p)) = _ - _ + abel + _ = _ := by rw [E.signedPermutation_flip]; simp [σ] + have hh := P.smul_mem (2⁻¹ : ℂ) (P.sub_mem (hm g₀) (hm g₁)) + rw [hdiff, smul_smul, inv_mul_cancel₀ (by norm_num : (2 : ℂ) ≠ 0), one_smul] at hh + exact hh + +omit [PartialOrder M] [StarOrderedRing M] in +lemma finiteCornerGroupHom_mem (R : StarSubalgebra ℂ M) + (hE : ∀ i j, (E.entry i j : M) ∈ R) (g : E.signedPermutationGroup) : + (finiteCornerGroupHom hp E g : M) ∈ R := by + classical + have hpR : p ∈ R := by + have he := congrArg (fun a : Corner p hp => (a : M)) E.sum_diagonal + have hm := R.sum_mem (fun i (_ : i ∈ Finset.univ) => hE i i) + rw [AddSubmonoidClass.coe_finsetSum, corner_coe_one] at he + rwa [← he] + rcases g with ⟨u, ⟨⟨σ, s⟩, rfl⟩⟩ + change (E.signedPermutation σ s : M) + (1 - p) ∈ R + apply R.add_mem _ (R.sub_mem R.one_mem hpR) + change ((∑ i, MatrixSystem.signScalar (s i) • E.entry (σ i) i : Corner p hp) : M) ∈ R + simpa using R.sum_mem (fun i (_ : i ∈ Finset.univ) => R.smul_mem (hE (σ i) i) _) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteCountableComparison.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteCountableComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..a8decf4714092fac957f109dffafecefc6a65a3b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteCountableComparison.lean @@ -0,0 +1,58 @@ +import OAI.Analysis.BoundedHochschild.ProjectionJoinComparison +import OAI.Analysis.BoundedHochschild.ProjectionSequenceLimits + +namespace OAI + +/-! Countable joins bounded by a finite orthogonal target. -/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Countably many projections, each embeddable into mutually orthogonal +subprojections of a finite projection, have a join embeddable there. -/ +theorem countable_join_subequivalence (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {Q : M} (hQ : IsStarProjection Q) (hfinite : FiniteCorner Q) + (p q : ℕ → M) (hp : ∀ n, IsStarProjection (p n)) + (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) (hqQ : ∀ n, q n ≤ Q) + (hembed : ∀ n, ∃ v : PartialIso M, v.initial = p n ∧ v.final ≤ q n) : + ∃ v : PartialIso M, v.final ≤ Q ∧ (∀ n, p n ≤ v.initial) ∧ + ∀ r : M, IsStarProjection r → (∀ n, p n ≤ r) → v.initial ≤ r := by + classical + choose a haf hau hal using finite_join_subequivalence e p q hp hq horth hembed + have hsumQ (n : ℕ) : (∑ i ∈ Finset.range n, q i) ≤ Q := by + apply ((orthogonal_projection_sum_range q hq horth n).le_iff_mul_eq_right hQ).mpr + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + exact ((hq i).le_iff_mul_eq_right hQ).mp (hqQ i) + have ham : Monotone (fun n => (a n).initial) := monotone_nat_of_le_succ fun n => by + apply hal n (a (n + 1)).initial (a (n + 1)).initial_proj + intro i hi + exact hau (n + 1) i (Nat.lt_succ_of_lt hi) + have haQ (n : ℕ) : (a n).final ≤ Q := (haf n).trans (hsumQ n) + obtain ⟨v, hvQ, hvupper, hvleast⟩ := finite_increasing_subequivalence e hQ hfinite + (fun n => (a n).initial) ham (fun n => ⟨a n, rfl, haQ n⟩) + refine ⟨v, hvQ, ?_, ?_⟩ + · intro n + exact (hau (n + 1) n (Nat.lt_succ_self n)).trans (hvupper (n + 1)) + · intro r hr hpr + apply hvleast r hr + intro n + exact hal n r hr (fun i _ => hpr i) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteFactorPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteFactorPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..7eb30205a86695ecfc83898e02f022fd05207126 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteFactorPrimitives.lean @@ -0,0 +1,45 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers +import OAI.Analysis.BoundedHochschild.HomogeneousPrimitives +import OAI.Analysis.BoundedHochschild.MinimalFactors + +namespace OAI + +/-! Bounded Hochschild primitives for arbitrary finite factors. -/ + +noncomputable section + +open scoped ComplexOrder +namespace BoundedHochschild +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +theorem primitive_of_finite_factor + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1:M)) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤12*‖f‖ ∧ ∀ x, differentialValue g x=f x := by + classical + by_cases hdiff : HochschildDiffuse.NoMinimalProjections M + · exact primitive_of_factor e τ hτ h1 htr hfaith hfactor hdiff f hf + · obtain ⟨d,E,i,hi⟩ := HochschildMinimalFactor.exists_abelian_matrix_system e τ hτ h1 htr hfaith hfactor hdiff + obtain ⟨g,hg,he⟩ := primitive_of_abelian_matrix_diagonal e E i hi f hf + exact ⟨g,hg.trans (by nlinarith [norm_nonneg f]),he⟩ + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteFunctionAverages.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteFunctionAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..88ae9221e7ad4281ac14597420bd8cd68811d2cb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteFunctionAverages.lean @@ -0,0 +1,40 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainAverages + +namespace OAI + +/-! Deleting one independently averaged finite coordinate leaves the +normalized average unchanged. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {G V : Type*} [Fintype G] [Nonempty G] [AddCommGroup V] [Module ℂ V] + +omit [Nonempty G] in +lemma sum_removeNth {n : ℕ} (k : Fin (n + 1)) (F : (Fin n → G) → V) : + (∑ u : Fin (n + 1) → G, F (k.removeNth u)) = + (Fintype.card G : ℂ) • ∑ v : Fin n → G, F v := by + calc + _ = ∑ p : G × (Fin n → G), F p.2 := by + apply Fintype.sum_equiv (Fin.insertNthEquiv (fun _ => G) k).symm _ _ + intro u + rfl + _ = _ := by + rw [Fintype.sum_prod_type] + simp only [Finset.sum_const, Finset.card_univ, Nat.cast_smul_eq_nsmul] + +lemma normalized_sum_removeNth {n : ℕ} (k : Fin (n + 1)) (F : (Fin n → G) → V) : + (Fintype.card (Fin (n + 1) → G) : ℂ)⁻¹ • (∑ u : Fin (n + 1) → G, F (k.removeNth u)) = + (Fintype.card (Fin n → G) : ℂ)⁻¹ • ∑ v : Fin n → G, F v := by + rw [sum_removeNth, smul_smul] + congr 1 + have hc : (Fintype.card G : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos) + simp only [Fintype.card_fun, Fintype.card_fin, Nat.cast_pow, pow_succ, Nat.cast_mul] + field_simp + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupBarOperators.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupBarOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..da9aeb0a2fc98c26a88b1d467c8a46a454933cb3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupBarOperators.lean @@ -0,0 +1,129 @@ +import OAI.Analysis.BoundedHochschild.MultimodularTransport +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainChainMap + +namespace OAI + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma curryMid_one_norm_le {n : ℕ} (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + ‖f.curryMid i 1‖ ≤ ‖f‖ := by + have h1 : ‖(1 : M)‖ ≤ 1 := by + rcases subsingleton_or_nontrivial M with h | h + · simp [Subsingleton.elim (1 : M) 0] + · simp + calc + _ ≤ ‖f.curryMid i‖ * ‖(1 : M)‖ := ContinuousLinearMap.le_opNorm _ _ + _ ≤ ‖f‖ * 1 := by rw [ContinuousMultilinearMap.norm_curryMid]; gcongr + _ = _ := mul_one _ + +def barInsertion {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) : Cochain M n := + (cochainUnitaryTransport (unitaryPrefix u (i.val + 1)) f).curryMid i 1 + +@[simp] lemma barInsertion_apply {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) (x : Fin n → M) : + barInsertion u i f x = cochainUnitaryTransport (unitaryPrefix u (i.val + 1)) f (i.insertNth 1 x) := rfl + +lemma barInsertion_value {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) (x : Fin n → M) : + barInsertion u i f x = star (u 0 : M) * + f (cochainUnitaryTuple (unitaryPrefix u (i.val + 1)) (i.insertNth 1 x)) := by + rw [barInsertion_apply, cochainUnitaryTransport_apply] + have h0 : unitaryPrefix u (i.val + 1) 0 = u 0 := by simp [unitaryPrefix] + have hl : unitaryPrefix u (i.val + 1) (Fin.last (n + 1)) = 1 := by + have hi : ¬n + 1 < i.val + 1 := by omega + simp only [unitaryPrefix, Fin.val_last, hi, ite_false] + rw [h0, hl] + simp only [OneMemClass.coe_one, mul_one] + +lemma barInsertion_norm {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) : ‖barInsertion u i f‖ ≤ ‖f‖ := + (curryMid_one_norm_le _ i).trans (cochainUnitaryTransport_norm _ f) + +lemma barInsertion_add {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (f g : Cochain M (n + 1)) : barInsertion u i (f + g) = barInsertion u i f + barInsertion u i g := by + ext x + simp only [barInsertion_apply, cochainUnitaryTransport_add, add_apply] + +lemma barInsertion_smul {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) + (z : ℂ) (f : Cochain M (n + 1)) : barInsertion u i (z • f) = z • barInsertion u i f := by + ext x + simp only [barInsertion_apply, cochainUnitaryTransport_smul, smul_apply] + +variable {G : Type*} [Group G] [Fintype G] + +def finiteGroupBarInsertion {n : ℕ} (ρ : G →* unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) : Cochain M n := + (Fintype.card (Fin (n + 2) → G) : ℂ)⁻¹ • + ∑ g : Fin (n + 2) → G, barInsertion (fun j => ρ (g j)) i f + +lemma finiteGroupBarInsertion_norm {n : ℕ} (ρ : G →* unitary M) (i : Fin (n + 1)) + (f : Cochain M (n + 1)) : ‖finiteGroupBarInsertion ρ i f‖ ≤ ‖f‖ := by + let K := Fin (n + 2) → G + have hc : (0 : ℝ) < Fintype.card K := Nat.cast_pos.mpr Fintype.card_pos + rw [finiteGroupBarInsertion, norm_smul, norm_inv, Complex.norm_natCast] + calc + _ ≤ (Fintype.card K : ℝ)⁻¹ * ((Fintype.card K : ℝ) * ‖f‖) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr hc.le) + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] using + Finset.sum_le_sum (s := Finset.univ) (fun (g : Fin (n + 2) → G) _ => + barInsertion_norm (fun j => ρ (g j)) i f)) + _ = _ := by rw [← mul_assoc, inv_mul_cancel₀ (ne_of_gt hc), one_mul] + +def finiteGroupBarOperator {n : ℕ} (ρ : G →* unitary M) (f : Cochain M (n + 1)) : Cochain M n := + ∑ i : Fin (n + 1), ((-1 : ℂ) ^ i.val) • finiteGroupBarInsertion ρ i f + +lemma finiteGroupBarOperator_norm {n : ℕ} (ρ : G →* unitary M) (f : Cochain M (n + 1)) : + ‖finiteGroupBarOperator ρ f‖ ≤ (n + 1 : ℝ) * ‖f‖ := by + unfold finiteGroupBarOperator + calc + _ ≤ ∑ i : Fin (n + 1), ‖((-1 : ℂ) ^ i.val) • finiteGroupBarInsertion ρ i f‖ := norm_sum_le _ _ + _ ≤ ∑ _i : Fin (n + 1), ‖f‖ := by + apply Finset.sum_le_sum + intro i _ + simpa only [norm_smul, norm_pow, norm_neg, norm_one, one_pow, one_mul] using + finiteGroupBarInsertion_norm ρ i f + _ = _ := by simp [nsmul_eq_mul] + +lemma finiteGroupBarInsertion_add {n : ℕ} (ρ : G →* unitary M) (i : Fin (n + 1)) + (f g : Cochain M (n + 1)) : + finiteGroupBarInsertion ρ i (f + g) = finiteGroupBarInsertion ρ i f + finiteGroupBarInsertion ρ i g := by + simp only [finiteGroupBarInsertion, barInsertion_add, Finset.sum_add_distrib, smul_add] + +lemma finiteGroupBarInsertion_smul {n : ℕ} (ρ : G →* unitary M) (i : Fin (n + 1)) + (z : ℂ) (f : Cochain M (n + 1)) : + finiteGroupBarInsertion ρ i (z • f) = z • finiteGroupBarInsertion ρ i f := by + simp only [finiteGroupBarInsertion, barInsertion_smul, ← Finset.smul_sum] + exact smul_comm _ _ _ + +lemma finiteGroupBarOperator_add {n : ℕ} (ρ : G →* unitary M) (f g : Cochain M (n + 1)) : + finiteGroupBarOperator ρ (f + g) = finiteGroupBarOperator ρ f + finiteGroupBarOperator ρ g := by + simp only [finiteGroupBarOperator, finiteGroupBarInsertion_add, smul_add, Finset.sum_add_distrib] + +lemma finiteGroupBarOperator_smul {n : ℕ} (ρ : G →* unitary M) (z : ℂ) (f : Cochain M (n + 1)) : + finiteGroupBarOperator ρ (z • f) = z • finiteGroupBarOperator ρ f := by + simp only [finiteGroupBarOperator, finiteGroupBarInsertion_smul, Finset.smul_sum] + apply Finset.sum_congr rfl + intro i _ + exact smul_comm _ _ _ + +def finiteGroupBarOperatorCLM (ρ : G →* unitary M) (n : ℕ) : + Cochain M (n + 1) →L[ℂ] Cochain M n := + LinearMap.mkContinuous + { toFun := finiteGroupBarOperator ρ + map_add' := finiteGroupBarOperator_add ρ + map_smul' := finiteGroupBarOperator_smul ρ } + (n + 1) (fun f => by + change ‖finiteGroupBarOperator ρ f‖ ≤ (n + 1 : ℝ) * ‖f‖ + exact finiteGroupBarOperator_norm ρ f) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainAverages.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..b5280ee85b3f8bb05d1e73191a2dae54a3539be2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainAverages.lean @@ -0,0 +1,138 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupModuleAverages + +namespace OAI + +/-! Contractive finite-group averaging on cochains. Every boundary between +inputs is averaged independently; the resulting cochain satisfies the +ordinary module identities over the linear span of the unitary group. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M : Type u} [CStarAlgebra M] + +private def unitaryBimultiply (u v : unitary M) : M →L[ℂ] M := + (ContinuousLinearMap.mul ℂ M (u : M)).comp + ((ContinuousLinearMap.mul ℂ M).flip (v : M)) + +private lemma unitaryBimultiply_apply (u v : unitary M) (a : M) : + unitaryBimultiply u v a = (u : M) * a * (v : M) := by + simp only [unitaryBimultiply, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.mul_apply', ContinuousLinearMap.flip_apply, mul_assoc] + +def cochainUnitaryTuple {n : ℕ} (u : Fin (n + 1) → unitary M) (x : Fin n → M) : Fin n → M := + fun i => (u i.castSucc : M) * x i * star (u i.succ : M) + +def cochainUnitaryTransport {n : ℕ} (u : Fin (n + 1) → unitary M) + (f : Cochain M n) : Cochain M n := + (unitaryBimultiply (star (u 0)) (u (Fin.last n))).compContinuousMultilinearMap + (f.compContinuousLinearMap (fun i => unitaryBimultiply (u i.castSucc) (star (u i.succ)))) + +@[simp] lemma cochainUnitaryTransport_apply {n : ℕ} (u : Fin (n + 1) → unitary M) + (f : Cochain M n) (x : Fin n → M) : + cochainUnitaryTransport u f x = + star (u 0 : M) * f (cochainUnitaryTuple u x) * (u (Fin.last n) : M) := by + change unitaryBimultiply _ _ (f (fun i => unitaryBimultiply _ _ (x i))) = _ + simp only [unitaryBimultiply_apply, Unitary.coe_star] + rfl + +lemma cochainUnitaryTransport_norm {n : ℕ} (u : Fin (n + 1) → unitary M) + (f : Cochain M n) : ‖cochainUnitaryTransport u f‖ ≤ ‖f‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (norm_nonneg _) + intro x + rw [cochainUnitaryTransport_apply] + change ‖((star (u 0) : unitary M) : M) * f (cochainUnitaryTuple u x) * + (u (Fin.last n) : M)‖ ≤ _ + rw [CStarRing.norm_mul_coe_unitary, CStarRing.norm_coe_unitary_mul] + have hp : (∏ i, ‖cochainUnitaryTuple u x i‖) = ∏ i, ‖x i‖ := by + apply Finset.prod_congr rfl + intro i _ + change ‖(u i.castSucc : M) * x i * ((star (u i.succ) : unitary M) : M)‖ = ‖x i‖ + rw [CStarRing.norm_mul_coe_unitary, CStarRing.norm_coe_unitary_mul] + have hb := f.le_opNorm (cochainUnitaryTuple u x) + rwa [hp] at hb + +lemma cochainUnitaryTransport_add {n : ℕ} (u : Fin (n + 1) → unitary M) + (f g : Cochain M n) : + cochainUnitaryTransport u (f + g) = cochainUnitaryTransport u f + cochainUnitaryTransport u g := by + ext x + simp only [cochainUnitaryTransport_apply, add_apply, mul_add, add_mul] + +lemma cochainUnitaryTransport_smul {n : ℕ} (u : Fin (n + 1) → unitary M) + (z : ℂ) (f : Cochain M n) : + cochainUnitaryTransport u (z • f) = z • cochainUnitaryTransport u f := by + ext x + simp only [cochainUnitaryTransport_apply, smul_apply, mul_smul_comm, smul_mul_assoc] + +def cochainUnitaryTransportCLM {n : ℕ} (u : Fin (n + 1) → unitary M) : + Cochain M n →L[ℂ] Cochain M n := + LinearMap.mkContinuous + { toFun := cochainUnitaryTransport u + map_add' := cochainUnitaryTransport_add u + map_smul' := cochainUnitaryTransport_smul u } + 1 (fun f => by + change ‖cochainUnitaryTransport u f‖ ≤ 1 * ‖f‖ + simpa only [one_mul] using cochainUnitaryTransport_norm u f) + +@[simp] lemma cochainUnitaryTransportCLM_apply {n : ℕ} (u : Fin (n + 1) → unitary M) + (f : Cochain M n) : cochainUnitaryTransportCLM u f = cochainUnitaryTransport u f := rfl + +lemma cochainUnitaryTransport_comp {n : ℕ} (u v : Fin (n + 1) → unitary M) + (f : Cochain M n) : + cochainUnitaryTransport u (cochainUnitaryTransport v f) = + cochainUnitaryTransport (v * u) f := by + ext x + simp only [cochainUnitaryTransport_apply, Pi.mul_apply, Submonoid.coe_mul, star_mul] + have ht : cochainUnitaryTuple v (cochainUnitaryTuple u x) = cochainUnitaryTuple (v * u) x := by + ext i + simp only [cochainUnitaryTuple, Pi.mul_apply, Submonoid.coe_mul, star_mul, mul_assoc] + rw [ht] + simp only [mul_assoc] + +variable {G : Type v} [Group G] [Fintype G] + +def finiteGroupCochainAverage {n : ℕ} (ρ : G →* unitary M) (f : Cochain M n) : Cochain M n := + (Fintype.card (Fin (n + 1) → G) : ℂ)⁻¹ • + ∑ g : Fin (n + 1) → G, cochainUnitaryTransport (fun i => ρ (g i)) f + +lemma finiteGroupCochainAverage_norm {n : ℕ} (ρ : G →* unitary M) (f : Cochain M n) : + ‖finiteGroupCochainAverage ρ f‖ ≤ ‖f‖ := by + let K := Fin (n + 1) → G + have hc : (0 : ℝ) < Fintype.card K := Nat.cast_pos.mpr Fintype.card_pos + rw [finiteGroupCochainAverage, norm_smul, norm_inv, Complex.norm_natCast] + calc + _ ≤ (Fintype.card K : ℝ)⁻¹ * ((Fintype.card K : ℝ) * ‖f‖) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr hc.le) + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] using + Finset.sum_le_sum (s := Finset.univ) (fun (g : Fin (n + 1) → G) _ => + cochainUnitaryTransport_norm (fun i => ρ (g i)) f)) + _ = _ := by rw [← mul_assoc, inv_mul_cancel₀ (ne_of_gt hc), one_mul] + +lemma finiteGroupCochainAverage_invariant {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M n) (h : Fin (n + 1) → G) : + cochainUnitaryTransport (fun i => ρ (h i)) (finiteGroupCochainAverage ρ f) = + finiteGroupCochainAverage ρ f := by + change cochainUnitaryTransportCLM (fun i => ρ (h i)) _ = _ + rw [finiteGroupCochainAverage, map_smul, map_sum] + congr 1 + calc + _ = ∑ g : Fin (n + 1) → G, cochainUnitaryTransport (fun i => ρ ((g * h) i)) f := by + apply Finset.sum_congr rfl + intro g _ + rw [cochainUnitaryTransportCLM_apply, cochainUnitaryTransport_comp] + congr 1 + funext i + exact (map_mul ρ (g i) (h i)).symm + _ = _ := by + apply Fintype.sum_equiv (Equiv.mulRight h) _ _ + intro g + rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainChainMap.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainChainMap.lean new file mode 100644 index 0000000000000000000000000000000000000000..477eb9a596f86014a5e2b213405fb103ac77fd70 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupCochainChainMap.lean @@ -0,0 +1,116 @@ +import OAI.Analysis.BoundedHochschild.CochainTransportMiddle +import OAI.Analysis.BoundedHochschild.FiniteFunctionAverages + +namespace OAI + +/-! The contractive finite-group cochain averages commute with the +Hochschild differential. No homotopy or cohomology-class assertion is +assumed in this calculation. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M : Type u} [CStarAlgebra M] {G : Type v} [Group G] [Fintype G] + +lemma finiteGroupCochainAverage_add {n : ℕ} (ρ : G →* unitary M) (f g : Cochain M n) : + finiteGroupCochainAverage ρ (f + g) = finiteGroupCochainAverage ρ f + finiteGroupCochainAverage ρ g := by + simp only [finiteGroupCochainAverage, cochainUnitaryTransport_add, Finset.sum_add_distrib, smul_add] + +lemma finiteGroupCochainAverage_smul {n : ℕ} (ρ : G →* unitary M) (z : ℂ) (f : Cochain M n) : + finiteGroupCochainAverage ρ (z • f) = z • finiteGroupCochainAverage ρ f := by + simp only [finiteGroupCochainAverage, cochainUnitaryTransport_smul, ← Finset.smul_sum] + exact smul_comm _ _ _ + +def finiteGroupCochainAverageLinear {n : ℕ} (ρ : G →* unitary M) : Cochain M n →ₗ[ℂ] Cochain M n where + toFun := finiteGroupCochainAverage ρ + map_add' := finiteGroupCochainAverage_add ρ + map_smul' := finiteGroupCochainAverage_smul ρ + +lemma finiteGroupCochainAverage_sum {I : Type*} {n : ℕ} (ρ : G →* unitary M) + (s : Finset I) (f : I → Cochain M n) : + finiteGroupCochainAverage ρ (∑ i ∈ s, f i) = ∑ i ∈ s, finiteGroupCochainAverage ρ (f i) := + map_sum (finiteGroupCochainAverageLinear ρ) f s + +def leftFaceLinear (n : ℕ) : Cochain M n →ₗ[ℂ] Cochain M (n + 1) where + toFun := leftCoboundary + map_add' f g := by ext x; simp only [leftCoboundary_apply, add_apply, mul_add] + map_smul' z f := by ext x; simp only [leftCoboundary_apply, smul_apply, mul_smul_comm, RingHom.id_apply] + +def rightFaceLinear (n : ℕ) : Cochain M n →ₗ[ℂ] Cochain M (n + 1) where + toFun := rightCoboundary + map_add' f g := by ext x; simp only [rightCoboundary_apply, add_apply, add_mul] + map_smul' z f := by ext x; simp only [rightCoboundary_apply, smul_apply, smul_mul_assoc, RingHom.id_apply] + +def middleFaceLinear {n : ℕ} (k : Fin (n + 1)) : + Cochain M (n + 1) →ₗ[ℂ] Cochain M (n + 2) where + toFun f := middleCoboundary f k + map_add' f g := by ext x; simp only [middleCoboundary_apply, add_apply] + map_smul' z f := by ext x; simp only [middleCoboundary_apply, smul_apply, RingHom.id_apply] + +lemma finiteGroupCochainAverage_face {n : ℕ} (ρ : G →* unitary M) + (L : Cochain M n →ₗ[ℂ] Cochain M (n + 1)) (k : Fin (n + 2)) (f : Cochain M n) + (hL : ∀ u : Fin (n + 2) → unitary M, + cochainUnitaryTransport u (L f) = L (cochainUnitaryTransport (k.removeNth u) f)) : + finiteGroupCochainAverage ρ (L f) = L (finiteGroupCochainAverage ρ f) := by + have ht (u : Fin (n + 2) → G) : + cochainUnitaryTransport (fun i => ρ (u i)) (L f) = + L (cochainUnitaryTransport (fun i => ρ (k.removeNth u i)) f) := hL (fun i => ρ (u i)) + unfold finiteGroupCochainAverage + simp_rw [ht] + rw [← map_sum, ← map_smul] + congr 1 + exact normalized_sum_removeNth k (fun u => cochainUnitaryTransport (fun i => ρ (u i)) f) + +lemma finiteGroupCochainAverage_leftCoboundary {n : ℕ} (ρ : G →* unitary M) (f : Cochain M n) : + finiteGroupCochainAverage ρ (leftCoboundary f) = leftCoboundary (finiteGroupCochainAverage ρ f) := by + apply finiteGroupCochainAverage_face ρ (leftFaceLinear n) 0 f + intro u + simpa only [leftFaceLinear, LinearMap.coe_mk, AddHom.coe_mk, Fin.removeNth_zero] using + cochainUnitaryTransport_leftCoboundary u f + +lemma finiteGroupCochainAverage_rightCoboundary {n : ℕ} (ρ : G →* unitary M) (f : Cochain M n) : + finiteGroupCochainAverage ρ (rightCoboundary f) = rightCoboundary (finiteGroupCochainAverage ρ f) := by + apply finiteGroupCochainAverage_face ρ (rightFaceLinear n) (Fin.last (n + 1)) f + intro u + change cochainUnitaryTransport u (rightCoboundary f) = + rightCoboundary (cochainUnitaryTransport ((Fin.last (n + 1)).removeNth u) f) + rw [Fin.removeNth_last, show Fin.init u = (fun i => u i.castSucc) from rfl] + exact cochainUnitaryTransport_rightCoboundary u f + +lemma finiteGroupCochainAverage_middleCoboundary {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (k : Fin (n + 1)) : + finiteGroupCochainAverage ρ (middleCoboundary f k) = middleCoboundary (finiteGroupCochainAverage ρ f) k := by + apply finiteGroupCochainAverage_face ρ (middleFaceLinear k) k.castSucc.succ f + intro u + exact cochainUnitaryTransport_middleCoboundary u f k + +lemma finiteGroupCochainAverage_differential {n : ℕ} (ρ : G →* unitary M) (f : Cochain M (n + 1)) : + finiteGroupCochainAverage ρ (differential f) = differential (finiteGroupCochainAverage ρ f) := by + change finiteGroupCochainAverage ρ + (leftCoboundary f + ∑ j : Fin (n + 1), ((-1 : ℂ) ^ (j.val + 1)) • middleCoboundary f j + + ((-1 : ℂ) ^ (n + 2)) • rightCoboundary f) = _ + simp only [finiteGroupCochainAverage_add, finiteGroupCochainAverage_sum, + finiteGroupCochainAverage_smul, finiteGroupCochainAverage_leftCoboundary, + finiteGroupCochainAverage_rightCoboundary, finiteGroupCochainAverage_middleCoboundary] + rfl + +lemma finiteGroupCochainAverage_cocycle {n : ℕ} (ρ : G →* unitary M) (f : Cochain M (n + 1)) + (hf : ∀ x, differentialValue f x = 0) : + ∀ x, differentialValue (finiteGroupCochainAverage ρ f) x = 0 := by + have hd : differential f = 0 := by + ext x + simpa only [differential_apply, zero_apply] using hf x + have he := finiteGroupCochainAverage_differential ρ f + rw [hd, show finiteGroupCochainAverage ρ (0 : Cochain M (n + 2)) = 0 from + map_zero (finiteGroupCochainAverageLinear ρ)] at he + intro x + simpa only [differential_apply, zero_apply] using + congrArg (fun F : Cochain M (n + 2) => F x) he.symm + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupModuleAverages.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupModuleAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..e34acbb7799e74b14a45d6a93858134206e98c88 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupModuleAverages.lean @@ -0,0 +1,120 @@ +import OAI.Analysis.BoundedHochschild.MultimodularGenerators +import OAI.Analysis.BoundedHochschild.RightAveragingAlgebra + +namespace OAI + +/-! Finite group averaging on arbitrary bounded linear maps. Unlike the +simultaneous infinite module projection, this elementary contraction does +not require complete boundedness and preserves normality. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M : Type u} {G : Type v} [CStarAlgebra M] [Group G] [Fintype G] + +def finiteGroupRightAverage (ρ : G →* unitary M) (T : M →L[ℂ] M) : M →L[ℂ] M := + (Fintype.card G : ℂ)⁻¹ • finiteRightAverage (fun g => (ρ g : M)) T + +@[simp] lemma finiteGroupRightAverage_apply (ρ : G →* unitary M) (T : M →L[ℂ] M) (x : M) : + finiteGroupRightAverage ρ T x = + (Fintype.card G : ℂ)⁻¹ • ∑ g : G, T (x * (ρ g : M)) * star (ρ g : M) := by + simp only [finiteGroupRightAverage, smul_apply, finiteRightAverage_apply] + +lemma finiteGroupRightAverage_norm (ρ : G →* unitary M) (T : M →L[ℂ] M) : + ‖finiteGroupRightAverage ρ T‖ ≤ ‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro x + have hb (g : G) : ‖T (x * (ρ g : M)) * star (ρ g : M)‖ ≤ ‖T‖ * ‖x‖ := by + rw [show star (ρ g : M) = ((star (ρ g) : unitary M) : M) by rfl, + CStarRing.norm_mul_coe_unitary] + simpa only [CStarRing.norm_mul_coe_unitary] using T.le_opNorm (x * (ρ g : M)) + have hc : (0 : ℝ) < Fintype.card G := Nat.cast_pos.mpr Fintype.card_pos + rw [finiteGroupRightAverage_apply, norm_smul, norm_inv, Complex.norm_natCast] + calc + _ ≤ (Fintype.card G : ℝ)⁻¹ * ((Fintype.card G : ℝ) * (‖T‖ * ‖x‖)) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr hc.le) + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] using + Finset.sum_le_sum (s := Finset.univ) (fun g _ => hb g)) + _ = _ := by rw [← mul_assoc, inv_mul_cancel₀ (ne_of_gt hc), one_mul] + +lemma finiteGroupRightAverage_module (ρ : G →* unitary M) (T : M →L[ℂ] M) + (h : G) (x : M) : + finiteGroupRightAverage ρ T (x * (ρ h : M)) = finiteGroupRightAverage ρ T x * (ρ h : M) := by + have hu : star (ρ h : M) * (ρ h : M) = 1 := Unitary.star_mul_self_of_mem (ρ h).property + have hs : (∑ g : G, T ((x * (ρ h : M)) * (ρ g : M)) * star (ρ g : M)) = + ∑ g : G, (T (x * (ρ g : M)) * star (ρ g : M)) * (ρ h : M) := by + apply Fintype.sum_equiv (Equiv.mulLeft h) _ _ + intro g + change T ((x * (ρ h : M)) * (ρ g : M)) * star (ρ g : M) = + (T (x * (ρ (h * g) : M)) * star (ρ (h * g) : M)) * (ρ h : M) + rw [map_mul ρ h g, Submonoid.coe_mul, star_mul] + simp only [mul_assoc, hu, mul_one] + simp only [finiteGroupRightAverage_apply, smul_mul_assoc, Finset.sum_mul] + rw [hs] + +lemma finiteGroupRightAverage_span_module (ρ : G →* unitary M) (T : M →L[ℂ] M) + {a : M} (ha : a ∈ Submodule.span ℂ (Set.range (fun g => (ρ g : M)))) (x : M) : + finiteGroupRightAverage ρ T (x * a) = finiteGroupRightAverage ρ T x * a := by + apply linear_maps_eq_on_span (Set.range (fun g => (ρ g : M))) + ((finiteGroupRightAverage ρ T).comp (ContinuousLinearMap.mul ℂ M x)) + (ContinuousLinearMap.mul ℂ M (finiteGroupRightAverage ρ T x)) _ ha + rintro _ ⟨g, rfl⟩ + exact finiteGroupRightAverage_module ρ T g x + +lemma finiteGroupRightAverage_fixes (ρ : G →* unitary M) (T : M →L[ℂ] M) + (hT : ∀ g x, T (x * (ρ g : M)) = T x * (ρ g : M)) : + finiteGroupRightAverage ρ T = T := by + have hc : (Fintype.card G : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos) + have hu (g : G) : (ρ g : M) * star (ρ g : M) = 1 := Unitary.mul_star_self_of_mem (ρ g).property + ext x + simp only [finiteGroupRightAverage_apply, hT, mul_assoc, hu, + mul_one, Finset.sum_const, Finset.card_univ] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, inv_mul_cancel₀ hc, one_smul] + +def finiteGroupRightAverageCLM (ρ : G →* unitary M) : + (M →L[ℂ] M) →L[ℂ] (M →L[ℂ] M) := + LinearMap.mkContinuous + { toFun := finiteGroupRightAverage ρ + map_add' := fun T U => by + simp only [finiteGroupRightAverage, finiteRightAverage_add, smul_add] + map_smul' := fun z T => by + simp only [finiteGroupRightAverage, finiteRightAverage_smul, RingHom.id_apply] + exact smul_comm _ _ _ } + 1 (fun T => by + change ‖finiteGroupRightAverage ρ T‖ ≤ 1 * ‖T‖ + simpa only [one_mul] using finiteGroupRightAverage_norm ρ T) + +@[simp] lemma finiteGroupRightAverageCLM_apply (ρ : G →* unitary M) (T : M →L[ℂ] M) : + finiteGroupRightAverageCLM ρ T = finiteGroupRightAverage ρ T := rfl + +lemma finiteGroupRightAverage_idempotent (ρ : G →* unitary M) (T : M →L[ℂ] M) : + finiteGroupRightAverage ρ (finiteGroupRightAverage ρ T) = finiteGroupRightAverage ρ T := + finiteGroupRightAverage_fixes ρ _ (finiteGroupRightAverage_module ρ T) + +lemma finiteGroupRightAverage_covariance (ρ : G →* unitary M) (T : M →L[ℂ] M) (a b : M) : + finiteGroupRightAverage ρ (leftSandwichMap a b T) = + leftSandwichMap a b (finiteGroupRightAverage ρ T) := by + rw [finiteGroupRightAverage, ← leftSandwichMap_rightAverage] + ext x + simp only [smul_apply, leftSandwichMap_apply, mul_smul_comm, finiteGroupRightAverage] + +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma finiteGroupRightAverage_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ρ : G →* unitary M) (T : M →L[ℂ] M) (hT : HasPreadjoint e T) : + HasPreadjoint e (finiteGroupRightAverage ρ T) := by + have hR := (HochschildSakai.abstract_multiplication_normal e).2 + unfold finiteGroupRightAverage finiteRightAverage + apply HasPreadjoint.smul e + apply HasPreadjoint.sum e + intro g _ + exact (hR _).comp e (hT.comp e (hR _)) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupMultimodularity.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupMultimodularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..6726087cef6a6c3ceabc6d8c053b45a9ea95b75b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupMultimodularity.lean @@ -0,0 +1,140 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainAverages + +namespace OAI + +/-! The module identities of the contractive finite-group cochain average. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M : Type u} [CStarAlgebra M] + +lemma cochainUnitaryTransport_fixed_value {n : ℕ} (u : Fin (n + 1) → unitary M) + (f : Cochain M n) (hf : cochainUnitaryTransport u f = f) (x : Fin n → M) : + f (cochainUnitaryTuple u x) = (u 0 : M) * f x * star (u (Fin.last n) : M) := by + have h := congrArg (fun F : Cochain M n => (u 0 : M) * F x * star (u (Fin.last n) : M)) hf + simp only [cochainUnitaryTransport_apply, mul_assoc, + Unitary.mul_star_self_of_mem (u (Fin.last n)).property, mul_one] at h + rw [← mul_assoc, Unitary.mul_star_self_of_mem (u 0).property, one_mul] at h + simpa only [mul_assoc] using h + +lemma cochainUnitaryTuple_left {n : ℕ} (u : unitary M) (x : Fin (n + 1) → M) : + cochainUnitaryTuple (Function.update (fun _ : Fin (n + 2) => 1) 0 u) x = + Function.update x 0 ((u : M) * x 0) := by + ext i + by_cases hi : i = 0 + · subst i + simp [cochainUnitaryTuple] + · have hi0 : i.castSucc ≠ (0 : Fin (n + 2)) := by + intro h + exact hi (Fin.ext (congrArg (fun z : Fin (n + 2) => z.val) h)) + simp [cochainUnitaryTuple, hi, hi0] + +lemma cochainUnitaryTuple_right {n : ℕ} (u : unitary M) (x : Fin (n + 1) → M) : + cochainUnitaryTuple (Function.update (fun _ : Fin (n + 2) => 1) (Fin.last (n + 1)) u) x = + Function.update x (Fin.last n) (x (Fin.last n) * star (u : M)) := by + ext i + by_cases hi : i = Fin.last n + · subst i + simp [cochainUnitaryTuple] + · have hiL : i.succ ≠ Fin.last (n + 1) := by + intro h + apply hi + apply Fin.ext + have hv := congrArg Fin.val h + simp only [Fin.val_succ, Fin.val_last] at hv ⊢ + omega + simp [cochainUnitaryTuple, hi, hiL] + +lemma cochainUnitaryTuple_internal {n : ℕ} (u : unitary M) (x : Fin (n + 1) → M) (j : Fin n) : + cochainUnitaryTuple (Function.update (fun _ : Fin (n + 2) => 1) j.castSucc.succ u) x = + Function.update (Function.update x j.castSucc (x j.castSucc * star (u : M))) + j.succ ((u : M) * x j.succ) := by + have hjs : j.castSucc ≠ j.succ := ne_of_lt Fin.castSucc_lt_succ + ext i + by_cases hi : i = j.castSucc + · subst i + have hne : j.castSucc.castSucc ≠ j.castSucc.succ := ne_of_lt Fin.castSucc_lt_succ + simp only [cochainUnitaryTuple, Function.update_of_ne hne, Function.update_self, + Function.update_of_ne hjs, OneMemClass.coe_one, one_mul] + · by_cases hi' : i = j.succ + · subst i + have hne : j.succ.succ ≠ j.castSucc.succ := by + simpa only [ne_eq, Fin.succ_inj] using hjs.symm + have heq : j.succ.castSucc = j.castSucc.succ := Fin.castSucc_succ j + simp only [cochainUnitaryTuple, heq, Function.update_self, Function.update_of_ne hne, + OneMemClass.coe_one, star_one, mul_one] + · have hneL : i.castSucc ≠ j.castSucc.succ := by + simpa only [← Fin.castSucc_succ, ne_eq, Fin.castSucc_inj] using hi' + have hneR : i.succ ≠ j.castSucc.succ := by + simpa only [ne_eq, Fin.succ_inj] using hi + simp only [cochainUnitaryTuple, Function.update_of_ne hneL, Function.update_of_ne hneR, + Function.update_of_ne hi, Function.update_of_ne hi', OneMemClass.coe_one, + star_one, one_mul, mul_one] + +variable {G : Type v} [Group G] [Fintype G] + +lemma finiteGroupCochainAverage_multimodularAt {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) (g : G) : + MultimodularAt (finiteGroupCochainAverage ρ f) (ρ g : M) := by + let F := finiteGroupCochainAverage ρ f + have hvalue (h : Fin (n + 2) → G) (x : Fin (n + 1) → M) : + F (cochainUnitaryTuple (fun i => ρ (h i)) x) = + (ρ (h 0) : M) * F x * star (ρ (h (Fin.last (n + 1))) : M) := + cochainUnitaryTransport_fixed_value _ F (finiteGroupCochainAverage_invariant ρ f h) x + have hρ (i : Fin (n + 2)) (h : G) : + (fun k => ρ (Function.update (fun _ : Fin (n + 2) => (1 : G)) i h k)) = + Function.update (fun _ : Fin (n + 2) => 1) i (ρ h) := by + ext k + by_cases hk : k = i <;> simp [hk] + constructor + · intro x + have h := hvalue (Function.update (fun _ => 1) 0 g) x + rw [hρ, cochainUnitaryTuple_left] at h + simpa using h + · intro x + have h := hvalue (Function.update (fun _ => 1) (Fin.last (n + 1)) g⁻¹) x + rw [hρ, cochainUnitaryTuple_right] at h + have hu : star (ρ g⁻¹ : M) = (ρ g : M) := by + rw [map_inv] + change star (star (ρ g : M)) = (ρ g : M) + exact star_star _ + simpa only [Function.update_self, map_one, OneMemClass.coe_one, one_mul, + Function.update_of_ne (by simp : (0 : Fin (n + 2)) ≠ Fin.last (n + 1)), hu] using h + · intro x j + let y := Function.update x j.castSucc (x j.castSucc * (ρ g : M)) + have h := hvalue (Function.update (fun _ => 1) j.castSucc.succ g) y + rw [hρ, cochainUnitaryTuple_internal] at h + have hz : Function.update + (Function.update y j.castSucc (y j.castSucc * star (ρ g : M))) + j.succ ((ρ g : M) * y j.succ) = + Function.update x j.succ ((ρ g : M) * x j.succ) := by + have hu := Unitary.mul_star_self_of_mem (ρ g).property + simp only [y, Function.update_self, mul_assoc, hu, mul_one, + Function.update_idem, Function.update_eq_self] + simp [ne_of_gt (Fin.castSucc_lt_succ (i := j))] + rw [hz] at h + have hfirst : (0 : Fin (n + 2)) ≠ j.castSucc.succ := by + intro hh + have hv := congrArg Fin.val hh + simp at hv + have hlast : Fin.last (n + 1) ≠ j.castSucc.succ := by + exact Ne.symm (ne_of_lt (Fin.castSucc_lt_last j.succ)) + simpa only [Function.update_of_ne hfirst, Function.update_of_ne hlast, + map_one, OneMemClass.coe_one, star_one, one_mul, mul_one] using h.symm + +lemma finiteGroupCochainAverage_span {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M (n + 1)) {a : M} + (ha : a ∈ Submodule.span ℂ (Set.range (fun g => (ρ g : M)))) : + MultimodularAt (finiteGroupCochainAverage ρ f) a := by + apply multimodularAt_of_span _ _ _ ha + rintro _ ⟨g, rfl⟩ + exact finiteGroupCochainAverage_multimodularAt ρ f g + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteGroupPrefixAverages.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupPrefixAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..55d85d3fc1f02c05bcb653df60a75b9269d00d84 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteGroupPrefixAverages.lean @@ -0,0 +1,98 @@ +import OAI.Analysis.BoundedHochschild.MultimodularTransport + +namespace OAI + +/-! Contractive prefix averages interpolate between the identity and the +finite-group cochain average. They use the same independent vertex variables +as the bar-insertion operators. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M G : Type*} [CStarAlgebra M] [Group G] [Fintype G] + +def finiteGroupPrefixAverage {n : ℕ} (ρ : G →* unitary M) (k : ℕ) + (f : Cochain M n) : Cochain M n := + (Fintype.card (Fin (n + 1) → G) : ℂ)⁻¹ • + ∑ g : Fin (n + 1) → G, cochainUnitaryTransport (unitaryPrefix (fun j => ρ (g j)) k) f + +lemma finiteGroupPrefixAverage_norm {n : ℕ} (ρ : G →* unitary M) (k : ℕ) + (f : Cochain M n) : ‖finiteGroupPrefixAverage ρ k f‖ ≤ ‖f‖ := by + let K := Fin (n + 1) → G + have hc : (0 : ℝ) < Fintype.card K := Nat.cast_pos.mpr Fintype.card_pos + rw [finiteGroupPrefixAverage, norm_smul, norm_inv, Complex.norm_natCast] + calc + _ ≤ (Fintype.card K : ℝ)⁻¹ * ((Fintype.card K : ℝ) * ‖f‖) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr hc.le) + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] using + Finset.sum_le_sum (s := Finset.univ) (fun (g : K) _ => + cochainUnitaryTransport_norm (unitaryPrefix (fun j => ρ (g j)) k) f)) + _ = _ := by rw [← mul_assoc, inv_mul_cancel₀ (ne_of_gt hc), one_mul] + +lemma finiteGroupPrefixAverage_zero {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M n) : finiteGroupPrefixAverage ρ 0 f = f := by + have hp (g : Fin (n + 1) → G) : + unitaryPrefix (fun j => ρ (g j)) 0 = (fun _ => 1) := by + funext j + simp [unitaryPrefix] + simp only [finiteGroupPrefixAverage, hp, cochainUnitaryTransport_one, + Finset.sum_const, Finset.card_univ] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, + inv_mul_cancel₀ (Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos)), one_smul] + +lemma finiteGroupPrefixAverage_full {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M n) : finiteGroupPrefixAverage ρ (n + 1) f = finiteGroupCochainAverage ρ f := by + have hp (g : Fin (n + 1) → G) : + unitaryPrefix (fun j => ρ (g j)) (n + 1) = (fun j => ρ (g j)) := by + funext j + simp only [unitaryPrefix, j.isLt, ite_true] + simp only [finiteGroupPrefixAverage, hp, finiteGroupCochainAverage] + +lemma finiteGroupPrefixAverage_add {n : ℕ} (ρ : G →* unitary M) (k : ℕ) + (f g : Cochain M n) : finiteGroupPrefixAverage ρ k (f + g) = + finiteGroupPrefixAverage ρ k f + finiteGroupPrefixAverage ρ k g := by + simp only [finiteGroupPrefixAverage, cochainUnitaryTransport_add, + Finset.sum_add_distrib, smul_add] + +lemma finiteGroupPrefixAverage_smul {n : ℕ} (ρ : G →* unitary M) (k : ℕ) + (z : ℂ) (f : Cochain M n) : finiteGroupPrefixAverage ρ k (z • f) = + z • finiteGroupPrefixAverage ρ k f := by + simp only [finiteGroupPrefixAverage, cochainUnitaryTransport_smul, ← Finset.smul_sum] + exact smul_comm _ _ _ + +def finiteGroupPrefixAverageCLM (ρ : G →* unitary M) (n k : ℕ) : + Cochain M n →L[ℂ] Cochain M n := + LinearMap.mkContinuous + { toFun := finiteGroupPrefixAverage ρ k + map_add' := finiteGroupPrefixAverage_add ρ k + map_smul' := finiteGroupPrefixAverage_smul ρ k } + 1 (fun f => by + change ‖finiteGroupPrefixAverage ρ k f‖ ≤ 1 * ‖f‖ + simpa only [one_mul] using finiteGroupPrefixAverage_norm ρ k f) + +/-- The successive prefix changes sum to the difference between a cochain +and its full finite-group average. -/ +lemma finiteGroupPrefixAverage_telescope {n : ℕ} (ρ : G →* unitary M) + (f : Cochain M n) : + (∑ i : Fin (n + 1), (finiteGroupPrefixAverage ρ i.val f - + finiteGroupPrefixAverage ρ (i.val + 1) f)) = f - finiteGroupCochainAverage ρ f := by + have h (m : ℕ) : + (∑ i : Fin m, (finiteGroupPrefixAverage ρ i.val f - + finiteGroupPrefixAverage ρ (i.val + 1) f)) = + finiteGroupPrefixAverage ρ 0 f - finiteGroupPrefixAverage ρ m f := by + induction m with + | zero => simp + | succ m ih => + rw [Fin.sum_univ_castSucc] + simp only [Fin.val_castSucc, Fin.val_last] + rw [ih] + abel + simpa only [finiteGroupPrefixAverage_zero, finiteGroupPrefixAverage_full] using h (n + 1) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteIncreasingComparison.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteIncreasingComparison.lean new file mode 100644 index 0000000000000000000000000000000000000000..0b67b2a02798b5a1b027c2f3100c104c1174474d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteIncreasingComparison.lean @@ -0,0 +1,79 @@ +import OAI.Analysis.BoundedHochschild.FiniteProjectionExtension + +namespace OAI + +/-! +# Increasing limits of subequivalent projections + +Ringrose, *Lectures on the trace in a finite von Neumann algebra*, Lemma 5.1: +an increasing supremum of projections subequivalent to a fixed finite +projection is still subequivalent to it. The proof aligns successive partial +isometries inside the finite corner and then takes their chain supremum. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Increasing limits preserve subequivalence to a finite projection. -/ +theorem finite_increasing_subequivalence (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {q : M} (hq : IsStarProjection q) (hfinite : FiniteCorner q) + (p : ℕ → M) (hmono : Monotone p) + (hembed : ∀ n, ∃ v : PartialIso M, v.initial = p n ∧ v.final ≤ q) : + ∃ v : PartialIso M, v.final ≤ q ∧ (∀ n, p n ≤ v.initial) ∧ + ∀ r : M, IsStarProjection r → (∀ n, p n ≤ r) → v.initial ≤ r := by + classical + choose b hb using hembed + let S (n : ℕ) := {v : PartialIso M // v.initial = p n ∧ v.final ≤ q} + have hnext (n : ℕ) (v : S n) : ∃ w : S (n + 1), v.val ≤ w.val := by + have hle : v.val.initial ≤ (b (n + 1)).initial := by + rw [v.property.1, (hb (n + 1)).1] + exact hmono (Nat.le_succ n) + obtain ⟨w, hvw, hwi, hwf⟩ := finite_partialIso_extension e hq hfinite + v.val (b (n + 1)) hle v.property.2 (hb (n + 1)).2 + exact ⟨⟨w, hwi.trans (hb (n + 1)).1, hwf⟩, hvw⟩ + choose step hstep using hnext + let a : (n : ℕ) → S n := fun n => Nat.rec ⟨b 0, hb 0⟩ (fun n v => step n v) n + let f : ℕ → PartialIso M := fun n => (a n).val + have hfmono : Monotone f := monotone_nat_of_le_succ fun n => hstep n (a n) + have hfi (n : ℕ) : (f n).initial = p n := (a n).property.1 + have hff (n : ℕ) : (f n).final ≤ q := (a n).property.2 + obtain ⟨v, hupper, _, hi, hf⟩ := exists_partialIso_chain_supremum e (Set.range f) + hfmono.isChain_range (Set.range_nonempty f) + refine ⟨v, hf q hq (by rintro _ ⟨n, rfl⟩; exact hff n), ?_, ?_⟩ + · intro n + rw [← hfi n] + exact (hupper _ ⟨n, rfl⟩).1 + · intro r hr hb + apply hi r hr + rintro _ ⟨n, rfl⟩ + rw [hfi n] + exact hb n + +/-- Ringrose's Lemma 5.1 with the supremum specified in advance. -/ +theorem finite_subequivalence_at_supremum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {q s : M} (hq : IsStarProjection q) (hfinite : FiniteCorner q) + (hs : IsStarProjection s) (p : ℕ → M) (hmono : Monotone p) + (hembed : ∀ n, ∃ v : PartialIso M, v.initial = p n ∧ v.final ≤ q) + (hupper : ∀ n, p n ≤ s) + (hleast : ∀ r : M, IsStarProjection r → (∀ n, p n ≤ r) → s ≤ r) : + ∃ v : PartialIso M, v.initial = s ∧ v.final ≤ q := by + obtain ⟨v, hvq, hvupper, hvleast⟩ := finite_increasing_subequivalence e hq hfinite + p hmono hembed + exact ⟨v, le_antisymm (hvleast s hs hupper) + (hleast v.initial v.initial_proj hvupper), hvq⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteModuleAverages.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteModuleAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..c30e6a30468caa4fcb946049b4dd5a10069ad2c1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteModuleAverages.lean @@ -0,0 +1,79 @@ +import OAI.Analysis.BoundedHochschild.EncodedMapFamilies +import OAI.Analysis.BoundedHochschild.RightModuleAveragingExistence + +namespace OAI + +/-! A finite family of completely bounded maps admits a simultaneous +right-module average, with each original complete bound retained. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def finiteFamilyAverageOrbit {I : Type*} (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) : Set (I → M → WeakDual ℂ X) := + {F | ∃ (k : ℕ) (m : Fin k → M), (∑ j, m j * star (m j) = 1) ∧ + F = fun i => weakOperatorImage e (finiteRightAverage m (T i))} + +def weakFamilyAverageOrbit {I : Type*} (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) : Set (I → M → WeakDual ℂ X) := + closure (finiteFamilyAverageOrbit e T) + +theorem exists_finite_right_module_average [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + {n : ℕ} (T : Fin (n+1) → M →L[ℂ] M) (C : Fin (n+1) → ℝ) + (hT : ∀ i, CompletelyBoundedEstimate (T i) (C i)) : + ∃ S : Fin (n+1) → M →L[ℂ] M, + (∀ i, ‖S i‖ ≤ C i ∧ ∀ a b, S i (a*b) = S i a * b) ∧ + (fun i => weakOperatorImage e (S i)) ∈ weakFamilyAverageOrbit e T := by + obtain ⟨c, hi, ho, _⟩ := exists_properlyInfinite_matrix_columns e hno (n+1) + let B := encodeMapFamily c T + let D := ∑ i, ‖(c i : M)‖ * C i * ‖star (c i : M)‖ + have hB : CompletelyBoundedEstimate B D := encodeMapFamily_completelyBounded c T C hT + have hB' : CompletelyBoundedEstimate B (D+1) := + ⟨by linarith [hB.1], fun k A => (hB.2 k A).trans + (mul_le_mul_of_nonneg_right (by linarith) (norm_nonneg A))⟩ + obtain ⟨R, _, hRorb, hR⟩ := exists_right_module_average e hno B + (by linarith [hB.1] : 0 < D+1) hB' + let S (i : Fin (n+1)) := leftSandwichMap (star (c i : M)) (c i : M) R + have he (i : Fin (n+1)) : + leftSandwichMap (star (c i : M)) (c i : M) B = T i := + extract_encodeMapFamily c hi ho T i + have horb (i : Fin (n+1)) : weakOperatorImage e (S i) ∈ weakRightAverageOrbit e (T i) := by + have h := weakLeftSandwich_mapsTo_orbit e (star (c i : M)) (c i : M) B hRorb + rwa [weakLeftSandwich_image, he] at h + refine ⟨S, fun i => ⟨?_, ?_⟩, ?_⟩ + · obtain ⟨U, hU, hUS⟩ := weakOperatorBall_realize e (hT i).1 + (weakRightAverageOrbit_subset_ball e hno (T i) (hT i) (horb i)) + have heq := weakOperatorImage_injective e hUS + exact heq ▸ hU + · intro a b + change star (c i : M) * R ((c i : M) * (a*b)) = + (star (c i : M) * R ((c i : M) * a)) * b + rw [← mul_assoc (c i : M) a b, hR, mul_assoc] + · let E (F : M → WeakDual ℂ X) : Fin (n+1) → M → WeakDual ℂ X := + fun i => weakLeftSandwich e (star (c i : M)) (c i : M) F + have hEc : Continuous E := continuous_pi (fun i => weakLeftSandwich_continuous e _ _) + have hmap : Set.MapsTo E (weakOperatorImage e '' rightAverageOrbit B) + (finiteFamilyAverageOrbit e T) := by + rintro F ⟨U, ⟨k, m, hm, rfl⟩, rfl⟩ + refine ⟨k, m, hm, ?_⟩ + funext i + dsimp [E] + rw [weakLeftSandwich_image, leftSandwichMap_rightAverage, he] + have hh := hmap.closure hEc hRorb + simpa only [E, weakLeftSandwich_image, S, weakFamilyAverageOrbit] using hh + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteMoments.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteMoments.lean new file mode 100644 index 0000000000000000000000000000000000000000..b2e61f94ca707a589d0e0353819c64365bbfa284 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteMoments.lean @@ -0,0 +1,241 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.IncrementalPatching + +namespace OAI + +/-! Small unitary moments, reindexing and simultaneous moment sequences. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open scoped BigOperators ComplexConjugate InnerProductSpace ComplexOrder +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +universe u v +variable {M : Type u} [CStarAlgebra M] + +def asPartialUnitary (u : unitary M) : PartialUnitary M := + ⟨⟨(u:M),by rw [u.property.2,one_mul]⟩,by + change (u:M)*star (u:M)=star (u:M)*(u:M) + exact u.property.2.trans u.property.1.symm⟩ +@[simp] lemma asPartialUnitary_coe (u : unitary M) : ((asPartialUnitary u : PartialUnitary M):M)=(u:M) := rfl +lemma asPartialUnitary_power (u : unitary M) (k : Bool × ℕ) : + (asPartialUnitary u).power k=((u^signedExponent k : unitary M):M) := by + dsimp only [PartialUnitary.power,signedExponent] + split + · rw [zpow_neg,show (k.2 : ℤ)+1=((k.2+1 : ℕ):ℤ) by simp,zpow_natCast,← Unitary.star_eq_inv, + Unitary.coe_star,SubmonoidClass.coe_pow,star_pow] + rfl + · rw [show (k.2 : ℤ)+1=((k.2+1 : ℕ):ℤ) by simp,zpow_natCast,SubmonoidClass.coe_pow] + rfl + +variable [PartialOrder M] [StarOrderedRing M] +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {I : Type v} [Fintype I] (F : I → M) +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in +theorem exists_unitary_small_moments + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (hF : ∀ i, ‖F i‖ ≤ 1) (hFτ : ∀ i, τ (F i)=0) + {K N : ℕ} (hK : 0 ?_⟩ + rw [he] + have herr := trace_mixedEval_patch τ htr F v w horth hF a.1 a.2.val + rw [hwt] at herr + have hvb := hvm a ha + rw [hvs] at hvb + have hb : expBudget δ (patchRate N T) T ≤ ε/4 := by + change δ*(Real.exp (C*T)-1) ≤ ε/4 + have heq : δ*Real.exp (C*T)=ε/4 := by dsimp only [δ]; field_simp + nlinarith + have hn : (a.2.val.length : ℝ)*t ≤ ε/4 := by + have hnN : (a.2.val.length : ℝ) ≤ (N : ℝ)+1 := by exact_mod_cast (a.2.property.trans (Nat.le_succ N)) + have hnt := mul_le_mul_of_nonneg_right hnN ht0.le + have hpos : 0<(4*((N : ℝ)+1)) := by positivity + have htbound := (le_div_iff₀ hpos).mp htε + nlinarith + have htotal : ‖τ (mixedEval F (v.orthogonalSum w horth) a.1 a.2.val)‖ ≤ ε/2 := by + calc + _ ≤ ‖τ (mixedEval F (v.orthogonalSum w horth) a.1 a.2.val)-τ (mixedEval F v a.1 a.2.val)‖+ + ‖τ (mixedEval F v a.1 a.2.val)‖ := by + simpa only [sub_add_cancel] using norm_add_le + (τ (mixedEval F (v.orthogonalSum w horth) a.1 a.2.val)-τ (mixedEval F v a.1 a.2.val)) + (τ (mixedEval F v a.1 a.2.val)) + _ ≤ ε/4+ε/4 := add_le_add (herr.trans hn) (hvb.trans hb) + _ = _ := by ring + exact htotal.trans_lt (by linarith) + +end HochschildPatching + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M : Type*} [CStarAlgebra M] +variable {I J : Type*} {K L : ℕ} + +def mapAtom (f : I → J) (g : Fin K → Fin L) (a : WordAtom I K) : WordAtom J L := + ((a.1.1,g a.1.2),a.2.map f) +lemma wordCoeff_map (F : J → M) (f : I → J) (a : Option I) : + wordCoeff F (a.map f)=wordCoeff (F ∘ f) a := by cases a <;> rfl +lemma mixedEval_map (F : J → M) (f : I → J) (g : Fin K → Fin L) + (hg : ∀ k, (g k).val=k.val) (v : PartialUnitary M) (a : Option I) (l : List (WordAtom I K)) : + mixedEval F v (a.map f) (l.map (mapAtom f g))=mixedEval (F ∘ f) v a l := by + unfold mixedEval + rw [wordCoeff_map] + congr 1 + unfold evaluatedTail + rw [List.map_map] + congr 1 + apply List.map_congr_left + intro b hb + simp only [Function.comp_apply,mapAtom,wordCoeff_map,hg] + +lemma admissibleTail_map (f : I → J) (g : Fin K → Fin L) (l : List (WordAtom I K)) + (hl : admissibleTail l) : admissibleTail (l.map (mapAtom f g)) := by + constructor + · intro h; exact hl.1 (List.map_eq_nil_iff.mp h) + · intro b hb + rw [← List.map_dropLast] at hb + obtain ⟨a,ha,rfl⟩ := List.mem_map.mp hb + intro h + exact hl.2 a ha (Option.map_eq_none_iff.mp h) + +def coeffNumber (a : Option I) : ℕ := if a.isSome then 1 else 0 +def wordCoeffNumber (a : Option I) (l : List (WordAtom I K)) : ℕ := + coeffNumber a + (l.map (fun b => coeffNumber b.2)).sum +lemma wordCoeff_smul (F : I → M) (c : ℂ) (a : Option I) : + wordCoeff (fun i => c • F i) a=c^coeffNumber a • wordCoeff F a := by + cases a <;> simp [wordCoeff,coeffNumber] +lemma mixedEval_smul (F : I → M) (c : ℂ) (v : PartialUnitary M) + (a : Option I) (l : List (WordAtom I K)) : + mixedEval (fun i => c • F i) v a l=c^wordCoeffNumber a l • mixedEval F v a l := by + have ht (l : List (WordAtom I K)) : + wordProduct v.power (evaluatedTail (fun i => c • F i) l)= + c^(l.map (fun b => coeffNumber b.2)).sum • wordProduct v.power (evaluatedTail F l) := by + induction l with + | nil => simp [evaluatedTail] + | cons b l ih => + change v.power (b.1.1,b.1.2.val)*wordCoeff (fun i => c • F i) b.2* + wordProduct v.power (evaluatedTail (fun i => c • F i) l) = + c^(coeffNumber b.2+(l.map (fun b => coeffNumber b.2)).sum) • + (v.power (b.1.1,b.1.2.val)*wordCoeff F b.2*wordProduct v.power (evaluatedTail F l)) + rw [wordCoeff_smul,ih] + simp only [pow_add,mul_smul_comm,smul_mul_assoc,smul_smul,mul_comm] + unfold mixedEval wordCoeffNumber + rw [wordCoeff_smul,ht,pow_add] + simp only [mul_smul_comm,smul_mul_assoc,smul_smul,mul_comm] +end HochschildPatching + + + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in +theorem exists_small_moment_sequence + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (F : ℕ → ℕ → M) (hF : ∀ n i, ‖F n i‖ ≤ 1) (hFτ : ∀ n i, τ (F n i)=0) : + ∃ u : ℕ → unitary M, ∀ m K N : ℕ, ∀ a : BoundedWord (Fin m) K N, + admissibleTail a.2.val → + Tendsto (fun n => τ (mixedEval (fun i : Fin m => F n i.val) (asPartialUnitary (u n)) a.1 a.2.val)) atTop (nhds 0) := by + classical + have hex (n : ℕ) := exists_unitary_small_moments (fun i : Fin n => F n i.val) e τ + hτ h1 htr hfaith hfactor hdiff (fun i => hF n i.val) (fun i => hFτ n i.val) + (Nat.zero_lt_succ n) (N := n) (ε := 1/((n:ℝ)+1)) (by positivity) + choose u hu using hex + refine ⟨u,fun m K N a ha => ?_⟩ + apply Metric.tendsto_nhds.mpr + intro ε hε + obtain ⟨b,hb⟩ := exists_nat_gt (1/ε) + filter_upwards [eventually_ge_atTop (max b (max m (max K N)))] with n hn + have hbn : b ≤ n := (le_max_left _ _).trans hn + have hmn : m ≤ n := (le_max_left m (max K N)).trans ((le_max_right b _).trans hn) + have hKn : K ≤ n := (le_max_left K N).trans ((le_max_right m _).trans ((le_max_right b _).trans hn)) + have hNn : N ≤ n := (le_max_right K N).trans ((le_max_right m _).trans ((le_max_right b _).trans hn)) + let f : Fin m → Fin n := fun i => ⟨i.val,i.isLt.trans_le hmn⟩ + let g : Fin K → Fin (n+1) := fun i => ⟨i.val,i.isLt.trans_le (hKn.trans (Nat.le_succ n))⟩ + let a' : BoundedWord (Fin n) (n+1) n := + (a.1.map f,⟨a.2.val.map (mapAtom f g),by simpa using a.2.property.trans hNn⟩) + have htest := hu n a' (admissibleTail_map f g a.2.val ha) + change ‖τ (mixedEval (fun i : Fin n => F n i.val) (asPartialUnitary (u n)) + (a.1.map f) (a.2.val.map (mapAtom f g)))‖ < _ at htest + rw [mixedEval_map _ f g (fun _ => rfl)] at htest + have hFcomp : (fun i : Fin n => F n i.val) ∘ f = (fun i : Fin m => F n i.val) := rfl + rw [hFcomp] at htest + have hne : 1/((n:ℝ)+1)<ε := by + have hbR : (b:ℝ) ≤ n := by exact_mod_cast hbn + have hpos : (0:ℝ)<(n:ℝ)+1 := by positivity + apply (div_lt_iff₀ hpos).mpr + have hh := (div_lt_iff₀ hε).mp hb + nlinarith + simpa only [dist_zero_right] using htest.trans hne + +end HochschildPatching +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteNormalOrbit.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalOrbit.lean new file mode 100644 index 0000000000000000000000000000000000000000..69c82d9c4705631f8641217b3a91cf0acd77f5a5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalOrbit.lean @@ -0,0 +1,107 @@ +import OAI.Analysis.BoundedHochschild.FiniteProjectionAbsoluteContinuity + +namespace OAI + +/-! +# Uniform normal-state decay along unitary orbits + +Ringrose, *Lectures on the trace in a finite von Neumann algebra*, Lemma 5.2, +for positive normal functionals. This is the specialization needed for the +normal-state orbit used in constructing a trace. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A normal positive functional vanishes along projections subequivalent to +an orthogonal sequence in a finite algebra. -/ +theorem normal_positive_subequivalent_tendsto_zero (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (p q : ℕ → M) (hp : ∀ n, IsStarProjection (p n)) + (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) + (hembed : ∀ n, ∃ v : PartialIso M, v.initial = p n ∧ v.final ≤ q n) : + Tendsto (fun n => ψ (p n)) atTop (𝓝 0) := by + obtain ⟨R, _, _, hle, ht⟩ := finite_subequivalent_orthogonal_tails e hfinite p q + hp hq horth hembed + have hRt : Tendsto (fun n => ‖ψ (R n)‖) atTop (𝓝 0) := by + simpa only [map_zero, norm_zero] using (trace_predual_tendsto e ψ hψ ht).norm + rw [tendsto_iff_norm_sub_tendsto_zero] + simp only [sub_zero] + apply squeeze_zero (fun n => norm_nonneg _) (fun n => ?_) hRt + exact CStarAlgebra.norm_le_norm_of_le_of_nonneg (ψ.monotone (hle n)) + (ψ.map_nonneg (hp n).nonneg) + +/-- Choosing a different unitary at each index still gives normal-state decay. -/ +theorem normal_positive_unitary_orbit_tendsto_zero (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (q : ℕ → M) (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) (u : ℕ → unitary M) : + Tendsto (fun n => ψ ((u n : M) * q n * star (u n : M))) atTop (𝓝 0) := by + let w (n : ℕ) : PartialIso M := ⟨(u n : M) * q n, by + have hu := (Unitary.mem_iff.mp (u n).property).1 + simp only [star_mul, (hq n).isSelfAdjoint.star_eq] + calc + ((u n : M) * q n) * (q n * star (u n : M)) * ((u n : M) * q n) = + (u n : M) * (q n * q n) * (star (u n : M) * (u n : M)) * q n := by + simp only [mul_assoc] + _ = (u n : M) * q n := by + rw [(hq n).isIdempotentElem.eq, hu, mul_one, mul_assoc, + (hq n).isIdempotentElem.eq]⟩ + have hwi (n : ℕ) : (w n).initial = q n := by + change star ((u n : M) * q n) * ((u n : M) * q n) = q n + rw [star_mul, (hq n).isSelfAdjoint.star_eq] + calc + _ = q n * (star (u n : M) * (u n : M)) * q n := by simp only [mul_assoc] + _ = q n := by rw [(Unitary.mem_iff.mp (u n).property).1, mul_one, + (hq n).isIdempotentElem.eq] + have hwf (n : ℕ) : (w n).final = (u n : M) * q n * star (u n : M) := by + change ((u n : M) * q n) * star ((u n : M) * q n) = _ + rw [star_mul, (hq n).isSelfAdjoint.star_eq] + calc + _ = (u n : M) * (q n * q n) * star (u n : M) := by simp only [mul_assoc] + _ = _ := by rw [(hq n).isIdempotentElem.eq] + have ht := normal_positive_subequivalent_tendsto_zero e hfinite ψ hψ + (fun n => (w n).final) q (fun n => (w n).final_proj) hq horth + (fun n => ⟨adjointPartialIso (w n), by simp, by simp [hwi]⟩) + simpa only [hwf] using ht + +/-- Normal positive functionals are uniformly small on every unitary conjugate +of the terms of an orthogonal projection sequence in a finite algebra. -/ +theorem normal_positive_uniform_unitary_orbit (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (q : ℕ → M) (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) (ε : ℝ) (hε : 0 < ε) : + ∀ᶠ n in atTop, ∀ u : unitary M, ‖ψ ((u : M) * q n * star (u : M))‖ < ε := by + classical + let u (n : ℕ) : unitary M := if h : ∃ v : unitary M, + ε ≤ ‖ψ ((v : M) * q n * star (v : M))‖ then h.choose else 1 + have ht := normal_positive_unitary_orbit_tendsto_zero e hfinite ψ hψ q hq horth u + have hlt : ∀ᶠ n in atTop, ‖ψ ((u n : M) * q n * star (u n : M))‖ < ε := + (tendsto_order.1 (by simpa only [norm_zero] using ht.norm)).2 ε hε + filter_upwards [hlt] with n hn v + by_contra hv + have hex : ∃ v : unitary M, ε ≤ ‖ψ ((v : M) * q n * star (v : M))‖ := + ⟨v, le_of_not_gt hv⟩ + have hu : ε ≤ ‖ψ ((u n : M) * q n * star (u n : M))‖ := by + simpa only [u, dite_eq_left hex] using hex.choose_spec + exact (not_le_of_gt hn) hu + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteNormalState.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalState.lean new file mode 100644 index 0000000000000000000000000000000000000000..b5d656e2b68d4ac69ec1cbcc6db56de6808039bc --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalState.lean @@ -0,0 +1,149 @@ +import OAI.Analysis.BoundedHochschild.FiniteTraceCover +import OAI.Analysis.BoundedHochschild.FiniteCentralDecomposition + +namespace OAI + +/-! +# Normal states and the remaining tracial averaging step + +A normal state faithful on central projections is faithful on positive +central elements. The property passes to its actual central corner. +Composing such a state with a faithful normal positive central averaging +map gives a faithful normal tracial state. Constructing that map from +finiteness is a separate remaining theorem; no such map is postulated here. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A positive functional vanishing on a positive contraction annihilates its left multiples. -/ +lemma positive_contraction_zero_mul (ψ : M →ₚ[ℂ] ℂ) {c : M} + (hc0 : 0 ≤ c) (hc1 : c ≤ 1) (hψc : ψ c = 0) (b : M) : ψ (c * b) = 0 := by + have hcc : c * c ≤ c := by + simpa only [pow_two, pow_one] using + CStarAlgebra.pow_antitone hc1 hc0 (by omega : 1 ≤ 2) + have hψcc : ψ (c * c) = 0 := le_antisymm + ((ψ.monotone hcc).trans_eq hψc) + (ψ.map_nonneg hc0.isSelfAdjoint.mul_self_nonneg) + have h := PositiveLinearMap.norm_map_star_mul_sq_le ψ c b + rw [hc0.isSelfAdjoint.star_eq, hψcc, norm_zero, zero_mul] at h + exact norm_eq_zero.mp (by nlinarith [norm_nonneg (ψ (c * b))]) + +/-- The support projection of a null positive contraction is null for a normal functional. -/ +lemma exists_null_support_projection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) {c : M} + (hc0 : 0 ≤ c) (hc1 : c ≤ 1) (hψc : ψ c = 0) : + ∃ r : M, IsSupportProjection c r ∧ ψ r = 0 := by + obtain ⟨r, hr, ht⟩ := HochschildSakai.exists_support_contraction e c hc0 hc1 + have hpow (n : ℕ) : ψ ((1 - c) ^ n) = ψ 1 := by + induction n with + | zero => simp only [pow_zero] + | succ n ih => + rw [pow_succ', sub_mul, one_mul, map_sub, + positive_contraction_zero_mul ψ hc0 hc1 hψc, sub_zero, ih] + have hzero (n : ℕ) : ψ (1 - (1 - c) ^ n) = 0 := by + rw [map_sub, hpow, sub_self] + refine ⟨r, hr, ?_⟩ + have hl := trace_predual_tendsto e ψ hψ ht + have heq : (fun n : ℕ => ψ (1 - (1 - c) ^ n)) = (fun _ : ℕ => (0 : ℂ)) := funext hzero + rw [heq] at hl + exact tendsto_nhds_unique hl tendsto_const_nhds + +/-- Normality upgrades faithfulness on central projections to positive central elements. -/ +theorem normal_state_faithful_on_positive_center (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (hfaith : ∀ p : M, IsStarProjection p → (∀ a : M, p * a = a * p) → ψ p = 0 → p = 0) + {a : M} (ha : 0 ≤ a) (hcentral : ∀ b : M, a * b = b * a) (hψa : ψ a = 0) : + a = 0 := by + let t : ℝ := ‖a‖ + 1 + have ht : 0 < t := by dsimp [t]; positivity + let c : M := t⁻¹ • a + have hc0 : 0 ≤ c := smul_nonneg (inv_nonneg.mpr ht.le) ha + have hcn : ‖c‖ ≤ 1 := by + rw [show c = t⁻¹ • a from rfl, norm_smul, Real.norm_eq_abs, abs_of_pos (inv_pos.mpr ht)] + exact (inv_mul_le_one₀ ht).mpr (by dsimp [t]; linarith) + have hc1 : c ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg c hc0).mp hcn + have hψc : ψ c = 0 := by + rw [show c = t⁻¹ • a from rfl, ψ.map_smul_of_tower, hψa, smul_zero] + obtain ⟨r, hr, hψr⟩ := exists_null_support_projection e ψ hψ hc0 hc1 hψc + have hrc : ∀ b : M, r * b = b * r := by + intro b + apply (hr.commute hc0.isSelfAdjoint ?_).eq + change (t⁻¹ • a) * b = b * (t⁻¹ • a) + rw [smul_mul_assoc, mul_smul_comm, hcentral] + have hr0 : r = 0 := hfaith r hr.proj hrc hψr + have hc : c = 0 := by simpa only [hr0, zero_mul] using hr.left.symm + exact (smul_eq_zero.mp hc).resolve_left (inv_ne_zero ht.ne') + +/-- A state faithful on the central subprojections of `p` induces a normal state +faithful on all central projections of the actual corner `pMp`. -/ +theorem central_faithful_state_on_corner (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p : M} (hp : IsStarProjection p) (hc : ∀ a : M, p * a = a * p) + (hstate : HasCentralFaithfulNormalState e p) : + ∃ ψ : Corner p hp →ₚ[ℂ] ℂ, + TraceInPredual (cornerPredualEquiv p hp e) ψ ∧ ψ 1 = 1 ∧ + ∀ q : Corner p hp, IsStarProjection q → + (∀ a : Corner p hp, q * a = a * q) → ψ q = 0 → q = 0 := by + obtain ⟨ψ, hψ, _, hψp, hfaith⟩ := hstate + let τ := cornerTrace p hp ψ + have hτ (a : Corner p hp) : τ a = ψ (a : M) := by + simp only [τ, cornerTrace_apply, hψp, Complex.one_re, Complex.ofReal_one, inv_one, one_mul] + refine ⟨τ, cornerTrace_normal p hp e ψ hψ, ?_, ?_⟩ + · simpa only [hτ, corner_coe_one] using hψp + · intro q hq hqc hzero + apply Subtype.ext + exact hfaith (q : M) (corner_projection_coe p hp hq) + (centralCorner_central hp hc q hqc) (corner_projection_le p hp hq) + (by rwa [hτ] at hzero) + +/-- Actual normal central averaging data convert a center-faithful state into a +faithful normal trace. The existence of this averaging map is the remaining +finite-algebra input. -/ +theorem tracial_state_of_normal_center_average (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) (hψ1 : ψ 1 = 1) + (hfaith : ∀ p : M, IsStarProjection p → (∀ a : M, p * a = a * p) → ψ p = 0 → p = 0) + (E : M →L[ℂ] M) (hEnormal : HasPreadjoint e E) + (hEpositive : ∀ a : M, 0 ≤ a → 0 ≤ E a) (hE1 : E 1 = 1) + (hEcentral : ∀ a b : M, E a * b = b * E a) + (hEtracial : ∀ a b : M, E (a * b) = E (b * a)) + (hEfaithful : ∀ a : M, E (star a * a) = 0 → a = 0) : + ∃ τ : M →ₚ[ℂ] ℂ, TraceInPredual e τ ∧ τ 1 = 1 ∧ + (∀ a b : M, τ (a * b) = τ (b * a)) ∧ + (∀ a : M, τ (star a * a) = 0 → a = 0) := by + let τ : M →ₚ[ℂ] ℂ := + { toLinearMap := ψ.toLinearMap.comp E.toLinearMap + monotone' := by + change Monotone (ψ.toLinearMap.comp E.toLinearMap) + apply (monotone_iff_map_nonneg _).mpr + intro a ha + exact ψ.map_nonneg (hEpositive a ha) } + have hτ (a : M) : τ a = ψ (E a) := rfl + refine ⟨τ, ?_, ?_, ?_, ?_⟩ + · obtain ⟨z, hz⟩ := hψ + obtain ⟨w, hw⟩ := hEnormal z + exact ⟨w, fun a => by rw [hτ, hz, hw]⟩ + · rw [hτ, hE1, hψ1] + · intro a b + rw [hτ, hτ, hEtracial] + · intro a ha + apply hEfaithful a + exact normal_state_faithful_on_positive_center e ψ hψ hfaith + (hEpositive _ (star_mul_self_nonneg a)) (hEcentral _) ha + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteNormalTrace.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalTrace.lean new file mode 100644 index 0000000000000000000000000000000000000000..a33c01b6abefce139f32e6a5cb76fd042cf9c633 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteNormalTrace.lean @@ -0,0 +1,100 @@ +import OAI.Analysis.BoundedHochschild.NormalOrbitInvariance + +namespace OAI + +/-! +# Normal traces in finite von Neumann algebras + +Ringrose, Theorem 5.4: the compact convex unitary orbit of a positive normal +functional contains a normal trace with the same values on the center. +This construction assumes no scalar or center-valued trace. +-/ + +noncomputable section + +open Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u + +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma tracial_of_unitary_invariant (F : StrongDual ℂ M) + (hinv : ∀ (u : unitary M) (a : M), F ((u : M) * a * star (u : M)) = F a) : + ∀ a b : M, F (a * b) = F (b * a) := by + classical + have hu (u : unitary M) (b : M) : F ((u : M) * b) = F (b * (u : M)) := by + calc + F ((u : M) * b) = F ((u : M) * (b * (u : M)) * star (u : M)) := by + simp only [mul_assoc, Unitary.mul_star_self_of_mem u.property, mul_one] + _ = F (b * (u : M)) := hinv u _ + intro a b + obtain ⟨u, c, ha, _⟩ := CStarAlgebra.exists_sum_four_unitary a + rw [ha, Finset.sum_mul, Finset.mul_sum, map_sum, map_sum] + apply Finset.sum_congr rfl + intro i _ + rw [smul_mul_assoc, mul_smul_comm, map_smul, map_smul, hu] + +variable [PartialOrder M] [StarOrderedRing M] + +/-- Every positive normal functional on a finite von Neumann algebra has a +normal tracial average agreeing with it on the center. -/ +theorem exists_normal_tracial_average (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) : + ∃ τ : M →ₚ[ℂ] ℂ, TraceInPredual e τ ∧ τ 1 = ψ 1 ∧ + (∀ a b : M, τ (a * b) = τ (b * a)) ∧ + ∀ a : M, (∀ b : M, a * b = b * a) → τ a = ψ a := by + classical + let C : Set (WeakSpace ℂ X) := (weakPredualMap e) ⁻¹' + weakFunctionalClosure (unitaryOrbitHull (positiveFunctionalCLM ψ)) + have hC : IsCompact C := normal_positive_predual_orbit_compact e hfinite ψ hψ + obtain ⟨z, hz⟩ := hψ + have hemb : predualEmbedding e z = positiveFunctionalCLM ψ := by + ext a + exact (hz a).symm + have hn : C.Nonempty := by + refine ⟨toWeakSpace ℂ X z, ?_⟩ + change StrongDual.toWeakDual (predualEmbedding e z) ∈ + weakFunctionalClosure (unitaryOrbitHull (positiveFunctionalCLM ψ)) + rw [hemb] + apply subset_closure + refine ⟨positiveFunctionalCLM ψ, ?_, rfl⟩ + have hmem := subset_closure (subset_convexHull ℝ + (Set.range (unitaryPullback (positiveFunctionalCLM ψ))) (Set.mem_range_self 1)) + simpa only [unitaryPullback_one, unitaryOrbitHull] using hmem + obtain ⟨x, hx, hfix⟩ := weakCompact_isometric_fixedPoint (unitaryPredualAction e) + (unitaryPredualAction_one e) (unitaryPredualAction_mul e) C hC hn + (weakPredualOrbit_convex e _) (weakPredualOrbit_invariant e _) + let F := weakPredualMap e x + have hFpos : ∀ a : M, 0 ≤ a → 0 ≤ F a := + weakFunctionalClosure_positive _ (unitaryOrbitHull_positive ψ) hx + let τ : M →ₚ[ℂ] ℂ := + { toLinearMap := (WeakDual.toStrongDual F).toLinearMap + monotone' := (monotone_iff_map_nonneg _).mpr hFpos } + have hτnormal : TraceInPredual e τ := by + exact ⟨(toWeakSpace ℂ X).symm x, fun _ => rfl⟩ + have hτcenter (a : M) (ha : ∀ b : M, a * b = b * a) : τ a = ψ a := + weakFunctionalClosure_eval_eq _ a (ψ a) + (unitaryOrbitHull_central (positiveFunctionalCLM ψ) ha) hx + have hτinv : ∀ (u : unitary M) (a : M), τ ((u : M) * a * star (u : M)) = τ a := by + intro u a + have hxfix : unitaryPredualAction e (star u) ((toWeakSpace ℂ X).symm x) = + (toWeakSpace ℂ X).symm x := congrArg (toWeakSpace ℂ X).symm (hfix (star u)) + have heq := congrArg (predualEmbedding e) hxfix + rw [predualEmbedding_unitaryAction, star_star] at heq + exact congrArg (fun f : StrongDual ℂ M => f a) heq + exact ⟨τ, hτnormal, hτcenter 1 (fun b => by rw [one_mul, mul_one]), + tracial_of_unitary_invariant (positiveFunctionalCLM τ) hτinv, hτcenter⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FinitePaths.lean b/lean/OAI/Analysis/BoundedHochschild/FinitePaths.lean new file mode 100644 index 0000000000000000000000000000000000000000..fe84cbd342b7c70b72a6aaf19a9ac950f74644a2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FinitePaths.lean @@ -0,0 +1,266 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PathStages + +namespace OAI + +/-! Simultaneous finite path tests and construction of stage assignments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open MeasureTheory Filter Topology +open scoped ComplexOrder +namespace HochschildRare +open HochschildWalk +variable {M : Type*} [CStarAlgebra M] + +def signedValue {A : Type*} (v : A → unitary M) (a : A × Bool) : unitary M := + if a.2 then v a.1 else (v a.1)⁻¹ + +def pathValue {A : Type*} {r n : ℕ} (v : A → unitary M) + (w : Fin r × Fin n → A × Bool) (i : Fin r) : unitary M := + word (fun j => signedValue v (w (i,j))) + + + +def FinitePathTests [PartialOrder M] (τ : M →ₚ[ℂ] ℂ) : Prop := + ∀ (C D T : Type) [Fintype C] [Fintype D] [Fintype T], + Nonempty D → ∀ (v : C → unitary M) (r n : T → ℕ) + (w : ∀ t, Fin (r t) × Fin (n t) → (C ⊕ D) × Bool) + (q : ∀ t, FreeGroup (Fin (r t))), + (∀ t, q t ≠ 1) → + (∀ t, ∃ (s : Fin (r t) → Fin (n t)) (a : Fin (r t) → D), + (∀ i, (w t (i,s i)).1 = Sum.inr (a i)) ∧ + (∀ i z, (w t z).1 = Sum.inr (a i) → z=(i,s i))) → + ∀ ε : ℝ, 0 < ε → ∃ u : D → unitary M, + ∀ t, ‖τ (FreeGroup.lift (pathValue (Sum.elim v u) (w t)) (q t) : M)‖ < ε + +def assignedLabel (v : ℕ → unitary M) + (a : ∀ k, Fin (labels k) → unitary M) : Label → unitary M + | .inl j => v j + | .inr t => a t.1 t.2 + +abbrev StepCoeff (k : ℕ) := Fin (baseCut k) ⊕ ((j : Fin k) × Fin (labels j.val)) +def stepEmbedding (k : ℕ) : (StepCoeff k ⊕ Fin (labels k)) → Label + | .inl (.inl j) => .inl j.val + | .inl (.inr a) => .inr ⟨a.1.val,a.2⟩ + | .inr j => .inr ⟨k,j⟩ + +lemma stepEmbedding_injective (k : ℕ) : Function.Injective (stepEmbedding k) := by + rintro (a|a) (b|b) + · rcases a with a|⟨s,a⟩ <;> rcases b with b|⟨t,b⟩ + · simp only [stepEmbedding,Sum.inl.injEq,Fin.val_inj] + exact id + · simp [stepEmbedding] + · simp [stepEmbedding] + · intro h + have hst : s=t := Fin.ext (congrArg Sigma.fst (Sum.inr.inj h)) + subst t + have hab : a=b := eq_of_heq (Sigma.mk.inj (Sum.inr.inj h)).2 + subst b + rfl + · rcases a with a|⟨s,a⟩ + · simp [stepEmbedding] + · intro h + have := congrArg Sigma.fst (Sum.inr.inj h) + exact False.elim ((Nat.ne_of_lt s.isLt) this) + · rcases b with b|⟨t,b⟩ + · simp [stepEmbedding] + · intro h + have := congrArg Sigma.fst (Sum.inr.inj h) + exact False.elim ((Nat.ne_of_lt t.isLt) this.symm) + · intro h + exact congrArg Sum.inr (eq_of_heq (Sigma.mk.inj (Sum.inr.inj h)).2) + +lemma goodPath_step_range {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) (i : Fin r × Fin (time k)) : + (w i).1 ∈ Set.range (stepEmbedding k) := by + obtain ⟨a,ha⟩ := goodPath_label_in_range w hw i + rcases a with a|⟨s,a⟩ + · exact ⟨.inl (.inl a),ha⟩ + · by_cases hs : s.val < k + · exact ⟨.inl (.inr ⟨⟨s.val,hs⟩,a⟩),ha⟩ + · have hsk : s.val=k := by omega + refine ⟨.inr (Fin.cast (congrArg labels hsk) a),?_⟩ + change Sum.inr ⟨k,Fin.cast (congrArg labels hsk) a⟩=(w i).1 + rw [← ha] + apply congrArg Sum.inr + exact (Sigma.ext hsk (by apply (Fin.heq_ext_iff (congrArg labels hsk)).mpr; rfl)).symm + +lemma lift_pathValue (v : Label → unitary M) {r n : ℕ} + (w : Fin r × Fin n → Increment) (q : FreeGroup (Fin r)) : + FreeGroup.lift v (FreeGroup.lift + (fun i => word (fun j => incrementValue (w (i,j)))) q) = + FreeGroup.lift (pathValue v w) q := by + apply FreeGroup.lift_unique ((FreeGroup.lift v).comp (FreeGroup.lift _)) + intro i + simp only [MonoidHom.coe_comp,Function.comp_apply,FreeGroup.lift_apply_of, + word,map_list_prod,List.map_ofFn,pathValue] + congr 2 + funext j + cases h : (w (i,j)).2 <;> simp [incrementValue,signedValue,h] + +abbrev StageTest (k : ℕ) := (r : Fin (k+2)) × + {w : Fin r.val × Fin (time k) → Increment // w ∉ stageBad k r.val} × + {q : FreeGroup (Fin r.val) // q ≠ 1 ∧ q.toWord.length ≤ k+1} + +instance stageTestFintype (k : ℕ) : Fintype (StageTest k) := by + classical + letI (r : Fin (k+2)) : Fintype {w : Fin r.val × Fin (time k) → Increment // + w ∉ stageBad k r.val} := (goodPaths_finite k r.val).fintype + letI (r : Fin (k+2)) : Fintype {q : FreeGroup (Fin r.val) // + q ≠ 1 ∧ q.toWord.length ≤ k+1} := (boundedWords_finite r.val (k+1)).fintype + infer_instance + +def encodePath {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) (z : Fin r × Fin (time k)) : + (StepCoeff k ⊕ Fin (labels k)) × Bool := + ((goodPath_step_range w hw z).choose,(w z).2) + +lemma encodePath_decodes {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) (z : Fin r × Fin (time k)) : + stepEmbedding k (encodePath w hw z).1=(w z).1 := + (goodPath_step_range w hw z).choose_spec + +lemma encodePath_distinguished {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) : + ∃ (s : Fin r → Fin (time k)) (a : Fin r → Fin (labels k)), + (∀ i, (encodePath w hw (i,s i)).1=Sum.inr (a i)) ∧ + (∀ i z, (encodePath w hw z).1=Sum.inr (a i) → z=(i,s i)) := by + obtain ⟨s,a,ha,huniq,_⟩ := goodPath_distinguished w hw + refine ⟨s,a,fun i => ?_,fun i z hz => ?_⟩ + · apply stepEmbedding_injective k + rw [encodePath_decodes,ha] + rfl + · apply huniq i z + rw [← encodePath_decodes w hw z,hz] + rfl + +def stageCoeff (v : ℕ → unitary M) (a : ∀ k, Fin (labels k) → unitary M) + (k : ℕ) : StepCoeff k → unitary M := fun b => + assignedLabel v a (stepEmbedding k (Sum.inl b)) + +lemma updated_step (v : ℕ → unitary M) (a : ∀ k, Fin (labels k) → unitary M) + (k : ℕ) (u : Fin (labels k) → unitary M) (b : StepCoeff k ⊕ Fin (labels k)) : + assignedLabel v (Function.update a k u) (stepEmbedding k b)= + Sum.elim (stageCoeff v a k) u b := by + classical + rcases b with (b|⟨j,b⟩)|b + · rfl + · simp [assignedLabel,stepEmbedding,stageCoeff,Function.update_of_ne (Nat.ne_of_lt j.isLt)] + · simp [assignedLabel,stepEmbedding] + +lemma pathValue_updated (v : ℕ → unitary M) (a : ∀ k, Fin (labels k) → unitary M) + {k r : ℕ} (u : Fin (labels k) → unitary M) + (w : Fin r × Fin (time k) → Increment) (hw : w ∉ stageBad k r) : + pathValue (assignedLabel v (Function.update a k u)) w = + pathValue (Sum.elim (stageCoeff v a k) u) (encodePath w hw) := by + funext i + unfold pathValue + congr 1 + funext j + have hh := updated_step v a k u (encodePath w hw (i,j)).1 + rw [encodePath_decodes] at hh + unfold signedValue + change (if (w (i,j)).2 then _ else _)=(if (w (i,j)).2 then _ else _) + rw [hh] + +variable [PartialOrder M] + +def AtStage (τ : M →ₚ[ℂ] ℂ) (v : ℕ → unitary M) + (a : ∀ k, Fin (labels k) → unitary M) (k : ℕ) : Prop := + ∀ r, r ≤ k+1 → ∀ w : Fin r × Fin (time k) → Increment, w ∉ stageBad k r → + ∀ q : FreeGroup (Fin r), q ≠ 1 → q.toWord.length ≤ k+1 → + ‖τ (FreeGroup.lift (assignedLabel v a) (FreeGroup.lift + (fun i => word (fun j => incrementValue (w (i,j)))) q) : M)‖ < 1/(k+1:ℝ) + + + +theorem exists_stage_choice (τ : M →ₚ[ℂ] ℂ) (hf : FinitePathTests τ) + (v : ℕ → unitary M) (a : ∀ k, Fin (labels k) → unitary M) (k : ℕ) : + ∃ u : Fin (labels k) → unitary M, AtStage τ v (Function.update a k u) k := by + classical + obtain ⟨u,hu⟩ := hf (StepCoeff k) (Fin (labels k)) (StageTest k) + ⟨⟨0,labels_pos k⟩⟩ (stageCoeff v a k) (fun t => t.1.val) (fun _ => time k) + (fun t => encodePath t.2.1.val t.2.1.property) (fun t => t.2.2.val) + (fun t => t.2.2.property.1) + (fun t => encodePath_distinguished t.2.1.val t.2.1.property) + (1/(k+1:ℝ)) (by positivity) + refine ⟨u,fun r hr w hw q hq hqn => ?_⟩ + let t : StageTest k := ⟨⟨r,by omega⟩,⟨w,hw⟩,⟨q,hq,hqn⟩⟩ + have ht := hu t + change ‖τ (FreeGroup.lift (pathValue (Sum.elim (stageCoeff v a k) u) (encodePath w hw)) q : M)‖ < _ at ht + rw [lift_pathValue,pathValue_updated] + exact ht + +lemma atStage_congr (τ : M →ₚ[ℂ] ℂ) (v : ℕ → unitary M) + (a b : ∀ k, Fin (labels k) → unitary M) (k : ℕ) + (hab : ∀ j, j ≤ k → a j=b j) (ha : AtStage τ v a k) : AtStage τ v b k := by + intro r hr w hw q hq hqn + have hpath : pathValue (assignedLabel v a) w=pathValue (assignedLabel v b) w := by + funext i + unfold pathValue + congr 1 + funext j + have he : assignedLabel v a (w (i,j)).1=assignedLabel v b (w (i,j)).1 := by + obtain ⟨s,hs⟩ := goodPath_label_in_range w hw (i,j) + rw [← hs] + rcases s with s|⟨t,s⟩ + · rfl + · change a t.val s=b t.val s + rw [hab t.val (by omega)] + simp only [signedValue,he] + have hh := ha r hr w hw q hq hqn + rw [lift_pathValue,hpath,← lift_pathValue] at hh + exact hh + + + +def stageAssignments (τ : M →ₚ[ℂ] ℂ) (hf : FinitePathTests τ) + (v : ℕ → unitary M) : ℕ → (∀ k, Fin (labels k) → unitary M) + | 0 => fun _ _ => 1 + | k+1 => Function.update (stageAssignments τ hf v k) k + (exists_stage_choice τ hf v (stageAssignments τ hf v k) k).choose + +lemma stageAssignments_spec (τ : M →ₚ[ℂ] ℂ) (hf : FinitePathTests τ) + (v : ℕ → unitary M) (k : ℕ) : AtStage τ v (stageAssignments τ hf v (k+1)) k := + (exists_stage_choice τ hf v (stageAssignments τ hf v k) k).choose_spec + +lemma stageAssignments_stable (τ : M →ₚ[ℂ] ℂ) (hf : FinitePathTests τ) + (v : ℕ → unitary M) (j k : ℕ) (hjk : j+1 ≤ k) : + stageAssignments τ hf v k j=stageAssignments τ hf v (j+1) j := by + induction k, hjk using Nat.le_induction with + | base => rfl + | succ k hk ih => + rw [stageAssignments,Function.update_of_ne (by omega : j ≠ k),ih] + + + +theorem exists_label_of_finite_paths (τ : M →ₚ[ℂ] ℂ) (hf : FinitePathTests τ) + (v : ℕ → unitary M) : + ∃ label : Label → unitary M, (∀ j, label (Sum.inl j)=v j) ∧ + StageTests (fun g => ‖τ (FreeGroup.lift label g : M)‖) := by + let a : ∀ k, Fin (labels k) → unitary M := fun k => stageAssignments τ hf v (k+1) k + refine ⟨assignedLabel v a,fun _ => rfl,?_⟩ + change ∀ k, AtStage τ v a k + intro k + apply atStage_congr τ v (stageAssignments τ hf v (k+1)) a k + (fun j hj => stageAssignments_stable τ hf v j (k+1) (by omega)) + exact stageAssignments_spec τ hf v k + +end HochschildRare +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FinitePhases.lean b/lean/OAI/Analysis/BoundedHochschild/FinitePhases.lean new file mode 100644 index 0000000000000000000000000000000000000000..94d64d0f9909460795ec93fdda5c0707cc1ddf62 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FinitePhases.lean @@ -0,0 +1,242 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.RareScales + +namespace OAI + +/-! Finite additive characters, phase matrices and orthogonality. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +namespace HochschildFinitePhase +variable {I : Type*} [Fintype I] + +def character (v : I → ZMod 3) : AddChar (I → ZMod 3) ℂ where + toFun g := ZMod.stdAddChar (∑ i,v i*g i) + map_zero_eq_one' := by simp + map_add_eq_mul' g h := by + simp only [Pi.add_apply,mul_add,Finset.sum_add_distrib,AddChar.map_add_eq_mul] + +lemma character_apply (v g : I → ZMod 3) : + character v g=ZMod.stdAddChar (∑ i,v i*g i) := rfl + +lemma character_zero (g : I → ZMod 3) : character 0 g=1 := by simp [character_apply] +lemma character_add (v w g : I → ZMod 3) : + character (v+w) g=character v g*character w g := by + simp only [character_apply,Pi.add_apply,add_mul,Finset.sum_add_distrib,AddChar.map_add_eq_mul] +lemma character_norm (v g : I → ZMod 3) : ‖character v g‖=1 := by + simp only [character_apply,ZMod.stdAddChar_apply,Circle.norm_coe] +lemma character_star (v g : I → ZMod 3) : star (character v g)=character (-v) g := by + simp only [character_apply,Pi.neg_apply,neg_mul,Finset.sum_neg_distrib, + AddChar.map_neg_eq_inv,ZMod.stdAddChar_apply] + exact (Circle.coe_inv_eq_conj _).symm + +lemma character_eq_one_iff (v : I → ZMod 3) : character v=1 ↔ v=0 := by + classical + constructor + · intro h + ext i + have hh := congrArg (fun χ : AddChar (I → ZMod 3) ℂ => χ (Pi.single i 1)) h + simp only [character_apply,AddChar.one_apply] at hh + have hsum : (∑ j,v j*((Pi.single i (1:ZMod 3) : I → ZMod 3) j))=v i := by + simp [Pi.single_apply] + rw [hsum,← (ZMod.stdAddChar : AddChar (ZMod 3) ℂ).map_zero_eq_one] at hh + exact ZMod.injective_stdAddChar hh + · rintro rfl + ext g + exact character_zero g + +variable [DecidableEq I] + +lemma sum_character (v : I → ZMod 3) : + ∑ g,character v g=if v=0 then (Fintype.card (I → ZMod 3):ℂ) else 0 := by + classical + by_cases hv : v=0 + · subst v + simp only [character_zero,Finset.sum_const,Finset.card_univ,nsmul_eq_mul,mul_one,ite_true] + · rw [ite_eq_right hv] + exact AddChar.sum_eq_zero_of_ne_one ((character_eq_one_iff v).not.mpr hv) + +lemma orthogonality (v w : I → ZMod 3) : + ∑ g,star (character v g)*character w g= + if v=w then (Fintype.card (I → ZMod 3):ℂ) else 0 := by + classical + simp only [character_star,← character_add,sum_character] + congr 1 + exact propext neg_add_eq_zero + +lemma character_parseval {J H : Type*} [Fintype J] [SeminormedAddCommGroup H] + [InnerProductSpace ℂ H] (f : J → (I → ZMod 3)) (hf : Function.Injective f) (v : J → H) : + (∑ g : I → ZMod 3, ‖∑ j, character (f j) g • v j‖^2)= + (Fintype.card (I → ZMod 3):ℝ)*(∑ j,‖v j‖^2) := by + classical + have hh : (∑ g : I → ZMod 3, ⟪∑ j, character (f j) g • v j, + ∑ j,character (f j) g • v j⟫_ℂ)= + (Fintype.card (I → ZMod 3):ℂ)*(∑ j,⟪v j,v j⟫_ℂ) := by + simp only [sum_inner,inner_sum] + simp only [inner_smul_left,inner_smul_right] + calc + _ = ∑ j,∑ k,(∑ g,star (character (f k) g)*character (f j) g)*⟪v k,v j⟫_ℂ := by + rw [Finset.sum_comm] + apply Finset.sum_congr rfl + intro j hj + rw [Finset.sum_comm] + simp only [Finset.sum_mul] + apply Finset.sum_congr rfl + intro k hk + apply Finset.sum_congr rfl + intro g hg + simp only [Complex.star_def] + ring + _ = _ := by simp only [orthogonality,hf.eq_iff]; simp [← Finset.mul_sum] + have hr := congrArg Complex.re hh + simp only [Complex.re_sum,Complex.mul_re,Complex.natCast_re,Complex.natCast_im, + zero_mul,sub_zero] at hr + simpa only [@norm_sq_eq_re_inner ℂ, RCLike.re_to_complex] using hr + +end HochschildFinitePhase + + + + + +open scoped BigOperators ComplexConjugate InnerProductSpace +namespace HochschildFinitePhase +variable {I : Type*} [DecidableEq I] + +def frequency (i j : I) : I → ZMod 3 := Pi.single j 1 - Pi.single i 1 + +abbrev OffDiagonal (I : Type*) := {p : I × I // p.1 ≠ p.2} + +lemma frequency_ne_zero {i j : I} (hij : i ≠ j) : frequency i j ≠ 0 := by + intro h + have hh := congrFun h i + norm_num [frequency,Pi.single_apply,hij,Ne.symm hij] at hh + +lemma frequency_injective {i j k l : I} (hij : i ≠ j) (hkl : k ≠ l) + (h : frequency i j = frequency k l) : i=k ∧ j=l := by + have hik : i=k := by + by_contra hik + have hh := congrFun h i + by_cases hil : i=l + · subst l + norm_num [frequency,Pi.single_apply,hij,Ne.symm hij,hik,Ne.symm hik] at hh + exact (by decide : (-1 : ZMod 3) ≠ 1) hh + · norm_num [frequency,Pi.single_apply,hij,Ne.symm hij,hik,Ne.symm hik,hil,Ne.symm hil] at hh + subst k + refine ⟨rfl,?_⟩ + by_contra hjl + have hh := congrFun h j + norm_num [frequency,Pi.single_apply,hij,Ne.symm hij,hjl,Ne.symm hjl] at hh + +def extendedFrequency : Option (OffDiagonal I) → (I → ZMod 3) + | none => 0 + | some p => frequency p.val.1 p.val.2 + +lemma extendedFrequency_injective : Function.Injective (extendedFrequency (I:=I)) := by + intro a b h + cases a with + | none => + cases b with + | none => rfl + | some b => exact False.elim (frequency_ne_zero b.property h.symm) + | some a => + cases b with + | none => exact False.elim (frequency_ne_zero a.property h) + | some b => + have hab := frequency_injective a.property b.property h + congr 1 + exact Subtype.ext (Prod.ext hab.1 hab.2) + +def phase (g : I → ZMod 3) (i : I) : ℂ := ZMod.stdAddChar (g i) + +omit [DecidableEq I] in +lemma phase_norm (g : I → ZMod 3) (i : I) : ‖phase g i‖=1 := by + simp only [phase,ZMod.stdAddChar_apply,Circle.norm_coe] + +variable [Fintype I] + +lemma character_single (i : I) (g : I → ZMod 3) : character (Pi.single i 1) g=phase g i := by + simp [character_apply,Pi.single_apply,phase] + +lemma character_frequency (i j : I) (g : I → ZMod 3) : + character (frequency i j) g=star (phase g i)*phase g j := by + rw [frequency,sub_eq_add_neg,character_add,← character_star] + simp only [character_single] + exact mul_comm _ _ + +lemma offDiagonal_sum {A : Type*} [AddCommMonoid A] (f : I → I → A) : + (∑ p : OffDiagonal I, f p.val.1 p.val.2)=∑ i,∑ j,if i=j then 0 else f i j := by + classical + rw [← Fintype.sum_prod_type (f := fun p : I × I => if p.1=p.2 then (0:A) else f p.1 p.2)] + change (∑ p : {p : I × I // p.1 ≠ p.2}, f p.val.1 p.val.2)=_ + rw [← Finset.sum_subtype (Finset.univ.filter (fun p : I × I => p.1 ≠ p.2)) (by simp) + (fun p => f p.1 p.2),Finset.sum_filter] + apply Finset.sum_congr rfl + intro p hp + split_ifs <;> simp_all + +lemma phase_star_self (g : I → ZMod 3) (i : I) : star (phase g i)*phase g i=1 := by + rw [← character_single i g,character_star,← character_add,neg_add_cancel,character_zero] + +lemma extended_sum {A : Type*} [AddCommMonoid A] [Module ℂ A] (c : I → I → A) + (g : I → ZMod 3) : + (∑ p : Option (OffDiagonal I),character (extendedFrequency p) g • + (Option.rec (∑ i,c i i) (fun p : OffDiagonal I => c p.val.1 p.val.2) p))= + ∑ i,∑ j,(star (phase g i)*phase g j) • c i j := by + classical + rw [Fintype.sum_option] + simp only [extendedFrequency,character_zero,one_smul,character_frequency] + rw [offDiagonal_sum (fun i j => (star (phase g i)*phase g j) • c i j),← Finset.sum_add_distrib] + apply Finset.sum_congr rfl + intro i hi + have hd : c i i = ∑ j : I,if i=j then c i i else 0 := by simp + rw [hd,← Finset.sum_add_distrib] + apply Finset.sum_congr rfl + intro j hj + by_cases hij : i=j + · subst j + rw [ite_eq_left rfl,ite_eq_left rfl,add_zero,phase_star_self,one_smul] + · simp [hij] + +lemma phase_parseval {H : Type*} [SeminormedAddCommGroup H] [InnerProductSpace ℂ H] + (c : I → I → H) : + (∑ g : I → ZMod 3, ‖∑ i,∑ j,(star (phase g i)*phase g j) • c i j‖^2)= + (Fintype.card (I → ZMod 3):ℝ)* + (‖∑ i,c i i‖^2+∑ i,∑ j,if i=j then 0 else ‖c i j‖^2) := by + let v : Option (OffDiagonal I) → H := fun p => Option.rec (∑ i,c i i) + (fun p : OffDiagonal I => c p.val.1 p.val.2) p + calc + _ = ∑ g : I → ZMod 3,‖∑ p,character (extendedFrequency p) g • v p‖^2 := by + apply Finset.sum_congr rfl + intro g hg + congr 2 + exact (extended_sum c g).symm + _ = _ := by + rw [character_parseval extendedFrequency extendedFrequency_injective v] + simp only [v,Fintype.sum_option] + rw [offDiagonal_sum (fun i j => ‖c i j‖^2)] + +end HochschildFinitePhase +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FinitePositiveExtension.lean b/lean/OAI/Analysis/BoundedHochschild/FinitePositiveExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..504bf6e5ce804795465d6dd8cbb0f7d81329f377 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FinitePositiveExtension.lean @@ -0,0 +1,110 @@ +import OAI.Analysis.BoundedHochschild.OperatorSystemMatrices +import OAI.Analysis.BoundedHochschild.MatrixFunctionalDilation + +namespace OAI + +/-! The finite-dimensional operator-valued positive extension theorem. +Only positivity at the target matrix size is needed. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def operatorSystemSingle (S : Submodule ℂ A) {n : ℕ} (i j : Fin n) (a : S) : + operatorSystemMatrices S n := + ⟨singleCStarMatrix i j (a : A), fun p q => by + change (if i = p ∧ j = q then (a : A) else 0) ∈ S + split_ifs + · exact a.property + · exact S.zero_mem⟩ + +omit [PartialOrder A] [StarOrderedRing A] in +lemma operatorSystemSingle_amplification (S : Submodule ℂ A) {n : ℕ} + (φ : S →ₗ[ℂ] (EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n))) + (i j : Fin n) (a : S) : + operatorSystemAmplification S φ n (operatorSystemSingle S i j a) = + singleCStarMatrix i j (φ a) := by + apply CStarMatrix.ext + intro p q + by_cases h : i = p ∧ j = q + · rcases h with ⟨rfl, rfl⟩ + have he : (⟨(operatorSystemSingle S i j a).val i j, + (operatorSystemSingle S i j a).property i j⟩ : S) = a := + Subtype.ext (Matrix.single_apply_same i j (a : A)) + exact (congrArg φ he).trans (Matrix.single_apply_same i j (φ a)).symm + · have hz : (operatorSystemSingle S i j a).val p q = 0 := by + exact ite_eq_right (fun h' => (h h').elim) + have he : (⟨(operatorSystemSingle S i j a).val p q, + (operatorSystemSingle S i j a).property p q⟩ : S) = 0 := Subtype.ext hz + exact (congrArg φ he).trans ((map_zero φ).trans + (show singleCStarMatrix i j (φ a) p q = 0 from + ite_eq_right (fun h' => (h h').elim)).symm) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma operatorSystemMatrixFunctional_single (S : Submodule ℂ A) {n : ℕ} + (φ : S →ₗ[ℂ] (EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n))) + (i j : Fin n) (a : S) : + operatorSystemMatrixFunctional S φ (fun k => EuclideanSpace.single k 1) + (operatorSystemSingle S i j a) = + inner ℂ (EuclideanSpace.single i 1) (φ a (EuclideanSpace.single j 1)) := by + change operatorMatrixVectorFunctional (fun k => EuclideanSpace.single k 1) + (operatorSystemAmplification S φ n (operatorSystemSingle S i j a)) = _ + rw [operatorSystemSingle_amplification] + change (∑ p, ∑ q, inner ℂ (EuclideanSpace.single p 1) + ((if i = p ∧ j = q then φ a else 0) (EuclideanSpace.single q 1))) = _ + have he (p q : Fin n) : inner ℂ (EuclideanSpace.single p 1) + ((if i = p ∧ j = q then φ a else 0) (EuclideanSpace.single q 1)) = + if p = i ∧ q = j then + inner ℂ (EuclideanSpace.single i 1) (φ a (EuclideanSpace.single j 1)) else 0 := by + by_cases hp : p = i <;> by_cases hq : q = j + · subst p; subst q; simp + · simp [hp, hq, Ne.symm hq] + · simp [hp, Ne.symm hp] + · simp [hp, Ne.symm hp] + simp_rw [he] + simp [ite_and] + +lemma euclideanOperator_ext {n : ℕ} + (T U : EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n)) + (h : ∀ i j, inner ℂ (EuclideanSpace.single i 1) (T (EuclideanSpace.single j 1)) = + inner ℂ (EuclideanSpace.single i 1) (U (EuclideanSpace.single j 1))) : T = U := by + have he (j : Fin n) : T (EuclideanSpace.single j 1) = U (EuclideanSpace.single j 1) := by + apply PiLp.ext + intro i + have hh := h i j + simp only [EuclideanSpace.inner_single_left, map_one, one_mul] at hh + exact hh + apply ContinuousLinearMap.coe_injective + apply (PiLp.basisFun 2 ℂ (Fin n)).ext + intro j + rw [PiLp.basisFun_apply] + exact he j + +theorem exists_finite_completelyPositive_extension (S : Submodule ℂ A) + (h1 : (1 : A) ∈ S) (hstar : ∀ a ∈ S, star a ∈ S) {n : ℕ} (i₀ : Fin n) + (φ : S →ₗ[ℂ] (EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n))) + (hφ : ∀ X : operatorSystemMatrices S n, + 0 ≤ (X : CStarMatrix (Fin n) (Fin n) A) → + 0 ≤ operatorSystemAmplification S φ n X) : + ∃ Φ : CompletelyPositiveMap A + (EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n)), + ∀ a : S, Φ (a : A) = φ a := by + let ξ : Fin n → EuclideanSpace ℂ (Fin n) := fun i => EuclideanSpace.single i 1 + obtain ⟨F, hF⟩ := exists_positive_operatorSystem_extension + (operatorSystemMatrices S n) (operatorSystemMatrices_one S h1 n) + (operatorSystemMatrices_star S hstar n) (operatorSystemMatrixFunctional S φ ξ) + (operatorSystemMatrixFunctional_nonneg S φ ξ hφ) + refine ⟨matrixFunctionalCP F i₀, fun a => euclideanOperator_ext _ _ (fun i j => ?_)⟩ + rw [matrixFunctionalCP_coefficient] + exact (hF (operatorSystemSingle S i j a)).trans + (operatorSystemMatrixFunctional_single S φ i j a) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionAbsoluteContinuity.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionAbsoluteContinuity.lean new file mode 100644 index 0000000000000000000000000000000000000000..8e80b2b94c5c905f99c350d136fc1d211ba9e905 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionAbsoluteContinuity.lean @@ -0,0 +1,94 @@ +import OAI.Analysis.BoundedHochschild.OrthogonalProjectionTails + +namespace OAI + +/-! +# Absolute continuity of finite projection comparison + +The projection argument behind Ringrose, *Lectures on the trace in a finite +von Neumann algebra*, Lemma 5.2. Projections separately subequivalent to an +orthogonal sequence admit decreasing dominating projections with zero +weak-star limit. No tracial functional is used. +-/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- In a finite algebra, projections dominated in comparison by an orthogonal +sequence have weak-star-null decreasing projection envelopes. -/ +theorem finite_subequivalent_orthogonal_tails (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (p q : ℕ → M) + (hp : ∀ n, IsStarProjection (p n)) (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) + (hembed : ∀ n, ∃ v : PartialIso M, v.initial = p n ∧ v.final ≤ q n) : + ∃ R : ℕ → M, (∀ n, IsStarProjection (R n)) ∧ Antitone R ∧ + (∀ n, p n ≤ R n) ∧ PredualTendsto e R atTop 0 := by + classical + obtain ⟨T, hT, hTm, hTq, hTlim⟩ := exists_orthogonal_projection_tails e q hq horth + have hjoins (n : ℕ) : ∃ v : PartialIso M, v.final ≤ T n ∧ + (∀ i, p (n + i) ≤ v.initial) ∧ + ∀ r : M, IsStarProjection r → (∀ i, p (n + i) ≤ r) → v.initial ≤ r := by + apply countable_join_subequivalence e (hT n) + (finiteCorner_of_finiteAlgebra hfinite _ (hT n)) + (fun i => p (n + i)) (fun i => q (n + i)) + (fun i => hp (n + i)) (fun i => hq (n + i)) + · intro i j hij + exact horth _ _ (fun h => hij (Nat.add_left_cancel h)) + · intro i + exact hTq n (n + i) (Nat.le_add_right n i) + · intro i + exact hembed (n + i) + choose v hvf hvu hvl using hjoins + let R (n : ℕ) : M := (v n).initial + have hR (n : ℕ) : IsStarProjection (R n) := (v n).initial_proj + have hRm : Antitone R := antitone_nat_of_succ_le fun n => by + apply hvl (n + 1) (R n) (hR n) + intro i + simpa only [Nat.add_assoc, Nat.add_comm 1 i] using hvu n (i + 1) + obtain ⟨s, hs, hglb, hRlim⟩ := exists_decreasing_projection_limit e R hR hRm + have hsR (n : ℕ) : s ≤ (v n).initial := hglb.1 ⟨n, rfl⟩ + have hembedS (n : ℕ) : ∃ w : PartialIso M, w.initial = s ∧ w.final ≤ T n := by + let w := (v n).restrict hs (hsR n) + exact ⟨w, PartialIso.restrict_initial _ _ _, + (PartialIso.final_mono (PartialIso.restrict_le _ _ _)).trans (hvf n)⟩ + have hcomp (n : ℕ) : ∃ w : PartialIso M, w.initial = 1 - T n ∧ w.final ≤ 1 - s := by + obtain ⟨w, hwi, hwf⟩ := hembedS n + exact finite_complement_subequivalence e hfinite hs (hT n) w hwi hwf + have hcomplim : PredualTendsto e (fun n => 1 - T n) atTop 1 := by + simpa only [sub_zero] using predual_tendsto_sub e + (predual_tendsto_const e 1 atTop) hTlim + have hcomleast (r : M) (_hr : IsStarProjection r) + (hb : ∀ n, 1 - T n ≤ r) : (1 : M) ≤ r := by + apply HochschildSakai.le_of_bounded_predual_limit e 1 zero_le_one + (Eventually.of_forall fun n => (hT n).one_sub.norm_le _) ?_ hcomplim + exact Eventually.of_forall hb + obtain ⟨w, hwi, hwf⟩ := finite_subequivalence_at_supremum e hs.one_sub + (finiteCorner_of_finiteAlgebra hfinite _ hs.one_sub) (IsStarProjection.one M) + (fun n => 1 - T n) (fun i j hij => sub_le_sub_left (hTm hij) 1) hcomp + (fun n => (hT n).one_sub.le_one) hcomleast + have hwfull : w.final = 1 := hfinite (w : M) hwi + have hs0 : s = 0 := by + rw [hwfull] at hwf + exact sub_eq_self.mp (le_antisymm hs.one_sub.le_one hwf) + refine ⟨R, hR, hRm, ?_, ?_⟩ + · intro n + simpa only [Nat.add_zero] using hvu n 0 + · simpa only [hs0] using hRlim + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionEquivalence.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionEquivalence.lean new file mode 100644 index 0000000000000000000000000000000000000000..551203e7c28671f1889611513fc0af00f1a09c0b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionEquivalence.lean @@ -0,0 +1,154 @@ +import OAI.Analysis.BoundedHochschild.FiniteCentralDecomposition +import OAI.Analysis.BoundedHochschild.TraceFreeComparison + +namespace OAI + +/-! +# Unitary equivalence of finite projections + +In a finite von Neumann algebra a partial isometry extends to a unitary. +The proof uses trace-free central comparison of the complementary projections +and finiteness of central corners. No scalar trace is used. +-/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison FinitePathMain + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +def adjointPartialIso (v : PartialIso M) : PartialIso M := + ⟨star (v : M), by + simpa only [star_mul, star_star, mul_assoc] using congrArg star v.mul_star_mul⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma adjointPartialIso_initial (v : PartialIso M) : + (adjointPartialIso v).initial = v.final := by simp [adjointPartialIso, PartialIso.initial, PartialIso.final] + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma adjointPartialIso_final (v : PartialIso M) : + (adjointPartialIso v).final = v.initial := by simp [adjointPartialIso, PartialIso.initial, PartialIso.final] + +/-- Restrict a partial isometry to a central summand. -/ +def centralCutPartialIso (z : M) (hz : IsStarProjection z) + (hc : ∀ a : M, z * a = a * z) (v : PartialIso M) : PartialIso M where + val := z * (v : M) + mul_star_mul := by + have hstar : star (z * (v : M)) = z * star (v : M) := by + rw [star_mul, hz.isSelfAdjoint.star_eq, hc] + rw [hstar, central_idempotent_mul z hz.isIdempotentElem.eq hc, + central_idempotent_mul z hz.isIdempotentElem.eq hc, v.mul_star_mul] + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma centralCutPartialIso_initial (z : M) (hz : IsStarProjection z) + (hc : ∀ a : M, z * a = a * z) (v : PartialIso M) : + (centralCutPartialIso z hz hc v).initial = z * v.initial := by + change star (z * (v : M)) * (z * (v : M)) = z * (star (v : M) * v) + rw [star_mul, hz.isSelfAdjoint.star_eq, ← hc (star (v : M)), + central_idempotent_mul z hz.isIdempotentElem.eq hc] + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma centralCutPartialIso_final (z : M) (hz : IsStarProjection z) + (hc : ∀ a : M, z * a = a * z) (v : PartialIso M) : + (centralCutPartialIso z hz hc v).final = z * v.final := by + change (z * (v : M)) * star (z * (v : M)) = z * ((v : M) * star (v : M)) + rw [star_mul, hz.isSelfAdjoint.star_eq, ← hc (star (v : M)), + central_idempotent_mul z hz.isIdempotentElem.eq hc] + +omit [PartialOrder M] [StarOrderedRing M] in +/-- A central cut of a partial isometry exhausts its initial projection +exactly when it exhausts its final projection in a finite algebra. -/ +lemma finite_central_initial_iff_final (hfinite : FiniteAlgebra M) + (z : M) (hz : IsStarProjection z) (hc : ∀ a : M, z * a = a * z) + (v : PartialIso M) : z * v.initial = z ↔ z * v.final = z := by + have forward (w : PartialIso M) (hi : z * w.initial = z) : z * w.final = z := by + let a := centralCutPartialIso z hz hc w + have hL : z * (a : M) = a := by + change z * (z * (w : M)) = z * (w : M) + rw [← mul_assoc, hz.isIdempotentElem.eq] + have hR : (a : M) * z = a := by rw [← hc, hL] + have hin : star (a : M) * a = z := by + change a.initial = z + change (centralCutPartialIso z hz hc w).initial = z + rw [centralCutPartialIso_initial, hi] + have hout := finiteCorner_of_finiteAlgebra hfinite z hz (a : M) hL hR hin + change a.final = z at hout + simpa only [a, centralCutPartialIso_final] using hout + exact ⟨forward v, fun h => by simpa using forward (adjointPartialIso v) (by simpa using h)⟩ + +variable {X : Type*} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A partial isometry in a finite von Neumann algebra extends to a unitary. -/ +theorem finite_partialIso_extends_unitary (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (v : PartialIso M) : + ∃ u : unitary M, (u : M) * v.initial = v := by + classical + obtain ⟨z, w, hz, hwi, hwf, hzf, hzi⟩ := trace_free_central_comparison e + v.initial_proj.one_sub v.final_proj.one_sub + have hi : v.initial * w.initial = 0 := + HochschildTypeII.projection_orthogonal_of_le_complement v.initial_proj w.initial_proj hwi + have hf : v.final * w.final = 0 := + HochschildTypeII.projection_orthogonal_of_le_complement v.final_proj w.final_proj hwf + let t := v.orthogonalSum w hi hf + have hti : t.initial = v.initial + w.initial := PartialIso.orthogonalSum_initial v w hi hf + have htf : t.final = v.final + w.final := PartialIso.orthogonalSum_final v w hi hf + have hzc : ∀ a : M, z * a = a * z := fun a => (hz.2 a).eq + have hzc' : ∀ a : M, (1 - z) * a = a * (1 - z) := by + intro a + simp only [sub_mul, mul_sub, one_mul, mul_one, hzc] + have hzfinal : z * t.final = z := by + rw [htf, mul_add, hzf, mul_sub, mul_one] + abel + have hczinitial : (1 - z) * t.initial = 1 - z := by + rw [hti, mul_add, hzi, mul_sub, mul_one] + abel + have hzinitial := (finite_central_initial_iff_final hfinite z hz.1 hzc t).mpr hzfinal + have hczfinal := (finite_central_initial_iff_final hfinite (1 - z) hz.1.one_sub hzc' t).mp hczinitial + have hsplit (a : M) : z * a + (1 - z) * a = a := by noncomm_ring + have htinitial : t.initial = 1 := by + rw [← hsplit t.initial, hzinitial, hczinitial] + abel + have htfinal : t.final = 1 := by + rw [← hsplit t.final, hzfinal, hczfinal] + abel + let u : unitary M := ⟨(t : M), by + rw [Unitary.mem_iff] + exact ⟨htinitial, htfinal⟩⟩ + refine ⟨u, ?_⟩ + change ((v : M) + (w : M)) * v.initial = v + have hwv : (w : M) * v.initial = 0 := by + calc + (w : M) * v.initial = ((w : M) * w.initial) * v.initial := by rw [w.mul_initial] + _ = 0 := by + rw [mul_assoc] + have hzero : w.initial * v.initial = 0 := by + simpa only [star_mul, v.initial_proj.isSelfAdjoint.star_eq, + w.initial_proj.isSelfAdjoint.star_eq, star_zero] using congrArg star hi + rw [hzero, mul_zero] + rw [add_mul, v.mul_initial, hwv, add_zero] + +/-- Equivalent projections in a finite von Neumann algebra are unitarily conjugate. -/ +theorem finite_equivalent_unitarily_conjugate (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (v : PartialIso M) : + ∃ u : unitary M, (u : M) * v.initial * star (u : M) = v.final := by + obtain ⟨u, hu⟩ := finite_partialIso_extends_unitary e hfinite v + refine ⟨u, ?_⟩ + calc + (u : M) * v.initial * star (u : M) = + ((u : M) * v.initial) * star ((u : M) * v.initial) := by + rw [star_mul, v.initial_proj.isSelfAdjoint.star_eq] + simp only [mul_assoc] + rw [← mul_assoc v.initial v.initial, v.initial_proj.isIdempotentElem.eq] + _ = v.final := by rw [hu]; rfl + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionExtension.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..d002d053bef61c6c0b04d7337efb7fe88d02f443 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteProjectionExtension.lean @@ -0,0 +1,129 @@ +import OAI.Analysis.BoundedHochschild.FiniteProjectionEquivalence + +namespace OAI + +/-! +# Extension of embeddings in finite corners + +A partial embedding into a finite projection extends whenever an embedding +of the larger initial projection exists. This is the cancellation step used +in Ringrose, *Lectures on the trace in a finite von Neumann algebra*, Lemma 5.1. +The construction uses only the predual and finiteness, not a trace. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison HochschildCorners + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma partialIso_left_support {q : M} (hq : IsStarProjection q) + (v : PartialIso M) (hv : v.final ≤ q) : q * (v : M) = v := by + calc + q * (v : M) = q * (v.final * (v : M)) := by rw [v.final_mul] + _ = (v : M) := by + rw [← mul_assoc, (v.final_proj.le_iff_mul_eq_right hq).mp hv, v.final_mul] + +lemma partialIso_right_support {q : M} (hq : IsStarProjection q) + (v : PartialIso M) (hv : v.initial ≤ q) : (v : M) * q = v := by + calc + (v : M) * q = ((v : M) * v.initial) * q := by rw [v.mul_initial] + _ = (v : M) := by + rw [mul_assoc, (v.initial_proj.le_iff_mul_eq_left hq).mp hv, v.mul_initial] + +/-- The unitary extending a supported partial isometry can be chosen in the +same finite corner. Its ambient initial and final projections are that corner. -/ +theorem finite_partialIso_extends_in_corner (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {q : M} (hq : IsStarProjection q) (hfinite : FiniteCorner q) + (v : PartialIso M) (hi : v.initial ≤ q) (hf : v.final ≤ q) : + ∃ u : M, q * u = u ∧ u * q = u ∧ star u * u = q ∧ u * star u = q ∧ + u * v.initial = v := by + let vC : PartialIso (Corner q hq) := + ⟨⟨(v : M), partialIso_left_support hq v hf, partialIso_right_support hq v hi⟩, + Subtype.ext v.mul_star_mul⟩ + obtain ⟨u, hu⟩ := finite_partialIso_extends_unitary (cornerPredualEquiv q hq e) + ((finiteCorner_iff q hq).mp hfinite) vC + refine ⟨((u : Corner q hq) : M), (u : Corner q hq).property.1, + (u : Corner q hq).property.2, ?_, ?_, ?_⟩ + · exact congrArg Subtype.val ((Unitary.mem_iff.mp u.property).1) + · exact congrArg Subtype.val ((Unitary.mem_iff.mp u.property).2) + · exact congrArg Subtype.val hu + +/-- An embedding of a smaller projection into a finite corner extends to an +embedding of a larger projection as soon as the latter embeds in that corner. -/ +theorem finite_partialIso_extension (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {q : M} (hq : IsStarProjection q) (hfinite : FiniteCorner q) + (v w : PartialIso M) (hvw : v.initial ≤ w.initial) + (hvq : v.final ≤ q) (hwq : w.final ≤ q) : + ∃ t : PartialIso M, v ≤ t ∧ t.initial = w.initial ∧ t.final ≤ q := by + have hvp : (v : M) * w.initial = v := partialIso_right_support w.initial_proj v hvw + have hqw : q * (w : M) = w := partialIso_left_support hq w hwq + have hqv : q * (v : M) = v := partialIso_left_support hq v hvq + let a : PartialIso M := ⟨(v : M) * star (w : M), by + calc + ((v : M) * star (w : M)) * star ((v : M) * star (w : M)) * + ((v : M) * star (w : M)) = + ((v : M) * w.initial) * star (v : M) * (v : M) * star (w : M) := by + simp only [star_mul, star_star, PartialIso.initial, mul_assoc] + _ = (v : M) * star (w : M) := by rw [hvp, v.mul_star_mul]⟩ + have haf : a.final = v.final := by + change ((v : M) * star (w : M)) * star ((v : M) * star (w : M)) = v.final + simp only [star_mul, star_star] + calc + _ = ((v : M) * w.initial) * star (v : M) := by + simp only [PartialIso.initial, mul_assoc] + _ = v.final := by rw [hvp]; rfl + have hai : a.initial = (w : M) * v.initial * star (w : M) := by + simp only [a, PartialIso.initial, star_mul, star_star, mul_assoc] + have haiq : a.initial ≤ q := by + apply (a.initial_proj.le_iff_mul_eq_right hq).mpr + rw [hai, ← mul_assoc, ← mul_assoc, hqw] + obtain ⟨u, hqu, huq, huu, _, hua⟩ := finite_partialIso_extends_in_corner e hq + hfinite a haiq (by rw [haf]; exact hvq) + have huwi : u * (w : M) * v.initial = v := by + have h := congrArg (fun b : M => b * (w : M)) hua + rw [hai] at h + change u * ((w : M) * v.initial * star (w : M)) * (w : M) = + ((v : M) * star (w : M)) * (w : M) at h + have hiv : v.initial * w.initial = v.initial := + (v.initial_proj.le_iff_mul_eq_left w.initial_proj).mp hvw + calc + u * (w : M) * v.initial = + u * ((w : M) * v.initial * star (w : M)) * (w : M) := by + simp only [mul_assoc] + change u * ((w : M) * v.initial) = + u * ((w : M) * (v.initial * w.initial)) + rw [hiv] + _ = (v : M) := by + rw [h] + simpa only [PartialIso.initial, mul_assoc] using hvp + have hti : star (u * (w : M)) * (u * (w : M)) = w.initial := by + calc + _ = star (w : M) * (star u * u) * (w : M) := by + simp only [star_mul, mul_assoc] + _ = w.initial := by rw [huu, mul_assoc, hqw]; rfl + let t : PartialIso M := ⟨u * (w : M), by + rw [mul_assoc, hti] + change u * (w : M) * w.initial = u * (w : M) + rw [mul_assoc, w.mul_initial]⟩ + refine ⟨t, ⟨?_, huwi⟩, hti, ?_⟩ + · change v.initial ≤ star (u * (w : M)) * (u * (w : M)) + rw [hti] + exact hvw + · apply (t.final_proj.le_iff_mul_eq_right hq).mpr + change q * ((u * (w : M)) * star (u * (w : M))) = _ + rw [← mul_assoc, ← mul_assoc, hqu] + rfl + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteRightAveraging.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteRightAveraging.lean new file mode 100644 index 0000000000000000000000000000000000000000..a922ebaa10d695692fd19b5eac3c91d3d91acd38 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteRightAveraging.lean @@ -0,0 +1,113 @@ +import OAI.Analysis.BoundedHochschild.ColumnRowEstimates + +namespace OAI + +/-! +# Elementary right averages of bounded linear maps + +These are the finite averages used in the completely bounded module-map +projection. The norm estimate only uses the precise finite-row inequality. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +/-- A finite-row bound, expressed in the C*-algebra without an auxiliary +operator-space structure. -/ +def HasFiniteRowBound (T : M →L[ℂ] M) (C : ℝ) : Prop := + 0 ≤ C ∧ ∀ (n : ℕ) (x : Fin n → M), + ‖∑ i, T (x i) * star (T (x i))‖ ≤ C ^ 2 * ‖∑ i, x i * star (x i)‖ + +variable {I : Type*} [Fintype I] + +/-- The elementary average `x ↦ ∑ T(x mᵢ) mᵢ*`. -/ +def finiteRightAverage (m : I → M) (T : M →L[ℂ] M) : M →L[ℂ] M := + ∑ i, ((ContinuousLinearMap.mul ℂ M).flip (star (m i))).comp + (T.comp ((ContinuousLinearMap.mul ℂ M).flip (m i))) + +@[simp] lemma finiteRightAverage_apply (m : I → M) (T : M →L[ℂ] M) (a : M) : + finiteRightAverage m T a = ∑ i, T (a * m i) * star (m i) := by + simp only [finiteRightAverage, sum_apply, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.mul_apply', ContinuousLinearMap.flip_apply] + +lemma finiteRightAverage_add (m : I → M) (S T : M →L[ℂ] M) : + finiteRightAverage m (S + T) = finiteRightAverage m S + finiteRightAverage m T := by + ext a + simp only [finiteRightAverage_apply, add_apply, add_mul, Finset.sum_add_distrib] + +lemma finiteRightAverage_smul (m : I → M) (z : ℂ) (T : M →L[ℂ] M) : + finiteRightAverage m (z • T) = z • finiteRightAverage m T := by + ext a + simp only [finiteRightAverage_apply, smul_apply, smul_mul_assoc, + Finset.smul_sum] + +lemma finiteRightAverage_leftOutput (m : I → M) (b : M) (T : M →L[ℂ] M) : + finiteRightAverage m ((ContinuousLinearMap.mul ℂ M b).comp T) = + (ContinuousLinearMap.mul ℂ M b).comp (finiteRightAverage m T) := by + ext a + simp only [finiteRightAverage_apply, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.mul_apply', Finset.mul_sum, mul_assoc] + +lemma finiteRightAverage_precompose_left (m : I → M) (b : M) (T : M →L[ℂ] M) : + finiteRightAverage m (T.comp (ContinuousLinearMap.mul ℂ M b)) = + (finiteRightAverage m T).comp (ContinuousLinearMap.mul ℂ M b) := by + ext a + simp only [finiteRightAverage_apply, ContinuousLinearMap.comp_apply, + ContinuousLinearMap.mul_apply', mul_assoc] + +lemma finiteRightAverage_mul_left (m : I → M) (hm : ∑ i, m i * star (m i) = 1) (b : M) : + finiteRightAverage m (ContinuousLinearMap.mul ℂ M b) = ContinuousLinearMap.mul ℂ M b := by + ext a + simp only [finiteRightAverage_apply, ContinuousLinearMap.mul_apply'] + calc + _ = b * a * (∑ i, m i * star (m i)) := by + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + simp only [mul_assoc] + _ = b * a := by rw [hm, mul_one] + +variable {n : ℕ} + +/-- Finite normalized right averages satisfy the row norm bound. -/ +theorem finiteRightAverage_norm_of_rowBound + (c : Fin n → HochschildComparison.PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (m : Fin n → M) (hm : ∑ i, m i * star (m i) = 1) + (T : M →L[ℂ] M) {C : ℝ} (hT : HasFiniteRowBound T C) : + ‖finiteRightAverage m T‖ ≤ C := by + by_cases hM : Nontrivial M + · let := hM + apply ContinuousLinearMap.opNorm_le_bound _ hT.1 + intro a + have hin : (∑ i, (a * m i) * star (a * m i)) = a * star a := by + calc + _ = a * (∑ i, m i * star (m i)) * star a := by + simp only [Finset.mul_sum, Finset.sum_mul, star_mul, mul_assoc] + _ = a * star a := by rw [hm, mul_one] + have hs : ‖finiteRightAverage m T a‖ ^ 2 ≤ C ^ 2 * ‖a‖ ^ 2 := by + rw [finiteRightAverage_apply] + calc + _ ≤ ‖∑ i, T (a * m i) * star (T (a * m i))‖ * + ‖∑ i, star (star (m i)) * star (m i)‖ := + finite_row_column_estimate c hi ho (fun i => T (a * m i)) (fun i => star (m i)) + _ = ‖∑ i, T (a * m i) * star (T (a * m i))‖ := by + simp only [star_star, hm, norm_one, mul_one] + _ ≤ C ^ 2 * ‖∑ i, (a * m i) * star (a * m i)‖ := hT.2 n (fun i => a * m i) + _ = C ^ 2 * ‖a‖ ^ 2 := by simp only [hin, CStarRing.norm_self_mul_star, sq] + have hnonneg : 0 ≤ C * ‖a‖ := mul_nonneg hT.1 (norm_nonneg a) + nlinarith [norm_nonneg (finiteRightAverage m T a)] + · let : Subsingleton M := not_nontrivial_iff_subsingleton.mp hM + have hz : finiteRightAverage m T = 0 := Subsingleton.elim _ _ + rw [hz, norm_zero] + exact hT.1 + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteTraceCover.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteTraceCover.lean new file mode 100644 index 0000000000000000000000000000000000000000..948e141fc6da7810759913d2aaa6bbb567b9d95b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteTraceCover.lean @@ -0,0 +1,198 @@ +import OAI.Analysis.BoundedHochschild.NormalOperators +import OAI.Analysis.BoundedHochschild.PrimitiveAverages +import OAI.Analysis.BoundedHochschild.CentralProjectionSuprema + +namespace OAI + +/-! +# Normal positive functionals for the finite trace cover + +Every nonzero projection in an abstract von Neumann algebra is detected by +a normal positive state supported on that projection. This constructs the +normal positive functionals needed for a later trace cover; it does not +assume or assert that finiteness alone supplies a trace. +-/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u v + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {H : Type v} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +/-- A vector state before normalizing its vector. -/ +def vectorPositiveFunctional (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (ξ : H) : M →ₚ[ℂ] ℂ where + toLinearMap := (coefficient π ξ ξ).toLinearMap + monotone' := by + change Monotone (coefficient π ξ ξ) + apply (monotone_iff_map_nonneg _).mpr + intro a ha + exact (ContinuousLinearMap.nonneg_iff_isPositive.mp (map_nonneg π ha)).inner_nonneg_right ξ + +@[simp] lemma vectorPositiveFunctional_apply (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (ξ : H) (a : M) : vectorPositiveFunctional π ξ a = inner ℂ ξ (π a ξ) := rfl + +omit [CompleteSpace X] in +lemma vectorPositiveFunctional_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) {ξ : H} (hξ : ξ ∈ normalVectors e π) : + TraceInPredual e (vectorPositiveFunctional π ξ) := by + exact (mem_normalDual e _).mp ((mem_normalVectors e π ξ).mp hξ ξ) + +/-- Every nonzero projection supports a normal positive state. -/ +theorem exists_normal_state_on_projection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) : + ∃ ψ : M →ₚ[ℂ] ℂ, TraceInPredual e ψ ∧ ψ 1 = 1 ∧ ψ p = 1 ∧ + ∀ a : M, ψ (p * a * p) = ψ a := by + classical + have hex : ∃ z : X, e.symm p z ≠ 0 := by + by_contra hn + push Not at hn + apply hp0 + apply e.symm.injective + ext z + simpa only [map_zero, zero_apply] using hn z + obtain ⟨z, hz⟩ := hex + let φ := predualEmbedding e z + let m := functionalModel φ + let π := m.representation + let η := m.leftVector + let ξ := normalProjection e π m.rightVector + have hφ : φ ∈ normalDual e := ⟨z, rfl⟩ + have hreal : coefficient π η ξ = φ := by + exact (normalProjection_fixes_normal e π η m.rightVector + (m.realizes.symm ▸ hφ)).trans m.realizes + have hξ : ξ ∈ normalVectors e π := by simp [ξ, normalProjection] + let ζ := π p ξ + have hζ : ζ ∈ normalVectors e π := normalVectors_mul e π hξ p + have hζ0 : ζ ≠ 0 := by + intro hzero + have he := congrArg (fun f : StrongDual ℂ M => f p) hreal + have hφp : φ p ≠ 0 := by simpa only [φ, predualEmbedding_apply, star_ne_zero] using hz + apply hφp + change inner ℂ η ζ = φ p at he + rw [hzero, inner_zero_right] at he + exact he.symm + have hfix : π p ζ = ζ := by + change π p (π p ξ) = π p ξ + rw [← mul_apply_eq_comp, ← map_mul, hp.isIdempotentElem.eq] + let w := (‖ζ‖⁻¹ : ℂ) • ζ + have hwn : ‖w‖ = 1 := norm_smul_inv_norm hζ0 + have hw : w ∈ normalVectors e π := (normalVectors e π).smul_mem _ hζ + have hwfix : π p w = w := by simp only [w, map_smul, hfix] + let ψ := vectorPositiveFunctional π w + have hψ1 : ψ 1 = 1 := by + simp only [ψ, vectorPositiveFunctional_apply, map_one, one_apply_eq_self, + inner_self_eq_norm_sq_to_K, hwn] + norm_num + refine ⟨ψ, vectorPositiveFunctional_normal e π hw, hψ1, ?_, ?_⟩ + · simpa only [ψ, vectorPositiveFunctional_apply, hwfix, map_one, one_apply_eq_self] + using hψ1 + · intro a + change inner ℂ w (π (p * a * p) w) = inner ℂ w (π a w) + rw [map_mul, map_mul] + change inner ℂ w (π p (π a (π p w))) = inner ℂ w (π a w) + rw [hwfix, ← ContinuousLinearMap.adjoint_inner_left] + rw [← ContinuousLinearMap.star_eq_adjoint, ← map_star, hp.isSelfAdjoint.star_eq, hwfix] + +lemma normal_functional_central_null_chain (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (S : Set M) (hne : S.Nonempty) (hchain : IsChain (· ≤ ·) S) + (hS : ∀ q ∈ S, IsStarProjection q ∧ (∀ a : M, q * a = a * q) ∧ ψ q = 0) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ ψ p = 0 ∧ + ∀ q ∈ S, q ≤ p := by + obtain ⟨p, hp, hc, hu, _, _, U, _, ht⟩ := + exists_central_projection_chain_supremum_with_limit e S hne hchain + (fun q hq => (hS q hq).1) (fun q hq => (hS q hq).2.1) + refine ⟨p, hp, hc, ?_, hu⟩ + have heq : (fun q : S => ψ (q : M)) = (fun _ : S => (0 : ℂ)) := + funext fun q => (hS q q.property).2.2 + have hl := trace_predual_tendsto e ψ hψ ht + rw [heq] at hl + exact tendsto_nhds_unique hl tendsto_const_nhds + +/-- A normal positive functional is faithful on central projections within its +central support. This is not a traciality assertion. -/ +theorem exists_normal_positive_central_support (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ ψ p = ψ 1 ∧ + ∀ q : M, IsStarProjection q → (∀ a : M, q * a = a * q) → + q ≤ p → ψ q = 0 → q = 0 := by + classical + let S : Set M := {q | IsStarProjection q ∧ (∀ a : M, q * a = a * q) ∧ ψ q = 0} + have hz : (0 : M) ∈ S := ⟨IsStarProjection.zero M, fun a => by simp, map_zero ψ⟩ + obtain ⟨r, _, hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain a ha => by + obtain ⟨s, hs, hcs, hψs, hu⟩ := normal_functional_central_null_chain e ψ hψ + c ⟨a, ha⟩ hchain (fun q hq => hc hq) + exact ⟨s, ⟨hs, hcs, hψs⟩, hu⟩) 0 hz + have hr := hmax.1.1 + have hrc := hmax.1.2.1 + have hψr := hmax.1.2.2 + refine ⟨1 - r, hr.one_sub, ?_, ?_, ?_⟩ + · intro a + simp only [sub_mul, mul_sub, one_mul, mul_one, hrc] + · rw [map_sub, hψr, sub_zero] + · intro q hq hqc hqr hψq + have hrq : r * q = 0 := by + have h := (hq.le_iff_mul_eq_right hr.one_sub).mp hqr + rw [sub_mul, one_mul] at h + exact sub_eq_self.mp h + have hs : r + q ∈ S := ⟨hr.add hq hrq, + fun a => by rw [add_mul, mul_add, hrc, hqc], by rw [map_add, hψr, hψq, add_zero]⟩ + have hle : r ≤ r + q := le_add_of_nonneg_right hq.nonneg + have he : r + q = r := le_antisymm (hmax.2 hs hle) hle + exact add_eq_left.mp he + +/-- A normal state detecting all nonzero central subprojections of `p`. -/ +def HasCentralFaithfulNormalState (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (p : M) : Prop := + ∃ ψ : M →ₚ[ℂ] ℂ, TraceInPredual e ψ ∧ ψ 1 = 1 ∧ ψ p = 1 ∧ + ∀ q : M, IsStarProjection q → (∀ a : M, q * a = a * q) → + q ≤ p → ψ q = 0 → q = 0 + +/-- Every nonzero central projection contains a nonzero central subprojection +on which some normal state is faithful on the center. -/ +theorem exists_central_normal_state_subprojection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {q : M} (hq : IsStarProjection q) (hqc : ∀ a : M, q * a = a * q) (hq0 : q ≠ 0) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ + p ≤ q ∧ p ≠ 0 ∧ HasCentralFaithfulNormalState e p := by + obtain ⟨ψ, hψ, hψ1, _, hsupport⟩ := exists_normal_state_on_projection e hq hq0 + obtain ⟨p, hp, hpc, hψp, hfaith⟩ := exists_normal_positive_central_support e ψ hψ + have hψp1 : ψ p = 1 := hψp.trans hψ1 + have hcut : IsStarProjection (p * (1 - q)) := hp.mul hq.one_sub + (show Commute p (1 - q) from hpc (1 - q)) + have hcutc : ∀ a : M, (p * (1 - q)) * a = a * (p * (1 - q)) := by + intro a + have hqc' : Commute (1 - q) a := (Commute.one_left a).sub_left (hqc a) + exact ((show Commute p a from hpc a).mul_left hqc').eq + have hcutle : p * (1 - q) ≤ p := (hcut.le_iff_mul_eq_right hp).mpr + (by rw [← mul_assoc, hp.isIdempotentElem.eq]) + have hcutzero : ψ (p * (1 - q)) = 0 := by + have h := hsupport (p * (1 - q)) + have hzero : q * (p * (1 - q)) = 0 := by + rw [← mul_assoc, hqc p, mul_assoc, mul_sub, mul_one, + hq.isIdempotentElem.eq, sub_self, mul_zero] + rw [hzero, zero_mul, map_zero] at h + exact h.symm + have hpq : p ≤ q := by + have hzero := hfaith (p * (1 - q)) hcut hcutc hcutle hcutzero + rw [mul_sub, mul_one] at hzero + exact (hp.le_iff_mul_eq_left hq).mpr (sub_eq_zero.mp hzero).symm + have hp0 : p ≠ 0 := by + intro hzero + have h01 : (0 : ℂ) = 1 := by simpa only [hzero, map_zero] using hψp1 + exact zero_ne_one h01 + exact ⟨p, hp, hpc, hpq, hp0, ψ, hψ, hψ1, hψp1, hfaith⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteTracialDecomposition.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteTracialDecomposition.lean new file mode 100644 index 0000000000000000000000000000000000000000..ad2c4686362e255ed2fea9d15bdbf616a740498b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteTracialDecomposition.lean @@ -0,0 +1,78 @@ +import OAI.Analysis.BoundedHochschild.NormalTraceFaithfulness +import OAI.Analysis.BoundedHochschild.CenterAveragingReduction + +namespace OAI + +/-! +# Unconditional scalar traces on finite central pieces + +Trace-free normal states, orbit compactness, and the isometric fixed-point +argument discharge the local tracial-cut input to central decomposition. +-/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A center-faithful normal state on a finite von Neumann algebra gives an +actual faithful normal tracial state. -/ +theorem faithful_normal_trace_of_center_state (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (hψ1 : ψ 1 = 1) + (hfaith : ∀ p : M, IsStarProjection p → (∀ a : M, p * a = a * p) → ψ p = 0 → p = 0) : + ∃ τ : M →ₚ[ℂ] ℂ, TraceInPredual e τ ∧ τ 1 = 1 ∧ + (∀ a b : M, τ (a * b) = τ (b * a)) ∧ + ∀ a : M, τ (star a * a) = 0 → a = 0 := by + obtain ⟨τ, hτ, hτ1, htr, hc⟩ := exists_normal_tracial_average e hfinite ψ hψ + refine ⟨τ, hτ, hτ1.trans hψ1, htr, ?_⟩ + apply normal_trace_faithful_of_center e τ hτ htr + intro p hp hpc hτp + apply hfaith p hp hpc + rwa [hc p hpc] at hτp + +/-- The local scalar-trace input is now a theorem, with no averaging input. -/ +theorem localTracialCutInput (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + LocalTracialCutInput M := by + intro z hz hzc hzfinite hzII hz0 + obtain ⟨p, hp, hpc, hpz, hp0, hstate⟩ := + exists_central_normal_state_subprojection e hz hzc hz0 + have hpfinite : FiniteAlgebra (Corner p hp) := + (finiteCorner_iff p hp).mp + (finiteCorner_mono hp hz hpz ((finiteCorner_iff z hz).mpr hzfinite)) + have hpII : PopaTypeII.NoTypeICentralPart (Corner p hp) := + noTypeICentralPart_smaller_centralCorner hp hz hpz hpc hzII + obtain ⟨ψ, hψ, hψ1, hfaith⟩ := central_faithful_state_on_corner e hp hpc hstate + let eP := cornerPredualEquiv p hp e + obtain ⟨τ, hτ, hτ1, htr, hfaithτ⟩ := + faithful_normal_trace_of_center_state eP hpfinite ψ hψ hψ1 hfaith + exact ⟨p, hp, hpc, hpz, hp0, CornerPredual p hp e, + inferInstance, inferInstance, inferInstance, eP, τ, hτ, htr, hfaithτ, hτ1, hpII⟩ + +/-- The central decomposition needed by the main theorem is unconditional. -/ +theorem centralDecompositionInput (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + CentralDecompositionInput M := + centralDecompositionInput_of_local_tracial_cuts e (localTracialCutInput e) + +/-- Only the classical non-type-II₁ vanishing input remains here. -/ +theorem primitive_of_classical_vanishing (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hclassical : ClassicalVanishingInput.{u}) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x, differentialValue g x = f x := + primitive_of_published_inputs e (centralDecompositionInput e) hclassical f hf + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIPieces.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIPieces.lean new file mode 100644 index 0000000000000000000000000000000000000000..a9f280d86300ba4f6b31e76016f97ae611c1788a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIPieces.lean @@ -0,0 +1,66 @@ +import OAI.Analysis.BoundedHochschild.HomogeneousCornerTransport +import OAI.Analysis.BoundedHochschild.FiniteTracialDecomposition + +namespace OAI + +/-! Existence of finite homogeneous central pieces in finite type I algebras. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners FinitePathMain + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem exists_homogeneous_piece_of_abelian_trace + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a * b) = τ (b * a)) + (hfaith : ∀ a : M, τ (star a * a) = 0 → a = 0) + {p : M} (hp : AbelianProjection p) (hp0 : p ≠ 0) : + ∃ z : M, CentralProjection z ∧ z ≠ 0 ∧ HomogeneousTypeICorner z := by + obtain ⟨c, hc⟩ := exists_central_support e hp.1 + have hc0 : c ≠ 0 := fun h => hp0 ((hc.eq_zero_iff hp.1).mpr h) + let eC := cornerPredualEquiv c hc.1.1 e + let τC := cornerTrace c hc.1.1 τ + have hpC := projectionInCorner_abelian hc.1.1 hp hc.2.1 + have hpC0 : projectionInCorner hc.1.1 hp.1 hc.2.1 ≠ 0 := + fun h => hp0 (congrArg Subtype.val h) + obtain ⟨q, hq, hq0, hhom⟩ := exists_homogeneous_piece_of_full_abelian_trace eC τC + (cornerTrace_tracial c hc.1.1 τ htr) (cornerTrace_faithful c hc.1.1 τ hfaith hc0) + hpC hpC0 (centralSupport_in_corner hc.1.1 (fun a => (hc.1.2 a).eq) hp.1 hc) + exact ⟨(q : M), ⟨corner_projection_coe c hc.1.1 hq.1, + fun a => centralCorner_central hc.1.1 (fun a => (hc.1.2 a).eq) q + (fun b => (hq.2 b).eq) a⟩, + (fun h => hq0 (Subtype.ext h)), homogeneousCorner_to_ambient hc.1.1 q hhom⟩ + +theorem finite_typeI_homogeneous_subprojection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (hI : TypeICentralSummand (1 : M)) + {z : M} (hz : IsStarProjection z) (hzc : ∀ a : M, z * a = a * z) (hz0 : z ≠ 0) : + ∃ q : M, CentralProjection q ∧ q ≤ z ∧ q ≠ 0 ∧ HomogeneousTypeICorner q := by + obtain ⟨c, hc, hcc, hcz, hc0, hstate⟩ := + exists_central_normal_state_subprojection e hz hzc hz0 + obtain ⟨p, hp, hpc, hp0⟩ := hI.2 c ⟨hc, fun a => hcc a⟩ hc.le_one hc0 + let eC := cornerPredualEquiv c hc e + have hfinC : FiniteAlgebra (Corner c hc) := + (finiteCorner_iff c hc).mp (finiteCorner_of_finiteAlgebra hfinite c hc) + obtain ⟨ψ, hψ, hψ1, hfaithψ⟩ := central_faithful_state_on_corner e hc hcc hstate + obtain ⟨τ, _hτ, _hτ1, htr, hfaith⟩ := + faithful_normal_trace_of_center_state eC hfinC ψ hψ hψ1 hfaithψ + have hpC := projectionInCorner_abelian hc hp hpc + have hpC0 : projectionInCorner hc hp.1 hpc ≠ 0 := fun h => hp0 (congrArg Subtype.val h) + obtain ⟨q, hq, hq0, hhom⟩ := exists_homogeneous_piece_of_abelian_trace eC τ htr hfaith hpC hpC0 + refine ⟨(q : M), ⟨corner_projection_coe c hc hq.1, + fun a => centralCorner_central hc hcc q (fun b => (hq.2 b).eq) a⟩, + (corner_projection_le c hc hq.1).trans hcz, + (fun h => hq0 (Subtype.ext h)), homogeneousCorner_to_ambient hc q hhom⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIVanishing.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIVanishing.lean new file mode 100644 index 0000000000000000000000000000000000000000..1ea31b4c4e518c758910ddb47a66612dcfc34324 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteTypeIVanishing.lean @@ -0,0 +1,84 @@ +import OAI.Analysis.BoundedHochschild.FiniteTypeIPieces + +namespace OAI + +/-! Unconditional bounded Hochschild vanishing on finite type I algebras. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open FinitePathMain HochschildCorners + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem finite_typeI_central_partition (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (hI : TypeICentralSummand (1 : M)) : + ∃ D : MaximalCentralPartition M HomogeneousTypeICorner, D.complement = 0 := by + obtain ⟨D⟩ := exists_maximal_central_partition e HomogeneousTypeICorner + refine ⟨D, ?_⟩ + by_contra h0 + obtain ⟨q, hq, hqle, hq0, hhom⟩ := finite_typeI_homogeneous_subprojection e hfinite hI + D.complement_isProjection D.complement_central h0 + exact hq0 (D.maximal q hq.1 (fun a => (hq.2 a).eq) hqle hhom) + +/-- Finite type I algebras have bounded primitives in every positive degree. +The bound is independent of the ranks of their homogeneous central pieces. -/ +theorem finite_typeI_primitive (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (hI : TypeICentralSummand (1 : M)) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ + n * ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + classical + obtain ⟨D, hD⟩ := finite_typeI_central_partition e hfinite hI + have htotal (a : M) (ha : ∀ i, D.projection i * a = 0) : a = 0 := + D.total a (by rw [hD, zero_mul]) ha + have hpieces (i : D.Index) : + ∃ b : Cochain (Corner (D.projection i) (D.isProjection i)) n, + ‖b‖ ≤ ‖f‖ ∧ ∀ x, differentialValue b x = + CentralCorner.restrict (D.projection i) (D.isProjection i) (D.central i) f x := by + obtain ⟨hp, d, E, j, hab⟩ := D.property i + obtain ⟨b, hbn, hb⟩ := finite_homogeneous_typeI_primitive_of_abelian_diagonal + (cornerPredualEquiv (D.projection i) (D.isProjection i) e) E j hab + (CentralCorner.restrict (D.projection i) (D.isProjection i) (D.central i) f) + (CentralCorner.restrict_cocycle _ _ _ f hf) + exact ⟨b, hbn.trans (CentralCorner.restrict_norm _ _ _ f), hb⟩ + choose b hbn hb using hpieces + exact primitive_of_central_cut_primitives e (HochschildSakai.mul_hasPreadjoint e) + D.projection D.isProjection D.central D.orthogonal htotal f hf + (fun i => CentralCorner.extend (D.projection i) (D.isProjection i) (D.central i) (b i)) + (fun i => CentralCorner.extend_supported _ _ _ _) + (fun i => CentralCorner.extend_primitive _ _ _ f (b i) (hb i)) + ‖f‖ (norm_nonneg f) (fun i => (CentralCorner.extend_norm _ _ _ _).trans (hbn i)) + +/-- In a finite algebra the absence of a type II₁ central summand forces type I. -/ +theorem finite_typeI_of_noTypeII1 (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (hno : NoTypeII1Summand M) : + TypeICentralSummand (1 : M) := by + obtain ⟨p, hp, hc, hI, _, hII⟩ := exists_typeI_central_cut e + have hcc (a : M) : (1 - p) * a = a * (1 - p) := by + simp only [sub_mul, mul_sub, one_mul, mul_one, hc] + have hfinC : FiniteAlgebra (Corner (1 - p) hp.one_sub) := + (finiteCorner_iff (1 - p) hp.one_sub).mp + (finiteCorner_of_finiteAlgebra hfinite (1 - p) hp.one_sub) + have hcomp := hno (1 - p) hp.one_sub hcc hfinC hII + have hp1 : p = 1 := (sub_eq_zero.mp hcomp).symm + simpa only [hp1] using hI + +/-- The entire finite case of the classical non-II₁ vanishing input. -/ +theorem finite_noTypeII1_primitive (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (hno : NoTypeII1Summand M) + {n : ℕ} (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ‖g‖ ≤ ‖f‖ + (n + 1) * ‖f‖ ∧ + ∀ x, differentialValue g x = f x := by + simpa only [Nat.cast_add, Nat.cast_one] using + finite_typeI_primitive e hfinite (finite_typeI_of_noTypeII1 e hfinite hno) f hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FiniteUnitaryPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/FiniteUnitaryPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..1c780728493fa743e63de09586faff87fa792613 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FiniteUnitaryPrimitives.lean @@ -0,0 +1,198 @@ +import OAI.Analysis.BoundedHochschild.AbelianPrimitives + +namespace OAI + +/-! +# Finite unitary averaging for type I pieces + +The separability homotopy of a finite group of unitaries has norm at most one. +It is exact in the first variable on the linear span of the group. This is the +finite-dimensional ingredient of the classical type I vanishing argument. +-/ + +noncomputable section + +open scoped BigOperators + +namespace BoundedHochschild +namespace KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma differentialValue_leftOutput {n : ℕ} (b : M) (f : Cochain M n) + (x : Fin (n + 1) → M) : + differentialValue (centralOutput b f) x = + b * differentialValue f x + + (x 0 * b - b * x 0) * f (fun i => x i.succ) := by + simp only [differentialValue, centralOutput_apply, mul_add, + Finset.mul_sum, mul_smul_comm, mul_assoc] + noncomm_ring + +lemma first_separability_identity {n : ℕ} (a b : M) (f : Cochain M (n + 1)) + (hf : ∀ x, differentialValue f x = 0) (x : Fin (n + 1) → M) : + differentialValue (centralOutput a (f.curryLeft b)) x = + a * b * f x - a * f (Fin.cons (b * x 0) (fun i => x i.succ)) + + x 0 * a * f (Fin.cons b (fun i => x i.succ)) := by + rw [differentialValue_leftOutput, first_homotopy_identity f hf] + simp only [ContinuousMultilinearMap.curryLeft_apply] + noncomm_ring + +variable {G : Type*} [Group G] [Fintype G] + +private lemma unitary_norm_le (u : unitary M) : ‖(u : M)‖ ≤ 1 := by + nontriviality M + exact (CStarRing.norm_coe_unitary u).le + +/-- The finite Haar average of the first-variable contracting homotopies. -/ +def finiteUnitaryHomotopy (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 1)) : Cochain M n := + (Fintype.card G : ℂ)⁻¹ • + ∑ u : G, centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M)) + +lemma finiteUnitaryHomotopy_norm (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 1)) : ‖finiteUnitaryHomotopy ρ f‖ ≤ ‖f‖ := by + have hterm (u : G) : + ‖centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M))‖ ≤ ‖f‖ := by + apply (norm_centralOutput_le _ (unitary_norm_le _) _).trans + calc + ‖f.curryLeft (ρ u⁻¹ : M)‖ ≤ ‖f.curryLeft‖ * ‖(ρ u⁻¹ : M)‖ := + f.curryLeft.le_opNorm _ + _ ≤ ‖f‖ := by + rw [ContinuousMultilinearMap.curryLeft_norm] + exact (mul_le_mul_of_nonneg_left (unitary_norm_le _) (norm_nonneg _)).trans_eq + (mul_one _) + have hc : (0 : ℝ) < Fintype.card G := Nat.cast_pos.mpr Fintype.card_pos + calc + ‖finiteUnitaryHomotopy ρ f‖ = + (Fintype.card G : ℝ)⁻¹ * + ‖∑ u : G, centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M))‖ := by + simp only [finiteUnitaryHomotopy, norm_smul, norm_inv, Complex.norm_natCast] + _ ≤ (Fintype.card G : ℝ)⁻¹ * ((Fintype.card G : ℝ) * ‖f‖) := by + apply mul_le_mul_of_nonneg_left _ (inv_nonneg.mpr hc.le) + exact (norm_sum_le _ _).trans (by + simpa only [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] using + Finset.sum_le_sum (s := Finset.univ) (fun u _ => hterm u)) + _ = ‖f‖ := by rw [← mul_assoc, inv_mul_cancel₀ (ne_of_gt hc), one_mul] + +lemma finiteUnitaryHomotopy_exact_unitary (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) + (v : G) (x : Fin n → M) : + differentialValue (finiteUnitaryHomotopy ρ f) (Fin.cons (ρ v : M) x) = + f (Fin.cons (ρ v : M) x) := by + classical + have hc : (Fintype.card G : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos) + have hu (u : G) : (ρ u : M) * (ρ u⁻¹ : M) = 1 := by + rw [← Submonoid.coe_mul, ← map_mul, mul_inv_cancel, map_one, Submonoid.coe_one] + have hsum : + (∑ u : G, (ρ u : M) * f (Fin.cons ((ρ u⁻¹ : M) * (ρ v : M)) x)) = + ∑ u : G, (ρ v : M) * (ρ u : M) * f (Fin.cons (ρ u⁻¹ : M) x) := by + apply Fintype.sum_equiv (Equiv.mulLeft v⁻¹) _ _ + intro u + change (ρ u : M) * f (Fin.cons ((ρ u⁻¹ : M) * (ρ v : M)) x) = + (ρ v : M) * (ρ (v⁻¹ * u) : M) * f (Fin.cons (ρ (v⁻¹ * u)⁻¹ : M) x) + have hcancel : (ρ v : M) * (ρ (v⁻¹ * u) : M) = (ρ u : M) := by + change ((ρ v * ρ (v⁻¹ * u) : unitary M) : M) = _ + rw [← map_mul, mul_inv_cancel_left] + rw [hcancel, mul_inv_rev, inv_inv, map_mul, Submonoid.coe_mul] + rw [finiteUnitaryHomotopy, differentialValue_smul] + have hd : differentialValue + (∑ u : G, centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M))) + (Fin.cons (ρ v : M) x) = + ∑ u : G, differentialValue + (centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M))) (Fin.cons (ρ v : M) x) := by + have hh := map_sum (differentialLinearMap M n) + (fun u : G => centralOutput (ρ u : M) (f.curryLeft (ρ u⁻¹ : M))) Finset.univ + have he := congrArg (fun g : Cochain M (n + 1) => g (Fin.cons (ρ v : M) x)) hh + change (differential _) _ = (∑ u : G, differential _) _ at he + simpa only [sum_apply, differential_apply] using he + rw [hd] + simp only [first_separability_identity _ _ f hf, hu, one_mul, Fin.cons_zero, + Fin.cons_succ, Finset.sum_add_distrib, Finset.sum_sub_distrib, hsum, sub_add_cancel, + Finset.sum_const, Finset.card_univ] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, inv_mul_cancel₀ hc, one_smul] + +lemma finiteUnitaryHomotopy_exact_span (ρ : G →* unitary M) {n : ℕ} + (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) + {a : M} (ha : a ∈ Submodule.span ℂ (Set.range (fun u : G => (ρ u : M)))) + (x : Fin n → M) : + differentialValue (finiteUnitaryHomotopy ρ f) (Fin.cons a x) = f (Fin.cons a x) := by + let L := firstSliceN (differential (finiteUnitaryHomotopy ρ f) - f) x + have hker : Submodule.span ℂ (Set.range (fun u : G => (ρ u : M))) ≤ L.ker := by + apply Submodule.span_le.mpr + rintro _ ⟨u, rfl⟩ + change L (ρ u : M) = 0 + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using + sub_eq_zero.mpr (finiteUnitaryHomotopy_exact_unitary ρ f hf u x) + have h := hker ha + change L a = 0 at h + exact sub_eq_zero.mp (by + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using h) + +section Predual + +open Filter Topology + +variable {X : Type*} [NormedAddCommGroup X] [NormedSpace ℂ X] + [CompleteSpace X] + +/-- Norm-one primitives for the locally finite unitary families used in the +finite homogeneous type I argument. The hypotheses are concrete group and +norm-density data, independent of cochains. -/ +theorem primitive_of_locally_finite_unitaries (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (S : Set (unitary M)) + (hfinite : ∀ s : Finset S, ∃ H : Subgroup (unitary M), + Finite H ∧ ∀ u ∈ s, (u : unitary M) ∈ H) + (hdense : (Submodule.span ℂ (Set.range (fun u : S => ((u : unitary M) : M)))).topologicalClosure = ⊤) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + classical + choose H hH hmem using hfinite + let F (s : Finset S) : Cochain M n := by + letI := hH s + letI := Fintype.ofFinite (H s) + exact finiteUnitaryHomotopy (H s).subtype f + have hFn (s : Finset S) : ‖F s‖ ≤ ‖f‖ := by + let := hH s + let := Fintype.ofFinite (H s) + exact finiteUnitaryHomotopy_norm (H s).subtype f + let U : Ultrafilter (Finset S) := Ultrafilter.of atTop + have hU : (U : Filter (Finset S)) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨g, hgn, ht⟩ := bounded_cochain_ultralimit e U F ‖f‖ (norm_nonneg _) hFn + have hunit (u : S) (x : Fin n → M) : + differentialValue g (Fin.cons ((u : unitary M) : M) x) = + f (Fin.cons ((u : unitary M) : M) x) := by + have he : (fun s => differentialValue (F s) (Fin.cons ((u : unitary M) : M) x)) =ᶠ[U] + (fun _ => f (Fin.cons ((u : unitary M) : M) x)) := by + apply hU + filter_upwards [eventually_ge_atTop ({u} : Finset S)] with s hs + let := hH s + let := Fintype.ofFinite (H s) + exact finiteUnitaryHomotopy_exact_unitary (H s).subtype f hf + ⟨u, hmem s u (hs (Finset.mem_singleton_self u))⟩ x + apply predual_tendsto_unique e (predual_tendsto_differential_of_predual e ht _) + intro z + exact tendsto_const_nhds.congr' (he.mono fun _ h => + congrArg (fun a : M => e.symm a z) h.symm) + refine ⟨g, hgn, fun x => ?_⟩ + let L := firstSliceN (differential g - f) (Fin.tail x) + have hspan : Submodule.span ℂ (Set.range (fun u : S => ((u : unitary M) : M))) ≤ L.ker := by + apply Submodule.span_le.mpr + rintro _ ⟨u, rfl⟩ + change L ((u : unitary M) : M) = 0 + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using + sub_eq_zero.mpr (hunit u (Fin.tail x)) + have hclosed := Submodule.topologicalClosure_minimal _ hspan L.isClosed_ker + rw [hdense] at hclosed + have hh := hclosed (Submodule.mem_top : x 0 ∈ (⊤ : Submodule ℂ M)) + change L (x 0) = 0 at hh + apply sub_eq_zero.mp + simpa only [L, firstSliceN_apply, sub_apply, differential_apply, Fin.cons_self_tail] using hh + +end Predual + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FirstLetter.lean b/lean/OAI/Analysis/BoundedHochschild/FirstLetter.lean new file mode 100644 index 0000000000000000000000000000000000000000..08efcd4f93abb1b103dcde16ea0841d534b83d0f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FirstLetter.lean @@ -0,0 +1,194 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.BlockSpans +import OAI.Analysis.BoundedHochschild.PowerRigidity + +namespace OAI + +/-! Finite and countable first-letter rigidity for free Haar families. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildFirstLetter +noncomputable section +open Filter Topology +open scoped Polynomial ComplexOrder +open HochschildFreeSums HochschildNewtonPolar HochschildBlockSpan +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +lemma tendsto_norm_of_span (τ : A →ₚ[ℂ] ℂ) + (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) + (h1 : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) + (hfree : ∀ r g, g ≠ 1 → τ (u r g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (R : A →L[ℂ] A) (a : A) (b : Bool) + (hR : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends b g.toWord → R (u r g) = a*u r g) + {x : ℕ → A} (hx : x ∈ span (fun r => freeSum (u r)) b) : + Tendsto (fun r => ‖R (x r)-a*x r‖) atTop (nhds 0) := by + let T : A →L[ℝ] A := (R-ContinuousLinearMap.mul ℂ A a).restrictScalars ℝ + have hT : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends b g.toWord → T (u r g) = 0 := by + intro r g hnodup hends + change R (u r g)-a*u r g = 0 + rw [hR r g hnodup hends,sub_self] + have ht := (tendsto_of_mem τ u h1 hu hfree htr hf T b hT hx).norm + change Tendsto (fun r => ‖R (x r)-a*x r‖) atTop (nhds ‖(0:A)‖) at ht + simpa only [norm_zero] using ht + + +lemma choose_diagonal (E : Bool → ℕ → ℕ → ℕ → ℝ) (c : ℕ → ℕ → ℝ) (C : ℕ → ℝ) + (hE : ∀ b n k, 0 < k → Tendsto (E b n k) atTop (nhds 0)) + (hc : ∀ n, Tendsto (c n) atTop (nhds (C n))) : + ∃ r : ℕ → ℕ, (∀ n, |c n (r n)-C n| < 1/(n+1:ℝ)) ∧ + (∀ b n k, 0 < k → k ≤ n → E b n k (r n) < 1/(n+1:ℝ)) := by + have hex (n : ℕ) : ∃ r, |c n r-C n| < 1/(n+1:ℝ) ∧ + ∀ b k, 0 < k → k ≤ n → E b n k r < 1/(n+1:ℝ) := by + have heps : 0 < 1/(n+1:ℝ) := by positivity + have he : ∀ᶠ r in atTop, ∀ b k, 0 < k → k ≤ n → E b n k r < 1/(n+1:ℝ) := by + apply eventually_all.mpr + intro b + have hb : ∀ᶠ r in atTop, ∀ k ∈ Finset.Icc 1 n, E b n k r < 1/(n+1:ℝ) := by + apply (eventually_all_finset _).mpr + intro k hk + exact (hE b n k (Finset.mem_Icc.mp hk).1).eventually (gt_mem_nhds heps) + filter_upwards [hb] with r hr + intro k hk hkn + exact hr k (Finset.mem_Icc.mpr ⟨hk,hkn⟩) + have hd : ∀ᶠ r in atTop, |c n r-C n| < 1/(n+1:ℝ) := by + simpa only [Real.dist_eq] using (hc n).eventually (Metric.ball_mem_nhds _ heps) + exact (hd.and he).exists + choose r hr using hex + exact ⟨r,fun n => (hr n).1,fun b n k hk hkn => (hr n).2 b k hk hkn⟩ + +lemma diagonal_error_tendsto (E : Bool → ℕ → ℕ → ℕ → ℝ) (r : ℕ → ℕ) + (h0 : ∀ b n k j, 0 ≤ E b n k j) + (he : ∀ b n k, 0 < k → k ≤ n → E b n k (r n) < 1/(n+1:ℝ)) + (b : Bool) (k : ℕ) (hk : 0 < k) : + Tendsto (fun n => E b n k (r n)) atTop (nhds 0) := by + have hinv : Tendsto (fun n : ℕ => 1/(n+1:ℝ)) atTop (nhds 0) := by + simpa only [Nat.cast_add,Nat.cast_one] using + (tendsto_one_div_add_atTop_nhds_zero_nat : Tendsto (fun n : ℕ => 1/((n:ℝ)+1)) atTop (nhds 0)) + apply squeeze_zero' (Filter.Eventually.of_forall fun n => h0 b n k (r n)) _ hinv + filter_upwards [eventually_ge_atTop k] with n hn + exact (he b n k hk hn).le + + + +theorem finite_config_rigidity + (τ : A →ₚ[ℂ] ℂ) (u : (r : ℕ) → FreeGroup (Fin (r+1)) →* A) + (h1 : τ 1 = 1) (hu : ∀ r g, star (u r g) = u r g⁻¹) + (hfree : ∀ r g, g ≠ 1 → τ (u r g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (R : A →L[ℂ] A) + (hR : ∀ x : ℕ → A, (∃ C : ℝ, ∀ r, ‖x r‖ ≤ C) → + Tendsto (fun r => ‖τ.toPreGNS (x r)‖) atTop (nhds 0) → + Tendsto (fun r => ‖τ.toPreGNS (R (x r))‖) atTop (nhds 0)) + (a b : A) + (hp : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends true g.toWord → R (u r g) = a*u r g) + (hm : ∀ r (g : FreeGroup (Fin (r+1))), (g.toWord.map Prod.fst).Nodup → + HochschildBlockWords.Ends false g.toWord → R (u r g) = b*u r g) : a = b := by + classical + rcases subsingleton_or_nontrivial A with hA | hA + · exact Subsingleton.elim _ _ + let s : ℕ → A := fun r => freeSum (u r) + let q : ℕ → ℕ → A := fun n r => polarApprox (s r) n + let E : Bool → ℕ → ℕ → ℕ → ℝ := fun t n k r => + if t then ‖R ((q n r)^k)-a*(q n r)^k‖ else + ‖R (star (q n r)^k)-b*star (q n r)^k‖ + let c : ℕ → ℕ → ℝ := fun n r => (τ ((1-(1/4:ℝ) • (star (s r)*s r))^(n+1))).re + let C : ℕ → ℝ := fun n => catalanFunctional (HochschildCatalan.cutoff^(n+1)) + have hE : ∀ t n k, 0 < k → Tendsto (E t n k) atTop (nhds 0) := by + intro t n k hk + cases t + · change Tendsto (fun r => ‖R (star (q n r)^k)-b*star (q n r)^k‖) _ _ + apply tendsto_norm_of_span τ u h1 hu hfree htr hf R b false hm + exact pow_mem s false (star_mem s true (polarApprox_mem s n)) k hk + · change Tendsto (fun r => ‖R ((q n r)^k)-a*(q n r)^k‖) _ _ + apply tendsto_norm_of_span τ u h1 hu hfree htr hf R a true hp + exact pow_mem s true (polarApprox_mem s n) k hk + have hc (n : ℕ) : Tendsto (c n) atTop (nhds (C n)) := by + have h := polynomial_moments_tendsto τ s (freeSum_moments_tendsto τ u h1 hu hfree) + (HochschildCatalan.cutoff^(n+1)) + simpa only [c,C,HochschildCatalan.cutoff,map_pow,map_sub,map_one,map_mul, + Polynomial.aeval_C,Polynomial.aeval_X,← Algebra.smul_def] using h + obtain ⟨r,hc',he⟩ := choose_diagonal E c C hE hc + have hs (r : ℕ) : ‖s r‖ ≤ 2 := norm_freeSum_le_two τ (u r) h1 (hu r) (hfree r) htr hf + have hq (n r : ℕ) : ‖q n r‖ ≤ 1 := polarApprox_norm_le_one (s r) (hs r) n + have hE0 (t : Bool) (n k j : ℕ) : 0 ≤ E t n k j := by cases t <;> exact norm_nonneg _ + have htE (t : Bool) (k : ℕ) (hk : 0 < k) := diagonal_error_tendsto E r hE0 he t k hk + have hinv : Tendsto (fun n : ℕ => 1/(n+1:ℝ)) atTop (nhds 0) := + tendsto_one_div_add_atTop_nhds_zero_nat + have hdef : Tendsto (fun n => (τ (1-star (q n (r n))*q n (r n))).re) atTop (nhds 0) := by + apply squeeze_zero (fun n => (τ.map_nonneg (defect_nonneg (s (r n)) (hs (r n)) n)).1) + (fun n => ?_) (by simpa only [add_zero] using cutoff_catalan_tendsto_zero.add hinv) + have hle := (τ.monotone (defect_le_cutoff (s (r n)) (hs (r n)) n)).1 + have hcupper := (abs_lt.mp (hc' n)).2 + change (τ (1-star (q n (r n))*q n (r n))).re ≤ c n (r n) at hle + change (τ (1-star (q n (r n))*q n (r n))).re ≤ C n+1/(n+1:ℝ) + linarith + apply HochschildMatrixDilation.contraction_power_rigidity τ h1 htr hf R hR + (fun n => q n (r n)) (fun n => hq n (r n)) hdef a b + · intro k hk + apply squeeze_zero (fun n => norm_nonneg _) (fun n => HochschildRigidity.preGNS_norm_le τ h1 _) + exact htE true k hk + · intro k hk + apply squeeze_zero (fun n => norm_nonneg _) (fun n => HochschildRigidity.preGNS_norm_le τ h1 _) + exact htE false k hk + +lemma toWord_map_injective {α β : Type*} [DecidableEq α] [DecidableEq β] + (f : α → β) (hf : Function.Injective f) (g : FreeGroup α) : + (FreeGroup.map f g).toWord = g.toWord.map (fun z => (f z.1,z.2)) := by + have hm : FreeGroup.IsReduced (g.toWord.map (fun z => (f z.1,z.2))) := by + rw [FreeGroup.IsReduced,List.isChain_map] + exact FreeGroup.isReduced_toWord.imp (fun a b h he => h (hf he)) + conv_lhs => rw [← (FreeGroup.mk_toWord (x:=g)),FreeGroup.map.mk,FreeGroup.toWord_mk] + exact hm.reduce_eq + + + +theorem countable_first_letter_rigidity + (τ : A →ₚ[ℂ] ℂ) (u : FreeGroup ℕ →* A) + (h1 : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) + (hfree : ∀ g, g ≠ 1 → τ (u g) = 0) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) + (R : A →L[ℂ] A) + (hR : ∀ x : ℕ → A, (∃ C : ℝ, ∀ r, ‖x r‖ ≤ C) → + Tendsto (fun r => ‖τ.toPreGNS (x r)‖) atTop (nhds 0) → + Tendsto (fun r => ‖τ.toPreGNS (R (x r))‖) atTop (nhds 0)) + (a b : A) + (hw : ∀ (g : FreeGroup ℕ) i t l, g.toWord = (i,t)::l → + (g.toWord.map Prod.fst).Nodup → R (u g) = (if t then a else b)*u g) : + a = b := by + let v (r : ℕ) := u.comp (FreeGroup.map (Fin.val : Fin (r+1) → ℕ)) + have hv (r : ℕ) (g : FreeGroup (Fin (r+1))) : star (v r g) = v r g⁻¹ := by + simp only [v,MonoidHom.comp_apply,hu,map_inv] + have hvfree (r : ℕ) (g : FreeGroup (Fin (r+1))) (hg : g ≠ 1) : τ (v r g) = 0 := by + apply hfree + exact fun he => hg ((FreeGroup.map_injective Fin.val_injective) (he.trans (map_one _).symm)) + have hvword (r : ℕ) (g : FreeGroup (Fin (r+1))) (t : Bool) + (hn : (g.toWord.map Prod.fst).Nodup) (he : HochschildBlockWords.Ends t g.toWord) : + R (v r g) = (if t then a else b)*v r g := by + obtain ⟨⟨i,l,hl⟩,_⟩ := he + let h : FreeGroup ℕ := FreeGroup.map Fin.val g + have hh := toWord_map_injective Fin.val Fin.val_injective g + apply hw h i.val t (l.map (fun z => (z.1.val,z.2))) + · rw [hh,hl,List.map_cons] + · rw [hh,List.map_map] + simpa only [List.map_map,Function.comp_def] using (hn.map Fin.val_injective) + apply finite_config_rigidity τ v h1 hv hvfree htr hf R hR a b + · intro r g hn he + exact hvword r g true hn he + · intro r g hn he + exact hvword r g false hn he + +end +end HochschildFirstLetter +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FixedFactorizationLimits.lean b/lean/OAI/Analysis/BoundedHochschild/FixedFactorizationLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..03e96c11a33909442103291be5de3a9f6932eeb1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FixedFactorizationLimits.lean @@ -0,0 +1,75 @@ +import OAI.Analysis.BoundedHochschild.WeakRepresentationAverages + +namespace OAI + +/-! Pointwise weak operator limits retain a fixed representation and left +factor, while the bounded right factor is allowed to vary. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +variable {M H K : Type*} [CStarAlgebra M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def weakFactorFamily (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) + (W : H →WOT[ℂ] K) : M → (H →WOT[ℂ] H) := + fun a => weakFactorValue π L a W + +lemma weakFactorFamily_continuous (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L : H →L[ℂ] K) : + Continuous (weakFactorFamily π L) := by + apply continuous_pi + intro a + exact weakFactorValue_continuous π L a + +theorem fixedFactorization_isClosed (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (L : H →L[ℂ] K) (D : ℝ) : + IsClosed {F : M → (H →WOT[ℂ] H) | ∃ W : H →L[ℂ] K, ‖W‖ ≤ D ∧ + ∀ a, F a = ContinuousLinearMapWOT.ofCLM (L.adjoint.comp ((π a).comp W))} := by + have hcompact := (rectangularWeakBall_isCompact (H := H) (K := K) D).image + (weakFactorFamily_continuous π L) + have he : weakFactorFamily π L '' rectangularWeakBall D = + {F : M → (H →WOT[ℂ] H) | ∃ W : H →L[ℂ] K, ‖W‖ ≤ D ∧ + ∀ a, F a = ContinuousLinearMapWOT.ofCLM (L.adjoint.comp ((π a).comp W))} := by + ext F + constructor + · rintro ⟨W, hW, rfl⟩ + exact ⟨W.toCLM, hW, fun _ => rfl⟩ + · rintro ⟨W, hW, hF⟩ + refine ⟨ContinuousLinearMapWOT.ofCLM W, hW, ?_⟩ + funext a + exact (hF a).symm + rw [he] at hcompact + exact hcompact.isClosed + +theorem factorization_of_pointwise_weak_limit + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (L : H →L[ℂ] K) {D : ℝ} {I : Type*} {l : Filter I} [l.NeBot] + (T : I → M →L[ℂ] M) (W : I → H →L[ℂ] K) (hW : ∀ i, ‖W i‖ ≤ D) + (hT : ∀ i a, σ (T i a) = L.adjoint.comp ((π a).comp (W i))) + (S : M →L[ℂ] M) + (hlim : ∀ a ξ η, Tendsto (fun i => inner ℂ η (σ (T i a) ξ)) l + (𝓝 (inner ℂ η (σ (S a) ξ)))) : + ∃ V : H →L[ℂ] K, ‖V‖ ≤ D ∧ + ∀ a, σ (S a) = L.adjoint.comp ((π a).comp V) := by + have ht : Tendsto (fun i a => ContinuousLinearMapWOT.ofCLM (σ (T i a))) l + (𝓝 (fun a => ContinuousLinearMapWOT.ofCLM (σ (S a)))) := by + apply tendsto_pi_nhds.mpr + intro a + exact ContinuousLinearMapWOT.tendsto_iff_forall_inner_apply_tendsto.mpr (hlim a) + have hf (i : I) : (fun a => ContinuousLinearMapWOT.ofCLM (σ (T i a))) ∈ + {F : M → (H →WOT[ℂ] H) | ∃ W : H →L[ℂ] K, ‖W‖ ≤ D ∧ + ∀ a, F a = ContinuousLinearMapWOT.ofCLM (L.adjoint.comp ((π a).comp W))} := + ⟨W i, hW i, fun a => congrArg ContinuousLinearMapWOT.ofCLM (hT i a)⟩ + obtain ⟨V, hV, he⟩ := (fixedFactorization_isClosed π L D).mem_of_tendsto ht + (Eventually.of_forall hf) + exact ⟨V, hV, fun a => congrArg ContinuousLinearMapWOT.toCLM (he a)⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FlipMatrixNesting.lean b/lean/OAI/Analysis/BoundedHochschild/FlipMatrixNesting.lean new file mode 100644 index 0000000000000000000000000000000000000000..93a3408828c096481361bf511a9ce688c4d0f577 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FlipMatrixNesting.lean @@ -0,0 +1,38 @@ +import OAI.Analysis.BoundedHochschild.ScalarMatrixActions + +namespace OAI + +/-! Exchange the finite matrix indices in a two-by-two amplification. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {A : Type*} [CStarAlgebra A] + +def flipMatrixNesting (n k : ℕ) : + CStarMatrix (Fin n) (Fin n) (CStarMatrix (Fin k) (Fin k) A) ≃⋆ₐ[ℂ] + CStarMatrix (Fin k) (Fin k) (CStarMatrix (Fin n) (Fin n) A) where + toFun X i j p q := X p q i j + invFun X i j p q := X p q i j + left_inv _ := rfl + right_inv _ := rfl + map_add' _ _ := rfl + map_smul' _ _ := rfl + map_star' _ := rfl + map_mul' X Y := by + ext i j p q + change (∑ s : Fin n, (fun r t => ∑ l : Fin k, X p s r l * Y s q l t)) i j = + (∑ l : Fin k, (fun r t => ∑ s : Fin n, X r s i l * Y s t l j)) p q + simp only [Finset.sum_apply] + exact Finset.sum_comm + +@[simp] lemma flipMatrixNesting_apply (n k : ℕ) + (X : CStarMatrix (Fin n) (Fin n) (CStarMatrix (Fin k) (Fin k) A)) + (i j : Fin k) (p q : Fin n) : flipMatrixNesting n k X i j p q = X p q i j := rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Frames.lean b/lean/OAI/Analysis/BoundedHochschild/Frames.lean new file mode 100644 index 0000000000000000000000000000000000000000..866e8cb946fc552ac054283546c8a0004a17144e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Frames.lean @@ -0,0 +1,358 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.TypeIIStructure + +namespace OAI + +/-! Orthogonal frames of partial isometries and maximal frame construction. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildComparison +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +namespace PartialIso + +def ofProjection (p : M) (hp : IsStarProjection p) : PartialIso M := + ⟨p,by rw [hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq,hp.isIdempotentElem.eq]⟩ +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma ofProjection_coe (p : M) (hp : IsStarProjection p) : + ((ofProjection p hp : PartialIso M):M)=p := rfl +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma ofProjection_initial (p : M) (hp : IsStarProjection p) : + (ofProjection p hp).initial=p := by simp only [initial,ofProjection_coe,hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma ofProjection_final (p : M) (hp : IsStarProjection p) : + (ofProjection p hp).final=p := by simp only [final,ofProjection_coe,hp.isSelfAdjoint.star_eq,hp.isIdempotentElem.eq] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma initial_ne_zero {v : PartialIso M} (hv : (v:M) ≠ 0) : v.initial ≠ 0 := by + intro h + apply hv + have hh := v.mul_initial + simpa only [h,mul_zero,eq_comm] using hh + +lemma restrict_square (v : PartialIso M) {p : M} (hp : IsStarProjection p) + (hpv : p ≤ v.initial) : star ((v:M)*p)*((v:M)*p)=p := by + calc + star ((v:M)*p)*((v:M)*p) = p*v.initial*p := by + simp only [star_mul,hp.isSelfAdjoint.star_eq,initial,mul_assoc] + _ = p := by rw [(hp.le_iff_mul_eq_left v.initial_proj).mp hpv,hp.isIdempotentElem.eq] + +def restrict (v : PartialIso M) {p : M} (hp : IsStarProjection p) + (hpv : p ≤ v.initial) : PartialIso M := + ⟨(v:M)*p,by rw [mul_assoc,restrict_square v hp hpv,mul_assoc,hp.isIdempotentElem.eq]⟩ +@[simp] lemma restrict_coe (v : PartialIso M) {p : M} (hp : IsStarProjection p) + (hpv : p ≤ v.initial) : ((v.restrict hp hpv : PartialIso M):M)=(v:M)*p := rfl +@[simp] lemma restrict_initial (v : PartialIso M) {p : M} (hp : IsStarProjection p) + (hpv : p ≤ v.initial) : (v.restrict hp hpv).initial=p := restrict_square v hp hpv +lemma restrict_le (v : PartialIso M) {p : M} (hp : IsStarProjection p) + (hpv : p ≤ v.initial) : v.restrict hp hpv ≤ v := by + exact ⟨by simpa only [restrict_initial] using hpv,by simp only [restrict_initial,restrict_coe]⟩ +end PartialIso + +lemma projection_orthogonal_mono {p q r s : M} + (hp : IsStarProjection p) (hq : IsStarProjection q) + (hr : IsStarProjection r) (hs : IsStarProjection s) + (hpr : p ≤ r) (hqs : q ≤ s) (hrs : r*s=0) : p*q=0 := by + calc + p*q = (p*r)*(s*q) := by + rw [(hp.le_iff_mul_eq_left hr).mp hpr,(hq.le_iff_mul_eq_right hs).mp hqs] + _ = p*(r*s)*q := by simp only [mul_assoc] + _ = 0 := by rw [hrs,mul_zero,zero_mul] + +structure Frame (M : Type*) [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] (n : ℕ) where + part : Fin (n+1) → PartialIso M + common : ∀ i, (part i).initial=(part 0).initial + anchor : (part 0 : M)=(part 0).initial + orthogonal : ∀ i j, i ≠ j → (part i).final*(part j).final=0 + +namespace Frame +variable {n : ℕ} +@[ext] lemma ext {v w : Frame M n} (h : ∀ i, v.part i=w.part i) : v=w := by + have he := funext h + cases v; cases w; congr + +def base (v : Frame M n) : M := (v.part 0).initial +def support (v : Frame M n) : M := ∑ i, (v.part i).final +lemma base_proj (v : Frame M n) : IsStarProjection v.base := (v.part 0).initial_proj +lemma final_zero (v : Frame M n) : (v.part 0).final=v.base := by + change (v.part 0:M)*star (v.part 0:M)=v.base + change (v.part 0:M)*star (v.part 0:M)=(v.part 0).initial + rw [v.anchor,(v.part 0).initial_proj.isSelfAdjoint.star_eq, + (v.part 0).initial_proj.isIdempotentElem.eq] +lemma initial_eq (v : Frame M n) (i : Fin (n+1)) : (v.part i).initial=v.base := v.common i +lemma support_proj (v : Frame M n) : IsStarProjection v.support := by + classical + have he (i j : Fin (n+1)) : (v.part i).final*(v.part j).final= + if i=j then (v.part i).final else 0 := by + by_cases h : i=j + · subst j; rw [ite_eq_left rfl]; exact (v.part i).final_proj.isIdempotentElem.eq + · rw [ite_eq_right h]; exact v.orthogonal i j h + constructor + · change (∑ i, (v.part i).final)*(∑ j, (v.part j).final)=∑ i, (v.part i).final + rw [Finset.sum_mul_sum] + simp only [he,Finset.sum_ite_eq,Finset.mem_univ,ite_true] + · change star (∑ i, (v.part i).final)=∑ i, (v.part i).final + simp only [star_sum,(v.part _).final_proj.isSelfAdjoint.star_eq] +lemma final_le_support (v : Frame M n) (i : Fin (n+1)) : (v.part i).final ≤ v.support := by + apply ((v.part i).final_proj.le_iff_mul_eq_left v.support_proj).mpr + change (v.part i).final*(∑ j, (v.part j).final)=(v.part i).final + rw [Finset.mul_sum] + rw [Finset.sum_eq_single i] + · exact (v.part i).final_proj.isIdempotentElem.eq + · intro j _ hji + exact v.orthogonal i j hji.symm + · simp +lemma base_le_support (v : Frame M n) : v.base ≤ v.support := by + rw [← v.final_zero]; exact v.final_le_support 0 +lemma support_le {p : M} (v : Frame M n) (hp : IsStarProjection p) + (hv : ∀ i, (v.part i).final ≤ p) : v.support ≤ p := by + apply (v.support_proj.le_iff_mul_eq_left hp).mpr + change (∑ i, (v.part i).final)*p=∑ i, (v.part i).final + simp only [Finset.sum_mul,((v.part _).final_proj.le_iff_mul_eq_left hp).mp (hv _)] + +instance : Zero (Frame M n) := ⟨⟨fun _ => 0,fun _ => rfl,by simp,by intros; simp⟩⟩ +@[simp] lemma zero_part (i : Fin (n+1)) : (0:Frame M n).part i=0 := rfl +@[simp] lemma zero_base : (0:Frame M n).base=0 := by simp only [base,zero_part,PartialIso.initial_zero] +@[simp] lemma zero_support : (0:Frame M n).support=0 := by simp only [support,zero_part,PartialIso.final_zero,Finset.sum_const_zero] +instance : LE (Frame M n) := ⟨fun v w => ∀ i, v.part i ≤ w.part i⟩ +instance : PartialOrder (Frame M n) where + le_refl _ _ := le_rfl + le_trans _ _ _ h1 h2 i := (h1 i).trans (h2 i) + le_antisymm _ _ h1 h2 := ext fun i => le_antisymm (h1 i) (h2 i) +lemma zero_le (v : Frame M n) : 0 ≤ v := fun i => PartialIso.zero_le (v.part i) +lemma base_mono {v w : Frame M n} (h : v ≤ w) : v.base ≤ w.base := (h 0).1 +lemma eq_of_le_of_base_eq {v w : Frame M n} (h : v ≤ w) (he : v.base=w.base) : v=w := by + apply ext + intro i + apply PartialIso.ext + have hh := (h i).2 + rw [v.initial_eq,he,← w.initial_eq i,(w.part i).mul_initial] at hh + exact hh.symm + +lemma cross_final_zero {v w : Frame M n} (h : v.support*w.support=0) + (i j : Fin (n+1)) : (v.part i).final*(w.part j).final=0 := + projection_orthogonal_mono (v.part i).final_proj (w.part j).final_proj + v.support_proj w.support_proj (v.final_le_support i) (w.final_le_support j) h +lemma cross_initial_zero {v w : Frame M n} (h : v.support*w.support=0) + (i j : Fin (n+1)) : (v.part i).initial*(w.part j).initial=0 := by + rw [v.initial_eq,w.initial_eq] + exact projection_orthogonal_mono v.base_proj w.base_proj v.support_proj w.support_proj + v.base_le_support w.base_le_support h +lemma support_orthogonal_symm {v w : Frame M n} (h : v.support*w.support=0) : + w.support*v.support=0 := by + simpa only [star_mul,v.support_proj.isSelfAdjoint.star_eq, + w.support_proj.isSelfAdjoint.star_eq,star_zero] using congrArg star h + +def orthogonalSum (v w : Frame M n) (h : v.support*w.support=0) : Frame M n where + part i := (v.part i).orthogonalSum (w.part i) (cross_initial_zero h i i) (cross_final_zero h i i) + common i := by simp only [PartialIso.orthogonalSum_initial,v.common,w.common] + anchor := by + change (v.part 0:M)+(w.part 0:M)=_ + rw [PartialIso.orthogonalSum_initial,v.anchor,w.anchor] + orthogonal i j hij := by + simp only [PartialIso.orthogonalSum_final,add_mul,mul_add,v.orthogonal i j hij, + w.orthogonal i j hij,cross_final_zero h i j,cross_final_zero (support_orthogonal_symm h) i j, + zero_add] +lemma orthogonalSum_support (v w : Frame M n) (h : v.support*w.support=0) : + (v.orthogonalSum w h).support=v.support+w.support := by + simp only [support,orthogonalSum,PartialIso.orthogonalSum_final,Finset.sum_add_distrib] +lemma orthogonalSum_base (v w : Frame M n) (h : v.support*w.support=0) : + (v.orthogonalSum w h).base=v.base+w.base := by + exact PartialIso.orthogonalSum_initial (v.part 0) (w.part 0) + (cross_initial_zero h 0 0) (cross_final_zero h 0 0) +lemma le_orthogonalSum (v w : Frame M n) (h : v.support*w.support=0) : + v ≤ v.orthogonalSum w h := fun i => PartialIso.le_orthogonalSum (v.part i) (w.part i) + (cross_initial_zero h i i) (cross_final_zero h i i) + +end Frame +end HochschildComparison + +open Filter Topology +open scoped ComplexOrder +namespace HochschildComparison +open BoundedHochschild HochschildRigidity HochschildTypeII FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +namespace Frame +variable {n : ℕ} +include e hτ htr hfaith in +lemma exists_local (hII : TypeII1 M) (n : ℕ) {p : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) : + ∃ v : Frame M n, v.base ≠ 0 ∧ v.support ≤ p := by + induction n with + | zero => + let v : Frame M 0 := ⟨fun _ => PartialIso.ofProjection p hp,fun _ => rfl, + by simp,by intro i j hij; exact (hij (Fin.ext (by omega))).elim⟩ + refine ⟨v,?_,?_⟩ + · simpa only [Frame.base,v,PartialIso.ofProjection_initial] using hp0 + · apply v.support_le hp + intro i + exact le_of_eq (PartialIso.ofProjection_final p hp) + | succ n ih => + obtain ⟨v,hv0,hvp⟩ := ih + obtain ⟨w,hw0,hwi,hwf,hwo⟩ := exists_orthogonal_equivalent e τ hτ htr hfaith hII v.base_proj hv0 + let r := w.initial + have hr : IsStarProjection r := w.initial_proj + have hrv (i : Fin (n+1)) : r ≤ (v.part i).initial := by rw [v.initial_eq]; exact hwi + let u (i : Fin (n+1)) := (v.part i).restrict hr (hrv i) + have hui (i : Fin (n+1)) : (u i).initial=r := PartialIso.restrict_initial _ _ _ + have huf (i : Fin (n+1)) : (u i).final ≤ (v.part i).final := + PartialIso.final_mono (PartialIso.restrict_le _ _ _) + have hu0 : (u 0:M)=r := by + change (v.part 0:M)*r=r + rw [v.anchor] + exact (hr.le_iff_mul_eq_right v.base_proj).mp hwi + have hu0f : (u 0).final=r := by + change (u 0:M)*star (u 0:M)=r + rw [hu0,hr.isSelfAdjoint.star_eq,hr.isIdempotentElem.eq] + have hwuj (j : Fin (n+1)) : w.final*(u j).final=0 := by + by_cases hj : j=0 + · subst j + rw [hu0f] + simpa only [star_mul,w.initial_proj.isSelfAdjoint.star_eq,w.final_proj.isSelfAdjoint.star_eq, + star_zero] using congrArg star hwo + · apply projection_orthogonal_mono w.final_proj (u j).final_proj + (v.part 0).final_proj (v.part j).final_proj + · rwa [v.final_zero] + · exact huf j + · exact v.orthogonal 0 j (Ne.symm hj) + let a : Fin (n+1+1) → PartialIso M := Fin.lastCases w u + have halast : a (Fin.last (n+1))=w := by simp only [a,Fin.lastCases_last] + have hacast (i : Fin (n+1)) : a i.castSucc=u i := by simp only [a,Fin.lastCases_castSucc] + have hai (i : Fin (n+1+1)) : (a i).initial=r := by + induction i using Fin.lastCases with + | last => rw [halast] + | cast i => rw [hacast]; exact hui i + have ha0 : (a 0:M)=r := by + change (a (Fin.castSucc (0:Fin (n+1))) : M)=r + rw [hacast]; exact hu0 + have hao (i j : Fin (n+1+1)) (hij : i ≠ j) : (a i).final*(a j).final=0 := by + induction i using Fin.lastCases with + | last => + induction j using Fin.lastCases with + | last => exact (hij rfl).elim + | cast j => rw [halast,hacast]; exact hwuj j + | cast i => + induction j using Fin.lastCases with + | last => + rw [hacast,halast] + simpa only [star_mul,w.final_proj.isSelfAdjoint.star_eq,(u i).final_proj.isSelfAdjoint.star_eq, + star_zero] using congrArg star (hwuj i) + | cast j => + rw [hacast,hacast] + exact projection_orthogonal_mono (u i).final_proj (u j).final_proj + (v.part i).final_proj (v.part j).final_proj (huf i) (huf j) + (v.orthogonal i j (fun he => hij (congrArg Fin.castSucc he))) + let z : Frame M (n+1) := ⟨a,fun i => (hai i).trans (hai 0).symm, + ha0.trans (hai 0).symm,hao⟩ + refine ⟨z,?_,?_⟩ + · change (a 0).initial ≠ 0 + rw [hai] + exact PartialIso.initial_ne_zero hw0 + · apply z.support_le hp + intro i + induction i using Fin.lastCases with + | last => change (a (Fin.last (n+1))).final ≤ p; rw [halast]; exact hwf.trans (v.base_le_support.trans hvp) + | cast i => change (a i.castSucc).final ≤ p; rw [hacast]; exact (huf i).trans ((v.final_le_support i).trans hvp) + +include hfaith in +lemma le_of_comparable_trace_le {v w : Frame M n} (hc : v ≤ w ∨ w ≤ v) + (ht : (τ v.base).re ≤ (τ w.base).re) : v ≤ w := by + rcases hc with h|h + · exact h + · have hh := HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith + v.base_proj w.base_proj (Or.inr (base_mono h)) ht + exact le_of_eq (eq_of_le_of_base_eq h (le_antisymm (base_mono h) hh)).symm + +include e hτ htr hfaith in +lemma chain_upper (c : Set (Frame M n)) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) : + ∃ s : Frame M n, ∀ v ∈ c, v ≤ s := by + classical + let T : Set ℝ := (fun v : Frame M n => (τ v.base).re) '' c + have hTne : T.Nonempty := Set.Nonempty.image _ hne + have hTbd : BddAbove T := ⟨(τ 1).re,by + rintro _ ⟨v,hv,rfl⟩ + exact Complex.re_le_re (τ.monotone v.base_proj.le_one)⟩ + obtain ⟨b,hbm,_hbL,hbt,hb⟩ := (isLUB_csSup hTne hTbd).exists_seq_monotone_tendsto hTne + choose a ha hab using hb + change ∀ m, (τ (a m).base).re=b m at hab + have ham : Monotone a := by + intro j k hjk + apply le_of_comparable_trace_le τ hfaith (hc.total (ha j) (ha k)) + rw [hab,hab] + exact hbm hjk + let L := HochschildSakai.mul_hasPreadjoint e + choose v ht hle hleast using fun i : Fin (n+1) => + PartialIso.exists_monotone_limit e τ L hτ htr hfaith + (fun m => (a m).part i) (fun j k hjk => ham hjk i) + have hfin (i : Fin (n+1)) : GNSTendsto τ (fun m => ((a m).part i).final) atTop (v i).final := + (ht i).mul τ htr ((ht i).star τ htr) 1 (fun m => ((a m).part i).norm_le_one) + have hini (i : Fin (n+1)) : GNSTendsto τ (fun m => ((a m).part i).initial) atTop (v i).initial := + ((ht i).star τ htr).mul τ htr (ht i) 1 + (fun m => by simpa only [norm_star] using ((a m).part i).norm_le_one) + have hcommon (i : Fin (n+1)) : (v i).initial=(v 0).initial := by + apply GNSTendsto.unique τ hfaith (hini i) + simpa only [(a _).common] using hini 0 + have hanchor : (v 0:M)=(v 0).initial := by + apply GNSTendsto.unique τ hfaith (ht 0) + simpa only [(a _).anchor] using hini 0 + have horth (i j : Fin (n+1)) (hij : i ≠ j) : (v i).final*(v j).final=0 := by + apply GNSTendsto.unique τ hfaith ((hfin i).mul τ htr (hfin j) 1 + (fun m => ((a m).part i).final_proj.norm_le _)) + simpa only [(a _).orthogonal i j hij] using GNSTendsto.const τ (0:M) atTop + let s : Frame M n := ⟨v,hcommon,hanchor,horth⟩ + have htrace : (τ s.base).re=sSup T := by + have hz := trace_predual_tendsto e τ hτ + (predual_tendsto_of_preGNS e τ L hτ hfaith 1 + (fun m => ((a m).part 0).initial_proj.norm_le _) (hini 0)) + apply tendsto_nhds_unique (Complex.continuous_re.tendsto _ |>.comp hz) + have hbb : ∀ m, (τ ((a m).part 0).initial).re=b m := hab + simpa only [Function.comp_def,hbb] using hbt + have has (m : ℕ) : a m ≤ s := fun i => hle i m + refine ⟨s,?_⟩ + intro z hz + by_cases hex : ∃ m, z ≤ a m + · obtain ⟨m,hm⟩ := hex + exact hm.trans (has m) + · have haz : ∀ m, a m ≤ z := fun m => + (hc.total (ha m) hz).resolve_right (fun h => hex ⟨m,h⟩) + have hsz : s ≤ z := fun i => hleast i (z.part i) (fun m => haz m i) + apply le_of_comparable_trace_le τ hfaith (Or.inr hsz) + rw [htrace] + exact le_csSup hTbd ⟨z,hz,rfl⟩ + +include e hτ htr hfaith in + +theorem exists_full (hII : TypeII1 M) (n : ℕ) : ∃ v : Frame M n, v.support=1 := by + classical + obtain ⟨v,_hv0,hmax⟩ := zorn_le_nonempty₀ (Set.univ : Set (Frame M n)) + (fun c _hc hchain y hy => by + obtain ⟨s,hs⟩ := chain_upper e τ hτ htr hfaith c hchain ⟨y,hy⟩ + exact ⟨s,Set.mem_univ _,hs⟩) 0 (Set.mem_univ _) + refine ⟨v,?_⟩ + by_contra hv + obtain ⟨w,hw0,hw⟩ := exists_local e τ hτ htr hfaith hII n + v.support_proj.one_sub (sub_ne_zero.mpr (Ne.symm hv)) + have horth := projection_orthogonal_of_le_complement v.support_proj w.support_proj hw + have hle := v.le_orthogonalSum w horth + have he := le_antisymm (hmax.2 (Set.mem_univ _) hle) hle + have hh := congrArg Frame.base he + rw [orthogonalSum_base] at hh + exact hw0 (add_eq_left.mp hh) + +end Frame +end HochschildComparison + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FreeCoefficients.lean b/lean/OAI/Analysis/BoundedHochschild/FreeCoefficients.lean new file mode 100644 index 0000000000000000000000000000000000000000..fc3782af1a026622b24d1592247603abf6cd9b2e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FreeCoefficients.lean @@ -0,0 +1,174 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.RareScales + +namespace OAI + +/-! Centered free coefficients and vanishing graded moments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +namespace HochschildFreeMoments +variable {M G : Type*} [Ring M] [Algebra ℂ M] [Group G] + (B : Subalgebra ℂ M) (u : G →* M) (τ : M →ₗ[ℂ] ℂ) + +abbrev Letter := B ⊕ G + +def tag : Letter B (G := G) → Bool + | .inl _ => false + | .inr _ => true + +def value : Letter B (G := G) → M + | .inl b => b + | .inr g => u g + +def degreeLetter : Letter B (G := G) → G + | .inl _ => 1 + | .inr g => g + +def evaluate (l : List (Letter B (G := G))) : M := (l.map (value B u)).prod + +def degree (l : List (Letter B (G := G))) : G := (l.map (degreeLetter B)).prod + +@[simp] lemma evaluate_nil : evaluate B u []=1 := rfl +@[simp] lemma evaluate_cons (x : Letter B (G := G)) (l : List (Letter B (G := G))) : + evaluate B u (x::l)=value B u x*evaluate B u l := rfl +@[simp] lemma evaluate_append (p q : List (Letter B (G := G))) : + evaluate B u (p++q)=evaluate B u p*evaluate B u q := by simp [evaluate,List.prod_append] +@[simp] lemma degree_nil : degree B ([] : List (Letter B (G := G)))=1 := rfl +@[simp] lemma degree_cons (x : Letter B (G := G)) (l : List (Letter B (G := G))) : + degree B (x::l)=degreeLetter B x*degree B l := rfl +@[simp] lemma degree_append (p q : List (Letter B (G := G))) : + degree B (p++q)=degree B p*degree B q := by simp [degree,List.prod_append] + + + +def FreeCoefficients : Prop := + ∀ l : List (Letter B (G := G)), + l.IsChain (fun x y => tag B x ≠ tag B y) → l ≠ [] → + (∀ x ∈ l, τ (value B u x)=0) → τ (evaluate B u l)=0 + +def center : Letter B (G := G) → Letter B (G := G) + | .inl b => .inl (b-(τ (b:M)) • (1:B)) + | .inr g => .inr g + +omit [Group G] in +@[simp] lemma tag_center (x : Letter B (G := G)) : tag B (center B τ x)=tag B x := by + cases x <;> rfl +@[simp] lemma degreeLetter_center (x : Letter B (G := G)) : + degreeLetter B (center B τ x)=degreeLetter B x := by cases x <;> rfl +@[simp] lemma degree_center (l : List (Letter B (G := G))) : + degree B (l.map (center B τ))=degree B l := by simp [degree,List.map_map,Function.comp_def] + +lemma center_replacement (p q : List (Letter B (G := G))) (b : B) : + τ (evaluate B u (p++center B τ (.inl b)::q))= + τ (evaluate B u (p++(.inl b)::q))- + τ (b:M)*τ (evaluate B u (p++q)) := by + simp only [evaluate_append,evaluate_cons,center,value,Subalgebra.coe_sub, + Subalgebra.coe_smul,Subalgebra.coe_one,mul_sub,sub_mul,mul_smul_comm, + smul_mul_assoc,one_mul,map_sub,map_smul,smul_eq_mul] + + + +lemma center_moment (l : List (Letter B (G := G))) (hl : degree B l ≠ 1) + (hshort : ∀ k : List (Letter B (G := G)), k.length rfl + | cons x q ih => + have hn' : ((p++[center B τ x])++q).length=l.length := by + simpa only [List.length_append,List.length_singleton,List.length_cons,List.length_nil, + Nat.add_assoc,Nat.add_comm,Nat.add_left_comm] using hn + have hd' : degree B ((p++[center B τ x])++q) ≠ 1 := by + simpa [mul_assoc] using hd + have heq := ih (p++[center B τ x]) hn' hd' + simp only [List.append_assoc,List.singleton_append] at heq + rw [List.map_cons,heq] + cases x with + | inr g => rfl + | inl b => + rw [center_replacement] + have hs := hshort (p++q) (by simp only [List.length_append,List.length_cons] at hn ⊢; omega) + (by simpa [degreeLetter] using hd) + simp only [hs,mul_zero,sub_zero] + simpa using h l [] (by simp) (by simpa using hl) + + + +theorem moment_eq_zero_of_degree_ne_one + (h1 : τ 1=1) (hu : ∀ g : G, g ≠ 1 → τ (u g)=0) + (hfree : FreeCoefficients B u τ) + (l : List (Letter B (G := G))) (hl : degree B l ≠ 1) : + τ (evaluate B u l)=0 := by + classical + suffices h : ∀ N : ℕ, ∀ k : List (Letter B (G := G)), k.length=N → + degree B k ≠ 1 → τ (evaluate B u k)=0 from h l.length l rfl hl + intro N + induction N using Nat.strong_induction_on with + | h N ih => + intro k hk hd + have H (t : List (Letter B (G := G))) (ht : t.length tag B x ≠ tag B y) + · have hkc : τ (evaluate B u (k.map (center B τ)))=0 := by + apply hfree + · rw [List.isChain_map] + simpa only [tag_center] using halt + · intro hnil + have hk0 : k=[] := List.map_eq_nil_iff.mp hnil + exact hd (by simp [hk0]) + · intro x hx + obtain ⟨y,hy,rfl⟩ := List.mem_map.mp hx + cases y with + | inl b => simp [center,value,map_sub,map_smul,h1] + | inr g => + apply hu + intro hg + exact hone (hg ▸ hy) + rw [center_moment B u τ k hd H] at hkc + exact hkc + · rw [List.isChain_iff_forall_rel_of_append_cons_cons] at halt + push Not at halt + obtain ⟨a,b,p,q,hk',hab⟩ := halt + subst k + cases a with + | inl a => + cases b with + | inl b => + have hz := H (p++Sum.inl (a*b)::q) (by simp) + (by simpa [degreeLetter,mul_assoc] using hd) + simpa [value,mul_assoc] using hz + | inr b => simp [tag] at hab + | inr a => + cases b with + | inl b => simp [tag] at hab + | inr b => + have hz := H (p++Sum.inr (a*b)::q) (by simp) + (by simpa [degreeLetter,mul_assoc] using hd) + simpa [value,map_mul,mul_assoc] using hz + +end HochschildFreeMoments +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FreeHaarFamilies.lean b/lean/OAI/Analysis/BoundedHochschild/FreeHaarFamilies.lean new file mode 100644 index 0000000000000000000000000000000000000000..46e9910d566bd38eb8479a173fc98049b8c27339 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FreeHaarFamilies.lean @@ -0,0 +1,309 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.AlternatingMoments +import OAI.Analysis.BoundedHochschild.PathWords + +namespace OAI + +/-! Free Haar extensions, graded families and finite free-group erasure. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open scoped BigOperators ComplexConjugate InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildUltrapower +open BoundedHochschild HochschildRigidity TracialUltrapower HochschildPatching HochschildComparison +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +def powerFamily {A : Type*} [CStarAlgebra A] (w : unitary A) : Multiplicative ℤ →* A := + (unitary A).subtype.comp (zpowersHom (unitary A) w) +@[simp] lemma powerFamily_apply {A : Type*} [CStarAlgebra A] (w : unitary A) (k : Multiplicative ℤ) : + powerFamily w k=((w^k.toAdd : unitary A):A) := rfl + +include e in +theorem exists_free_haar_extension + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + {G : Type*} [Group G] [Countable G] (ν : ℕ → G →* unitary M) : + ∃ w : ℕ → unitary M, + (∀ k : ℤ, k ≠ 0 → quotientTrace τ h1 ω htr + (((quotientUnitary τ h1 ω htr w)^k : unitary (Ultrapower τ h1 ω htr)) : Ultrapower τ h1 ω htr)=0) ∧ + ∀ l : List (G ⊕ Multiplicative ℤ), + l.IsChain (fun x y => HochschildGradedFree.tag x ≠ HochschildGradedFree.tag y) → l ≠ [] → + quotientTrace τ h1 ω htr + (HochschildGradedFree.centeredEval (quotientFamily τ h1 ω htr ν) + (powerFamily (quotientUnitary τ h1 ω htr w)) (quotientTrace τ h1 ω htr).toLinearMap l)=0 := by + have hnorm (g : G) (n : ℕ) : ‖boundedHom ν g n‖ ≤ 1 := by + have hh := CStarRing.norm_coe_unitary_mul (ν n g) (1:M) + simp only [mul_one] at hh + change ‖(ν n g:M)‖ ≤ 1 + rw [hh] + exact IsStarProjection.norm_le _ (IsStarProjection.one M) + obtain ⟨w,hw⟩ := exists_quotient_unitary_all_moments e τ hτ h1 htr hfaith hfactor hdiff ω hω + (fun g => boundedHom ν g) hnorm + let U := quotientFamily τ h1 ω htr ν + let W := quotientUnitary τ h1 ω htr w + let T := quotientTrace τ h1 ω htr + let F : G → Ultrapower τ h1 ω htr := fun g => U g-T (U g) • 1 + have hm (a : Option G) (l : List (IntAtom G)) (hl : admissibleIntTail l) + (hk : ∀ b ∈ l, b.1 ≠ 0) : T (integerEval F W a l)=0 := + integer_moments_of_bounded T F W hw a l hl hk + have hpower (k : ℤ) (hk : k ≠ 0) : T ((W^k : unitary (Ultrapower τ h1 ω htr)):Ultrapower τ h1 ω htr)=0 := by + have hh := hm none [(k,none)] ⟨by simp,by simp⟩ (by simpa using hk) + simpa only [integerEval,wordCoeff,List.map_cons,List.map_nil,List.prod_cons,List.prod_nil,mul_one,one_mul] using hh + refine ⟨w,hpower,fun l hc hl => ?_⟩ + let R : Multiplicative ℤ → Ultrapower τ h1 ω htr := fun h => powerFamily W h-T (powerFamily W h) • 1 + have hF (g : G) : T (F g)=0 := by + simp only [F,map_sub,map_smul,smul_eq_mul,quotientTrace_one,T,mul_one,sub_self] + have hR (h : Multiplicative ℤ) : R h=0 ∨ ∃ k : ℤ, k ≠ 0 ∧ R h=((W^k : unitary (Ultrapower τ h1 ω htr)):Ultrapower τ h1 ω htr) := by + by_cases hh : h.toAdd=0 + · left + simp [R,powerFamily_apply,hh,T,quotientTrace_one] + · right + exact ⟨h.toAdd,hh,by simp only [R,powerFamily_apply,hpower _ hh,zero_smul,sub_zero]⟩ + have hz := alternating_moment_zero T.toLinearMap F R W hF hR hm l hc hl + have he : HochschildGradedFree.centeredEval U (powerFamily W) T.toLinearMap l = + (l.map (Sum.elim F R)).prod := by + unfold HochschildGradedFree.centeredEval + congr 1 + apply List.map_congr_left + intro x hx + cases x <;> rfl + change T (HochschildGradedFree.centeredEval U (powerFamily W) T.toLinearMap l)=0 + rw [he] + exact hz + +end HochschildUltrapower + + + + + +namespace HochschildSplitWord +variable {A G H B : Type*} [Group G] [Group H] [Monoid B] +def invLetter : G ⊕ H → G ⊕ H := Sum.map Inv.inv Inv.inv +def signedLetter (f : A → G ⊕ H) (x : A × Bool) : G ⊕ H := + if x.2 then f x.1 else invLetter (f x.1) +def sumProduct (u : G →* B) (v : H →* B) (l : List (G ⊕ H)) : B := + (l.map (Sum.elim u v)).prod + +def splitWord [DecidableEq A] (f : A → G ⊕ H) (q : FreeGroup A) : List (G ⊕ H) := + q.toWord.map (signedLetter f) + +lemma hom_mk (σ : FreeGroup A →* B) (l : List (A × Bool)) : + σ (FreeGroup.mk l)=(l.map (fun x => if x.2 then σ (FreeGroup.of x.1) else σ ((FreeGroup.of x.1)⁻¹))).prod := by + conv_lhs => rw [← FreeGroup.lift_of_apply (FreeGroup.mk l),FreeGroup.lift_mk] + rw [map_list_prod,List.map_map] + congr 1 + apply List.map_congr_left + intro x hx + rcases x with ⟨a,b⟩ + cases b <;> rfl + +lemma sumProduct_splitWord [DecidableEq A] + (u : G →* B) (v : H →* B) (σ : FreeGroup A →* B) (f : A → G ⊕ H) + (hp : ∀ a, σ (FreeGroup.of a)=Sum.elim u v (f a)) + (hn : ∀ a, σ ((FreeGroup.of a)⁻¹)=Sum.elim u v (invLetter (f a))) (q : FreeGroup A) : + sumProduct u v (splitWord f q)=σ q := by + conv_rhs => rw [← FreeGroup.mk_toWord (x := q),hom_mk] + simp only [sumProduct,splitWord,List.map_map] + congr 1 + apply List.map_congr_left + intro x hx + cases hb : x.2 <;> simp only [Function.comp_apply,signedLetter,hb,Bool.false_eq_true,ite_false,ite_true] + · exact (hn x.1).symm + · exact (hp x.1).symm + +lemma sumProduct_splitWord_group {B : Type*} [Group B] [DecidableEq A] + (u : G →* B) (v : H →* B) (σ : FreeGroup A →* B) (f : A → G ⊕ H) + (hp : ∀ a, σ (FreeGroup.of a)=Sum.elim u v (f a)) (q : FreeGroup A) : + sumProduct u v (splitWord f q)=σ q := by + apply sumProduct_splitWord u v σ f hp + intro a + rw [map_inv,hp] + cases h : f a <;> simp [invLetter,Sum.elim,map_inv] +end HochschildSplitWord + + + + + +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildUltrapower +open BoundedHochschild HochschildRigidity HochschildPatching HochschildComparison HochschildSplitWord +variable {C D : Type*} [DecidableEq D] +def gradedDegree (s : Finset D) : FreeGroup (C ⊕ D) →* FreeGroup D := + FreeGroup.lift (Sum.elim (fun _ => 1) (fun d => if d ∈ s then FreeGroup.of d else 1)) +@[simp] lemma gradedDegree_left (s : Finset D) (c : C) : gradedDegree s (FreeGroup.of (Sum.inl c))=1 := by + simp [gradedDegree] +@[simp] lemma gradedDegree_right (s : Finset D) (d : D) : + gradedDegree (C := C) s (FreeGroup.of (Sum.inr d))=if d ∈ s then FreeGroup.of d else 1 := by + simp [gradedDegree] +@[simp] lemma gradedDegree_empty (q : FreeGroup (C ⊕ D)) : gradedDegree ∅ q=1 := by + have hhom : gradedDegree (C := C) (∅:Finset D)=1 := by + apply FreeGroup.ext_hom + intro x + cases x <;> simp + rw [hhom] + rfl + +def splitNew (d : D) : C ⊕ D → FreeGroup (C ⊕ D) ⊕ Multiplicative ℤ := + Sum.elim (fun c => Sum.inl (FreeGroup.of (Sum.inl c))) + (fun j => if j=d then Sum.inr (Multiplicative.ofAdd 1) else Sum.inl (FreeGroup.of (Sum.inr j))) + +lemma degree_splitNew (s : Finset D) (d : D) (x : C ⊕ D) : + gradedDegree (insert d s) (FreeGroup.of x)= + Sum.elim (gradedDegree s) (zpowersHom (FreeGroup D) (FreeGroup.of d)) (splitNew d x) := by + cases x with + | inl c => simp [splitNew] + | inr j => + by_cases hj : j=d + · subst j; simp [splitNew,zpowersHom] + · simp [splitNew,hj] + +lemma powerFamily_star {A : Type*} [CStarAlgebra A] (w : unitary A) (h : Multiplicative ℤ) : + star (powerFamily w h)=powerFamily w h⁻¹ := by + change star ((w^h.toAdd : unitary A):A)=((w^(-h.toAdd) : unitary A):A) + rw [zpow_neg,← Unitary.coe_star,Unitary.star_eq_inv] + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable (τ : M →ₚ[ℂ] ℂ) (h1 : τ 1=1) (ω : Ultrafilter ℕ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) +def mixedFamily (v : C → unitary M) (u : D → unitary M) : FreeGroup (C ⊕ D) →* unitary M := + FreeGroup.lift (Sum.elim v u) + +def updateFamily (u : ℕ → D → unitary M) (w : ℕ → unitary M) (d : D) : ℕ → D → unitary M := + fun n j => if j=d then w n else u n j + +lemma mixedFamily_splitNew (v : C → unitary M) (u : ℕ → D → unitary M) (w : ℕ → unitary M) + (d : D) (x : C ⊕ D) : + quotientFamily τ h1 ω htr (fun n => mixedFamily v (updateFamily u w d n)) (FreeGroup.of x)= + Sum.elim (quotientFamily τ h1 ω htr (fun n => mixedFamily v (u n))) + (powerFamily (quotientUnitary τ h1 ω htr w)) (splitNew d x) := by + cases x with + | inl c => + change quotientHom τ h1 ω htr (boundedHom _ (FreeGroup.of (Sum.inl c)))= + quotientHom τ h1 ω htr (boundedHom _ (FreeGroup.of (Sum.inl c))) + congr 1 + | inr j => + by_cases hj : j=d + · subst j + simp only [splitNew,Sum.elim_inr,ite_true,powerFamily_apply] + change _ = (((quotientUnitary τ h1 ω htr w) ^ (1:ℤ) : unitary (Ultrapower τ h1 ω htr)) : Ultrapower τ h1 ω htr) + rw [zpow_one] + change quotientHom τ h1 ω htr (boundedHom _ (FreeGroup.of (Sum.inr d)))= + quotientHom τ h1 ω htr (unitarySequence w) + congr 1 + ext n + simp [mixedFamily,updateFamily] + · simp only [splitNew,Sum.elim_inr,hj,ite_false,Sum.elim_inl] + change quotientHom τ h1 ω htr (boundedHom _ (FreeGroup.of (Sum.inr j)))= + quotientHom τ h1 ω htr (boundedHom _ (FreeGroup.of (Sum.inr j))) + congr 1 + ext n + simp [mixedFamily,updateFamily,hj] + +lemma mixedFamily_splitNew_inv (v : C → unitary M) (u : ℕ → D → unitary M) (w : ℕ → unitary M) + (d : D) (x : C ⊕ D) : + quotientFamily τ h1 ω htr (fun n => mixedFamily v (updateFamily u w d n)) ((FreeGroup.of x)⁻¹)= + Sum.elim (quotientFamily τ h1 ω htr (fun n => mixedFamily v (u n))) + (powerFamily (quotientUnitary τ h1 ω htr w)) (invLetter (splitNew d x)) := by + rw [← quotientFamily_star,mixedFamily_splitNew] + cases h : splitNew d x with + | inl g => exact quotientFamily_star τ h1 ω htr _ g + | inr k => exact powerFamily_star _ k +end HochschildUltrapower + + + + + +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildUltrapower +open BoundedHochschild HochschildRigidity HochschildPatching HochschildComparison HochschildSplitWord +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in + + +theorem exists_finite_graded_family + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + {C D : Type*} [Countable C] [Countable D] [DecidableEq D] + (v : C → unitary M) (s : Finset D) : + ∃ u : ℕ → D → unitary M, ∀ q : FreeGroup (C ⊕ D), gradedDegree s q ≠ 1 → + quotientTrace τ h1 ω htr (quotientFamily τ h1 ω htr (fun n => mixedFamily v (u n)) q)=0 := by + classical + induction s using Finset.induction_on with + | empty => + refine ⟨fun _ _ => 1,fun q hq => ?_⟩ + exact (hq (gradedDegree_empty q)).elim + | @insert d s hd ih => + obtain ⟨u,hu⟩ := ih + let ν : ℕ → FreeGroup (C ⊕ D) →* unitary M := fun n => mixedFamily v (u n) + obtain ⟨w,hpower,hfree⟩ := exists_free_haar_extension e τ hτ h1 htr hfaith hfactor hdiff ω hω ν + refine ⟨updateFamily u w d,fun q hq => ?_⟩ + let U := quotientFamily τ h1 ω htr ν + let W := quotientUnitary τ h1 ω htr w + let V := powerFamily W + let T := quotientTrace τ h1 ω htr + let β := zpowersHom (FreeGroup D) (FreeGroup.of d) + let l := splitWord (splitNew (C := C) d) q + have hev : sumProduct U V l= + quotientFamily τ h1 ω htr (fun n => mixedFamily v (updateFamily u w d n)) q := + sumProduct_splitWord U V _ (splitNew d) + (mixedFamily_splitNew τ h1 ω htr v u w d) + (mixedFamily_splitNew_inv τ h1 ω htr v u w d) q + have hdeg : HochschildGradedFree.degree (gradedDegree s) β l=gradedDegree (insert d s) q := + sumProduct_splitWord_group (gradedDegree s) β (gradedDegree (insert d s)) (splitNew d) + (degree_splitNew s d) q + have hβ (k : Multiplicative ℤ) (hk : β k ≠ 1) : T (V k)=0 := by + apply hpower k.toAdd + intro hzero + apply hk + simp [β,zpowersHom,hzero] + have hz := HochschildGradedFree.moment_eq_zero_of_degree_ne_one U V (gradedDegree s) β T.toLinearMap + (quotientTrace_tracial τ h1 ω htr) hu hβ hfree l (fun hh => hq (hdeg.symm.trans hh)) + change T (sumProduct U V l)=0 at hz + rw [hev] at hz + exact hz + +end HochschildUltrapower +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/FreeWords.lean b/lean/OAI/Analysis/BoundedHochschild/FreeWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..d96a0dddb900990dfdcd1a895f2140f823d5d117 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/FreeWords.lean @@ -0,0 +1,406 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.ProductTaylor + +namespace OAI + +/-! Reduced free words, cancellation fibers and repeated-letter bounds. -/ + +noncomputable section + + +namespace HochschildFreeWords +variable {α : Type*} +def charge (a : α × Bool) : ℤ := if a.2 then 1 else -1 +@[simp] theorem charge_true (a : α) : charge (a, true) = 1 := rfl +@[simp] theorem charge_false (a : α) : charge (a, false) = -1 := rfl +@[simp] theorem charge_not (a : α) (b : Bool) : + charge (a, b) + charge (a, !b) = 0 := by cases b <;> rfl +def total (l : List (α × Bool)) : ℤ := (l.map charge).sum +@[simp] theorem total_nil : total ([] : List (α × Bool)) = 0 := rfl +@[simp] theorem total_cons (a : α × Bool) (l : List (α × Bool)) : + total (a :: l) = charge a + total l := by simp [total] +@[simp] theorem total_append (l k : List (α × Bool)) : + total (l ++ k) = total l + total k := by simp [total] +@[simp] theorem total_reverse (l : List (α × Bool)) : total l.reverse = total l := by + simp [total, List.map_reverse] + +def Above (h : ℤ) : List (α × Bool) → Prop + | [] => 0 ≤ h + | a :: l => 0 ≤ h ∧ Above (h + charge a) l +@[simp] theorem above_nil (h : ℤ) : Above h ([] : List (α × Bool)) ↔ 0 ≤ h := Iff.rfl +@[simp] theorem above_cons (h : ℤ) (a : α × Bool) (l : List (α × Bool)) : + Above h (a :: l) ↔ 0 ≤ h ∧ Above (h + charge a) l := Iff.rfl +lemma above_start {h : ℤ} {l : List (α × Bool)} (hl : Above h l) : 0 ≤ h := by + cases l with + | nil => exact hl + | cons a l => exact hl.1 +lemma above_mono {h k : ℤ} (hh : h ≤ k) {l : List (α × Bool)} + (hl : Above h l) : Above k l := by + induction l generalizing h k with + | nil => exact hl.trans hh + | cons a l ih => exact ⟨hl.1.trans hh, ih (by omega) hl.2⟩ +lemma above_append (h : ℤ) (l k : List (α × Bool)) : + Above h (l ++ k) ↔ Above h l ∧ Above (h + total l) k := by + induction l generalizing h with + | nil => simpa using (fun hh : Above h k => above_start hh) + | cons a l ih => + simp only [List.cons_append, above_cons, ih, total_cons] + constructor + · rintro ⟨hh, hl, hk⟩ + exact ⟨⟨hh, hl⟩, by convert hk using 1; omega⟩ + · rintro ⟨⟨hh, hl⟩, hk⟩ + exact ⟨hh, hl, by convert hk using 1; omega⟩ +lemma above_cancel (h : ℤ) (l k : List (α × Bool)) (a : α) (b : Bool) + (hw : Above h (l ++ (a,b) :: (a,!b) :: k)) : Above h (l ++ k) := by + rw [above_append] at hw ⊢ + refine ⟨hw.1, ?_⟩ + have hk := hw.2.2.2 + convert hk using 1 + have := charge_not a b + omega +lemma total_step {l k : List (α × Bool)} (h : FreeGroup.Red.Step l k) : + total l = total k := by + cases h with + | @not l k a b => + simp only [total_append, total_cons] + have := charge_not a b + omega +lemma above_step {h : ℤ} {l k : List (α × Bool)} (hr : FreeGroup.Red.Step l k) + (hl : Above h l) : Above h k := by + cases hr + exact above_cancel _ _ _ _ _ hl +lemma above_reverse_step {h : ℤ} {l k : List (α × Bool)} + (hr : FreeGroup.Red.Step l k) (hl : Above h l.reverse) : Above h k.reverse := by + cases hr with + | @not l k a b => + simp only [List.reverse_append, List.reverse_cons, List.append_assoc] at hl ⊢ + have hh : Above h (k.reverse ++ (a,!b) :: (a,!(!b)) :: l.reverse) := by + simpa using hl + exact above_cancel _ _ _ _ _ hh +lemma above_red {h : ℤ} {l k : List (α × Bool)} (hr : FreeGroup.Red l k) + (hl : Above h l) : Above h k := by + induction hr with + | refl => exact hl + | tail hr hs ih => exact above_step hs ih +lemma above_reverse_red {h : ℤ} {l k : List (α × Bool)} (hr : FreeGroup.Red l k) + (hl : Above h l.reverse) : Above h k.reverse := by + induction hr with + | refl => exact hl + | tail hr hs ih => exact above_reverse_step hs ih +lemma total_red {l k : List (α × Bool)} (hr : FreeGroup.Red l k) : total l = total k := by + induction hr with + | refl => rfl + | tail hr hs ih => exact ih.trans (total_step hs) +lemma above_head {l : List (α × Bool)} (hl : Above 0 l) (hne : l ≠ []) : + l.head?.map Prod.snd = some true := by + cases l with + | nil => exact (hne rfl).elim + | cons a l => + obtain ⟨a,b⟩ := a + have hh := above_start hl.2 + cases b with + | false => simp [charge] at hh + | true => rfl + +inductive OddBlock : List (α × Bool) → Prop + | one (a : α) : OddBlock [(a,true)] + | step (a b : α) {l : List (α × Bool)} : OddBlock l → + OddBlock ((a,true)::(b,false)::l) +lemma OddBlock.total {l : List (α × Bool)} (hl : OddBlock l) : total l = 1 := by + induction hl with + | one a => simp + | step a b hl ih => simp [ih] +lemma OddBlock.above {l : List (α × Bool)} (hl : OddBlock l) : Above 0 l := by + induction hl with + | one a => simp [Above] + | step a b hl ih => simpa [Above] using ih +lemma OddBlock.above_reverse {l : List (α × Bool)} (hl : OddBlock l) : + Above 0 l.reverse := by + induction hl with + | one a => simp [Above] + | @step a b l hl ih => + simp only [List.reverse_cons, List.append_assoc] + rw [above_append] + exact ⟨ih, by simp [hl.total, Above]⟩ +lemma blocks_total (ls : List (List (α × Bool))) (h : ∀ l ∈ ls, OddBlock l) : + total ls.flatten = ls.length := by + induction ls with + | nil => simp + | cons l ls ih => + simp only [List.flatten_cons, total_append, List.length_cons, Nat.cast_add, Nat.cast_one] + rw [(h l (by simp)).total, ih (fun k hk => h k (by simp [hk]))] + omega +lemma blocks_above (ls : List (List (α × Bool))) (h : ∀ l ∈ ls, OddBlock l) : + Above 0 ls.flatten ∧ Above 0 ls.flatten.reverse := by + induction ls with + | nil => simp + | cons l ls ih => + have hl := h l (by simp) + have ht := fun k hk => h k (List.mem_cons_of_mem l hk) + obtain ⟨hp, hs⟩ := ih ht + simp only [List.flatten_cons, List.reverse_append, above_append] + refine ⟨⟨hl.above, above_mono ?_ hp⟩, ⟨hs, above_mono ?_ hl.above_reverse⟩⟩ + · rw [hl.total]; omega + · rw [total_reverse, blocks_total ls ht]; positivity + + +theorem ordered_blocks_reduced [DecidableEq α] + (ls : List (List (α × Bool))) (hne : ls ≠ []) (h : ∀ l ∈ ls, OddBlock l) : + let w := FreeGroup.reduce ls.flatten + w ≠ [] ∧ w.head?.map Prod.snd = some true ∧ + w.reverse.head?.map Prod.snd = some true := by + dsimp + have ht := total_red (FreeGroup.reduce.red (L := ls.flatten)) + rw [blocks_total ls h] at ht + have hn : FreeGroup.reduce ls.flatten ≠ [] := by + intro hz + rw [hz, total_nil] at ht + have : ls.length = 0 := by exact_mod_cast ht + exact hne (List.length_eq_zero_iff.mp this) + obtain ⟨hp, hs⟩ := blocks_above ls h + exact ⟨hn, above_head (above_red FreeGroup.reduce.red hp) hn, + above_head (above_reverse_red FreeGroup.reduce.red hs) (by simpa)⟩ +end HochschildFreeWords + +namespace HochschildFreeWords +open Finset +variable {α : Type*} + +def insertPair (w : List (α × Bool)) (i : ℕ) (x : α × Bool) : List (α × Bool) := + w.take i ++ x :: (x.1, !x.2) :: w.drop i +@[simp] theorem length_insertPair (w : List (α × Bool)) (i : ℕ) (x : α × Bool) : + (insertPair w i x).length = w.length + 2 := by + simp only [insertPair, List.length_append, List.length_cons, List.length_take, + List.length_drop] + omega +lemma insertPair_append (l k : List (α × Bool)) (a : α) (b : Bool) : + insertPair (l ++ k) l.length (a,b) = l ++ (a,b) :: (a,!b) :: k := by + simp [insertPair] +variable [DecidableEq α] [Fintype α] + + +def expansions : ℕ → List (α × Bool) → Finset (List (α × Bool)) + | 0, w => {w} + | p+1, w => (expansions p w).biUnion fun v => + (range (v.length + 1)).biUnion fun i => univ.image (insertPair v i) +lemma mem_expansions_length {p : ℕ} {v w : List (α × Bool)} + (hv : v ∈ expansions p w) : v.length = w.length + 2*p := by + induction p generalizing v with + | zero => + simp only [expansions, mem_singleton] at hv + simp [hv] + | succ p ih => + simp only [expansions, mem_biUnion, mem_image, mem_univ, true_and] at hv + obtain ⟨u, hu, i, hi, x, rfl⟩ := hv + rw [length_insertPair, ih hu] + omega +lemma expansions_insert {p : ℕ} {v w : List (α × Bool)} (hv : v ∈ expansions p w) + (i : ℕ) (hi : i ≤ v.length) (x : α × Bool) : + insertPair v i x ∈ expansions (p+1) w := by + simp only [expansions, mem_biUnion, mem_image, mem_univ, true_and] + exact ⟨v, hv, i, by simpa using hi, x, rfl⟩ +lemma red_mem_expansions {v w : List (α × Bool)} (h : FreeGroup.Red v w) : + ∃ p, v.length = w.length + 2*p ∧ v ∈ expansions p w := by + induction h using Relation.ReflTransGen.head_induction_on with + | refl => exact ⟨0, by omega, by simp [expansions]⟩ + | @head v u hs hr ih => + obtain ⟨p, hp, hm⟩ := ih + refine ⟨p+1, ?_, ?_⟩ + · have := hs.length; omega + · cases hs with + | @not l k a b => + simpa only [insertPair_append] using + expansions_insert hm l.length (by simp) (a,b) +lemma mem_expansions_of_reduce {v w : List (α × Bool)} (h : FreeGroup.reduce v = w) : + v ∈ expansions ((v.length-w.length)/2) w := by + obtain ⟨p, hp, hm⟩ := red_mem_expansions (h ▸ FreeGroup.reduce.red (L := v)) + have : (v.length - w.length) / 2 = p := by omega + simpa only [this] using hm +lemma card_expansions_succ (p : ℕ) (w : List (α × Bool)) : + (expansions (p+1) w).card ≤ + (expansions p w).card * (w.length + 2*p + 1) * (2 * Fintype.card α) := by + conv_lhs => unfold expansions + apply (card_biUnion_le).trans + calc + _ ≤ ∑ v ∈ expansions p w, (w.length + 2*p + 1) * (2 * Fintype.card α) := by + apply sum_le_sum + intro v hv + apply card_biUnion_le.trans + calc + _ ≤ ∑ _i ∈ range (v.length+1), Fintype.card (α × Bool) := by + apply sum_le_sum + intro i hi + exact card_image_le + _ = _ := by + rw [mem_expansions_length hv] + simp [Nat.mul_comm, Nat.mul_left_comm] + _ = _ := by simp [Nat.mul_assoc] + + +theorem card_expansions_le (p : ℕ) (w : List (α × Bool)) : + (expansions p w).card ≤ (2 * (w.length + 2*p)) ^ p * (Fintype.card α) ^ p := by + induction p with + | zero => simp [expansions] + | succ p ih => + calc + _ ≤ (expansions p w).card * (w.length+2*p+1) * (2 * Fintype.card α) := + card_expansions_succ p w + _ ≤ ((2 * (w.length+2*p)) ^ p * (Fintype.card α)^p) * + (w.length+2*p+1) * (2 * Fintype.card α) := by gcongr + _ ≤ ((2 * (w.length+2*(p+1))) ^ p * (Fintype.card α)^p) * + (w.length+2*(p+1)) * (2 * Fintype.card α) := by + exact Nat.mul_le_mul_right _ (Nat.mul_le_mul + (Nat.mul_le_mul_right _ (Nat.pow_le_pow_left (by omega) p)) (by omega)) + _ = _ := by rw [pow_succ, pow_succ]; ring + +theorem reduction_fiber_bound (S : Finset (List (α × Bool))) + (L : ℕ) (w : List (α × Bool)) (hne : S.Nonempty) + (hS : ∀ v ∈ S, v.length = L ∧ FreeGroup.reduce v = w) : + ∃ p, L = w.length + 2*p ∧ + S.card ≤ (2*L)^p * (Fintype.card α)^p := by + obtain ⟨v, hv⟩ := hne + obtain ⟨p, hp, _⟩ := red_mem_expansions + ((hS v hv).2 ▸ FreeGroup.reduce.red (L := v)) + rw [(hS v hv).1] at hp + refine ⟨p, hp, ?_⟩ + have hsub : S ⊆ expansions p w := by + intro u hu + have he := mem_expansions_of_reduce (hS u hu).2 + rw [(hS u hu).1] at he + have : (L-w.length)/2 = p := by omega + simpa only [this] using he + exact (card_le_card hsub).trans (by simpa only [← hp] using card_expansions_le p w) + + + +theorem normalized_reduction_fiber_bound (S : Finset (List (α × Bool))) + (L : ℕ) (w : List (α × Bool)) + (hS : ∀ v ∈ S, v.length = L ∧ FreeGroup.reduce v = w) + (hr : 0 < Fintype.card α) : + (S.card : ℝ) / (Real.sqrt (Fintype.card α))^L ≤ + ((2 * (L+1) : ℕ)^L : ℝ) / (Real.sqrt (Fintype.card α))^w.length := by + have hrreal : 0 < (Fintype.card α : ℝ) := by exact_mod_cast hr + have hsqrt : 0 < Real.sqrt (Fintype.card α) := Real.sqrt_pos.mpr hrreal + have hsqrt2 := Real.sq_sqrt hrreal.le + by_cases hempty : S = ∅ + · simp only [hempty, card_empty, Nat.cast_zero, zero_div] + positivity + obtain ⟨p, hp, hb⟩ := reduction_fiber_bound S L w + (Finset.nonempty_iff_ne_empty.mpr hempty) hS + have hpL : p ≤ L := by omega + have hconst : (2*L)^p ≤ (2*(L+1))^L := + (Nat.pow_le_pow_left (by omega) p).trans (Nat.pow_le_pow_right (by omega) hpL) + have hcount : (S.card : ℝ) ≤ ((2*(L+1))^L : ℕ) * (Fintype.card α : ℝ)^p := by + exact_mod_cast hb.trans (Nat.mul_le_mul_right _ hconst) + have hpow : (Real.sqrt (Fintype.card α))^L = + (Real.sqrt (Fintype.card α))^w.length * (Fintype.card α : ℝ)^p := by + rw [hp, pow_add, pow_mul, hsqrt2] + rw [hpow] + apply (div_le_div_iff₀ (mul_pos (pow_pos hsqrt _) (pow_pos hrreal _)) + (pow_pos hsqrt _)).mpr + calc + _ ≤ (((2*(L+1))^L : ℕ) * (Fintype.card α : ℝ)^p) * + (Real.sqrt (Fintype.card α))^w.length := + mul_le_mul_of_nonneg_right hcount (pow_nonneg hsqrt.le w.length) + _ = _ := by push_cast; ring +end HochschildFreeWords +namespace HochschildFreeWords +open Finset +variable {α : Type*} [DecidableEq α] [Fintype α] +def allWords : ℕ → Finset (List (α × Bool)) + | 0 => {[]} + | n+1 => ((univ : Finset (α × Bool)) ×ˢ allWords n).image + (fun p => p.1 :: p.2) +omit [DecidableEq α] [Fintype α] in +lemma cons_pair_injective : Function.Injective (fun p : (α × Bool) × List (α × Bool) => + p.1 :: p.2) := by + rintro ⟨a,l⟩ ⟨b,k⟩ h + simp only [List.cons.injEq] at h + exact Prod.ext h.1 h.2 +lemma mem_allWords {w : List (α × Bool)} {n : ℕ} : + w ∈ allWords n ↔ w.length = n := by + induction n generalizing w with + | zero => simp [allWords] + | succ n ih => + cases w with + | nil => simp [allWords] + | cons a l => simp [allWords, ih] +lemma card_allWords (n : ℕ) : (allWords (α := α) n).card = + (2 * Fintype.card α)^n := by + induction n with + | zero => simp [allWords] + | succ n ih => + rw [allWords, card_image_of_injective _ cons_pair_injective, card_product, ih] + simp [pow_succ, Nat.mul_comm] +def badWords (n : ℕ) : Finset (List (α × Bool)) := + (allWords n).filter fun w => ¬ (w.map Prod.fst).Nodup +lemma mem_badWords {w : List (α × Bool)} {n : ℕ} : + w ∈ badWords n ↔ w.length = n ∧ ¬ (w.map Prod.fst).Nodup := by + simp [badWords, mem_allWords] +lemma card_badWords_one : (badWords (α := α) 1).card = 0 := by + rw [card_eq_zero] + apply eq_empty_iff_forall_notMem.mpr + intro w hw + obtain ⟨hl, hn⟩ := mem_badWords.mp hw + obtain ⟨a,rfl⟩ := List.length_eq_one_iff.mp hl + simp at hn +lemma card_badWords_succ (n : ℕ) : + (badWords (α := α) (n+1)).card ≤ + (2 * Fintype.card α) * (badWords (α := α) n).card + + (2 * n) * (2 * Fintype.card α)^n := by + let A := ((univ : Finset (α × Bool)) ×ˢ badWords n).image + (fun p => p.1 :: p.2) + let B := (allWords (α := α) n).biUnion fun w => + ((w.map Prod.fst).toFinset ×ˢ (univ : Finset Bool)).image fun p => p :: w + have hsub : badWords (α := α) (n+1) ⊆ A ∪ B := by + intro w hw + obtain ⟨hl, hn⟩ := mem_badWords.mp hw + cases w with + | nil => simp at hl + | cons a w => + have hwlen : w.length = n := by simpa using hl + simp only [List.map_cons, List.nodup_cons, not_and_or] at hn + rcases hn with hhead | htail + · apply mem_union_right + simp only [B, mem_biUnion, mem_image, mem_product, List.mem_toFinset, + mem_univ, and_true] + exact ⟨w, mem_allWords.mpr hwlen, a, by simpa only [not_not] using hhead, rfl⟩ + · apply mem_union_left + simp only [A, mem_image, mem_product, mem_univ, true_and] + exact ⟨(a,w), mem_badWords.mpr ⟨hwlen, htail⟩, rfl⟩ + have hA : A.card ≤ (2 * Fintype.card α) * (badWords (α := α) n).card := by + exact card_image_le.trans (by simp [card_product, Nat.mul_comm]) + have hB : B.card ≤ (2*n) * (2 * Fintype.card α)^n := by + apply card_biUnion_le.trans + calc + _ ≤ ∑ _w ∈ allWords (α := α) n, n*2 := by + apply sum_le_sum + intro w hw + apply card_image_le.trans + rw [card_product, card_univ, Fintype.card_bool] + gcongr + exact (List.toFinset_card_le _).trans_eq (by simpa using mem_allWords.mp hw) + _ = _ := by simp [card_allWords, Nat.mul_comm] + exact (card_le_card hsub).trans ((card_union_le A B).trans (Nat.add_le_add hA hB)) + +theorem card_badWords_le (n : ℕ) : + (badWords (α := α) (n+1)).card ≤ + (n+1).choose 2 * 2^(n+1) * (Fintype.card α)^n := by + induction n with + | zero => simp [card_badWords_one] + | succ n ih => + calc + _ ≤ (2 * Fintype.card α) * (badWords (α := α) (n+1)).card + + (2*(n+1)) * (2 * Fintype.card α)^(n+1) := card_badWords_succ (n+1) + _ ≤ (2 * Fintype.card α) * ((n+1).choose 2 * 2^(n+1) * (Fintype.card α)^n) + + (2*(n+1)) * (2 * Fintype.card α)^(n+1) := by gcongr + _ = _ := by + have hc : (n+1+1).choose 2 = (n+1) + (n+1).choose 2 := by + exact Nat.choose_succ_succ (n+1) 1 |>.trans (by simp) + rw [hc] + simp only [mul_pow, pow_succ] + ring +end HochschildFreeWords +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Haagerup.lean b/lean/OAI/Analysis/BoundedHochschild/Haagerup.lean new file mode 100644 index 0000000000000000000000000000000000000000..527c399eb36011c6f7f2e4f2d4beab31e20f223c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Haagerup.lean @@ -0,0 +1,605 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MomentNorms + +namespace OAI + +/-! Free-group convolution bounds and transfer of Haagerup estimates to tracial algebras. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildLength +open Finset FreeGroup +noncomputable section +variable {α : Type*} [Fintype α] [DecidableEq α] +abbrev Word (α : Type*) := List (α × Bool) +def words : ℕ → Finset (Word α) + | 0 => {[]} + | n+1 => ((univ : Finset (α × Bool)) ×ˢ words n).image (fun p => p.1 :: p.2) +@[simp] lemma mem_words {w : Word α} {n : ℕ} : w ∈ words n ↔ w.length = n := by + induction n generalizing w with + | zero => simp [words] + | succ n ih => + cases w with + | nil => simp [words] + | cons a l => simp [words, ih] +def wordBall (N : ℕ) : Finset (Word α) := (range (N+1)).biUnion words +@[simp] lemma mem_wordBall {w : Word α} {N : ℕ} : w ∈ wordBall N ↔ w.length ≤ N := by + simp only [wordBall, mem_biUnion, mem_range, mem_words] + constructor + · rintro ⟨n, hn, rfl⟩; omega + · intro h; exact ⟨w.length, by omega, rfl⟩ + +omit [Fintype α] in +lemma reduced_boundary_product (u v h : Word α) (hr : IsReduced (u ++ h)) : + reduce ((u ++ v) ++ (invRev v ++ h)) = u ++ h := by + have heq : FreeGroup.mk ((u ++ v) ++ (invRev v ++ h)) = FreeGroup.mk (u ++ h) := by + simp only [← FreeGroup.mul_mk, ← FreeGroup.inv_mk] + group + have ht := congr_arg FreeGroup.toWord heq + simpa only [FreeGroup.toWord_mk, hr.reduce_eq] using ht + +omit [Fintype α] in + +lemma boundary_unique {u v h u' v' h' : Word α} + (hr : IsReduced (u ++ h)) (hr' : IsReduced (u' ++ h')) + (hw : u ++ v = u' ++ v') (hx : invRev v ++ h = invRev v' ++ h') : + u = u' ∧ v = v' ∧ h = h' := by + have hout : u ++ h = u' ++ h' := by + rw [← reduced_boundary_product u v h hr, hw, hx, + reduced_boundary_product u' v' h' hr'] + have hwL := congrArg List.length hw + have hxL := congrArg List.length hx + have hyL := congrArg List.length hout + simp only [List.length_append, invRev_length] at hwL hxL hyL + have hvL : v.length = v'.length := by omega + have hu : u = u' := List.append_inj_left' hw hvL + subst u' + have hv : v = v' := List.append_cancel_left hw + subst v' + exact ⟨rfl, rfl, List.append_cancel_left hx⟩ + +omit [Fintype α] [DecidableEq α] in +lemma append_injOn {su sv : Finset (Word α)} {l : ℕ} + (hU : ∀ u ∈ su, u.length = l) : + Set.InjOn (fun p : Word α × Word α => p.1 ++ p.2) (↑(su ×ˢ sv) : Set _) := by + rintro ⟨u,v⟩ hp ⟨u',v'⟩ hp' h + have hp₁ : u ∈ su ∧ v ∈ sv := by simpa only [mem_coe, mem_product] using hp + have hp₂ : u' ∈ su ∧ v' ∈ sv := by simpa only [mem_coe, mem_product] using hp' + have hu : u = u' := List.append_inj_left h + ((hU u hp₁.1).trans (hU u' hp₂.1).symm) + subst u' + exact Prod.ext rfl (List.append_cancel_left h) + +omit [Fintype α] [DecidableEq α] in +lemma invRev_append_injOn {sv sh : Finset (Word α)} {l : ℕ} + (hV : ∀ v ∈ sv, v.length = l) : + Set.InjOn (fun p : Word α × Word α => invRev p.1 ++ p.2) (↑(sv ×ˢ sh) : Set _) := by + rintro ⟨v,h⟩ hp ⟨v',h'⟩ hp' hh + have hp₁ : v ∈ sv ∧ h ∈ sh := by simpa only [mem_coe, mem_product] using hp + have hp₂ : v' ∈ sv ∧ h' ∈ sh := by simpa only [mem_coe, mem_product] using hp' + have hv : invRev v = invRev v' := List.append_inj_left hh (by + simp only [invRev_length] + exact (hV v hp₁.1).trans (hV v' hp₂.1).symm) + have hv' : v = v' := by simpa using congrArg invRev hv + subst v' + exact Prod.ext rfl (List.append_cancel_left hh) + +omit [Fintype α] [DecidableEq α] in +lemma sum_sq_comp_le {I J : Type*} [DecidableEq J] + (si : Finset I) (sj : Finset J) (out : I → J) (c : J → ℂ) + (hinj : Set.InjOn out si) (hzero : ∀ i ∈ si, out i ∉ sj → c (out i) = 0) : + ∑ i ∈ si, ‖c (out i)‖ ^ 2 ≤ ∑ j ∈ sj, ‖c j‖ ^ 2 := by + classical + let ss := si.filter (fun i => out i ∈ sj) + have heq : ∑ i ∈ si, ‖c (out i)‖ ^ 2 = ∑ i ∈ ss, ‖c (out i)‖ ^ 2 := by + symm + apply sum_subset (filter_subset _ _) + intro i hi hnot + have hz : c (out i) = 0 := hzero i hi (by + intro hh; exact hnot (mem_filter.mpr ⟨hi,hh⟩)) + simp [hz] + rw [heq, ← sum_image (f := fun j => ‖c j‖ ^ 2) (s := ss) + (hinj.mono (by exact filter_subset _ _))] + apply sum_le_sum_of_subset_of_nonneg + · intro j hj + obtain ⟨i, hi, rfl⟩ := mem_image.mp hj + exact (mem_filter.mp hi).2 + · intros; positivity + +lemma coefficient_energy_le (q t : ℕ) (ht : t ≤ q) (c : Word α → ℂ) : + ∑ u ∈ words (q-t), ∑ v ∈ words t, ‖c (u ++ v)‖ ^ 2 ≤ + ∑ w ∈ words q, ‖c w‖ ^ 2 := by + have hb := sum_sq_comp_le (words (α := α) (q-t) ×ˢ words t) (words q) + (fun p : Word α × Word α => p.1 ++ p.2) c (append_injOn (l := q-t) (by simp)) (by + intro p hp hn + have hh : p.1.length = q-t ∧ p.2.length = t := by simpa using hp + exact (hn (by simp [hh, Nat.sub_add_cancel ht])).elim) + simpa only [sum_product] using hb + +lemma input_energy_le (N t : ℕ) (f : Word α → ℂ) + (hf : ∀ w, N < w.length → f w = 0) : + ∑ h ∈ wordBall N, ∑ v ∈ words t, ‖f (invRev v ++ h)‖ ^ 2 ≤ + ∑ x ∈ wordBall N, ‖f x‖ ^ 2 := by + have hb := sum_sq_comp_le (words (α := α) t ×ˢ wordBall N) (wordBall N) + (fun p : Word α × Word α => invRev p.1 ++ p.2) f + (invRev_append_injOn (l := t) (by simp)) (by + intro p _ hp + exact hf _ (by simpa using hp)) + rw [sum_comm] + simpa only [sum_product] using hb + +def piece (q N t : ℕ) (c f : Word α → ℂ) : Vector (Word α) := by + classical + exact ∑ p ∈ ((wordBall N) ×ˢ words (q-t)).filter (fun p => IsReduced (p.2 ++ p.1)), + lp.single 2 (p.2 ++ p.1) (∑ v ∈ words t, c (p.2 ++ v) * f (invRev v ++ p.1)) + +lemma piece_norm_sq_le (q N t : ℕ) (ht : t ≤ q) (c f : Word α → ℂ) + (hf : ∀ w, N < w.length → f w = 0) : + ‖piece q N t c f‖ ^ 2 ≤ + (∑ w ∈ words q, ‖c w‖ ^ 2) * ∑ x ∈ wordBall N, ‖f x‖ ^ 2 := by + classical + have hi : Set.InjOn (fun p : Word α × Word α => p.2 ++ p.1) + {p | p.1 ∈ wordBall N ∧ p.2 ∈ words (q-t) ∧ IsReduced (p.2 ++ p.1)} := by + rintro ⟨h,u⟩ hp ⟨h',u'⟩ hp' heq + have hu : u = u' := List.append_inj_left heq + ((mem_words.mp hp.2.1).trans (mem_words.mp hp'.2.1).symm) + subst u' + exact Prod.ext (List.append_cancel_left heq) rfl + have hb := masked_block_matrix_bound (words (q-t)) (words t) (wordBall N) + (fun u v => c (u ++ v)) (fun v h => f (invRev v ++ h)) + (fun u h => IsReduced (u ++ h)) (fun u h => u ++ h) hi + exact hb.trans (mul_le_mul (coefficient_energy_le q t ht c) + (input_energy_le N t f hf) (by positivity) (by positivity)) + +lemma piece_norm_le (q N t : ℕ) (ht : t ≤ q) (c f : Word α → ℂ) + (hf : ∀ w, N < w.length → f w = 0) : + ‖piece q N t c f‖ ≤ + Real.sqrt (∑ w ∈ words q, ‖c w‖ ^ 2) * + Real.sqrt (∑ x ∈ wordBall N, ‖f x‖ ^ 2) := by + have hc0 : 0 ≤ ∑ w ∈ words (α := α) q, ‖c w‖ ^ 2 := by positivity + have hf0 : 0 ≤ ∑ x ∈ wordBall (α := α) N, ‖f x‖ ^ 2 := by positivity + have hsq : (Real.sqrt (∑ w ∈ words (α := α) q, ‖c w‖ ^ 2) * + Real.sqrt (∑ x ∈ wordBall (α := α) N, ‖f x‖ ^ 2)) ^ 2 = + (∑ w ∈ words q, ‖c w‖ ^ 2) * ∑ x ∈ wordBall N, ‖f x‖ ^ 2 := by + rw [mul_pow, Real.sq_sqrt hc0, Real.sq_sqrt hf0] + have hb := piece_norm_sq_le q N t ht c f hf + rw [← hsq] at hb + exact (sq_le_sq₀ (norm_nonneg _) (by positivity)).mp hb + +omit [Fintype α] [DecidableEq α] in +lemma single_sum {I J : Type*} [DecidableEq J] (s : Finset I) (j : J) (c : I → ℂ) : + (lp.single 2 j (∑ i ∈ s, c i) : Vector J) = ∑ i ∈ s, lp.single 2 j (c i) := by + classical + induction s using Finset.induction_on with + | empty => simp + | @insert a s ha ih => simp [sum_insert ha, lp.single_add, ih] + +def tripleBox (q N t : ℕ) : Finset ((Word α × Word α) × Word α) := by + classical + exact (((wordBall N) ×ˢ words (q-t)).filter + (fun p => IsReduced (p.2 ++ p.1))) ×ˢ words t + +def triples (q N : ℕ) : Finset (Σ _ : ℕ, (Word α × Word α) × Word α) := + (range (q+1)).sigma (tripleBox q N) + +@[simp] lemma mem_triples (q N t : ℕ) (h u v : Word α) : + Sigma.mk t ((h,u),v) ∈ triples q N ↔ + t ≤ q ∧ h.length ≤ N ∧ u.length = q-t ∧ IsReduced (u ++ h) ∧ v.length = t := by + classical + simp [triples, tripleBox, and_assoc] + +def tripleValue (c f : Word α → ℂ) (p : Σ _ : ℕ, (Word α × Word α) × Word α) : + Vector (Word α) := + lp.single 2 (p.2.1.2 ++ p.2.1.1) (c (p.2.1.2 ++ p.2.2) * f (invRev p.2.2 ++ p.2.1.1)) + +def triplePair (p : Σ _ : ℕ, (Word α × Word α) × Word α) : Word α × Word α := + (p.2.1.2 ++ p.2.2, invRev p.2.2 ++ p.2.1.1) + +def convolution (q N : ℕ) (c f : Word α → ℂ) : Vector (Word α) := + ∑ p ∈ words q ×ˢ wordBall N, + lp.single 2 (reduce (p.1 ++ p.2)) (c p.1 * f p.2) + +lemma sum_pieces (q N : ℕ) (c f : Word α → ℂ) : + ∑ t ∈ range (q+1), piece q N t c f = + ∑ p ∈ triples q N, tripleValue c f p := by + classical + unfold triples + rw [← sum_sigma' (range (q+1)) (tripleBox q N) + (fun t p => tripleValue c f ⟨t,p⟩)] + apply sum_congr rfl + intro t _ + unfold piece tripleBox + rw [sum_product] + apply sum_congr rfl + intro p _ + exact single_sum (words t) (p.2 ++ p.1) _ + +lemma convolution_eq_pieces (q N : ℕ) (c f : Word α → ℂ) + (hc : ∀ w, c w ≠ 0 → IsReduced w) + (hfr : ∀ w, f w ≠ 0 → IsReduced w) + (hfN : ∀ w, N < w.length → f w = 0) : + convolution q N c f = ∑ t ∈ range (q+1), piece q N t c f := by + classical + rw [sum_pieces] + unfold convolution + symm + apply sum_bij_ne_zero (fun p _ _ => triplePair p) + · rintro ⟨t,⟨⟨h,u⟩,v⟩⟩ hp hn + obtain ⟨ht, hh, hu, hr, hv⟩ := (mem_triples q N t h u v).mp hp + simp only [triplePair, mem_product, mem_words, mem_wordBall, List.length_append, + invRev_length] + refine ⟨by omega, ?_⟩ + by_contra! hgt + have hz := hfN (invRev v ++ h) (by simpa using hgt) + exact hn (by simp [tripleValue, hz]) + · rintro ⟨t,⟨⟨h,u⟩,v⟩⟩ hp _ ⟨t',⟨⟨h',u'⟩,v'⟩⟩ hp' _ heq + obtain ⟨ht, hh, hu, hr, hv⟩ := (mem_triples q N t h u v).mp hp + obtain ⟨ht', hh', hu', hr', hv'⟩ := (mem_triples q N t' h' u' v').mp hp' + have hw : u ++ v = u' ++ v' := congrArg Prod.fst heq + have hx : invRev v ++ h = invRev v' ++ h' := congrArg Prod.snd heq + obtain ⟨rfl,rfl,rfl⟩ := boundary_unique hr hr' hw hx + have htt : t = t' := hv.symm.trans hv' + cases htt + rfl + · rintro ⟨w,x⟩ hp hn + have hwL : w.length = q := mem_words.mp (mem_product.mp hp).1 + have hxL : x.length ≤ N := mem_wordBall.mp (mem_product.mp hp).2 + have hcw : c w ≠ 0 := by + intro hz + exact hn (by simp [hz]) + have hfx : f x ≠ 0 := by + intro hz + exact hn (by simp [hz]) + obtain ⟨u,v,h,hw,hx,hy,hr⟩ := + HochschildFreeWords.boundary_reduction w x (hc w hcw) (hfr x hfx) + have hwLen : u.length + v.length = q := by simpa [hw] using hwL + have hxLen : v.length + h.length ≤ N := by simpa [hx] using hxL + let p : Σ _ : ℕ, (Word α × Word α) × Word α := ⟨v.length,((h,u),v)⟩ + have hpm : p ∈ triples q N := (mem_triples q N _ _ _ _).mpr + ⟨by omega, by omega, by omega, hr, rfl⟩ + have hpvalue : tripleValue c f p = + lp.single 2 (reduce (w ++ x)) (c w * f x) := by + simp only [tripleValue, p, ← hw, ← hx, hy] + refine ⟨p,hpm,?_,?_⟩ + · rwa [hpvalue] + · exact Prod.ext hw.symm hx.symm + · rintro ⟨t,⟨⟨h,u⟩,v⟩⟩ hp _ + obtain ⟨ht, hh, hu, hr, hv⟩ := (mem_triples q N t h u v).mp hp + simp only [tripleValue, triplePair, reduced_boundary_product u v h hr] + + + +theorem convolution_norm_le (q N : ℕ) (c f : Word α → ℂ) + (hc : ∀ w, c w ≠ 0 → IsReduced w) + (hfr : ∀ w, f w ≠ 0 → IsReduced w) + (hfN : ∀ w, N < w.length → f w = 0) : + ‖convolution q N c f‖ ≤ (q+1 : ℝ) * + Real.sqrt (∑ w ∈ words q, ‖c w‖ ^ 2) * + Real.sqrt (∑ x ∈ wordBall N, ‖f x‖ ^ 2) := by + rw [convolution_eq_pieces q N c f hc hfr hfN] + calc + _ ≤ ∑ t ∈ range (q+1), ‖piece q N t c f‖ := norm_sum_le _ _ + _ ≤ ∑ _t ∈ range (q+1), Real.sqrt (∑ w ∈ words q, ‖c w‖ ^ 2) * + Real.sqrt (∑ x ∈ wordBall N, ‖f x‖ ^ 2) := by + apply sum_le_sum + intro t ht + exact piece_norm_le q N t (by simpa using ht) c f hfN + _ = _ := by simp [mul_assoc] + +end +end HochschildLength + +namespace HochschildTransfer +open Finset FreeGroup +open HochschildLength +noncomputable section +variable {α : Type*} [DecidableEq α] +abbrev Polynomial (α : Type*) := MonoidAlgebra ℂ (FreeGroup α) + +def vector : Polynomial α →ₗ[ℂ] Vector (Word α) := + (Finsupp.lsum ℂ (fun g : FreeGroup α => lp.lsingle (𝕜 := ℂ) (E := fun _ : Word α => ℂ) 2 g.toWord)).comp + (MonoidAlgebra.coeffLinearEquiv ℂ).toLinearMap + +lemma vector_def (p : Polynomial α) : vector p = + ∑ g ∈ p.coeff.support, lp.single 2 g.toWord (p.coeff g) := by + rfl + +@[simp] lemma vector_single (g : FreeGroup α) (c : ℂ) : + vector (MonoidAlgebra.single g c) = lp.single 2 g.toWord c := by + simp [vector] + +lemma vector_norm_sq (p : Polynomial α) : + ‖vector p‖^2 = ∑ g ∈ p.coeff.support, ‖p.coeff g‖^2 := by + rw [vector_def] + exact norm_sum_single_sq _ _ _ (toWord_injective.injOn) + +def wordCoeff (p : Polynomial α) (w : Word α) : ℂ := by + classical + exact if IsReduced w then p.coeff (mk w) else 0 + +@[simp] lemma wordCoeff_toWord (p : Polynomial α) (g : FreeGroup α) : + wordCoeff p g.toWord = p.coeff g := by + simp [wordCoeff, isReduced_toWord, mk_toWord] + +omit [DecidableEq α] in +lemma reduced_of_wordCoeff_ne_zero (p : Polynomial α) (w : Word α) + (h : wordCoeff p w ≠ 0) : IsReduced w := by + classical + by_contra hn + simp [wordCoeff, hn] at h + +omit [DecidableEq α] in +lemma wordCoeff_eq_zero (p : Polynomial α) (w : Word α) + (h : p.coeff (mk w) = 0) : wordCoeff p w = 0 := by + simp [wordCoeff, h] + +lemma sum_wordCoeff (p : Polynomial α) (s : Finset (Word α)) + (hs : ∀ g ∈ p.coeff.support, g.toWord ∈ s) + {V : Type*} [AddCommMonoid V] (F : Word α → ℂ → V) + (hzero : ∀ w, F w 0 = 0) : + (∑ w ∈ s, F w (wordCoeff p w)) = + ∑ g ∈ p.coeff.support, F g.toWord (p.coeff g) := by + classical + calc + _ = ∑ w ∈ p.coeff.support.image toWord, F w (wordCoeff p w) := by + symm + apply sum_subset + · intro w hw + obtain ⟨g,hg,rfl⟩ := mem_image.mp hw + exact hs g hg + · intro w hw hnot + by_cases hr : IsReduced w + · have hm : mk w ∉ p.coeff.support := by + intro hm + apply hnot + exact mem_image.mpr ⟨mk w, hm, by simpa [toWord_mk] using hr.reduce_eq⟩ + simp [wordCoeff, hr, Finsupp.notMem_support_iff.mp hm, hzero] + · simp [wordCoeff, hr, hzero] + _ = _ := by + rw [sum_image toWord_injective.injOn] + simp only [wordCoeff_toWord] + +lemma polynomial_wordSum (p : Polynomial α) (s : Finset (Word α)) + (hs : ∀ g ∈ p.coeff.support, g.toWord ∈ s) : + (∑ w ∈ s, MonoidAlgebra.single (mk w) (wordCoeff p w)) = p := by + rw [sum_wordCoeff p s hs _ (by simp)] + simpa only [mk_toWord, Finsupp.sum] using p.sum_coeff_single + +lemma vector_wordSum (p : Polynomial α) (s : Finset (Word α)) + (hs : ∀ g ∈ p.coeff.support, g.toWord ∈ s) : + (∑ w ∈ s, lp.single 2 w (wordCoeff p w)) = vector p := by + rw [sum_wordCoeff p s hs _ (by simp), vector_def] + +lemma vector_mul_wordSum (p d : Polynomial α) (S T : Finset (Word α)) + (hS : ∀ g ∈ p.coeff.support, g.toWord ∈ S) + (hT : ∀ g ∈ d.coeff.support, g.toWord ∈ T) : + vector (p*d) = ∑ v ∈ S, ∑ w ∈ T, + lp.single 2 (reduce (v++w)) (wordCoeff p v * wordCoeff d w) := by + conv_lhs => rw [← polynomial_wordSum p S hS, ← polynomial_wordSum d T hT] + simp only [sum_mul, mul_sum, map_sum, MonoidAlgebra.single_mul_single, vector_single, + FreeGroup.mul_mk, toWord_mk] + rw [sum_comm] + +lemma vector_norm_sq_wordSum (p : Polynomial α) (s : Finset (Word α)) + (hs : ∀ g ∈ p.coeff.support, g.toWord ∈ s) : + ‖vector p‖^2 = ∑ w ∈ s, ‖wordCoeff p w‖^2 := by + rw [← vector_wordSum p s hs] + exact norm_sum_single_sq s id _ (Function.injective_id.injOn) + +variable [Fintype α] +lemma vector_mul_norm_le (p d : Polynomial α) (q : ℕ) + (hq : ∀ g ∈ p.coeff.support, g.toWord.length = q) : + ‖vector (p*d)‖ ≤ (q+1:ℝ) * ‖vector p‖ * ‖vector d‖ := by + let N := d.coeff.support.sup (fun g => g.toWord.length) + have hq' : ∀ g ∈ p.coeff.support, g.toWord ∈ words q := by + simpa only [mem_words] using hq + have hN : ∀ g ∈ d.coeff.support, g.toWord ∈ wordBall N := by + intro g hg + rw [mem_wordBall] + exact le_sup (f := fun g : FreeGroup α => g.toWord.length) hg + have heq : vector (p*d) = convolution q N (wordCoeff p) (wordCoeff d) := by + rw [vector_mul_wordSum p d _ _ hq' hN] + unfold HochschildLength.convolution + exact (sum_product (words q) (wordBall N) + (fun z : Word α × Word α => (lp.single 2 (reduce (z.1++z.2)) + (wordCoeff p z.1 * wordCoeff d z.2) : Vector (Word α)))).symm + rw [heq] + have h := convolution_norm_le q N (wordCoeff p) (wordCoeff d) + (reduced_of_wordCoeff_ne_zero p) (reduced_of_wordCoeff_ne_zero d) (by + intro w hw + classical + by_cases hr : IsReduced w + · apply wordCoeff_eq_zero + by_contra hn + have hmem := hN (mk w) (Finsupp.mem_support_iff.mpr hn) + rw [mem_wordBall, toWord_mk, hr.reduce_eq] at hmem + omega + · simp [wordCoeff, hr]) + rw [← vector_norm_sq_wordSum p _ hq', ← vector_norm_sq_wordSum d _ hN, + Real.sqrt_sq (norm_nonneg _), Real.sqrt_sq (norm_nonneg _)] at h + exact h + +end +end HochschildTransfer + +namespace HochschildTracePolynomial +open Finset +open scoped ComplexOrder +noncomputable section +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable {G : Type*} [Group G] [DecidableEq G] +variable (τ : A →ₚ[ℂ] ℂ) (u : G →* A) +variable (hτ : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) +variable (hfree : ∀ g : G, g ≠ 1 → τ (u g) = 0) + +include hτ hu hfree + +lemma inner_word (g h : G) : + inner ℂ (τ.toPreGNS (u g)) (τ.toPreGNS (u h)) = if g = h then 1 else 0 := by + classical + rw [PositiveLinearMap.preGNS_inner_def] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, hu, ← map_mul] + split_ifs with heq + · subst h + simp [hτ] + · apply hfree + exact fun h => heq (_root_.inv_mul_eq_one.mp h) + +lemma norm_sum_word_sq (s : Finset G) (c : G → ℂ) : + ‖τ.toPreGNS (∑ g ∈ s, c g • u g)‖^2 = ∑ g ∈ s, ‖c g‖^2 := by + classical + have hi : inner ℂ (τ.toPreGNS (∑ g ∈ s, c g • u g)) + (τ.toPreGNS (∑ g ∈ s, c g • u g)) = ∑ g ∈ s, (‖c g‖ : ℂ)^2 := by + simp only [map_sum, map_smul] + rw [sum_inner] + apply sum_congr rfl + intro g hg + rw [inner_sum, sum_eq_single g] + · rw [inner_smul_left, inner_smul_right, inner_word τ u hτ hu hfree] + simp [Complex.conj_mul'] + · intro h hh hne + rw [inner_smul_left, inner_smul_right, inner_word τ u hτ hu hfree] + simp [Ne.symm hne] + · exact fun h => (h hg).elim + apply Complex.ofReal_injective + simpa [inner_self_eq_norm_sq_to_K, Complex.ofReal_sum, Complex.ofReal_pow] using hi + +lemma norm_eval_sq (p : MonoidAlgebra ℂ G) : + ‖τ.toPreGNS (MonoidAlgebra.lift ℂ A G u p)‖^2 = + ∑ g ∈ p.coeff.support, ‖p.coeff g‖^2 := by + rw [MonoidAlgebra.lift_apply] + exact norm_sum_word_sq τ u hτ hu hfree _ _ + +end +end HochschildTracePolynomial + +namespace HochschildPolynomial +open Finset +noncomputable section +variable {G : Type*} [Group G] + +def adjoint (p : MonoidAlgebra ℂ G) : MonoidAlgebra ℂ G := + .ofCoeff ((p.coeff.mapRange (starRingEnd ℂ) (map_zero _)).mapDomain Inv.inv) + +@[simp] lemma coeff_adjoint (p : MonoidAlgebra ℂ G) (g : G) : + (adjoint p).coeff g = star (p.coeff g⁻¹) := by + have h := Finsupp.mapDomain_apply_of_injective inv_injective + (p.coeff.mapRange (starRingEnd ℂ) (map_zero _)) g⁻¹ + simpa [adjoint] using h + +lemma adjoint_support (p : MonoidAlgebra ℂ G) (g : G) : + g ∈ (adjoint p).coeff.support ↔ g⁻¹ ∈ p.coeff.support := by + simp [Finsupp.mem_support_iff] + +variable {A : Type*} [CStarAlgebra A] +lemma eval_adjoint (u : G →* A) (hu : ∀ g, star (u g) = u g⁻¹) + (p : MonoidAlgebra ℂ G) : + MonoidAlgebra.lift ℂ A G u (adjoint p) = star (MonoidAlgebra.lift ℂ A G u p) := by + classical + simp only [MonoidAlgebra.lift_apply, adjoint] + rw [Finsupp.sum_mapDomain_index (by simp) (by intros; simp [add_smul])] + rw [Finsupp.sum_mapRange_index (by simp)] + simp only [Finsupp.sum, star_sum, star_smul, hu, Complex.star_def] + +end +end HochschildPolynomial + +open scoped ComplexOrder +open Filter Topology +namespace HochschildTransfer +open Finset +open scoped ComplexOrder +noncomputable section +variable {α : Type*} [Fintype α] [DecidableEq α] +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (u : FreeGroup α →* A) +variable (hτ : τ 1 = 1) (hu : ∀ g, star (u g) = u g⁻¹) +variable (hfree : ∀ g : FreeGroup α, g ≠ 1 → τ (u g) = 0) +include hτ hu hfree +omit [Fintype α] in +lemma vector_norm_eq_preGNS (p : Polynomial α) : + ‖vector p‖ = ‖τ.toPreGNS (MonoidAlgebra.lift ℂ A (FreeGroup α) u p)‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [vector_norm_sq, HochschildTracePolynomial.norm_eval_sq τ u hτ hu hfree] + +omit hτ hu hfree in +lemma norm_one_gns (h1 : τ 1 = 1) : ‖τ.toPreGNS 1‖ = 1 := by + have h := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS 1)) + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, star_one, one_mul, h1, + ← Complex.ofReal_pow, Complex.ofReal_re, Complex.one_re] at h + nlinarith [norm_nonneg (τ.toPreGNS 1)] + +omit hτ hu hfree in +lemma norm_star_gns (htr : ∀ a b : A, τ (a*b) = τ (b*a)) (a : A) : + ‖τ.toPreGNS (star a)‖ = ‖τ.toPreGNS a‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + apply Complex.ofReal_injective + push_cast + simp only [τ.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS, star_star] + exact htr _ _ + + + +theorem norm_eval_homogeneous_le + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (hfaith : ∀ a : A, τ (star a*a) = 0 → a = 0) + (p : Polynomial α) (q : ℕ) + (hq : ∀ g ∈ p.coeff.support, g.toWord.length = q) : + ‖MonoidAlgebra.lift ℂ A (FreeGroup α) u p‖ ≤ + (q+1:ℝ) * ‖τ.toPreGNS (MonoidAlgebra.lift ℂ A (FreeGroup α) u p)‖ := by + let E := MonoidAlgebra.lift ℂ A (FreeGroup α) u + let C : ℝ := (q+1:ℝ) * ‖τ.toPreGNS (E p)‖ + have hC : 0 ≤ C := by dsimp [C]; positivity + have hp (d : Polynomial α) : + ‖τ.toPreGNS (E (p*d))‖ ≤ C * ‖τ.toPreGNS (E d)‖ := by + simpa only [vector_norm_eq_preGNS τ u hτ hu hfree] using + vector_mul_norm_le p d q hq + have hqa : ∀ g ∈ (HochschildPolynomial.adjoint p).coeff.support, + g.toWord.length = q := by + intro g hg + have h := hq g⁻¹ ((HochschildPolynomial.adjoint_support p g).mp hg) + simpa only [FreeGroup.toWord_inv, FreeGroup.invRev_length] using h + have hpa (d : Polynomial α) : + ‖τ.toPreGNS (E (HochschildPolynomial.adjoint p*d))‖ ≤ + C * ‖τ.toPreGNS (E d)‖ := by + have h := vector_mul_norm_le (HochschildPolynomial.adjoint p) d q hqa + simp only [vector_norm_eq_preGNS τ u hτ hu hfree, + HochschildPolynomial.eval_adjoint u hu, norm_star_gns τ htr] at h + exact h + let a : Polynomial α := HochschildPolynomial.adjoint p * p + have ha : E a = star (E p) * E p := by + simp only [a, map_mul, E, HochschildPolynomial.eval_adjoint u hu] + have hpow (n : ℕ) : ‖τ.toPreGNS (E (a^n))‖ ≤ (C^2)^n := by + induction n with + | zero => simp [norm_one_gns τ hτ] + | succ n ih => + calc + _ = ‖τ.toPreGNS (E (HochschildPolynomial.adjoint p*(p*a^n)))‖ := by + rw [pow_succ']; simp only [a, mul_assoc] + _ ≤ C * ‖τ.toPreGNS (E (p*a^n))‖ := hpa _ + _ ≤ C * (C * ‖τ.toPreGNS (E (a^n))‖) := mul_le_mul_of_nonneg_left (hp _) hC + _ ≤ C * (C * (C^2)^n) := by gcongr + _ = _ := by ring + have hmoment (n : ℕ) : (τ ((star (E p)*E p)^n)).re ≤ (C^2)^n := by + have hinner : inner ℂ (τ.toPreGNS 1) (τ.toPreGNS (E (a^n))) = + τ ((star (E p)*E p)^n) := by + simp only [PositiveLinearMap.preGNS_inner_def, + PositiveLinearMap.ofPreGNS_toPreGNS, star_one, one_mul, map_pow, ha] + calc + _ ≤ ‖τ ((star (E p)*E p)^n)‖ := Complex.re_le_norm _ + _ = ‖inner ℂ (τ.toPreGNS 1) (τ.toPreGNS (E (a^n)))‖ := congrArg norm hinner.symm + _ ≤ ‖τ.toPreGNS 1‖ * ‖τ.toPreGNS (E (a^n))‖ := norm_inner_le_norm _ _ + _ ≤ (C^2)^n := by rw [norm_one_gns τ hτ, one_mul]; exact hpow n + have hn := HochschildMoments.norm_le_of_positive_moment_bound τ hfaith + (star (E p)*E p) (star_mul_self_nonneg _) (C^2) (sq_nonneg _) hmoment + rw [CStarRing.norm_star_mul_self] at hn + change ‖E p‖ ≤ C + nlinarith [norm_nonneg (E p)] + +end +end HochschildTransfer +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/HarmonicSums.lean b/lean/OAI/Analysis/BoundedHochschild/HarmonicSums.lean new file mode 100644 index 0000000000000000000000000000000000000000..c7d01dd60b94ffe4247e0f181b9b11b3f7c230f1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/HarmonicSums.lean @@ -0,0 +1,623 @@ +import Mathlib + +namespace OAI + +/-! Harmonic sine estimates, Fourier windows, tracial Hilbert spaces and unitary power rigidity. -/ + +noncomputable section + + +namespace HochschildRigidity +open Finset + + +theorem norm_sum_smul_le_of_antitone + {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] + (f : ℕ → ℝ) (z : ℕ → E) (B : ℝ) (hf : ∀ i, 0 ≤ f i) + (hfmono : Antitone f) (hB : 0 ≤ B) + (hz : ∀ k, ‖∑ i ∈ range k, z i‖ ≤ B) (n : ℕ) : + ‖∑ i ∈ range n, f i • z i‖ ≤ f 0 * B := by + cases n with + | zero => simpa using mul_nonneg (hf 0) hB + | succ n => + rw [sum_range_by_parts, Nat.succ_sub_one] + have hd (i : ℕ) : 0 ≤ f i - f (i + 1) := sub_nonneg.mpr (hfmono (Nat.le_succ i)) + have heq : -(∑ i ∈ range n, (f (i + 1) - f i) • ∑ j ∈ range (i + 1), z j) = + ∑ i ∈ range n, (f i - f (i + 1)) • ∑ j ∈ range (i + 1), z j := by + simp only [← Finset.sum_neg_distrib, ← neg_smul, neg_sub] + rw [sub_eq_add_neg, heq] + calc + _ ≤ ‖f n • ∑ i ∈ range (n + 1), z i‖ + + ‖∑ i ∈ range n, (f i - f (i + 1)) • ∑ j ∈ range (i + 1), z j‖ := norm_add_le _ _ + _ ≤ f n * B + ∑ i ∈ range n, (f i - f (i + 1)) * B := by + apply add_le_add + · rw [norm_smul, Real.norm_eq_abs, abs_of_nonneg (hf n)] + exact mul_le_mul_of_nonneg_left (hz _) (hf n) + · refine (norm_sum_le _ _).trans (sum_le_sum (fun i _ => ?_)) + rw [norm_smul, Real.norm_eq_abs, abs_of_nonneg (hd i)] + exact mul_le_mul_of_nonneg_left (hz _) (hd i) + _ = f 0 * B := by + rw [← sum_mul, sum_range_sub'] + ring + + +theorem abs_sum_sin_le (t : ℝ) (ht : 0 < t) (htpi : t ≤ Real.pi) + (b : ℝ) (n : ℕ) : + |∑ i ∈ range n, Real.sin (t * i + b)| ≤ Real.pi / t := by + have hspos : 0 < Real.sin (t / 2) := + Real.sin_pos_of_pos_of_lt_pi (by linarith) (by linarith [Real.pi_pos]) + have hprod : Real.sin (t / 2) * |∑ i ∈ range n, Real.sin (t * i + b)| ≤ 1 := by + have heq := congrArg abs (Real.sin_mul_sum_sin n t b) + rw [abs_mul, abs_of_pos hspos, abs_mul] at heq + rw [heq] + calc + _ ≤ 1 * _ := mul_le_mul_of_nonneg_right (Real.abs_sin_le_one _) (abs_nonneg _) + _ ≤ 1 := by simpa using Real.abs_sin_le_one _ + have hsin : t / Real.pi ≤ Real.sin (t / 2) := by + simpa using Real.mul_le_sin (x := t / 2) (by positivity) (by linarith) + calc + _ ≤ 1 / Real.sin (t / 2) := (le_div_iff₀ hspos).mpr (by nlinarith [hprod]) + _ ≤ Real.pi / t := (div_le_div_iff₀ hspos ht).mpr (by + have h := (div_le_iff₀ Real.pi_pos).mp hsin + nlinarith) + + +theorem abs_harmonic_sin_tail_le (t : ℝ) (ht : 0 < t) (htpi : t ≤ Real.pi) + (p : ℕ) (hp : 0 < p) (n : ℕ) : + |∑ i ∈ range n, Real.sin (((p + i : ℕ) : ℝ) * t) / (p + i)| ≤ + Real.pi / (t * p) := by + let f : ℕ → ℝ := fun i => 1 / (p + i : ℕ) + let z : ℕ → ℝ := fun i => Real.sin (((p + i : ℕ) : ℝ) * t) + have hf (i : ℕ) : 0 ≤ f i := by dsimp [f]; positivity + have hfm : Antitone f := by + intro i j hij + apply one_div_le_one_div_of_le + · positivity + · exact_mod_cast Nat.add_le_add_left hij p + have hz (k : ℕ) : ‖∑ i ∈ range k, z i‖ ≤ Real.pi / t := by + simpa [z, Real.norm_eq_abs, Nat.cast_add, add_mul, mul_add, mul_comm, add_comm] using + abs_sum_sin_le t ht htpi (p * t) k + have h := norm_sum_smul_le_of_antitone f z (Real.pi / t) hf hfm + (by positivity) hz n + simpa [f, z, Real.norm_eq_abs, div_eq_mul_inv, mul_comm, mul_left_comm, mul_assoc] using h + +theorem abs_harmonic_sin_prefix_le (t : ℝ) (ht : 0 ≤ t) (n : ℕ) : + |∑ i ∈ range n, Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)| ≤ n * t := by + calc + _ ≤ ∑ i ∈ range n, |Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)| := + abs_sum_le_sum_abs _ _ + _ ≤ ∑ _i ∈ range n, t := by + apply sum_le_sum + intro i _ + have hi : (0 : ℝ) < i + 1 := by positivity + rw [abs_div, abs_of_pos hi] + apply (div_le_iff₀ hi).mpr + have h := Real.abs_sin_le_abs (x := ((i + 1 : ℕ) : ℝ) * t) + rw [abs_of_nonneg (mul_nonneg (Nat.cast_nonneg _) ht)] at h + simpa only [Nat.cast_add, Nat.cast_one, mul_comm] using h + _ = n * t := by simp + + +theorem abs_harmonic_sin_le_pos (t : ℝ) (ht : 0 < t) (htpi : t ≤ Real.pi) + (n : ℕ) : + |∑ i ∈ range n, Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)| ≤ 1 + Real.pi := by + let K : ℕ := ⌊1 / t⌋₊ + have hK : (K : ℝ) * t ≤ 1 := by + have h := Nat.floor_le (show 0 ≤ 1 / t by positivity) + exact (le_div_iff₀ ht).mp h + by_cases hn : n ≤ K + · calc + _ ≤ (n : ℝ) * t := abs_harmonic_sin_prefix_le t ht.le n + _ ≤ (K : ℝ) * t := mul_le_mul_of_nonneg_right (by exact_mod_cast hn) ht.le + _ ≤ 1 := hK + _ ≤ 1 + Real.pi := by linarith [Real.pi_pos] + · have hKn : K ≤ n := by omega + have hp : (0 : ℝ) < t * (K + 1) := by positivity + have htK : 1 ≤ t * (K + 1) := by + have h : 1 / t < (K : ℝ) + 1 := Nat.lt_floor_add_one (1 / t) + have h' := (div_lt_iff₀ ht).mp h + nlinarith + have htail := abs_harmonic_sin_tail_le t ht htpi (K + 1) (by omega) (n - K) + have htail' : + |∑ i ∈ range (n - K), Real.sin (((K + i + 1 : ℕ) : ℝ) * t) / (K + i + 1)| + ≤ Real.pi := by + calc + _ ≤ Real.pi / (t * (K + 1)) := by + simpa [Nat.cast_add, Nat.cast_one, Nat.add_assoc, Nat.add_comm, Nat.add_left_comm, + add_assoc, add_comm, add_left_comm] using htail + _ ≤ Real.pi := (div_le_iff₀ hp).mpr (by nlinarith [Real.pi_pos]) + rw [show n = K + (n - K) by omega, sum_range_add] + calc + _ ≤ |∑ i ∈ range K, Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)| + + |∑ i ∈ range (n - K), Real.sin (((K + i + 1 : ℕ) : ℝ) * t) / (K + i + 1)| := + by + simpa only [Nat.cast_add] using + (abs_add_le + (∑ i ∈ range K, Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)) + (∑ i ∈ range (n - K), + Real.sin (((K + i + 1 : ℕ) : ℝ) * t) / (K + i + 1))) + _ ≤ (K : ℝ) * t + Real.pi := add_le_add + (abs_harmonic_sin_prefix_le t ht.le K) htail' + _ ≤ 1 + Real.pi := by linarith + + +theorem abs_harmonic_sin_le (t : ℝ) (ht : |t| ≤ Real.pi) (n : ℕ) : + |∑ i ∈ range n, Real.sin (((i + 1 : ℕ) : ℝ) * t) / (i + 1)| ≤ 1 + Real.pi := by + rcases lt_trichotomy 0 t with hpos | rfl | hneg + · exact abs_harmonic_sin_le_pos t hpos ((le_abs_self _).trans ht) n + · simp only [mul_zero, Real.sin_zero, zero_div, sum_const_zero, abs_zero] + positivity + · have h := abs_harmonic_sin_le_pos (-t) (by linarith) (by + simpa only [abs_of_neg hneg] using ht) n + simpa only [mul_neg, Real.sin_neg, neg_div, sum_neg_distrib, abs_neg] using h + + +noncomputable def harmonicPolynomial {A : Type*} [Ring A] [Algebra ℂ A] + (n : ℕ) (x : A) : A := + ∑ i ∈ range n, ((i + 1 : ℂ)⁻¹) • x ^ (i + 1) + + +theorem harmonicPolynomial_im (z : ℂ) (hz : ‖z‖ = 1) (n : ℕ) : + (harmonicPolynomial n z).im = + ∑ i ∈ range n, Real.sin (((i + 1 : ℕ) : ℝ) * z.arg) / (i + 1) := by + have hpower (k : ℕ) : (z ^ k).im = Real.sin ((k : ℝ) * z.arg) := by + have hzrep := Complex.norm_mul_cos_add_sin_mul_I z + rw [hz, Complex.ofReal_one, one_mul] at hzrep + have h := congrArg Complex.im (Complex.cos_add_sin_mul_I_pow k (z.arg : ℂ)) + rw [hzrep] at h + simpa only [← Complex.ofReal_natCast, ← Complex.ofReal_mul, ← Complex.ofReal_cos, + ← Complex.ofReal_sin, Complex.add_im, Complex.ofReal_im, Complex.mul_im, + Complex.ofReal_re, Complex.I_im, Complex.I_re, mul_one, mul_zero, add_zero, + zero_add] using h + simp only [harmonicPolynomial, Complex.im_sum, smul_eq_mul] + apply sum_congr rfl + intro i _ + rw [show (i + 1 : ℂ)⁻¹ = (((i + 1 : ℝ)⁻¹ : ℝ) : ℂ) by simp] + simp only [Complex.mul_im, Complex.ofReal_re, Complex.ofReal_im, zero_mul, add_zero, hpower] + ring + +theorem norm_harmonicPolynomial_sub_star_le (z : ℂ) (hz : ‖z‖ = 1) (n : ℕ) : + ‖harmonicPolynomial n z - star (harmonicPolynomial n z)‖ ≤ + 2 * (1 + Real.pi) := by + have h := abs_harmonic_sin_le z.arg (Complex.abs_arg_le_pi z) n + rw [← harmonicPolynomial_im z hz n] at h + change ‖harmonicPolynomial n z - (starRingEnd ℂ) (harmonicPolynomial n z)‖ ≤ _ + rw [Complex.sub_conj, norm_mul, Complex.norm_I, mul_one, Complex.norm_real, + Real.norm_eq_abs, abs_mul, abs_of_nonneg (by norm_num : (0 : ℝ) ≤ 2)] + exact mul_le_mul_of_nonneg_left h (by norm_num) + + +theorem norm_unitary_harmonicPolynomial_sub_star_le {A : Type*} [CStarAlgebra A] + (u : unitary A) (n : ℕ) : + ‖harmonicPolynomial n (u : A) - star (harmonicPolynomial n (u : A))‖ ≤ + 2 * (1 + Real.pi) := by + have hcfc : cfc (harmonicPolynomial n : ℂ → ℂ) (u : A) = + harmonicPolynomial n (u : A) := by + unfold harmonicPolynomial + rw [show (fun x : ℂ => ∑ i ∈ range n, ((i + 1 : ℂ)⁻¹) • x ^ (i + 1)) = + ∑ i ∈ range n, (fun x : ℂ => ((i + 1 : ℂ)⁻¹) • x ^ (i + 1)) by + ext; simp only [Finset.sum_apply]] + rw [cfc_sum (fun (i : ℕ) (x : ℂ) => ((i + 1 : ℂ)⁻¹) • x ^ (i + 1)) + (u : A) (range n) (by intro i _; fun_prop)] + apply sum_congr rfl + intro i _ + rw [cfc_smul ((i + 1 : ℂ)⁻¹) (fun x : ℂ => x ^ (i + 1)) (u : A) (by fun_prop), + cfc_pow_id (R := ℂ) (u : A) (i + 1)] + have hcont : Continuous (harmonicPolynomial n : ℂ → ℂ) := by + unfold harmonicPolynomial + fun_prop + have h := norm_cfc_le (a := (u : A)) (f := fun z : ℂ => + harmonicPolynomial n z - star (harmonicPolynomial n z)) + (show 0 ≤ 2 * (1 + Real.pi) by positivity) + (fun z hz => norm_harmonicPolynomial_sub_star_le z + (spectrum.norm_eq_one_of_unitary u.property hz) n) + rwa [cfc_sub _ _ _ hcont.continuousOn hcont.star.continuousOn, cfc_star, hcfc] at h + +section FourierWindows +variable {L : ℕ} [NeZero L] + +lemma sum_stdAddChar_mul (t : ZMod L) : + ∑ j : ZMod L, ZMod.stdAddChar (t * j) = if t = 0 then (L : ℂ) else 0 := by + split_ifs with ht + · simp [ht] + · exact AddChar.sum_eq_zero_of_ne_one (ZMod.isPrimitive_stdAddChar L ht) + + +theorem sum_dft_mul_star_dft {A : Type*} [Ring A] [StarRing A] [Algebra ℂ A] + [StarModule ℂ A] (f g : ZMod L → A) : + ∑ j : ZMod L, ZMod.dft f j * star (ZMod.dft g j) = + (L : ℂ) • ∑ k : ZMod L, f k * star (g k) := by + simp only [ZMod.dft_apply, star_sum, star_smul, sum_mul, mul_sum, + smul_mul_assoc, mul_smul_comm, smul_sum, smul_smul] + simp only [Complex.star_def, ← AddChar.map_neg_eq_conj, neg_neg, + ← AddChar.map_add_eq_mul, ← sub_eq_add_neg, ← sub_mul] + rw [sum_comm] + conv_lhs => + enter [2, k] + rw [sum_comm] + simp only [← sum_smul, sum_stdAddChar_mul, sub_eq_zero, ite_smul, zero_smul, + sum_ite_eq, mem_univ, ite_true, ← smul_sum] + +noncomputable def rootUnitary (j : ZMod L) : unitary ℂ := + ⟨ZMod.stdAddChar j, by + rw [Unitary.mem_iff] + simp only [Complex.star_def, ← AddChar.map_neg_eq_conj, ← AddChar.map_add_eq_mul, + neg_add_cancel, add_neg_cancel, AddChar.map_zero_eq_one, and_self]⟩ + +@[simp] lemma rootUnitary_coe (j : ZMod L) : + (rootUnitary j : ℂ) = ZMod.stdAddChar j := rfl + +noncomputable def fourierWindow {A : Type*} [Ring A] [Algebra ℂ A] + (u : A) (j : ZMod L) : A := + (L : ℂ)⁻¹ • ZMod.dft (fun k : ZMod L => u ^ k.val) j + +lemma sum_fourierWindow_mul_star {A : Type*} [Ring A] [StarRing A] [Algebra ℂ A] + [StarModule ℂ A] (u : unitary A) : + ∑ j : ZMod L, fourierWindow (u : A) j * star (fourierWindow (u : A) j) = 1 := by + have hpow (k : ZMod L) : (u : A) ^ k.val * star ((u : A) ^ k.val) = 1 := by + simpa only [Unitary.coe_star, SubmonoidClass.coe_pow] using Unitary.coe_mul_star_self (u ^ k.val) + simp only [fourierWindow, star_smul, smul_mul_smul_comm, star_inv₀, star_natCast, + ← smul_sum, sum_dft_mul_star_dft, hpow, sum_const, card_univ, ZMod.card] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, smul_smul] + have hL : (L : ℂ) ≠ 0 := Nat.cast_ne_zero.mpr (NeZero.ne L) + rw [show (L : ℂ)⁻¹ * (L : ℂ)⁻¹ * (L : ℂ) * (L : ℂ) = 1 by field_simp] + exact one_smul _ _ + +lemma sum_zmod_val {A : Type*} [AddCommMonoid A] (f : ℕ → A) : + ∑ k : ZMod L, f k.val = ∑ k ∈ range L, f k := by + cases L with + | zero => exact (NeZero.ne 0 rfl).elim + | succ L => exact Fin.sum_univ_eq_sum_range f (L + 1) + +lemma fourierWindow_eq_geometric {A : Type*} [Ring A] [Algebra ℂ A] + (u : A) (j : ZMod L) : + fourierWindow u j = (L : ℂ)⁻¹ • + ∑ k ∈ range L, (ZMod.stdAddChar (-j) • u) ^ k := by + unfold fourierWindow + rw [ZMod.dft_apply] + congr 1 + calc + _ = ∑ k : ZMod L, (ZMod.stdAddChar (-j) • u) ^ k.val := by + apply sum_congr rfl + intro k _ + rw [smul_pow, ← AddChar.map_nsmul_eq_pow, nsmul_eq_mul, + ZMod.natCast_zmod_val, mul_neg] + _ = _ := sum_zmod_val _ + + +lemma norm_unitary_mul_fourierWindow_sub_le {A : Type*} [CStarAlgebra A] + [Nontrivial A] (u : unitary A) (j : ZMod L) : + ‖((rootUnitary (-j) • u : unitary A) : A) * fourierWindow (u : A) j - + fourierWindow (u : A) j‖ ≤ 2 / (L : ℝ) := by + let v : unitary A := rootUnitary (-j) • u + have hq : fourierWindow (u : A) j = + (L : ℂ)⁻¹ • ∑ k ∈ range L, (v : A) ^ k := fourierWindow_eq_geometric _ _ + have heq : (v : A) * fourierWindow (u : A) j - fourierWindow (u : A) j = + (L : ℂ)⁻¹ • ((v : A) ^ L - 1) := by + rw [← sub_one_mul, hq, mul_smul_comm, mul_geom_sum] + change ‖(v : A) * fourierWindow (u : A) j - fourierWindow (u : A) j‖ ≤ _ + rw [heq, norm_smul, norm_inv, Complex.norm_natCast] + have hpow : ‖(v : A) ^ L‖ = 1 := by + simpa only [SubmonoidClass.coe_pow] using CStarRing.norm_coe_unitary (v ^ L) + calc + _ ≤ (L : ℝ)⁻¹ * (‖(v : A) ^ L‖ + ‖(1 : A)‖) := by gcongr; exact norm_sub_le _ _ + _ = _ := by rw [hpow, norm_one]; ring + +lemma norm_unitary_pow_mul_sub_le {A : Type*} [CStarAlgebra A] + (v : unitary A) (q : A) (k : ℕ) : + ‖(v : A) ^ k * q - q‖ ≤ (k : ℝ) * ‖(v : A) * q - q‖ := by + induction k with + | zero => simp + | succ k ih => + have heq : (v : A) ^ (k + 1) * q - q = + (v : A) * ((v : A) ^ k * q - q) + ((v : A) * q - q) := by + rw [pow_succ', mul_sub, ← mul_assoc]; noncomm_ring + rw [heq] + calc + _ ≤ ‖(v : A) * ((v : A) ^ k * q - q)‖ + ‖(v : A) * q - q‖ := norm_add_le _ _ + _ = ‖(v : A) ^ k * q - q‖ + ‖(v : A) * q - q‖ := by + rw [CStarRing.norm_coe_unitary_mul] + _ ≤ (k : ℝ) * ‖(v : A) * q - q‖ + ‖(v : A) * q - q‖ := by gcongr + _ = _ := by push_cast; ring + +lemma norm_star_unitary_mul_sub {A : Type*} [CStarAlgebra A] + (v : unitary A) (q : A) : + ‖(star v : A) * q - q‖ = ‖(v : A) * q - q‖ := by + rw [← CStarRing.norm_coe_unitary_mul v ((star v : A) * q - q), mul_sub, + ← mul_assoc, Unitary.mul_star_self_of_mem v.property, one_mul, norm_sub_rev] + +lemma norm_harmonicPolynomial_mul_sub_le {A : Type*} [CStarAlgebra A] + (v : unitary A) (q : A) (n : ℕ) : + ‖harmonicPolynomial n (v : A) * q - (harmonic n : ℂ) • q‖ ≤ + (n : ℝ) * ‖(v : A) * q - q‖ := by + have heq : harmonicPolynomial n (v : A) * q - (harmonic n : ℂ) • q = + ∑ i ∈ range n, ((i + 1 : ℂ)⁻¹) • ((v : A) ^ (i + 1) * q - q) := by + simp [harmonicPolynomial, harmonic, smul_sub, sum_mul, + sum_smul, sum_sub_distrib] + rw [heq] + calc + _ ≤ ∑ i ∈ range n, ‖((i + 1 : ℂ)⁻¹) • ((v : A) ^ (i + 1) * q - q)‖ := norm_sum_le _ _ + _ ≤ ∑ _i ∈ range n, ‖(v : A) * q - q‖ := by + apply sum_le_sum + intro i _ + rw [norm_smul, norm_inv, ← Nat.cast_one (R := ℂ), ← Nat.cast_add, + Complex.norm_natCast] + calc + _ ≤ ((i + 1 : ℕ) : ℝ)⁻¹ * + (((i + 1 : ℕ) : ℝ) * ‖(v : A) * q - q‖) := by + gcongr + exact norm_unitary_pow_mul_sub_le v q (i + 1) + _ = _ := by rw [← mul_assoc, inv_mul_cancel₀ (by positivity), one_mul] + _ = _ := by simp + +lemma star_harmonicPolynomial {A : Type*} [Ring A] [StarRing A] [Algebra ℂ A] + [StarModule ℂ A] (v : A) (n : ℕ) : + star (harmonicPolynomial n v) = harmonicPolynomial n (star v) := by + simp [harmonicPolynomial, star_sum, star_smul, star_pow] + +lemma power_multiplier_smul {A : Type*} [CStarAlgebra A] (S : A →L[ℂ] A) + (u a : A) (hS : ∀ k : ℕ, 0 < k → S (u ^ k) = a * u ^ k) (c : ℂ) : + ∀ k : ℕ, 0 < k → S ((c • u) ^ k) = a * (c • u) ^ k := by + intro k hk + rw [smul_pow, map_smul, hS k hk, mul_smul_comm] + +lemma map_harmonicPolynomial {A : Type*} [CStarAlgebra A] (S : A →L[ℂ] A) + (u a : A) (hS : ∀ k : ℕ, 0 < k → S (u ^ k) = a * u ^ k) (n : ℕ) : + S (harmonicPolynomial n u) = a * harmonicPolynomial n u := by + simp only [harmonicPolynomial, map_sum, map_smul, hS _ (Nat.succ_pos _), + mul_sum, mul_smul_comm] + +end FourierWindows + +section TraceHilbertSpace +open scoped ComplexOrder +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) +lemma preGNS_norm_mul_le (a b : A) : + ‖τ.toPreGNS (a * b)‖ ≤ ‖a‖ * ‖τ.toPreGNS b‖ := by + calc + _ = ‖τ.leftMulMapPreGNS a (τ.toPreGNS b)‖ := rfl + _ ≤ ‖τ.leftMulMapPreGNS a‖ * ‖τ.toPreGNS b‖ := + (τ.leftMulMapPreGNS a).le_opNorm _ + _ ≤ _ := by + gcongr + unfold PositiveLinearMap.leftMulMapPreGNS + exact LinearMap.mkContinuous_norm_le _ (norm_nonneg _) _ +lemma preGNS_norm_one (h1 : τ 1 = 1) : ‖τ.toPreGNS 1‖ = 1 := by + have h := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS 1)) + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, star_one, one_mul, h1, + ← Complex.ofReal_pow, Complex.ofReal_re, Complex.one_re] at h + nlinarith [norm_nonneg (τ.toPreGNS 1)] +lemma preGNS_norm_le (h1 : τ 1 = 1) (a : A) : ‖τ.toPreGNS a‖ ≤ ‖a‖ := by + simpa only [mul_one, preGNS_norm_one τ h1] using preGNS_norm_mul_le τ a 1 +lemma preGNS_norm_star (htr : ∀ a b : A, τ (a*b) = τ (b*a)) (a : A) : + ‖τ.toPreGNS (star a)‖ = ‖τ.toPreGNS a‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + apply Complex.ofReal_injective + push_cast + simp only [τ.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS, star_star] + exact htr _ _ +lemma preGNS_norm_mul_right_le (htr : ∀ a b : A, τ (a*b) = τ (b*a)) (a b : A) : + ‖τ.toPreGNS (a * b)‖ ≤ ‖b‖ * ‖τ.toPreGNS a‖ := by + rw [← preGNS_norm_star τ htr, star_mul] + exact (preGNS_norm_mul_le τ (star b) (star a)).trans_eq + (by rw [norm_star, preGNS_norm_star τ htr]) +lemma preGNS_norm_eq_zero_iff + (hf : ∀ a : A, τ (star a * a) = 0 → a = 0) (a : A) : + ‖τ.toPreGNS a‖ = 0 ↔ a = 0 := by + constructor + · intro h + apply hf + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS, h, Complex.ofReal_zero, + zero_pow (by decide : 2 ≠ 0)] using (τ.preGNS_norm_sq (τ.toPreGNS a)).symm + · rintro rfl + simp + +open Finset +open scoped BigOperators +variable {ι : Type*} [Fintype ι] +lemma sum_preGNS_norm_mul_sq (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (q : ι → A) (hq : ∑ j, q j * star (q j) = 1) (a : A) : + ∑ j, ‖τ.toPreGNS (a * q j)‖ ^ 2 = ‖τ.toPreGNS a‖ ^ 2 := by + apply Complex.ofReal_injective + push_cast + simp only [τ.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS, star_mul] + calc + _ = ∑ j, τ ((star a * a) * (q j * star (q j))) := by + apply sum_congr rfl + intro j _ + simpa only [mul_assoc] using htr (star (q j)) ((star a * a) * q j) + _ = τ ((star a * a) * ∑ j, q j * star (q j)) := by rw [mul_sum, map_sum] + _ = _ := by rw [hq, mul_one] + +noncomputable def gnsFamily (f : ι → A) : PiLp 2 (fun _ : ι => τ.PreGNS) := + WithLp.toLp 2 (fun j => τ.toPreGNS (f j)) + +lemma norm_gnsFamily_sq (f : ι → A) : + ‖gnsFamily τ f‖ ^ 2 = ∑ j, ‖τ.toPreGNS (f j)‖ ^ 2 := + PiLp.norm_sq_eq_of_L2 _ _ + +omit [StarOrderedRing A] [Fintype ι] in +lemma gnsFamily_add (f g : ι → A) : + gnsFamily τ (fun j => f j + g j) = gnsFamily τ f + gnsFamily τ g := by + ext j + exact map_add τ.toPreGNS _ _ + +omit [StarOrderedRing A] [Fintype ι] in +lemma gnsFamily_sub (f g : ι → A) : + gnsFamily τ (fun j => f j - g j) = gnsFamily τ f - gnsFamily τ g := by + ext j + exact map_sub τ.toPreGNS _ _ + +omit [StarOrderedRing A] [Fintype ι] in +lemma gnsFamily_smul (c : ℂ) (f : ι → A) : + gnsFamily τ (fun j => c • f j) = c • gnsFamily τ f := by + ext j + exact map_smul τ.toPreGNS _ _ + +lemma norm_gnsFamily_mul (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + (q : ι → A) (hq : ∑ j, q j * star (q j) = 1) (a : A) : + ‖gnsFamily τ (fun j => a * q j)‖ = ‖τ.toPreGNS a‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_gnsFamily_sq, sum_preGNS_norm_mul_sq τ htr q hq] + +lemma norm_gnsFamily_leftMul_le (a f : ι → A) (C : ℝ) (hC : 0 ≤ C) + (ha : ∀ j, ‖a j‖ ≤ C) : + ‖gnsFamily τ (fun j => a j * f j)‖ ≤ C * ‖gnsFamily τ f‖ := by + apply (sq_le_sq₀ (norm_nonneg _) (mul_nonneg hC (norm_nonneg _))).mp + rw [mul_pow, norm_gnsFamily_sq, norm_gnsFamily_sq, mul_sum] + apply sum_le_sum + intro j _ + rw [← mul_pow] + apply pow_le_pow_left₀ (norm_nonneg _) + exact (preGNS_norm_mul_le τ _ _).trans (by gcongr; exact ha j) + +lemma norm_gnsFamily_sq_le (h1 : τ 1 = 1) (f : ι → A) (C : ℝ) + (hf : ∀ j, ‖f j‖ ≤ C) : + ‖gnsFamily τ f‖ ^ 2 ≤ (Fintype.card ι : ℝ) * C ^ 2 := by + rw [norm_gnsFamily_sq] + calc + _ ≤ ∑ _ : ι, C ^ 2 := by + apply sum_le_sum + intro j _ + exact pow_le_pow_left₀ (norm_nonneg _) ((preGNS_norm_le τ h1 _).trans (hf j)) _ + _ = _ := by simp + +lemma norm_gnsFamily_square_card_le (h1 : τ 1 = 1) {K : ℕ} [NeZero K] + (f : ZMod (K ^ 2) → A) (C : ℝ) (hC : 0 ≤ C) + (hf : ∀ j, ‖f j‖ ≤ C / (K : ℝ) ^ 2) : + ‖gnsFamily τ f‖ ≤ C / (K : ℝ) := by + apply (sq_le_sq₀ (norm_nonneg _) (div_nonneg hC (Nat.cast_nonneg _))).mp + have hK : (K : ℝ) ≠ 0 := Nat.cast_ne_zero.mpr (NeZero.ne K) + calc + _ ≤ (Fintype.card (ZMod (K ^ 2)) : ℝ) * (C / (K : ℝ) ^ 2) ^ 2 := + norm_gnsFamily_sq_le τ h1 f _ hf + _ = _ := by rw [ZMod.card, Nat.cast_pow]; field_simp + +lemma norm_gnsFamily_harmonic_error_le (h1 : τ 1 = 1) {K : ℕ} [NeZero K] + (q : ZMod (K ^ 2) → A) (v : ZMod (K ^ 2) → unitary A) + (hv : ∀ j, ‖(v j : A) * q j - q j‖ ≤ 2 / (K : ℝ) ^ 2) (n : ℕ) : + ‖gnsFamily τ (fun j => harmonicPolynomial n (v j : A) * q j - + (harmonic n : ℂ) • q j)‖ ≤ (2 * n : ℝ) / (K : ℝ) := by + apply norm_gnsFamily_square_card_le τ h1 _ _ (by positivity) + intro j + calc + _ ≤ (n : ℝ) * ‖(v j : A) * q j - q j‖ := norm_harmonicPolynomial_mul_sub_le _ _ _ + _ ≤ (n : ℝ) * (2 / (K : ℝ) ^ 2) := by gcongr; exact hv j + _ = _ := by ring + + + +theorem unitary_power_multiplier_bound [Nontrivial A] + (h1 : τ 1 = 1) (htr : ∀ a b : A, τ (a * b) = τ (b * a)) + (S : A →L[ℂ] A) (u : unitary A) (a b : A) + (hpos : ∀ k : ℕ, 0 < k → S ((u : A) ^ k) = a * (u : A) ^ k) + (hneg : ∀ k : ℕ, 0 < k → S ((star u : A) ^ k) = b * (star u : A) ^ k) + (n : ℕ) {K : ℕ} [NeZero K] : + (harmonic n : ℝ) * ‖τ.toPreGNS (a - b)‖ ≤ + (2 * (1 + Real.pi)) * ‖S‖ + (‖a‖ + ‖b‖) * ((2 * n : ℝ) / K) := by + let q : ZMod (K ^ 2) → A := fun j => fourierWindow (u : A) j + let v : ZMod (K ^ 2) → unitary A := fun j => rootUnitary (-j) • u + have hvdef (j) : (v j : A) = (ZMod.stdAddChar (-j)) • (u : A) := rfl + have hq : ∑ j, q j * star (q j) = 1 := sum_fourierWindow_mul_star u + have hv (j) : ‖(v j : A) * q j - q j‖ ≤ 2 / (K : ℝ) ^ 2 := by + simpa only [q, v, Nat.cast_pow] using norm_unitary_mul_fourierWindow_sub_le u j + have hvneg (j) : ‖(star (v j) : A) * q j - q j‖ ≤ 2 / (K : ℝ) ^ 2 := by + rw [norm_star_unitary_mul_sub] + exact hv j + let ep := fun j => harmonicPolynomial n (v j : A) * q j - (harmonic n : ℂ) • q j + let em := fun j => star (harmonicPolynomial n (v j : A)) * q j - (harmonic n : ℂ) • q j + let F := fun j => S (harmonicPolynomial n (v j : A) - star (harmonicPolynomial n (v j : A))) + have hep : ‖gnsFamily τ ep‖ ≤ (2 * n : ℝ) / K := + norm_gnsFamily_harmonic_error_le τ h1 q v hv n + have hem : ‖gnsFamily τ em‖ ≤ (2 * n : ℝ) / K := by + simpa only [em, star_harmonicPolynomial, Unitary.coe_star] using + norm_gnsFamily_harmonic_error_le τ h1 q (fun j => star (v j)) hvneg n + have hF (j) : F j = a * harmonicPolynomial n (v j : A) - + b * star (harmonicPolynomial n (v j : A)) := by + have hp : ∀ k : ℕ, 0 < k → S ((v j : A) ^ k) = a * (v j : A) ^ k := by + simpa only [hvdef] using power_multiplier_smul S (u : A) a hpos (ZMod.stdAddChar (-j)) + have hn : ∀ k : ℕ, 0 < k → S (star (v j : A) ^ k) = b * star (v j : A) ^ k := by + simpa only [hvdef, star_smul] using + power_multiplier_smul S (star u : A) b hneg (star (ZMod.stdAddChar (-j))) + simp only [F, map_sub, star_harmonicPolynomial] + rw [map_harmonicPolynomial S _ a hp, map_harmonicPolynomial S _ b hn] + have hFbound (j) : ‖F j‖ ≤ (2 * (1 + Real.pi)) * ‖S‖ := by + calc + _ ≤ ‖S‖ * ‖harmonicPolynomial n (v j : A) - star (harmonicPolynomial n (v j : A))‖ := S.le_opNorm _ + _ ≤ ‖S‖ * (2 * (1 + Real.pi)) := by + gcongr + exact norm_unitary_harmonicPolynomial_sub_star_le (v j) n + _ = _ := mul_comm _ _ + have hqn : ‖gnsFamily τ q‖ = 1 := by + simpa only [one_mul, preGNS_norm_one τ h1] using norm_gnsFamily_mul τ htr q hq 1 + have hFn : ‖gnsFamily τ (fun j => F j * q j)‖ ≤ (2 * (1 + Real.pi)) * ‖S‖ := by + simpa only [hqn, mul_one] using + norm_gnsFamily_leftMul_le τ F q _ (by positivity) hFbound + have hepn : ‖gnsFamily τ (fun j => a * ep j)‖ ≤ ‖a‖ * ((2 * n : ℝ) / K) := + (norm_gnsFamily_leftMul_le τ (fun _ => a) ep ‖a‖ (norm_nonneg _) (fun _ => le_rfl)).trans + (by gcongr) + have hemn : ‖gnsFamily τ (fun j => b * em j)‖ ≤ ‖b‖ * ((2 * n : ℝ) / K) := + (norm_gnsFamily_leftMul_le τ (fun _ => b) em ‖b‖ (norm_nonneg _) (fun _ => le_rfl)).trans + (by gcongr) + have hid (j) : (harmonic n : ℂ) • ((a - b) * q j) = + F j * q j - a * ep j + b * em j := by + simp only [hF j, ep, em, sub_mul, mul_sub, smul_sub, mul_smul_comm] + noncomm_ring + have hh : 0 ≤ (harmonic n : ℝ) := by unfold harmonic; positivity + have hhnorm : ‖(harmonic n : ℂ)‖ = (harmonic n : ℝ) := by + rw [← Complex.ofReal_ratCast, Complex.norm_real, Real.norm_of_nonneg hh] + calc + _ = ‖gnsFamily τ (fun j => (harmonic n : ℂ) • ((a - b) * q j))‖ := by + rw [gnsFamily_smul, norm_smul, hhnorm, norm_gnsFamily_mul τ htr q hq] + _ = ‖gnsFamily τ (fun j => F j * q j) - gnsFamily τ (fun j => a * ep j) + + gnsFamily τ (fun j => b * em j)‖ := by + simp only [hid, gnsFamily_add, gnsFamily_sub] + _ ≤ (‖gnsFamily τ (fun j => F j * q j)‖ + ‖gnsFamily τ (fun j => a * ep j)‖) + + ‖gnsFamily τ (fun j => b * em j)‖ := + (norm_add_le _ _).trans (by gcongr; exact norm_sub_le _ _) + _ ≤ _ := by nlinarith [hFn, hepn, hemn] + + + +theorem unitary_power_rigidity + (h1 : τ 1 = 1) (htr : ∀ a b : A, τ (a * b) = τ (b * a)) + (hfaithful : ∀ x : A, τ (star x * x) = 0 → x = 0) + (S : A →L[ℂ] A) (u : unitary A) (a b : A) + (hpos : ∀ k : ℕ, 0 < k → S ((u : A) ^ k) = a * (u : A) ^ k) + (hneg : ∀ k : ℕ, 0 < k → S ((star u : A) ^ k) = b * (star u : A) ^ k) : + a = b := by + classical + rcases subsingleton_or_nontrivial A with hA | hA + · exact Subsingleton.elim _ _ + let C : ℝ := (2 * (1 + Real.pi)) * ‖S‖ + have hbound (n : ℕ) : (harmonic n : ℝ) * ‖τ.toPreGNS (a - b)‖ ≤ C := by + have hl : Filter.Tendsto (fun m : ℕ => + C + (‖a‖ + ‖b‖) * ((2 * n : ℝ) / ((m : ℝ) + 1))) + Filter.atTop (nhds C) := by + simpa only [mul_zero, add_zero, mul_one_div] using + tendsto_const_nhds.add + ((tendsto_one_div_add_atTop_nhds_zero_nat (𝕜 := ℝ)).const_mul (2 * (n : ℝ)) |>.const_mul (‖a‖ + ‖b‖)) + apply ge_of_tendsto hl + apply Filter.Eventually.of_forall + intro m + simpa only [Nat.cast_add, Nat.cast_one] using + unitary_power_multiplier_bound τ h1 htr S u a b hpos hneg n (K := m + 1) + have hdiv : Filter.Tendsto (fun n : ℕ => (harmonic n : ℝ)) Filter.atTop Filter.atTop := + Filter.tendsto_atTop_mono log_add_one_le_harmonic + (Real.tendsto_log_atTop.comp + ((tendsto_natCast_atTop_atTop : Filter.Tendsto (fun n : ℕ => (n : ℝ)) + Filter.atTop Filter.atTop).comp (Filter.tendsto_add_atTop_nat 1))) + have hz : ‖τ.toPreGNS (a - b)‖ = 0 := by + by_contra hne + have hp : 0 < ‖τ.toPreGNS (a - b)‖ := lt_of_le_of_ne (norm_nonneg _) (Ne.symm hne) + obtain ⟨n, hn⟩ := ((hdiv.atTop_mul_const hp).eventually_gt_atTop C).exists + exact (not_lt_of_ge (hbound n)) hn + exact sub_eq_zero.mp ((preGNS_norm_eq_zero_iff τ hfaithful (a - b)).mp hz) + +end TraceHilbertSpace + +end HochschildRigidity +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/HomogeneousCornerTransport.lean b/lean/OAI/Analysis/BoundedHochschild/HomogeneousCornerTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..cf6cc328afab187ca3963f7cfa0eb98715abcb00 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/HomogeneousCornerTransport.lean @@ -0,0 +1,73 @@ +import OAI.Analysis.BoundedHochschild.TracialTypeIHomogeneousPiece +import OAI.Analysis.BoundedHochschild.CentralTypeIIInheritance + +namespace OAI + +/-! Transport of the homogeneous pieces used in the finite type I partition. -/ + +noncomputable section + +namespace HochschildMatrixSystems.MatrixSystem + +variable {M N : Type*} [CStarAlgebra M] [CStarAlgebra N] {n : ℕ} + +def mapEquiv (E : HochschildMatrixSystems.MatrixSystem M n) (φ : M ≃⋆ₐ[ℂ] N) : + HochschildMatrixSystems.MatrixSystem N n where + entry i j := φ (E.entry i j) + star_entry i j := by rw [← map_star, E.star_entry] + entry_mul i j k l := by rw [← map_mul, E.entry_mul]; split_ifs <;> simp + sum_diagonal := by rw [← map_sum, E.sum_diagonal, map_one] + +end HochschildMatrixSystems.MatrixSystem + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners HochschildMatrixSystems FinitePathMain + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma abelian_map_equiv {N : Type*} [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N] + (φ : M ≃⋆ₐ[ℂ] N) {p : M} (hp : AbelianProjection p) : AbelianProjection (φ p) := + finitePath_abelian_of_popa (hp.1.map φ) + (abelianProjection_map_equiv φ hp.1 (popa_abelian_of_finitePath hp)) + +def projectionInCorner {z p : M} (hz : IsStarProjection z) (hp : IsStarProjection p) + (hpz : p ≤ z) : Corner z hz := ⟨p, projection_mem_corner hz hp hpz⟩ + +lemma projectionInCorner_abelian {z p : M} (hz : IsStarProjection z) + (hp : AbelianProjection p) (hpz : p ≤ z) : + AbelianProjection (projectionInCorner hz hp.1 hpz) := by + refine ⟨⟨Subtype.ext hp.1.isIdempotentElem.eq, Subtype.ext hp.1.isSelfAdjoint.star_eq⟩, ?_⟩ + intro a b + exact Subtype.ext (hp.2 (a : M) (b : M)).eq + +lemma centralSupport_in_corner {z p : M} (hz : IsStarProjection z) + (hzc : ∀ a : M, z * a = a * z) (hp : IsStarProjection p) (h : IsCentralSupport p z) : + IsCentralSupport (projectionInCorner hz hp h.2.1) (1 : Corner z hz) := by + refine ⟨⟨IsStarProjection.one _, fun _ => Commute.one_left _⟩, ?_, ?_⟩ + · exact (show IsStarProjection (projectionInCorner hz hp h.2.1) from + ⟨Subtype.ext hp.isIdempotentElem.eq, Subtype.ext hp.isSelfAdjoint.star_eq⟩).le_one + · intro c hc hcp + have hcM : CentralProjection (c : M) := + ⟨corner_projection_coe z hz hc.1, + fun a => centralCorner_central hz hzc c (fun b => (hc.2 b).eq) a⟩ + have hcpM : (c : M) * p = 0 := congrArg Subtype.val hcp + have hcz := h.2.2 (c : M) hcM hcpM + have hc0 : c = 0 := by + apply Subtype.ext + change (c : M) = 0 + simpa only [c.property.2] using hcz + simp only [hc0, zero_mul] + +lemma homogeneousCorner_to_ambient {z : M} (hz : IsStarProjection z) + (q : Corner z hz) (hq : HomogeneousTypeICorner q) : + HomogeneousTypeICorner (q : M) := by + obtain ⟨hqp, n, E, i, hi⟩ := hq + let φ := nestedCornerEquiv hz q hqp + exact ⟨corner_projection_coe z hz hqp, n, E.mapEquiv φ, i, abelian_map_equiv φ hi⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/HomogeneousPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/HomogeneousPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..73df591c0b7ad136871d9a818466dd9651bb5c1b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/HomogeneousPrimitives.lean @@ -0,0 +1,133 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers +import OAI.Analysis.BoundedHochschild.CompactAverages +import OAI.Analysis.BoundedHochschild.MatrixAlgebras +import OAI.Analysis.BoundedHochschild.SubalgebraModules +import OAI.Analysis.BoundedHochschild.CommutingExtensions + +namespace OAI + +/-! Bounded primitives for homogeneous type-I matrix algebras. -/ + +noncomputable section + +namespace BoundedHochschild +open Filter Topology TopologicalSpace MeasureTheory MeasureTheory.Measure +open HochschildMatrixSystems +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +include e in +theorem primitive_of_homogeneous_typeI {d : ℕ} (E : MatrixSystem M d) + (hcomm : ∀ a b : E.commutant, a*b=b*a) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤‖f‖ ∧ ∀ x, differentialValue g x=f x := by + classical + let A := E.matrixAlgebra + let B := E.commutant + let K := unitary A + let compactUnitaryMeasurableSpace : MeasurableSpace K := borel K + let compactUnitaryBorelSpace : BorelSpace K := ⟨rfl⟩ + let K₀ : PositiveCompacts K := ⟨⟨Set.univ,isCompact_univ⟩,by simp⟩ + let μ : Measure K := haarMeasure K₀ + let compactUnitaryProbabilityMeasure : IsProbabilityMeasure μ := ⟨haarMeasure_self⟩ + let ρ : K →* unitary M := unitaryInclusion A + have hρ : Continuous ρ := continuous_unitaryInclusion A + let F := compactAverage ρ μ f + have hF : ‖F‖≤‖f‖ := norm_compactAverage_le ρ μ f + have hfix : ∀ v ∈ Set.range ρ, translateLast F v=F := by + rintro v ⟨u,rfl⟩ + exact compactAverage_fixed ρ hρ μ f u + let σ : unitary B →* unitary M := unitaryInclusion B + have hσcomm (s t : unitary B) : Commute (σ s) (σ t) := by + apply Subtype.ext + exact congrArg (fun b : B => (b:M)) (hcomm (s:B) (t:B)) + have hcross (s : unitary B) (v : unitary M) (hv : v ∈ Set.range ρ) : Commute (σ s) v := by + obtain ⟨t,rfl⟩ := hv + apply Subtype.ext + exact (E.commutant_commutes_matrix (s:B) (t:A)).eq + have hr : ∀ v x, residualCLM x (translateLast F v)=((-1:ℂ)^(n+1)) • f x := + compactAverage_residual ρ hρ μ f _ (residual_translate_cocycle f hf) + obtain ⟨G,hG,hGA,hGB,hGr⟩ := exists_commuting_extension e σ (Set.range ρ) + (HochschildSakai.mul_hasPreadjoint e) (HochschildSakai.mul_right_hasPreadjoint e) + hσcomm hcross F hfix _ hr + have hA : ∀ u : unitary A, translateLast G (unitaryInclusion A u)=G := + fun u => hGA _ ⟨u,rfl⟩ + have hB : ∀ u : unitary B, translateLast G (unitaryInclusion B u)=G := hGB + have hmod : ∀ (a : Fin n → M) (x : M), G (Fin.snoc a x)=G (Fin.snoc a 1)*x := by + intro a x + let L := G.curryRight a + have hAm (y : A) : L (y:M)=L 1*(y:M) := by + simpa only [one_mul,L,ContinuousMultilinearMap.curryRight_apply] using right_module_subalgebra A G hA a 1 y + have hBm (y : M) (z : B) : L (y*(z:M))=L y*(z:M) := + right_module_subalgebra B G hB a y z + change L x=L 1*x + calc + L x = L (∑ i,∑ j,E.entry i j*E.coefficient i j x) := congrArg L (E.reconstruct x).symm + _ = ∑ i,∑ j,L (E.entry i j*E.coefficient i j x) := by simp only [_root_.map_sum] + _ = ∑ i,∑ j,(L 1*E.entry i j)*E.coefficient i j x := by + apply Finset.sum_congr rfl + intro i hi + apply Finset.sum_congr rfl + intro j hj + rw [hBm (E.entry i j) ⟨_,E.coefficient_mem i j x⟩, + hAm ⟨_,E.entry_mem_span i j⟩] + _ = L 1*(∑ i,∑ j,E.entry i j*E.coefficient i j x) := by + simp only [Finset.mul_sum,mul_assoc] + _ = L 1*x := congrArg (fun y : M => L 1*y) (E.reconstruct x) + apply primitive_from_average f G (hG.trans hF) ?_ hmod + intro x + simpa only [translateLast_one] using hGr 1 x + +omit [PartialOrder M] [StarOrderedRing M] in +lemma commutant_commutative_of_abelian_diagonal {d : ℕ} (E : MatrixSystem M d) + (i : Fin d) (hp : FinitePathMain.AbelianProjection (E.entry i i)) : + ∀ a b : E.commutant, a*b=b*a := by + intro a b + have he (y : E.commutant) : E.entry i i*(y:M)*E.entry i i=E.entry i i*(y:M) := by + rw [mul_assoc,(y.property i i).eq,← mul_assoc,hp.1.isIdempotentElem.eq] + have hm (y z : E.commutant) : + (E.entry i i*(y:M))*(E.entry i i*(z:M))=E.entry i i*((y:M)*(z:M)) := by + rw [← mul_assoc,he,mul_assoc] + have h := (hp.2 (a:M) (b:M)).eq + rw [he,he,hm,hm] at h + have hh := congrArg (E.coefficient i i) h + change E.coefficient i i (E.entry i i*((a*b : E.commutant):M)) = + E.coefficient i i (E.entry i i*((b*a : E.commutant):M)) at hh + rw [E.coefficient_of_commutant i (a*b).property, + E.coefficient_of_commutant i (b*a).property] at hh + exact Subtype.ext hh + +include e in +theorem primitive_of_abelian_matrix_diagonal {d : ℕ} (E : MatrixSystem M d) + (i : Fin d) (hp : FinitePathMain.AbelianProjection (E.entry i i)) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤‖f‖ ∧ ∀ x, differentialValue g x=f x := + primitive_of_homogeneous_typeI e E (commutant_commutative_of_abelian_diagonal E i hp) f hf + +theorem primitive_of_homogeneous_typeI_wstar [WStarAlgebra M] {d : ℕ} (E : MatrixSystem M d) + (hcomm : ∀ a b : E.commutant, a*b=b*a) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) : + ∃ g : Cochain M n, ‖g‖≤‖f‖ ∧ ∀ x, differentialValue g x=f x := by + obtain ⟨Y,hY,hN,hC,⟨d⟩⟩ := WStarAlgebra.exists_predual (M:=M) + let predualNormedAddCommGroup := hY + let predualNormedSpace := hN + let predualCompleteSpace := hC + exact primitive_of_homogeneous_typeI d E hcomm f hf + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeI.lean b/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeI.lean new file mode 100644 index 0000000000000000000000000000000000000000..300805e5dfc00658eddd45e5fdbae0d1acd15364 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeI.lean @@ -0,0 +1,60 @@ +import OAI.Analysis.BoundedHochschild.SignedMatrixUnitaries +import OAI.Analysis.BoundedHochschild.CentralBlockSpans +import OAI.Analysis.BoundedHochschild.TypeICentralSupport + +namespace OAI + +/-! The abelian commutant of a finite homogeneous type I matrix system. -/ + +noncomputable section + +namespace HochschildMatrixSystems +namespace MatrixSystem + +variable {M : Type*} [CStarAlgebra M] {n : ℕ} (E : MatrixSystem M n) + +lemma commutant_central (hcomm : ∀ a b : E.commutant, Commute a b) + (a : E.commutant) (x : M) : (a : M) * x = x * (a : M) := by + have hc : Commute (a : M) x := by + rw [← E.reconstruct x] + apply Commute.sum_right + intro i _ + apply Commute.sum_right + intro j _ + exact (a.property i j).mul_right (show Commute (a : M) (E.coefficient i j x) from + congrArg (fun z : E.commutant => (z : M)) + (hcomm a ⟨_, E.coefficient_mem i j x⟩).eq) + exact hc.eq + +lemma commutant_commutative_of_abelian_diagonal (i : Fin n) + (hi : FinitePathMain.AbelianProjection (E.entry i i)) : + ∀ a b : E.commutant, Commute a b := by + intro a b + have hcut (a : E.commutant) : E.entry i i * (a : M) * E.entry i i = + E.entry i i * (a : M) := by + rw [mul_assoc, (a.property i i).eq, ← mul_assoc, (E.diagonal_proj i).isIdempotentElem.eq] + have hprod (a b : E.commutant) : + (E.entry i i * (a : M)) * (E.entry i i * (b : M)) = + E.entry i i * ((a : M) * (b : M)) := by + calc + _ = (E.entry i i * (a : M) * E.entry i i) * (b : M) := by noncomm_ring + _ = _ := by rw [hcut]; noncomm_ring + have h := hi.2 (a : M) (b : M) + change (E.entry i i * (a : M) * E.entry i i) * + (E.entry i i * (b : M) * E.entry i i) = + (E.entry i i * (b : M) * E.entry i i) * + (E.entry i i * (a : M) * E.entry i i) at h + simp only [hcut, hprod] at h + have he := congrArg (E.coefficient i i) h + change E.coefficient i i (E.entry i i * ((a * b : E.commutant) : M)) = + E.coefficient i i (E.entry i i * ((b * a : E.commutant) : M)) at he + rw [E.coefficient_of_commutant i (a * b).property, + E.coefficient_of_commutant i (b * a).property] at he + exact Subtype.ext he + +end MatrixSystem +end HochschildMatrixSystems + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeIPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeIPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..127375c0a6ee5daa8abb050a1fd82b14fed71d64 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/HomogeneousTypeIPrimitives.lean @@ -0,0 +1,101 @@ +import OAI.Analysis.BoundedHochschild.MatrixBlockGroups + +namespace OAI + +/-! +# Norm-one primitives on finite homogeneous type I algebras + +Finite central partitions and signed permutation groups give exact homotopies +on central projection multiples of matrix entries. Their bounded weak-star +limit is exact everywhere by the projection-span theorem in the commutant. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder BigOperators + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildMatrixSystems HochschildSakai + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem finite_homogeneous_typeI_primitive (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {d : ℕ} (E : MatrixSystem M d) (hcomm : ∀ a b : E.commutant, Commute a b) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + classical + let : CommCStarAlgebra E.commutant := { mul_comm := fun a b => (hcomm a b).eq } + obtain ⟨P, _, hP⟩ := exists_abstract_star_preadjoint e + let eC := E.commutantPredualEquiv e (mul_hasPreadjoint e) + (mul_right_hasPreadjoint e) P hP + let Q := {q : E.commutant // IsStarProjection q} + choose r p hp ho hs href using fun S : Finset Q => exists_refining_partition S + let := Fintype.ofFinite E.signedPermutationGroup + let F (S : Finset Q) : Cochain M n := finiteUnitaryHomotopy + (E.matrixBlockHom hcomm (p S) (hp S) (ho S) (hs S)) f + have hFn (S : Finset Q) : ‖F S‖ ≤ ‖f‖ := finiteUnitaryHomotopy_norm _ f + let U : Ultrafilter (Finset Q) := Ultrafilter.of atTop + have hU : (U : Filter (Finset Q)) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨g, hgn, ht⟩ := bounded_cochain_ultralimit e U F ‖f‖ (norm_nonneg _) hFn + have hproj (q : Q) (a b : Fin d) (x : Fin n → M) : + differentialValue g (Fin.cons ((q.val : M) * E.entry a b) x) = + f (Fin.cons ((q.val : M) * E.entry a b) x) := by + have he : (fun S => differentialValue (F S) + (Fin.cons ((q.val : M) * E.entry a b) x)) =ᶠ[U] + (fun _ => f (Fin.cons ((q.val : M) * E.entry a b) x)) := by + apply hU + filter_upwards [eventually_ge_atTop ({q} : Finset Q)] with S hS + exact finiteUnitaryHomotopy_exact_span _ f hf + (E.matrixBlock_refined_entry_mem_span hcomm (p S) (hp S) (ho S) (hs S) q.val + (href S q (hS (Finset.mem_singleton_self q))) a b) x + apply predual_tendsto_unique e (predual_tendsto_differential_of_predual e ht _) + intro z + exact tendsto_const_nhds.congr' (he.mono fun _ h => + congrArg (fun a : M => e.symm a z) h.symm) + refine ⟨g, hgn, fun x => ?_⟩ + let L := firstSliceN (differential g - f) (Fin.tail x) + have hcoord (a b : Fin d) (c : E.commutant) : L ((c : M) * E.entry a b) = 0 := by + let T : E.commutant →L[ℂ] M := L.comp + (((ContinuousLinearMap.mul ℂ M).flip (E.entry a b)).comp + E.commutant.toSubalgebra.toSubmodule.subtypeL) + have hspan : Submodule.span ℂ {q : E.commutant | IsStarProjection q} ≤ T.ker := by + apply Submodule.span_le.mpr + intro q hq + change L ((q : M) * E.entry a b) = 0 + simpa only [L, firstSliceN_apply, sub_apply, differential_apply] using + sub_eq_zero.mpr (hproj ⟨q, hq⟩ a b (Fin.tail x)) + have hclosed := Submodule.topologicalClosure_minimal _ hspan T.isClosed_ker + rw [projection_span_dense eC] at hclosed + exact hclosed (Submodule.mem_top : c ∈ (⊤ : Submodule ℂ E.commutant)) + have hzero : L (x 0) = 0 := by + rw [← E.reconstruct (x 0), map_sum] + apply Finset.sum_eq_zero + intro a _ + rw [map_sum] + apply Finset.sum_eq_zero + intro b _ + have h := hcoord a b ⟨_, E.coefficient_mem a b (x 0)⟩ + simpa only [(E.coefficient_mem a b (x 0) a b).eq] using h + apply sub_eq_zero.mp + simpa only [L, firstSliceN_apply, sub_apply, differential_apply, Fin.cons_self_tail] using hzero + +/-- An abelian diagonal corner is the concrete homogeneous type I hypothesis. -/ +theorem finite_homogeneous_typeI_primitive_of_abelian_diagonal + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {d : ℕ} (E : MatrixSystem M d) (i : Fin d) + (hi : FinitePathMain.AbelianProjection (E.entry i i)) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := + finite_homogeneous_typeI_primitive e E (E.commutant_commutative_of_abelian_diagonal i hi) f hf + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/IncrementalPatching.lean b/lean/OAI/Analysis/BoundedHochschild/IncrementalPatching.lean new file mode 100644 index 0000000000000000000000000000000000000000..eead32cda5d20163fb363d98ecae01a070a3fbd8 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/IncrementalPatching.lean @@ -0,0 +1,398 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MixedWords +import OAI.Analysis.BoundedHochschild.RelativeQuantization + +namespace OAI + +/-! Corner partial unitaries, incremental moment estimates and unitary completion. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped BigOperators ComplexConjugate InnerProductSpace +open scoped BigOperators ComplexConjugate InnerProductSpace ComplexOrder +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildSakai HochschildCorners HochschildComparison +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (q : M) (hq : IsStarProjection q) + +def ofCornerUnitary (u : unitary (Corner q hq)) : PartialUnitary M := + ⟨⟨((u : Corner q hq):M),by + have hh := congrArg (fun a : Corner q hq => (a : M)) (Unitary.coe_mul_star_self u) + change ((u : Corner q hq):M)*star ((u : Corner q hq):M)=q at hh + rw [hh] + exact (u : Corner q hq).property.1⟩,by + have hl := congrArg (fun a : Corner q hq => (a : M)) (Unitary.coe_mul_star_self u) + have hr := congrArg (fun a : Corner q hq => (a : M)) (Unitary.coe_star_mul_self u) + exact hl.trans hr.symm⟩ +@[simp] lemma ofCornerUnitary_coe (u : unitary (Corner q hq)) : + ((ofCornerUnitary q hq u : PartialUnitary M):M)=((u : Corner q hq):M) := rfl +@[simp] lemma ofCornerUnitary_support (u : unitary (Corner q hq)) : + (ofCornerUnitary q hq u).support=q := by + exact congrArg (fun a : Corner q hq => (a : M)) (Unitary.coe_star_mul_self u) + +lemma corner_coe_pow_succ (a : Corner q hq) (n : ℕ) : ((a^(n+1) : Corner q hq):M)=(a:M)^(n+1) := by + induction n with + | zero => simp + | succ n ih => + rw [pow_succ (a := a),corner_coe_mul,ih] + exact (pow_succ (a : M) (n+1)).symm + +def signedExponent (k : Bool × ℕ) : ℤ := if k.1 then -((k.2 : ℤ)+1) else (k.2 : ℤ)+1 +lemma signedExponent_ne_zero (k : Bool × ℕ) : signedExponent k ≠ 0 := by + dsimp [signedExponent]; split <;> omega +lemma ofCornerUnitary_power (u : unitary (Corner q hq)) (k : Bool × ℕ) : + (ofCornerUnitary q hq u).power k=(((u^signedExponent k : unitary (Corner q hq)) : Corner q hq):M) := by + dsimp only [PartialUnitary.power,signedExponent] + split + · rw [zpow_neg,show (k.2 : ℤ)+1=((k.2+1 : ℕ):ℤ) by simp,zpow_natCast,← Unitary.star_eq_inv, + Unitary.coe_star,SubmonoidClass.coe_pow,corner_coe_star,corner_coe_pow_succ,star_pow] + rfl + · rw [show (k.2 : ℤ)+1=((k.2+1 : ℕ):ℤ) by simp,zpow_natCast,SubmonoidClass.coe_pow,corner_coe_pow_succ] + rfl + +variable [PartialOrder M] [StarOrderedRing M] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable {I : Type v} [Fintype I] +include e hq in +theorem exists_partial_unitary_weak_powers + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) (hq0 : q ≠ 0) + (a : I → M) (k : I → Bool × ℕ) {ε : ℝ} (hε : 0<ε) : + ∃ w : PartialUnitary M, w.support=q ∧ ∀ i, ‖τ (a i*w.power (k i))‖<ε*(τ q).re := by + let eC := cornerPredualEquiv q hq e + let ρ := cornerTrace q hq τ + let b : I → Corner q hq := fun i => ⟨q*a i*q,compress_mem_corner hq (a i)⟩ + have ht : 0<(τ q).re := HochschildDiffuse.projection_trace_pos τ hfaith hq hq0 + obtain ⟨u,hu⟩ := HochschildMatrixSystems.exists_unitary_weak_powers eC ρ + (cornerTrace_normal q hq e τ hτ) (cornerTrace_one q hq τ hfaith hq0) + (cornerTrace_tracial q hq τ htr) (cornerTrace_faithful q hq τ hfaith hq0) + (corner_factor q hq e τ hτ h1 htr hfaith hfactor hdiff hq0) + (corner_no_minimal q hq hdiff) b (fun i => signedExponent (k i)) (fun i => signedExponent_ne_zero _) hε + refine ⟨ofCornerUnitary q hq u,ofCornerUnitary_support q hq u,fun i => ?_⟩ + let v : Corner q hq := (u^signedExponent (k i) : unitary (Corner q hq)) + have hvq : (v:M)*q=(v:M) := v.property.2 + have hqv : q*(v:M)=(v:M) := v.property.1 + have he : τ ((b i*v : Corner q hq):M)=τ (a i*(v:M)) := by + change τ (q*a i*q*(v:M))=_ + calc + _ = τ (q*(a i*(v:M))) := by rw [mul_assoc,mul_assoc,hqv] + _ = τ ((a i*(v:M))*q) := htr _ _ + _ = _ := by rw [mul_assoc,hvq] + have hh := hu i + change ‖cornerTrace q hq τ (b i*v)‖<ε at hh + rw [cornerTrace_apply,he,norm_mul,norm_inv,Complex.norm_real,Real.norm_eq_abs,abs_of_pos ht] at hh + rw [ofCornerUnitary_power] + have hh' := (mul_lt_mul_of_pos_left hh ht) + simpa only [← mul_assoc,mul_inv_cancel₀ ht.ne',one_mul,mul_comm (τ q).re ε] using hh' +end HochschildPatching + + + + + + + +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +universe u v +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {I : Type v} [Fintype I] (F : I → M) +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +include e in +lemma exists_incremental_patch + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (hF : ∀ i, ‖F i‖ ≤ 1) (hFτ : ∀ i, τ (F i)=0) + {K N : ℕ} (hK : 0 mixedEval F v a.1 a.2.val) (sq_pos_of_pos hε) hη + obtain ⟨w,hw,hweak⟩ := exists_partial_unitary_weak_powers q hq e τ hτ h1 htr hfaith hfactor hdiff hq0 + (linearCoeff F v (K := K) (N := N)) linearPower hε + have horth : v.support*w.support=0 := by + rw [hw] + have hh := (hq.le_iff_mul_eq_right v.support_proj.one_sub).mp hqv + rw [sub_mul,one_mul,sub_eq_self] at hh + exact hh + have hwpos : 0<(τ w.support).re := by rw [hw]; exact HochschildDiffuse.projection_trace_pos τ hfaith hq hq0 + refine ⟨w,horth,hwpos,by rwa [hw],fun a ha => ?_⟩ + have hsmall : ∀ z : BoundedWord I K N, + ‖τ.toPreGNS (w.support*mixedEval F v z.1 z.2.val*w.support- + residualScalar τ v (mixedEval F v z.1 z.2.val) • w.support)‖ ≤ ε*‖τ.toPreGNS w.support‖ := by + intro z + rw [hw] + apply le_of_sq_le_sq _ (mul_nonneg hε.le (norm_nonneg _)) + rw [mul_pow,projection_gns_sq τ hq] + exact (hqsmall z).le + have hlin := linear_trace_bound F τ htr v w a.1 a.2.val a.2.property + (ε*(τ w.support).re) (fun j => by rw [hw]; exact (hweak j).le) + have hquad := quadratic_trace_bound F τ htr v w horth hK hF hFτ hb hv hp ε hsmall + a.1 a.2.val a.2.property ha + have hh := mixedEval_patch_bound F τ v w horth a.1 a.2.val a.2.property + (mul_nonneg hε.le hwpos.le) + (mul_nonneg (add_nonneg hε.le (div_nonneg (mul_nonneg (by norm_num) hb) hp.le)) hwpos.le) hlin hquad + rw [hpt] at hh + calc + _ ≤ ‖τ (mixedEval F v a.1 a.2.val)‖+(N : ℝ)*(ε*(τ w.support).re)+ + (N : ℝ)^2*((ε+2*b ((τ v.support).re)/(1-(τ v.support).re))*(τ w.support).re) := hh + _ ≤ b ((τ v.support).re)+(N : ℝ)*(ε*(τ w.support).re)+ + (N : ℝ)^2*((ε+2*b ((τ v.support).re)/(1-(τ v.support).re))*(τ w.support).re) := + add_le_add (add_le_add (hv a ha) le_rfl) le_rfl + _ = _ := by ring + +end HochschildPatching + + + + + + + +namespace HochschildPatching + +def expBudget (δ C s : ℝ) : ℝ := δ*(Real.exp (C*s)-1) +lemma expBudget_zero (δ C : ℝ) : expBudget δ C 0=0 := by simp [expBudget] +lemma expBudget_continuous (δ C : ℝ) : Continuous (expBudget δ C) := by unfold expBudget; fun_prop +lemma expBudget_nonneg {δ C s : ℝ} (hδ : 0 ≤ δ) (hC : 0 ≤ C) (hs : 0 ≤ s) : 0 ≤ expBudget δ C s := by + exact mul_nonneg hδ (sub_nonneg.mpr (Real.one_le_exp_iff.mpr (mul_nonneg hC hs))) +lemma expBudget_increment {δ C s t : ℝ} (hδ : 0 ≤ δ) : + expBudget δ C s+C*(δ+expBudget δ C s)*t ≤ expBudget δ C (s+t) := by + have h := mul_le_mul_of_nonneg_left (Real.add_one_le_exp (C*t)) (mul_nonneg hδ (Real.exp_pos (C*s)).le) + have he : Real.exp (C*(s+t))=Real.exp (C*s)*Real.exp (C*t) := by rw [mul_add,Real.exp_add] + unfold expBudget + rw [he] + nlinarith + +def patchRate (n T : ℝ) : ℝ := 1+2*n^2/(1-T) +def patchTolerance (δ n : ℝ) : ℝ := δ/(n+n^2+1) +lemma patchRate_ge_one {n T : ℝ} (hT : T<1) : 1 ≤ patchRate n T := by + unfold patchRate + have : 0 ≤ 2*n^2/(1-T) := div_nonneg (mul_nonneg (by norm_num) (sq_nonneg n)) (by linarith) + linarith +lemma patchTolerance_pos {δ n : ℝ} (hδ : 0<δ) (hn : 0 ≤ n) : 0 (τ v.support).re ≤ T ∧ MomentBound F τ (K := K) (N := N) b v + have h0 : P 0 := by + constructor + · simpa only [PartialUnitary.support_zero,map_zero,Complex.zero_re] using hT0 + · exact momentBound_zero F τ (by dsimp only [b]; rw [expBudget_zero]) + have hclosed : ∀ (a : ℕ → PartialUnitary M) (s : PartialUnitary M), Monotone a → + (∀ n, P (a n)) → GNSTendsto τ (fun n => (a n : M)) atTop (s : M) → P s := by + intro a s _ha hPa ht + constructor + · have hs := (ht.star τ htr).mul τ htr ht 1 (fun n => by simpa only [norm_star] using (a n).norm_le_one) + have htrace := (Complex.continuous_re.tendsto _).comp (trace_tendsto_of_gns τ h1 hs) + exact le_of_tendsto htrace (Filter.Eventually.of_forall (fun n => (hPa n).1)) + · exact momentBound_limit F τ htr h1 ht (expBudget_continuous δ _).continuousAt (fun n => (hPa n).2) + obtain ⟨v,hv⟩ := PartialUnitary.maximal_of_sequentially_closed e τ (HochschildSakai.mul_hasPreadjoint e) + hτ htr hfaith P h0 hclosed + have hs0 : 0 ≤ (τ v.support).re := (τ.map_nonneg v.support_proj.nonneg).1 + have hb : 0 ≤ b ((τ v.support).re) := expBudget_nonneg hδ.le + ((by norm_num : (0 : ℝ) ≤ 1).trans (patchRate_ge_one hT)) hs0 + refine ⟨v,?_,hv.1.2⟩ + by_contra hne + have hsT : (τ v.support).re simp + | cons a l ih => + obtain ⟨k,c⟩ := a + have hc := hl (k,c) (List.mem_cons_self ..) + have htail := fun a ha => hl a (List.mem_cons_of_mem _ ha) + have hA' : ‖A*v.power k*c‖ ≤ 1 := by + simpa only [one_mul] using norm_mul_le_of_le (norm_mul_le_of_le hA (v.norm_power_le_one k)) hc + have hin := ih htail (A*v.power k*c) hA' + have hnew := trace_supported_insertion τ htr w.support_proj A (w.power k) + (c*wordProduct (v.orthogonalSum w horth).power l) hA (w.norm_power_le_one k) + (by simpa only [one_mul] using norm_mul_le_of_le hc (norm_wordProduct_le_one _ (fun k => (v.orthogonalSum w horth).norm_power_le_one k) l htail)) + (w.support_power k) + have he : A*wordProduct (v.orthogonalSum w horth).power ((k,c)::l)-A*wordProduct v.power ((k,c)::l)= + (A*v.power k*c*wordProduct (v.orthogonalSum w horth).power l-A*v.power k*c*wordProduct v.power l)+ + A*w.power k*(c*wordProduct (v.orthogonalSum w horth).power l) := by + rw [wordProduct_cons,wordProduct_cons,PartialUnitary.power_orthogonalSum] + noncomm_ring + rw [← map_sub,he,map_add,map_sub] + apply (norm_add_le _ _).trans + have hh := add_le_add hin hnew + simpa only [List.length_cons,Nat.cast_add,Nat.cast_one,add_mul,one_mul] using hh + +variable {I : Type*} (F : I → M) +include htr in +lemma trace_mixedEval_patch {K : ℕ} (v w : PartialUnitary M) (horth : v.support*w.support=0) + (hF : ∀ i, ‖F i‖ ≤ 1) (a : Option I) (l : List (WordAtom I K)) : + ‖τ (mixedEval F (v.orthogonalSum w horth) a l)-τ (mixedEval F v a l)‖ ≤ + (l.length : ℝ)*(τ w.support).re := by + have hh := trace_wordProduct_patch τ htr v w horth (evaluatedTail F l) + (fun a ha => by obtain ⟨b,hb,rfl⟩ := List.mem_map.mp ha; exact norm_wordCoeff F hF b.2) + (wordCoeff F a) (norm_wordCoeff F hF a) + simpa only [mixedEval,evaluatedTail,List.length_map] using hh + + +def unitaryCompletion (v : PartialUnitary M) : unitary M := + ⟨(v:M)+(1-v.support),by + apply Unitary.mem_iff.mpr + have hp := v.support_proj + have horth : v.support*(1-v.support)=0 := by rw [mul_sub,mul_one,hp.isIdempotentElem.eq,sub_self] + let w := ofCornerUnitary (1-v.support) hp.one_sub 1 + have hw : w.support=1-v.support := ofCornerUnitary_support .. + have hwv : (w:M)=1-v.support := rfl + let he := v.orthogonalSum w (by rwa [hw]) + have hs : he.support=1 := by dsimp only [he]; rw [PartialUnitary.support_orthogonalSum,hw,add_sub_cancel] + constructor + · have hh := he.star_mul_self_eq_support.trans hs + change star ((v:M)+(w:M))*((v:M)+(w:M))=1 at hh + simpa only [hwv] using hh + · have hh := he.mul_star_self_eq_support.trans hs + change ((v:M)+(w:M))*star ((v:M)+(w:M))=1 at hh + simpa only [hwv] using hh⟩ + +end HochschildPatching +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteAveragingLimits.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteAveragingLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..6440718e610b1c5f0b3fd35ebe42f2b2faeeb583 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteAveragingLimits.lean @@ -0,0 +1,90 @@ +import OAI.Analysis.BoundedHochschild.NormalInfiniteAverages +import OAI.Analysis.BoundedHochschild.RightAveragingOrbit + +namespace OAI + +/-! Infinite normalized right averages are actual algebra-valued maps in the +original finite-averaging orbit closure, with the original factorization bound. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {I K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma normal_factorization_value_norm_le (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) (x a : M) + (hx : normalGNSRepresentation e x = L.adjoint.comp ((π a).comp W)) : + ‖x‖ ≤ ‖L‖ * ‖a‖ * ‖W‖ := by + calc + ‖x‖ = ‖normalGNSRepresentation e x‖ := + (NonUnitalStarAlgHom.norm_map _ (normalGNSRepresentation_injective e) x).symm + _ = ‖L.adjoint.comp ((π a).comp W)‖ := congrArg norm hx + _ ≤ _ := weakFactorValue_norm_le π L a (ContinuousLinearMapWOT.ofCLM W) + +lemma completed_averages_predual_tendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (T : M →L[ℂ] M) + (hT : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + (m : I → M) (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, m i * star (m i)) atTop 1) + (S : M →L[ℂ] M) + (hS : ∀ a, normalGNSRepresentation e (S a) = L.adjoint.comp ((π a).comp + (infiniteRepresentedRightAverage π (normalGNSRepresentation e) m hm W))) (a : M) : + PredualTendsto e (fun s : Finset I => finiteRightAverage (completedRow m s) T a) + atTop (S a) := by + have hfac (s : Finset I) := representedRightAverage_factorization π + (normalGNSRepresentation e) T L W hT (completedRow m s) a + apply predual_tendsto_of_normalGNS e + (C := ‖L‖ * ‖a‖ * ‖W‖) + · apply Eventually.of_forall + intro s + exact (normal_factorization_value_norm_le e π L _ _ a (hfac s)).trans + (mul_le_mul_of_nonneg_left + (representedRightAverage_norm_le π (normalGNSRepresentation e) (completedRow m s) + (completedRow_normalized m s (hm s)) W) + (mul_nonneg (norm_nonneg _) (norm_nonneg _))) + · intro ξ η + have ht := completedRow_average_tendsto π (normalGNSRepresentation e) m hm + (normalGNS_row_limit e m hlim) W ξ + have hv := ((L.adjoint.comp (π a)).continuous.tendsto _).comp ht + have hinner := (tendsto_const_nhds (x := η)).inner (𝕜 := ℂ) hv + simp only [Function.comp_def, ContinuousLinearMap.comp_apply] at hinner + simpa only [hfac, hS, ContinuousLinearMap.comp_apply] using hinner + +theorem exists_infinite_right_average (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (T : M →L[ℂ] M) + (hT : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + (m : I → M) (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, m i * star (m i)) atTop 1) : + ∃ S : M →L[ℂ] M, ‖S‖ ≤ ‖L‖ * ‖W‖ ∧ + (∀ a, PredualTendsto e (fun s : Finset I => finiteRightAverage (completedRow m s) T a) + atTop (S a)) ∧ weakOperatorImage e S ∈ weakRightAverageOrbit e T := by + classical + obtain ⟨S, hn, hS⟩ := normal_infinite_average_realize e π L W T hT m hm hlim + have hconv := completed_averages_predual_tendsto e π L W T hT m hm hlim S hS + refine ⟨S, hn, hconv, ?_⟩ + have ht : Tendsto (fun s : Finset I => weakOperatorImage e (finiteRightAverage (completedRow m s) T)) + atTop (𝓝 (weakOperatorImage e S)) := by + apply tendsto_pi_nhds.mpr + intro a + apply tendsto_iff_forall_eval_tendsto_topDualPairing.mpr + exact hconv a + apply mem_closure_of_tendsto ht + apply Eventually.of_forall + intro s + exact ⟨finiteRightAverage (completedRow m s) T, + finiteRightAverage_mem_orbit _ (completedRow_normalized m s (hm s)) T, rfl⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteCentralReduction.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteCentralReduction.lean new file mode 100644 index 0000000000000000000000000000000000000000..a194b1cf63817d84aea6675ad30e895b999712ef --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteCentralReduction.lean @@ -0,0 +1,61 @@ +import OAI.Analysis.BoundedHochschild.FiniteTypeIVanishing + +namespace OAI + +/-! +# The remaining properly infinite input + +The finite case is proved. The maximal finite central cut reduces the +classical vanishing input to algebras with no nonzero finite central summand, +the properly infinite case of Christensen--Effros--Sinclair (1987), as +recorded in Christensen--Pop--Sinclair--Smith (2003), p. 636, equation (1.1). +-/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +open HochschildCorners + +universe u + +def NoFiniteCentralSummand (M : Type u) [CStarAlgebra M] + [PartialOrder M] [StarOrderedRing M] : Prop := + ∀ (p : M) (hp : IsStarProjection p), (∀ a : M, p * a = a * p) → + FiniteAlgebra (Corner p hp) → p = 0 + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma noTypeII1_centralCorner (hM : NoTypeII1Summand M) {p : M} + (hp : IsStarProjection p) (hc : ∀ a : M, p * a = a * p) : + NoTypeII1Summand (Corner p hp) := by + intro z hz hzc hfin hII + have hzM := corner_projection_coe p hp hz + have hzcM := centralCorner_central hp hc z hzc + have hfinM : FiniteAlgebra (Corner (z : M) hzM) := + (finiteCorner_iff (z : M) hzM).mp + (finiteCorner_trans hp z ((finiteCorner_iff z hz).mpr hfin)) + have hIIM := noTypeICentralPart_map_equiv (nestedCornerEquiv hp z hz) hII + exact Subtype.ext (hM (z : M) hzM hzcM hfinM hIIM) + +theorem exists_finite_central_cut_noFiniteSummand (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + ∃ (p : M) (hp : IsStarProjection p), (∀ a : M, p * a = a * p) ∧ + FiniteAlgebra (Corner p hp) ∧ NoFiniteCentralSummand (Corner (1 - p) hp.one_sub) := by + obtain ⟨p, hp, hc, hfin, hmax⟩ := exists_maximal_finite_central_cut e + refine ⟨p, hp, hc, (finiteCorner_iff p hp).mp hfin, ?_⟩ + intro q hq hqc hqfin + have hcc (a : M) : (1 - p) * a = a * (1 - p) := by + simp only [sub_mul, mul_sub, one_mul, mul_one, hc] + have hqM := corner_projection_coe (1 - p) hp.one_sub hq + have hqcM := centralCorner_central hp.one_sub hcc q hqc + have hqfinM := finiteCorner_trans hp.one_sub q ((finiteCorner_iff q hq).mpr hqfin) + exact Subtype.ext (hmax (q : M) hqM hqcM hqfinM (corner_projection_le _ _ hq)) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteInvariantFamilies.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteInvariantFamilies.lean new file mode 100644 index 0000000000000000000000000000000000000000..8e7e1844a2afb52200f7e4d36431aec062894309 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteInvariantFamilies.lean @@ -0,0 +1,59 @@ +import OAI.Analysis.BoundedHochschild.InfiniteAveragingLimits +import OAI.Analysis.BoundedHochschild.MinimalRightAverages + +namespace OAI + +/-! Closed families invariant under finite normalized averages are also +invariant under every normalized infinite row for which an operator +factorization is given. This justifies the infinite rows in the minimal-family +argument without strengthening its invariance hypothesis. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {I K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem infinite_average_mem_invariant_family (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (F : Set (M → WeakDual ℂ X)) (hclosed : IsClosed F) (hinv : RightAverageInvariant e F) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (T : M →L[ℂ] M) (hmem : weakOperatorImage e T ∈ F) + (hT : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + (m : I → M) (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, m i * star (m i)) atTop 1) : + ∃ S : M →L[ℂ] M, ‖S‖ ≤ ‖L‖ * ‖W‖ ∧ weakOperatorImage e S ∈ F ∧ + ∀ a, PredualTendsto e (fun s : Finset I => finiteRightAverage (completedRow m s) T a) + atTop (S a) := by + classical + obtain ⟨S, hn, hconv, _⟩ := exists_infinite_right_average e π L W T hT m hm hlim + refine ⟨S, hn, ?_, hconv⟩ + have ht : Tendsto (fun s : Finset I => weakOperatorImage e (finiteRightAverage (completedRow m s) T)) + atTop (𝓝 (weakOperatorImage e S)) := by + apply tendsto_pi_nhds.mpr + intro a + exact tendsto_iff_forall_eval_tendsto_topDualPairing.mpr (hconv a) + apply hclosed.mem_of_tendsto ht + apply Eventually.of_forall + intro s + let r := completedRow m s + let q := Fintype.equivFin (Option s) + have hr : ∑ j, r j * star (r j) = 1 := completedRow_normalized m s (hm s) + have hq : ∑ j, r (q.symm j) * star (r (q.symm j)) = 1 := + (q.symm.sum_comp (fun j => r j * star (r j))).trans hr + have hin := hinv (Fintype.card (Option s)) (r ∘ q.symm) hq hmem + rw [weakRightAverage_image] at hin + have he := finiteRightAverage_reindex q.symm r T + change finiteRightAverage (r ∘ q.symm) T = finiteRightAverage r T at he + rwa [he] at hin + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteMatrixColumns.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteMatrixColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..66b523f9104896f4938e6dfb8f9fbd556f652c48 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteMatrixColumns.lean @@ -0,0 +1,137 @@ +import OAI.Analysis.BoundedHochschild.ProperlyInfiniteIsometries +import OAI.Analysis.BoundedHochschild.IsometryAbsorption + +namespace OAI + +/-! +# A unital countable system of equivalent orthogonal projections + +Two orthogonal isometries give a countable shift. Its residual projection is +absorbed into the first column, so the finite diagonal sums converge weak-star +to the unit, without a countability assumption on the predual. +-/ + +noncomputable section + +open Filter + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The concrete countable column system needed in the properly infinite +cohomology argument. All columns are isometries and their ranges sum to one. -/ +theorem exists_countable_isometries_of_two (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {v w : M} (hv : star v * v = 1) (hw : star w * w = 1) (hvw : star v * w = 0) : + ∃ c : ℕ → PartialIso M, (∀ i, (c i).initial = 1) ∧ + (∀ i j, i ≠ j → (c i).final * (c j).final = 0) ∧ + PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) atTop 1 := by + have hwi (i : ℕ) : star (v ^ i * w) * (v ^ i * w) = 1 := by + rw [star_mul] + calc + _ = star w * (star (v ^ i) * v ^ i) * w := by simp only [mul_assoc] + _ = 1 := by rw [isometry_pow_initial hv, mul_one, hw] + let c (i : ℕ) : PartialIso M := ⟨v ^ i * w, by rw [mul_assoc, hwi, mul_one]⟩ + have hci (i) : (c i).initial = 1 := hwi i + let p := (c 0).final + have hp : IsStarProjection p := (c 0).final_proj + have hpw : p = w * star w := by simp only [p, c, PartialIso.final, pow_zero, one_mul] + have hpv : p * v = 0 := by + have h : star w * v = 0 := by + simpa only [star_mul, star_star, star_zero] using congrArg star hvw + rw [hpw, mul_assoc, h, mul_zero] + have hcfin (i) : (c i).final = (isometryColumn v hv p hp i).final := by + change (v ^ i * w) * star (v ^ i * w) = (v ^ i * p) * star (v ^ i * p) + rw [star_mul, star_mul, hp.isSelfAdjoint.star_eq] + calc + _ = v ^ i * (w * star w) * star (v ^ i) := by simp only [mul_assoc] + _ = v ^ i * p * star (v ^ i) := by rw [hpw] + _ = _ := by simp only [mul_assoc, ← mul_assoc p p, hp.isIdempotentElem.eq] + have hco (i j) (hij : i ≠ j) : (c i).final * (c j).final = 0 := by + rw [hcfin, hcfin] + exact isometryColumn_final_orthogonal hv hp hpv hij + obtain ⟨q, hq, hcq, hqmin, _⟩ := exists_orthogonal_projection_sum e + (fun i => (c i).final) (fun i => (c i).final_proj) hco + have hpq : p ≤ q := hcq 0 + have hpR : p * (1 - q) = 0 := by + rw [mul_sub, mul_one, (hp.le_iff_mul_eq_left hq).mp hpq, sub_self] + have hP : IsStarProjection (p + (1 - q)) := hp.add hq.one_sub hpR + have hPw : (p + (1 - q)) * w = w := by + have hqw : q * w = w := by + have hh := partialIso_left_support hq (c 0) hpq + simpa only [c, pow_zero, one_mul] using hh + rw [add_mul, hpw, mul_assoc, hw, mul_one, sub_mul, one_mul, hqw, sub_self, add_zero] + obtain ⟨b, hbi, hbf⟩ := isometry_onto_projection e hw hP hPw + let d : ℕ → PartialIso M + | 0 => b + | n + 1 => c (n + 1) + have hdi (i) : (d i).initial = 1 := by + cases i with + | zero => exact hbi + | succ i => exact hci (i + 1) + have hb_orth (i : ℕ) : b.final * (c (i + 1)).final = 0 := by + have hR : (1 - q) * (c (i + 1)).final = 0 := by + rw [sub_mul, one_mul, ((c (i + 1)).final_proj.le_iff_mul_eq_right hq).mp (hcq _), sub_self] + rw [hbf, add_mul, hco 0 (i + 1) (by omega), hR, zero_add] + have hdo (i j) (hij : i ≠ j) : (d i).final * (d j).final = 0 := by + cases i with + | zero => + cases j with + | zero => exact (hij rfl).elim + | succ j => exact hb_orth j + | succ i => + cases j with + | zero => + simpa only [star_mul, b.final_proj.isSelfAdjoint.star_eq, + (c (i + 1)).final_proj.isSelfAdjoint.star_eq, star_zero] using + congrArg star (hb_orth i) + | succ j => exact hco (i + 1) (j + 1) hij + obtain ⟨P, hPproj, hdP, hPmin, ht⟩ := exists_orthogonal_projection_sum e + (fun i => (d i).final) (fun i => (d i).final_proj) hdo + have hpP : p ≤ P := by + calc + p ≤ p + (1 - q) := le_add_of_nonneg_right hq.one_sub.nonneg + _ = b.final := hbf.symm + _ ≤ P := hdP 0 + have hqP : q ≤ P := by + apply hqmin P hPproj + intro i + cases i with + | zero => exact hpP + | succ i => exact hdP (i + 1) + have hRP : 1 - q ≤ P := by + calc + 1 - q ≤ p + (1 - q) := le_add_of_nonneg_left hp.nonneg + _ = b.final := hbf.symm + _ ≤ P := hdP 0 + have h1P : 1 ≤ P := by + apply ((IsStarProjection.one M).le_iff_mul_eq_right hPproj).mpr + calc + P * 1 = P * (q + (1 - q)) := by congr 1; abel + _ = q + (1 - q) := by + rw [mul_add, (hq.le_iff_mul_eq_right hPproj).mp hqP, + (hq.one_sub.le_iff_mul_eq_right hPproj).mp hRP] + _ = 1 := by abel + have hPeq : P = 1 := le_antisymm hPproj.le_one h1P + exact ⟨d, hdi, hdo, hPeq ▸ ht⟩ + +/-- Every algebra with no finite central summand has a unital countable matrix +column system. -/ +theorem exists_countable_isometries (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) : + ∃ c : ℕ → PartialIso M, (∀ i, (c i).initial = 1) ∧ + (∀ i j, i ≠ j → (c i).final * (c j).final = 0) ∧ + PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) atTop 1 := by + obtain ⟨v, w, hv, hw, hvw⟩ := exists_two_orthogonal_isometries e hno + exact exists_countable_isometries_of_two e hv hw hvw + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteOperatorRows.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteOperatorRows.lean new file mode 100644 index 0000000000000000000000000000000000000000..8c42d3508facf93778d44c15c1be35b6f5f74db9 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteOperatorRows.lean @@ -0,0 +1,115 @@ +import OAI.Analysis.BoundedHochschild.SubnormalizedOperatorRows +import Mathlib.Analysis.Normed.Group.InfiniteSum +import Mathlib.Analysis.Normed.Operator.Completeness + +namespace OAI + +/-! Strongly convergent operator rows. The left row need not be normal: the +summability estimate uses the square-sum bound on the right row only. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {I H K : Type*} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma summable_row_vectors (a : I → (K →L[ℂ] K)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (y : I → K) (hy : Summable (fun i => ‖y i‖ ^ 2)) : + Summable (fun i => a i (y i)) := by + classical + apply summable_iff_vanishing_norm.mpr + intro ε hε + obtain ⟨s, hs⟩ := summable_iff_vanishing_norm.mp hy (ε ^ 2) (sq_pos_of_pos hε) + refine ⟨s, fun t ht => ?_⟩ + have h := norm_sum_row_apply_sq_le (fun i : t => a i) + (by rw [Finset.sum_coe_sort t (fun i => a i * star (a i))]; exact ha t) (fun i : t => y i) + rw [Finset.sum_coe_sort t (fun i => a i (y i)), + Finset.sum_coe_sort t (fun i => ‖y i‖ ^ 2)] at h + have hpos : 0 ≤ ∑ i ∈ t, ‖y i‖ ^ 2 := Finset.sum_nonneg (fun i _ => sq_nonneg _) + have hh := hs t ht + rw [Real.norm_eq_abs, abs_of_nonneg hpos] at hh + have hsq := h.trans_lt hh + nlinarith [norm_nonneg (∑ i ∈ t, a i (y i))] + +lemma summable_adjoint_row_sq (b : I → (H →L[ℂ] H)) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) (ξ : H) : + Summable (fun i => ‖(b i).adjoint ξ‖ ^ 2) := by + apply summable_of_sum_le (fun _ => sq_nonneg _) (c := ‖ξ‖ ^ 2) + intro s + rw [← Finset.sum_coe_sort s (fun i => ‖(b i).adjoint ξ‖ ^ 2)] + exact sum_norm_adjoint_sq_le (fun i : s => b i) + (by rw [Finset.sum_coe_sort s (fun i => b i * star (b i))]; exact hb s) ξ + +lemma summable_operator_row_apply (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) + (W : H →L[ℂ] K) (ξ : H) : + Summable (fun i => a i (W ((b i).adjoint ξ))) := by + apply summable_row_vectors a ha + apply Summable.of_nonneg_of_le (fun _ => sq_nonneg _) + (fun i => pow_le_pow_left₀ (norm_nonneg _) (W.le_opNorm _) 2) + simpa only [mul_pow] using (summable_adjoint_row_sq b hb ξ).mul_left (‖W‖ ^ 2) + +lemma tsum_operator_row_apply_norm_le (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) + (W : H →L[ℂ] K) (ξ : H) : + ‖∑' i, a i (W ((b i).adjoint ξ))‖ ≤ ‖W‖ * ‖ξ‖ := by + have ht := (summable_operator_row_apply a b ha hb W ξ).hasSum.norm + apply le_of_tendsto ht + apply Eventually.of_forall + intro s + have h := (operatorRowAverage_norm_le_of_le (fun i : s => a i) (fun i : s => b i) + (by rw [Finset.sum_coe_sort s (fun i => a i * star (a i))]; exact ha s) + (by rw [Finset.sum_coe_sort s (fun i => b i * star (b i))]; exact hb s) W) + have h' := (operatorRowAverage (fun i : s => a i) (fun i : s => b i) W).le_opNorm ξ + rw [operatorRowAverage_apply, + Finset.sum_coe_sort s (fun i => a i (W ((b i).adjoint ξ)))] at h' + exact h'.trans (mul_le_mul_of_nonneg_right h (norm_nonneg ξ)) + +def infiniteOperatorRow (a : I → (K →L[ℂ] K)) (b : I → (H →L[ℂ] H)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) + (W : H →L[ℂ] K) : H →L[ℂ] K := + LinearMap.mkContinuous + { toFun := fun ξ => ∑' i, a i (W ((b i).adjoint ξ)) + map_add' := by + intro ξ η + simp only [map_add] + exact (summable_operator_row_apply a b ha hb W ξ).tsum_add + (summable_operator_row_apply a b ha hb W η) + map_smul' := by + intro c ξ + simp only [map_smul, RingHom.id_apply] + exact tsum_const_smul'' c } + ‖W‖ (tsum_operator_row_apply_norm_le a b ha hb W) + +lemma infiniteOperatorRow_norm_le (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) + (W : H →L[ℂ] K) : ‖infiniteOperatorRow a b ha hb W‖ ≤ ‖W‖ := + ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg W) + (tsum_operator_row_apply_norm_le a b ha hb W) + +lemma infiniteOperatorRow_hasSum (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) + (ha : ∀ s : Finset I, ∑ i ∈ s, a i * star (a i) ≤ 1) + (hb : ∀ s : Finset I, ∑ i ∈ s, b i * star (b i) ≤ 1) + (W : H →L[ℂ] K) (ξ : H) : + HasSum (fun i => a i (W ((b i).adjoint ξ))) (infiniteOperatorRow a b ha hb W ξ) := + (summable_operator_row_apply a b ha hb W ξ).hasSum + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfinitePairChains.lean b/lean/OAI/Analysis/BoundedHochschild/InfinitePairChains.lean new file mode 100644 index 0000000000000000000000000000000000000000..0d9dcf508e3abeb3c8611847584d2b31850f13db --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfinitePairChains.lean @@ -0,0 +1,97 @@ +import OAI.Analysis.BoundedHochschild.ProperlyInfiniteCorners + +namespace OAI + +/-! Increasing chains of pairs implementing properly infinite projections. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Two embeddings of a common projection into orthogonal subprojections. -/ +def IsInfinitePair (a : PartialIso M × PartialIso M) : Prop := + a.1.initial = a.2.initial ∧ a.1.final ≤ a.1.initial ∧ + a.2.final ≤ a.1.initial ∧ a.1.final * a.2.final = 0 + +lemma infinitePair_cross_orthogonal {C : Set (PartialIso M × PartialIso M)} + (hC : ∀ a ∈ C, IsInfinitePair a) (hchain : IsChain (· ≤ ·) C) + {a b : PartialIso M × PartialIso M} (ha : a ∈ C) (hb : b ∈ C) : + a.1.final * b.2.final = 0 := by + rcases hchain.total ha hb with h | h + · calc + _ = (a.1.final * b.1.final) * b.2.final := by + rw [(a.1.final_proj.le_iff_mul_eq_left b.1.final_proj).mp (PartialIso.final_mono h.1)] + _ = 0 := by rw [mul_assoc, (hC b hb).2.2.2, mul_zero] + · calc + _ = a.1.final * (a.2.final * b.2.final) := by + rw [(b.2.final_proj.le_iff_mul_eq_right a.2.final_proj).mp (PartialIso.final_mono h.2)] + _ = 0 := by rw [← mul_assoc, (hC a ha).2.2.2, zero_mul] + +/-- The pair order preserves both common initial supports and orthogonality +at a chain supremum. -/ +theorem infinitePair_chain_upper (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (C : Set (PartialIso M × PartialIso M)) (hC : ∀ a ∈ C, IsInfinitePair a) + (hchain : IsChain (· ≤ ·) C) (hne : C.Nonempty) : + ∃ a : PartialIso M × PartialIso M, IsInfinitePair a ∧ ∀ b ∈ C, b ≤ a := by + let L := Prod.fst '' C + let R := Prod.snd '' C + have hL : IsChain (· ≤ ·) L := by + rintro _ ⟨a, ha, rfl⟩ _ ⟨b, hb, rfl⟩ _ + exact (hchain.total ha hb).imp (fun h => h.1) (fun h => h.1) + have hR : IsChain (· ≤ ·) R := by + rintro _ ⟨a, ha, rfl⟩ _ ⟨b, hb, rfl⟩ _ + exact (hchain.total ha hb).imp (fun h => h.2) (fun h => h.2) + obtain ⟨v, hv, _, hvi, hvf⟩ := exists_partialIso_chain_supremum e L hL (hne.image _) + obtain ⟨w, hw, _, hwi, hwf⟩ := exists_partialIso_chain_supremum e R hR (hne.image _) + have hV (a) (ha : a ∈ C) : a.1 ≤ v := hv a.1 ⟨a, ha, rfl⟩ + have hW (a) (ha : a ∈ C) : a.2 ≤ w := hw a.2 ⟨a, ha, rfl⟩ + have hi : v.initial = w.initial := by + apply le_antisymm + · apply hvi _ w.initial_proj + rintro _ ⟨a, ha, rfl⟩ + rw [(hC a ha).1] + exact (hW a ha).1 + · apply hwi _ v.initial_proj + rintro _ ⟨a, ha, rfl⟩ + rw [← (hC a ha).1] + exact (hV a ha).1 + have hfv : v.final ≤ v.initial := by + apply hvf _ v.initial_proj + rintro _ ⟨a, ha, rfl⟩ + exact (hC a ha).2.1.trans (hV a ha).1 + have hfw : w.final ≤ v.initial := by + apply hwf _ v.initial_proj + rintro _ ⟨a, ha, rfl⟩ + exact (hC a ha).2.2.1.trans (hV a ha).1 + have hcross (a) (ha : a ∈ C) : a.1.final * w.final = 0 := by + have hbound : w.final ≤ 1 - a.1.final := by + apply hwf _ a.1.final_proj.one_sub + rintro _ ⟨b, hb, rfl⟩ + have ho := infinitePair_cross_orthogonal hC hchain ha hb + apply projection_le_complement_of_mul_zero b.2.final_proj a.1.final_proj + simpa only [star_mul, a.1.final_proj.isSelfAdjoint.star_eq, + b.2.final_proj.isSelfAdjoint.star_eq, star_zero] using congrArg star ho + exact HochschildTypeII.projection_orthogonal_of_le_complement a.1.final_proj + w.final_proj hbound + have hfinal : v.final ≤ 1 - w.final := by + apply hvf _ w.final_proj.one_sub + rintro _ ⟨a, ha, rfl⟩ + exact projection_le_complement_of_mul_zero a.1.final_proj w.final_proj (hcross a ha) + have ho : v.final * w.final = 0 := by + have h := (v.final_proj.le_iff_mul_eq_left w.final_proj.one_sub).mp hfinal + rw [mul_sub, mul_one] at h + exact sub_eq_self.mp h + exact ⟨(v, w), ⟨hi, hfv, hfw, ho⟩, fun a ha => ⟨hV a ha, hW a ha⟩⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedAverages.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..eed3ff4526dfb66c34383ed8fb72bad50cbfb0aa --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedAverages.lean @@ -0,0 +1,91 @@ +import OAI.Analysis.BoundedHochschild.InfiniteOperatorRows +import OAI.Analysis.BoundedHochschild.StrongRowDefect +import OAI.Analysis.BoundedHochschild.RepresentedAveragingOrbit + +namespace OAI + +/-! Infinite right averages are strong limits of finite normalized averages, +and hence lie in the same weakly closed orbit. Only the target representation +is required to preserve the normalization limit. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {M I H K : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma representation_row_le (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) (s : Finset I) : + ∑ i ∈ s, π (m i) * star (π (m i)) ≤ 1 := by + simpa only [map_sum, map_mul, map_star, map_one] using OrderHomClass.mono π (hm s) + +def infiniteRepresentedRightAverage (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (W : H →L[ℂ] K) : H →L[ℂ] K := + infiniteOperatorRow (fun i => π (m i)) (fun i => σ (m i)) + (representation_row_le π m hm) (representation_row_le σ m hm) W + +lemma infiniteRepresentedRightAverage_norm_le (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) (W : H →L[ℂ] K) : + ‖infiniteRepresentedRightAverage π σ m hm W‖ ≤ ‖W‖ := + infiniteOperatorRow_norm_le _ _ _ _ W + +lemma infiniteRepresentedRightAverage_hasSum (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (W : H →L[ℂ] K) (ξ : H) : + HasSum (fun i => π (m i) (W ((σ (m i)).adjoint ξ))) + (infiniteRepresentedRightAverage π σ m hm W ξ) := + infiniteOperatorRow_hasSum _ _ _ _ W ξ + +lemma completedRow_average_tendsto (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : ∀ ξ : H, Tendsto + (fun s : Finset I => inner ℂ ξ (σ (∑ i ∈ s, m i * star (m i)) ξ)) + atTop (𝓝 (inner ℂ ξ ξ))) (W : H →L[ℂ] K) (ξ : H) : + Tendsto (fun s : Finset I => representedRightAverage π σ (completedRow m s) W ξ) + atTop (𝓝 (infiniteRepresentedRightAverage π σ m hm W ξ)) := by + have hd := rowDefect_average_strong_zero π σ m hm hlim W ξ + have hs := infiniteRepresentedRightAverage_hasSum π σ m hm W ξ + have he (s : Finset I) : representedRightAverage π σ (completedRow m s) W ξ = + π (rowDefect m s) (W ((σ (rowDefect m s)).adjoint ξ)) + + ∑ i ∈ s, π (m i) (W ((σ (m i)).adjoint ξ)) := by + rw [completedRow_average] + simp only [add_apply, sum_apply, ContinuousLinearMap.comp_apply] + simp_rw [he] + simpa only [zero_add] using hd.add hs + +lemma infiniteRepresentedRightAverage_mem_closed_orbit + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (m : I → M) + (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : ∀ ξ : H, Tendsto + (fun s : Finset I => inner ℂ ξ (σ (∑ i ∈ s, m i * star (m i)) ξ)) + atTop (𝓝 (inner ℂ ξ ξ))) (W : H →WOT[ℂ] K) : + ContinuousLinearMapWOT.ofCLM (infiniteRepresentedRightAverage π σ m hm W.toCLM) ∈ + closedRepresentedAveragingOrbit π σ W := by + classical + have ht : Tendsto (fun s : Finset I => weakRepresentedRightAverage π σ (completedRow m s) W) + atTop (𝓝 (ContinuousLinearMapWOT.ofCLM + (infiniteRepresentedRightAverage π σ m hm W.toCLM))) := by + apply ContinuousLinearMapWOT.tendsto_iff_forall_inner_apply_tendsto.mpr + intro ξ η + exact tendsto_const_nhds.inner (completedRow_average_tendsto π σ m hm hlim W.toCLM ξ) + apply isClosed_closure.mem_of_tendsto ht + apply Eventually.of_forall + intro s + exact subset_closure (weakRepresentedRightAverage_mem_orbit π σ (completedRow m s) + (completedRow_normalized m s (hm s)) W) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedFamilies.lean b/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedFamilies.lean new file mode 100644 index 0000000000000000000000000000000000000000..a83ef8eb896f6709e29079b9929525948840b4c1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/InfiniteRepresentedFamilies.lean @@ -0,0 +1,54 @@ +import OAI.Analysis.BoundedHochschild.CompressedAveragingNorms +import OAI.Analysis.BoundedHochschild.InfiniteRepresentedAverages + +namespace OAI + +/-! Infinite normalized rows preserve the closed represented families used +in the minimal-family argument. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +variable {M I H K : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma infinite_represented_average_mem_family + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (F : Set (H →WOT[ℂ] K)) (hclosed : IsClosed F) + (hinv : RepresentedRightAverageInvariant π σ F) (W : H →WOT[ℂ] K) (hW : W ∈ F) + (m : I → M) (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : ∀ ξ : H, Tendsto + (fun s : Finset I => inner ℂ ξ (σ (∑ i ∈ s, m i * star (m i)) ξ)) + atTop (𝓝 (inner ℂ ξ ξ))) : + ContinuousLinearMapWOT.ofCLM (infiniteRepresentedRightAverage π σ m hm W.toCLM) ∈ F := by + classical + have ht : Tendsto (fun s : Finset I => weakRepresentedRightAverage π σ (completedRow m s) W) + atTop (𝓝 (ContinuousLinearMapWOT.ofCLM + (infiniteRepresentedRightAverage π σ m hm W.toCLM))) := by + apply ContinuousLinearMapWOT.tendsto_iff_forall_inner_apply_tendsto.mpr + intro ξ η + exact tendsto_const_nhds.inner (completedRow_average_tendsto π σ m hm hlim W.toCLM ξ) + apply hclosed.mem_of_tendsto ht + apply Eventually.of_forall + intro s + let q := Fintype.equivFin (Option s) + let r := completedRow m s + have hr : ∑ i, r i * star (r i) = 1 := completedRow_normalized m s (hm s) + have hq : ∑ i, r (q.symm i) * star (r (q.symm i)) = 1 := + (q.symm.sum_comp (fun i => r i * star (r i))).trans hr + have hin := hinv (Fintype.card (Option s)) (r ∘ q.symm) hq hW + have he := congrArg ContinuousLinearMapWOT.ofCLM + (representedRightAverage_reindex π σ q.symm r W.toCLM) + change weakRepresentedRightAverage π σ (r ∘ q.symm) W = + weakRepresentedRightAverage π σ r W at he + rwa [he] at hin + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/IsometricFixedPoint.lean b/lean/OAI/Analysis/BoundedHochschild/IsometricFixedPoint.lean new file mode 100644 index 0000000000000000000000000000000000000000..448df8d35d714b62067c66270c2ed3cffdbf5b54 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/IsometricFixedPoint.lean @@ -0,0 +1,115 @@ +import OAI.Analysis.BoundedHochschild.WeakIsometricFixedPoint +import Mathlib.GroupTheory.FreeGroup.Basic + +namespace OAI + +/-! +# Common fixed points for weakly compact linear isometric actions + +A countable orbit generates a norm-separable closed convex hull. Applying +the separable argument to free groups on finitely many prescribed elements, +then using compactness, removes the separability restriction. +-/ + +noncomputable section + +open Topology TopologicalSpace + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u v + +variable {E : Type u} [NormedAddCommGroup E] [NormedSpace ℂ E] [CompleteSpace E] +variable {G : Type v} [Group G] + +/-- A countable acting group can be restricted to the separable closed +convex hull of one orbit. -/ +theorem weakCompact_countable_isometric_fixedPoint [Countable G] + (T : G → E ≃ₗᵢ[ℂ] E) + (hone : ∀ x, T 1 x = x) (hmul : ∀ g h x, T (g * h) x = T g (T h x)) + (C : Set (WeakSpace ℂ E)) (hC : IsCompact C) (hne : C.Nonempty) + (hconv : Convex ℝ C) (hinv : ∀ g, Set.MapsTo (weakIsometry (T g)) C C) : + ∃ x ∈ C, ∀ g, weakIsometry (T g) x = x := by + classical + obtain ⟨x, hx⟩ := hne + let S : Set E := Set.range (fun g : G => T g ((toWeakSpace ℂ E).symm x)) + let D : Set E := closure (convexHull ℝ S) + let W : Set (WeakSpace ℂ E) := (toWeakSpace ℂ E) '' D + have hDc : IsClosed D := isClosed_closure + have hDv : Convex ℝ D := (convex_convexHull ℝ S).closure + have hWc : IsClosed W := by + rw [show W = closure ((toWeakSpace ℂ E) '' convexHull ℝ S) from + (convex_convexHull ℝ S).toWeakSpace_closure ℂ] + exact isClosed_closure + have hWC : W ⊆ C := by + rintro _ ⟨y, hy, rfl⟩ + have hsub : D ⊆ (toWeakSpace ℂ E) ⁻¹' C := by + apply closure_minimal _ (hC.isClosed.preimage (toWeakSpaceCLM ℂ E).continuous) + apply convexHull_min _ (hconv.linear_preimage ((toWeakSpace ℂ E).restrictScalars ℝ).toLinearMap) + rintro _ ⟨g, rfl⟩ + exact hinv g hx + exact hsub hy + have hWn : W.Nonempty := by + refine ⟨x, (toWeakSpace ℂ E).symm x, ?_, (toWeakSpace ℂ E).apply_symm_apply x⟩ + apply subset_closure + apply subset_convexHull ℝ S + exact ⟨1, hone _⟩ + have hWs : IsSeparable ((toWeakSpace ℂ E).symm '' W) := by + have hS : S.Countable := Set.countable_range _ + have hDsep : IsSeparable D := by + apply (hS.isSeparable.span (R := ℝ)).closure.mono + exact closure_mono (convexHull_min (Submodule.subset_span) (Submodule.span ℝ S).convex) + have heq : (toWeakSpace ℂ E).symm '' W = D := by + simp only [W, Set.image_image, LinearEquiv.symm_apply_apply, Set.image_id'] + rw [heq] + exact hDsep + have hWi : ∀ g, Set.MapsTo (weakIsometry (T g)) W W := by + intro g a ha + obtain ⟨y, hy, rfl⟩ := ha + refine ⟨T g y, ?_, rfl⟩ + have hsub : D ⊆ (T g) ⁻¹' D := by + apply closure_minimal _ (hDc.preimage (T g).continuous) + apply convexHull_min _ (hDv.linear_preimage ((T g).toLinearMap.restrictScalars ℝ)) + rintro _ ⟨h, rfl⟩ + apply subset_closure + apply subset_convexHull ℝ S + exact ⟨g * h, hmul g h _⟩ + exact hsub hy + obtain ⟨y, hy, hfix⟩ := weakCompact_separable_isometric_fixedPoint T hone hmul W + (hC.of_isClosed_subset hWc hWC) hWn + (hDv.linear_image ((toWeakSpace ℂ E).restrictScalars ℝ).toLinearMap) hWs hWi + exact ⟨y, hWC hy, hfix⟩ + +/-- The linear-isometric case of the Ryll-Nardzewski fixed-point theorem, +without separability assumptions. -/ +theorem weakCompact_isometric_fixedPoint + (T : G → E ≃ₗᵢ[ℂ] E) + (hone : ∀ x, T 1 x = x) (hmul : ∀ g h x, T (g * h) x = T g (T h x)) + (C : Set (WeakSpace ℂ E)) (hC : IsCompact C) (hne : C.Nonempty) + (hconv : Convex ℝ C) (hinv : ∀ g, Set.MapsTo (weakIsometry (T g)) C C) : + ∃ x ∈ C, ∀ g, weakIsometry (T g) x = x := by + classical + have hfinite (s : Finset G) : ∃ x ∈ C, ∀ g ∈ s, weakIsometry (T g) x = x := by + let ρ : FreeGroup s →* G := FreeGroup.lift (fun g : s => g.val) + have : Countable (FreeGroup s) := inferInstanceAs (Countable (Quot _)) + obtain ⟨x, hx, hfix⟩ := weakCompact_countable_isometric_fixedPoint (fun g => T (ρ g)) + (fun x => by simpa only [map_one] using hone x) + (fun g h x => by simpa only [map_mul] using hmul (ρ g) (ρ h) x) + C hC hne hconv (fun g => hinv (ρ g)) + refine ⟨x, hx, fun g hg => ?_⟩ + simpa only [ρ, FreeGroup.lift_apply_of] using hfix (FreeGroup.of ⟨g, hg⟩) + let F (g : G) : Set (WeakSpace ℂ E) := {x | weakIsometry (T g) x = x} + have hc (g) : IsClosed (F g) := isClosed_eq + (WeakSpace.map (T g).toContinuousLinearEquiv.toContinuousLinearMap).continuous continuous_id + obtain ⟨x, hx, hfix⟩ := hC.inter_iInter_nonempty F hc (fun s => by + obtain ⟨x, hx, hfix⟩ := hfinite s + exact ⟨x, hx, Set.mem_iInter₂.mpr hfix⟩) + exact ⟨x, hx, fun g => Set.mem_iInter.mp hfix g⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/IsometryAbsorption.lean b/lean/OAI/Analysis/BoundedHochschild/IsometryAbsorption.lean new file mode 100644 index 0000000000000000000000000000000000000000..fa23c7406f126ae770a47962e4bd1a473ca74234 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/IsometryAbsorption.lean @@ -0,0 +1,98 @@ +import OAI.Analysis.BoundedHochschild.ProperlyInfiniteColumns + +namespace OAI + +/-! +# Absorbing a projection around an isometry + +If a projection contains the range of an isometry, it is equivalent to the +unit. The countable shift proof is the particular projection comparison needed +for a unital infinite matrix system. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The projection form of the countable shift argument: an isometry whose +range lies under `p` extends to an equivalence between one and `p`. -/ +theorem isometry_onto_projection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {v p : M} (hv : star v * v = 1) (hp : IsStarProjection p) (hpv : p * v = v) : + ∃ w : PartialIso M, w.initial = 1 ∧ w.final = p := by + let r := 1 - p + have hr : IsStarProjection r := hp.one_sub + have hrv : r * v = 0 := by rw [sub_mul, one_mul, hpv, sub_self] + let c := isometryColumn v hv r hr + have hci (i) : (c i).initial = r := isometryColumn_initial .. + have hco (i j) (hij : i ≠ j) : (c i).final * (c j).final = 0 := + isometryColumn_final_orthogonal hv hr hrv hij + have hc0 : (c 0).final = r := by + change (v ^ 0 * r) * star (v ^ 0 * r) = r + rw [pow_zero, one_mul, hr.isSelfAdjoint.star_eq, hr.isIdempotentElem.eq] + obtain ⟨q, hq, hcq, hqmin, _⟩ := exists_orthogonal_projection_sum e + (fun i => (c i).final) (fun i => (c i).final_proj) hco + let a (i : ℕ) := columnTransition (c (i + 1)) (c i) ((hci _).trans (hci _).symm) + have hai (i) : (a i).initial = (c i).final := columnTransition_initial .. + have haf (i) : (a i).final = (c (i + 1)).final := columnTransition_final .. + obtain ⟨s, hsi, hsf, hsi_min, hsf_min⟩ := exists_countable_partialIso_sum e a + (fun i j hij => by rw [hai, hai]; exact hco i j hij) + (fun i j hij => by rw [haf, haf]; exact hco _ _ (by omega)) + have hsq : s.initial = q := le_antisymm + (hsi_min q hq (fun i => by rw [hai]; exact hcq i)) + (hqmin _ s.initial_proj (fun i => by rw [← hai]; exact hsi i)) + have hstq : s.final ≤ q := hsf_min q hq (fun i => by rw [haf]; exact hcq _) + have hrt : r * s.final = 0 := by + have hb : s.final ≤ 1 - r := by + apply hsf_min _ hr.one_sub + intro i + apply projection_le_complement_of_mul_zero (a i).final_proj hr + rw [haf, ← hc0] + exact hco _ _ (by omega) + exact HochschildTypeII.projection_orthogonal_of_le_complement hr s.final_proj hb + have hrq : r ≤ q := by rw [← hc0]; exact hcq 0 + have hrs : IsStarProjection (r + s.final) := hr.add s.final_proj hrt + have hqrs : q = r + s.final := by + apply le_antisymm + · apply hqmin _ hrs + intro i + cases i with + | zero => rw [hc0]; exact le_add_of_nonneg_right s.final_proj.nonneg + | succ i => + calc + (c (i + 1)).final = (a i).final := (haf i).symm + _ ≤ s.final := hsf i + _ ≤ r + s.final := le_add_of_nonneg_left hr.nonneg + · apply (hrs.le_iff_mul_eq_right hq).mpr + rw [mul_add, (hr.le_iff_mul_eq_right hq).mp hrq, + (s.final_proj.le_iff_mul_eq_right hq).mp hstq] + let t : PartialIso M := ⟨1 - q, by + rw [hq.one_sub.isSelfAdjoint.star_eq, hq.one_sub.isIdempotentElem.eq, + hq.one_sub.isIdempotentElem.eq]⟩ + have hti : t.initial = 1 - q := by + change star (1 - q) * (1 - q) = _ + rw [hq.one_sub.isSelfAdjoint.star_eq, hq.one_sub.isIdempotentElem.eq] + have htf : t.final = 1 - q := by + change (1 - q) * star (1 - q) = _ + rw [hq.one_sub.isSelfAdjoint.star_eq, hq.one_sub.isIdempotentElem.eq] + have hi : s.initial * t.initial = 0 := by rw [hsq, hti, hq.mul_one_sub_self] + have hf : s.final * t.final = 0 := by + rw [htf, mul_sub, mul_one, (s.final_proj.le_iff_mul_eq_left hq).mp hstq, sub_self] + refine ⟨s.orthogonalSum t hi hf, ?_, ?_⟩ + · rw [PartialIso.orthogonalSum_initial, hsq, hti] + abel + · rw [PartialIso.orthogonalSum_final, htf, hqrs] + change s.final + (1 - ((1 - p) + s.final)) = p + abel + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/IsometryDefectColumns.lean b/lean/OAI/Analysis/BoundedHochschild/IsometryDefectColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..8a5d1bd1de7c1801a06fcddd66853f9d66d0fd22 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/IsometryDefectColumns.lean @@ -0,0 +1,105 @@ +import OAI.Analysis.BoundedHochschild.PartialIsoProducts + +namespace OAI + +/-! +# Orthogonal columns from an isometry defect + +A nonunitary isometry supplies countably many equivalent, orthogonal defect +projections. This is an algebraic ingredient of the properly infinite case. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] + +lemma isometry_pow_initial {v : M} (hv : star v * v = 1) (n : ℕ) : + star (v ^ n) * v ^ n = 1 := by + induction n with + | zero => simp + | succ n ih => + rw [pow_succ, star_mul] + calc + _ = star v * (star (v ^ n) * v ^ n) * v := by simp only [mul_assoc] + _ = 1 := by rw [ih, mul_one, hv] + +lemma isometry_pow_cancel {v : M} (hv : star v * v = 1) (n k : ℕ) : + star (v ^ n) * v ^ (n + k) = v ^ k := by + rw [pow_add, ← mul_assoc, isometry_pow_initial hv, one_mul] + +def isometryDefect (v : M) : M := 1 - v * star v + +lemma isometryDefect_projection {v : M} (hv : star v * v = 1) : + IsStarProjection (isometryDefect v) := by + apply IsStarProjection.one_sub + refine ⟨?_, IsSelfAdjoint.mul_star_self v⟩ + calc + (v * star v) * (v * star v) = v * (star v * v) * star v := by simp only [mul_assoc] + _ = v * star v := by rw [hv, mul_one] + +lemma isometryDefect_mul {v : M} (hv : star v * v = 1) : + isometryDefect v * v = 0 := by + rw [isometryDefect, sub_mul, one_mul, mul_assoc, hv, mul_one, sub_self] + +lemma isometryDefect_mul_pow_succ {v : M} (hv : star v * v = 1) (n : ℕ) : + isometryDefect v * v ^ (n + 1) = 0 := by + rw [pow_succ', ← mul_assoc, isometryDefect_mul hv, zero_mul] + +lemma isometry_column_initial {v p : M} (hv : star v * v = 1) + (hp : IsStarProjection p) (n : ℕ) : + star (v ^ n * p) * (v ^ n * p) = p := by + rw [star_mul, hp.isSelfAdjoint.star_eq] + calc + _ = p * (star (v ^ n) * v ^ n) * p := by simp only [mul_assoc] + _ = p := by rw [isometry_pow_initial hv, mul_one, hp.isIdempotentElem.eq] + +def isometryColumn (v : M) (hv : star v * v = 1) (p : M) + (hp : IsStarProjection p) (n : ℕ) : PartialIso M := + ⟨v ^ n * p, by + rw [mul_assoc, isometry_column_initial hv hp, mul_assoc, hp.isIdempotentElem.eq]⟩ + +@[simp] lemma isometryColumn_initial (v : M) (hv : star v * v = 1) (p : M) + (hp : IsStarProjection p) (n : ℕ) : + (isometryColumn v hv p hp n).initial = p := isometry_column_initial hv hp n + +@[simp] lemma isometryColumn_coe (v : M) (hv : star v * v = 1) (p : M) + (hp : IsStarProjection p) (n : ℕ) : + (isometryColumn v hv p hp n : M) = v ^ n * p := rfl + +lemma isometryColumn_star_mul_of_lt {v p : M} (hv : star v * v = 1) + (hp : IsStarProjection p) (hpv : p * v = 0) {i j : ℕ} (hij : i < j) : + star (isometryColumn v hv p hp i : M) * (isometryColumn v hv p hp j : M) = 0 := by + obtain ⟨k, rfl⟩ := Nat.exists_eq_add_of_lt hij + have hpk : p * v ^ (k + 1) = 0 := by + rw [pow_succ', ← mul_assoc, hpv, zero_mul] + simp only [isometryColumn_coe, star_mul, hp.isSelfAdjoint.star_eq] + calc + _ = p * (star (v ^ i) * v ^ (i + (k + 1))) * p := by + simp only [mul_assoc, Nat.add_assoc] + _ = 0 := by rw [isometry_pow_cancel hv, hpk, zero_mul] + +lemma isometryColumn_star_mul_of_ne {v p : M} (hv : star v * v = 1) + (hp : IsStarProjection p) (hpv : p * v = 0) {i j : ℕ} (hij : i ≠ j) : + star (isometryColumn v hv p hp i : M) * (isometryColumn v hv p hp j : M) = 0 := by + rcases lt_or_gt_of_ne hij with h | h + · exact isometryColumn_star_mul_of_lt hv hp hpv h + · simpa only [star_mul, star_star, star_zero] using + congrArg star (isometryColumn_star_mul_of_lt hv hp hpv h) + +lemma isometryColumn_final_orthogonal {v p : M} (hv : star v * v = 1) + (hp : IsStarProjection p) (hpv : p * v = 0) {i j : ℕ} (hij : i ≠ j) : + (isometryColumn v hv p hp i).final * (isometryColumn v hv p hp j).final = 0 := by + change (((isometryColumn v hv p hp i : M) * star (isometryColumn v hv p hp i : M)) * + ((isometryColumn v hv p hp j : M) * star (isometryColumn v hv p hp j : M))) = 0 + rw [mul_assoc, ← mul_assoc (star (isometryColumn v hv p hp i : M)), + isometryColumn_star_mul_of_ne hv hp hpv hij, zero_mul, mul_zero] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/JointAveragingRelations.lean b/lean/OAI/Analysis/BoundedHochschild/JointAveragingRelations.lean new file mode 100644 index 0000000000000000000000000000000000000000..c890968e3d68deba1a03b1bb23d353ef85b9d6b5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/JointAveragingRelations.lean @@ -0,0 +1,79 @@ +import OAI.Analysis.BoundedHochschild.CompactFamilyAverages + +namespace OAI + +/-! Relations preserved by every finite average pass to the joint orbit. +These are the linearity and covariance identities of the eventual projection. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {I : Type*} + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma joint_orbit_closed_relation (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) (R : Set (I → M → WeakDual ℂ X)) (hR : IsClosed R) + (hfin : ∀ (n : ℕ) (m : Fin n → M), (∑ j, m j * star (m j) = 1) → + (fun i => weakOperatorImage e (finiteRightAverage m (T i))) ∈ R) : + weakFamilyAverageOrbit e T ⊆ R := by + apply closure_minimal _ hR + rintro F ⟨n, m, hm, rfl⟩ + exact hfin n m hm + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma weakOperatorImage_complex_smul (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (z : ℂ) (T : M →L[ℂ] M) : + weakOperatorImage e (z • T) = star z • weakOperatorImage e T := by + funext a + change StrongDual.toWeakDual (e.symm (z • T a)) = _ + rw [e.symm.map_smulₛₗ] + rfl + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma joint_orbit_add_relation (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) {i j k : I} (hT : T k = T i + T j) + {F : I → M → WeakDual ℂ X} (hF : F ∈ weakFamilyAverageOrbit e T) : + F k = F i + F j := by + apply joint_orbit_closed_relation e T {F | F k = F i + F j} _ _ hF + · exact isClosed_eq (continuous_apply k) ((continuous_apply i).add (continuous_apply j)) + · intro n m _ + change weakOperatorImage e (finiteRightAverage m (T k)) = + weakOperatorImage e (finiteRightAverage m (T i)) + weakOperatorImage e (finiteRightAverage m (T j)) + rw [hT, finiteRightAverage_add, weakOperatorImage_add] + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma joint_orbit_smul_relation (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) {i j : I} (z : ℂ) (hT : T j = z • T i) + {F : I → M → WeakDual ℂ X} (hF : F ∈ weakFamilyAverageOrbit e T) : + F j = star z • F i := by + apply joint_orbit_closed_relation e T {F | F j = star z • F i} _ _ hF + · exact isClosed_eq (continuous_apply j) ((continuous_apply i).const_smul (star z)) + · intro n m _ + change weakOperatorImage e (finiteRightAverage m (T j)) = + star z • weakOperatorImage e (finiteRightAverage m (T i)) + rw [hT, finiteRightAverage_smul, weakOperatorImage_complex_smul] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma joint_orbit_sandwich_relation (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : I → M →L[ℂ] M) {i j : I} (a b : M) (hT : T j = leftSandwichMap a b (T i)) + {F : I → M → WeakDual ℂ X} (hF : F ∈ weakFamilyAverageOrbit e T) : + F j = weakLeftSandwich e a b (F i) := by + apply joint_orbit_closed_relation e T {F | F j = weakLeftSandwich e a b (F i)} _ _ hF + · exact isClosed_eq (continuous_apply j) + ((weakLeftSandwich_continuous e a b).comp (continuous_apply i)) + · intro n m _ + change weakOperatorImage e (finiteRightAverage m (T j)) = + weakLeftSandwich e a b (weakOperatorImage e (finiteRightAverage m (T i))) + rw [hT, ← leftSandwichMap_rightAverage, weakLeftSandwich_image] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/LeftSandwichAverages.lean b/lean/OAI/Analysis/BoundedHochschild/LeftSandwichAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..7c3f31922049ed8f70df2e179148cfbb791be771 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/LeftSandwichAverages.lean @@ -0,0 +1,62 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedArithmetic +import OAI.Analysis.BoundedHochschild.RightAveragingOrbit + +namespace OAI + +/-! Input and output left multiplication commute with right averaging, +including on the weak-star orbit closure. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma leftSandwichMap_rightAverage {I : Type*} [Fintype I] + (a b : M) (m : I → M) (T : M →L[ℂ] M) : + leftSandwichMap a b (finiteRightAverage m T) = + finiteRightAverage m (leftSandwichMap a b T) := by + ext x + simp only [leftSandwichMap_apply, finiteRightAverage_apply, Finset.mul_sum, mul_assoc] + +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def weakLeftSandwich (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a b : M) + (F : M → WeakDual ℂ X) : M → WeakDual ℂ X := + fun x => weakDualOperator e (ContinuousLinearMap.mul ℂ M a) (F (b * x)) + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma weakLeftSandwich_image (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (a b : M) (T : M →L[ℂ] M) : + weakLeftSandwich e a b (weakOperatorImage e T) = + weakOperatorImage e (leftSandwichMap a b T) := by + funext x + exact weakDualOperator_image e _ _ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma weakLeftSandwich_continuous (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a b : M) : + Continuous (weakLeftSandwich e a b) := by + apply continuous_pi + intro x + exact (weakDualOperator_continuous e _ + ((HochschildSakai.abstract_multiplication_normal e).1 a)).comp (continuous_apply (b*x)) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma weakLeftSandwich_mapsTo_orbit (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (a b : M) (T : M →L[ℂ] M) : + Set.MapsTo (weakLeftSandwich e a b) (weakRightAverageOrbit e T) + (weakRightAverageOrbit e (leftSandwichMap a b T)) := by + apply Set.MapsTo.closure _ (weakLeftSandwich_continuous e a b) + rintro F ⟨S, ⟨n, m, hm, rfl⟩, rfl⟩ + rw [weakLeftSandwich_image, leftSandwichMap_rightAverage] + exact ⟨_, finiteRightAverage_mem_orbit m hm _, rfl⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/LiftedOrbitRealization.lean b/lean/OAI/Analysis/BoundedHochschild/LiftedOrbitRealization.lean new file mode 100644 index 0000000000000000000000000000000000000000..132c3dae85c583ff9f05f09e6b81510f5f86fd90 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/LiftedOrbitRealization.lean @@ -0,0 +1,55 @@ +import OAI.Analysis.BoundedHochschild.AveragingOrbitFactorization + +namespace OAI + +/-! The lifted operator orbit maps back into the original weak-star averaging +orbit, including at its boundary. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem lifted_orbit_realization (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (hfac : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + {V : NormalGNS e →WOT[ℂ] K} + (hV : V ∈ closedRepresentedAveragingOrbit π (normalGNSRepresentation e) + (ContinuousLinearMapWOT.ofCLM W)) : + ∃ S : M →L[ℂ] M, ‖S‖ ≤ C ∧ weakOperatorImage e S ∈ weakRightAverageOrbit e T ∧ + ∀ a, normalGNSRepresentation e (S a) = L.adjoint.comp ((π a).comp V.toCLM) := by + let B := weakNormalOperatorFamily e '' weakRightAverageOrbit e T + have hBc : IsClosed B := ((weakRightAverageOrbit_isCompact e hno T hT).image + (weakNormalOperatorFamily_continuous e)).isClosed + have hpre : IsClosed (weakFactorFamily π L ⁻¹' B) := + hBc.preimage (weakFactorFamily_continuous π L) + have hsub : representedAveragingOrbit π (normalGNSRepresentation e) + (ContinuousLinearMapWOT.ofCLM W) ⊆ weakFactorFamily π L ⁻¹' B := by + rintro V ⟨n, m, hm, rfl⟩ + refine ⟨weakOperatorImage e (finiteRightAverage m T), + subset_closure ⟨finiteRightAverage m T, finiteRightAverage_mem_orbit m hm T, rfl⟩, ?_⟩ + funext a + rw [weakNormalOperatorFamily_image] + exact congrArg ContinuousLinearMapWOT.ofCLM + (representedRightAverage_factorization π (normalGNSRepresentation e) T L W hfac m a) + obtain ⟨F, hF, he⟩ := closure_minimal hsub hpre hV + obtain ⟨S, hSC, hSF⟩ := weakOperatorBall_realize e hT.1 + (weakRightAverageOrbit_subset_ball e hno T hT hF) + refine ⟨S, hSC, hSF ▸ hF, fun a => ?_⟩ + have hh := congrFun he a + rw [← hSF, weakNormalOperatorFamily_image] at hh + exact congrArg ContinuousLinearMapWOT.toCLM hh + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Liouville.lean b/lean/OAI/Analysis/BoundedHochschild/Liouville.lean new file mode 100644 index 0000000000000000000000000000000000000000..4a20290ec4f4bc55e2cd67cac694f3ecf1c161fd --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Liouville.lean @@ -0,0 +1,429 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.AsymptoticRigidity +import OAI.Analysis.BoundedHochschild.WalkSelection + +namespace OAI + +/-! Support rigidity, constant martingale limits and harmonic multiplier identities. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildLiouville +open HochschildRigidity HochschildWalk HochschildFirstLetter TracialUltrapower +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + + +def hilbertMap : A →L[ℂ] τ.GNS := + UniformSpace.Completion.toComplL.comp (TracialUltrapower.traceHilbertMap τ h1) + +@[simp] lemma hilbertMap_norm (a : A) : ‖hilbertMap τ h1 a‖ = ‖τ.toPreGNS a‖ := + UniformSpace.Completion.norm_coe _ + +include htr in +lemma trace_norm_unitary_right (a : A) (u : unitary A) : + ‖τ.toPreGNS (a*(u:A))‖ = ‖τ.toPreGNS a‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + apply Complex.ofReal_injective + push_cast + simp only [τ.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS, star_mul] + calc + τ ((star (u:A)*star a)*(a*(u:A))) = τ (star (u:A)*((star a*a)*(u:A))) := by + simp only [mul_assoc] + _ = τ (((star a*a)*(u:A))*star (u:A)) := htr _ _ + _ = τ (star a*a) := by rw [mul_assoc, Unitary.mul_star_self_of_mem u.property, mul_one] + +variable {G : Type*} [Group G] +variable (ρ : G →* unitary A) (R : A →L[ℂ] A) + + +def algebraD (g : G) : A := R (ρ g : A) * (ρ g⁻¹ : A) +def hilbertD (g : G) : τ.GNS := hilbertMap τ h1 (algebraD ρ R g) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma algebraD_mul (g : G) : algebraD ρ R g * (ρ g : A) = R (ρ g : A) := by + simp [algebraD, mul_assoc, ← Submonoid.coe_mul] + +omit [PartialOrder A] [StarOrderedRing A] in +lemma algebraD_norm (g : G) : ‖algebraD ρ R g‖ ≤ ‖R‖ * ‖(1:A)‖ := by + rw [algebraD, CStarRing.norm_mul_coe_unitary] + have hu := CStarRing.norm_coe_unitary_mul (ρ g) (1:A) + simp only [mul_one] at hu + exact (R.le_opNorm _).trans_eq (by rw [hu]) + +lemma hilbertD_norm (g : G) : ‖hilbertD τ h1 ρ R g‖ ≤ ‖R‖ * ‖(1:A)‖ := + (hilbertMap_norm τ h1 _).le.trans ((preGNS_norm_le τ h1 _).trans (algebraD_norm ρ R g)) + +include htr in +lemma multiplied_error (g : G) (a : A) : + ‖τ.toPreGNS (R (ρ g : A)-a*(ρ g : A))‖ = + ‖hilbertD τ h1 ρ R g - hilbertMap τ h1 a‖ := by + rw [hilbertD, ← map_sub, hilbertMap_norm] + rw [← trace_norm_unitary_right τ htr (algebraD ρ R g-a) (ρ g)] + rw [sub_mul, algebraD_mul] + + +def endpointSequence (g : ℕ → G) : ℕ →ᵇ A := + BoundedContinuousFunction.mkOfBound ⟨fun n => algebraD ρ R (g n), continuous_of_discreteTopology⟩ + (2*(‖R‖*‖(1:A)‖)) (fun i j => by + rw [dist_eq_norm] + change ‖algebraD ρ R (g i)-algebraD ρ R (g j)‖ ≤ _ + exact (norm_sub_le _ _).trans (by linarith [algebraD_norm ρ R (g i), algebraD_norm ρ R (g j)])) + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma endpointSequence_apply (g : ℕ → G) (n : ℕ) : + endpointSequence ρ R g n = algebraD ρ R (g n) := rfl + +omit [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] in +lemma evalList_eq_lift {I : Type*} [DecidableEq I] (u : I → G) (g : FreeGroup I) : + evalList u g.toWord = FreeGroup.lift u g := by + conv_rhs => rw [← FreeGroup.mk_toWord (x := g), FreeGroup.lift_mk] + apply congrArg List.prod + apply List.map_congr_left + intro p _ + cases p.2 <;> rfl + +omit [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] in +lemma lift_comp_hom {J K : Type*} [Group K] (f : G →* K) (u : J → G) (g : FreeGroup J) : + (FreeGroup.lift (fun i => f (u i))) g = f (FreeGroup.lift u g) := by + have he : FreeGroup.lift (fun i => f (u i)) = f.comp (FreeGroup.lift u) := by + ext i + simp + exact DFunLike.congr_fun he g + +variable [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (μ : Measure G) [IsProbabilityMeasure μ] + +include htr + + + +theorem support_rigidity (hR : BallSequential τ.toPreGNS R) + (hsym : μ.map (fun g => g⁻¹) = μ) + (time : ℕ → ℕ) (htime : Tendsto time atTop atTop) + (hmom : FreeMomentsInProbability μ (fun g => ‖τ (ρ g : A)‖) time) + (z : Lp τ.GNS 2 (pathMeasure μ)) + (hz : Tendsto (fun k => ∫ ω, ‖z ω-hilbertD τ h1 ρ R (walk k ω)‖^2 ∂pathMeasure μ) atTop (𝓝 0)) + (hc : ∀ k n, k ≤ n → + ∫ ω, ‖hilbertD τ h1 ρ R (walk n ω)-hilbertD τ h1 ρ R (walk k ω)‖^2 ∂pathMeasure μ ≤ + ∫ ω, ‖z ω-hilbertD τ h1 ρ R (walk k ω)‖^2 ∂pathMeasure μ) + (a b : τ.GNS) (ha : ∀ r > 0, 0 < (pathMeasure μ).real {ω | ‖z ω-a‖ < r}) + (hb : ∀ r > 0, 0 < (pathMeasure μ).real {ω | ‖z ω-b‖ < r}) : a = b := by + obtain ⟨u,hu,hfree,hblock⟩ := infinite_walk_selection μ hsym (hilbertD τ h1 ρ R) + (‖R‖*‖(1:A)‖) (hilbertD_norm τ h1 ρ R) z hz hc a b ha hb + (fun g => ‖τ (ρ g : A)‖) (fun _ => norm_nonneg _) time htime hmom + let U (n : ℕ) : FreeGroup ℕ →* unitary A := FreeGroup.lift (fun i => ρ (u n i)) + let a' := endpointSequence ρ R (fun n => u n 0) + let b' := endpointSequence ρ R (fun n => (u n 0)⁻¹) + have ha' : Tendsto (fun n => hilbertMap τ h1 (a' n)) atTop (nhds a) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + exact squeeze_zero (fun _ => norm_nonneg _) (fun n => (hu n 0).1.le) + tendsto_one_div_add_atTop_nhds_zero_nat + have hb' : Tendsto (fun n => hilbertMap τ h1 (b' n)) atTop (nhds b) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + exact squeeze_zero (fun _ => norm_nonneg _) (fun n => (hu n 0).2.le) + tendsto_one_div_add_atTop_nhds_zero_nat + have hw (g : FreeGroup ℕ) (i : ℕ) (t : Bool) (l : List (ℕ × Bool)) + (hg : g.toWord = (i,t)::l) (hn : (g.toWord.map Prod.fst).Nodup) : + Tendsto (fun n => ‖τ.toPreGNS (R (U n g : A) - (if t then a' n else b' n)*(U n g : A))‖) + atTop (nhds 0) := by + have he := hblock ((i,t),l) (by simpa only [hg] using hn) + have hnear : Tendsto (fun n => + ‖hilbertD τ h1 ρ R (signed t (u n i)) - + hilbertMap τ h1 (if t then a' n else b' n)‖) atTop (nhds 0) := by + cases t with + | false => + have hi : Tendsto (fun n => hilbertD τ h1 ρ R ((u n i)⁻¹)) atTop (nhds b) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + exact squeeze_zero (fun _ => norm_nonneg _) (fun n => (hu n i).2.le) + tendsto_one_div_add_atTop_nhds_zero_nat + simpa only [signed, Bool.false_eq_true, ↓reduceIte, sub_self, norm_zero] using (hi.sub hb').norm + | true => + have hi : Tendsto (fun n => hilbertD τ h1 ρ R (u n i)) atTop (nhds a) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + exact squeeze_zero (fun _ => norm_nonneg _) (fun n => (hu n i).1.le) + tendsto_one_div_add_atTop_nhds_zero_nat + simpa only [signed, ↓reduceIte, sub_self, norm_zero] using (hi.sub ha').norm + have hzero := he.add hnear + simp only [zero_add] at hzero + apply squeeze_zero (fun _ => norm_nonneg _) (fun n => ?_) hzero + change ‖τ.toPreGNS (R (FreeGroup.lift (fun i => ρ (u n i)) g : A) - _ * _)‖ ≤ _ + rw [lift_comp_hom, multiplied_error τ h1 htr] + have hword : evalList (u n) ((i,t)::l) = FreeGroup.lift (u n) g := by + rw [← hg, evalList_eq_lift] + rw [hword] + exact norm_sub_le_norm_sub_add_norm_sub _ _ _ + have hab := asymptotic_first_letter_endpoints τ h1 htr R hR U + (fun g hg => by + apply tendsto_zero_iff_norm_tendsto_zero.mpr + simpa only [U, lift_comp_hom] using hfree g hg) a' b' hw + have hh : Tendsto (fun n => ‖τ.toPreGNS (a' n-b' n)‖) atTop (nhds ‖a-b‖) := by + simpa only [← map_sub, hilbertMap_norm] using (ha'.sub hb').norm + exact sub_eq_zero.mp (norm_eq_zero.mp (tendsto_nhds_unique hh hab)) + +end HochschildLiouville + + + +open MeasureTheory Filter Topology TopologicalSpace +namespace HochschildProbability + + +theorem ae_constant_of_support_unique {Ω H : Type*} [MeasurableSpace Ω] [Nonempty Ω] + [NormedAddCommGroup H] (μ : Measure Ω) [IsFiniteMeasure μ] + (f : Ω → H) (hf : AEStronglyMeasurable f μ) + (huniq : ∀ a b : H, + (∀ r > 0, 0 < μ.real {ω | ‖f ω-a‖ < r}) → + (∀ r > 0, 0 < μ.real {ω | ‖f ω-b‖ < r}) → a = b) : + ∃ a : H, ∀ᵐ ω ∂μ, f ω = a := by + classical + by_contra hn + have hn' (b : H) : ¬ ∀ᵐ ω ∂μ, f ω = b := fun h => hn ⟨b,h⟩ + let f' := hf.mk f + let S := Set.range f' + have : SeparableSpace S := hf.stronglyMeasurable_mk.isSeparable_range.separableSpace + have : Nonempty S := ⟨⟨f' (Classical.arbitrary Ω), ⟨_,rfl⟩⟩⟩ + let g : Ω → S := fun ω => ⟨f' ω, ⟨ω,rfl⟩⟩ + have hg : ∀ b : S, ∃ᵐ ω ∂μ, g ω ≠ b := by + intro b + apply Filter.not_eventually.mp + intro hb + apply hn' b.val + filter_upwards [hf.ae_eq_mk, hb] with ω he hb + exact he.trans (congrArg Subtype.val hb) + obtain ⟨a,b,hab,ha,hb⟩ := exists_ne_forall_mem_nhds_pos_measure_preimage hg + have hs (x : S) (hx : ∀ s ∈ 𝓝 x, 0 < μ (g ⁻¹' s)) : + ∀ r > 0, 0 < μ.real {ω | ‖f ω-x.val‖ < r} := by + intro r hr + have hp := hx (Metric.ball x r) (Metric.ball_mem_nhds x hr) + have he : μ {ω | ‖f ω-x.val‖ < r} = μ (g ⁻¹' Metric.ball x r) := by + apply measure_congr + filter_upwards [hf.ae_eq_mk] with ω hω + change (‖f ω-x.val‖ < r) = (dist (g ω) x < r) + rw [Subtype.dist_eq, dist_eq_norm] + change (‖f ω-x.val‖ < r) = (‖f' ω-x.val‖ < r) + rw [hω] + rw [Measure.real, he] + exact ENNReal.toReal_pos hp.ne' (measure_ne_top _ _) + exact hab (Subtype.ext (huniq a.val b.val (hs a ha) (hs b hb))) + +end HochschildProbability + + + +open MeasureTheory ProbabilityTheory Filter Topology +open scoped RealInnerProductSpace ENNReal +namespace HochschildWalk +variable {G : Type*} [Group G] [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (μ : Measure G) [IsProbabilityMeasure μ] +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H] + +lemma processLp_const_inner (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) (n : ℕ) (c : H) : + inner ℝ (processLp μ D C hD n-processLp μ D C hD 0) + (Lp.const 2 (pathMeasure μ) c) = 0 := by + induction n with + | zero => simp + | succ n ih => + have hstep : inner ℝ (processLp μ D C hD (n+1)-processLp μ D C hD n) + (Lp.const 2 (pathMeasure μ) c) = 0 := by + rw [L2.inner_def] + have he := increment_inner_integral μ D C hD hh n (fun _ => c) ‖c‖ (fun _ => le_rfl) + refine Eq.trans (integral_congr_ae ?_) he + filter_upwards [Lp.coeFn_sub (processLp μ D C hD (n+1)) (processLp μ D C hD n), + processLp_ae μ D C hD (n+1), processLp_ae μ D C hD n, + Lp.coeFn_const 2 (pathMeasure μ) c] with ω hs hn hn' hc + rw [hs,Pi.sub_apply,hn,hn',hc] + rfl + have he : processLp μ D C hD (n+1)-processLp μ D C hD 0 = + (processLp μ D C hD (n+1)-processLp μ D C hD n) + + (processLp μ D C hD n-processLp μ D C hD 0) := by abel + rw [he,inner_add_left,hstep,ih,add_zero] + +omit [InnerProductSpace ℝ H] [CompleteSpace H] in +lemma processLp_zero (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) : + processLp μ D C hD 0 = Lp.const 2 (pathMeasure μ) (D 1) := by + apply Lp.ext + filter_upwards [processLp_ae μ D C hD 0, Lp.coeFn_const 2 (pathMeasure μ) (D 1)] with ω he hc + simp only [he,hc,walk,word,List.ofFn_zero,List.prod_nil,Function.const_apply] + + + +theorem atoms_eq_of_constant_limit (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) + (z : Lp H 2 (pathMeasure μ)) (hz : Tendsto (fun n => processLp μ D C hD n) atTop (nhds z)) + (c : H) (hc : ∀ᵐ ω ∂pathMeasure μ, z ω = c) : + ∀ g, μ {g} ≠ 0 → D g = D 1 := by + let Z := processLp μ D C hD + have hzconst : z = Lp.const 2 (pathMeasure μ) c := by + apply Lp.ext + filter_upwards [hc, Lp.coeFn_const 2 (pathMeasure μ) c] with ω hω hconst + exact hω.trans hconst.symm + have hdiff : Lp.const 2 (pathMeasure μ) (c-D 1) = z-Z 0 := by + rw [map_sub,hzconst,show Z 0 = _ from processLp_zero μ D C hD] + have hlim := ((hz.sub_const (Z 0)).inner tendsto_const_nhds : + Tendsto (fun n => inner ℝ (Z n-Z 0) (Lp.const 2 (pathMeasure μ) (c-D 1))) + atTop (nhds (inner ℝ (z-Z 0) (Lp.const 2 (pathMeasure μ) (c-D 1))))) + have hzero : inner ℝ (z-Z 0) (Lp.const 2 (pathMeasure μ) (c-D 1)) = 0 := + tendsto_nhds_unique hlim (by simpa only [Z,processLp_const_inner μ D C hD hh] using + (tendsto_const_nhds : Tendsto (fun _ : ℕ => (0:ℝ)) atTop (nhds 0))) + rw [hdiff,real_inner_self_eq_norm_sq] at hzero + have heq : z = Z 0 := sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp hzero)) + obtain ⟨z',hz',_,hbound⟩ := HochschildMartingale.uniform_cauchy_error Z + (fun _ _ h => processLp_orthogonal μ D C hD hh h) C (processLp_norm_le μ D C hD) + have heq' : z' = Z 0 := (tendsto_nhds_unique hz' hz).trans heq + have hZ1 : Z 1 = Z 0 := by + have hb := hbound 0 1 (by omega) + rw [heq',sub_self,norm_zero,zero_pow (by decide : 2 ≠ 0)] at hb + exact sub_eq_zero.mp (norm_eq_zero.mp (sq_eq_zero_iff.mp (le_antisymm hb (sq_nonneg _)))) + have hpath : ∀ᵐ ω ∂pathMeasure μ, D (ω 0) = D 1 := by + have hae := Lp.ext_iff.mp hZ1 + filter_upwards [hae,processLp_ae μ D C hD 1,processLp_ae μ D C hD 0] with ω he h1 h0 + change processLp μ D C hD 1 ω = processLp μ D C hD 0 ω at he + rw [h1,h0] at he + simpa [walk,word,takePath,List.ofFn_succ] using he + have hg : ∀ᵐ g ∂μ, D g = D 1 := by + have hm : (pathMeasure μ).map (Function.eval 0) = μ := + Measure.infinitePi_map_eval (fun _ : ℕ => μ) 0 + rw [← hm] + exact (ae_map_iff (measurable_pi_apply 0).aemeasurable (Set.to_countable _).measurableSet).mpr hpath + exact ae_iff_of_countable.mp hg + +end HochschildWalk + + + +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildLiouville +open HochschildRigidity HochschildWalk HochschildFirstLetter TracialUltrapower +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) +variable (hf : ∀ x : A, τ (star x * x) = 0 → x = 0) +variable {G : Type*} [Group G] [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (ρ : G →* unitary A) (R : A →L[ℂ] A) +variable (μ : Measure G) [IsProbabilityMeasure μ] + +include htr hf + + +theorem atoms_multiplier (hR : BallSequential τ.toPreGNS R) + (hsym : μ.map (fun g => g⁻¹) = μ) + (time : ℕ → ℕ) (htime : Tendsto time atTop atTop) + (hmom : FreeMomentsInProbability μ (fun g => ‖τ (ρ g : A)‖) time) + (hh : ∀ g, ∫ u, hilbertD τ h1 ρ R (g*u) ∂μ = hilbertD τ h1 ρ R g) : + ∀ g, μ {g} ≠ 0 → R (ρ g : A) = R 1 * (ρ g : A) := by + let : InnerProductSpace ℝ τ.GNS := InnerProductSpace.rclikeToReal ℂ τ.GNS + obtain ⟨z,hz,he,hc⟩ := harmonic_mean_square_convergence μ (hilbertD τ h1 ρ R) + (‖R‖*‖(1:A)‖) (hilbertD_norm τ h1 ρ R) hh + obtain ⟨a,ha⟩ := HochschildProbability.ae_constant_of_support_unique (pathMeasure μ) z + (Lp.aestronglyMeasurable z) (support_rigidity τ h1 htr ρ R μ hR hsym time htime hmom z he hc) + have hatom := atoms_eq_of_constant_limit μ (hilbertD τ h1 ρ R) + (‖R‖*‖(1:A)‖) (hilbertD_norm τ h1 ρ R) hh z hz a ha + intro g hg + have he := hatom g hg + have hn : ‖τ.toPreGNS (algebraD ρ R g-algebraD ρ R 1)‖ = 0 := by + rw [← hilbertMap_norm τ h1, map_sub] + change ‖hilbertD τ h1 ρ R g-hilbertD τ h1 ρ R 1‖ = 0 + rw [he, sub_self, norm_zero] + have heq := sub_eq_zero.mp ((preGNS_norm_eq_zero_iff τ hf _).mp hn) + have heq' := congrArg (fun x : A => x*(ρ g : A)) heq + rw [algebraD_mul] at heq' + simpa [algebraD] using heq' + + + +theorem multiplier_of_walk (hR : BallSequential τ.toPreGNS R) + (hsym : μ.map (fun g => g⁻¹) = μ) + (time : ℕ → ℕ) (htime : Tendsto time atTop atTop) + (hmom : FreeMomentsInProbability μ (fun g => ‖τ (ρ g : A)‖) time) + (hh : ∀ g, ∫ u, hilbertD τ h1 ρ R (g*u) ∂μ = hilbertD τ h1 ρ R g) + (hdense : ∀ u : unitary A, ∃ g : ℕ → G, (∀ n, μ {g n} ≠ 0) ∧ + Tendsto (fun n => ‖τ.toPreGNS ((ρ (g n) : A)-(u:A))‖) atTop (𝓝 0)) : + ∀ x : A, R x = R 1*x := by + have hatom := atoms_multiplier τ h1 htr hf ρ R μ hR hsym time htime hmom hh + have hu (u : unitary A) : R (u:A) = R 1*(u:A) := by + obtain ⟨g,hg,hlim⟩ := hdense u + have hbound : ∀ n, ‖(ρ (g n) : A)-(u:A)‖ ≤ 2*‖(1:A)‖ := by + intro n + have ha := CStarRing.norm_coe_unitary_mul (ρ (g n)) (1:A) + have hb := CStarRing.norm_coe_unitary_mul u (1:A) + simp only [mul_one] at ha hb + exact (norm_sub_le _ _).trans (by rw [ha,hb]; ring_nf; rfl) + have hRl := hR (fun n => (ρ (g n):A)-(u:A)) ⟨_,hbound⟩ hlim + have hmul : Tendsto (fun n => ‖τ.toPreGNS (R 1*((ρ (g n):A)-(u:A)))‖) atTop (𝓝 0) := + squeeze_zero (fun _ => norm_nonneg _) (fun _ => preGNS_norm_mul_le τ _ _) + (by simpa using hlim.const_mul ‖R 1‖) + have hzero : Tendsto (fun _ : ℕ => ‖τ.toPreGNS (R (u:A)-R 1*(u:A))‖) atTop (𝓝 0) := by + apply squeeze_zero (fun _ => norm_nonneg _) (fun n => ?_) (by simpa using hRl.add hmul) + have he : R (u:A)-R 1*(u:A) = + -(R ((ρ (g n):A)-(u:A))) + R 1*((ρ (g n):A)-(u:A)) := by + rw [map_sub,mul_sub,hatom _ (hg n)] + abel + rw [he,map_add,map_neg] + exact (norm_add_le _ _).trans_eq (by simp only [norm_neg, map_sub]) + have hz := tendsto_nhds_unique tendsto_const_nhds hzero + exact sub_eq_zero.mp ((preGNS_norm_eq_zero_iff τ hf _).mp hz) + intro x + obtain ⟨u,c,hx,_⟩ := CStarAlgebra.exists_sum_four_unitary x + rw [hx,map_sum,Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + rw [map_smul, hu, mul_smul_comm] + +end HochschildLiouville + + + +open MeasureTheory Filter Topology +open scoped ComplexOrder +namespace HochschildLiouville +open HochschildWalk HochschildRigidity +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) +variable {G : Type*} [Group G] [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (ρ : G →* unitary A) (R : A →L[ℂ] A) +variable (μ : Measure G) [IsProbabilityMeasure μ] + + + +theorem hilbertD_harmonic + (hh : ∀ x : A, ∫ u, R (x*(ρ u:A)) * (ρ u⁻¹:A) ∂μ = R x) : + ∀ g, ∫ u, hilbertD τ h1 ρ R (g*u) ∂μ = hilbertD τ h1 ρ R g := by + intro g + let L : A →L[ℂ] τ.GNS := (hilbertMap τ h1).comp + ((ContinuousLinearMap.mul ℂ A).flip (ρ g⁻¹:A)) + have hb (u : G) : ‖R ((ρ g:A)*(ρ u:A)) * (ρ u⁻¹:A)‖ ≤ ‖R‖*‖(1:A)‖ := by + rw [CStarRing.norm_mul_coe_unitary] + have he : ‖(ρ g:A)*(ρ u:A)‖ = ‖(1:A)‖ := by + rw [CStarRing.norm_coe_unitary_mul] + have h := CStarRing.norm_coe_unitary_mul (ρ u) (1:A) + simpa only [mul_one] using h + exact (R.le_opNorm _).trans_eq (by rw [he]) + have hi : Integrable (fun u => R ((ρ g:A)*(ρ u:A))*(ρ u⁻¹:A)) μ := + integrable_of_countable_bound μ _ (‖R‖*‖(1:A)‖) hb + have he (u : G) : hilbertD τ h1 ρ R (g*u) = L (R ((ρ g:A)*(ρ u:A))*(ρ u⁻¹:A)) := by + simp only [hilbertD,algebraD,map_mul,Submonoid.coe_mul,mul_inv_rev] + simp only [mul_assoc,L,ContinuousLinearMap.comp_apply,ContinuousLinearMap.flip_apply, + ContinuousLinearMap.mul_apply'] + simp_rw [he] + rw [L.integral_comp_comm hi,hh] + rfl + +end HochschildLiouville +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Main.lean b/lean/OAI/Analysis/BoundedHochschild/Main.lean new file mode 100644 index 0000000000000000000000000000000000000000..4cbf05745695e71d419070fb60dcb800bc073129 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Main.lean @@ -0,0 +1,129 @@ +import OAI.Analysis.BoundedHochschild.ProperlyInfinitePrimitives +import OAI.Analysis.BoundedHochschild.AveragedBarFaces +import OAI.Analysis.BoundedHochschild.NormalBarOperators +import OAI.Analysis.BoundedHochschild.MatrixBarLimits +import OAI.Analysis.BoundedHochschild.BarInsertionFormula +import OAI.Analysis.BoundedHochschild.CountableMatrixProjection +import OAI.Analysis.BoundedHochschild.AlgebraicMatrixPrimitives +import OAI.Analysis.BoundedHochschild.MultimodularInsertion +import OAI.Analysis.BoundedHochschild.MatrixAverageLimits +import OAI.Analysis.BoundedHochschild.NormalCochainTransport +import OAI.Analysis.BoundedHochschild.FiniteGroupModuleAverages +import OAI.Analysis.BoundedHochschild.CountableMatrixGroups +import OAI.Analysis.BoundedHochschild.MultimodularGenerators +import OAI.Analysis.BoundedHochschild.NormalMultimodularClosure +import OAI.Analysis.BoundedHochschild.CountableMatrixPrimitives +import OAI.Analysis.BoundedHochschild.MultimodularMatrixBound +import OAI.Analysis.BoundedHochschild.CompletelyBoundedPrimitives +import OAI.Analysis.BoundedHochschild.RightModuleProjection +import OAI.Analysis.BoundedHochschild.Conditional +import OAI.Analysis.BoundedHochschild.CentralVanishing +import OAI.Analysis.BoundedHochschild.TracialDecomposition +import OAI.Analysis.BoundedHochschild.AbelianPrimitives +import OAI.Analysis.BoundedHochschild.OperatorTypeI +import OAI.Analysis.BoundedHochschild.AbelianTypeI +import OAI.Analysis.BoundedHochschild.FiniteCentralDecomposition +import OAI.Analysis.BoundedHochschild.TypeICentralDecomposition +import OAI.Analysis.BoundedHochschild.CenterAveragingReduction +import OAI.Analysis.BoundedHochschild.NormalStatePartitions +import OAI.Analysis.BoundedHochschild.TraceFreeComparison +import OAI.Analysis.BoundedHochschild.TypeIICharacterization +import OAI.Analysis.BoundedHochschild.FiniteIncreasingComparison +import OAI.Analysis.BoundedHochschild.NormalOrbitHull +import OAI.Analysis.BoundedHochschild.NormalOrderIntervals +import OAI.Analysis.BoundedHochschild.OrthogonalProjectionSums +import OAI.Analysis.BoundedHochschild.PositiveCompleteAdditivity +import OAI.Analysis.BoundedHochschild.WeakPredual +import OAI.Analysis.BoundedHochschild.MinimalIsometricOrbit +import OAI.Analysis.BoundedHochschild.FiniteTracialDecomposition +import OAI.Analysis.BoundedHochschild.HomogeneousTypeIPrimitives +import OAI.Analysis.BoundedHochschild.FiniteTypeIVanishing +import OAI.Analysis.BoundedHochschild.ClassicalVanishingReduction +import OAI.Analysis.BoundedHochschild.InfiniteMatrixColumns +import OAI.Analysis.BoundedHochschild.ProperlyInfiniteMatrixSystems +import OAI.Analysis.BoundedHochschild.MatrixAmplification +import OAI.Analysis.BoundedHochschild.CompletelyBoundedRows +import OAI.Analysis.BoundedHochschild.MinimalRightAverages +import OAI.Analysis.BoundedHochschild.RightModuleFixedPoints +import OAI.Analysis.BoundedHochschild.WeakCompletelyBoundedClosure +import OAI.Analysis.BoundedHochschild.NormalGNSWeakTopology +import OAI.Analysis.BoundedHochschild.NormalGNSMatrices +import OAI.Analysis.BoundedHochschild.StinespringEmbedding +import OAI.Analysis.BoundedHochschild.UnitalPositiveExtension +import OAI.Analysis.BoundedHochschild.PositiveUnitBlocks +import OAI.Analysis.BoundedHochschild.CompletelyBoundedFactorization +import OAI.Analysis.BoundedHochschild.NormalFactorCandidates +import OAI.Analysis.BoundedHochschild.RepresentedAveragingConvexity +import OAI.Analysis.BoundedHochschild.AveragingOrbitFactorization +import OAI.Analysis.BoundedHochschild.InfiniteAveragingLimits +import OAI.Analysis.BoundedHochschild.InfiniteInvariantFamilies +import OAI.Analysis.BoundedHochschild.InfiniteRepresentedFamilies +import OAI.Analysis.BoundedHochschild.CentralSupportNormalizedRows +import OAI.Analysis.BoundedHochschild.PositiveProjectionGap +import OAI.Analysis.BoundedHochschild.RightModuleAveragingExistence +import OAI.Analysis.BoundedHochschild.SimultaneousModuleAverages + +namespace OAI + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open scoped ComplexOrder + +universe u + +/-- Every bounded higher cocycle on a von Neumann algebra has a bounded +primitive. No complete-boundedness or normality assumption is required. -/ +theorem bounded_primitive + {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} (f : Cochain M (n + 2)) + (hf : differential f = 0) : + ∃ g : Cochain M (n + 1), differential g = f := by + obtain ⟨g, hg⟩ := primitive_of_properlyInfinite_input e properlyInfiniteVanishingInput f + ((differential_eq_zero_iff f).mp hf) + refine ⟨g, ?_⟩ + ext x + simpa only [differential_apply] using hg x + +/-- Theorem 1.1: ordinary bounded Hochschild cohomology vanishes in every +degree at least two, with the actual image of the differential. -/ +theorem vanishing + {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] [WStarAlgebra M] + (k : ℕ) (hk : 2 ≤ k) : + (∀ f : Cochain M k, differential f = 0 → + ∃ g : Cochain M (k - 1), incomingDifferential M k g = f) ∧ + Subsingleton (Cohomology M k) := by + obtain ⟨X, hX, hXS, hXC, ⟨e⟩⟩ := WStarAlgebra.exists_predual (M := M) + let := hX + let := hXS + let := hXC + exact vanishing_of_published_inputs (centralDecompositionInput e) classicalVanishingInput k hk + +/-- A separately normal higher cocycle on a tracial type II₁ algebra has an +actual bounded primitive with norm at most its own norm. -/ +theorem normal_tracial_primitive + {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a * b) = τ (b * a)) + (hfaith : ∀ a : M, τ (star a * a) = 0 → a = 0) (h1 : τ 1 = 1) + (hII : PopaTypeII.NoTypeICentralPart M) {n : ℕ} + (f : Cochain M (n + 2)) (hf : differential f = 0) + (hn : SeparatelyNormal e f) : + ∃ g : Cochain M (n + 1), ‖g‖ ≤ ‖f‖ ∧ differential g = f := by + obtain ⟨g, hgn, hg⟩ := source_tracial_primitive e τ hτ htr hfaith h1 hII f + ((differential_eq_zero_iff f).mp hf) + ((separatelyNormal_iff_tracialSeparatelyNormal e f).mp hn) + refine ⟨g, hgn, ?_⟩ + ext x + simpa only [differential_apply] using hg x + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MainResult.lean b/lean/OAI/Analysis/BoundedHochschild/MainResult.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd7dd9075c4cf8d61b9c77a25b1f71ff53ff6ab4 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MainResult.lean @@ -0,0 +1,36 @@ +import OAI.Analysis.BoundedHochschild.Main + +namespace OAI + +/-! Ordinary bounded Hochschild cocycles in degrees at least two are coboundaries. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u + +theorem main_result + {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] [WStarAlgebra M] + (n : ℕ) (f : Cochain M (n + 2)) + (hf : ∀ x : Fin (n + 3) → M, differentialValue f x = 0) : + ∃ g : Cochain M (n + 1), ∀ x : Fin (n + 2) → M, + differentialValue g x = f x := by + obtain ⟨X, hX, hXS, hXC, ⟨e⟩⟩ := WStarAlgebra.exists_predual (M := M) + let := hX + let := hXS + let := hXC + have hf' : differential f = 0 := by + ext x + simpa only [differential_apply, zero_apply] using hf x + obtain ⟨g, hg⟩ := bounded_primitive e f hf' + refine ⟨g, ?_⟩ + intro x + have h := congrArg (fun h : Cochain M (n + 2) => h x) hg + simpa only [differential_apply] using h + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/Martingales.lean b/lean/OAI/Analysis/BoundedHochschild/Martingales.lean new file mode 100644 index 0000000000000000000000000000000000000000..ca8e6b4fbf7f9ef83dfabcb7829666a4c5c4ff09 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/Martingales.lean @@ -0,0 +1,325 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.Ultrapowers + +namespace OAI + +/-! Hilbert-valued martingale limits and random-walk mean-square convergence. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +namespace HochschildMartingale + +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H] + +omit [CompleteSpace H] in + +lemma energy_identity (Z : ℕ → H) + (horth : ∀ k n, k ≤ n → inner ℝ (Z n - Z k) (Z k) = 0) {k n : ℕ} (hkn : k ≤ n) : + ‖Z n - Z k‖ ^ 2 = ‖Z n‖ ^ 2 - ‖Z k‖ ^ 2 := by + have h := horth k n hkn + rw [inner_sub_left, real_inner_self_eq_norm_sq] at h + rw [norm_sub_sq_real] + linarith + + + +theorem exists_limit_of_bounded_orthogonal_increments (Z : ℕ → H) + (horth : ∀ k n, k ≤ n → inner ℝ (Z n - Z k) (Z k) = 0) + (C : ℝ) (hb : ∀ n, ‖Z n‖ ≤ C) : + ∃ z : H, Tendsto Z atTop (𝓝 z) ∧ + ∀ k n, k ≤ n → ‖Z n - Z k‖ ^ 2 = ‖z - Z k‖ ^ 2 - ‖z - Z n‖ ^ 2 := by + have hmono : Monotone (fun n => ‖Z n‖ ^ 2) := by + intro k n hkn + have := sq_nonneg ‖Z n-Z k‖ + rw [energy_identity Z horth hkn] at this + linarith + have hbd : BddAbove (Set.range (fun n => ‖Z n‖^2)) := by + refine ⟨C^2, ?_⟩ + rintro x ⟨n,rfl⟩ + exact pow_le_pow_left₀ (norm_nonneg _) (hb n) _ + let L : ℝ := ⨆ n, ‖Z n‖^2 + have hlim : Tendsto (fun n => ‖Z n‖^2) atTop (𝓝 L) := tendsto_atTop_ciSup hmono hbd + have hc : CauchySeq Z := by + apply cauchySeq_of_le_tendsto_0' (fun n => Real.sqrt (L-‖Z n‖^2)) + · intro n m hnm + rw [dist_eq_norm, norm_sub_rev] + apply Real.le_sqrt_of_sq_le + rw [energy_identity Z horth hnm] + exact sub_le_sub_right (le_ciSup hbd m) _ + · simpa only [sub_self, Real.sqrt_zero] using ((tendsto_const_nhds (x := L)).sub hlim).sqrt + obtain ⟨z,hz⟩ := cauchySeq_tendsto_of_complete hc + refine ⟨z,hz,?_⟩ + intro k n hkn + have he (i : ℕ) : ‖z-Z i‖^2 = ‖z‖^2-‖Z i‖^2 := by + have ha : Tendsto (fun m => ‖Z m-Z i‖^2) atTop (𝓝 (‖z-Z i‖^2)) := + (hz.sub_const _).norm.pow 2 + have hb' : Tendsto (fun m => ‖Z m‖^2-‖Z i‖^2) atTop (𝓝 (‖z‖^2-‖Z i‖^2)) := + (hz.norm.pow 2).sub_const _ + exact tendsto_nhds_unique ha (hb'.congr' (eventually_atTop.2 + ⟨i,fun m hm => (energy_identity Z horth hm).symm⟩)) + rw [he k,he n,energy_identity Z horth hkn] + ring + + +theorem uniform_cauchy_error (Z : ℕ → H) + (horth : ∀ k n, k ≤ n → inner ℝ (Z n - Z k) (Z k) = 0) + (C : ℝ) (hb : ∀ n, ‖Z n‖ ≤ C) : + ∃ z : H, Tendsto Z atTop (𝓝 z) ∧ + Tendsto (fun k => ‖z-Z k‖^2) atTop (𝓝 0) ∧ + ∀ k n, k ≤ n → ‖Z n-Z k‖^2 ≤ ‖z-Z k‖^2 := by + obtain ⟨z,hz,he⟩ := exists_limit_of_bounded_orthogonal_increments Z horth C hb + refine ⟨z,hz,?_,fun k n hkn => ?_⟩ + · simpa using ((tendsto_const_nhds (x := z)).sub hz).norm.pow 2 + · rw [he k n hkn] + exact sub_le_self _ (sq_nonneg _) + +variable {Ω : Type*} [MeasurableSpace Ω] {μ : Measure Ω} [IsFiniteMeasure μ] +variable {ℱ : Filtration ℕ ‹MeasurableSpace Ω›} {f : ℕ → Ω → H} + + +lemma martingale_L2_orthogonal (hm : Martingale f ℱ μ) (h2 : ∀ n, MemLp (f n) 2 μ) + {k n : ℕ} (hkn : k ≤ n) : + inner ℝ ((h2 n).toLp (f n) - (h2 k).toLp (f k)) ((h2 k).toLp (f k)) = 0 := by + have hcond : (condExpL2 H ℝ (ℱ.le k) ((h2 n).toLp (f n)) : Lp H 2 μ) = + (h2 k).toLp (f k) := by + apply Lp.ext + exact ((h2 n).condExpL2_ae_eq_condExp (𝕜 := ℝ) (ℱ.le k)).trans + ((hm.2 k n hkn).trans (h2 k).coeFn_toLp.symm) + have hinner := inner_condExpL2_eq_inner_fun (𝕜 := ℝ) (ℱ.le k) ((h2 n).toLp (f n)) + ((h2 k).toLp (f k)) + (((hm.stronglyMeasurable k).aestronglyMeasurable).congr (h2 k).coeFn_toLp.symm) + rw [hcond] at hinner + rw [inner_sub_left, ← hinner, sub_self] + + +theorem martingale_L2_convergence (hm : Martingale f ℱ μ) (h2 : ∀ n, MemLp (f n) 2 μ) + (C : ℝ) (hb : ∀ n, ‖(h2 n).toLp (f n)‖ ≤ C) : + ∃ z : Lp H 2 μ, Tendsto (fun n => (h2 n).toLp (f n)) atTop (𝓝 z) ∧ + Tendsto (fun k => ‖z-(h2 k).toLp (f k)‖^2) atTop (𝓝 0) ∧ + ∀ k n, k ≤ n → ‖(h2 n).toLp (f n)-(h2 k).toLp (f k)‖^2 ≤ + ‖z-(h2 k).toLp (f k)‖^2 := + uniform_cauchy_error _ (fun _ _ hkn => martingale_L2_orthogonal hm h2 hkn) C hb + +end HochschildMartingale + +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +namespace HochschildWalk +variable {G : Type*} [Group G] [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (μ : Measure G) [IsProbabilityMeasure μ] +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H] + + +def pathMeasure : Measure (ℕ → G) := Measure.infinitePi (fun _ : ℕ => μ) +instance : IsProbabilityMeasure (pathMeasure μ) := by unfold pathMeasure; infer_instance + +def takePath (n : ℕ) (ω : ℕ → G) : Fin n → G := fun i => ω i + +def word {n : ℕ} (ω : Fin n → G) : G := (List.ofFn ω).prod + +def walk (n : ℕ) (ω : ℕ → G) : G := word (takePath n ω) + +omit [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] in +lemma walk_succ (n : ℕ) (ω : ℕ → G) : walk (n+1) ω = walk n ω * ω n := by + unfold walk word + rw [List.ofFn_succ', List.prod_concat] + rfl + +omit [Group G] [Countable G] [MeasurableSingletonClass G] in +lemma takePath_measurable (n : ℕ) : Measurable (takePath (G := G) n) := by + exact Measurable.of_eval (fun index : Fin n => measurable_pi_apply (index : ℕ)) + +omit [Group G] [Countable G] [MeasurableSingletonClass G] in +lemma takePath_law (n : ℕ) : (pathMeasure μ).map (takePath n) = Measure.pi (fun _ : Fin n => μ) := by + have h := Measure.map_infinitePi_infinitePi_of_inj (P := fun _ : ℕ => μ) + (f := (Fin.val : Fin n → ℕ)) Fin.val_injective + change (Measure.infinitePi (fun _ : ℕ => μ)).map (fun ω (i : Fin n) => ω (i : ℕ)) = _ + rw [h, Measure.infinitePi_eq_pi] + +lemma walk_measurable (n : ℕ) : Measurable (walk (G := G) n) := + (measurable_of_countable (word (G := G) (n := n))).comp (takePath_measurable n) + +omit [CompleteSpace H] [Group G] in +lemma takePath_integral (n : ℕ) (F : (Fin n → G) → H) : + ∫ ω, F (takePath n ω) ∂pathMeasure μ = ∫ w, F w ∂Measure.pi (fun _ : Fin n => μ) := by + rw [← takePath_law μ n] + exact (integral_map (takePath_measurable n).aemeasurable + (StronglyMeasurable.of_discrete (f := F)).aestronglyMeasurable).symm + +omit [Group G] [MeasurableSingletonClass G] [CompleteSpace H] in + +lemma last_integral (n : ℕ) (F : (Fin n → G) → G → H) + (hF : Integrable (fun p : (Fin n → G) × G => F p.1 p.2) + ((Measure.pi (fun _ : Fin n => μ)).prod μ)) : + ∫ v : Fin (n+1) → G, F (fun i => v i.castSucc) (v (Fin.last n)) + ∂Measure.pi (fun _ : Fin (n+1) => μ) = + ∫ w : Fin n → G, ∫ u, F w u ∂μ ∂Measure.pi (fun _ : Fin n => μ) := by + have h := (measurePreserving_piFinSuccAbove (fun _ : Fin (n+1) => μ) (Fin.last n)).integral_comp' + (fun p => F p.2 p.1) + have he : ∀ v : Fin (n+1) → G, + (fun p : G × (Fin n → G) => F p.2 p.1) + ((MeasurableEquiv.piFinSuccAbove (fun _ : Fin (n+1) => G) (Fin.last n)) v) = + F (fun i => v i.castSucc) (v (Fin.last n)) := by + intro v + simp [MeasurableEquiv.piFinSuccAbove] + rfl + simp only [he] at h + rw [h] + calc + _ = ∫ p : (Fin n → G) × G, F p.1 p.2 ∂(Measure.pi (fun _ : Fin n => μ)).prod μ := + integral_prod_swap (fun p : (Fin n → G) × G => F p.1 p.2) + _ = _ := integral_prod _ hF + +omit [InnerProductSpace ℝ H] [CompleteSpace H] in + +lemma integrable_of_countable_bound {S : Type*} [Countable S] [MeasurableSpace S] + [MeasurableSingletonClass S] (ν : Measure S) [IsFiniteMeasure ν] + (f : S → H) (C : ℝ) (hb : ∀ x, ‖f x‖ ≤ C) : Integrable f ν := + Integrable.of_bound (StronglyMeasurable.of_discrete (f := f)).aestronglyMeasurable C + (Filter.Eventually.of_forall hb) + + +lemma increment_inner_integral (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) (n : ℕ) + (Y : (Fin n → G) → H) (B : ℝ) (hY : ∀ w, ‖Y w‖ ≤ B) : + ∫ ω, inner ℝ (D (walk (n+1) ω)-D (walk n ω)) (Y (takePath n ω)) ∂pathMeasure μ = 0 := by + let F (w : Fin n → G) (u : G) := inner ℝ (D (word w*u)-D (word w)) (Y w) + have hF : ∀ w u, ‖F w u‖ ≤ (C+C)*B := by + intro w u + calc + _ ≤ ‖D (word w*u)-D (word w)‖ * ‖Y w‖ := norm_inner_le_norm _ _ + _ ≤ (C+C)*B := mul_le_mul + ((norm_sub_le _ _).trans (add_le_add (hD _) (hD _))) (hY _) (norm_nonneg _) + (add_nonneg ((norm_nonneg (D 1)).trans (hD 1)) ((norm_nonneg (D 1)).trans (hD 1))) + have hstep : ∀ w, ∫ u, F w u ∂μ = 0 := by + intro w + have hi : Integrable (fun u => D (word w*u)) μ := integrable_of_countable_bound μ _ C (fun _ => hD _) + simp_rw [show F w = fun u => inner ℝ (D (word w*u)-D (word w)) (Y w) from rfl, + real_inner_comm] + have he := integral_inner (𝕜 := ℝ) (hi.sub (integrable_const (D (word w)))) (Y w) + simp only [Pi.sub_apply] at he + rw [he, integral_sub hi (integrable_const _), hh, integral_const] + simp + have hhF := integrable_of_countable_bound + ((Measure.pi (fun _ : Fin n => μ)).prod μ) (fun p => F p.1 p.2) ((C+C)*B) + (fun p => hF p.1 p.2) + have hm : (fun ω => inner ℝ (D (walk (n+1) ω)-D (walk n ω)) (Y (takePath n ω))) = + fun ω => (fun v : Fin (n+1) → G => F (fun i => v i.castSucc) (v (Fin.last n))) + (takePath (n+1) ω) := by + funext ω + rw [walk_succ] + rfl + rw [hm, takePath_integral μ (n+1) (fun v => F (fun i => v i.castSucc) (v (Fin.last n))), + last_integral μ n F hhF] + simp [hstep] + +omit [CompleteSpace H] [InnerProductSpace ℝ H] in +lemma process_memLp (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) (n : ℕ) : + MemLp (fun ω => D (walk n ω)) 2 (pathMeasure μ) := + MemLp.of_bound ((StronglyMeasurable.of_discrete (f := D)).comp_measurable + (walk_measurable n)).aestronglyMeasurable C (Filter.Eventually.of_forall (fun _ => hD _)) + + +def processLp (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) (n : ℕ) : + Lp H 2 (pathMeasure μ) := (process_memLp μ D C hD n).toLp (fun ω => D (walk n ω)) + +omit [CompleteSpace H] [InnerProductSpace ℝ H] in +lemma processLp_ae (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) (n : ℕ) : + processLp μ D C hD n =ᵐ[pathMeasure μ] fun ω => D (walk n ω) := + (process_memLp μ D C hD n).coeFn_toLp + +omit [CompleteSpace H] [InnerProductSpace ℝ H] in +lemma processLp_norm_le (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) (n : ℕ) : + ‖processLp μ D C hD n‖ ≤ C := by + have hC : 0 ≤ C := (norm_nonneg (D 1)).trans (hD 1) + have ha : ∀ᵐ ω ∂pathMeasure μ, ‖processLp μ D C hD n ω‖ ≤ C := by + filter_upwards [processLp_ae μ D C hD n] with ω hω + rw [hω] + exact hD _ + simpa [measureUnivNNReal] using Lp.norm_le_of_ae_bound hC ha + +lemma processLp_step_orthogonal (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) {k n : ℕ} (hkn : k ≤ n) : + inner ℝ (processLp μ D C hD (n+1)-processLp μ D C hD n) (processLp μ D C hD k) = 0 := by + let Y (w : Fin n → G) : H := D (word (fun i : Fin k => w (Fin.castLE hkn i))) + have he := increment_inner_integral μ D C hD hh n Y C (fun _ => hD _) + rw [L2.inner_def] + calc + _ = ∫ ω, inner ℝ (D (walk (n+1) ω)-D (walk n ω)) (Y (takePath n ω)) ∂pathMeasure μ := by + apply integral_congr_ae + filter_upwards [Lp.coeFn_sub (processLp μ D C hD (n+1)) (processLp μ D C hD n), + processLp_ae μ D C hD (n+1), processLp_ae μ D C hD n, + processLp_ae μ D C hD k] with ω hs hn hn' hk + rw [hs,Pi.sub_apply,hn,hn',hk] + rfl + _ = 0 := he + +lemma processLp_orthogonal (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) {k n : ℕ} (hkn : k ≤ n) : + inner ℝ (processLp μ D C hD n-processLp μ D C hD k) (processLp μ D C hD k) = 0 := by + induction n, hkn using Nat.le_induction with + | base => simp + | succ n hkn ih => + have hs := processLp_step_orthogonal μ D C hD hh hkn + have he : processLp μ D C hD (n+1)-processLp μ D C hD k = + (processLp μ D C hD (n+1)-processLp μ D C hD n) + + (processLp μ D C hD n-processLp μ D C hD k) := by abel + rw [he,inner_add_left,hs,ih,add_zero] + +end HochschildWalk + +namespace HochschildWalk +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +variable {G : Type*} [Group G] [Countable G] [MeasurableSpace G] [MeasurableSingletonClass G] +variable (μ : Measure G) [IsProbabilityMeasure μ] +variable {H : Type*} [NormedAddCommGroup H] [InnerProductSpace ℝ H] [CompleteSpace H] + +omit [CompleteSpace H] in +lemma processLp_sq_error (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) (k n : ℕ) : + ‖processLp μ D C hD n-processLp μ D C hD k‖ ^ 2 = + ∫ ω, ‖D (walk n ω)-D (walk k ω)‖ ^ 2 ∂pathMeasure μ := by + rw [← real_inner_self_eq_norm_sq, L2.inner_def] + apply integral_congr_ae + filter_upwards [Lp.coeFn_sub (processLp μ D C hD n) (processLp μ D C hD k), + processLp_ae μ D C hD n, processLp_ae μ D C hD k] with ω hs hn hk + rw [hs, Pi.sub_apply, hn, hk, real_inner_self_eq_norm_sq] + +omit [CompleteSpace H] in +lemma limitLp_sq_error (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (z : Lp H 2 (pathMeasure μ)) (n : ℕ) : + ‖z-processLp μ D C hD n‖ ^ 2 = + ∫ ω, ‖z ω-D (walk n ω)‖ ^ 2 ∂pathMeasure μ := by + rw [← real_inner_self_eq_norm_sq, L2.inner_def] + apply integral_congr_ae + filter_upwards [Lp.coeFn_sub z (processLp μ D C hD n), + processLp_ae μ D C hD n] with ω hs hn + rw [hs, Pi.sub_apply, hn, real_inner_self_eq_norm_sq] + + + +theorem harmonic_mean_square_convergence (D : G → H) (C : ℝ) (hD : ∀ g, ‖D g‖ ≤ C) + (hh : ∀ g, ∫ u, D (g*u) ∂μ = D g) : + ∃ z : Lp H 2 (pathMeasure μ), + Tendsto (fun n => processLp μ D C hD n) atTop (𝓝 z) ∧ + Tendsto (fun n => ∫ ω, ‖z ω-D (walk n ω)‖^2 ∂pathMeasure μ) atTop (𝓝 0) ∧ + ∀ k n, k ≤ n → + ∫ ω, ‖D (walk n ω)-D (walk k ω)‖^2 ∂pathMeasure μ ≤ + ∫ ω, ‖z ω-D (walk k ω)‖^2 ∂pathMeasure μ := by + obtain ⟨z,hz,he,hb⟩ := HochschildMartingale.uniform_cauchy_error (processLp μ D C hD) + (fun _ _ hkn => processLp_orthogonal μ D C hD hh hkn) C (processLp_norm_le μ D C hD) + refine ⟨z,hz,?_,?_⟩ + · simpa only [limitLp_sq_error] using he + · intro k n hkn + rw [← processLp_sq_error μ D C hD k n, ← limitLp_sq_error μ D C hD z k] + exact hb k n hkn + +end HochschildWalk +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixAlgebras.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixAlgebras.lean new file mode 100644 index 0000000000000000000000000000000000000000..943e320a9c101842ed14e43bba2f06569103ec03 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixAlgebras.lean @@ -0,0 +1,110 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Finite matrix subalgebras and their commutants. -/ + +noncomputable section + +open Filter Topology +namespace HochschildMatrixSystems.MatrixSystem +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {n : ℕ} (E : MatrixSystem M n) + +def entrySpan : Submodule ℂ M := Submodule.span ℂ (Set.range (fun p : Fin n × Fin n => E.entry p.1 p.2)) + +lemma entry_mem_span {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + {n : ℕ} (E : MatrixSystem M n) (i j : Fin n) : E.entry i j ∈ E.entrySpan := + Submodule.subset_span ⟨(i,j),rfl⟩ + +lemma one_mem_entrySpan : (1:M) ∈ E.entrySpan := by + rw [← E.sum_diagonal] + exact (E.entrySpan).sum_mem (fun i _ => E.entry_mem_span i i) + +lemma mul_mem_entrySpan {x y : M} (hx : x ∈ E.entrySpan) (hy : y ∈ E.entrySpan) : + x*y ∈ E.entrySpan := by + induction hx using Submodule.span_induction with + | mem a ha => + obtain ⟨⟨i,j⟩,rfl⟩ := ha + induction hy using Submodule.span_induction with + | mem b hb => + obtain ⟨⟨k,l⟩,rfl⟩ := hb + rw [E.entry_mul] + split + · exact E.entry_mem_span _ _ + · exact (E.entrySpan).zero_mem + | zero => simp + | add a b ha hb iha ihb => simpa [mul_add] using (E.entrySpan).add_mem iha ihb + | smul c a ha ih => simpa [mul_smul_comm] using (E.entrySpan).smul_mem c ih + | zero => simp + | add a b ha hb iha ihb => simpa [add_mul] using (E.entrySpan).add_mem iha ihb + | smul c a ha ih => simpa [smul_mul_assoc] using (E.entrySpan).smul_mem c ih + +lemma star_mem_entrySpan {x : M} (hx : x ∈ E.entrySpan) : star x ∈ E.entrySpan := by + induction hx using Submodule.span_induction with + | mem a ha => + obtain ⟨⟨i,j⟩,rfl⟩ := ha + rw [E.star_entry] + exact E.entry_mem_span _ _ + | zero => simp + | add a b ha hb iha ihb => simpa [star_add] using (E.entrySpan).add_mem iha ihb + | smul c a ha ih => simpa [star_smul] using (E.entrySpan).smul_mem (star c) ih + +def matrixAlgebra : StarSubalgebra ℂ M where + carrier := E.entrySpan + zero_mem' := (E.entrySpan).zero_mem + one_mem' := E.one_mem_entrySpan + add_mem' := (E.entrySpan).add_mem + mul_mem' := E.mul_mem_entrySpan + algebraMap_mem' c := by + change algebraMap ℂ M c ∈ E.entrySpan + rw [Algebra.algebraMap_eq_smul_one] + exact (E.entrySpan).smul_mem c E.one_mem_entrySpan + star_mem' := E.star_mem_entrySpan + +instance matrixAlgebra_finiteDimensional : FiniteDimensional ℂ E.matrixAlgebra := + FiniteDimensional.span_of_finite ℂ (Set.finite_range _) + +instance matrixAlgebra_closed : IsClosed (E.matrixAlgebra : Set M) := by + let : FiniteDimensional ℂ E.entrySpan := FiniteDimensional.span_of_finite ℂ (Set.finite_range _) + exact (E.entrySpan).closed_of_finiteDimensional + +lemma commutant_commutes_matrix (x : E.commutant) (y : E.matrixAlgebra) : + Commute (x:M) (y:M) := by + suffices h : ∀ a ∈ E.entrySpan, Commute (x:M) a from h y y.property + intro a ha + induction ha using Submodule.span_induction with + | mem a ha => + obtain ⟨⟨i,j⟩,rfl⟩ := ha + exact x.property i j + | zero => exact Commute.zero_right _ + | add a b ha hb iha ihb => exact iha.add_right ihb + | smul c a ha ih => exact ih.smul_right c + +instance matrixUnitary_compactSpace : CompactSpace (unitary E.matrixAlgebra) := by + apply isCompact_iff_compactSpace.mp + apply (isCompact_closedBall (0:E.matrixAlgebra) 1).of_isClosed_subset isClosed_unitary + intro u hu + rw [Metric.mem_closedBall,dist_zero_right] + calc + ‖u‖ = ‖(1:E.matrixAlgebra)‖ := by + simpa only [one_mul] using CStarRing.norm_mul_coe_unitary (1:E.matrixAlgebra) ⟨u,hu⟩ + _ ≤ 1 := by + rcases subsingleton_or_nontrivial E.matrixAlgebra with h | h + · have : (1:E.matrixAlgebra)=0 := Subsingleton.elim _ _ + simp [this] + · simp + +end HochschildMatrixSystems.MatrixSystem + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixAmplification.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixAmplification.lean new file mode 100644 index 0000000000000000000000000000000000000000..fdb578dc902718c37d20ca7460dd507ccb075fc3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixAmplification.lean @@ -0,0 +1,124 @@ +import OAI.Analysis.BoundedHochschild.ProperlyInfiniteMatrixSystems + +namespace OAI + +/-! +# Isometric matrix amplification from unital isometry columns + +The actual C*-matrix algebra is identified with the original algebra by +compression and reconstruction. Consequently matrix norms can be used directly +in the remaining completely bounded argument. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] {n : ℕ} +variable (c : Fin n → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) + +include hi ho in +lemma column_star_mul (i j : Fin n) : + star (c i : M) * (c j : M) = if i = j then 1 else 0 := by + split_ifs with h + · subst j + exact hi i + · exact PartialIso.star_mul_eq_zero_of_final_orthogonal (ho i j h) + +/-- The matrix of an element with respect to unital isometry columns. -/ +def columnCompression (a : M) : CStarMatrix (Fin n) (Fin n) M := + CStarMatrix.ofMatrix (fun i j => star (c i : M) * a * (c j : M)) + +/-- Reconstruction from the actual matrix entries. -/ +def columnReconstruction (A : CStarMatrix (Fin n) (Fin n) M) : M := + ∑ i, ∑ j, (c i : M) * A i j * star (c j : M) + +include hs in +lemma columnReconstruction_compression (a : M) : + columnReconstruction c (columnCompression c a) = a := by + calc + _ = ∑ i, ((c i : M) * star (c i : M)) * a * (∑ j, (c j : M) * star (c j : M)) := by + apply Finset.sum_congr rfl + intro i _ + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro j _ + change (c i : M) * (star (c i : M) * a * (c j : M)) * star (c j : M) = _ + simp only [mul_assoc] + _ = a := by + change (∑ i, (c i).final * a * (∑ j, (c j).final)) = a + rw [hs] + simp only [mul_one] + rw [← Finset.sum_mul, hs, one_mul] + +include hi ho in +lemma columnCompression_reconstruction (A : CStarMatrix (Fin n) (Fin n) M) : + columnCompression c (columnReconstruction c A) = A := by + classical + ext i j + change star (c i : M) * (∑ k, ∑ l, (c k : M) * A k l * star (c l : M)) * (c j : M) = A i j + calc + _ = ∑ k, ∑ l, (star (c i : M) * (c k : M)) * A k l * + (star (c l : M) * (c j : M)) := by + simp only [Finset.mul_sum, Finset.sum_mul] + apply Finset.sum_congr rfl + intro k _ + apply Finset.sum_congr rfl + intro l _ + simp only [mul_assoc] + _ = A i j := by simp [column_star_mul c hi ho] + +include hs in +lemma columnCompression_mul (a b : M) : + columnCompression c (a * b) = columnCompression c a * columnCompression c b := by + ext i j + change star (c i : M) * (a * b) * (c j : M) = + ∑ k, (star (c i : M) * a * (c k : M)) * (star (c k : M) * b * (c j : M)) + calc + _ = star (c i : M) * a * (∑ k, (c k : M) * star (c k : M)) * b * (c j : M) := by + change _ = star (c i : M) * a * (∑ k, (c k).final) * b * (c j : M) + rw [hs, mul_one] + simp only [mul_assoc] + _ = _ := by + simp only [Finset.mul_sum, Finset.sum_mul] + apply Finset.sum_congr rfl + intro k _ + simp only [mul_assoc] + +/-- The compression/reconstruction identification preserves the C*-norm. -/ +def columnMatrixEquiv : M ≃⋆ₐ[ℂ] CStarMatrix (Fin n) (Fin n) M where + toFun := columnCompression c + invFun := columnReconstruction c + left_inv := columnReconstruction_compression c hs + right_inv := columnCompression_reconstruction c hi ho + map_mul' := columnCompression_mul c hs + map_add' a b := by + ext i j + change star (c i : M) * (a + b) * (c j : M) = + star (c i : M) * a * (c j : M) + star (c i : M) * b * (c j : M) + rw [mul_add, add_mul] + map_smul' z a := by + ext i j + change star (c i : M) * (z • a) * (c j : M) = z • (star (c i : M) * a * (c j : M)) + rw [mul_smul_comm, smul_mul_assoc] + map_star' a := by + ext i j + change star (c i : M) * star a * (c j : M) = star (star (c j : M) * a * (c i : M)) + simp only [star_mul, star_star, mul_assoc] + +variable [PartialOrder M] [StarOrderedRing M] + +include hi ho hs in +lemma columnCompression_norm (a : M) : ‖columnCompression c a‖ = ‖a‖ := by + change ‖columnMatrixEquiv c hi ho hs a‖ = ‖a‖ + exact StarAlgEquiv.norm_map (columnMatrixEquiv c hi ho hs) a + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixAverageLimits.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixAverageLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..032190b1d9ea8358f8851a229dc52b9405c25ceb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixAverageLimits.lean @@ -0,0 +1,88 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupMultimodularity +import OAI.Analysis.BoundedHochschild.CountableMatrixGroups + +namespace OAI + +/-! Finite matrix-section averages and passage of their module identities +through a bounded pointwise weak-star limit. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [CompleteSpace X] in +lemma predualTendsto_congr_eventually (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {I : Type v} {l : Filter I} {a b : I → M} {c : M} + (hab : a =ᶠ[l] b) (ha : PredualTendsto e a l c) : PredualTendsto e b l c := by + intro z + exact (ha z).congr' (hab.mono (fun i hi => congrArg (fun d : M => e.symm d z) hi)) + +lemma multimodularAt_of_predualTendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {I : Type v} {l : Filter I} [l.NeBot] {n : ℕ} + (F : I → Cochain M (n + 1)) (f : Cochain M (n + 1)) (r : M) + (ht : ∀ x, PredualTendsto e (fun i => F i x) l (f x)) + (hF : ∀ᶠ i in l, MultimodularAt (F i) r) : MultimodularAt f r := by + have hL := (HochschildSakai.abstract_multiplication_normal e).1 + have hR := (HochschildSakai.abstract_multiplication_normal e).2 + constructor + · intro x + apply predual_tendsto_unique e (ht (Function.update x 0 (r * x 0))) + exact predualTendsto_congr_eventually e + (hF.mono (fun i hi => (hi.left x).symm)) ((hL r).tendsto e (ht x)) + · intro x + apply predual_tendsto_unique e (ht (Function.update x (Fin.last n) (x (Fin.last n) * r))) + exact predualTendsto_congr_eventually e + (hF.mono (fun i hi => (hi.right x).symm)) ((hR r).tendsto e (ht x)) + · intro x j + apply predual_tendsto_unique e (ht (Function.update x j.castSucc (x j.castSucc * r))) + exact predualTendsto_congr_eventually e + (hF.mono (fun i hi => (hi.balance x j).symm)) + (ht (Function.update x j.succ (r * x j.succ))) + +lemma exists_finite_matrix_section_average (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → HochschildComparison.PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M (n + 1)) (k : ℕ) : + ∃ (G : Type u) (_ : Group G) (_ : Fintype G) (ρ : G →* unitary M), + (∀ g, (ρ g : M) ∈ countableMatrixClosure e c) ∧ + ‖finiteGroupCochainAverage ρ f‖ ≤ ‖f‖ ∧ + ∀ i j : Fin k, MultimodularAt (finiteGroupCochainAverage ρ f) + (countableMatrixUnit c i.val j.val) := by + obtain ⟨G, hG, hGF, ρ, hρ, hspan⟩ := finite_group_spans_matrix_section e c hi ho k + let := hG + let := hGF + let _ : Fintype G := Fintype.ofFinite G + exact ⟨G, hG, inferInstance, ρ, hρ, finiteGroupCochainAverage_norm ρ f, + fun i j => finiteGroupCochainAverage_span ρ f (hspan i j)⟩ + +/-- This retains the limit of the supplied averages, so any separately +verified linear identity of those averages can be passed to the same limit. -/ +theorem matrix_section_average_limit (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → HochschildComparison.PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (F : ℕ → Cochain M (n + 1)) (C : ℝ) (hC : 0 ≤ C) + (hF : ∀ k, ‖F k‖ ≤ C) + (hmodule : ∀ k, ∀ i j : Fin k, MultimodularAt (F k) (countableMatrixUnit c i.val j.val)) : + ∃ A : Cochain M (n + 1), ‖A‖ ≤ C ∧ MultimodularOver (countableMatrixAlgebra c) A ∧ + ∀ x, PredualTendsto e (fun k => F k x) (Ultrafilter.of (atTop : Filter ℕ) : Filter ℕ) (A x) := by + let U : Ultrafilter ℕ := Ultrafilter.of atTop + have hU : (U : Filter ℕ) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨A, hA, ht⟩ := bounded_cochain_ultralimit e U F C hC hF + refine ⟨A, hA, multimodular_of_matrixUnits c hi ho A (fun i j => ?_), ht⟩ + apply multimodularAt_of_predualTendsto e F A _ ht + apply hU + filter_upwards [eventually_gt_atTop (max i j)] with k hk + exact hmodule k ⟨i, lt_of_le_of_lt (le_max_left i j) hk⟩ + ⟨j, lt_of_le_of_lt (le_max_right i j) hk⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixBarLimits.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixBarLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..2b9eeb08448025e3e5c05874f67692b998e53501 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixBarLimits.lean @@ -0,0 +1,71 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixBarOperators +import OAI.Analysis.BoundedHochschild.CochainLimitDifferential + +namespace OAI + +/-! Passage to the weak-star limit for the bar-operator identity. +This module proves convergence of the defects; it does not assert that the +finite-group defects vanish. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def matrixSectionBarDefect (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) (k : ℕ) : Cochain M (n + 1) := + differential (matrixSectionBarOperator c hi ho f k) + + matrixSectionBarOperator c hi ho (differential f) k - + (f - matrixSectionAverage c hi ho f k) + +def countableMatrixBarDefect (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) : Cochain M (n + 1) := + differential (countableMatrixBarOperator e c hi ho f) + + countableMatrixBarOperator e c hi ho (differential f) - + (f - countableMatrixAverage e c hi ho f) + +lemma countableMatrixBarDefect_tendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) (x : Fin (n + 1) → M) : + PredualTendsto e (fun k => matrixSectionBarDefect c hi ho f k x) + matrixAverageUltrafilter (countableMatrixBarDefect e c hi ho f x) := by + have hd := predual_tendsto_differential_of_predual e + (countableMatrixBarOperator_tendsto e c hi ho f) x + have hH := countableMatrixBarOperator_tendsto e c hi ho (differential f) x + have hP := predual_tendsto_sub e + (predual_tendsto_const e (f x) (matrixAverageUltrafilter : Filter ℕ)) + (countableMatrixAverage_tendsto e c hi ho f x) + simpa only [matrixSectionBarDefect, countableMatrixBarDefect, + add_apply, sub_apply, differential_apply] using + predual_tendsto_sub e (predual_tendsto_add e hd hH) hP + +/-- An eventually vanishing finite-section defect has zero weak-star limit. +The finite algebraic identity is a separate obligation. -/ +lemma countableMatrixBarDefect_eq_zero_of_eventually + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) + (h : ∀ᶠ k in (matrixAverageUltrafilter : Filter ℕ), + matrixSectionBarDefect c hi ho f k = 0) : + countableMatrixBarDefect e c hi ho f = 0 := by + ext x + apply predual_tendsto_unique e (countableMatrixBarDefect_tendsto e c hi ho f x) + apply predualTendsto_congr_eventually e _ (predual_tendsto_const e 0 _) + filter_upwards [h] with k hk + simp only [hk, zero_apply] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixBlockGroups.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixBlockGroups.lean new file mode 100644 index 0000000000000000000000000000000000000000..1a68a9514a4705a6e837728668026ae41e90ecb3 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixBlockGroups.lean @@ -0,0 +1,75 @@ +import OAI.Analysis.BoundedHochschild.HomogeneousTypeI + +namespace OAI + +/-! Finite unitary groups for finite central partitions of a matrix algebra. -/ + +noncomputable section + +open scoped BigOperators + +namespace HochschildMatrixSystems +namespace MatrixSystem + +open BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] {n r : ℕ} (E : MatrixSystem M n) + (hcomm : ∀ a b : E.commutant, Commute a b) + (p : Fin r → E.commutant) (hp : ∀ j, IsStarProjection (p j)) + (ho : ∀ i j, i ≠ j → p i * p j = 0) (hs : ∑ j, p j = 1) + +include hp in +lemma partition_coe_projection (j : Fin r) : IsStarProjection (p j : M) := by + constructor + · exact congrArg Subtype.val (hp j).isIdempotentElem.eq + · exact congrArg Subtype.val (hp j).isSelfAdjoint.star_eq + +include ho in +lemma partition_coe_orthogonal (i j : Fin r) (hij : i ≠ j) : + (p i : M) * (p j : M) = 0 := congrArg Subtype.val (ho i j hij) + +include hs in +lemma partition_coe_sum : ∑ j, (p j : M) = 1 := by + simpa using congrArg (fun a : E.commutant => (a : M)) hs + +def matrixBlockHom : (Fin r → E.signedPermutationGroup) →* unitary M := + centralBlockHom (fun j => (p j : M)) (E.partition_coe_projection p hp) + (fun j => E.commutant_central hcomm (p j)) (E.partition_coe_orthogonal p ho) + (E.partition_coe_sum p hs) E.signedPermutationGroup.subtype + +def matrixBlockSpan : Submodule ℂ M := Submodule.span ℂ + (Set.range (fun a : Fin r → E.signedPermutationGroup => + (E.matrixBlockHom hcomm p hp ho hs a : M))) + +lemma matrixBlock_entry_mem_span (j : Fin r) (a b : Fin n) : + (p j : M) * E.entry a b ∈ E.matrixBlockSpan hcomm p hp ho hs := by + exact centralBlock_mul_mem_span (fun j => (p j : M)) (E.partition_coe_projection p hp) + (fun j => E.commutant_central hcomm (p j)) (E.partition_coe_orthogonal p ho) + (E.partition_coe_sum p hs) E.signedPermutationGroup.subtype j + ⟨-1, E.neg_one_mem_signedPermutationGroup⟩ rfl (E.entry_mem_signedPermutation_span a b) + +lemma matrixBlock_refined_entry_mem_span (q : E.commutant) + (hq : ∀ j, q * p j = 0 ∨ q * p j = p j) (a b : Fin n) : + (q : M) * E.entry a b ∈ E.matrixBlockSpan hcomm p hp ho hs := by + have he : (q : M) * E.entry a b = + ∑ j, ((q : M) * (p j : M)) * E.entry a b := by + rw [← Finset.sum_mul, ← Finset.mul_sum, E.partition_coe_sum p hs, mul_one] + rw [he] + apply Submodule.sum_mem + intro j _ + rcases hq j with hj | hj + · have he := congrArg Subtype.val hj + change (q : M) * (p j : M) = 0 at he + rw [he, zero_mul] + exact Submodule.zero_mem _ + · have he := congrArg Subtype.val hj + change (q : M) * (p j : M) = (p j : M) at he + rw [he] + exact E.matrixBlock_entry_mem_span hcomm p hp ho hs j a b + +end MatrixSystem +end HochschildMatrixSystems + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixCommutants.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixCommutants.lean new file mode 100644 index 0000000000000000000000000000000000000000..37d0a7676d0c597d2e3ce4925c69dcee71e08134 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixCommutants.lean @@ -0,0 +1,319 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MatrixSystems +import OAI.Analysis.BoundedHochschild.NormalVectors +import OAI.Analysis.BoundedHochschild.WeakAlgebras + +namespace OAI + +/-! Matrix coefficients, commutant algebras and their preduals. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +variable {M : Type*} [CStarAlgebra M] +variable {n : ℕ} (E : MatrixSystem M n) + + +def commutant : StarSubalgebra ℂ M where + carrier := {x | ∀ i j, Commute x (E.entry i j)} + zero_mem' := fun i j => Commute.zero_left _ + one_mem' := fun i j => Commute.one_left _ + add_mem' := fun hx hy i j => (hx i j).add_left (hy i j) + mul_mem' := fun hx hy i j => (hx i j).mul_left (hy i j) + algebraMap_mem' c := fun i j => Algebra.commutes c (E.entry i j) + star_mem' := fun hx i j => by + have hh := congrArg star (hx j i).eq + change _ * _ = _ * _ + simpa only [star_mul,E.star_entry] using hh.symm + +lemma mem_commutant {x : M} : x ∈ E.commutant ↔ ∀ i j, Commute x (E.entry i j) := Iff.rfl + +instance commutant_closed : IsClosed (E.commutant : Set M) := by + change IsClosed {x : M | ∀ i j, x*E.entry i j = E.entry i j*x} + simp only [Set.ofPred_forall] + exact isClosed_iInter fun i => isClosed_iInter fun j => + isClosed_eq (continuous_id.mul continuous_const) (continuous_const.mul continuous_id) + + +def coefficient (i j : Fin n) (x : M) : M := ∑ k, E.entry k i*x*E.entry j k + +lemma entry_mul_coefficient (a b i j : Fin n) (x : M) : + E.entry a b*E.coefficient i j x=E.entry a i*x*E.entry j b := by + classical + simp only [coefficient,Finset.mul_sum,← mul_assoc,E.entry_mul,ite_mul,zero_mul] + simp + +lemma coefficient_mul_entry (a b i j : Fin n) (x : M) : + E.coefficient i j x*E.entry a b=E.entry a i*x*E.entry j b := by + classical + simp only [coefficient,Finset.sum_mul,mul_assoc,E.entry_mul,mul_ite,mul_zero] + simp [← mul_assoc] + +lemma coefficient_mem (i j : Fin n) (x : M) : E.coefficient i j x ∈ E.commutant := by + intro a b + exact (E.coefficient_mul_entry a b i j x).trans (E.entry_mul_coefficient a b i j x).symm + +lemma reconstruct (x : M) : ∑ i, ∑ j, E.entry i j*E.coefficient i j x=x := by + simp only [E.entry_mul_coefficient,← Finset.mul_sum,← Finset.sum_mul,E.sum_diagonal,one_mul,mul_one] + +lemma factor_of_commutant (A : StarSubalgebra ℂ M) (hA : A=E.commutant) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) : + ∀ b : A, (∀ x : A, Commute b x) → ∃ c : ℂ, b=c • (1 : A) := by + subst A + intro b hb + have hc : ∀ x : M, Commute (b:M) x := by + intro x + rw [← E.reconstruct x] + apply Commute.sum_right + intro i hi + apply Commute.sum_right + intro j hj + exact (b.property i j).mul_right (show Commute (b:M) (E.coefficient i j x) from + congrArg (fun z : E.commutant => (z:M)) (hb ⟨_,E.coefficient_mem i j x⟩).eq) + obtain ⟨c,hc⟩ := hfactor b hc + exact ⟨c,Subtype.ext hc⟩ + +lemma coefficient_star (i j : Fin n) (x : M) : + star (E.coefficient i j x)=E.coefficient j i (star x) := by + simp only [coefficient,star_sum,star_mul,E.star_entry,mul_assoc] + +lemma coefficient_nil (i j : Fin n) : E.coefficient i j (0:M)=0 := by + simp [coefficient] + +lemma coefficient_diagonal_base (i : Fin n) : E.coefficient i i (E.entry i i)=1 := by + simp only [coefficient,E.entry_mul,ite_true,E.sum_diagonal] + +lemma coefficient_corner (i : Fin n) (x : M) : + E.entry i i*E.coefficient i i x*E.entry i i = E.entry i i*x*E.entry i i := by + rw [E.entry_mul_coefficient,mul_assoc,E.entry_mul,ite_eq_left rfl] + +lemma coefficient_mul (i : Fin n) (x y : M) : + E.coefficient i i x*E.coefficient i i y = E.coefficient i i (x*E.entry i i*y) := by + classical + simp only [coefficient,Finset.sum_mul,Finset.mul_sum] + congr 1 + ext j + have hterm (k : Fin n) : + (E.entry k i*x*E.entry i k)*(E.entry j i*y*E.entry i j)= + if k=j then E.entry j i*(x*E.entry i i*y)*E.entry i j else 0 := by + by_cases h : k=j + · subst k + rw [ite_eq_left rfl] + calc + (E.entry j i*x*E.entry i j)*(E.entry j i*y*E.entry i j) = + E.entry j i*x*(E.entry i j*E.entry j i)*y*E.entry i j := by noncomm_ring + _ = _ := by rw [E.entry_mul,ite_eq_left rfl]; noncomm_ring + · rw [ite_eq_right h] + calc + (E.entry k i*x*E.entry i k)*(E.entry j i*y*E.entry i j) = + E.entry k i*x*(E.entry i k*E.entry j i)*y*E.entry i j := by noncomm_ring + _ = 0 := by rw [E.entry_mul,ite_eq_right h,mul_zero,zero_mul,zero_mul] + simp only [hterm] + simp + +lemma diagonal_proj (i : Fin n) : IsStarProjection (E.entry i i) := by + exact ⟨by change E.entry i i*E.entry i i=E.entry i i; rw [E.entry_mul,ite_eq_left rfl], + by change star (E.entry i i)=E.entry i i; exact E.star_entry i i⟩ + +variable [PartialOrder M] [StarOrderedRing M] + +lemma inflate_projection (i : Fin n) {p : M} (hp : IsStarProjection p) + (hle : p ≤ E.entry i i) : IsStarProjection (E.coefficient i i p) := by + refine ⟨?_,?_⟩ + · change E.coefficient i i p*E.coefficient i i p=E.coefficient i i p + rw [E.coefficient_mul,(hp.le_iff_mul_eq_left (E.diagonal_proj i)).mp hle,hp.isIdempotentElem.eq] + · change star (E.coefficient i i p)=E.coefficient i i p + rw [E.coefficient_star,hp.isSelfAdjoint.star_eq] + +lemma coefficient_recover (i : Fin n) {p : M} (hp : IsStarProjection p) + (hle : p ≤ E.entry i i) : + E.entry i i*E.coefficient i i p*E.entry i i=p := by + rw [E.coefficient_corner,(hp.le_iff_mul_eq_right (E.diagonal_proj i)).mp hle, + (hp.le_iff_mul_eq_left (E.diagonal_proj i)).mp hle] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coefficient_of_commutant (i : Fin n) {x : M} (hx : x ∈ E.commutant) : + E.coefficient i i (E.entry i i*x)=x := by + classical + calc + E.coefficient i i (E.entry i i*x) = ∑ k, (E.entry k k)*x := by + apply Finset.sum_congr rfl + intro k hk + calc + E.entry k i*(E.entry i i*x)*E.entry i k = (E.entry k i*E.entry i i)*(x*E.entry i k) := by + noncomm_ring + _ = (E.entry k i*E.entry i i)*(E.entry i k*x) := by rw [(hx i k).eq] + _ = E.entry k k*x := by rw [E.entry_mul,ite_eq_left rfl,← mul_assoc,E.entry_mul,ite_eq_left rfl] + _ = x := by rw [← Finset.sum_mul,E.sum_diagonal,one_mul] + +end MatrixSystem +end HochschildMatrixSystems + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +open BoundedHochschild +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {n : ℕ} (E : MatrixSystem M n) + +lemma commutant_no_minimal (i : Fin n) (hdiff : HochschildDiffuse.NoMinimalProjections M) : + HochschildDiffuse.NoMinimalProjections E.commutant := by + intro q hq hq0 + have hqM : IsStarProjection (q:M) := + ⟨congrArg (fun z : E.commutant => (z:M)) hq.isIdempotentElem.eq, + congrArg (fun z : E.commutant => (z:M)) hq.isSelfAdjoint.star_eq⟩ + let p := E.entry i i*(q:M) + have hp : IsStarProjection p := (E.diagonal_proj i).mul hqM (q.property i i).symm + have hpe : p ≤ E.entry i i := (hp.le_iff_mul_eq_right (E.diagonal_proj i)).mpr + (by dsimp [p]; rw [← mul_assoc,(E.diagonal_proj i).isIdempotentElem.eq]) + have hp0 : p ≠ 0 := by + intro hz + have hh := E.coefficient_of_commutant i q.property + change E.coefficient i i p=(q:M) at hh + rw [hz,E.coefficient_nil] at hh + exact hq0 (Subtype.ext hh.symm) + obtain ⟨r,hr,hrp,hr0,hrne⟩ := hdiff p hp hp0 + have hre := hrp.trans hpe + have hs := E.inflate_projection i hr hre + let s : E.commutant := ⟨E.coefficient i i r,E.coefficient_mem i i r⟩ + have hsN : IsStarProjection s := ⟨Subtype.ext hs.isIdempotentElem.eq, + Subtype.ext hs.isSelfAdjoint.star_eq⟩ + refine ⟨s,hsN,?_,?_,?_⟩ + · apply (hsN.le_iff_mul_eq_left hq).mpr + apply Subtype.ext + change E.coefficient i i r*(q:M)=E.coefficient i i r + rw [← E.coefficient_of_commutant i q.property,E.coefficient_mul] + congr 1 + rw [(hr.le_iff_mul_eq_left (E.diagonal_proj i)).mp hre] + exact (hr.le_iff_mul_eq_left hp).mp hrp + · intro hz + have hzM : E.coefficient i i r=0 := congrArg (fun x : E.commutant => (x:M)) hz + have hh := E.coefficient_recover i hr hre + rw [hzM,mul_zero,zero_mul] at hh + exact hr0 hh.symm + · intro he + have heM : E.coefficient i i r=(q:M) := congrArg (fun x : E.commutant => (x:M)) he + have hh := E.coefficient_recover i hr hre + rw [heM,mul_assoc, (q.property i i).eq,← mul_assoc,(E.diagonal_proj i).isIdempotentElem.eq] at hh + exact hrne hh.symm + +end MatrixSystem + +universe u +namespace MatrixSystem +open BoundedHochschild BoundedHochschild.WeakAlgebra +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable {n : ℕ} (E : MatrixSystem M n) +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hL : ∀ a : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M a)) + (hR : ∀ a : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip a)) + (P : X →L⋆[ℂ] X) (hP : ∀ a z, e.symm (star a) z=star (e.symm a (P z))) + +lemma commutantClosure_eq : WeakAlgebra.closure e E.commutant hL hR P hP=E.commutant := by + apply le_antisymm + · intro x hx i j + have hclosed : IsClosed {f : WeakDual ℂ X | + (weakEquiv e).symm (E.entry i j*weakEquiv e f)= + (weakEquiv e).symm (weakEquiv e f*E.entry i j)} := + isClosed_eq (normal_continuous e _ (hL _)) (normal_continuous e _ (hR _)) + have hs : (linearClosure e E.commutant : Set (WeakDual ℂ X)) ⊆ + {f | (weakEquiv e).symm (E.entry i j*weakEquiv e f)= + (weakEquiv e).symm (weakEquiv e f*E.entry i j)} := by + apply closure_minimal _ hclosed + rintro f ⟨a,ha,rfl⟩ + change (weakEquiv e).symm (E.entry i j*weakEquiv e ((weakEquiv e).symm a)) = + (weakEquiv e).symm (weakEquiv e ((weakEquiv e).symm a)*E.entry i j) + simpa only [LinearEquiv.apply_symm_apply] using congrArg (weakEquiv e).symm (ha i j).eq.symm + have hh := (weakEquiv e).symm.injective (hs hx) + change x*E.entry i j=E.entry i j*x + simpa only [LinearEquiv.apply_symm_apply] using hh.symm + · intro x hx + exact mem_linearClosure e E.commutant hx + +def commutantPredual := X ⧸ WeakSubspace.preannihilator (linearClosure e E.commutant) +instance : NormedAddCommGroup (E.commutantPredual e) := inferInstanceAs + (NormedAddCommGroup (X ⧸ WeakSubspace.preannihilator (linearClosure e E.commutant))) +instance : NormedSpace ℂ (E.commutantPredual e) := inferInstanceAs + (NormedSpace ℂ (X ⧸ WeakSubspace.preannihilator (linearClosure e E.commutant))) +instance [CompleteSpace X] : CompleteSpace (E.commutantPredual e) := inferInstanceAs + (CompleteSpace (X ⧸ WeakSubspace.preannihilator (linearClosure e E.commutant))) + +def subalgebraIsoOfEq (A B : StarSubalgebra ℂ M) (h : A=B) : A ≃ₗᵢ[ℂ] B := by + subst B + exact LinearIsometryEquiv.refl ℂ A + +def commutantPredualEquiv : StrongDual ℂ (E.commutantPredual e) ≃ₗᵢ⋆[ℂ] E.commutant := + (predualEquiv e E.commutant hL hR P hP).trans + (subalgebraIsoOfEq _ _ (E.commutantClosure_eq e hL hR P hP)) + +lemma subalgebraIsoOfEq_coe (A B : StarSubalgebra ℂ M) (h : A=B) (a : A) : + (subalgebraIsoOfEq A B h a : M)=(a:M) := by + subst B + rfl + +lemma subalgebraIsoOfEq_symm_coe (A B : StarSubalgebra ℂ M) (h : A=B) (a : B) : + ((subalgebraIsoOfEq A B h).symm a : M)=(a:M) := by + subst B + rfl + +lemma commutantPredualEquiv_symm_mk (a : E.commutant) (z : X) : + (E.commutantPredualEquiv e hL hR P hP).symm a (Submodule.Quotient.mk z)= + e.symm (a:M) z := by + change (predualEquiv e E.commutant hL hR P hP).symm + ((subalgebraIsoOfEq _ _ (E.commutantClosure_eq e hL hR P hP)).symm a) + (Submodule.Quotient.mk z)=_ + rw [predualEquiv_symm_apply_mk,subalgebraIsoOfEq_symm_coe] + +variable [PartialOrder M] + +def commutantTrace (τ : M →ₚ[ℂ] ℂ) : E.commutant →ₚ[ℂ] ℂ where + toLinearMap := τ.toLinearMap.comp E.commutant.subtype.toLinearMap + monotone' := fun _ _ h => τ.monotone h + +lemma commutantTrace_normal (τ : M →ₚ[ℂ] ℂ) (hτ : TraceInPredual e τ) : + TraceInPredual (E.commutantPredualEquiv e hL hR P hP) (E.commutantTrace τ) := by + obtain ⟨z,hz⟩ := hτ + refine ⟨Submodule.Quotient.mk z,fun a => ?_⟩ + rw [E.commutantPredualEquiv_symm_mk] + exact hz a.val + +lemma commutantTrace_one (τ : M →ₚ[ℂ] ℂ) (h1 : τ 1=1) : E.commutantTrace τ 1=1 := h1 +lemma commutantTrace_tracial (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (a b : E.commutant) : E.commutantTrace τ (a*b)=E.commutantTrace τ (b*a) := htr a.val b.val +lemma commutantTrace_faithful (τ : M →ₚ[ℂ] ℂ) (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (a : E.commutant) (ha : E.commutantTrace τ (star a*a)=0) : a=0 := + Subtype.ext (hfaith a.val ha) + +end MatrixSystem +end HochschildMatrixSystems +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixCornerCommutant.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixCornerCommutant.lean new file mode 100644 index 0000000000000000000000000000000000000000..ea527098e1b1b5a9f4b11abdf6e7f4a74042d2d2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixCornerCommutant.lean @@ -0,0 +1,75 @@ +import OAI.Analysis.BoundedHochschild.PartialIsoCornerEquivalence +import OAI.Analysis.BoundedHochschild.TracialDecomposition + +namespace OAI + +/-! Explicit identification of a matrix diagonal corner with its commutant. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildMatrixSystems HochschildComparison HochschildCorners + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {n : ℕ} (E : MatrixSystem M n) (i : Fin n) + +/-- The matrix coefficient map identifies a diagonal corner with the full +matrix commutant. Its inverse is multiplication by that diagonal projection. -/ +def matrixCornerCommutantEquiv : + PopaCorner.algebra (E.diagonal_proj i) ≃⋆ₐ[ℂ] E.commutant where + toFun a := ⟨E.coefficient i i a, E.coefficient_mem i i a⟩ + invFun b := ⟨E.entry i i * (b : M), by + constructor + · rw [← mul_assoc, (E.diagonal_proj i).isIdempotentElem.eq] + · rw [mul_assoc, (b.property i i).eq, ← mul_assoc, + (E.diagonal_proj i).isIdempotentElem.eq]⟩ + left_inv a := by + apply Subtype.ext + change E.entry i i * E.coefficient i i (a : M) = (a : M) + have hc := E.coefficient_corner i (a : M) + rw [a.property.1, a.property.2] at hc + calc + _ = E.entry i i * E.coefficient i i (a : M) * E.entry i i := by + rw [mul_assoc, (E.coefficient_mem i i (a : M) i i).eq, + ← mul_assoc, (E.diagonal_proj i).isIdempotentElem.eq] + _ = (a : M) := hc + right_inv b := Subtype.ext (E.coefficient_of_commutant i b.property) + map_mul' a b := by + apply Subtype.ext + change E.coefficient i i ((a : M) * (b : M)) = + E.coefficient i i (a : M) * E.coefficient i i (b : M) + rw [E.coefficient_mul, a.property.2] + map_add' a b := by + apply Subtype.ext + change E.coefficient i i ((a : M) + (b : M)) = + E.coefficient i i (a : M) + E.coefficient i i (b : M) + simp only [MatrixSystem.coefficient, mul_add, add_mul, Finset.sum_add_distrib] + map_smul' z a := by + apply Subtype.ext + change E.coefficient i i (z • (a : M)) = z • E.coefficient i i (a : M) + simp only [MatrixSystem.coefficient, mul_smul_comm, smul_mul_assoc, Finset.smul_sum] + map_star' a := Subtype.ext (E.coefficient_star i i (a : M)).symm + +/-- An isometry identifies the whole algebra with its range corner. -/ +def isometryCornerEquiv (v : PartialIso M) (hi : v.initial = 1) : + M ≃⋆ₐ[ℂ] PopaCorner.algebra v.final_proj := by + let hunit : M ≃⋆ₐ[ℂ] PopaCorner.algebra v.initial_proj := + { toFun := fun a => ⟨a, by + change v.initial * a = a ∧ a * v.initial = a + rw [hi, one_mul, mul_one] + exact ⟨rfl, rfl⟩⟩ + invFun := Subtype.val + left_inv := fun _ => rfl + right_inv := fun _ => Subtype.ext rfl + map_mul' := fun _ _ => rfl + map_add' := fun _ _ => rfl + map_smul' := fun _ _ => rfl + map_star' := fun _ => rfl } + exact hunit.trans (partialIsoCornerEquiv v) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixDilation.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixDilation.lean new file mode 100644 index 0000000000000000000000000000000000000000..1b3b35e63ca622d2ccb35c797bf4bf8bde4dc2c2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixDilation.lean @@ -0,0 +1,244 @@ +import Mathlib + +namespace OAI + +/-! Matrix dilations, tracial matrix algebras and bounded linear maps. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +namespace HochschildMatrixDilation +noncomputable section +open scoped Matrix ComplexOrder +open Complex +variable {A : Type*} [CStarAlgebra A] + +abbrev Mat (A : Type*) := CStarMatrix (Fin 2) (Fin 2) A + +def diag (a b : A) : Mat A := CStarMatrix.ofMatrix !![a,0;0,b] + +def offdiag (a b : A) : Mat A := CStarMatrix.ofMatrix !![0,a;b,0] + +@[simp] lemma diag_zero_zero : diag (0:A) 0 = 0 := by + ext i j; fin_cases i <;> fin_cases j <;> rfl +@[simp] lemma diag_one_one : diag (1:A) 1 = 1 := by + ext i j; fin_cases i <;> fin_cases j <;> rfl +@[simp] lemma diag_add (a b c d : A) : diag (a+c) (b+d) = diag a b + diag c d := by + ext i j; fin_cases i <;> fin_cases j <;> simp [diag] +@[simp] lemma diag_smul (z : ℂ) (a b : A) : diag (z • a) (z • b) = z • diag a b := by + ext i j; fin_cases i <;> fin_cases j <;> simp [diag] +@[simp] lemma diag_mul (a b c d : A) : diag a b * diag c d = diag (a*c) (b*d) := by + ext i j; fin_cases i <;> fin_cases j <;> + simp [diag, CStarMatrix.mul_apply, Fin.sum_univ_two] +@[simp] lemma star_diag (a b : A) : star (diag a b) = diag (star a) (star b) := by + ext i j; fin_cases i <;> fin_cases j <;> + simp [diag, CStarMatrix.star_eq_conjTranspose] +@[simp] lemma star_offdiag (a b : A) : star (offdiag a b) = offdiag (star b) (star a) := by + ext i j; fin_cases i <;> fin_cases j <;> + simp [offdiag, CStarMatrix.star_eq_conjTranspose] +@[simp] lemma offdiag_mul (a b c d : A) : + offdiag a b * offdiag c d = diag (a*d) (b*c) := by + ext i j; fin_cases i <;> fin_cases j <;> + simp [diag, offdiag, CStarMatrix.mul_apply, Fin.sum_univ_two] + + +def diagHom : A × A →⋆ₐ[ℂ] Mat A where + toFun a := diag a.1 a.2 + map_one' := diag_one_one + map_mul' a b := (diag_mul _ _ _ _).symm + map_zero' := diag_zero_zero + map_add' a b := diag_add _ _ _ _ + commutes' z := by + ext i j; fin_cases i <;> fin_cases j <;> + rfl + map_star' a := (star_diag _ _).symm + +variable [PartialOrder A] [StarOrderedRing A] + +lemma norm_diag_le (a b : A) : ‖diag a b‖ ≤ max ‖a‖ ‖b‖ := by + exact NonUnitalStarAlgHom.norm_apply_le diagHom (a,b) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma offdiag_selfAdjoint (a : A) : IsSelfAdjoint (offdiag a (star a)) := by + change star (offdiag a (star a)) = _ + simp + +lemma offdiag_norm_le_one (a : A) (ha : ‖a‖ ≤ 1) : ‖offdiag a (star a)‖ ≤ 1 := by + have hsq : ‖offdiag a (star a)‖^2 ≤ 1 := by + rw [← (offdiag_selfAdjoint a).norm_mul_self, offdiag_mul] + refine (norm_diag_le _ _).trans (max_le ?_ ?_) + · calc + ‖a * star a‖ ≤ ‖a‖ * ‖star a‖ := norm_mul_le _ _ + _ ≤ 1 := by rw [norm_star]; nlinarith [norm_nonneg a] + · calc + ‖star a * a‖ ≤ ‖star a‖ * ‖a‖ := norm_mul_le _ _ + _ ≤ 1 := by rw [norm_star]; nlinarith [norm_nonneg a] + exact (sq_le_one_iff₀ (norm_nonneg _)).mp hsq + +def flipUnitary : unitary (Mat A) := + ⟨offdiag 1 1, by rw [Unitary.mem_iff]; simp⟩ + + + +def dilation (a : A) (ha : ‖a‖ ≤ 1) : unitary (Mat A) := + (selfAdjoint.unitarySelfAddISMul + ⟨offdiag a (star a), offdiag_selfAdjoint a⟩ (offdiag_norm_le_one a ha)) * flipUnitary + +local instance : NonUnitalContinuousFunctionalCalculus ℝ (Mat A) IsSelfAdjoint := + IsSelfAdjoint.instNonUnitalContinuousFunctionalCalculus + +local instance : NonnegSpectrumClass ℝ (Mat A) := + CStarAlgebra.instNonnegSpectrumClass + +lemma dilation_sub_diag (a : A) (ha : ‖a‖ ≤ 1) : + (dilation a ha : Mat A) - diag a (star a) = + Complex.I • (CFC.sqrt (1 - offdiag a (star a) ^ 2) * offdiag 1 1) := by + change (offdiag a (star a) + Complex.I • CFC.sqrt (1 - offdiag a (star a)^2)) * + offdiag 1 1 - diag a (star a) = _ + rw [add_mul, smul_mul_assoc, offdiag_mul, mul_one, mul_one] + abel + +lemma diagEntry_nonneg (M : Mat A) (hM : 0 ≤ M) (i : Fin 2) : 0 ≤ M i i := by + have hs := CFC.sqrt_nonneg M + have he : M = star (CFC.sqrt M) * CFC.sqrt M := by + rw [hs.isSelfAdjoint.star_eq, CFC.sqrt_mul_sqrt_self M hM] + rw [he, CStarMatrix.mul_apply] + simp only [CStarMatrix.star_apply] + exact Finset.sum_nonneg fun j _ => star_mul_self_nonneg _ + +def matrixTraceLinear (τ : A →ₚ[ℂ] ℂ) : Mat A →ₗ[ℂ] ℂ where + toFun M := (τ (M 0 0) + τ (M 1 1)) / 2 + map_add' M N := by simp only [CStarMatrix.add_apply, map_add]; ring + map_smul' z M := by + simp only [CStarMatrix.smul_apply, map_smul, smul_eq_mul, RingHom.id_apply] + ring + + +def matrixTrace (τ : A →ₚ[ℂ] ℂ) : Mat A →ₚ[ℂ] ℂ := + PositiveLinearMap.mk₀ (matrixTraceLinear τ) (fun M hM => + div_nonneg (add_nonneg (τ.map_nonneg (diagEntry_nonneg M hM 0)) + (τ.map_nonneg (diagEntry_nonneg M hM 1))) (by norm_num)) + +lemma matrixTrace_apply (τ : A →ₚ[ℂ] ℂ) (M : Mat A) : + matrixTrace τ M = (τ (M 0 0) + τ (M 1 1)) / 2 := rfl + +@[simp] lemma matrixTrace_diag (τ : A →ₚ[ℂ] ℂ) (a b : A) : + matrixTrace τ (diag a b) = (τ a + τ b)/2 := rfl + +lemma matrixTrace_one (τ : A →ₚ[ℂ] ℂ) (hτ : τ 1 = 1) : matrixTrace τ 1 = 1 := by + rw [← diag_one_one, matrixTrace_diag, hτ] + ring + +lemma matrixTrace_tracial (τ : A →ₚ[ℂ] ℂ) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) (M N : Mat A) : + matrixTrace τ (M*N) = matrixTrace τ (N*M) := by + simp only [matrixTrace_apply, CStarMatrix.mul_apply, Fin.sum_univ_two, map_add] + rw [htr (M 0 0), htr (M 0 1), htr (M 1 0), htr (M 1 1)] + ring + +lemma matrixTrace_norm_sq (τ : A →ₚ[ℂ] ℂ) (M : Mat A) : + ‖(matrixTrace τ).toPreGNS M‖^2 = + (‖τ.toPreGNS (M 0 0)‖^2 + ‖τ.toPreGNS (M 1 0)‖^2 + + ‖τ.toPreGNS (M 0 1)‖^2 + ‖τ.toPreGNS (M 1 1)‖^2) / 2 := by + apply Complex.ofReal_injective + push_cast + simp only [PositiveLinearMap.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS, + matrixTrace_apply, CStarMatrix.mul_apply, Fin.sum_univ_two, CStarMatrix.star_apply, + map_add] + ring + +lemma matrixTrace_faithful (τ : A →ₚ[ℂ] ℂ) + (hf : ∀ a : A, τ (star a*a) = 0 → a = 0) (M : Mat A) + (hM : matrixTrace τ (star M*M) = 0) : M = 0 := by + have hm : ‖(matrixTrace τ).toPreGNS M‖^2 = 0 := by + apply Complex.ofReal_injective + simpa only [Complex.ofReal_pow, Complex.ofReal_zero, + PositiveLinearMap.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS] using hM + rw [matrixTrace_norm_sq] at hm + have hn (a : A) (h : ‖τ.toPreGNS a‖^2 = 0) : a = 0 := by + apply hf + simpa only [Complex.ofReal_pow, Complex.ofReal_zero, + PositiveLinearMap.preGNS_norm_sq, PositiveLinearMap.ofPreGNS_toPreGNS] using + congrArg (fun r : ℝ => (r:ℂ)) h + have h00 := sq_nonneg ‖τ.toPreGNS (M 0 0)‖ + have h10 := sq_nonneg ‖τ.toPreGNS (M 1 0)‖ + have h01 := sq_nonneg ‖τ.toPreGNS (M 0 1)‖ + have h11 := sq_nonneg ‖τ.toPreGNS (M 1 1)‖ + have hz00 : M 0 0 = 0 := hn _ (by linarith) + have hz10 : M 1 0 = 0 := hn _ (by linarith) + have hz01 : M 0 1 = 0 := hn _ (by linarith) + have hz11 : M 1 1 = 0 := hn _ (by linarith) + ext i j + fin_cases i <;> fin_cases j + · exact hz00 + · exact hz01 + · exact hz10 + · exact hz11 + +open scoped Matrix.Norms.Elementwise in + +def matrixMap (R : A →L[ℂ] A) : Mat A →L[ℂ] Mat A where + toLinearMap := CStarMatrix.mapₗ R.toLinearMap + cont := by + let e := CStarMatrix.ofMatrixL (m:=Fin 2) (n:=Fin 2) (A:=A) + have hc : Continuous (fun M : Mat A => fun i j => R (e.symm M i j)) := by + apply continuous_pi; intro i + apply continuous_pi; intro j + exact R.continuous.comp ((continuous_apply j).comp ((continuous_apply i).comp e.symm.continuous)) + exact e.continuous.comp hc + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma matrixMap_apply (R : A →L[ℂ] A) (M : Mat A) (i j : Fin 2) : + matrixMap R M i j = R (M i j) := rfl + +omit [PartialOrder A] [StarOrderedRing A] in +@[simp] lemma matrixMap_diag (R : A →L[ℂ] A) (a b : A) : + matrixMap R (diag a b) = diag (R a) (R b) := by + ext i j; fin_cases i <;> fin_cases j <;> simp [diag] + +lemma dilation_defect_nonneg (a : A) (ha : ‖a‖ ≤ 1) : + 0 ≤ (1 - offdiag a (star a)^2 : Mat A) := by + have hself := offdiag_selfAdjoint a + have hnon : 0 ≤ (offdiag a (star a) : Mat A)^2 := by + simpa only [hself.star_eq, pow_two] using (star_mul_self_nonneg (offdiag a (star a))) + rw [sub_nonneg, ← CStarAlgebra.norm_le_one_iff_of_nonneg _ hnon, + pow_two, hself.norm_mul_self] + exact (sq_le_one_iff₀ (norm_nonneg _)).mpr (offdiag_norm_le_one a ha) + +lemma dilation_error_sq (τ : A →ₚ[ℂ] ℂ) + (htr : ∀ a b : A, τ (a*b) = τ (b*a)) (a : A) (ha : ‖a‖ ≤ 1) : + ‖(matrixTrace τ).toPreGNS ((dilation a ha : Mat A) - diag a (star a))‖^2 = + (τ (1-star a*a)).re := by + apply Complex.ofReal_injective + rw [Complex.ofReal_pow, PositiveLinearMap.preGNS_norm_sq] + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, dilation_sub_diag, + star_smul, star_mul, smul_mul_smul, Complex.star_def, Complex.conj_I, neg_mul, + Complex.I_mul_I, neg_neg, one_smul] + let d : Mat A := CFC.sqrt (1 - offdiag a (star a)^2) + have hd : star d = d := (CFC.sqrt_nonneg _).isSelfAdjoint.star_eq + change matrixTrace τ ((star (offdiag 1 1) * star d) * (d * offdiag 1 1)) = _ + rw [mul_assoc, ← mul_assoc (star d), hd, CFC.sqrt_mul_sqrt_self _ (dilation_defect_nonneg a ha)] + rw [← mul_assoc, matrixTrace_tracial τ htr, ← mul_assoc, star_offdiag, + star_one, offdiag_mul, one_mul, diag_one_one, one_mul] + rw [pow_two, offdiag_mul] + have he : (1 : Mat A) - diag (a*star a) (star a*a) = + diag (1-a*star a) (1-star a*a) := by + ext i j; fin_cases i <;> fin_cases j <;> simp [diag] + rw [he, matrixTrace_diag] + have ht : τ (1-a*star a) = τ (1-star a*a) := by simp only [map_sub, htr a (star a)] + rw [ht] + have hnon : 0 ≤ 1-star a*a := by + rw [sub_nonneg, ← CStarAlgebra.norm_le_one_iff_of_nonneg _ (star_mul_self_nonneg a), + CStarRing.norm_star_mul_self] + nlinarith [norm_nonneg a] + have hre : (τ (1-star a*a)).im = 0 := (Complex.nonneg_iff.mp (τ.map_nonneg hnon)).2.symm + + rw [← Complex.re_add_im (τ (1-star a*a)), hre] + simp + +end +end HochschildMatrixDilation +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixDisplacement.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixDisplacement.lean new file mode 100644 index 0000000000000000000000000000000000000000..6c356df97b906150aa9757c3331c384129316e5d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixDisplacement.lean @@ -0,0 +1,445 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.MatrixSystems +import OAI.Analysis.BoundedHochschild.MatrixCommutants + +namespace OAI + +/-! Projection displacement and energy-decreasing matrix extensions. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildQuantization +open BoundedHochschild HochschildRigidity HochschildSakai +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +include e in +lemma positive_contraction_bound_of_projections + {V : Type*} [SeminormedAddCommGroup V] [NormedSpace ℂ V] + (F : M →ₗ[ℂ] V) (B K : ℝ) (hB : 0 ≤ B) (hK : 0 ≤ K) + (hbound : ∀ a : M, ‖F a‖ ≤ B*‖a‖) + (hproj : ∀ p : M, IsStarProjection p → ‖F p‖ ≤ K) + (a : M) (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : ‖F a‖ ≤ K := by + have hb : ∀ n : ℕ, ∀ a : M, 0 ≤ a → a ≤ 1 → + ‖F a‖ ≤ K+(1/2:ℝ)^n*B := by + intro n + induction n with + | zero => + intro a ha0 ha1 + have hn : ‖a‖ ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg _ ha0).mpr ha1 + have hh := (hbound a).trans (mul_le_of_le_one_right hB hn) + simpa only [pow_zero,one_mul] using hh.trans (le_add_of_nonneg_left hK) + | succ n ih => + intro a ha0 ha1 + obtain ⟨p,hp,h0,h1⟩ := exists_dyadic_projection e a ha0 ha1 + have hh := ih ((2:ℝ) • a-p) h0 h1 + have he : (2:ℝ) • F a=F ((2:ℝ) • a-p)+F p := by + simp only [map_sub,← Complex.coe_smul,map_smul,sub_add_cancel] + have ht := norm_add_le (F ((2:ℝ) • a-p)) (F p) + rw [← he,norm_smul,Real.norm_eq_abs,abs_of_pos (by norm_num : (0:ℝ)<2)] at ht + rw [pow_succ] + nlinarith [hproj p hp] + have ht : Tendsto (fun n : ℕ => K+(1/2:ℝ)^n*B) atTop (𝓝 K) := by + convert tendsto_const_nhds.add + ((tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : (0:ℝ) ≤ 1/2) + (by norm_num : (1/2:ℝ)<1)).mul_const B) using 1 + simp + exact ge_of_tendsto ht (Eventually.of_forall fun n => hb n a ha0 ha1) + +include e in +lemma contraction_bound_of_projections + {V : Type*} [SeminormedAddCommGroup V] [NormedSpace ℂ V] + (F : M →ₗ[ℂ] V) (B K : ℝ) (hB : 0 ≤ B) (hK : 0 ≤ K) + (hbound : ∀ a : M, ‖F a‖ ≤ B*‖a‖) + (hproj : ∀ p : M, IsStarProjection p → ‖F p‖ ≤ K) + (a : M) (ha : ‖a‖ ≤ 1) : ‖F a‖ ≤ 4*K := by + obtain ⟨x,hx0,hxn,he⟩ := CStarAlgebra.exists_sum_four_nonneg a + have hb (i : Fin 4) : ‖F (x i)‖ ≤ K := + positive_contraction_bound_of_projections e F B K hB hK hbound hproj (x i) + (hx0 i) ((CStarAlgebra.norm_le_one_iff_of_nonneg _ (hx0 i)).mp ((hxn i).trans ha)) + rw [he,map_sum] + calc + ‖∑ i : Fin 4, F (Complex.I^(i:ℕ) • x i)‖ ≤ + ∑ i : Fin 4, ‖F (Complex.I^(i:ℕ) • x i)‖ := norm_sum_le _ _ + _ ≤ ∑ _i : Fin 4, K := by + apply Finset.sum_le_sum + intro i hi + simpa only [map_smul,norm_smul,norm_pow,Complex.norm_I,one_pow,one_mul] using hb i + _ = 4*K := by simp + +variable (τ : M →ₚ[ℂ] ℂ) + +def commutatorGNS (a : M) : M →ₗ[ℂ] τ.PreGNS := + τ.toPreGNS.toLinearMap.comp + (((ContinuousLinearMap.mul ℂ M).flip a - ContinuousLinearMap.mul ℂ M a).toLinearMap) + +omit [StarOrderedRing M] in +lemma commutatorGNS_apply (a x : M) : commutatorGNS τ a x=τ.toPreGNS (x*a-a*x) := rfl + +lemma commutatorGNS_bound (h1 : τ 1=1) (a x : M) : + ‖commutatorGNS τ a x‖ ≤ (2*‖a‖)*‖x‖ := by + change ‖τ.toPreGNS (x*a-a*x)‖ ≤ _ + calc + _ ≤ ‖x*a-a*x‖ := preGNS_norm_le τ h1 _ + _ ≤ ‖x*a‖+‖a*x‖ := norm_sub_le _ _ + _ ≤ ‖x‖*‖a‖+‖a‖*‖x‖ := add_le_add (norm_mul_le _ _) (norm_mul_le _ _) + _ = _ := by ring + +include e in +lemma norm_sub_trace_le_of_projection_commutators + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (a : M) (K : ℝ) (hK : 0 ≤ K) + (hp : ∀ p : M, IsStarProjection p → ‖τ.toPreGNS (p*a-a*p)‖ ≤ K) : + ‖τ.toPreGNS (a-(τ a) • (1:M))‖ ≤ 4*K := by + apply HochschildDixmier.norm_sub_trace_le_of_conjugations e τ (mul_hasPreadjoint e) + hτ h1 htr hfaith hfactor a (4*K) + intro u + have : Nontrivial M := ⟨⟨1,0,by + intro hz + have hh : (1:ℂ)=0 := h1.symm.trans ((congrArg τ hz).trans (map_zero τ)) + exact one_ne_zero hh⟩⟩ + have hnu : ‖(u:M)‖ ≤ 1 := (CStarRing.norm_coe_unitary u).le + have hh := contraction_bound_of_projections e (commutatorGNS τ a) (2*‖a‖) K + (by positivity) hK (commutatorGNS_bound τ h1 a) hp (u:M) hnu + have he : HochschildDixmier.conjugate u a-a=((u:M)*a-a*(u:M))*star (u:M) := by + simp only [HochschildDixmier.conjugate_apply,sub_mul,mul_assoc,Unitary.mul_star_self_of_mem u.prop, + mul_one] + rw [he,show star (u:M)=((star u:unitary M):M) from rfl, + preGNS_norm_unitary_right τ htr] + exact hh + +include e in + + +theorem exists_projection_displacement + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (a : M) (ha : 0<‖τ.toPreGNS (a-(τ a) • (1:M))‖) : + ∃ p : M, IsStarProjection p ∧ + ‖τ.toPreGNS (a-(τ a) • (1:M))‖/8 < ‖τ.toPreGNS (p*a-a*p)‖ := by + by_contra hn + push Not at hn + have hh := norm_sub_trace_le_of_projection_commutators e τ hτ h1 htr hfaith hfactor a + (‖τ.toPreGNS (a-(τ a) • (1:M))‖/8) (by positivity) hn + linarith + +end HochschildQuantization + + + + + +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {n m : ℕ} (E : MatrixSystem M n) (F : MatrixSystem E.commutant m) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coe_entry_star (c d : Fin m) : star (F.entry c d : M) = (F.entry d c : M) := by + change ((star (F.entry c d) : E.commutant) : M) = _ + rw [F.star_entry] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coe_entry_mul (a b c d : Fin m) : + (F.entry a b : M)*(F.entry c d : M) = if b=c then (F.entry a d : M) else 0 := by + change ((F.entry a b * F.entry c d : E.commutant) : M) = _ + rw [F.entry_mul] + split <;> rfl + +omit [PartialOrder M] [StarOrderedRing M] in +lemma coe_sum_diagonal : ∑ c : Fin m, (F.entry c c : M) = 1 := by + have h := congrArg (fun z : E.commutant => (z : M)) F.sum_diagonal + simpa only [← E.commutant.subtype_apply, map_sum, map_one] using h + + + +def extend : MatrixSystem M (n*m) where + entry i j := E.entry (finProdFinEquiv.symm i).1 (finProdFinEquiv.symm j).1 * + (F.entry (finProdFinEquiv.symm i).2 (finProdFinEquiv.symm j).2 : M) + star_entry i j := by + simp only [star_mul,E.star_entry,E.coe_entry_star F] + exact ((F.entry _ _).property _ _).eq + entry_mul i j k l := by + classical + have hterm (a b c d : Fin n × Fin m) : + (E.entry a.1 b.1*(F.entry a.2 b.2 : M))*(E.entry c.1 d.1*(F.entry c.2 d.2 : M))= + if b=c then E.entry a.1 d.1*(F.entry a.2 d.2 : M) else 0 := by + calc + _ = (E.entry a.1 b.1*E.entry c.1 d.1)*((F.entry a.2 b.2 : M)*(F.entry c.2 d.2 : M)) := by + rw [mul_assoc,← mul_assoc (F.entry a.2 b.2 : M),((F.entry a.2 b.2).property c.1 d.1).eq] + noncomm_ring + _ = _ := by + rw [E.entry_mul,E.coe_entry_mul F] + by_cases h1 : b.1=c.1 <;> by_cases h2 : b.2=c.2 <;> + simp [h1,h2,Prod.ext_iff] + convert hterm (finProdFinEquiv.symm i) (finProdFinEquiv.symm j) + (finProdFinEquiv.symm k) (finProdFinEquiv.symm l) using 1 + simp only [Equiv.apply_eq_iff_eq] + sum_diagonal := by + rw [← Equiv.sum_comp finProdFinEquiv] + simp only [Equiv.symm_apply_apply,Fintype.sum_prod_type] + simp only [← Finset.mul_sum,E.coe_sum_diagonal F,mul_one] + exact E.sum_diagonal + +omit [PartialOrder M] [StarOrderedRing M] in +lemma extend_entry (a b : Fin n) (c d : Fin m) : + (E.extend F).entry (finProdFinEquiv (a,c)) (finProdFinEquiv (b,d))= + E.entry a b*(F.entry c d : M) := by simp only [extend,Equiv.symm_apply_apply] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma entry_sum_extension (a b : Fin n) : + ∑ c : Fin m, (E.extend F).entry (finProdFinEquiv (a,c)) (finProdFinEquiv (b,c))=E.entry a b := by + simp only [E.extend_entry,← Finset.mul_sum,E.coe_sum_diagonal F,mul_one] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma commutant_entry_sum_extension (c d : Fin m) : + ∑ a : Fin n, (E.extend F).entry (finProdFinEquiv (a,c)) (finProdFinEquiv (a,d))=(F.entry c d : M) := by + simp only [E.extend_entry,← Finset.sum_mul,E.sum_diagonal,one_mul] + + +omit [PartialOrder M] [StarOrderedRing M] in +lemma extension_expectation_commutes (x : M) : + (∀ a b, Commute ((E.extend F).expectation x) (E.entry a b)) ∧ + (∀ c d, Commute ((E.extend F).expectation x) (F.entry c d : M)) := by + constructor + · intro a b + rw [← E.entry_sum_extension F a b] + apply Commute.sum_right + intro c hc + exact (E.extend F).commute_expectation x _ _ + · intro c d + rw [← E.commutant_entry_sum_extension F c d] + apply Commute.sum_right + intro a ha + exact (E.extend F).commute_expectation x _ _ + +omit [StarOrderedRing M] in +lemma extension_residual_orthogonal (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (hm : m ≠ 0) (x : M) : + τ (star (E.expectation x-(E.extend F).expectation x)*(E.extend F).expectation x)=0 := by + have ht := (E.extend F).trace_residual_expectation τ htr (Nat.mul_ne_zero hn hm) x + rw [star_sub,sub_mul,map_sub] at ht ⊢ + rw [← E.expectation_star,E.trace_adjoint τ htr, + E.expectation_eq_self hn _ (E.extension_expectation_commutes F x).1] + exact ht + +lemma extension_pythagoras (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (hm : m ≠ 0) (x : M) : + ‖τ.toPreGNS (E.expectation x)‖^2 = ‖τ.toPreGNS ((E.extend F).expectation x)‖^2 + + ‖τ.toPreGNS (E.expectation x-(E.extend F).expectation x)‖^2 := by + have hh := E.extension_residual_orthogonal F τ htr hn hm x + have hh' : τ (star ((E.extend F).expectation x)* + (E.expectation x-(E.extend F).expectation x))=0 := by + have hs := congrArg star hh + rw [← map_star τ] at hs + simpa only [star_mul,star_star,star_zero] using hs + rw [norm_sq,norm_sq,norm_sq] + have he : τ (star (E.expectation x)*E.expectation x)= + τ (star ((E.extend F).expectation x)*(E.extend F).expectation x)+ + τ (star (E.expectation x-(E.extend F).expectation x)* + (E.expectation x-(E.extend F).expectation x)) := by + have hdecomp : star (E.expectation x)*E.expectation x= + star ((E.extend F).expectation x)*(E.extend F).expectation x+ + star (E.expectation x-(E.extend F).expectation x)* + (E.expectation x-(E.extend F).expectation x)+ + (star (E.expectation x-(E.extend F).expectation x)*(E.extend F).expectation x+ + star ((E.extend F).expectation x)*(E.expectation x-(E.extend F).expectation x)) := by + simp only [star_sub] + noncomm_ring + simp only [hdecomp,map_add,hh,hh',add_zero] + rw [he,Complex.add_re] + +lemma extension_gns_contract (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (hm : m ≠ 0) (x : M) : + ‖τ.toPreGNS ((E.extend F).expectation x)‖ ≤ ‖τ.toPreGNS (E.expectation x)‖ := by + have hh := E.extension_pythagoras F τ htr hn hm x + nlinarith [sq_nonneg ‖τ.toPreGNS (E.expectation x-(E.extend F).expectation x)‖, + norm_nonneg (τ.toPreGNS (E.expectation x)), + norm_nonneg (τ.toPreGNS ((E.extend F).expectation x))] + +end MatrixSystem +end HochschildMatrixSystems + + + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildQuantization +open BoundedHochschild HochschildRigidity HochschildSakai HochschildMatrixSystems +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +lemma commutator_gns_le (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (a x : M) : + ‖τ.toPreGNS (x*a-a*x)‖ ≤ 2*‖a‖*‖τ.toPreGNS x‖ := by + calc + _ ≤ ‖τ.toPreGNS (x*a)‖+‖τ.toPreGNS (a*x)‖ := by + rw [map_sub]; exact norm_sub_le _ _ + _ ≤ ‖a‖*‖τ.toPreGNS x‖+‖a‖*‖τ.toPreGNS x‖ := + add_le_add (preGNS_norm_mul_right_le τ htr _ _) (preGNS_norm_mul_le τ _ _) + _ = _ := by ring + +include e in +lemma exists_matrix_displacement + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) + (a : M) (ha : 0<‖τ.toPreGNS (a-(τ a) • (1:M))‖) : + ∃ (m : ℕ) (F : MatrixSystem M m) (s : Finset (Fin m)), 0 < m ∧ + IsStarProjection (∑ i ∈ s,F.entry i i) ∧ + ‖τ.toPreGNS (a-(τ a) • (1:M))‖/16 < + ‖τ.toPreGNS ((∑ i ∈ s,F.entry i i)*a-a*(∑ i ∈ s,F.entry i i))‖ := by + obtain ⟨p,hp,hpdisp⟩ := exists_projection_displacement e τ hτ h1 htr hfaith hfactor a ha + let t := ‖τ.toPreGNS (a-(τ a) • (1:M))‖ + let ε : ℝ := t/(64*(‖a‖+1)) + have hε : 0<ε := div_pos ha (by positivity) + obtain ⟨m,F,s,hm,hq,hqp,happrox⟩ := exists_matrix_projection_approx e τ hτ htr hfaith + hdiff h1 hfactor hp hε + refine ⟨m,F,s,hm,hq,?_⟩ + let q := ∑ i ∈ s,F.entry i i + have herr : ‖τ.toPreGNS (p*a-a*p)‖ ≤ ‖τ.toPreGNS (q*a-a*q)‖+2*‖a‖*ε := by + calc + _ = ‖τ.toPreGNS (q*a-a*q)+τ.toPreGNS ((p-q)*a-a*(p-q))‖ := by + rw [← map_add]; congr 2; noncomm_ring + _ ≤ ‖τ.toPreGNS (q*a-a*q)‖+‖τ.toPreGNS ((p-q)*a-a*(p-q))‖ := norm_add_le _ _ + _ ≤ ‖τ.toPreGNS (q*a-a*q)‖+2*‖a‖*ε := + add_le_add_right ((commutator_gns_le τ htr a (p-q)).trans + (mul_le_mul_of_nonneg_left happrox.le (by positivity))) _ + have hsmall : 2*‖a‖*ε ≤ t/32 := by + have heq : ε*(64*(‖a‖+1))=t := div_mul_cancel₀ _ (by positivity) + nlinarith [hε.le] + change t/16 < ‖τ.toPreGNS (q*a-a*q)‖ + change t/8 < _ at hpdisp + linarith + +end HochschildQuantization + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +open BoundedHochschild HochschildRigidity HochschildSakai HochschildQuantization +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {n : ℕ} (E : MatrixSystem M n) +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +lemma commutant_gns_norm (a : E.commutant) : + ‖(E.commutantTrace τ).toPreGNS a‖ = ‖τ.toPreGNS (a:M)‖ := by + apply (sq_eq_sq₀ (norm_nonneg _) (norm_nonneg _)).mp + rw [norm_sq,norm_sq] + rfl + +include e in + + +theorem exists_energy_decreasing_extension + (hn : 0 ∑ i, ξ i • matrixFunctionalVector F i₀ i + map_add' := fun ξ η => by simp [add_smul, Finset.sum_add_distrib] + map_smul' := fun z ξ => by simp [Finset.smul_sum, mul_smul] } + +@[simp] lemma matrixFunctionalEmbedding_single {n : ℕ} + (F : CStarMatrix (Fin n) (Fin n) A →ₚ[ℂ] ℂ) (i₀ i : Fin n) : + matrixFunctionalEmbedding F i₀ (EuclideanSpace.single i 1) = + matrixFunctionalVector F i₀ i := by + change (∑ j, (EuclideanSpace.single i (1 : ℂ)) j • matrixFunctionalVector F i₀ j) = _ + simp [PiLp.single_apply] + +def matrixFunctionalCP {n : ℕ} (F : CStarMatrix (Fin n) (Fin n) A →ₚ[ℂ] ℂ) + (i₀ : Fin n) : CompletelyPositiveMap A + (EuclideanSpace ℂ (Fin n) →L[ℂ] EuclideanSpace ℂ (Fin n)) := + compressCompletelyPositive + (CompletelyPositiveMapClass.toCompletelyPositiveLinearMap + (F.gnsStarAlgHom.comp (matrixScalarHom n))) (matrixFunctionalEmbedding F i₀) + +lemma matrixFunctionalCP_coefficient {n : ℕ} + (F : CStarMatrix (Fin n) (Fin n) A →ₚ[ℂ] ℂ) (i₀ i j : Fin n) (a : A) : + inner ℂ (EuclideanSpace.single i 1) + (matrixFunctionalCP F i₀ a (EuclideanSpace.single j 1)) = + F (singleCStarMatrix i j a) := by + change inner ℂ (EuclideanSpace.single i 1) + ((matrixFunctionalEmbedding F i₀).adjoint + (F.gnsStarAlgHom (matrixScalarHom n a) + (matrixFunctionalEmbedding F i₀ (EuclideanSpace.single j 1)))) = _ + rw [ContinuousLinearMap.adjoint_inner_right, matrixFunctionalEmbedding_single, + matrixFunctionalEmbedding_single] + unfold matrixFunctionalVector + rw [← ContinuousLinearMap.adjoint_inner_right, ← ContinuousLinearMap.star_eq_adjoint, + ← map_star] + change inner ℂ (NaimarkZFC.gnsVector F) + ((F.gnsStarAlgHom (star (singleCStarMatrix i₀ i 1)) * + (F.gnsStarAlgHom (matrixScalarHom n a) * + F.gnsStarAlgHom (singleCStarMatrix i₀ j 1))) (NaimarkZFC.gnsVector F)) = _ + rw [← map_mul, ← map_mul, NaimarkZFC.gnsVector_coefficient, + singleCStarMatrix_diagonal] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixRightAveraging.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixRightAveraging.lean new file mode 100644 index 0000000000000000000000000000000000000000..5a134761a8a9b1da7fc9e3a3c9e9256fe77ceb16 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixRightAveraging.lean @@ -0,0 +1,100 @@ +import OAI.Analysis.BoundedHochschild.MatrixScalarColumns + +namespace OAI + +/-! Complete boundedness is preserved by finite normalized right averaging. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +lemma finiteRowEstimate_of_columns {n : ℕ} [NeZero n] + (c : Fin n → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) (x : Fin n → M) : + ‖∑ i, T (x i) * star (T (x i))‖ ≤ C ^ 2 * ‖∑ i, x i * star (x i)‖ := by + let k : Fin n := ⟨0, NeZero.pos n⟩ + have hmap : (columnCompression c ((c k : M) * columnRow c x)).map T = + columnCompression c ((c k : M) * columnRow c (fun i => T (x i))) := by + ext i j + rw [CStarMatrix.map_apply, columnCompression_row c hi ho, columnCompression_row c hi ho] + split_ifs <;> simp + have hb := hT.2 n (columnCompression c ((c k : M) * columnRow c x)) + rw [hmap, columnCompression_norm c hi ho hs, columnCompression_norm c hi ho hs, + left_isometry_norm (hi k), left_isometry_norm (hi k)] at hb + have hb2 := pow_le_pow_left₀ (norm_nonneg _) hb 2 + rw [mul_pow, columnRow_norm_sq c hi ho, columnRow_norm_sq c hi ho] at hb2 + exact hb2 + +universe u +variable {N X : Type u} [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma matrixAmplification_rowBound (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] N) + (hno : NoFiniteCentralSummand N) (k : ℕ) (T : N →L[ℂ] N) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : HasFiniteRowBound (matrixAmplification k T) C := by + refine ⟨hT.1, ?_⟩ + intro n x + cases n with + | zero => simp + | succ n => + obtain ⟨c, hi, ho, hs⟩ := exists_properlyInfinite_matrix_columns e hno (n + 1) + obtain ⟨hdi, hdo, hds⟩ := matrixScalar_columns k c hi ho hs + exact finiteRowEstimate_of_columns _ hdi hdo hds _ + (matrixAmplification_completelyBounded k T hT) x + +omit [PartialOrder N] [StarOrderedRing N] in +lemma cstar_finite_sum_apply {I : Type*} [Fintype I] {n : ℕ} + (f : I → CStarMatrix (Fin n) (Fin n) N) (i j : Fin n) : + (∑ t, f t) i j = ∑ t, f t i j := by + classical + exact Matrix.sum_apply i j Finset.univ (fun t => CStarMatrix.ofMatrix.symm (f t)) + +omit [PartialOrder N] [StarOrderedRing N] in +lemma matrix_mul_scalar_apply {k : ℕ} (A : CStarMatrix (Fin k) (Fin k) N) + (b : N) (i j : Fin k) : (A * matrixScalarHom k b) i j = A i j * b := by + simp only [CStarMatrix.mul_apply, matrixScalarHom_apply, mul_ite, mul_zero] + simp + +lemma matrixAmplification_rightAverage {I : Type*} [Fintype I] + (k : ℕ) (m : I → N) (T : N →L[ℂ] N) : + matrixAmplification k (finiteRightAverage m T) = + finiteRightAverage (fun i => matrixScalarHom k (m i)) (matrixAmplification k T) := by + ext A i j + simp only [matrixAmplification_apply, CStarMatrix.map_apply, finiteRightAverage_apply, + cstar_finite_sum_apply, ← map_star, matrix_mul_scalar_apply] + +omit [PartialOrder N] [StarOrderedRing N] in +lemma matrixScalar_normalized {I : Type*} [Fintype I] (k : ℕ) (m : I → N) + (hm : ∑ i, m i * star (m i) = 1) : + ∑ i, matrixScalarHom k (m i) * star (matrixScalarHom k (m i)) = 1 := by + simpa only [map_sum, map_mul, map_star, map_one] using congrArg (matrixScalarHom k) hm + +/-- Finite normalized right averages preserve the original complete bound, +not only its level-one operator norm consequence. -/ +theorem finiteRightAverage_completelyBounded {n : ℕ} + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] N) (hno : NoFiniteCentralSummand N) + (m : Fin (n + 1) → N) (hm : ∑ i, m i * star (m i) = 1) + (T : N →L[ℂ] N) {C : ℝ} (hT : CompletelyBoundedEstimate T C) : + CompletelyBoundedEstimate (finiteRightAverage m T) C := by + refine ⟨hT.1, ?_⟩ + intro k A + have hnorm : ‖matrixAmplification k (finiteRightAverage m T)‖ ≤ C := by + rw [matrixAmplification_rightAverage] + obtain ⟨c, hi, ho, hs⟩ := exists_properlyInfinite_matrix_columns e hno (n + 1) + obtain ⟨hdi, hdo, _⟩ := matrixScalar_columns k c hi ho hs + exact finiteRightAverage_norm_of_rowBound _ hdi hdo _ (matrixScalar_normalized k m hm) + _ (matrixAmplification_rowBound e hno k T hT) + exact ((matrixAmplification k (finiteRightAverage m T)).le_opNorm A).trans + (mul_le_mul_of_nonneg_right hnorm (norm_nonneg A)) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixScalarColumns.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixScalarColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..e7f3717496f233572c15d0e3b867d584f6ff65df --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixScalarColumns.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.NestedMatrixAmplification + +namespace OAI + +/-! Diagonal copies of the proved isometry columns inside finite matrix +algebras. These supply the row estimates at every matrix level. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] + +/-- The unital diagonal embedding into a finite matrix algebra. -/ +def matrixScalarHom (k : ℕ) : M →⋆ₐ[ℂ] CStarMatrix (Fin k) (Fin k) M where + toFun a := CStarMatrix.ofMatrix (Matrix.scalar (Fin k) a) + map_zero' := (Matrix.scalar (Fin k)).map_zero + map_one' := (Matrix.scalar (Fin k)).map_one + map_add' a b := (Matrix.scalar (Fin k)).map_add a b + map_mul' a b := (Matrix.scalar (Fin k)).map_mul a b + commutes' _ := rfl + map_star' a := by + ext i j + change (if i = j then star a else 0) = star (if j = i then a else 0) + by_cases h : i = j + · simp only [h, ite_true] + · simp only [h, Ne.symm h, ite_false, star_zero] + +@[simp] lemma matrixScalarHom_apply (k : ℕ) (a : M) (i j : Fin k) : + matrixScalarHom k a i j = if i = j then a else 0 := rfl + +variable [PartialOrder M] [StarOrderedRing M] + +def matrixScalarPartialIso (k : ℕ) (v : PartialIso M) : + PartialIso (CStarMatrix (Fin k) (Fin k) M) where + val := matrixScalarHom k (v : M) + mul_star_mul := by + simpa only [map_mul, map_star] using congrArg (matrixScalarHom k) v.mul_star_mul + +@[simp] lemma matrixScalarPartialIso_initial (k : ℕ) (v : PartialIso M) : + (matrixScalarPartialIso k v).initial = matrixScalarHom k v.initial := by + simp only [PartialIso.initial, matrixScalarPartialIso, map_mul, map_star] + +@[simp] lemma matrixScalarPartialIso_final (k : ℕ) (v : PartialIso M) : + (matrixScalarPartialIso k v).final = matrixScalarHom k v.final := by + simp only [PartialIso.final, matrixScalarPartialIso, map_mul, map_star] + +lemma matrixScalar_columns {n : ℕ} (k : ℕ) (c : Fin n → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) : + (∀ i, (matrixScalarPartialIso k (c i)).initial = 1) ∧ + (∀ i j, i ≠ j → (matrixScalarPartialIso k (c i)).final * + (matrixScalarPartialIso k (c j)).final = 0) ∧ + ∑ i, (matrixScalarPartialIso k (c i)).final = 1 := by + refine ⟨?_, ?_, ?_⟩ + · intro i + rw [matrixScalarPartialIso_initial, hi, map_one] + · intro i j hij + rw [matrixScalarPartialIso_final, matrixScalarPartialIso_final, ← map_mul, + ho i j hij, map_zero] + · simp only [matrixScalarPartialIso_final, ← map_sum, hs, map_one] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixSectionAveraging.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixSectionAveraging.lean new file mode 100644 index 0000000000000000000000000000000000000000..72a4fc8f01f0ea7daad1e4e775c59f7ea0200c84 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixSectionAveraging.lean @@ -0,0 +1,101 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupMultimodularity +import OAI.Analysis.BoundedHochschild.CountableMatrixGroups +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainChainMap + +namespace OAI + +/-! A fixed finite unitary group for each matrix section. The choices are +independent of the cochain and its degree, so their averages form maps of +the Hochschild complex. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +universe u +variable {M : Type u} [CStarAlgebra M] + +structure MatrixSectionGroup (c : ℕ → PartialIso M) (k : ℕ) where + carrier : Type u + [group : Group carrier] + [finite : Fintype carrier] + representation : carrier →* unitary M + mem : ∀ g, (representation g : M) ∈ countableMatrixAlgebra c + spans : ∀ i j : Fin k, countableMatrixUnit c i.val j.val ∈ + Submodule.span ℂ (Set.range (fun g => (representation g : M))) + +attribute [instance] MatrixSectionGroup.group MatrixSectionGroup.finite + +lemma matrixSectionGroup_nonempty (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (k : ℕ) : + Nonempty (MatrixSectionGroup c k) := by + let d : Fin k → PartialIso M := fun i => c i.val + have hd : ∀ i, (d i).initial = 1 := fun i => hi i.val + have hdo : ∀ i j, i ≠ j → (d i).final * (d j).final = 0 := by + intro i j hij + exact ho i.val j.val (fun h => hij (Fin.ext h)) + let hp := finiteColumnProjection_isProjection d hdo + let E := finiteColumnMatrixSystem d hd hdo + let : Fintype E.signedPermutationGroup := Fintype.ofFinite _ + refine ⟨{ carrier := E.signedPermutationGroup + representation := finiteCornerGroupHom hp E + mem := ?_ + spans := ?_ }⟩ + · apply finiteCornerGroupHom_mem + intro i j + change (c i.val : M) * star (c j.val : M) ∈ countableMatrixAlgebra c + exact StarAlgebra.subset_adjoin ℂ _ ⟨(i.val, j.val), rfl⟩ + · intro i j + exact corner_matrixUnit_mem_group_span hp E i j + +def matrixSectionGroup (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) (k : ℕ) : MatrixSectionGroup c k := + Classical.choice (matrixSectionGroup_nonempty c hi ho k) + +def matrixSectionAverage (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M n) (k : ℕ) : Cochain M n := + finiteGroupCochainAverage (matrixSectionGroup c hi ho k).representation f + +lemma matrixSectionAverage_norm (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M n) (k : ℕ) : ‖matrixSectionAverage c hi ho f k‖ ≤ ‖f‖ := + finiteGroupCochainAverage_norm _ f + +lemma matrixSectionAverage_module (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M (n + 1)) (k : ℕ) (i j : Fin k) : + MultimodularAt (matrixSectionAverage c hi ho f k) (countableMatrixUnit c i.val j.val) := + finiteGroupCochainAverage_span _ f ((matrixSectionGroup c hi ho k).spans i j) + +lemma matrixSectionAverage_add (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f g : Cochain M n) (k : ℕ) : + matrixSectionAverage c hi ho (f + g) k = matrixSectionAverage c hi ho f k + matrixSectionAverage c hi ho g k := + finiteGroupCochainAverage_add _ f g + +lemma matrixSectionAverage_smul (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (z : ℂ) (f : Cochain M n) (k : ℕ) : + matrixSectionAverage c hi ho (z • f) k = z • matrixSectionAverage c hi ho f k := + finiteGroupCochainAverage_smul _ z f + +lemma matrixSectionAverage_differential (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M (n + 1)) (k : ℕ) : + matrixSectionAverage c hi ho (differential f) k = differential (matrixSectionAverage c hi ho f k) := + finiteGroupCochainAverage_differential _ f + +lemma matrixSectionAverage_cocycle (c : ℕ → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + {n : ℕ} (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) (k : ℕ) : + ∀ x, differentialValue (matrixSectionAverage c hi ho f k) x = 0 := + finiteGroupCochainAverage_cocycle _ f hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixSeeds.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixSeeds.lean new file mode 100644 index 0000000000000000000000000000000000000000..dc18be6534a4ef65576a06f44140193818cacdd6 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixSeeds.lean @@ -0,0 +1,119 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.AbelianComparison + +namespace OAI + +/-! Diagonal matrix projections and the type-II condition. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildMatrixSystems +open BoundedHochschild HochschildComparison HochschildTypeII FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +namespace MatrixSystem +variable {n : ℕ} (E : MatrixSystem M n) +omit [PartialOrder M] [StarOrderedRing M] in +lemma diagonal_projection (i : Fin n) : IsStarProjection (E.entry i i) := + ⟨by change E.entry i i*E.entry i i=E.entry i i; simp only [E.entry_mul,ite_true],E.star_entry i i⟩ + +omit [StarOrderedRing M] in +include htr in +lemma diagonal_trace (i j : Fin n) : τ (E.entry i i)=τ (E.entry j j) := by + have ht := htr (E.entry i j) (E.entry j i) + simpa only [E.entry_mul,ite_true] using ht + +omit [StarOrderedRing M] in +include htr in +lemma mul_diagonal_trace (i : Fin n) : (n:ℝ)*(τ (E.entry i i)).re=(τ 1).re := by + have hh := congrArg (fun x : M => (τ x).re) E.sum_diagonal + rw [map_sum,Complex.re_sum] at hh + simpa only [diagonal_trace τ htr E _ i,Finset.sum_const,Finset.card_univ, + Fintype.card_fin,nsmul_eq_mul] using hh + +omit [PartialOrder M] [StarOrderedRing M] in +lemma diagonal_full (i : Fin n) (r : M) (hr : r ≠ 0) : + ∃ a : M, E.entry i i*a*r ≠ 0 := by + by_contra hn + push Not at hn + have her (j : Fin n) : E.entry i j*r=0 := by + simpa only [E.entry_mul,ite_true] using hn (E.entry i j) + have hrr (j : Fin n) : E.entry j j*r=0 := by + calc + E.entry j j*r = (E.entry j i*E.entry i j)*r := by rw [E.entry_mul,ite_eq_left rfl] + _ = 0 := by rw [mul_assoc,her,mul_zero] + apply hr + calc + r = (∑ j, E.entry j j)*r := by rw [E.sum_diagonal,one_mul] + _ = 0 := by rw [Finset.sum_mul]; simp only [hrr,Finset.sum_const_zero] +end MatrixSystem + +include e hτ htr hfaith in +lemma abelian_trace_bound {n : ℕ} (E : MatrixSystem M n) (i : Fin n) + {p : M} (hp : AbelianProjection p) : (n:ℝ)*(τ p).re ≤ (τ 1).re := by + have h := abelian_trace_le_full e τ hτ htr hfaith hp (E.diagonal_projection i) + (fun r _hr hr0 => E.diagonal_full i r hr0) + calc + (n:ℝ)*(τ p).re ≤ (n:ℝ)*(τ (E.entry i i)).re := + mul_le_mul_of_nonneg_left h (Nat.cast_nonneg n) + _ = (τ 1).re := E.mul_diagonal_trace τ htr i + +include e hτ htr hfaith in + +lemma no_abelian_of_matrixSystems (hE : ∀ n : ℕ, Nonempty (MatrixSystem M (n+1))) + {p : M} (hp : AbelianProjection p) : p=0 := by + have hnonneg : 0 ≤ (τ p).re := (Complex.nonneg_iff.mp (τ.map_nonneg hp.1.nonneg)).1 + have hzero : (τ p).re=0 := by + apply le_antisymm _ hnonneg + by_contra hn + have hpos : 0 < (τ p).re := lt_of_not_ge hn + obtain ⟨n,hn⟩ := exists_nat_gt ((τ 1).re/(τ p).re) + let E := Classical.choice (hE n) + have hb := abelian_trace_bound e τ hτ htr hfaith E (0 : Fin (n+1)) hp + have ht : (τ 1).re < (n:ℝ)*(τ p).re := (div_lt_iff₀ hpos).mp hn + rw [Nat.cast_add,Nat.cast_one] at hb + nlinarith + apply hfaith p + rw [hp.1.isSelfAdjoint.star_eq,hp.1.isIdempotentElem.eq] + apply Complex.ext + · exact hzero + · exact (Complex.nonneg_iff.mp (τ.map_nonneg hp.1.nonneg)).2.symm + +omit [StarOrderedRing M] in +include htr hfaith in +lemma finite_of_faithful_trace (a : M) (ha : star a*a=1) : a*star a=1 := by + have hproj : IsStarProjection (a*star a) := by + constructor + · change (a*star a)*(a*star a)=a*star a + simp only [mul_assoc,← mul_assoc (star a) a,ha,one_mul] + · simp only [IsSelfAdjoint,star_mul,star_star] + have hres := hproj.one_sub + have ht : τ (1-a*star a)=0 := by rw [map_sub,htr a (star a),ha,sub_self] + have hz := hfaith (1-a*star a) (by simpa only [hres.isSelfAdjoint.star_eq, + hres.isIdempotentElem.eq] using ht) + exact (sub_eq_zero.mp hz).symm + +include e hτ htr hfaith in +theorem typeII1_of_matrixSystems (hE : ∀ n : ℕ, Nonempty (MatrixSystem M (n+1))) : + TypeII1 M := by + refine ⟨finite_of_faithful_trace τ htr hfaith,?_⟩ + intro z hz + by_contra hz0 + obtain ⟨p,hp,_hpz,hp0⟩ := hz.2 z hz.1 le_rfl hz0 + exact hp0 (no_abelian_of_matrixSystems e τ hτ htr hfaith hE hp) + +end HochschildMatrixSystems + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MatrixSystems.lean b/lean/OAI/Analysis/BoundedHochschild/MatrixSystems.lean new file mode 100644 index 0000000000000000000000000000000000000000..f5db549aa22c0fd6c935d0f2339c0eb5a510ac7e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MatrixSystems.lean @@ -0,0 +1,496 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PartialIsometries + +namespace OAI + +/-! Matrix systems, expectations and rational projection approximation. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +private lemma projection_orthogonal_of_le_sub {p r t : M} + (hp : IsStarProjection p) (hr : IsStarProjection r) (ht : IsStarProjection t) + (hrp : r ≤ p) (htp : t ≤ p-r) : r*t=0 := by + have hh := (ht.le_iff_mul_eq_right ((hr.le_iff_sub hp).mp hrp)).mp htp + calc + r*t = r*((p-r)*t) := by rw [hh] + _ = (r*p-r*r)*t := by noncomm_ring + _ = 0 := by rw [(hr.le_iff_mul_eq_left hp).mp hrp,hr.isIdempotentElem.eq,sub_self,zero_mul] + +include e hτ htr hfaith in +lemma exists_partition_trace (hdiff : HochschildDiffuse.NoMinimalProjections M) + (n : ℕ) {p : M} (hp : IsStarProjection p) {t : ℝ} (ht : 0 ≤ t) + (hpt : (τ p).re = (n : ℝ)*t) : + ∃ q : Fin n → M, (∀ i, IsStarProjection (q i)) ∧ + (∀ i, q i ≤ p) ∧ (∀ i j, i ≠ j → q i*q j=0) ∧ + (∑ i, q i)=p ∧ ∀ i, (τ (q i)).re=t := by + induction n generalizing p with + | zero => + have htp : τ p=0 := by + apply Complex.ext + · simpa using hpt + · exact (Complex.nonneg_iff.mp (τ.map_nonneg hp.nonneg)).2.symm + have hp0 : p=0 := hfaith p (by simpa only [hp.isSelfAdjoint.star_eq, + hp.isIdempotentElem.eq] using htp) + subst p + exact ⟨Fin.elim0, by simp, by simp, by simp, by simp, by simp⟩ + | succ n ih => + have hle : t ≤ (τ p).re := by + rw [hpt, Nat.cast_add, Nat.cast_one] + nlinarith [mul_nonneg (Nat.cast_nonneg n : (0:ℝ)≤n) ht] + obtain ⟨a,ha,hap,hat⟩ := HochschildDiffuse.exists_projection_of_trace τ e + (HochschildSakai.mul_hasPreadjoint e) hτ htr hfaith hdiff hp t ht hle + have hpa := (ha.le_iff_sub hp).mp hap + have hpat : (τ (p-a)).re = (n : ℝ)*t := by + rw [map_sub,Complex.sub_re,hpt,hat,Nat.cast_add,Nat.cast_one] + ring + obtain ⟨q,hq,hqp,hqo,hqs,hqt⟩ := ih hpa hpat + refine ⟨Fin.cases a q,?_,?_,?_,?_,?_⟩ + · intro i + exact Fin.cases ha hq i + · intro i + exact Fin.cases hap (fun j => (hqp j).trans (sub_le_self _ ha.nonneg)) i + · intro i + refine Fin.cases ?_ (fun i => ?_) i + · intro j + refine Fin.cases ?_ (fun j => ?_) j + · intro hij + exact (hij rfl).elim + · intro _ + exact projection_orthogonal_of_le_sub hp ha (hq j) hap (hqp j) + · intro j + refine Fin.cases ?_ (fun j => ?_) j + · intro _ + have hh := projection_orthogonal_of_le_sub hp ha (hq i) hap (hqp i) + simpa only [star_mul, (hq i).isSelfAdjoint.star_eq, ha.isSelfAdjoint.star_eq, + star_zero,Fin.cases_zero,Fin.cases_succ] using congrArg star hh + · intro hij + exact hqo i j (fun he => hij (congrArg Fin.succ he)) + · rw [Fin.sum_univ_succ] + simp only [Fin.cases_zero,Fin.cases_succ,hqs] + abel + · intro i + exact Fin.cases hat hqt i + + +structure MatrixSystem (M : Type*) [Ring M] [StarRing M] (n : ℕ) where + entry : Fin n → Fin n → M + star_entry : ∀ i j, star (entry i j)=entry j i + entry_mul : ∀ i j k l, entry i j*entry k l=if j=k then entry i l else 0 + sum_diagonal : ∑ i, entry i i=1 + +omit [PartialOrder M] [StarOrderedRing M] in +private lemma mul_of_initial_projection {v p : M} (hp : IsStarProjection p) + (hv : star v*v=p) : v*p=v := by + apply sub_eq_zero.mp + apply (CStarRing.star_mul_self_eq_zero_iff _).mp + calc + star (v*p-v)*(v*p-v) = p*(star v*v)*p-p*(star v*v)-(star v*v)*p+star v*v := by + simp only [star_sub,star_mul,hp.isSelfAdjoint.star_eq] + noncomm_ring + _ = 0 := by simp only [hv,hp.isIdempotentElem.eq]; abel + +include e hτ htr hfaith in + + +theorem exists_matrixSystem (h1 : τ 1=1) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + (hdiff : HochschildDiffuse.NoMinimalProjections M) (n : ℕ) (hn : 0 exists_partialIso_of_equal_trace e τ hτ htr hfaith + h1 hfactor (hp i0) (hp i) (ht i) + have hvi : ∀ i, v i*p i0=v i := fun i => mul_of_initial_projection (hp i0) (hv0 i) + have hvf : ∀ i, p i*v i=v i := by + intro i + rw [← hv i,mul_assoc,hv0 i,hvi i] + have hvs : ∀ i, star (v i)*p i=star (v i) := by + intro i + simpa only [star_mul,(hp i).isSelfAdjoint.star_eq] using congrArg star (hvf i) + have hcross : ∀ i j, i ≠ j → star (v i)*v j=0 := by + intro i j hij + calc + star (v i)*v j = (star (v i)*p i)*(p j*v j) := by rw [hvs,hvf] + _ = star (v i)*(p i*p j)*v j := by simp only [mul_assoc] + _ = 0 := by rw [hpo i j hij,mul_zero,zero_mul] + refine ⟨⟨fun i j => v i*star (v j),?_,?_,?_⟩⟩ + · intro i j + simp only [star_mul,star_star] + · intro i j k l + by_cases h : j=k + · subst k + rw [ite_eq_left rfl] + calc + (v i*star (v j))*(v j*star (v l)) = v i*(star (v j)*v j)*star (v l) := by + simp only [mul_assoc] + _ = v i*star (v l) := by rw [hv0,hvi] + · rw [ite_eq_right h] + calc + (v i*star (v j))*(v k*star (v l)) = v i*(star (v j)*v k)*star (v l) := by + simp only [mul_assoc] + _ = 0 := by rw [hcross j k h,mul_zero,zero_mul] + · simpa only [hv] using hps + +end HochschildMatrixSystems + + + + + + + +open scoped ComplexOrder +namespace HochschildMatrixSystems +namespace MatrixSystem +variable {M : Type*} [CStarAlgebra M] +variable {n : ℕ} (E : MatrixSystem M n) + + +def expectation : M →ₗ[ℂ] M where + toFun x := (n : ℂ)⁻¹ • ∑ i, ∑ j, E.entry i j*x*E.entry j i + map_add' x y := by simp only [mul_add, add_mul, Finset.sum_add_distrib, smul_add] + map_smul' c x := by + simp only [mul_smul_comm, smul_mul_assoc, ← Finset.smul_sum] + exact smul_comm _ _ _ + +lemma expectation_apply (x : M) : E.expectation x = + (n : ℂ)⁻¹ • ∑ i, ∑ j, E.entry i j*x*E.entry j i := rfl + +lemma expectation_star (x : M) : E.expectation (star x) = star (E.expectation x) := by + simp [expectation_apply, star_smul, star_sum, star_mul, E.star_entry,mul_assoc] + +lemma entry_mul_expectation (a b : Fin n) (x : M) : + E.entry a b*E.expectation x = + (n : ℂ)⁻¹ • ∑ j, E.entry a j*x*E.entry j b := by + classical + simp only [expectation_apply,mul_smul_comm,Finset.mul_sum,← mul_assoc,E.entry_mul] + simp only [ite_mul,zero_mul] + rw [Finset.sum_comm] + simp + +lemma expectation_mul_entry (a b : Fin n) (x : M) : + E.expectation x*E.entry a b = + (n : ℂ)⁻¹ • ∑ j, E.entry a j*x*E.entry j b := by + have hh := congrArg star (E.entry_mul_expectation b a (star x)) + simpa [star_mul,← E.expectation_star,E.star_entry,star_smul,star_sum,mul_assoc] using hh + +lemma commute_expectation (x : M) (i j : Fin n) : + Commute (E.expectation x) (E.entry i j) := + (E.expectation_mul_entry i j x).trans (E.entry_mul_expectation i j x).symm + +lemma expectation_eq_self (hn : n ≠ 0) (x : M) + (hx : ∀ i j, Commute x (E.entry i j)) : E.expectation x=x := by + classical + have hnC : (n : ℂ) ≠ 0 := by exact_mod_cast hn + calc + E.expectation x = (n : ℂ)⁻¹ • ∑ i, ∑ j, x*(E.entry i j*E.entry j i) := by + simp only [expectation_apply,← mul_assoc,← fun i j => (hx i j).eq] + _ = (n : ℂ)⁻¹ • ((n : ℂ) • (x * ∑ i, E.entry i i)) := by + simp only [E.entry_mul,ite_true,Finset.sum_const,Finset.card_univ,Fintype.card_fin] + simp only [← Finset.mul_sum,nsmul_eq_mul,Nat.cast_smul_eq_nsmul] + _ = x := by rw [E.sum_diagonal,mul_one,smul_smul,inv_mul_cancel₀ hnC,one_smul] + +lemma expectation_idempotent (hn : n ≠ 0) (x : M) : + E.expectation (E.expectation x)=E.expectation x := + E.expectation_eq_self hn _ (E.commute_expectation x) + +variable [PartialOrder M] + +lemma trace_expectation (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hn : n ≠ 0) (x : M) : τ (E.expectation x)=τ x := by + classical + have hnC : (n : ℂ) ≠ 0 := by exact_mod_cast hn + have hterm (i j : Fin n) : τ (E.entry i j*x*E.entry j i)=τ (x*E.entry j j) := by + rw [htr,← mul_assoc,E.entry_mul,ite_eq_left rfl,htr] + simp only [expectation_apply,map_smul,map_sum,hterm] + simp only [Finset.sum_const,Finset.card_univ,Fintype.card_fin,← map_sum,← Finset.mul_sum, + E.sum_diagonal,mul_one,smul_eq_mul] + simp [← Nat.cast_smul_eq_nsmul ℂ n (τ x),smul_eq_mul,hnC] + +lemma trace_adjoint (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (x y : M) : τ (E.expectation x*y)=τ (x*E.expectation y) := by + classical + have hterm (i j : Fin n) : τ ((E.entry i j*x*E.entry j i)*y)= + τ (x*(E.entry j i*y*E.entry i j)) := by + rw [mul_assoc,mul_assoc,htr] + simp only [mul_assoc] + simp only [expectation_apply,smul_mul_assoc,mul_smul_comm,map_smul, + Finset.sum_mul,Finset.mul_sum,map_sum,hterm] + rw [Finset.sum_comm] + +lemma trace_residual_expectation (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (x : M) : + τ (star (x-E.expectation x)*E.expectation x)=0 := by + rw [← E.trace_adjoint τ htr,E.expectation_star,map_sub,E.expectation_idempotent hn, + sub_self,star_zero,zero_mul,map_zero] + +variable [StarOrderedRing M] + +lemma norm_sq (τ : M →ₚ[ℂ] ℂ) (x : M) : + ‖τ.toPreGNS x‖^2=(τ (star x*x)).re := by + have hh := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS x)) + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS,← Complex.ofReal_pow,Complex.ofReal_re] using hh + +lemma expectation_pythagoras (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (x : M) : + ‖τ.toPreGNS x‖^2 = ‖τ.toPreGNS (E.expectation x)‖^2 + + ‖τ.toPreGNS (x-E.expectation x)‖^2 := by + have hh := E.trace_residual_expectation τ htr hn x + have hh' : τ (star (E.expectation x)*(x-E.expectation x))=0 := by + have hs := congrArg star hh + rw [← map_star τ] at hs + simpa only [star_mul,star_star,star_zero] using hs + rw [norm_sq,norm_sq,norm_sq] + have he : τ (star x*x)=τ (star (E.expectation x)*E.expectation x)+ + τ (star (x-E.expectation x)*(x-E.expectation x)) := by + have hdecomp : star x*x=star (E.expectation x)*E.expectation x+ + star (x-E.expectation x)*(x-E.expectation x)+ + (star (x-E.expectation x)*E.expectation x+star (E.expectation x)*(x-E.expectation x)) := by + simp only [star_sub] + noncomm_ring + simp only [hdecomp,map_add,hh,hh',add_zero] + rw [he,Complex.add_re] + +lemma expectation_gns_contract (τ : M →ₚ[ℂ] ℂ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) (hn : n ≠ 0) (x : M) : + ‖τ.toPreGNS (E.expectation x)‖ ≤ ‖τ.toPreGNS x‖ := by + have hh := E.expectation_pythagoras τ htr hn x + nlinarith [sq_nonneg ‖τ.toPreGNS (x-E.expectation x)‖, + norm_nonneg (τ.toPreGNS x),norm_nonneg (τ.toPreGNS (E.expectation x))] + +end MatrixSystem +end HochschildMatrixSystems + + + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildMatrixSystems +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +include e hτ htr hfaith in +lemma exists_matrixSystem_of_partition (h1 : τ 1=1) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + {n : ℕ} (hn : 0 exists_partialIso_of_equal_trace e τ hτ htr hfaith + h1 hfactor (hp i0) (hp i) (ht i0 i) + have hvi : ∀ i, v i*p i0=v i := by + intro i + apply sub_eq_zero.mp + apply (CStarRing.star_mul_self_eq_zero_iff _).mp + calc + star (v i*p i0-v i)*(v i*p i0-v i) = + p i0*(star (v i)*v i)*p i0-p i0*(star (v i)*v i)- + (star (v i)*v i)*p i0+star (v i)*v i := by + simp only [star_sub,star_mul,(hp i0).isSelfAdjoint.star_eq] + noncomm_ring + _ = 0 := by simp only [hv0,(hp i0).isIdempotentElem.eq,sub_self,zero_sub,neg_add_cancel] + have hvf : ∀ i, p i*v i=v i := by + intro i + rw [← hv i,mul_assoc,hv0 i,hvi i] + have hvs : ∀ i, star (v i)*p i=star (v i) := by + intro i + simpa only [star_mul,(hp i).isSelfAdjoint.star_eq] using congrArg star (hvf i) + have hcross : ∀ i j, i ≠ j → star (v i)*v j=0 := by + intro i j hij + calc + star (v i)*v j = (star (v i)*p i)*(p j*v j) := by rw [hvs,hvf] + _ = star (v i)*(p i*p j)*v j := by simp only [mul_assoc] + _ = 0 := by rw [hpo i j hij,mul_zero,zero_mul] + refine ⟨⟨fun i j => v i*star (v j),?_,?_,?_⟩,?_⟩ + · intro i j + simp only [star_mul,star_star] + · intro i j k l + by_cases h : j=k + · subst k + rw [ite_eq_left rfl] + calc + (v i*star (v j))*(v j*star (v l)) = v i*(star (v j)*v j)*star (v l) := by + simp only [mul_assoc] + _ = v i*star (v l) := by rw [hv0,hvi] + · rw [ite_eq_right h] + calc + (v i*star (v j))*(v k*star (v l)) = v i*(star (v j)*v k)*star (v l) := by + simp only [mul_assoc] + _ = 0 := by rw [hcross j k h,mul_zero,zero_mul] + · simpa only [hv] using hps + · exact hv + +lemma projection_trace_real (p : M) (hp : IsStarProjection p) : τ p = ((τ p).re : ℂ) := by + apply Complex.ext + · rfl + · exact (Complex.nonneg_iff.mp (τ.map_nonneg hp.nonneg)).2.symm + +include e hτ htr hfaith in +lemma exists_rational_subprojection (hdiff : HochschildDiffuse.NoMinimalProjections M) + {p : M} (hp : IsStarProjection p) (n : ℕ) (hn : 0.mp (haq i), + (hb j).le_iff_mul_eq_right hqc |>.mp (hbq j)] + _ = 0 := by rw [mul_assoc,← mul_assoc q, mul_sub,mul_one,hq.isIdempotentElem.eq, + sub_self,zero_mul,mul_zero] + refine ⟨p,?_,?_,?_,?_,?_⟩ + · intro i + refine Fin.addCases (fun i => ?_) (fun i => ?_) i + · simpa only [p,Fin.addCases_left] using ha i + · simpa only [p,Fin.addCases_right] using hb i + · intro i j + refine Fin.addCases ?_ ?_ i <;> intro i <;> refine Fin.addCases ?_ ?_ j <;> intro j hij + · simpa only [p,Fin.addCases_left] using hao i j (fun h => hij (congrArg (Fin.castAdd (n-k)) h)) + · simpa only [p,Fin.addCases_left,Fin.addCases_right] using hcross i j + · simpa only [p,Fin.addCases_left,Fin.addCases_right,star_mul,star_zero,(hb i).isSelfAdjoint.star_eq, + (ha j).isSelfAdjoint.star_eq] using congrArg star (hcross j i) + · simpa only [p,Fin.addCases_right] using hbo i j (fun h => hij (congrArg (Fin.natAdd k) h)) + · simp only [p,Fin.sum_univ_add,Fin.addCases_left,Fin.addCases_right,has,hbs] + abel + · intro i + refine Fin.addCases (fun i => ?_) (fun i => ?_) i + · simpa only [p,Fin.addCases_left] using hat i + · simpa only [p,Fin.addCases_right] using hbt i + · simpa only [p,Fin.addCases_left] using has + +include e hτ htr hfaith in + + +theorem exists_matrix_projection_approx (hdiff : HochschildDiffuse.NoMinimalProjections M) + (h1 : τ 1=1) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + {p : M} (hp : IsStarProjection p) {ε : ℝ} (hε : 0<ε) : + ∃ (n : ℕ) (E : MatrixSystem M n) (s : Finset (Fin n)), 0 by + obtain ⟨c, hc, hu⟩ := infinitePair_chain_upper e C (fun a ha => hC ha) hchain ⟨b, hb⟩ + exact ⟨c, hc, hu⟩) (0, 0) hzero + have ha : IsInfinitePair a := hm.1 + let p := a.1.initial + have hp : IsStarProjection p := a.1.initial_proj + refine ⟨p, hp, ⟨a.1, a.2, rfl, ha.1.symm, ha.2.1, ha.2.2.1, ha.2.2.2⟩, ?_⟩ + by_contra hn + obtain ⟨q, hq, hqp, hq0, u, w, hui, hwi, huf, hwf, huw⟩ := + exists_properlyInfinite_subprojection e hp.one_sub hn + have hpq : p * q = 0 := HochschildTypeII.projection_orthogonal_of_le_complement hp hq hqp + have hi1 : a.1.initial * u.initial = 0 := by rw [hui]; exact hpq + have hi2 : a.2.initial * w.initial = 0 := by rw [← ha.1, hwi]; exact hpq + have hf1 : a.1.final * u.final = 0 := + projection_mul_zero_of_bounds hp hq a.1.final_proj u.final_proj hpq ha.2.1 huf + have hf2 : a.2.final * w.final = 0 := + projection_mul_zero_of_bounds hp hq a.2.final_proj w.final_proj hpq ha.2.2.1 hwf + let b := (a.1.orthogonalSum u hi1 hf1, a.2.orthogonalSum w hi2 hf2) + have hbi : b.1.initial = p + q := by rw [PartialIso.orthogonalSum_initial, hui] + have hbii : b.2.initial = p + q := by rw [PartialIso.orthogonalSum_initial, ← ha.1, hwi] + have hbf : b.1.final = a.1.final + u.final := by + exact PartialIso.orthogonalSum_final a.1 u hi1 hf1 + have hbff : b.2.final = a.2.final + w.final := by + exact PartialIso.orthogonalSum_final a.2 w hi2 hf2 + have hb : b ∈ S := by + refine ⟨hbi.trans hbii.symm, ?_, ?_, ?_⟩ + · rw [hbf, hbi] + exact add_le_add ha.2.1 huf + · rw [hbff, hbi] + exact add_le_add ha.2.2.1 hwf + · have hcross1 : a.1.final * w.final = 0 := + projection_mul_zero_of_bounds hp hq a.1.final_proj w.final_proj hpq ha.2.1 hwf + have hcross2 : u.final * a.2.final = 0 := by + have h := projection_mul_zero_of_bounds hp hq a.2.final_proj u.final_proj + hpq ha.2.2.1 huf + simpa only [star_mul, a.2.final_proj.isSelfAdjoint.star_eq, + u.final_proj.isSelfAdjoint.star_eq, star_zero] using congrArg star h + rw [hbf, hbff] + simp only [add_mul, mul_add, ha.2.2.2, huw, hcross1, hcross2, zero_add] + have hab : a ≤ b := ⟨a.1.le_orthogonalSum u hi1 hf1, a.2.le_orthogonalSum w hi2 hf2⟩ + have he := le_antisymm (hm.2 hb hab) hab + have hip : p + q = p := by + have h := congrArg (fun b : PartialIso M × PartialIso M => b.1.initial) he + exact hbi.symm.trans h + exact hq0 (add_eq_left.mp hip) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MinimalFactors.lean b/lean/OAI/Analysis/BoundedHochschild/MinimalFactors.lean new file mode 100644 index 0000000000000000000000000000000000000000..7e641848cc83d8070c6703db794429949d8a0b8c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MinimalFactors.lean @@ -0,0 +1,231 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.CocycleNormalParts +import OAI.Analysis.BoundedHochschild.FactorFinitePaths +import OAI.Analysis.BoundedHochschild.FreeWords +import OAI.Analysis.BoundedHochschild.MatrixDisplacement +import OAI.Analysis.BoundedHochschild.UnitaryLifts +import OAI.Analysis.BoundedHochschild.FactorPrimitive +import OAI.Analysis.BoundedHochschild.TypeIICorners +import OAI.Analysis.BoundedHochschild.CenterPowers + +namespace OAI + +/-! Matrix systems in finite factors with minimal projections. -/ + +noncomputable section + +open scoped ComplexOrder +namespace HochschildMinimalFactor +open BoundedHochschild HochschildComparison HochschildMatrixSystems FinitePathMain +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hτ : TraceInPredual e τ) (h1 : τ 1=1) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hfactor : ∀ a : M, (∀ x : M, Commute a x) → ∃ c : ℂ, a=c • (1:M)) + +include e in +lemma abelian_of_minimal {p : M} (hp : IsStarProjection p) + (hmin : ∀ q : M, IsStarProjection q → q ≤ p → q=0 ∨ q=p) : AbelianProjection p := by + refine ⟨hp,fun a b => ?_⟩ + apply HochschildCorners.commute_corner_of_projections e hp + (b:=p*b*p) _ (HochschildCorners.compress_mem_corner hp a) + intro q hq hqp + rcases hmin q hq hqp with hz | he + · rw [hz]; exact Commute.zero_left _ + · rw [he] + change p*(p*b*p)=(p*b*p)*p + rw [(HochschildCorners.compress_mem_corner hp b).1, + (HochschildCorners.compress_mem_corner hp b).2] + +include e hτ h1 htr hfaith hfactor in +lemma copy_into_nonzero {p q : M} (hp : IsStarProjection p) (hp0 : p ≠ 0) + (hmin : ∀ r : M, IsStarProjection r → r ≤ p → r=0 ∨ r=p) + (hq : IsStarProjection q) (hq0 : q≠0) : + ∃ v : PartialIso M, v.initial=p ∧ v.final ≤ q := by + obtain ⟨a,ha⟩ := exists_nonzero_corner e τ (HochschildSakai.mul_hasPreadjoint e) + hτ htr hfaith h1 hfactor hq hp hq0 hp0 + obtain ⟨v,hv,hvi,hvf⟩ := partialIso_of_nonzero_corner e hq hp (q*a*p) ha + (by rw [← mul_assoc,← mul_assoc,hq.isIdempotentElem.eq]) + (by rw [mul_assoc,hp.isIdempotentElem.eq]) + refine ⟨v,?_,hvf⟩ + rcases hmin v.initial v.initial_proj hvi with hz | he + · exact (hv ((CStarRing.star_mul_self_eq_zero_iff (v:M)).mp hz)).elim + · exact he + +structure Packing (p : M) (n : ℕ) where + v : Fin n → PartialIso M + initial : ∀ i, (v i).initial=p + orthogonal : ∀ i j, i≠j → (v i).final*(v j).final=0 + +namespace Packing +variable {p : M} {n : ℕ} (P : Packing p n) +def total : M := ∑ i, (P.v i).final +omit [PartialOrder M] [StarOrderedRing M] in +lemma total_proj : IsStarProjection P.total := by + classical + have he (i j : Fin n) : (P.v i).final*(P.v j).final= + if i=j then (P.v i).final else 0 := by + by_cases h : i=j + · subst j; rw [ite_eq_left rfl]; exact (P.v i).final_proj.isIdempotentElem.eq + · rw [ite_eq_right h]; exact P.orthogonal i j h + constructor + · change (∑ i, (P.v i).final)*(∑ j, (P.v j).final)=∑ i, (P.v i).final + rw [Finset.sum_mul_sum] + simp only [he,Finset.sum_ite_eq,Finset.mem_univ,ite_true] + · change star (∑ i, (P.v i).final)=∑ i, (P.v i).final + simp only [star_sum,(P.v _).final_proj.isSelfAdjoint.star_eq] + +lemma final_le_total (i : Fin n) : (P.v i).final ≤ P.total := by + exact Finset.single_le_sum (fun j _ => (P.v j).final_proj.nonneg) (Finset.mem_univ i) +omit [StarOrderedRing M] in +include htr in +lemma total_trace : (τ P.total).re=(n:ℝ)*(τ p).re := by + have he (i : Fin n) : τ (P.v i).final=τ p := by + rw [PartialIso.final,htr,← PartialIso.initial,P.initial] + simp [total,map_sum,he] + +include e hτ h1 htr hfaith hfactor in +lemma extend (hp : IsStarProjection p) (hp0 : p≠0) + (hmin : ∀ r : M, IsStarProjection r → r ≤ p → r=0 ∨ r=p) + (hne : P.total≠1) : Nonempty (Packing p (n+1)) := by + have hq0 : 1-P.total≠0 := sub_ne_zero.mpr (Ne.symm hne) + obtain ⟨w,hwi,hwf⟩ := copy_into_nonzero e τ hτ h1 htr hfaith hfactor hp hp0 hmin + P.total_proj.one_sub hq0 + have hfw (i : Fin n) : (P.v i).final*w.final=0 := by + have htw : P.total*w.final=0 := by + have h := (w.final_proj.le_iff_mul_eq_right P.total_proj.one_sub).mp hwf + rw [sub_mul,one_mul] at h + exact sub_eq_self.mp h + calc + (P.v i).final*w.final=((P.v i).final*P.total)*w.final := by + rw [((P.v i).final_proj.le_iff_mul_eq_left P.total_proj).mp (P.final_le_total i)] + _ = 0 := by rw [mul_assoc,htw,mul_zero] + refine ⟨⟨Fin.cases w P.v,?_,?_⟩⟩ + · intro i + exact Fin.cases hwi P.initial i + · intro i + refine Fin.cases ?_ (fun i => ?_) i + · intro j + refine Fin.cases ?_ (fun j => ?_) j + · intro hj; exact (hj rfl).elim + · intro _; exact PartialIso.orthogonal_final_symm (hfw j) + · intro j + refine Fin.cases ?_ (fun j => ?_) j + · intro _; exact hfw i + · intro hij; exact P.orthogonal i j (fun he => hij (congrArg Fin.succ he)) +end Packing + +include e hτ h1 htr hfaith hfactor in +lemma exists_full_packing {p : M} (hp : IsStarProjection p) (hp0 : p≠0) + (hmin : ∀ r : M, IsStarProjection r → r ≤ p → r=0 ∨ r=p) : + ∃ (n : ℕ) (P : Packing p n), 0 exact ⟨⟨Fin.elim0,by simp,by simp⟩⟩ + | succ n ih => + obtain ⟨P⟩ := ih + exact P.extend e τ hτ h1 htr hfaith hfactor hp hp0 hmin (hnot n P) + obtain ⟨N,hN⟩ := exists_nat_gt ((τ 1).re/(τ p).re) + obtain ⟨P⟩ := hall N + have hle := Complex.re_le_re (τ.monotone P.total_proj.le_one) + change (τ P.total).re ≤ (τ 1).re at hle + rw [P.total_trace τ htr] at hle + have hlt : (τ 1).re < (N:ℝ)*(τ p).re := (div_lt_iff₀ ht0).mp hN + exact (not_lt_of_ge hle) hlt + +omit [PartialOrder M] [StarOrderedRing M] in +lemma abelian_final (v : PartialIso M) (hp : AbelianProjection v.initial) : + AbelianProjection v.final := by + refine ⟨v.final_proj,fun a b => ?_⟩ + have hi : v.initial*star (v:M)=star (v:M) := by + simpa only [star_mul,star_star,v.initial_proj.isSelfAdjoint.star_eq] + using congrArg star v.mul_initial + have he (a : M) : v.initial*(star (v:M)*a*v)*v.initial=star (v:M)*a*v := by + calc + v.initial*(star (v:M)*a*v)*v.initial= + (v.initial*star (v:M))*a*((v:M)*v.initial) := by simp only [mul_assoc] + _ = star (v:M)*a*v := by rw [hi,v.mul_initial] + have h := (hp.2 (star (v:M)*a*v) (star (v:M)*b*v)).eq + rw [he,he] at h + have hprod (a b : M) : + (v.final*a*v.final)*(v.final*b*v.final)= + (v:M)*((star (v:M)*a*v)*(star (v:M)*b*v))*star (v:M) := by + calc + (v.final*a*v.final)*(v.final*b*v.final)= + v.final*a*(v.final*v.final)*b*v.final := by noncomm_ring + _ = v.final*a*v.final*b*v.final := by rw [v.final_proj.isIdempotentElem.eq] + _ = _ := by simp only [PartialIso.final,mul_assoc] + change (v.final*a*v.final)*(v.final*b*v.final)=(v.final*b*v.final)*(v.final*a*v.final) + rw [hprod,hprod,h] + +namespace Packing +variable {p : M} {n : ℕ} (P : Packing p n) +def matrixSystem (hfull : P.total=1) : MatrixSystem M n where + entry i j := (P.v i:M)*star (P.v j:M) + star_entry i j := by simp only [star_mul,star_star] + entry_mul i j k l := by + by_cases h : j=k + · subst k + rw [ite_eq_left rfl] + have he : (P.v i:M)*(P.v j).initial=(P.v i:M) := by + rw [(P.initial j).trans (P.initial i).symm,(P.v i).mul_initial] + calc + ((P.v i:M)*star (P.v j:M))*((P.v j:M)*star (P.v l:M)) = + ((P.v i:M)*(P.v j).initial)*star (P.v l:M) := by simp only [PartialIso.initial,mul_assoc] + _ = _ := by rw [he] + · rw [ite_eq_right h] + have hcross := PartialIso.star_mul_eq_zero_of_final_orthogonal (P.orthogonal j k h) + calc + ((P.v i:M)*star (P.v j:M))*((P.v k:M)*star (P.v l:M)) = + (P.v i:M)*(star (P.v j:M)*(P.v k:M))*star (P.v l:M) := by simp only [mul_assoc] + _ = 0 := by rw [hcross,mul_zero,zero_mul] + sum_diagonal := hfull +omit [PartialOrder M] [StarOrderedRing M] in +lemma matrix_abelian_diagonal (hfull : P.total=1) (hp : AbelianProjection p) (i : Fin n) : + AbelianProjection ((P.matrixSystem hfull).entry i i) := by + apply abelian_final (P.v i) + simpa only [P.initial i] using hp +end Packing + +include e hτ h1 htr hfaith hfactor in + +theorem exists_abelian_matrix_system (hnd : ¬HochschildDiffuse.NoMinimalProjections M) : + ∃ (n : ℕ) (E : MatrixSystem M n) (i : Fin n), AbelianProjection (E.entry i i) := by + classical + rw [HochschildDiffuse.NoMinimalProjections] at hnd + push Not at hnd + obtain ⟨p,hp,hp0,hm⟩ := hnd + have hmin (q : M) (hq : IsStarProjection q) (hqp : q ≤ p) : q=0 ∨ q=p := by + by_cases hq0 : q=0 + · exact Or.inl hq0 + · exact Or.inr (hm q hq hqp hq0) + obtain ⟨n,P,hn,hfull⟩ := exists_full_packing e τ hτ h1 htr hfaith hfactor hp hp0 hmin + exact ⟨n,P.matrixSystem hfull,⟨0,hn⟩, + P.matrix_abelian_diagonal hfull (abelian_of_minimal e hp hmin) _⟩ + +end HochschildMinimalFactor + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MinimalIsometricOrbit.lean b/lean/OAI/Analysis/BoundedHochschild/MinimalIsometricOrbit.lean new file mode 100644 index 0000000000000000000000000000000000000000..50c208cd7e56e1f61025d166e19cb08d7de69376 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MinimalIsometricOrbit.lean @@ -0,0 +1,104 @@ +import OAI.Analysis.BoundedHochschild.WeakCompactFragment +import OAI.Analysis.BoundedHochschild.CompactInvariantSets +import Mathlib.Topology.MetricSpace.Pseudo.Basic + +namespace OAI + +/-! Minimal weakly compact isometric orbits are norm compact in a separable space. -/ + +noncomputable section + +open Topology TopologicalSpace + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u v + +variable {E : Type u} [NormedAddCommGroup E] [NormedSpace ℂ E] +variable {G : Type v} [Group G] + +/-- The weak action associated to a linear isometry. -/ +def weakIsometry (T : E ≃ₗᵢ[ℂ] E) : WeakSpace ℂ E → WeakSpace ℂ E := + WeakSpace.map T.toContinuousLinearEquiv.toContinuousLinearMap + +@[simp] lemma weakIsometry_apply (T : E ≃ₗᵢ[ℂ] E) (x : WeakSpace ℂ E) : + (toWeakSpace ℂ E).symm (weakIsometry T x) = T ((toWeakSpace ℂ E).symm x) := rfl + +/-- Minimality and the Baire small-piece lemma give a finite norm net. -/ +theorem minimal_isometric_orbit_finite_net (T : G → E ≃ₗᵢ[ℂ] E) + (hone : ∀ x, T 1 x = x) (hmul : ∀ g h x, T (g * h) x = T g (T h x)) + (K : Set (WeakSpace ℂ E)) (hK : IsCompact K) (hne : K.Nonempty) + (hsep : IsSeparable ((toWeakSpace ℂ E).symm '' K)) + (hinv : ∀ g, Set.MapsTo (weakIsometry (T g)) K K) + (hmin : ∀ L : Set (WeakSpace ℂ E), L ⊆ K → L.Nonempty → IsClosed L → + (∀ g, Set.MapsTo (weakIsometry (T g)) L L) → K ⊆ L) + (ε : ℝ) (hε : 0 < ε) : + ∃ s : Finset E, (↑s : Set E) ⊆ (toWeakSpace ℂ E).symm '' K ∧ + ∀ x ∈ K, ∃ y ∈ s, ‖(toWeakSpace ℂ E).symm x - y‖ < ε := by + classical + obtain ⟨U, hU, hKU, hdiam⟩ := weakCompact_small_open_piece K hK hne hsep ε hε + have hcov : K ⊆ ⋃ g, weakIsometry (T g) ⁻¹' U := by + apply minimal_invariant_open_cover (fun g => weakIsometry (T g)) + (fun g => (WeakSpace.map (T g).toContinuousLinearEquiv.toContinuousLinearMap).continuous) + _ _ K hK.isClosed hinv hmin U hU hKU + · intro x + apply (toWeakSpace ℂ E).symm.injective + exact hone _ + · intro g h x + apply (toWeakSpace ℂ E).symm.injective + exact hmul g h _ + obtain ⟨s, hs⟩ := hK.elim_finite_subcover + (fun g => weakIsometry (T g) ⁻¹' U) + (fun g => hU.preimage (WeakSpace.map (T g).toContinuousLinearEquiv.toContinuousLinearMap).continuous) hcov + obtain ⟨y, hyK, hyU⟩ := hKU + let z (g : G) : E := T g⁻¹ ((toWeakSpace ℂ E).symm y) + refine ⟨s.image z, ?_, ?_⟩ + · intro a ha + obtain ⟨g, _, rfl⟩ := Finset.mem_image.mp ha + exact ⟨weakIsometry (T g⁻¹) y, hinv g⁻¹ hyK, rfl⟩ + · intro x hx + obtain ⟨g, hgs, hxU⟩ := Set.mem_iUnion₂.mp (hs hx) + refine ⟨z g, Finset.mem_image.mpr ⟨g, hgs, rfl⟩, ?_⟩ + have hgzy : T g (z g) = (toWeakSpace ℂ E).symm y := by + dsimp [z] + rw [← hmul, mul_inv_cancel, hone] + have hd := hdiam (weakIsometry (T g) x) ⟨hinv g hx, hxU⟩ y ⟨hyK, hyU⟩ + change ‖T g ((toWeakSpace ℂ E).symm x) - (toWeakSpace ℂ E).symm y‖ < ε at hd + rwa [← hgzy, ← map_sub, (T g).norm_map] at hd + +/-- A minimal weakly compact orbit inside a norm-separable Banach space is +compact for the norm topology as well. -/ +theorem minimal_isometric_orbit_normCompact [CompleteSpace E] + (T : G → E ≃ₗᵢ[ℂ] E) + (hone : ∀ x, T 1 x = x) (hmul : ∀ g h x, T (g * h) x = T g (T h x)) + (K : Set (WeakSpace ℂ E)) (hK : IsCompact K) (hne : K.Nonempty) + (hsep : IsSeparable ((toWeakSpace ℂ E).symm '' K)) + (hinv : ∀ g, Set.MapsTo (weakIsometry (T g)) K K) + (hmin : ∀ L : Set (WeakSpace ℂ E), L ⊆ K → L.Nonempty → IsClosed L → + (∀ g, Set.MapsTo (weakIsometry (T g)) L L) → K ⊆ L) : + IsCompact ((toWeakSpace ℂ E).symm '' K) := by + have hc : IsClosed ((toWeakSpace ℂ E).symm '' K) := by + have heq : (toWeakSpace ℂ E).symm '' K = (toWeakSpace ℂ E) ⁻¹' K := by + ext x + simp only [Set.mem_image, Set.mem_preimage] + exact ⟨fun ⟨y, hy, he⟩ => he ▸ by simpa using hy, + fun hx => ⟨toWeakSpace ℂ E x, hx, rfl⟩⟩ + rw [heq] + exact hK.isClosed.preimage (toWeakSpaceCLM ℂ E).continuous + apply TotallyBounded.isCompact_of_isComplete _ hc.isComplete + apply Metric.totallyBounded_iff.mpr + intro ε hε + obtain ⟨s, _, hs⟩ := minimal_isometric_orbit_finite_net T hone hmul K hK hne hsep hinv hmin ε hε + refine ⟨s, s.finite_toSet, ?_⟩ + rintro x ⟨y, hy, rfl⟩ + obtain ⟨z, hz, hdist⟩ := hs y hy + apply Set.mem_iUnion₂.mpr + exact ⟨z, hz, by simpa only [Metric.mem_ball, dist_eq_norm] using hdist⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MinimalProjectionNorms.lean b/lean/OAI/Analysis/BoundedHochschild/MinimalProjectionNorms.lean new file mode 100644 index 0000000000000000000000000000000000000000..838253a66c34d7371d8357b5065afd845a77354b --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MinimalProjectionNorms.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.CentralRowCompression +import OAI.Analysis.BoundedHochschild.NormalInfiniteAverages + +namespace OAI + +/-! Every projection corner retains the norm of right compression in a +minimal represented averaging family. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +theorem minimal_family_projection_norm (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (F : Set (NormalGNS e →WOT[ℂ] K)) + (hclosed : IsClosed F) (hconv : Convex ℝ F) + (hinv : RepresentedRightAverageInvariant π (normalGNSRepresentation e) F) + (hmin : ∀ G : Set (NormalGNS e →WOT[ℂ] K), G ⊆ F → G.Nonempty → IsClosed G → + Convex ℝ G → RepresentedRightAverageInvariant π (normalGNSRepresentation e) G → F ⊆ G) + (W : NormalGNS e →WOT[ℂ] K) (hW : W ∈ F) {p : M} (hp : IsStarProjection p) : + ‖W.toCLM.comp (normalGNSRepresentation e p)‖ = + ‖(π p).comp (W.toCLM.comp (normalGNSRepresentation e p))‖ := by + let σ := normalGNSRepresentation e + obtain ⟨z, hz⟩ := exists_central_support e hp + obtain ⟨S, hS, ho, ht⟩ := exists_central_support_row e hp hz + obtain ⟨hm, hlim⟩ := centralSupportRow_normalized e hz.1.1 S + (fun v hv => (hS v hv).2) ho ht + let U := ContinuousLinearMapWOT.ofCLM + (infiniteRepresentedRightAverage π σ (centralSupportRow z S) hm W.toCLM) + have hU : U ∈ F := infinite_represented_average_mem_family π σ F hclosed hinv W hW + (centralSupportRow z S) hm (normalGNS_row_limit e _ hlim) + have hzcomm (a : M) : (σ z).comp (σ a) = (σ a).comp (σ z) := by + change σ z * σ a = σ a * σ z + rw [← map_mul, ← map_mul, (hz.1.2 a).eq] + have hn := compressed_norm_eq_on_minimal_family π σ F hclosed hconv hinv hmin + (1 : K →L[ℂ] K) (σ z) (fun _ => by ext; simp) hzcomm hW hU + have hn' : ‖W.toCLM.comp (σ z)‖ = ‖U.toCLM.comp (σ z)‖ := by + have hcomp (A : NormalGNS e →L[ℂ] K) : (1 : K →L[ℂ] K).comp A = A := by + ext ξ + rfl + simpa only [weakCompression, ContinuousLinearMapWOT.toCLM_comp, + ContinuousLinearMapWOT.toCLM_ofCLM, hcomp] using hn + have hle : ‖W.toCLM.comp (σ z)‖ ≤ ‖(π p).comp (W.toCLM.comp (σ p))‖ := by + rw [hn'] + exact centralSupportRow_compression_norm_le π σ hp hz.1.1 hz.2.1 S hS hm W.toCLM + have hpp : ‖(π p).comp (W.toCLM.comp (σ p))‖ ≤ ‖W.toCLM.comp (σ p)‖ := + (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_of_le_one_left (norm_nonneg _) ((hp.map π).norm_le _)) + have hpz : (σ z).comp (σ p) = σ p := by + change σ z * σ p = σ p + rw [← map_mul, (hp.le_iff_mul_eq_right hz.1.1).mp hz.2.1] + have hpz' : W.toCLM.comp (σ p) = (W.toCLM.comp (σ z)).comp (σ p) := by + rw [ContinuousLinearMap.comp_assoc, hpz] + have hpc : ‖W.toCLM.comp (σ p)‖ ≤ ‖W.toCLM.comp (σ z)‖ := by + rw [hpz'] + exact (ContinuousLinearMap.opNorm_comp_le _ _).trans + (mul_le_of_le_one_right (norm_nonneg _) ((hp.map σ).norm_le _)) + exact le_antisymm (hpc.trans hle) hpp + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MinimalRepresentedAverages.lean b/lean/OAI/Analysis/BoundedHochschild/MinimalRepresentedAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..e5a8e27742d5db1aae009d8a487e93c3e4471906 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MinimalRepresentedAverages.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.RepresentedAveragingConvexity + +namespace OAI + +/-! Minimal families for represented right averages, and constancy of +commutant-compressed norms. This is the first step of the minimal-family +argument in Paulsen, J. Funct. Anal. 157 (1998), Theorem 5.8, pp. 378–379. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +variable {M H K : Type*} [CStarAlgebra M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def RepresentedRightAverageInvariant (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (F : Set (H →WOT[ℂ] K)) : Prop := + ∀ (n : ℕ) (m : Fin n → M), (∑ i, m i * star (m i) = 1) → + Set.MapsTo (weakRepresentedRightAverage π σ m) F F + +theorem exists_minimal_represented_averages (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (σ : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (W : H →WOT[ℂ] K) : + ∃ F : Set (H →WOT[ℂ] K), F ⊆ closedRepresentedAveragingOrbit π σ W ∧ + F.Nonempty ∧ IsClosed F ∧ Convex ℝ F ∧ RepresentedRightAverageInvariant π σ F ∧ + ∀ G : Set (H →WOT[ℂ] K), G ⊆ F → G.Nonempty → IsClosed G → + Convex ℝ G → RepresentedRightAverageInvariant π σ G → F ⊆ G := by + classical + let B := closedRepresentedAveragingOrbit π σ W + have hBc : IsCompact B := closedRepresentedAveragingOrbit_isCompact π σ W + let S : Set (Set (H →WOT[ℂ] K)) := {F | F ⊆ B ∧ F.Nonempty ∧ IsClosed F ∧ + Convex ℝ F ∧ RepresentedRightAverageInvariant π σ F} + have hBS : B ∈ S := ⟨Set.Subset.rfl, + ⟨W, subset_closure (representedAveragingOrbit_self π σ W)⟩, + isClosed_closure, closedRepresentedAveragingOrbit_convex π σ W, + fun _ m hm => closedRepresentedAveragingOrbit_invariant π σ m hm W⟩ + obtain ⟨F, hFB, hF⟩ := zorn_superset_nonempty S (fun c hc hchain hcne => by + have : Nonempty c := hcne.to_subtype + have hn : (⋂₀ c).Nonempty := + IsCompact.nonempty_sInter_of_directed_nonempty_isCompact_isClosed + (fun A hA B hB => by + rcases hchain.total hA hB with h | h + · exact ⟨A, hA, Set.Subset.rfl, h⟩ + · exact ⟨B, hB, h, Set.Subset.rfl⟩) + (fun A hA => (hc hA).2.1) + (fun A hA => hBc.of_isClosed_subset (hc hA).2.2.1 (hc hA).1) + (fun A hA => (hc hA).2.2.1) + refine ⟨⋂₀ c, ⟨?_, hn, ?_, ?_, ?_⟩, fun A hA => Set.sInter_subset_of_mem hA⟩ + · obtain ⟨A, hA⟩ := hcne + exact (Set.sInter_subset_of_mem hA).trans (hc hA).1 + · exact isClosed_sInter (fun A hA => (hc hA).2.2.1) + · intro x hx y hy r s hr hs hrs + apply Set.mem_sInter.mpr + intro A hA + exact (hc hA).2.2.2.1 (Set.mem_sInter.mp hx A hA) + (Set.mem_sInter.mp hy A hA) hr hs hrs + · intro n m hm x hx + apply Set.mem_sInter.mpr + intro A hA + exact (hc hA).2.2.2.2 n m hm (Set.mem_sInter.mp hx A hA)) B hBS + exact ⟨F, hFB, hF.1.2.1, hF.1.2.2.1, hF.1.2.2.2.1, hF.1.2.2.2.2, + fun G hGF hGn hGc hGv hGi => hF.2 ⟨hGF.trans hFB, hGn, hGc, hGv, hGi⟩ hGF⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MinimalRightAverages.lean b/lean/OAI/Analysis/BoundedHochschild/MinimalRightAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..710774d03dd5cb1b0678c24bb7d015924908900e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MinimalRightAverages.lean @@ -0,0 +1,74 @@ +import OAI.Analysis.BoundedHochschild.RightAveragingOrbit + +namespace OAI + +/-! A minimal compact convex invariant family of right averages. The proof +uses the finite intersection property and does not presume a fixed point. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Invariance under every finite normalized right average. -/ +def RightAverageInvariant (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (K : Set (M → WeakDual ℂ X)) : Prop := + ∀ (n : ℕ) (m : Fin n → M), (∑ i, m i * star (m i) = 1) → + Set.MapsTo (weakRightAverage e m) K K + +/-- The averaging orbit contains a minimal nonempty closed convex invariant +subset. The separate module-map step must still show that it is a singleton. -/ +theorem exists_minimal_right_averages (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hno : NoFiniteCentralSummand M) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : + ∃ K : Set (M → WeakDual ℂ X), K ⊆ weakRightAverageOrbit e T ∧ + K.Nonempty ∧ IsClosed K ∧ Convex ℝ K ∧ RightAverageInvariant e K ∧ + ∀ L : Set (M → WeakDual ℂ X), L ⊆ K → L.Nonempty → IsClosed L → + Convex ℝ L → RightAverageInvariant e L → K ⊆ L := by + classical + let B := weakRightAverageOrbit e T + have hBc : IsCompact B := weakRightAverageOrbit_isCompact e hno T hT + let S : Set (Set (M → WeakDual ℂ X)) := + {K | K ⊆ B ∧ K.Nonempty ∧ IsClosed K ∧ Convex ℝ K ∧ RightAverageInvariant e K} + have hBS : B ∈ S := ⟨Set.Subset.rfl, weakRightAverageOrbit_nonempty e T, + isClosed_closure, weakRightAverageOrbit_convex e T, + fun _ m hm => weakRightAverageOrbit_invariant e m hm T⟩ + obtain ⟨K, hKB, hK⟩ := zorn_superset_nonempty S (fun c hc hchain hcne => by + have : Nonempty c := hcne.to_subtype + have hn : (⋂₀ c).Nonempty := + IsCompact.nonempty_sInter_of_directed_nonempty_isCompact_isClosed + (fun L hL J hJ => by + rcases hchain.total hL hJ with h | h + · exact ⟨L, hL, Set.Subset.rfl, h⟩ + · exact ⟨J, hJ, h, Set.Subset.rfl⟩) + (fun L hL => (hc hL).2.1) + (fun L hL => hBc.of_isClosed_subset (hc hL).2.2.1 (hc hL).1) + (fun L hL => (hc hL).2.2.1) + refine ⟨⋂₀ c, ⟨?_, hn, ?_, ?_, ?_⟩, fun L hL => Set.sInter_subset_of_mem hL⟩ + · obtain ⟨L, hL⟩ := hcne + exact (Set.sInter_subset_of_mem hL).trans (hc hL).1 + · exact isClosed_sInter (fun L hL => (hc hL).2.2.1) + · intro x hx y hy r s hr hs hrs + apply Set.mem_sInter.mpr + intro L hL + exact (hc hL).2.2.2.1 (Set.mem_sInter.mp hx L hL) + (Set.mem_sInter.mp hy L hL) hr hs hrs + · intro n m hm x hx + apply Set.mem_sInter.mpr + intro L hL + exact (hc hL).2.2.2.2 n m hm (Set.mem_sInter.mp hx L hL)) B hBS + refine ⟨K, hKB, hK.1.2.1, hK.1.2.2.1, hK.1.2.2.2.1, hK.1.2.2.2.2, ?_⟩ + intro L hLK hLn hLc hLv hLi + exact hK.2 ⟨hLK.trans hKB, hLn, hLc, hLv, hLi⟩ hLK + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MixedWords.lean b/lean/OAI/Analysis/BoundedHochschild/MixedWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..9a1dcbb5fccee0a09ae43bc8039685830bc85c9f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MixedWords.lean @@ -0,0 +1,408 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PartialUnitaries +import OAI.Analysis.BoundedHochschild.ProductTaylor + +namespace OAI + +/-! Mixed-word Taylor expansions, moment corners and patch coefficients. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M : Type*} [CStarAlgebra M] + + +def wordProduct {J : Type*} (ρ : J → M) : List (J × M) → M + | [] => 1 + | (k,a)::l => ρ k*a*wordProduct ρ l +@[simp] lemma wordProduct_nil {J : Type*} (ρ : J → M) : wordProduct ρ []=1 := rfl +@[simp] lemma wordProduct_cons {J : Type*} (ρ : J → M) (k : J) (a : M) (l : List (J × M)) : + wordProduct ρ ((k,a)::l)=ρ k*a*wordProduct ρ l := rfl +lemma wordProduct_append {J : Type*} (ρ : J → M) (l r : List (J × M)) : + wordProduct ρ (l++r)=wordProduct ρ l*wordProduct ρ r := by + induction l with + | nil => simp + | cons ka l ih => rcases ka with ⟨k,a⟩; simp only [List.cons_append,wordProduct_cons,ih,mul_assoc] +lemma norm_wordProduct_le_one {J : Type*} (ρ : J → M) (hρ : ∀ k, ‖ρ k‖ ≤ 1) + (l : List (J × M)) (hl : ∀ ka ∈ l, ‖ka.2‖ ≤ 1) : ‖wordProduct ρ l‖ ≤ 1 := by + induction l with + | nil => exact IsStarProjection.norm_le (1 : M) (IsStarProjection.one M) + | cons ka l ih => + rcases ka with ⟨k,a⟩ + have ha := hl (k,a) (List.mem_cons_self ..) + have ht := ih (fun ka hk => hl ka (List.mem_cons_of_mem _ hk)) + exact (norm_mul_le_of_le (norm_mul_le_of_le (hρ k) ha) ht).trans_eq (by simp) + +variable {I : Type*} (F : I → M) +def wordCoeff : Option I → M | none => 1 | some i => F i +@[simp] lemma wordCoeff_none : wordCoeff F none=1 := rfl +@[simp] lemma wordCoeff_some (i : I) : wordCoeff F (some i)=F i := rfl +lemma norm_wordCoeff (hF : ∀ i, ‖F i‖ ≤ 1) (a : Option I) : ‖wordCoeff F a‖ ≤ 1 := by + cases a with + | none => exact IsStarProjection.norm_le (1 : M) (IsStarProjection.one M) + | some i => exact hF i +abbrev WordAtom (I : Type*) (K : ℕ) := (Bool × Fin K) × Option I +abbrev BoundedWord (I : Type*) (K N : ℕ) := Option I × {l : List (WordAtom I K) // l.length ≤ N} +instance [Finite I] (K N : ℕ) : Finite (BoundedWord I K N) := by + let : Finite {l : List (WordAtom I K) // l.length ≤ N} := (List.finite_length_le (WordAtom I K) N).to_subtype + infer_instance +instance [Finite I] (K N : ℕ) : Fintype (BoundedWord I K N) := Fintype.ofFinite _ + +def admissibleTail {K : ℕ} (l : List (WordAtom I K)) : Prop := + l ≠ [] ∧ ∀ ka ∈ l.dropLast, ka.2 ≠ none + +def evaluatedTail {K : ℕ} (l : List (WordAtom I K)) : List ((Bool × ℕ) × M) := + l.map (fun ka => ((ka.1.1,ka.1.2.val),wordCoeff F ka.2)) +def mixedEval {K : ℕ} (v : PartialUnitary M) (a : Option I) (l : List (WordAtom I K)) : M := + wordCoeff F a*wordProduct v.power (evaluatedTail F l) +lemma norm_mixedEval {K : ℕ} (hF : ∀ i, ‖F i‖ ≤ 1) (v : PartialUnitary M) + (a : Option I) (l : List (WordAtom I K)) : ‖mixedEval F v a l‖ ≤ 1 := by + apply (norm_mul_le_of_le (norm_wordCoeff F hF a) (norm_wordProduct_le_one _ v.norm_power_le_one _ ?_)).trans_eq (one_mul 1) + rintro ka hk + obtain ⟨kb,hkb,rfl⟩ := List.mem_map.mp hk + exact norm_wordCoeff F hF kb.2 + +variable [PartialOrder M] [StarOrderedRing M] +variable (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) +include htr in +lemma wordProduct_tendsto {J L : Type*} {f : Filter L} (ρ : L → J → M) (σ : J → M) + (hρ : ∀ k, GNSTendsto τ (fun i => ρ i k) f (σ k)) + (hbn : ∀ i k, ‖ρ i k‖ ≤ 1) (l : List (J × M)) : + GNSTendsto τ (fun i => wordProduct (ρ i) l) f (wordProduct σ l) := by + induction l with + | nil => exact GNSTendsto.const τ 1 f + | cons ka l ih => + obtain ⟨k,a⟩ := ka + apply GNSTendsto.mul τ htr ((hρ k).mul τ htr (GNSTendsto.const τ a f) 1 (fun i => hbn i k)) ih ‖a‖ + intro i + simpa only [one_mul] using norm_mul_le_of_le (hbn i k) (le_refl ‖a‖) +include htr in +lemma mixedEval_tendsto {K : Type*} {r : ℕ} {f : Filter K} + {v : K → PartialUnitary M} {w : PartialUnitary M} + (h : GNSTendsto τ (fun i => (v i : M)) f (w : M)) + (a : Option I) (l : List (WordAtom I r)) : + GNSTendsto τ (fun i => mixedEval F (v i) a l) f (mixedEval F w a l) := by + apply GNSTendsto.mul τ htr (GNSTendsto.const τ (wordCoeff F a) f) _ ‖wordCoeff F a‖ (fun _ => le_rfl) + exact wordProduct_tendsto τ htr (fun i => (v i).power) w.power + (fun k => PartialUnitary.power_tendsto τ htr h k) (fun i k => (v i).norm_power_le_one k) _ + +lemma trace_tendsto_of_gns (h1 : τ 1=1) {J : Type*} {f : Filter J} {x : J → M} {y : M} + (h : GNSTendsto τ x f y) : Tendsto (fun i => τ (x i)) f (𝓝 (τ y)) := by + apply tendsto_iff_norm_sub_tendsto_zero.mpr + apply squeeze_zero (fun _ => norm_nonneg _) _ h + intro i + rw [← map_sub] + exact HochschildUltrapower.norm_trace_le τ h1 _ + + +def MomentBound {K N : ℕ} (b : ℝ → ℝ) (v : PartialUnitary M) : Prop := + ∀ w : BoundedWord I K N, admissibleTail w.2.val → + ‖τ (mixedEval F v w.1 w.2.val)‖ ≤ b ((τ v.support).re) + +include htr in +lemma momentBound_limit {K N : ℕ} {b : ℝ → ℝ} {v : ℕ → PartialUnitary M} {w : PartialUnitary M} + (h1 : τ 1=1) (h : GNSTendsto τ (fun i => (v i : M)) atTop (w : M)) + (hb : ContinuousAt b ((τ w.support).re)) + (hv : ∀ i, MomentBound F τ (K := K) (N := N) b (v i)) : + MomentBound F τ (K := K) (N := N) b w := by + intro a ha + have he := trace_tendsto_of_gns τ h1 (mixedEval_tendsto F τ htr h a.1 a.2.val) + have hs := (h.star τ htr).mul τ htr h 1 (fun i => by simpa only [norm_star] using (v i).norm_le_one) + have hst := (Complex.continuous_re.tendsto _).comp (trace_tendsto_of_gns τ h1 hs) + exact le_of_tendsto_of_tendsto he.norm (hb.tendsto.comp hst) (Filter.Eventually.of_forall (fun i => hv i a ha)) +end HochschildPatching + + + + + +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +namespace ProductTaylor +variable {A R : Type*} [Ring R] +lemma mem_linearTerms_map (f : A → R × R) {l : List A} {x : R} + (hx : x ∈ linearTerms (l.map f)) : + ∃ pre a post, l=pre++a::post ∧ x=oldProduct (pre.map f)*(f a).2*oldProduct (post.map f) := by + obtain ⟨p,b,t,he,hx⟩ := mem_linearTerms hx + obtain ⟨pre,rest,hr,hp,ht⟩ := List.map_eq_append_iff.mp he + obtain ⟨a,post,hs,ha,hpost⟩ := List.map_eq_cons_iff.mp ht + exact ⟨pre,a,post,by rw [hr,hs],by rw [hp,ha,hpost]; exact hx⟩ +lemma mem_quadraticTerms_map (f : A → R × R) {l : List A} {x : R} + (hx : x ∈ quadraticTerms (l.map f)) : + ∃ pre a middle b post, l=pre++a::(middle++b::post) ∧ + x=oldProduct (pre.map f)*(f a).2*oldProduct (middle.map f)*(f b).2*totalProduct (post.map f) := by + obtain ⟨p,a,m,b,t,he,hx⟩ := mem_quadraticTerms hx + obtain ⟨pre,rest,hr,hp,ht⟩ := List.map_eq_append_iff.mp he + obtain ⟨aa,rest2,hs,ha,ht2⟩ := List.map_eq_cons_iff.mp ht + obtain ⟨mid,rest3,hr2,hm,ht3⟩ := List.map_eq_append_iff.mp ht2 + obtain ⟨bb,post,hs2,hb,hpost⟩ := List.map_eq_cons_iff.mp ht3 + exact ⟨pre,aa,mid,bb,post,by rw [hr,hs,hr2,hs2],by rw [hp,ha,hm,hb,hpost]; exact hx⟩ +end ProductTaylor + +variable {M : Type*} [CStarAlgebra M] +variable {I : Type*} (F : I → M) +def atomPower {K : ℕ} (v : PartialUnitary M) (a : WordAtom I K) : M := v.power (a.1.1,a.1.2.val) +def splitFactor {K : ℕ} (v w : PartialUnitary M) (a : WordAtom I K) : M × M := + (atomPower v a*wordCoeff F a.2,atomPower w a*wordCoeff F a.2) +lemma oldProduct_split {K : ℕ} (v w : PartialUnitary M) (l : List (WordAtom I K)) : + ProductTaylor.oldProduct (l.map (splitFactor F v w))=wordProduct v.power (evaluatedTail F l) := by + induction l with + | nil => rfl + | cons a l ih => simp only [List.map_cons,ProductTaylor.old_cons,evaluatedTail,wordProduct_cons,splitFactor,atomPower] at *; rw [ih] +lemma totalProduct_split {K : ℕ} (v w : PartialUnitary M) (h : v.support*w.support=0) (l : List (WordAtom I K)) : + ProductTaylor.totalProduct (l.map (splitFactor F v w))=wordProduct (v.orthogonalSum w h).power (evaluatedTail F l) := by + induction l with + | nil => rfl + | cons a l ih => + simp only [List.map_cons,ProductTaylor.total_cons,evaluatedTail,wordProduct_cons,splitFactor,atomPower] at * + rw [ih,PartialUnitary.power_orthogonalSum] + simp only [add_mul] +lemma mixedEval_split {K : ℕ} (v w : PartialUnitary M) (h : v.support*w.support=0) (a : Option I) (l : List (WordAtom I K)) : + mixedEval F (v.orthogonalSum w h) a l=mixedEval F v a l+ + wordCoeff F a*(ProductTaylor.linearTerms (l.map (splitFactor F v w))).sum+ + wordCoeff F a*(ProductTaylor.quadraticTerms (l.map (splitFactor F v w))).sum := by + rw [mixedEval,← totalProduct_split F v w h,ProductTaylor.total_eq_old_add_linear_add_quadratic, + mul_add,mul_add,oldProduct_split] + rfl + +lemma admissible_middle {K : ℕ} {l pre middle post : List (WordAtom I K)} {a b : WordAtom I K} + (hl : admissibleTail l) (he : l=pre++a::(middle++b::post)) : + a.2 ≠ none ∧ ∀ c ∈ middle, c.2 ≠ none := by + have hsub : ∀ c ∈ pre++a::middle, c.2 ≠ none := by + intro c hc + apply hl.2 c + have he' : l=(pre++a::middle)++b::post := by rw [he]; simp only [List.append_assoc,List.cons_append] + rw [he',List.dropLast_append_of_ne_nil (List.cons_ne_nil _ _)] + exact List.mem_append_left _ hc + exact ⟨hsub a (List.mem_append_right _ (List.mem_cons_self ..)),fun c hc => + hsub c (List.mem_append_right _ (List.mem_cons_of_mem _ hc))⟩ + +variable [PartialOrder M] (τ : M →ₚ[ℂ] ℂ) +lemma trace_list_sum_bound (A : M) (l : List M) (c : ℝ) + (h : ∀ x ∈ l, ‖τ (A*x)‖ ≤ c) : ‖τ (A*l.sum)‖ ≤ (l.length : ℝ)*c := by + induction l with + | nil => simp + | cons x l ih => + rw [List.sum_cons,mul_add,map_add,List.length_cons,Nat.cast_add,Nat.cast_one,add_mul,one_mul] + exact (norm_add_le _ _).trans ((add_le_add (h x (List.mem_cons_self ..)) + (ih (fun y hy => h y (List.mem_cons_of_mem _ hy)))).trans_eq (add_comm _ _)) + +lemma mixedEval_patch_bound {K N : ℕ} (v w : PartialUnitary M) (h : v.support*w.support=0) + (a : Option I) (l : List (WordAtom I K)) (hlen : l.length ≤ N) {c d : ℝ} (hc : 0 ≤ c) (hd : 0 ≤ d) + (hlin : ∀ x ∈ ProductTaylor.linearTerms (l.map (splitFactor F v w)), ‖τ (wordCoeff F a*x)‖ ≤ c) + (hquad : ∀ x ∈ ProductTaylor.quadraticTerms (l.map (splitFactor F v w)), ‖τ (wordCoeff F a*x)‖ ≤ d) : + ‖τ (mixedEval F (v.orthogonalSum w h) a l)‖ ≤ ‖τ (mixedEval F v a l)‖+(N : ℝ)*c+(N : ℝ)^2*d := by + rw [mixedEval_split,map_add,map_add] + apply (norm_add_le _ _).trans + apply add_le_add + · apply (norm_add_le _ _).trans + apply add_le_add le_rfl + apply (trace_list_sum_bound τ _ _ _ hlin).trans + rw [ProductTaylor.linearTerms_length,List.length_map] + exact mul_le_mul_of_nonneg_right (by exact_mod_cast hlen) hc + · apply (trace_list_sum_bound τ _ _ _ hquad).trans + apply mul_le_mul_of_nonneg_right _ hd + have hn := ProductTaylor.quadraticTerms_length_le (l.map (splitFactor F v w)) + rw [List.length_map] at hn + exact_mod_cast hn.trans (Nat.pow_le_pow_left hlen 2) +end HochschildPatching + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] +variable {I : Type*} (F : I → M) (τ : M →ₚ[ℂ] ℂ) + +lemma centered_word_bound {K N : ℕ} {b : ℝ → ℝ} {v : PartialUnitary M} + (hF : ∀ i, τ (F i)=0) (hb : 0 ≤ b ((τ v.support).re)) + (hv : MomentBound F τ (K := K) (N := N) b v) + (i : I) (l : List (WordAtom I K)) (hl : ∀ a ∈ l, a.2 ≠ none) (hn : l.length ≤ N) : + ‖τ (mixedEval F v (some i) l)‖ ≤ b ((τ v.support).re) := by + by_cases he : l=[] + · subst l + simpa only [mixedEval,evaluatedTail,List.map_nil,wordProduct_nil,mul_one,wordCoeff_some,hF,norm_zero] using hb + · exact hv (some i,⟨l,hn⟩) ⟨he,fun a ha => hl a (List.mem_of_mem_dropLast ha)⟩ + +omit [PartialOrder M] in +lemma support_wrapped_eval {K : ℕ} (hK : 0 exact (hl rfl).elim + | cons ka l => + rcases ka with ⟨⟨s,k⟩,j⟩ + simp only [mixedEval,evaluatedTail,List.map_cons,wordProduct_cons,PartialUnitary.power,PartialUnitary.coe_zero,star_zero,ite_self,zero_pow (Nat.succ_ne_zero _),zero_mul,mul_zero] +lemma momentBound_zero {K N : ℕ} {b : ℝ → ℝ} (hb : 0 ≤ b 0) : + MomentBound F τ (K := K) (N := N) b 0 := by + intro w hw + rw [mixedEval_zero F _ _ hw.1,map_zero,norm_zero,PartialUnitary.support_zero,map_zero,Complex.zero_re] + exact hb +end HochschildPatching + + + + + +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity HochschildComparison +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {I : Type*} (F : I → M) +abbrev ShortTail (I : Type*) (K N : ℕ) := {l : List (WordAtom I K) // l.length ≤ N} +abbrev LinearLabel (I : Type*) (K N : ℕ) := Option I × ShortTail I K N × WordAtom I K × ShortTail I K N +instance [Finite I] (K N : ℕ) : Finite (LinearLabel I K N) := by + let : Finite (ShortTail I K N) := (List.finite_length_le (WordAtom I K) N).to_subtype + infer_instance +instance [Finite I] (K N : ℕ) : Fintype (LinearLabel I K N) := Fintype.ofFinite _ +def linearCoeff {K N : ℕ} (v : PartialUnitary M) (a : LinearLabel I K N) : M := + wordCoeff F a.2.2.1.2 * wordProduct v.power (evaluatedTail F a.2.2.2.val) * + mixedEval F v a.1 a.2.1.val +def linearPower {K N : ℕ} (a : LinearLabel I K N) : Bool × ℕ := (a.2.2.1.1.1,a.2.2.1.1.2.val) + +variable (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) +omit [StarOrderedRing M] in +include htr in +lemma linear_trace_bound {K N : ℕ} (v w : PartialUnitary M) (a : Option I) + (l : List (WordAtom I K)) (hlen : l.length ≤ N) (c : ℝ) + (hweak : ∀ j : LinearLabel I K N, ‖τ (linearCoeff F v j*w.power (linearPower j))‖ ≤ c) + (x : M) (hx : x ∈ ProductTaylor.linearTerms (l.map (splitFactor F v w))) : + ‖τ (wordCoeff F a*x)‖ ≤ c := by + obtain ⟨pre,b,post,he,rfl⟩ := ProductTaylor.mem_linearTerms_map _ hx + have hn := hlen + rw [he,List.length_append,List.length_cons] at hn + let j : LinearLabel I K N := (a,⟨pre,by omega⟩,b,⟨post,by omega⟩) + have hh := hweak j + have ht : τ (wordCoeff F a*(ProductTaylor.oldProduct (pre.map (splitFactor F v w))* + (splitFactor F v w b).2*ProductTaylor.oldProduct (post.map (splitFactor F v w))))= + τ (linearCoeff F v j*w.power (linearPower j)) := by + simp only [oldProduct_split,splitFactor,linearCoeff,linearPower,mixedEval,atomPower,j] + rw [show wordCoeff F a*(wordProduct v.power (evaluatedTail F pre)* + (w.power (b.1.1,b.1.2.val)*wordCoeff F b.2)*wordProduct v.power (evaluatedTail F post))= + (wordCoeff F a*wordProduct v.power (evaluatedTail F pre)*w.power (b.1.1,b.1.2.val))* + (wordCoeff F b.2*wordProduct v.power (evaluatedTail F post)) by simp only [mul_assoc],htr] + simp only [mul_assoc] + rw [ht] + exact hh + +def residualScalar (v : PartialUnitary M) (z : M) : ℂ := + (((τ (1-v.support)).re : ℂ)⁻¹)*τ ((1-v.support)*z*(1-v.support)) +omit [StarOrderedRing M] in +include htr in +lemma residualScalar_bound {K N : ℕ} {b : ℝ → ℝ} {v : PartialUnitary M} + (hF : ∀ i, τ (F i)=0) (hb : 0 ≤ b ((τ v.support).re)) + (hv : MomentBound F τ (K := K) (N := N) b v) (hK : 0 max 0 (t-c) + have hf : Continuous f := by fun_prop + let x : A := cfc f a + have hsa : IsSelfAdjoint a := .of_nonneg ha + have hsx : IsSelfAdjoint x := cfc_predicate f a + have hineq (n : ℕ) : c^n • (star x*x) ≤ ‖a‖^2 • a^n := by + have hleft : cfc (fun t => c^n * (f t * f t)) a = c^n • (star x*x) := by + rw [cfc_const_mul (c^n) (fun t => f t * f t) a (hf.mul hf).continuousOn, + cfc_mul f f a hf.continuousOn hf.continuousOn, hsx.star_eq] + have hright : cfc (fun t : ℝ => ‖a‖^2 * t^n) a = ‖a‖^2 • a^n := by + rw [cfc_const_mul (‖a‖^2) (fun t : ℝ => t^n) a (continuous_id.pow n).continuousOn, + cfc_pow_id a n hsa] + rw [← hleft, ← hright] + apply (cfc_le_iff _ _ a ((hf.mul hf).const_mul _).continuousOn + ((continuous_id.pow n).const_mul _).continuousOn hsa).mpr + intro t ht + change c^n * (f t * f t) ≤ ‖a‖^2 * t^n + have ht0 : 0 ≤ t := spectrum_nonneg_of_nonneg ha ht + have htA : t ≤ ‖a‖ := (le_abs_self t).trans (spectrum.norm_le_norm_of_mem ht) + by_cases htc : t ≤ c + · simp only [f, max_eq_left (sub_nonpos.mpr htc), mul_zero] + positivity + · have hct : c ≤ t := le_of_lt (lt_of_not_ge htc) + simp only [f, max_eq_right (sub_nonneg.mpr hct)] + have hfA : (t-c)*(t-c) ≤ ‖a‖^2 := by nlinarith [norm_nonneg a] + calc + _ ≤ t^n * ‖a‖^2 := mul_le_mul (pow_le_pow_left₀ hc.le hct n) hfA + (mul_self_nonneg _) (pow_nonneg ht0 _) + _ = _ := by ring + have hxtrace : 0 ≤ (τ (star x*x)).re := by + exact (τ.map_nonneg (star_mul_self_nonneg x)).1 + have htrace (n : ℕ) : (τ (star x*x)).re ≤ ‖a‖^2 * (R/c)^n := by + have hh := τ.monotone (hineq n) + change τ (c^n • (star x*x)) ≤ τ (‖a‖^2 • a^n) at hh + rw [τ.map_smul_of_tower, τ.map_smul_of_tower] at hh + have hre : c^n * (τ (star x*x)).re ≤ ‖a‖^2 * (τ (a^n)).re := by simpa only [Complex.smul_re, smul_eq_mul] using hh.1 + apply (mul_le_mul_iff_right₀ (pow_pos hc n)).mp + calc + _ = c^n * (τ (star x*x)).re := by ring + _ ≤ ‖a‖^2 * (τ (a^n)).re := hre + _ ≤ ‖a‖^2 * R^n := mul_le_mul_of_nonneg_left (hbound n) (sq_nonneg _) + _ = (‖a‖^2 * (R/c)^n) * c^n := by + rw [div_pow, mul_assoc, div_mul_cancel₀ _ (ne_of_gt (pow_pos hc n))] + _ = c^n * (‖a‖^2 * (R/c)^n) := by ring + have hlim : Tendsto (fun n : ℕ => ‖a‖^2 * (R/c)^n) atTop (𝓝 0) := by + convert (tendsto_pow_atTop_nhds_zero_of_lt_one (div_nonneg hR hc.le) + ((div_lt_one hc).mpr hRc)).const_mul (‖a‖^2) using 1; simp + have hzre : (τ (star x*x)).re = 0 := le_antisymm (ge_of_tendsto' hlim htrace) hxtrace + have hz : τ (star x*x) = 0 := by + have hp := τ.map_nonneg (star_mul_self_nonneg x) + exact Complex.ext hzre hp.2.symm + have hx : x = 0 := hfaithful x hz + have heq : cfc f a = cfc (fun _ : ℝ => 0) a := by simpa only [cfc_const_zero] using hx + have hxnorm := eqOn_of_cfc_eq_cfc heq hf.continuousOn continuousOn_const hsa + (CStarAlgebra.norm_mem_spectrum_of_nonneg a ha) + dsimp [f] at hxnorm + have : 0 < max 0 (‖a‖-c) := lt_max_of_lt_right (sub_pos.mpr hca) + linarith + +lemma positive_moment_le_norm_pow (τ : A →ₚ[ℂ] ℂ) (hτ : τ 1 = 1) + (a : A) (ha : 0 ≤ a) (n : ℕ) : (τ (a^n)).re ≤ ‖a‖^n := by + have : Nontrivial A := nontrivial_of_ne (1 : A) 0 (by + intro h; have := hτ; rw [h, map_zero] at this; exact zero_ne_one this) + calc + _ ≤ ‖τ (a^n)‖ := Complex.re_le_norm _ + _ ≤ ‖τ 1‖ * ‖a^n‖ := τ.norm_apply_le_of_nonneg _ (CStarAlgebra.pow_nonneg a n ha) + _ ≤ ‖a‖^n := by simpa [hτ] using norm_pow_le a n + +variable {B : Type*} [CStarAlgebra B] [PartialOrder B] [StarOrderedRing B] + + +theorem norm_eq_of_positive_moments + (τ : A →ₚ[ℂ] ℂ) (ρ : B →ₚ[ℂ] ℂ) (hτ : τ 1 = 1) (hρ : ρ 1 = 1) + (hτf : ∀ x : A, τ (star x*x)=0 → x=0) + (hρf : ∀ x : B, ρ (star x*x)=0 → x=0) + (a : A) (ha : 0 ≤ a) (b : B) (hb : 0 ≤ b) + (hm : ∀ n : ℕ, τ (a^n) = ρ (b^n)) : ‖a‖ = ‖b‖ := by + apply le_antisymm + · apply norm_le_of_positive_moment_bound τ hτf a ha ‖b‖ (norm_nonneg _) + intro n + rw [hm] + exact positive_moment_le_norm_pow ρ hρ b hb n + · apply norm_le_of_positive_moment_bound ρ hρf b hb ‖a‖ (norm_nonneg _) + intro n + rw [← hm] + exact positive_moment_le_norm_pow τ hτ a ha n + + +theorem norm_eq_of_star_mul_moments + (τ : A →ₚ[ℂ] ℂ) (ρ : B →ₚ[ℂ] ℂ) (hτ : τ 1 = 1) (hρ : ρ 1 = 1) + (hτf : ∀ x : A, τ (star x*x)=0 → x=0) + (hρf : ∀ x : B, ρ (star x*x)=0 → x=0) + (a : A) (b : B) + (hm : ∀ n : ℕ, τ ((star a*a)^n) = ρ ((star b*b)^n)) : ‖a‖ = ‖b‖ := by + have h := norm_eq_of_positive_moments τ ρ hτ hρ hτf hρf + (star a*a) (star_mul_self_nonneg _) (star b*b) (star_mul_self_nonneg _) hm + rw [CStarRing.norm_star_mul_self, CStarRing.norm_star_mul_self] at h + nlinarith [norm_nonneg a, norm_nonneg b] +end HochschildMoments +namespace HochschildFreeWords +open FreeGroup +variable {α : Type*} + + +theorem boundary_decomposition (v w : List (α × Bool)) + (hv : IsReduced v) (hw : IsReduced w) : + ∃ u c h, v = u ++ c ∧ w = invRev c ++ h ∧ IsReduced (u ++ h) := by + induction v using List.reverseRecOn generalizing w with + | nil => exact ⟨[], [], w, rfl, rfl, hw⟩ + | @append_singleton v a ih => + cases w with + | nil => exact ⟨v ++ [a], [], [], by simp, rfl, by simpa using hv⟩ + | cons b w => + by_cases hab : a.1 = b.1 ∧ a.2 = !b.2 + · have hv' : IsReduced v := hv.left_of_append + have hw' : IsReduced w := hw.tail + obtain ⟨u,c,h,hu,hc,hr⟩ := ih w hv' hw' + refine ⟨u, c ++ [a], h, ?_, ?_, hr⟩ + · simp only [hu, List.append_assoc] + · have hba : (a.1, !a.2) = b := by + apply Prod.ext + · exact hab.1 + · simp [hab.2] + have hinv : invRev [a] = [b] := by + simp [invRev, hba] + rw [invRev_append, hinv] + simpa using congrArg (fun l => b :: l) hc + · refine ⟨v ++ [a], [], b::w, by simp, rfl, ?_⟩ + change List.IsChain _ _ + rw [List.append_assoc, List.singleton_append, List.isChain_append_cons_cons] + refine ⟨hv, ?_, hw⟩ + intro hfst + have hh : a.2 ≠ !b.2 := fun h => hab ⟨hfst,h⟩ + cases ha : a.2 <;> cases hb : b.2 <;> simp_all + +variable [DecidableEq α] + +theorem boundary_reduction (v w : List (α × Bool)) + (hv : IsReduced v) (hw : IsReduced w) : + ∃ u c h, v = u ++ c ∧ w = invRev c ++ h ∧ + reduce (v ++ w) = u ++ h ∧ IsReduced (u ++ h) := by + obtain ⟨u,c,h,hu,hw,hr⟩ := boundary_decomposition v w hv hw + refine ⟨u,c,h,hu,hw,?_,hr⟩ + have heq : FreeGroup.mk (v ++ w) = FreeGroup.mk (u ++ h) := by + rw [hu,hw] + simp only [← FreeGroup.mul_mk, ← FreeGroup.inv_mk] + group + have heq' := congr_arg FreeGroup.toWord heq + simpa only [FreeGroup.toWord_mk, hr.reduce_eq] using heq' +end HochschildFreeWords + + + +namespace HochschildLength +open Finset +noncomputable section + +abbrev Vector (ι : Type*) := lp (fun _ : ι => ℂ) 2 + +lemma norm_sum_single_sq {ι κ : Type*} [DecidableEq κ] (s : Finset ι) (out : ι → κ) + (c : ι → ℂ) (hinj : Set.InjOn out s) : + ‖∑ i ∈ s, (lp.single 2 (out i) (c i) : Vector κ)‖ ^ 2 = ∑ i ∈ s, ‖c i‖ ^ 2 := by + classical + have hi : inner ℂ (∑ i ∈ s, (lp.single 2 (out i) (c i) : Vector κ)) + (∑ i ∈ s, (lp.single 2 (out i) (c i) : Vector κ)) = + ∑ i ∈ s, (‖c i‖ : ℂ) ^ 2 := by + rw [sum_inner] + apply sum_congr rfl + intro i hi + rw [inner_sum] + rw [sum_eq_single i] + · simp [inner_self_eq_norm_sq_to_K] + · intro j hj hji + rw [lp.inner_single_left, lp.single_apply_ne] + · exact inner_zero_right _ + · exact fun h => hji (hinj hj hi h.symm) + · exact fun h => (h hi).elim + apply Complex.ofReal_injective + simpa [inner_self_eq_norm_sq_to_K, Complex.ofReal_sum, Complex.ofReal_pow] using hi + +lemma norm_sum_mul_sq_le {ι : Type*} (s : Finset ι) (a b : ι → ℂ) : + ‖∑ i ∈ s, a i * b i‖ ^ 2 ≤ + (∑ i ∈ s, ‖a i‖ ^ 2) * ∑ i ∈ s, ‖b i‖ ^ 2 := by + have h := norm_sum_le s (fun i => a i * b i) + simp only [norm_mul] at h + exact (pow_le_pow_left₀ (norm_nonneg _) h 2).trans + (sum_mul_sq_le_sq_mul_sq s (fun i => ‖a i‖) (fun i => ‖b i‖)) + + + +lemma block_matrix_bound {U V H : Type*} (su : Finset U) (sv : Finset V) + (sh : Finset H) (a : U → V → ℂ) (b : V → H → ℂ) : + ∑ h ∈ sh, ∑ u ∈ su, ‖∑ v ∈ sv, a u v * b v h‖ ^ 2 ≤ + (∑ u ∈ su, ∑ v ∈ sv, ‖a u v‖ ^ 2) * + (∑ h ∈ sh, ∑ v ∈ sv, ‖b v h‖ ^ 2) := by + calc + _ ≤ ∑ h ∈ sh, ∑ u ∈ su, + (∑ v ∈ sv, ‖a u v‖ ^ 2) * (∑ v ∈ sv, ‖b v h‖ ^ 2) := by + gcongr with h hh u hu + exact norm_sum_mul_sq_le sv _ _ + _ = _ := by simp_rw [← sum_mul, ← mul_sum] + + + +lemma masked_block_matrix_bound {U V H W : Type*} [DecidableEq W] + (su : Finset U) (sv : Finset V) (sh : Finset H) + (a : U → V → ℂ) (b : V → H → ℂ) (P : U → H → Prop) [∀ u h, Decidable (P u h)] + (out : U → H → W) + (hinj : Set.InjOn (fun p : H × U => out p.2 p.1) + {p | p.1 ∈ sh ∧ p.2 ∈ su ∧ P p.2 p.1}) : + ‖∑ p ∈ (sh ×ˢ su).filter (fun p => P p.2 p.1), + (lp.single 2 (out p.2 p.1) (∑ v ∈ sv, a p.2 v * b v p.1) : Vector W)‖ ^ 2 ≤ + (∑ u ∈ su, ∑ v ∈ sv, ‖a u v‖ ^ 2) * + (∑ h ∈ sh, ∑ v ∈ sv, ‖b v h‖ ^ 2) := by + classical + rw [norm_sum_single_sq _ _ _ (by + intro p hp q hq hpq + apply hinj (by simpa only [mem_coe, mem_filter, mem_product, Set.mem_ofPred_eq, and_assoc] using hp) + (by simpa only [mem_coe, mem_filter, mem_product, Set.mem_ofPred_eq, and_assoc] using hq) hpq)] + calc + _ ≤ ∑ p ∈ sh ×ˢ su, ‖∑ v ∈ sv, a p.2 v * b v p.1‖ ^ 2 := by + apply sum_le_sum_of_subset_of_nonneg (filter_subset _ _) + intros; positivity + _ = ∑ h ∈ sh, ∑ u ∈ su, ‖∑ v ∈ sv, a u v * b v h‖ ^ 2 := sum_product .. + _ ≤ _ := block_matrix_bound su sv sh a b + +end +end HochschildLength +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MonotoneLimits.lean b/lean/OAI/Analysis/BoundedHochschild/MonotoneLimits.lean new file mode 100644 index 0000000000000000000000000000000000000000..0c7448e11825a648675db67262b9205224a2678c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MonotoneLimits.lean @@ -0,0 +1,236 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.StarPreduals + +namespace OAI + +/-! Monotone weak-star limits and bounded GNS limits. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open Filter Topology +namespace HochschildSakai +open BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + + +theorem nonneg_of_bounded_predual_limit {a : I → M} {l : Filter I} [l.NeBot] + {b : M} (C : ℝ) (hC : 0 ≤ C) (ha : ∀ᶠ i in l, ‖a i‖ ≤ C) + (hp : ∀ᶠ i in l, 0 ≤ a i) (ht : PredualTendsto e a l b) : 0 ≤ b := by + have hs : PredualTendsto e (fun i => star (a i)) l b := by + intro z + apply (ht z).congr' + filter_upwards [hp] with i hi + rw [(IsSelfAdjoint.of_nonneg hi).star_eq] + have hb : IsSelfAdjoint b := predual_tendsto_unique e (predual_tendsto_star e ht) hs + let c := algebraMap ℝ M C + have hc : 0 ≤ c := algebraMap_nonneg M hC + have hac : ∀ᶠ i in l, ‖c-a i‖ ≤ C := by + filter_upwards [ha,hp] with i hn hi + have hai : a i ≤ c := (CStarAlgebra.norm_le_iff_le_algebraMap (a i) hC hi).mp hn + exact (CStarAlgebra.norm_le_iff_le_algebraMap (c-a i) hC (sub_nonneg.mpr hai)).mpr + (sub_le_self _ hi) + have hbc : ‖c-b‖ ≤ C := predual_norm_le e C hC hac + (predual_tendsto_sub e (predual_tendsto_const e c l) ht) + have hsa : IsSelfAdjoint (c-b) := (IsSelfAdjoint.of_nonneg hc).sub hb + have hle : c-b ≤ c := hsa.le_algebraMap_norm_self.trans (algebraMap_mono M hbc) + exact le_of_add_le_add_left (show c+0 ≤ c+b by + simpa only [add_zero] using sub_le_iff_le_add.mp hle) + + +theorem le_of_bounded_predual_limit {a : I → M} {l : Filter I} [l.NeBot] + {b c : M} (C : ℝ) (hC : 0 ≤ C) (ha : ∀ᶠ i in l, ‖a i‖ ≤ C) + (hp : ∀ᶠ i in l, a i ≤ c) (ht : PredualTendsto e a l b) : b ≤ c := by + apply sub_nonneg.mp + apply nonneg_of_bounded_predual_limit e (‖c‖+C) (add_nonneg (norm_nonneg _) hC) + ?_ (hp.mono fun _ hi => sub_nonneg.mpr hi) + (predual_tendsto_sub e (predual_tendsto_const e c l) ht) + filter_upwards [ha] with i hi + exact (norm_sub_le c (a i)).trans (by gcongr) + +theorem ge_of_bounded_predual_limit {a : I → M} {l : Filter I} [l.NeBot] + {b c : M} (C : ℝ) (hC : 0 ≤ C) (ha : ∀ᶠ i in l, ‖a i‖ ≤ C) + (hp : ∀ᶠ i in l, c ≤ a i) (ht : PredualTendsto e a l b) : c ≤ b := by + apply sub_nonneg.mp + apply nonneg_of_bounded_predual_limit e (C+‖c‖) (add_nonneg hC (norm_nonneg _)) + ?_ (hp.mono fun _ hi => sub_nonneg.mpr hi) + (predual_tendsto_sub e ht (predual_tendsto_const e c l)) + filter_upwards [ha] with i hi + exact (norm_sub_le (a i) c).trans (by gcongr) + + + +theorem exists_monotone_predual_limit [Preorder I] [IsDirected I (· ≤ ·)] [Nonempty I] + (a : I → M) (hm : Monotone a) (C : ℝ) (hC : 0 ≤ C) (ha : ∀ i, ‖a i‖ ≤ C) : + ∃ b : M, ‖b‖ ≤ C ∧ IsLUB (Set.range a) b ∧ PredualTendsto e a atTop b := by + let u : Ultrafilter I := Ultrafilter.of atTop + have hu : (u : Filter I) ≤ atTop := Ultrafilter.of_le _ + obtain ⟨b,hb,ht⟩ := exists_predual_ultralimit e u a C ha + have hlu (v : Ultrafilter I) (hv : (v : Filter I) ≤ atTop) (c : M) + (hc : PredualTendsto e a (v : Filter I) c) : IsLUB (Set.range a) c := by + constructor + · rintro _ ⟨i,rfl⟩ + apply ge_of_bounded_predual_limit e C hC (Eventually.of_forall ha) ?_ hc + exact hv ((eventually_ge_atTop i).mono fun j hj => hm hj) + · intro d hd + apply le_of_bounded_predual_limit e C hC (Eventually.of_forall ha) ?_ hc + exact Eventually.of_forall fun i => hd (Set.mem_range_self i) + have hbL := hlu u hu b ht + refine ⟨b,hb,hbL,fun z => ?_⟩ + rw [Filter.tendsto_iff_ultrafilter] + intro v hv + obtain ⟨c,_hc,hct⟩ := exists_predual_ultralimit e v a C ha + have hcb : c=b := (hlu v hv c hct).unique hbL + exact hcb ▸ hct z + +end HochschildSakai + + + +open Filter Topology +namespace HochschildUltrafilter + + + +theorem diagonal_rank (ω : Ultrafilter ℕ) (hω : (ω : Filter ℕ) ≤ atTop) + (P : ℕ → ℕ → Prop) (hP : ∀ n, ∀ᶠ j in (ω : Filter ℕ), P n j) : + ∃ r : ℕ → ℕ, Tendsto r (ω : Filter ℕ) atTop ∧ ∀ᶠ j in (ω : Filter ℕ), P (r j) j := by + classical + let r : ℕ → ℕ := fun j => Nat.findGreatest (fun n => P n j) j + refine ⟨r,?_,?_⟩ + · apply Filter.tendsto_atTop.mpr + intro n + filter_upwards [hP n,hω (eventually_ge_atTop n)] with j hj hn + exact Nat.le_findGreatest hn hj + · filter_upwards [hP 0] with j hj + exact Nat.findGreatest_spec (P := fun n => P n j) (Nat.zero_le j) hj + +end HochschildUltrafilter + + + +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildUltrapower +open TracialUltrapower HochschildRigidity BoundedHochschild +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] +variable (τ : A →ₚ[ℂ] ℂ) (h1 : τ 1 = 1) (ω : Ultrafilter ℕ) +variable (htr : ∀ a b : A, τ (a*b) = τ (b*a)) + +lemma tendsto_quotient_preGNS_norm (a : ℕ →ᵇ A) : + Tendsto (fun j => ‖τ.toPreGNS (a j)‖) (ω : Filter ℕ) + (𝓝 ‖(quotientTrace τ h1 ω htr).toPreGNS (quotientHom τ h1 ω htr a)‖) := by + rw [quotientTrace_preGNS_norm] + exact tendsto_sequenceTwoNorm (traceHilbertMap τ h1) ω a + + + +lemma quotient_norm_le_of_eventually (a : ℕ →ᵇ A) (C : ℝ) (hC : 0 ≤ C) + (ha : ∀ᶠ j in (ω : Filter ℕ), ‖a j‖ ≤ C) : + ‖quotientHom τ h1 ω htr a‖ ≤ C := by + classical + let b : ℕ →ᵇ A := BoundedContinuousFunction.ofNormedAddCommGroupDiscrete + (fun j => if ‖a j‖ ≤ C then a j else 0) C (fun j => by split_ifs <;> simp_all) + have hb : ‖b‖ ≤ C := (BoundedContinuousFunction.norm_le hC).mpr (fun j => by + change ‖if ‖a j‖ ≤ C then a j else 0‖ ≤ C + split_ifs <;> simp_all) + have he : quotientHom τ h1 ω htr (a-b)=0 := by + apply Ideal.Quotient.eq_zero_iff_mem.mpr + change a-b ∈ nullSubmodule (traceHilbertMap τ h1).toLinearMap (ω : Filter ℕ) + rw [mem_nullSubmodule] + apply tendsto_const_nhds.congr' + filter_upwards [ha] with j hj + simp only [BoundedContinuousFunction.sub_apply] + change (0:ℝ) = ‖τ.toPreGNS (a j - if ‖a j‖ ≤ C then a j else 0)‖ + simp only [ite_eq_left hj,sub_self,map_zero,norm_zero] + have he' : quotientHom τ h1 ω htr a=quotientHom τ h1 ω htr b := by + simpa only [map_sub,sub_eq_zero] using he + rw [he'] + exact (HochschildCStarQuotient.norm_mk_le (ideal τ h1 ω htr) b).trans hb + + + +theorem exists_bounded_GNS_limit (hω : (ω : Filter ℕ) ≤ atTop) + (x : ℕ → Ultrapower τ h1 ω htr) (C : ℝ) (hx : ∀ n, ‖x n‖ ≤ C) + (hc : CauchySeq (fun n => (quotientTrace τ h1 ω htr).toPreGNS (x n))) : + ∃ b : Ultrapower τ h1 ω htr, ‖b‖ ≤ C ∧ + GNSTendsto (quotientTrace τ h1 ω htr) x atTop b := by + classical + let q := quotientHom τ h1 ω htr + let T := quotientTrace τ h1 ω htr + have hreps (n : ℕ) : ∃ a : ℕ →ᵇ A, q a=x n ∧ ‖a‖ < C+1/(n+1:ℝ) := by + obtain ⟨a,ha,han⟩ := HochschildCStarQuotient.norm_mk_lt + (ideal τ h1 ω htr) (x n) (show (0:ℝ)<1/(n+1:ℝ) by positivity) + exact ⟨a,ha,han.trans_le (by linarith [hx n])⟩ + choose a ha han' using hreps + have han (n : ℕ) : ‖a n‖ < C+1 := (han' n).trans_le (by + have : 1/(n+1:ℝ) ≤ 1 := (div_le_one (by positivity)).mpr (by exact_mod_cast Nat.le_add_left 1 n) + linarith) + let P : ℕ → ℕ → Prop := fun n j => ∀ k ≤ n, + ‖τ.toPreGNS (a k j-a n j)‖ < ‖T.toPreGNS (x k-x n)‖ + 1/(n+1:ℝ) + have hP (n : ℕ) : ∀ᶠ j in (ω : Filter ℕ), P n j := by + have ht (k : ℕ) := tendsto_quotient_preGNS_norm τ h1 ω htr (a k-a n) + have he : ∀ᶠ j in (ω : Filter ℕ), ∀ k ∈ Finset.range (n+1), + ‖τ.toPreGNS (a k j-a n j)‖ < ‖T.toPreGNS (x k-x n)‖ + 1/(n+1:ℝ) := by + rw [Filter.eventually_all_finset] + intro k _hk + have ht' : Tendsto (fun j => ‖τ.toPreGNS (a k j-a n j)‖) (ω : Filter ℕ) + (𝓝 ‖T.toPreGNS (x k-x n)‖) := by + simpa only [BoundedContinuousFunction.sub_apply,map_sub,← show q = quotientHom τ h1 ω htr from rfl,ha] using ht k + exact ht'.eventually_lt_const (lt_add_of_pos_right _ (by positivity)) + filter_upwards [he] with j hj + intro k hk + exact hj k (Finset.mem_range.mpr (by omega)) + obtain ⟨r,hr,hrP⟩ := HochschildUltrafilter.diagonal_rank ω hω P hP + let b : ℕ →ᵇ A := BoundedContinuousFunction.ofNormedAddCommGroupDiscrete + (fun j => a (r j) j) (C+1) (fun j => + (BoundedContinuousFunction.norm_coe_le_norm (a (r j)) j).trans (han (r j)).le) + have htol : Tendsto (fun j => 1/(r j+1:ℝ)) (ω : Filter ℕ) (𝓝 0) := + (tendsto_one_div_add_atTop_nhds_zero_nat).comp hr + have hb : ‖q b‖ ≤ C := by + apply le_of_forall_pos_le_add + intro ε hε + apply quotient_norm_le_of_eventually τ h1 ω htr b (C+ε) + (by linarith [norm_nonneg (x 0),hx 0]) + filter_upwards [htol.eventually_lt_const hε] with j hj + exact (BoundedContinuousFunction.norm_coe_le_norm (a (r j)) j).trans + ((han' (r j)).trans_le (by linarith)).le + refine ⟨q b,hb,?_⟩ + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨N,hN⟩ := Metric.cauchySeq_iff.mp hc (ε/4) (by positivity) + refine ⟨N,fun k hk => ?_⟩ + have he : ∀ᶠ j in (ω : Filter ℕ), ‖τ.toPreGNS (a k j-b j)‖ ≤ ε/2 := by + filter_upwards [hrP,hr.eventually (eventually_ge_atTop k), + htol.eventually_lt_const (show (0:ℝ)<ε/4 by positivity)] with j hj hjk hjε + have hsmall : ‖T.toPreGNS (x k-x (r j))‖ < ε/4 := by + simpa only [map_sub,← dist_eq_norm] using hN k hk (r j) (hk.trans hjk) + have hj' := hj k hjk + change ‖τ.toPreGNS (a k j-a (r j) j)‖ ≤ ε/2 + linarith + have ht : Tendsto (fun j => ‖τ.toPreGNS (a k j-b j)‖) (ω : Filter ℕ) + (𝓝 ‖T.toPreGNS (x k-q b)‖) := by + simpa only [BoundedContinuousFunction.sub_apply,map_sub,← show q = quotientHom τ h1 ω htr from rfl,ha] using tendsto_quotient_preGNS_norm τ h1 ω htr (a k-b) + have hbound : ‖T.toPreGNS (x k-q b)‖ ≤ ε/2 := le_of_tendsto ht he + simpa only [Real.dist_eq,sub_zero,abs_norm] using hbound.trans_lt (half_lt_self hε) + +end HochschildUltrapower +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularCofaces.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularCofaces.lean new file mode 100644 index 0000000000000000000000000000000000000000..43ce32e018684c5363e87ab60458b0c7101ddc2f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularCofaces.lean @@ -0,0 +1,76 @@ +import OAI.Analysis.BoundedHochschild.MultimodularMergeBalance + +namespace OAI + +/-! The elementary Hochschild cofaces preserve module identities. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma MultimodularAt.add {n : ℕ} {f g : Cochain M (n + 1)} {r : M} + (hf : MultimodularAt f r) (hg : MultimodularAt g r) : MultimodularAt (f + g) r := by + constructor + · intro x + simp only [add_apply, hf.left, hg.left, mul_add] + · intro x + simp only [add_apply, hf.right, hg.right, add_mul] + · intro x j + simp only [add_apply, hf.balance x j, hg.balance x j] + +lemma MultimodularAt.smul {n : ℕ} {f : Cochain M (n + 1)} {r : M} + (hf : MultimodularAt f r) (z : ℂ) : MultimodularAt (z • f) r := by + constructor + · intro x + simp only [smul_apply, hf.left, mul_smul_comm] + · intro x + simp only [smul_apply, hf.right, smul_mul_assoc] + · intro x j + simp only [smul_apply, hf.balance x j] + +lemma MultimodularAt.zero {n : ℕ} (r : M) : MultimodularAt (0 : Cochain M (n + 1)) r := by + constructor <;> intros <;> simp + +lemma MultimodularAt.sum {I : Type*} {n : ℕ} (s : Finset I) (f : I → Cochain M (n + 1)) (r : M) + (hf : ∀ i ∈ s, MultimodularAt (f i) r) : MultimodularAt (∑ i ∈ s, f i) r := by + classical + induction s using Finset.induction_on with + | empty => simpa using MultimodularAt.zero (n := n) r + | @insert a s ha ih => + rw [Finset.sum_insert ha] + exact (hf a (Finset.mem_insert_self _ _)).add + (ih (fun i hi => hf i (Finset.mem_insert_of_mem hi))) + +lemma multimodularAt_middleCoboundary {n : ℕ} (f : Cochain M (n + 1)) (r : M) + (hf : MultimodularAt f r) (k : Fin (n + 1)) : MultimodularAt (middleCoboundary f k) r := by + constructor + · intro x + simp only [middleCoboundary_apply, mergeInputs_left_module] + exact hf.left _ + · intro x + simp only [middleCoboundary_apply, mergeInputs_right_module] + exact hf.right _ + · intro x j + simp only [middleCoboundary_apply] + by_cases hkj : k = j + · subst k + rw [mergeInputs_balance_at] + · rcases lt_or_gt_of_ne hkj with hk | hk + · let p : Fin n := ⟨j.val - 1, by omega⟩ + have hp : p.val + 1 = j.val := by dsimp [p]; omega + rw [merge_balance_before_left x k j p hk hp, + merge_balance_before_right x k j p hk hp] + exact hf.balance _ p + · let p : Fin n := ⟨j.val, by omega⟩ + have hp : p.val = j.val := rfl + rw [merge_balance_after_left x k j p hk hp, + merge_balance_after_right x k j p hk hp] + exact hf.balance _ p + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularColumns.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularColumns.lean new file mode 100644 index 0000000000000000000000000000000000000000..0bc3cffefe5e9e3b2fa87fe8dbeab70319c9d28c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularColumns.lean @@ -0,0 +1,113 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedLastSlices + +namespace OAI + +/-! The algebraic column identity for a cochain that is multimodular over +a star subalgebra. This is the matrix estimate used in the properly infinite +reduction; all module identities are the usual adjacent-input identities. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] + +structure MultimodularOver (R : StarSubalgebra ℂ M) {n : ℕ} + (f : Cochain M (n + 1)) : Prop where + left : ∀ (r : M), r ∈ R → ∀ x, + f (Function.update x 0 (r * x 0)) = r * f x + right : ∀ (r : M), r ∈ R → ∀ x, + f (Function.update x (Fin.last n) (x (Fin.last n) * r)) = f x * r + balance : ∀ (r : M), r ∈ R → ∀ x (j : Fin n), + f (Function.update x j.castSucc (x j.castSucc * r)) = + f (Function.update x j.succ (r * x j.succ)) + +def shiftedColumnTuple {n : ℕ} (a b : Fin (n + 1) → M) (r : M) + (k : Fin (n + 1)) : Fin (n + 1) → M := + fun j => if j < k then b j else if j = k then r * a j else a j + +lemma shiftedColumnTuple_zero {n : ℕ} (a b : Fin (n + 1) → M) (r : M) : + shiftedColumnTuple a b r 0 = Function.update a 0 (r * a 0) := by + ext j + by_cases hj : j = 0 + · subst j; simp [shiftedColumnTuple] + · simp [shiftedColumnTuple, hj] + +lemma multimodular_slide_column {R : StarSubalgebra ℂ M} {n : ℕ} + (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (r : M) (hr : r ∈ R) (a b : Fin (n + 1) → M) + (hb : ∀ j : Fin n, b j.castSucc * r = r * a j.castSucc) + (k : Fin (n + 1)) : f (shiftedColumnTuple a b r k) = r * f a := by + induction k using Fin.induction with + | zero => rw [shiftedColumnTuple_zero]; exact hf.left r hr a + | succ k ih => + let x : Fin (n + 1) → M := fun j => if j ≤ k.castSucc then b j else a j + have h₀ : shiftedColumnTuple a b r k.castSucc = + Function.update x k.castSucc (x k.castSucc * r) := by + ext j + by_cases he : j = k.castSucc + · subst j + simp [shiftedColumnTuple, x, hb k] + · by_cases hj : j < k.castSucc + · simp [shiftedColumnTuple, x, he, hj, le_of_lt hj] + · have hle : ¬j ≤ k.castSucc := fun h => he (le_antisymm h (le_of_not_gt hj)) + simp [shiftedColumnTuple, x, he, hj, hle] + have h₁ : shiftedColumnTuple a b r k.succ = + Function.update x k.succ (r * x k.succ) := by + ext j + by_cases he : j = k.succ + · subst j + have hnot : ¬ k.succ ≤ k.castSucc := by simp [Fin.le_def] + simp [shiftedColumnTuple, x, hnot] + · have he' : j < k.succ ↔ j ≤ k.castSucc := by + simp only [Fin.lt_def, Fin.le_def, Fin.val_succ, Fin.val_castSucc] + omega + simp [shiftedColumnTuple, x, he, he'] + rw [h₁, ← hf.balance r hr x k, ← h₀] + exact ih + +def columnDiagonal {m : ℕ} (c : Fin m → PartialIso M) (a : M) : M := + ∑ i, (c i : M) * a * star (c i : M) + +lemma columnDiagonal_mul_column {m : ℕ} (c : Fin m → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (a : M) (j : Fin m) : columnDiagonal c a * (c j : M) = (c j : M) * a := by + classical + simp only [columnDiagonal, Finset.sum_mul, mul_assoc] + simp [column_star_mul c hi ho] + +lemma multimodular_column_term {R : StarSubalgebra ℂ M} {n m : ℕ} + (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (c : Fin m → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hc : ∀ i, (c i : M) ∈ R) (a : Fin n → M) (y : M) (i j : Fin m) : + f (Fin.snoc (fun k => columnDiagonal c (a k)) ((c i : M) * y * star (c j : M))) = + (c i : M) * f (Fin.snoc a y) * star (c j : M) := by + have he : Function.update (Fin.snoc (fun k => columnDiagonal c (a k)) ((c i : M) * y) : + Fin (n + 1) → M) (Fin.last n) (((c i : M) * y) * star (c j : M)) = + Fin.snoc (fun k => columnDiagonal c (a k)) ((c i : M) * y * star (c j : M)) := by + ext k + refine Fin.lastCases ?_ (fun k => ?_) k <;> simp + have hright := hf.right (star (c j : M)) (star_mem (hc j)) + (Fin.snoc (fun k => columnDiagonal c (a k)) ((c i : M) * y)) + rw [Fin.snoc_last, he] at hright + rw [hright] + congr 1 + have h := multimodular_slide_column f hf (c i : M) (hc i) + (Fin.snoc a y) (Fin.snoc (fun k => columnDiagonal c (a k)) y) + (fun k => by simpa using columnDiagonal_mul_column c hi ho (a k) i) (Fin.last n) + convert h using 2 + ext k + refine Fin.lastCases ?_ (fun k => ?_) k + · simp [shiftedColumnTuple] + · have hlt : k.castSucc < Fin.last n := by simp [Fin.lt_def] + simp [shiftedColumnTuple, hlt] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularEndFaces.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularEndFaces.lean new file mode 100644 index 0000000000000000000000000000000000000000..89015832110432b16011b73e03a9f4147331f14d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularEndFaces.lean @@ -0,0 +1,105 @@ +import OAI.Analysis.BoundedHochschild.MultimodularCofaces + +namespace OAI + +/-! The left and right end faces of the Hochschild differential preserve +ordinary module identities. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +omit [CStarAlgebra M] in +private lemma tail_update_zero {n : ℕ} (x : Fin (n + 1) → M) (a : M) : + (fun i : Fin n => Function.update x 0 a i.succ) = (fun i => x i.succ) := by + ext i + simp + +omit [CStarAlgebra M] in +private lemma tail_update_succ {n : ℕ} (x : Fin (n + 1) → M) (k : Fin n) (a : M) : + (fun i : Fin n => Function.update x k.succ a i.succ) = + Function.update (fun i => x i.succ) k a := by + ext i + by_cases hi : i = k <;> simp [hi] + +omit [CStarAlgebra M] in +private lemma init_update_last {n : ℕ} (x : Fin (n + 1) → M) (a : M) : + (fun i : Fin n => Function.update x (Fin.last n) a i.castSucc) = (fun i => x i.castSucc) := by + ext i + exact Function.update_of_ne (ne_of_lt (Fin.castSucc_lt_last i)) a x + +omit [CStarAlgebra M] in +private lemma init_update_castSucc {n : ℕ} (x : Fin (n + 1) → M) (k : Fin n) (a : M) : + (fun i : Fin n => Function.update x k.castSucc a i.castSucc) = + Function.update (fun i => x i.castSucc) k a := by + ext i + by_cases hi : i = k <;> simp [hi] + +lemma multimodularAt_leftCoboundary {n : ℕ} (f : Cochain M (n + 1)) (r : M) + (hf : MultimodularAt f r) : MultimodularAt (leftCoboundary f) r := by + constructor + · intro x + simp only [leftCoboundary_apply, Function.update_self, tail_update_zero, mul_assoc] + · intro x + have hlast : Fin.last (n + 1) = (Fin.last n).succ := rfl + simp only [leftCoboundary_apply, hlast, tail_update_succ, + Function.update_of_ne (Ne.symm (Fin.succ_ne_zero (Fin.last n)))] + rw [hf.right] + exact (mul_assoc _ _ _).symm + · intro x j + by_cases hj : j = 0 + · subst j + simp only [leftCoboundary_apply, Fin.castSucc_zero, Function.update_self, + tail_update_zero, tail_update_succ, + Function.update_of_ne (Ne.symm (Fin.succ_ne_zero (0 : Fin (n + 1))))] + rw [hf.left] + exact mul_assoc _ _ _ + · obtain ⟨p, rfl⟩ := Fin.eq_succ_of_ne_zero hj + simp only [leftCoboundary_apply, Fin.castSucc_succ, tail_update_succ, + Function.update_of_ne (Ne.symm (Fin.succ_ne_zero p.castSucc)), + Function.update_of_ne (Ne.symm (Fin.succ_ne_zero p.succ))] + rw [hf.balance] + +lemma multimodularAt_rightCoboundary {n : ℕ} (f : Cochain M (n + 1)) (r : M) + (hf : MultimodularAt f r) : MultimodularAt (rightCoboundary f) r := by + constructor + · intro x + have hzero : (0 : Fin (n + 2)) = (0 : Fin (n + 1)).castSucc := rfl + simp only [rightCoboundary_apply, hzero, init_update_castSucc, + Function.update_of_ne (Ne.symm (ne_of_lt (Fin.castSucc_lt_last (0 : Fin (n + 1)))))] + rw [hf.left] + exact mul_assoc _ _ _ + · intro x + simp only [rightCoboundary_apply, Function.update_self, init_update_last, mul_assoc] + · intro x j + by_cases hj : j = Fin.last n + · subst j + have hlast : (Fin.last n).succ = Fin.last (n + 1) := rfl + simp only [rightCoboundary_apply, hlast, init_update_castSucc, + Function.update_of_ne (Ne.symm (ne_of_lt (Fin.castSucc_lt_last (Fin.last n)))), + init_update_last, Function.update_self] + rw [hf.right] + exact mul_assoc _ _ _ + · obtain ⟨p, rfl⟩ := Fin.eq_castSucc_of_ne_last hj + simp only [rightCoboundary_apply, ← Fin.castSucc_succ, init_update_castSucc, + Function.update_of_ne (Ne.symm (ne_of_lt (Fin.castSucc_lt_last p.castSucc))), + Function.update_of_ne (Ne.symm (ne_of_lt (Fin.castSucc_lt_last p.succ)))] + rw [hf.balance] + +lemma multimodularAt_differential {n : ℕ} (f : Cochain M (n + 1)) (r : M) + (hf : MultimodularAt f r) : MultimodularAt (differential f) r := by + change MultimodularAt + (leftCoboundary f + ∑ j : Fin (n + 1), ((-1 : ℂ) ^ (j.val + 1)) • middleCoboundary f j + + ((-1 : ℂ) ^ (n + 2)) • rightCoboundary f) r + exact ((multimodularAt_leftCoboundary f r hf).add + (MultimodularAt.sum Finset.univ _ r (fun j _ => + (multimodularAt_middleCoboundary f r hf j).smul _))).add + ((multimodularAt_rightCoboundary f r hf).smul _) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularGenerators.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularGenerators.lean new file mode 100644 index 0000000000000000000000000000000000000000..831f12d1bdff2bf74083248d725b7e6858518d5e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularGenerators.lean @@ -0,0 +1,107 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixSpan +import OAI.Analysis.BoundedHochschild.NormalMultimodularClosure + +namespace OAI + +/-! It suffices to verify the module identities on matrix units: their +linearity gives the algebraic identities, and normality gives the weak-star +identities used in the primitive construction. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +structure MultimodularAt {n : ℕ} (f : Cochain M (n + 1)) (r : M) : Prop where + left : ∀ x, f (Function.update x 0 (r * x 0)) = r * f x + right : ∀ x, f (Function.update x (Fin.last n) (x (Fin.last n) * r)) = f x * r + balance : ∀ x (j : Fin n), + f (Function.update x j.castSucc (x j.castSucc * r)) = + f (Function.update x j.succ (r * x j.succ)) + +lemma multimodularAt_one {n : ℕ} (f : Cochain M (n + 1)) : MultimodularAt f 1 := by + constructor <;> intros <;> simp + +lemma linear_maps_eq_on_span (S : Set M) (T U : M →L[ℂ] M) + (h : ∀ r ∈ S, T r = U r) {a : M} (ha : a ∈ Submodule.span ℂ S) : T a = U a := by + have hker : Submodule.span ℂ S ≤ (T - U).ker := by + apply Submodule.span_le.mpr + intro r hr + change T r - U r = 0 + exact sub_eq_zero.mpr (h r hr) + have hzero := hker ha + change T a - U a = 0 at hzero + exact sub_eq_zero.mp hzero + +lemma multimodularAt_of_span {n : ℕ} (f : Cochain M (n + 1)) (S : Set M) + (hS : ∀ r ∈ S, MultimodularAt f r) {a : M} (ha : a ∈ Submodule.span ℂ S) : + MultimodularAt f a := by + constructor + · intro x + have h := linear_maps_eq_on_span S + ((updateSlice f 0 x).comp ((ContinuousLinearMap.mul ℂ M).flip (x 0))) + ((ContinuousLinearMap.mul ℂ M).flip (f x)) + (fun r hr => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using (hS r hr).left x) ha + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using h + · intro x + have h := linear_maps_eq_on_span S + ((updateSlice f (Fin.last n) x).comp (ContinuousLinearMap.mul ℂ M (x (Fin.last n)))) + (ContinuousLinearMap.mul ℂ M (f x)) + (fun r hr => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.mul_apply'] using (hS r hr).right x) ha + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.mul_apply'] using h + · intro x j + have h := linear_maps_eq_on_span S + ((updateSlice f j.castSucc x).comp (ContinuousLinearMap.mul ℂ M (x j.castSucc))) + ((updateSlice f j.succ x).comp ((ContinuousLinearMap.mul ℂ M).flip (x j.succ))) + (fun r hr => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using (hS r hr).balance x j) ha + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using h + +theorem multimodular_of_matrixUnits (c : ℕ → HochschildComparison.PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) {n : ℕ} + (f : Cochain M (n + 1)) (hf : ∀ i j, MultimodularAt f (countableMatrixUnit c i j)) : + MultimodularOver (countableMatrixAlgebra c) f := by + have hS : ∀ r ∈ ({1} ∪ Set.range (fun p : ℕ × ℕ => countableMatrixUnit c p.1 p.2)), + MultimodularAt f r := by + intro r hr + rcases hr with hr | ⟨⟨i, j⟩, rfl⟩ + · have hr1 : r = 1 := Set.mem_singleton_iff.mp hr + subst r + exact multimodularAt_one f + · exact hf i j + have hA : ∀ r ∈ countableMatrixAlgebra c, MultimodularAt f r := by + intro r hr + apply multimodularAt_of_span f _ hS + rw [← countableMatrixAlgebra_eq_span c hi ho] + exact hr + exact ⟨fun r hr => (hA r hr).left, fun r hr => (hA r hr).right, + fun r hr => (hA r hr).balance⟩ + +universe u +variable {N Y : Type u} [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N] + [NormedAddCommGroup Y] [NormedSpace ℂ Y] [CompleteSpace Y] + +theorem primitive_of_normal_matrix_units [Nontrivial N] + (e : StrongDual ℂ Y ≃ₗᵢ⋆[ℂ] N) (hno : NoFiniteCentralSummand N) + (c : ℕ → HochschildComparison.PartialIso N) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + {n : ℕ} (f : Cochain N (n + 1)) (hn : SeparatelyNormal e f) + (hf : ∀ i j, MultimodularAt f (countableMatrixUnit c i j)) + (hcocycle : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain N n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := + primitive_of_normal_matrix_multimodular e hno c hi ho ht f hn + (multimodular_of_matrixUnits c hi ho f hf) hcocycle + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularInsertion.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularInsertion.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf10b0ddb3fafe14de738f85a97c2a86b10e966e --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularInsertion.lean @@ -0,0 +1,91 @@ +import OAI.Analysis.BoundedHochschild.NormalMultimodularity + +namespace OAI + +/-! Inserting the identity in a multimodular cochain retains its module +identities, including the balance across the deleted input. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma multimodularAt_curryMid_one {n : ℕ} (f : Cochain M (n + 2)) (r : M) + (hf : MultimodularAt f r) (k : Fin (n + 2)) : + MultimodularAt (f.curryMid k 1) r := by + constructor + · intro x + change f (k.insertNth 1 (Function.update x 0 (r * x 0))) = r * f (k.insertNth (α := fun _ => M) 1 x) + rw [Fin.insertNth_update] + by_cases hk : k = 0 + · subst k + have h := hf.balance ((0 : Fin (n + 2)).insertNth 1 x) (0 : Fin (n + 1)) + have hl := hf.left ((0 : Fin (n + 2)).insertNth 1 x) + simp only [Fin.succAbove_zero, Fin.insertNth_zero', Fin.cons_zero, + Fin.castSucc_zero, one_mul, mul_one] at h hl ⊢ + exact h.symm.trans hl + · have hs : k.succAbove (0 : Fin (n + 1)) = 0 := Fin.succAbove_ne_zero_zero hk + have hv : k.insertNth (α := fun _ => M) 1 x 0 = x 0 := by + rw [← hs] + exact Fin.insertNth_apply_succAbove (α := fun _ => M) k 1 x 0 + simpa only [hs, hv] using hf.left (k.insertNth (α := fun _ => M) 1 x) + · intro x + change f (k.insertNth 1 (Function.update x (Fin.last n) (x (Fin.last n) * r))) = + f (k.insertNth (α := fun _ => M) 1 x) * r + rw [Fin.insertNth_update] + by_cases hk : k = Fin.last (n + 1) + · subst k + have h := hf.balance ((Fin.last (n + 1)).insertNth 1 x) (Fin.last n) + have hr := hf.right ((Fin.last (n + 1)).insertNth 1 x) + simp only [Fin.succAbove_last, Fin.insertNth_last', Fin.snoc_last, + Fin.snoc_castSucc, Fin.succ_last, one_mul, mul_one] at h hr ⊢ + exact h.trans hr + · have hs := Fin.succAbove_ne_last_last hk + have hv : k.insertNth (α := fun _ => M) 1 x (Fin.last (n + 1)) = x (Fin.last n) := by + rw [← hs] + exact Fin.insertNth_apply_succAbove (α := fun _ => M) k 1 x (Fin.last n) + simpa only [hs, hv] using hf.right (k.insertNth (α := fun _ => M) 1 x) + · intro x j + change f (k.insertNth 1 (Function.update x j.castSucc (x j.castSucc * r))) = + f (k.insertNth 1 (Function.update x j.succ (r * x j.succ))) + rw [Fin.insertNth_update, Fin.insertNth_update] + let y := k.insertNth (α := fun _ => M) 1 x + have hv (i : Fin (n + 1)) : y (k.succAbove i) = x i := + Fin.insertNth_apply_succAbove (α := fun _ => M) k 1 x i + by_cases hk : k.val ≤ j.val + · have hs₀ : k.succAbove j.castSucc = j.castSucc.succ := + Fin.succAbove_of_le_castSucc _ _ (by simpa only [Fin.le_def, Fin.val_castSucc] using hk) + have hs₁ : k.succAbove j.succ = j.succ.succ := + Fin.succAbove_of_le_castSucc _ _ (by simp only [Fin.le_def, Fin.val_castSucc, Fin.val_succ]; omega) + have h₀ : y j.succ.castSucc = x j.castSucc := by + simpa only [hs₀, Fin.castSucc_succ] using hv j.castSucc + have h₁ : y j.succ.succ = x j.succ := by simpa only [hs₁] using hv j.succ + simpa only [hs₀, hs₁, ← Fin.castSucc_succ, h₀, h₁] using hf.balance y j.succ + · by_cases hk' : k.val = j.val + 1 + · have he : k = j.castSucc.succ := Fin.ext hk' + have hs₀ : k.succAbove j.castSucc = j.castSucc.castSucc := + Fin.succAbove_of_castSucc_lt _ _ (by simp only [Fin.lt_def, Fin.val_castSucc]; omega) + have hs₁ : k.succAbove j.succ = j.succ.succ := + Fin.succAbove_of_le_castSucc _ _ (by simp only [Fin.le_def, Fin.val_castSucc, Fin.val_succ]; omega) + have h₀ : y j.castSucc.castSucc = x j.castSucc := by simpa only [hs₀] using hv j.castSucc + have h₁ : y j.succ.succ = x j.succ := by simpa only [hs₁] using hv j.succ + have hmid : y j.castSucc.succ = 1 := by rw [← he]; exact Fin.insertNth_apply_same (α := fun _ => M) k 1 x + have ha := hf.balance y j.castSucc + have hb := hf.balance y j.succ + simp only [h₀, hmid, mul_one] at ha + simp only [Fin.castSucc_succ, hmid, h₁, one_mul] at hb + simpa only [hs₀, hs₁] using ha.trans hb + · have hs₀ : k.succAbove j.castSucc = j.castSucc.castSucc := + Fin.succAbove_of_castSucc_lt _ _ (by simp only [Fin.lt_def, Fin.val_castSucc]; omega) + have hs₁ : k.succAbove j.succ = j.succ.castSucc := + Fin.succAbove_of_castSucc_lt _ _ (by simp only [Fin.lt_def, Fin.val_castSucc, Fin.val_succ]; omega) + have h₀ : y j.castSucc.castSucc = x j.castSucc := by simpa only [hs₀] using hv j.castSucc + have h₁ : y j.castSucc.succ = x j.succ := by simpa only [hs₁, Fin.castSucc_succ] using hv j.succ + simpa only [hs₀, hs₁, Fin.castSucc_succ, h₀, h₁] using hf.balance y j.castSucc + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularMatrixBound.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularMatrixBound.lean new file mode 100644 index 0000000000000000000000000000000000000000..d5b02cf6cd3bd8d5f43f5557fc3430c71bcfe780 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularMatrixBound.lean @@ -0,0 +1,114 @@ +import OAI.Analysis.BoundedHochschild.MultimodularColumns +import OAI.Analysis.BoundedHochschild.CompletelyBoundedPrimitives + +namespace OAI + +/-! A bounded multimodular cochain has completely bounded last slices if +the coefficient subalgebra contains unital isometry columns of every finite +size. This is the required matrix-norm specialization, with no dimension +factor in the bound. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +omit [PartialOrder M] [StarOrderedRing M] in +lemma columnDiagonal_eq_reconstruction {m : ℕ} (c : Fin m → PartialIso M) (a : M) : + columnDiagonal c a = columnReconstruction c (matrixScalarHom m a) := by + classical + simp [columnDiagonal, columnReconstruction, matrixScalarHom_apply] + +lemma columnReconstruction_norm_for_multimodular {m : ℕ} (c : Fin m → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) (A : CStarMatrix (Fin m) (Fin m) M) : + ‖columnReconstruction c A‖ = ‖A‖ := by + rw [← columnCompression_norm c hi ho hs (columnReconstruction c A), + columnCompression_reconstruction c hi ho] + +lemma columnDiagonal_norm_le {m : ℕ} (c : Fin m → PartialIso M) + (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) (a : M) : ‖columnDiagonal c a‖ ≤ ‖a‖ := by + rw [columnDiagonal_eq_reconstruction, columnReconstruction_norm_for_multimodular c hi ho hs] + exact NonUnitalStarAlgHom.norm_apply_le _ _ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma multimodular_matrix_identity {R : StarSubalgebra ℂ M} {n m : ℕ} + (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (c : Fin m → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hc : ∀ i, (c i : M) ∈ R) (a : Fin n → M) (A : CStarMatrix (Fin m) (Fin m) M) : + f (Fin.snoc (fun k => columnDiagonal c (a k)) (columnReconstruction c A)) = + columnReconstruction c (A.map (f.curryRight a)) := by + classical + calc + _ = (f.curryRight (fun k => columnDiagonal c (a k))) + (∑ i, ∑ j, (c i : M) * A i j * star (c j : M)) := rfl + _ = ∑ i, ∑ j, f (Fin.snoc (fun k => columnDiagonal c (a k)) + ((c i : M) * A i j * star (c j : M))) := by + simp only [map_sum, ContinuousMultilinearMap.curryRight_apply] + _ = ∑ i, ∑ j, (c i : M) * f (Fin.snoc a (A i j)) * star (c j : M) := by + apply Finset.sum_congr rfl + intro i _ + apply Finset.sum_congr rfl + intro j _ + exact multimodular_column_term f hf c hi ho hc a (A i j) i j + _ = _ := rfl + +lemma multimodular_last_matrix_bound {R : StarSubalgebra ℂ M} {n m : ℕ} + (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (c : Fin m → PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (hs : ∑ i, (c i).final = 1) (hc : ∀ i, (c i : M) ∈ R) + (a : Fin n → M) (A : CStarMatrix (Fin m) (Fin m) M) : + ‖A.map (f.curryRight a)‖ ≤ (‖f‖ * ∏ k, ‖a k‖) * ‖A‖ := by + rw [← columnReconstruction_norm_for_multimodular c hi ho hs (A.map (f.curryRight a)), + ← multimodular_matrix_identity f hf c hi ho hc a A] + calc + _ ≤ (‖f‖ * ∏ k, ‖columnDiagonal c (a k)‖) * ‖columnReconstruction c A‖ := + f.norm_map_snoc_le _ _ + _ ≤ (‖f‖ * ∏ k, ‖a k‖) * ‖A‖ := by + rw [columnReconstruction_norm_for_multimodular c hi ho hs] + gcongr with k + exact columnDiagonal_norm_le c hi ho hs (a k) + +theorem lastSliceEstimate_of_multimodular_columns {R : StarSubalgebra ℂ M} {n : ℕ} + (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (hcols : ∀ m : ℕ, ∃ c : Fin (m + 1) → PartialIso M, + (∀ i, (c i).initial = 1) ∧ + (∀ i j, i ≠ j → (c i).final * (c j).final = 0) ∧ + (∑ i, (c i).final = 1) ∧ ∀ i, (c i : M) ∈ R) : + LastSliceEstimate f ‖f‖ := by + refine ⟨norm_nonneg _, fun a => ⟨by positivity, fun m A => ?_⟩⟩ + cases m with + | zero => + have hA : A = 0 := by ext i; exact Fin.elim0 i + have hB : A.map (f.curryRight a) = 0 := by ext i; exact Fin.elim0 i + rw [hB, hA, norm_zero, mul_zero] + | succ m => + obtain ⟨c, hi, ho, hs, hc⟩ := hcols m + exact multimodular_last_matrix_bound f hf c hi ho hs hc a A + +theorem primitive_of_multimodular_columns [Nontrivial M] + (P : RightModuleAveragingProjection (M := M)) + {R : StarSubalgebra ℂ M} {n : ℕ} (f : Cochain M (n + 1)) + (hf : MultimodularOver R f) + (hcols : ∀ m : ℕ, ∃ c : Fin (m + 1) → PartialIso M, + (∀ i, (c i).initial = 1) ∧ + (∀ i j, i ≠ j → (c i).final * (c j).final = 0) ∧ + (∑ i, (c i).final = 1) ∧ ∀ i, (c i : M) ∈ R) + (hcocycle : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := + primitive_of_lastSliceEstimate P f (lastSliceEstimate_of_multimodular_columns f hf hcols) + hcocycle + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularMergeBalance.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularMergeBalance.lean new file mode 100644 index 0000000000000000000000000000000000000000..cd905ff2e5d8bc41798746988f2b7ffe6766d7c1 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularMergeBalance.lean @@ -0,0 +1,70 @@ +import OAI.Analysis.BoundedHochschild.MultimodularMerges + +namespace OAI + +/-! Module balance survives an adjacent-input multiplication, on either +side of the balanced pair. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma merge_balance_before_left {n : ℕ} (x : Fin (n + 2) → M) + (k j : Fin (n + 1)) (p : Fin n) (hk : k.val < j.val) (hp : p.val + 1 = j.val) (r : M) : + mergeInputs (Function.update x j.castSucc (x j.castSucc * r)) k = + Function.update (mergeInputs x k) p.castSucc (mergeInputs x k p.castSucc * r) := by + ext i + simp only [mergeInputs, Function.update_apply, Fin.ext_iff, Fin.lt_def, + Fin.val_castSucc, Fin.val_succ] + split_ifs <;> try omega + all_goals try simp_all only + all_goals try simp only [mul_assoc] + all_goals congr 3 <;> (try apply Fin.ext) <;> simp only [Fin.val_castSucc, Fin.val_succ] <;> omega + +lemma merge_balance_before_right {n : ℕ} (x : Fin (n + 2) → M) + (k j : Fin (n + 1)) (p : Fin n) (hk : k.val < j.val) (hp : p.val + 1 = j.val) (r : M) : + mergeInputs (Function.update x j.succ (r * x j.succ)) k = + Function.update (mergeInputs x k) p.succ (r * mergeInputs x k p.succ) := by + ext i + simp only [mergeInputs, Function.update_apply, Fin.ext_iff, Fin.lt_def, + Fin.val_castSucc, Fin.val_succ] + split_ifs <;> try omega + all_goals try simp_all only + congr 3 + apply Fin.ext + simp only [Fin.val_succ] + omega + +lemma merge_balance_after_left {n : ℕ} (x : Fin (n + 2) → M) + (k j : Fin (n + 1)) (p : Fin n) (hk : j.val < k.val) (hp : p.val = j.val) (r : M) : + mergeInputs (Function.update x j.castSucc (x j.castSucc * r)) k = + Function.update (mergeInputs x k) p.castSucc (mergeInputs x k p.castSucc * r) := by + ext i + simp only [mergeInputs, Function.update_apply, Fin.ext_iff, Fin.lt_def, + Fin.val_castSucc, Fin.val_succ] + split_ifs <;> try omega + all_goals try simp_all only + congr 3 + apply Fin.ext + simp only [Fin.val_castSucc] + omega + +lemma merge_balance_after_right {n : ℕ} (x : Fin (n + 2) → M) + (k j : Fin (n + 1)) (p : Fin n) (hk : j.val < k.val) (hp : p.val = j.val) (r : M) : + mergeInputs (Function.update x j.succ (r * x j.succ)) k = + Function.update (mergeInputs x k) p.succ (r * mergeInputs x k p.succ) := by + ext i + simp only [mergeInputs, Function.update_apply, Fin.ext_iff, Fin.lt_def, + Fin.val_castSucc, Fin.val_succ] + split_ifs <;> try omega + all_goals try simp_all only + all_goals try simp only [mul_assoc] + all_goals congr 3 <;> (try apply Fin.ext) <;> simp only [Fin.val_castSucc, Fin.val_succ] <;> omega + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularMerges.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularMerges.lean new file mode 100644 index 0000000000000000000000000000000000000000..4510f1af1504093d199741659e2b807edc31aa75 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularMerges.lean @@ -0,0 +1,78 @@ +import OAI.Analysis.BoundedHochschild.MultimodularInsertion + +namespace OAI + +/-! Multiplying adjacent inputs is compatible with module balance. These +identities supply the interior faces of the relative Hochschild complex. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma mergeInputs_left_module {n : ℕ} (x : Fin (n + 2) → M) (k : Fin (n + 1)) (r : M) : + mergeInputs (Function.update x 0 (r * x 0)) k = + Function.update (mergeInputs x k) 0 (r * mergeInputs x k 0) := by + ext i + by_cases hi : i = 0 + · subst i + by_cases hk : k = 0 + · subst k + simp [mergeInputs, mul_assoc] + · have hkpos : (0 : Fin (n + 1)) < k := lt_of_le_of_ne (Fin.zero_le _) (Ne.symm hk) + simp [mergeInputs, hkpos] + · have his : i.castSucc ≠ (0 : Fin (n + 2)) := by + intro h + exact hi (Fin.ext (congrArg (fun j : Fin (n + 2) => j.val) h)) + simp only [mergeInputs, Function.update_of_ne hi, Function.update_of_ne his, + Function.update_of_ne (Fin.succ_ne_zero i)] + +lemma mergeInputs_right_module {n : ℕ} (x : Fin (n + 2) → M) (k : Fin (n + 1)) (r : M) : + mergeInputs (Function.update x (Fin.last (n + 1)) (x (Fin.last (n + 1)) * r)) k = + Function.update (mergeInputs x k) (Fin.last n) (mergeInputs x k (Fin.last n) * r) := by + ext i + by_cases hi : i = Fin.last n + · subst i + by_cases hk : k = Fin.last n + · subst k + simp [mergeInputs, mul_assoc] + · have hklt : k < Fin.last n := lt_of_le_of_ne (Fin.le_last _) hk + simp [mergeInputs, not_lt_of_ge (Fin.le_last k), Ne.symm hk] + · have his : i.succ ≠ Fin.last (n + 1) := by + intro h + apply hi + apply Fin.ext + have hv := congrArg Fin.val h + simp only [Fin.val_succ, Fin.val_last] at hv ⊢ + omega + simp only [mergeInputs, Function.update_of_ne hi, + Function.update_of_ne (ne_of_lt (Fin.castSucc_lt_last i)), Function.update_of_ne his] + +lemma mergeInputs_balance_at {n : ℕ} (x : Fin (n + 2) → M) (k : Fin (n + 1)) (r : M) : + mergeInputs (Function.update x k.castSucc (x k.castSucc * r)) k = + mergeInputs (Function.update x k.succ (r * x k.succ)) k := by + ext i + by_cases hik : i = k + · subst i + simp [mergeInputs, ne_of_lt (Fin.castSucc_lt_succ (i := k)), + ne_of_gt (Fin.castSucc_lt_succ (i := k)), mul_assoc] + · by_cases hlt : i < k + · have hic : i.castSucc ≠ k.castSucc := by simpa using hik + have his : i.castSucc ≠ k.succ := ne_of_lt (lt_trans (Fin.castSucc_lt_castSucc_iff.mpr hlt) + Fin.castSucc_lt_succ) + simp only [mergeInputs, ite_eq_left hlt, Function.update_of_ne hic, Function.update_of_ne his] + · have his : i.succ ≠ k.succ := by simpa using hik + have hic : i.succ ≠ k.castSucc := by + intro he + have hv := congrArg Fin.val he + simp only [Fin.val_succ, Fin.val_castSucc] at hv + have hv' : k.val ≤ i.val := le_of_not_gt hlt + omega + simp only [mergeInputs, ite_eq_right hlt, ite_eq_right hik, Function.update_of_ne his, Function.update_of_ne hic] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularNormalReduction.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularNormalReduction.lean new file mode 100644 index 0000000000000000000000000000000000000000..7b5a5326383919eb73ae39b24c386bba29e41ba5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularNormalReduction.lean @@ -0,0 +1,129 @@ +import OAI.Analysis.BoundedHochschild.MultimodularEndFaces +import OAI.Analysis.TracialCohomology.NormalReduction + +namespace OAI + +/-! The established normal-cocycle reduction retains multimodularity. +This is preparatory support for the properly infinite application; it +assumes no complete bound on the initial cocycle. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma MultimodularAt.sub {n : ℕ} {f g : Cochain M (n + 1)} {r : M} + (hf : MultimodularAt f r) (hg : MultimodularAt g r) : MultimodularAt (f - g) r := by + simpa only [neg_one_smul, ← sub_eq_add_neg] using hf.add (hg.smul (-1)) + +lemma multimodularOver_iff_at {n : ℕ} (R : StarSubalgebra ℂ M) (f : Cochain M (n + 1)) : + MultimodularOver R f ↔ ∀ r ∈ R, MultimodularAt f r := by + constructor + · intro h r hr + exact ⟨h.left r hr, h.right r hr, h.balance r hr⟩ + · intro h + exact ⟨fun r hr => (h r hr).left, fun r hr => (h r hr).right, + fun r hr => (h r hr).balance⟩ + +lemma normalFirst_eq_normalAt_zero (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 1)) : normalFirst e f = normalAt e f 0 := by + ext x + rw [← Fin.cons_self_tail x, normalFirst_cons] + have h := normalAt_insert e f 0 (Fin.tail x) (x 0) + simp only [Fin.insertNth_zero'] at h + rw [h] + have hs : firstSliceN f (Fin.tail x) = sliceAt f 0 (Fin.tail x) := by + ext a + simp only [sliceAt_apply, Fin.insertNth_zero', firstSliceN_apply] + rw [hs] + +lemma multimodularAt_firstNormalCorrection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 2)) (r : M) (hf : MultimodularAt f r) : + MultimodularAt (firstNormalCorrectionN e f) r := by + have hn : MultimodularAt (normalFirst e f) r := by + rw [normalFirst_eq_normalAt_zero] + exact normalAt_multimodularAt e f 0 r hf + have he : firstNormalCorrectionN e f = (normalFirst e f).curryMid 0 1 := by + ext x + change normalFirst e f (Fin.cons 1 x) = normalFirst e f ((0 : Fin (n + 2)).insertNth 1 x) + rw [Fin.insertNth_zero'] + rw [he] + exact multimodularAt_curryMid_one _ r hn 0 + +lemma multimodularAt_firstNormalRemainder (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 2)) (r : M) (hf : MultimodularAt f r) : + MultimodularAt (firstNormalRemainderN e f) r := by + exact hf.sub (multimodularAt_differential _ r (multimodularAt_firstNormalCorrection e f r hf)) + +lemma multimodularAt_slotInsertion (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 2)) (i : Fin (n + 2)) (r : M) + (hf : MultimodularAt f r) : MultimodularAt (slotInsertion e f i) r := + multimodularAt_curryMid_one _ r (normalAt_multimodularAt e f i r hf) i + +lemma multimodularAt_slotRemainder (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (f : Cochain M (n + 2)) (i : Fin (n + 2)) (r : M) + (hf : MultimodularAt f r) : MultimodularAt (slotRemainder e f i) r := + hf.sub ((multimodularAt_differential _ r (multimodularAt_slotInsertion e f i r hf)).smul _) + +lemma multimodularOver_firstNormalRemainder (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (R : StarSubalgebra ℂ M) (f : Cochain M (n + 2)) (hf : MultimodularOver R f) : + MultimodularOver R (firstNormalRemainderN e f) := by + rw [multimodularOver_iff_at] at hf ⊢ + exact fun r hr => multimodularAt_firstNormalRemainder e f r (hf r hr) + +lemma multimodularOver_slotRemainder (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (R : StarSubalgebra ℂ M) (f : Cochain M (n + 2)) (i : Fin (n + 2)) + (hf : MultimodularOver R f) : MultimodularOver R (slotRemainder e f i) := by + rw [multimodularOver_iff_at] at hf ⊢ + exact fun r hr => multimodularAt_slotRemainder e f i r (hf r hr) + +lemma normal_before_multimodular (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hP : BilinearNormalPartPreservation e) {n : ℕ} (R : StarSubalgebra ℂ M) + (f : Cochain M (n + 2)) (hf : ∀ x, differentialValue f x = 0) + (hM : MultimodularOver R f) (r : ℕ) (hr : 1 ≤ r) (hrn : r ≤ n + 1) : + ∃ (F : Cochain M (n + 2)) (b : Cochain M (n + 1)), + (∀ x, differentialValue F x = 0) ∧ (∀ x, f x = F x + differentialValue b x) ∧ + NormalBefore e F r ∧ UnitZeroBefore F r ∧ MultimodularOver R F := by + induction r with + | zero => omega + | succ r ih => + by_cases hz : r = 0 + · subst r + exact ⟨firstNormalRemainderN e f, firstNormalCorrectionN e f, + firstNormalRemainderN_cocycle e f hf, firstNormalRemainderN_identity e f, + firstRemainder_before_normal e f hf, firstRemainder_before_unitZero e f hf, + multimodularOver_firstNormalRemainder e R f hM⟩ + · obtain ⟨F, b, hFc, hid, hFN, hFU, hFM⟩ := ih (by omega) (by omega) + let i : Fin (n + 1) := ⟨r, by omega⟩ + have hi : 0 < i.val := by dsimp [i]; omega + have hNN := normalAt_before_normal_of_preservation e hP F i.castSucc hFN + refine ⟨slotRemainder e F i.castSucc, b + slotCorrection e F i.castSucc, + slotRemainder_cocycle e F i.castSucc hFc, ?_, + slotRemainder_normal e F i hi hFc hFN hFU hNN, + slotRemainder_unitZero e F i hi hFc hFN hFU, + multimodularOver_slotRemainder e R F i.castSucc hFM⟩ + intro x + rw [hid x, slotRemainder_identity e F i.castSucc x, differentialValue_add] + abel + +theorem normal_reduction_multimodular (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (R : StarSubalgebra ℂ M) (f : Cochain M (n + 2)) + (hf : ∀ x, differentialValue f x = 0) (hM : MultimodularOver R f) : + ∃ (F : Cochain M (n + 2)) (b : Cochain M (n + 1)), + SeparatelyNormal e F ∧ MultimodularOver R F ∧ + (∀ x, differentialValue F x = 0) ∧ (∀ x, f x = F x + differentialValue b x) := by + have hP : BilinearNormalPartPreservation e := + (bilinear_preservation_iff e).mpr (HochschildNormalPart.operator_bilinear_normal_preservation e) + obtain ⟨F, b, hFc, hid, hFN, _, hFM⟩ := + normal_before_multimodular e hP R f hf hM (n + 1) (by omega) le_rfl + exact ⟨F, b, (separatelyNormal_iff_slices e F).mpr + (all_normal_of_before_penultimate e F hFc hFN), hFM, hFc, hid⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/MultimodularTransport.lean b/lean/OAI/Analysis/BoundedHochschild/MultimodularTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..72503a0a1618a96c6beff4e2dae646cdd17f1699 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/MultimodularTransport.lean @@ -0,0 +1,138 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupMultimodularity + +namespace OAI + +/-! A multimodular cochain is fixed by independent boundary transports +from its subalgebra, hence by finite-group averaging in that subalgebra. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +lemma cochainUnitaryTransport_one {n : ℕ} (f : Cochain M n) : + cochainUnitaryTransport (fun _ => 1) f = f := by + ext x + simp only [cochainUnitaryTransport_apply, OneMemClass.coe_one, star_one, one_mul, mul_one] + congr 1 + funext i + simp only [cochainUnitaryTuple, OneMemClass.coe_one, star_one, one_mul, mul_one] + +def unitaryPrefix {n : ℕ} (u : Fin (n + 1) → unitary M) (k : ℕ) : Fin (n + 1) → unitary M := + fun i => if i.val < k then u i else 1 + +lemma unitaryPrefix_step {n : ℕ} (u : Fin (n + 1) → unitary M) (k : ℕ) (hk : k < n + 1) : + unitaryPrefix u (k + 1) = + unitaryPrefix u k * Function.update (fun _ => 1) ⟨k, hk⟩ (u ⟨k, hk⟩) := by + funext i + by_cases hi : i = ⟨k, hk⟩ + · subst i + simp [unitaryPrefix] + · have hv : i.val ≠ k := fun h => hi (Fin.ext h) + by_cases hlt : i.val < k + · simp [unitaryPrefix, hlt, Nat.lt_succ_of_lt hlt, hi] + · have hn : ¬i.val < k + 1 := by omega + simp [unitaryPrefix, hlt, hn, hi] + +lemma cochainUnitaryTransport_fixed_of_coordinates {n : ℕ} + (u : Fin (n + 1) → unitary M) (f : Cochain M n) + (hf : ∀ i, cochainUnitaryTransport (Function.update (fun _ => 1) i (u i)) f = f) : + cochainUnitaryTransport u f = f := by + have hp : ∀ k, k ≤ n + 1 → cochainUnitaryTransport (unitaryPrefix u k) f = f := by + intro k + induction k with + | zero => + intro _ + have hzero : unitaryPrefix u 0 = (fun _ => 1) := by + funext i + simp [unitaryPrefix] + rw [hzero] + exact cochainUnitaryTransport_one f + | succ k ih => + intro hk + rw [unitaryPrefix_step u k (by omega), ← cochainUnitaryTransport_comp, ih (by omega)] + exact hf _ + have hu : unitaryPrefix u (n + 1) = u := by + funext i + simp only [unitaryPrefix, i.isLt, ite_true] + rw [← hu] + exact hp _ le_rfl + +lemma cochainUnitaryTransport_coordinate_fixed {n : ℕ} + (R : StarSubalgebra ℂ M) (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (i : Fin (n + 2)) (u : unitary M) (hu : (u : M) ∈ R) : + cochainUnitaryTransport (Function.update (fun _ => 1) i u) f = f := by + have hcancel (a : M) : star (u : M) * ((u : M) * a) = a := by + rw [← mul_assoc, Unitary.star_mul_self_of_mem u.property, one_mul] + ext x + by_cases hi : i = 0 + · subst i + rw [cochainUnitaryTransport_apply, cochainUnitaryTuple_left, hf.left (u : M) hu x] + simp only [Function.update_self, Function.update_of_ne (by simp : Fin.last (n + 1) ≠ 0), + OneMemClass.coe_one, mul_one] + exact hcancel _ + · by_cases hl : i = Fin.last (n + 1) + · subst i + rw [cochainUnitaryTransport_apply, cochainUnitaryTuple_right, hf.right _ (star_mem hu) x] + simp only [Function.update_self, Function.update_of_ne (by simp : (0 : Fin (n + 2)) ≠ Fin.last (n + 1)), + OneMemClass.coe_one, star_one, one_mul, mul_assoc, + Unitary.star_mul_self_of_mem u.property, mul_one] + · let j : Fin n := ⟨i.val - 1, by + have h0 : 0 < i.val := Fin.pos_iff_ne_zero.mpr hi + have hlast : i.val < n + 1 := lt_of_le_of_ne i.is_le (fun h => hl (Fin.ext h)) + omega⟩ + have hij : i = j.castSucc.succ := by + apply Fin.ext + dsimp [j] + have h0 : 0 < i.val := Fin.pos_iff_ne_zero.mpr hi + omega + rw [hij, cochainUnitaryTransport_apply, cochainUnitaryTuple_internal] + have hzero : (0 : Fin (n + 2)) ≠ j.castSucc.succ := Ne.symm (Fin.succ_ne_zero _) + have hlast : Fin.last (n + 1) ≠ j.castSucc.succ := by + intro h + have hv := congrArg Fin.val h + simp only [Fin.val_last, Fin.val_succ, Fin.val_castSucc] at hv + omega + simp only [Function.update_of_ne hzero, Function.update_of_ne hlast, + OneMemClass.coe_one, star_one, one_mul, mul_one] + let y := Function.update x j.succ ((u : M) * x j.succ) + have hleft : Function.update y j.castSucc (y j.castSucc * star (u : M)) = + Function.update (Function.update x j.castSucc (x j.castSucc * star (u : M))) + j.succ ((u : M) * x j.succ) := by + ext k + by_cases hk : k = j.castSucc + · subst k + simp [y, ne_of_lt (Fin.castSucc_lt_succ (i := j))] + · by_cases hk' : k = j.succ + · subst k + simp [y, ne_of_gt (Fin.castSucc_lt_succ (i := j))] + · simp [y, hk, hk'] + have hright : Function.update y j.succ (star (u : M) * y j.succ) = x := by + simp only [y, Function.update_self, hcancel, Function.update_idem, Function.update_eq_self] + have h := hf.balance _ (star_mem hu) y j + rw [hleft, hright] at h + exact h + +lemma cochainUnitaryTransport_fixed_of_multimodular {n : ℕ} + (R : StarSubalgebra ℂ M) (f : Cochain M (n + 1)) (hf : MultimodularOver R f) + (u : Fin (n + 2) → unitary M) (hu : ∀ i, (u i : M) ∈ R) : + cochainUnitaryTransport u f = f := + cochainUnitaryTransport_fixed_of_coordinates u f + (fun i => cochainUnitaryTransport_coordinate_fixed R f hf i (u i) (hu i)) + +lemma finiteGroupCochainAverage_fixes {G : Type*} [Group G] [Fintype G] + (ρ : G →* unitary M) {n : ℕ} (R : StarSubalgebra ℂ M) (f : Cochain M (n + 1)) + (hf : MultimodularOver R f) (hρ : ∀ g, (ρ g : M) ∈ R) : finiteGroupCochainAverage ρ f = f := by + unfold finiteGroupCochainAverage + have h (g : Fin (n + 2) → G) : cochainUnitaryTransport (fun i => ρ (g i)) f = f := + cochainUnitaryTransport_fixed_of_multimodular R f hf _ (fun i => hρ (g i)) + simp only [h, Finset.sum_const, Finset.card_univ] + rw [← Nat.cast_smul_eq_nsmul ℂ, smul_smul, + inv_mul_cancel₀ (Nat.cast_ne_zero.mpr (ne_of_gt Fintype.card_pos)), one_smul] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NestedMatrixAmplification.lean b/lean/OAI/Analysis/BoundedHochschild/NestedMatrixAmplification.lean new file mode 100644 index 0000000000000000000000000000000000000000..0ab9cccb03fbea02dbcb56682898aadfbd10e388 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NestedMatrixAmplification.lean @@ -0,0 +1,82 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedRows + +namespace OAI + +/-! Nested finite matrix amplifications and their actual C*-norms. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +variable {M : Type*} [CStarAlgebra M] + +/-- Flattening two finite matrix indices is a star-algebra equivalence. -/ +def nestedMatrixEquiv (n k : ℕ) : + CStarMatrix (Fin n) (Fin n) (CStarMatrix (Fin k) (Fin k) M) ≃⋆ₐ[ℂ] + CStarMatrix (Fin n × Fin k) (Fin n × Fin k) M where + toFun A i j := A i.1 j.1 i.2 j.2 + invFun A i j p q := A (i, p) (j, q) + left_inv _ := rfl + right_inv _ := rfl + map_add' _ _ := rfl + map_smul' _ _ := rfl + map_star' _ := rfl + map_mul' A B := by + ext i j + change (∑ q : Fin n, + (fun a b : Fin k => ∑ t : Fin k, A i.1 q a t * B q j.1 t b)) i.2 j.2 = + ∑ q : Fin n × Fin k, A i.1 q.1 i.2 q.2 * B q.1 j.1 q.2 j.2 + simp only [Finset.sum_apply, Fintype.sum_prod_type] + +variable [PartialOrder M] [StarOrderedRing M] + +lemma nestedMatrix_norm (n k : ℕ) + (A : CStarMatrix (Fin n) (Fin n) (CStarMatrix (Fin k) (Fin k) M)) : + ‖nestedMatrixEquiv n k A‖ = ‖A‖ := StarAlgEquiv.norm_map (nestedMatrixEquiv n k) A + +/-- Reindexing a finite square amplification preserves its norm. -/ +lemma matrix_reindex_norm {I J : Type*} [Fintype I] [Fintype J] + (e : I ≃ J) (A : CStarMatrix I I M) : + ‖CStarMatrix.reindexₐ ℂ M e A‖ = ‖A‖ := + StarAlgEquiv.norm_map (CStarMatrix.reindexₐ ℂ M e) A + +/-- The entrywise amplification of a bounded map is a bounded linear map +on each fixed finite matrix algebra. -/ +def matrixAmplification (k : ℕ) (T : M →L[ℂ] M) : + CStarMatrix (Fin k) (Fin k) M →L[ℂ] CStarMatrix (Fin k) (Fin k) M := by + refine ⟨CStarMatrix.mapₗ T.toLinearMap, ?_⟩ + change Continuous (fun A : Fin k → Fin k → M => fun i j => T (A i j)) + exact continuous_pi fun i => continuous_pi fun j => + T.continuous.comp ((continuous_apply j).comp (continuous_apply i)) + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma matrixAmplification_apply (k : ℕ) (T : M →L[ℂ] M) + (A : CStarMatrix (Fin k) (Fin k) M) : matrixAmplification k T A = A.map T := rfl + +lemma matrixAmplification_norm_le (k : ℕ) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : ‖matrixAmplification k T‖ ≤ C := + ContinuousLinearMap.opNorm_le_bound _ hT.1 (hT.2 k) + +/-- A complete bound is unchanged by passing to any fixed finite +amplification. The proof flattens the two genuine matrix norms. -/ +theorem matrixAmplification_completelyBounded (k : ℕ) (T : M →L[ℂ] M) {C : ℝ} + (hT : CompletelyBoundedEstimate T C) : + CompletelyBoundedEstimate (matrixAmplification k T) C := by + refine ⟨hT.1, ?_⟩ + intro n A + let e : Fin n × Fin k ≃ Fin (n * k) := finProdFinEquiv + have heq : + CStarMatrix.reindexₐ ℂ M e (nestedMatrixEquiv n k (A.map (matrixAmplification k T))) = + (CStarMatrix.reindexₐ ℂ M e (nestedMatrixEquiv n k A)).map T := by + ext i j + rfl + have hb := hT.2 (n * k) (CStarMatrix.reindexₐ ℂ M e (nestedMatrixEquiv n k A)) + rw [← heq, matrix_reindex_norm, nestedMatrix_norm, + matrix_reindex_norm, nestedMatrix_norm] at hb + exact hb + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalBarOperators.lean b/lean/OAI/Analysis/BoundedHochschild/NormalBarOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..9ecea2e134cf2424e94075353af0fc21d1a567ce --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalBarOperators.lean @@ -0,0 +1,69 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupBarOperators +import OAI.Analysis.BoundedHochschild.FiniteGroupPrefixAverages +import OAI.Analysis.BoundedHochschild.NormalCochainTransport + +namespace OAI + +/-! Separate normality is retained by finite prefix averaging and by each +bounded bar-insertion operator. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [CompleteSpace X] in +lemma separatelyNormal_curryMid (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (f : Cochain M (n + 2)) (hf : SeparatelyNormal e f) (i : Fin (n + 2)) (a : M) : + SeparatelyNormal e (f.curryMid i a) := by + intro j x z + obtain ⟨w, hw⟩ := hf (i.succAbove j) (i.insertNth a x) z + refine ⟨w, fun b => ?_⟩ + change e.symm (f (i.insertNth a (Function.update x j b))) z = e.symm b w + rw [Fin.insertNth_update] + exact hw b + +lemma barInsertion_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (u : Fin (n + 3) → unitary M) (i : Fin (n + 2)) + (f : Cochain M (n + 2)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (barInsertion u i f) := + separatelyNormal_curryMid e _ + (cochainUnitaryTransport_normal e (unitaryPrefix u (i.val + 1)) f hf) i 1 + +variable {G : Type v} [Group G] [Fintype G] + +lemma finiteGroupPrefixAverage_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (ρ : G →* unitary M) (k : ℕ) (f : Cochain M (n + 1)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (finiteGroupPrefixAverage ρ k f) := by + unfold finiteGroupPrefixAverage + apply separatelyNormal_smul e + apply separatelyNormal_sum e + intro g _ + exact cochainUnitaryTransport_normal e _ f hf + +lemma finiteGroupBarInsertion_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (ρ : G →* unitary M) (i : Fin (n + 2)) + (f : Cochain M (n + 2)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (finiteGroupBarInsertion ρ i f) := by + unfold finiteGroupBarInsertion + apply separatelyNormal_smul e + apply separatelyNormal_sum e + intro g _ + exact barInsertion_normal e _ i f hf + +lemma finiteGroupBarOperator_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (ρ : G →* unitary M) (f : Cochain M (n + 2)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (finiteGroupBarOperator ρ f) := by + unfold finiteGroupBarOperator + apply separatelyNormal_sum e + intro i _ + exact separatelyNormal_smul e _ _ (finiteGroupBarInsertion_normal e ρ i f hf) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalCochainTransport.lean b/lean/OAI/Analysis/BoundedHochschild/NormalCochainTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..c9b9df9313560f13218e9d627b198a6ea908aef2 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalCochainTransport.lean @@ -0,0 +1,110 @@ +import OAI.Analysis.BoundedHochschild.FiniteGroupCochainAverages + +namespace OAI + +/-! Unitary transport and finite cochain averaging preserve separate +normality. Normalizing an input also commutes with unitary transport. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [CompleteSpace X] in +lemma cochainUnitaryTuple_update {n : ℕ} (u : Fin (n + 2) → unitary M) + (x : Fin (n + 1) → M) (i : Fin (n + 1)) (a : M) : + cochainUnitaryTuple u (Function.update x i a) = + Function.update (cochainUnitaryTuple u x) i + ((u i.castSucc : M) * a * star (u i.succ : M)) := by + ext j + by_cases hji : j = i + · subst j + simp [cochainUnitaryTuple] + · simp [cochainUnitaryTuple, hji] + +private def inputTransport {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) : + M →L[ℂ] M := + ((ContinuousLinearMap.mul ℂ M).flip (star (u i.succ : M))).comp + (ContinuousLinearMap.mul ℂ M (u i.castSucc : M)) + +private def outputTransport {n : ℕ} (u : Fin (n + 2) → unitary M) : M →L[ℂ] M := + ((ContinuousLinearMap.mul ℂ M).flip (u (Fin.last (n + 1)) : M)).comp + (ContinuousLinearMap.mul ℂ M (star (u 0 : M))) + +private lemma inputTransport_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (u : Fin (n + 2) → unitary M) (i : Fin (n + 1)) : + HasPreadjoint e (inputTransport u i) := + ((HochschildSakai.abstract_multiplication_normal e).2 _).comp e + ((HochschildSakai.abstract_multiplication_normal e).1 _) + +private lemma outputTransport_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (u : Fin (n + 2) → unitary M) : HasPreadjoint e (outputTransport u) := + ((HochschildSakai.abstract_multiplication_normal e).2 _).comp e + ((HochschildSakai.abstract_multiplication_normal e).1 _) + +private lemma transport_updateSlice {n : ℕ} (u : Fin (n + 2) → unitary M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) (x : Fin (n + 1) → M) : + updateSlice (cochainUnitaryTransport u f) i x = + (outputTransport u).comp ((updateSlice f i (cochainUnitaryTuple u x)).comp (inputTransport u i)) := by + ext a + simp only [updateSlice_apply, cochainUnitaryTransport_apply, cochainUnitaryTuple_update, + ContinuousLinearMap.comp_apply, inputTransport, outputTransport, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] + +lemma cochainUnitaryTransport_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (u : Fin (n + 2) → unitary M) (f : Cochain M (n + 1)) + (hf : SeparatelyNormal e f) : SeparatelyNormal e (cochainUnitaryTransport u f) := by + intro i x z + have hn : HasPreadjoint e (updateSlice (cochainUnitaryTransport u f) i x) := by + rw [transport_updateSlice] + exact (outputTransport_normal e u).comp e + ((updateSlice_normal e f hf i _).comp e (inputTransport_normal e u i)) + obtain ⟨w, hw⟩ := hn z + exact ⟨w, fun a => by simpa only [updateSlice_apply] using hw a⟩ + +omit [CompleteSpace X] in +lemma separatelyNormal_smul (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {n : ℕ} (z : ℂ) (f : Cochain M (n + 1)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (z • f) := by + intro i x w + have he : updateSlice (z • f) i x = z • updateSlice f i x := by + ext a + simp only [updateSlice_apply, smul_apply] + have hn : HasPreadjoint e (updateSlice (z • f) i x) := by + rw [he] + exact (updateSlice_normal e f hf i x).smul e z + obtain ⟨w', hw'⟩ := hn w + exact ⟨w', fun a => by simpa only [updateSlice_apply] using hw' a⟩ + +omit [CompleteSpace X] in +lemma separatelyNormal_sum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {I : Type v} (s : Finset I) {n : ℕ} (f : I → Cochain M (n + 1)) + (hf : ∀ j ∈ s, SeparatelyNormal e (f j)) : SeparatelyNormal e (∑ j ∈ s, f j) := by + intro i x w + have he : updateSlice (∑ j ∈ s, f j) i x = ∑ j ∈ s, updateSlice (f j) i x := by + ext a + simp only [updateSlice_apply, sum_apply] + have hn : HasPreadjoint e (updateSlice (∑ j ∈ s, f j) i x) := by + rw [he] + exact HasPreadjoint.sum e s _ (fun j hj => updateSlice_normal e (f j) (hf j hj) i x) + obtain ⟨w', hw'⟩ := hn w + exact ⟨w', fun a => by simpa only [updateSlice_apply] using hw' a⟩ + +lemma finiteGroupCochainAverage_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {G : Type v} [Group G] [Fintype G] (ρ : G →* unitary M) + {n : ℕ} (f : Cochain M (n + 1)) (hf : SeparatelyNormal e f) : + SeparatelyNormal e (finiteGroupCochainAverage ρ f) := by + unfold finiteGroupCochainAverage + apply separatelyNormal_smul e + apply separatelyNormal_sum e + intro g _ + exact cochainUnitaryTransport_normal e _ f hf + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalFactorCandidates.lean b/lean/OAI/Analysis/BoundedHochschild/NormalFactorCandidates.lean new file mode 100644 index 0000000000000000000000000000000000000000..6a6d0baeed815729a16bf36aba236315170651a5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalFactorCandidates.lean @@ -0,0 +1,31 @@ +import OAI.Analysis.BoundedHochschild.RepresentedAveragingOrbit +import OAI.Analysis.BoundedHochschild.NormalGNSWeakTopology + +namespace OAI + +/-! The compact factorization construction for the given W*-algebra predual. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +theorem normalGNS_representation_ball_closed (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (C : ℝ) : + IsClosed (representationWeakBall (normalGNSRepresentation e) C) := + normalGNSWeak_ball_isClosed e C + +theorem normalGNS_factorization [Nontrivial M] (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : M →L[ℂ] M) {C : ℝ} (hC : 0 < C) (hT : CompletelyBoundedEstimate T C) : + Nonempty (OperatorFactorization + ((normalGNSRepresentation e).toLinearMap.comp T.toLinearMap) C) := by + let := normalGNS_nontrivial e + exact represented_factorization (normalGNSRepresentation e) T hC hT + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalGNSConvergence.lean b/lean/OAI/Analysis/BoundedHochschild/NormalGNSConvergence.lean new file mode 100644 index 0000000000000000000000000000000000000000..ee14e2f8f8723d54e5a2a20171b6a69921f0bbd0 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalGNSConvergence.lean @@ -0,0 +1,75 @@ +import OAI.Analysis.BoundedHochschild.NormalGNSWeakTopology + +namespace OAI + +/-! On bounded nets the given predual topology agrees with weak operator +convergence in the faithful normal representation. -/ + +noncomputable section + +open Filter Topology +open scoped InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +open HochschildNormalPart + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma normalGNS_predual_tendsto (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {I : Type*} {l : Filter I} {a : I → M} {b : M} (h : PredualTendsto e a l b) + (ξ η : NormalGNS e) : + Tendsto (fun i => inner ℂ η (normalGNSRepresentation e (a i) ξ)) l + (𝓝 (inner ℂ η (normalGNSRepresentation e b ξ))) := by + obtain ⟨x, hx⟩ := (mem_normalDual e _).mp (normalGNSRepresentation_coefficients e η ξ) + change Tendsto (fun i => coefficient (normalGNSRepresentation e) η ξ (a i)) l + (𝓝 (coefficient (normalGNSRepresentation e) η ξ b)) + simpa only [hx] using (h x).star + +lemma predual_tendsto_of_normalGNS (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {I : Type*} {l : Filter I} {a : I → M} {b : M} {C : ℝ} + (hbdd : ∀ᶠ i in l, ‖a i‖ ≤ C) + (h : ∀ ξ η : NormalGNS e, + Tendsto (fun i => inner ℂ η (normalGNSRepresentation e (a i) ξ)) l + (𝓝 (inner ℂ η (normalGNSRepresentation e b ξ)))) : + PredualTendsto e a l b := by + let f (i : I) : WeakDual ℂ X := StrongDual.toWeakDual (e.symm (a i)) + let g : WeakDual ℂ X := StrongDual.toWeakDual (e.symm b) + let B : Set (WeakDual ℂ X) := {F | ‖WeakDual.toStrongDual F‖ ≤ C} + have hB : IsCompact B := by + have heq : B = WeakDual.toStrongDual ⁻¹' Metric.closedBall (0 : StrongDual ℂ X) C := by + ext F + simp only [B, Set.mem_ofPred_eq, Set.mem_preimage, Metric.mem_closedBall, dist_zero_right] + rw [heq] + exact WeakDual.isCompact_closedBall (0 : StrongDual ℂ X) C + have hf : ∀ᶠ i in l, f i ∈ B := by + filter_upwards [hbdd] with i hi + change ‖e.symm (a i)‖ ≤ C + simpa only [e.symm.norm_map] using hi + have he (i : I) : normalGNSWeak e (f i) = + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e (a i)) := by + change ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e (e (e.symm (a i)))) = _ + rw [e.apply_symm_apply] + have heg : normalGNSWeak e g = ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e b) := by + change ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e (e (e.symm b))) = _ + rw [e.apply_symm_apply] + have ht : Tendsto (normalGNSWeak e ∘ f) l (𝓝 (normalGNSWeak e g)) := by + simp only [Function.comp_def, he, heg] + exact ContinuousLinearMapWOT.tendsto_iff_forall_inner_apply_tendsto.mpr h + have hfg : Tendsto f l (𝓝 g) := by + apply hB.tendsto_nhds_of_unique_mapClusterPt hf + intro F _ hF + apply normalGNSWeak_injective e + have hc := hF.continuousAt_comp (normalGNSWeak_continuous e).continuousAt + have hc' : (𝓝 (normalGNSWeak e F) ⊓ map (normalGNSWeak e ∘ f) l).NeBot := hc + exact eq_of_nhds_neBot (hc'.mono (inf_le_inf_left _ ht)) + intro x + exact (WeakDual.eval_continuous x).continuousAt.tendsto.comp hfg + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalGNSMatrices.lean b/lean/OAI/Analysis/BoundedHochschild/NormalGNSMatrices.lean new file mode 100644 index 0000000000000000000000000000000000000000..129a94fb86280c51ae849919a7dfa3416466ad0a --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalGNSMatrices.lean @@ -0,0 +1,49 @@ +import OAI.Analysis.BoundedHochschild.NormalGNSRepresentation +import OAI.Analysis.BoundedHochschild.CompletelyBoundedRows + +namespace OAI + +/-! The faithful normal realization preserves every finite matrix norm. +In particular it preserves the complete bounds used in right averaging. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Entrywise realization is isometric at each finite matrix size. -/ +theorem normalGNS_matrix_norm (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (n : ℕ) + (A : CStarMatrix (Fin n) (Fin n) M) : + ‖A.map (normalGNSRepresentation e)‖ = ‖A‖ := by + let π := CStarMatrix.mapₙₐ (n := Fin n) (normalGNSRepresentation e).toNonUnitalStarAlgHom + have hπ : Function.Injective π := + CStarMatrix.map_injective (normalGNSRepresentation_injective e) + exact NonUnitalStarAlgHom.norm_map π hπ A + +/-- The concrete Hilbert-space realization has the same complete bound as +the original map. No extra regularity of that map is required. -/ +theorem normalGNS_complete_bound_iff (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (T : M →L[ℂ] M) (C : ℝ) : + CompletelyBoundedEstimate T C ↔ 0 ≤ C ∧ + ∀ (n : ℕ) (A : CStarMatrix (Fin n) (Fin n) M), + ‖(A.map T).map (normalGNSRepresentation e)‖ ≤ C * ‖A‖ := by + simp only [normalGNS_matrix_norm, CompletelyBoundedEstimate] + +/-- The representation as a continuous linear map. -/ +def normalGNSLinear (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + M →L[ℂ] (NormalGNS e →L[ℂ] NormalGNS e) := + (normalGNSRepresentation e).toLinearMap.mkContinuous 1 (fun a => by + change ‖normalGNSRepresentation e a‖ ≤ 1 * ‖a‖ + rw [normalGNSRepresentation_norm, one_mul]) + +@[simp] lemma normalGNSLinear_apply (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a : M) : + normalGNSLinear e a = normalGNSRepresentation e a := rfl + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalGNSRepresentation.lean b/lean/OAI/Analysis/BoundedHochschild/NormalGNSRepresentation.lean new file mode 100644 index 0000000000000000000000000000000000000000..bf5c8a265ebc05685d85384922c863267950f5fb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalGNSRepresentation.lean @@ -0,0 +1,174 @@ +import OAI.Analysis.BoundedHochschild.UniversalGNSRepresentation + +namespace OAI + +/-! Restriction to normal vectors gives a faithful normal representation for +the specified predual, without a faithful scalar state assumption. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace +open Classical + +namespace BoundedHochschild.KadisonRingrose + +open HochschildNormalPart + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def NormalGNS (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : Type u := + normalVectors e (universalGNSRepresentation (M := M)) + +instance normalGNSNormedAddCommGroup (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + NormedAddCommGroup (NormalGNS e) := + inferInstanceAs (NormedAddCommGroup (normalVectors e (universalGNSRepresentation (M := M)))) + +instance normalGNSInnerProductSpace (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + InnerProductSpace ℂ (NormalGNS e) := + inferInstanceAs (InnerProductSpace ℂ (normalVectors e (universalGNSRepresentation (M := M)))) + +instance normalGNSCompleteSpace (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + CompleteSpace (NormalGNS e) := + inferInstanceAs (CompleteSpace (normalVectors e (universalGNSRepresentation (M := M)))) + +instance normalGNSCoe (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : CoeOut (NormalGNS e) (UniversalGNS M) := + ⟨Subtype.val⟩ + +def normalGNSOperator (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a : M) : + NormalGNS e →L[ℂ] NormalGNS e := + (universalGNSRepresentation a).restrict + (fun _ξ hξ => normalVectors_mul e universalGNSRepresentation hξ a) + +@[simp] lemma normalGNSOperator_coe (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (a : M) (ξ : NormalGNS e) : + (normalGNSOperator e a ξ : UniversalGNS M) = universalGNSRepresentation a ξ := rfl + +lemma normalGNSOperator_zero (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + normalGNSOperator e 0 = 0 := by + apply ContinuousLinearMap.ext + intro ξ + apply Subtype.ext + change universalGNSRepresentation (M := M) (0 : M) (ξ : UniversalGNS M) = 0 + simp + +lemma normalGNSOperator_one (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + normalGNSOperator e 1 = 1 := by + apply ContinuousLinearMap.ext + intro ξ + apply Subtype.ext + change universalGNSRepresentation (M := M) (1 : M) (ξ : UniversalGNS M) = (ξ : UniversalGNS M) + simp + +lemma normalGNSOperator_add (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a b : M) : + normalGNSOperator e (a + b) = normalGNSOperator e a + normalGNSOperator e b := by + apply ContinuousLinearMap.ext + intro ξ + apply Subtype.ext + change universalGNSRepresentation (M := M) (a + b) (ξ : UniversalGNS M) = + universalGNSRepresentation a (ξ : UniversalGNS M) + universalGNSRepresentation b (ξ : UniversalGNS M) + simp + +lemma normalGNSOperator_mul (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a b : M) : + normalGNSOperator e (a * b) = normalGNSOperator e a * normalGNSOperator e b := by + apply ContinuousLinearMap.ext + intro ξ + apply Subtype.ext + change universalGNSRepresentation (M := M) (a * b) (ξ : UniversalGNS M) = + universalGNSRepresentation a (universalGNSRepresentation b (ξ : UniversalGNS M)) + rw [map_mul] + rfl + +lemma normalGNSOperator_commutes (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (z : ℂ) : + normalGNSOperator e (algebraMap ℂ M z) = algebraMap ℂ (NormalGNS e →L[ℂ] NormalGNS e) z := by + apply ContinuousLinearMap.ext + intro ξ + apply Subtype.ext + change universalGNSRepresentation (M := M) (algebraMap ℂ M z) (ξ : UniversalGNS M) = z • (ξ : UniversalGNS M) + exact congrArg (fun A : UniversalGNS M →L[ℂ] UniversalGNS M => A (ξ : UniversalGNS M)) + ((universalGNSRepresentation (M := M)).commutes z) + +lemma normalGNSOperator_star (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a : M) : + normalGNSOperator e (star a) = star (normalGNSOperator e a) := by + rw [ContinuousLinearMap.star_eq_adjoint] + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro ξ η + change inner ℂ (universalGNSRepresentation (star a) (ξ : UniversalGNS M)) (η : UniversalGNS M) = + inner ℂ (ξ : UniversalGNS M) (universalGNSRepresentation a (η : UniversalGNS M)) + rw [map_star, ContinuousLinearMap.star_eq_adjoint] + exact ContinuousLinearMap.adjoint_inner_left _ _ _ + +def normalGNSRepresentation (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + M →⋆ₐ[ℂ] (NormalGNS e →L[ℂ] NormalGNS e) where + toFun := normalGNSOperator e + map_zero' := normalGNSOperator_zero e + map_one' := normalGNSOperator_one e + map_add' := normalGNSOperator_add e + map_mul' := normalGNSOperator_mul e + commutes' := normalGNSOperator_commutes e + map_star' := normalGNSOperator_star e + +@[simp] lemma normalGNSRepresentation_coe (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (a : M) (ξ : NormalGNS e) : + (normalGNSRepresentation e a ξ : UniversalGNS M) = universalGNSRepresentation a ξ := rfl + +lemma normalGNSRepresentation_coefficients (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (η ξ : NormalGNS e) : coefficient (normalGNSRepresentation e) η ξ ∈ normalDual e := by + have h := (mem_normalVectors e universalGNSRepresentation ξ).mp ξ.property (η : UniversalGNS M) + exact h + +/-- Every positive cyclic coefficient occurs in the universal representation. -/ +lemma universalGNS_positive_coefficient (ψ : M →ₚ[ℂ] ℂ) : + ∀ a : M, coefficient universalGNSRepresentation + (lp.single 2 ψ (positiveVector ψ)) (lp.single 2 ψ (positiveVector ψ)) a = ψ a := by + classical + intro a + rw [coefficient_apply, lp.inner_single_left, universalGNSRepresentation_apply, + lp.single_apply_self] + exact positiveVector_coefficient ψ a + +/-- The normal subrepresentation remains faithful even when there is no +faithful normal scalar state. -/ +theorem normalGNSRepresentation_injective (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + Function.Injective (normalGNSRepresentation e) := by + classical + apply (injective_iff_map_eq_zero _).mpr + intro a ha + have hzero (ξ : NormalGNS e) : universalGNSRepresentation a ξ = 0 := by + have h := congrArg (fun A : NormalGNS e →L[ℂ] NormalGNS e => + (A ξ : UniversalGNS M)) ha + exact h + have hcoef (η : UniversalGNS M) : + scalarNormalPart e (coefficient universalGNSRepresentation η η) a = 0 := by + rw [scalarNormalPart_coefficient, coefficient_apply] + have hp : normalProjection e universalGNSRepresentation η ∈ normalVectors e universalGNSRepresentation := + (normalVectors e universalGNSRepresentation).starProjection_apply_mem η + rw [hzero ⟨_, hp⟩, inner_zero_right] + have hnormal (φ : StrongDual ℂ M) (hφ : φ ∈ normalDual e) : φ a = 0 := by + obtain ⟨ψ, _, hψ⟩ := HochschildPositiveDecomposition.exists_four_positive φ + let f (i : Fin 4) : StrongDual ℂ M := coefficient universalGNSRepresentation + (lp.single 2 (ψ i) (positiveVector (ψ i))) + (lp.single 2 (ψ i) (positiveVector (ψ i))) + have hf (i : Fin 4) (b : M) : f i b = ψ i b := + universalGNS_positive_coefficient (ψ i) b + have heq : φ = f 0 - f 1 + Complex.I • (f 2 - f 3) := by + ext b + simpa only [add_apply, sub_apply, smul_apply, smul_eq_mul, hf] using hψ b + have hfzero (i : Fin 4) : scalarNormalPart e (f i) a = 0 := hcoef _ + rw [← scalarNormalPart_fixes e hφ, heq, map_add, map_sub, map_smul, map_sub] + simp only [add_apply, sub_apply, smul_apply, hfzero, smul_zero, sub_self, add_zero] + apply predual_separates e + intro z + simpa only [map_zero] using hnormal (predualEmbedding e z) ⟨z, rfl⟩ + +theorem normalGNSRepresentation_norm (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a : M) : + ‖normalGNSRepresentation e a‖ = ‖a‖ := + NonUnitalStarAlgHom.norm_map (normalGNSRepresentation e) + (normalGNSRepresentation_injective e) a + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalGNSWeakTopology.lean b/lean/OAI/Analysis/BoundedHochschild/NormalGNSWeakTopology.lean new file mode 100644 index 0000000000000000000000000000000000000000..0bef66e968565746e8a0aa824bfcc0bfe878c1f5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalGNSWeakTopology.lean @@ -0,0 +1,88 @@ +import OAI.Analysis.BoundedHochschild.NormalGNSRepresentation +import Mathlib.Analysis.InnerProductSpace.WeakOperatorTopology + +namespace OAI + +/-! On bounded sets the faithful normal representation preserves the weak-star +compactness needed to realize limits of the elementary averaging operators. -/ + +noncomputable section + +open Topology +open scoped InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +open HochschildNormalPart + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +def normalGNSWeak (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (F : WeakDual ℂ X) : + NormalGNS e →WOT[ℂ] NormalGNS e := + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e (e (WeakDual.toStrongDual F))) + +lemma normalGNSWeak_continuous (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + Continuous (normalGNSWeak e) := by + apply ContinuousLinearMapWOT.continuous_iff.mpr + intro ξ η + obtain ⟨x, hx⟩ := (mem_normalDual e _).mp (normalGNSRepresentation_coefficients e η ξ) + have heq : (fun F : WeakDual ℂ X => inner ℂ η (normalGNSWeak e F ξ)) = + fun F => star (F x) := by + funext F + change coefficient (normalGNSRepresentation e) η ξ (e (WeakDual.toStrongDual F)) = _ + rw [hx, e.symm_apply_apply] + rfl + rw [heq] + exact (WeakDual.eval_continuous x).star + +lemma normalGNSWeak_injective (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + Function.Injective (normalGNSWeak e) := by + intro F G h + have hrep := congrArg ContinuousLinearMapWOT.toCLM h + have he := normalGNSRepresentation_injective e hrep + have hd := e.injective he + exact DFunLike.ext _ _ (fun x => congrArg (fun f : StrongDual ℂ X => f x) hd) + +lemma normalGNSWeak_image_ball (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (C : ℝ) : + normalGNSWeak e '' {F : WeakDual ℂ X | ‖WeakDual.toStrongDual F‖ ≤ C} = + {A : NormalGNS e →WOT[ℂ] NormalGNS e | ∃ a : M, ‖a‖ ≤ C ∧ + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e a) = A} := by + ext A + constructor + · rintro ⟨F, hF, rfl⟩ + change ‖WeakDual.toStrongDual F‖ ≤ C at hF + exact ⟨e (WeakDual.toStrongDual F), by simpa only [e.norm_map] using hF, rfl⟩ + · rintro ⟨a, ha, rfl⟩ + refine ⟨StrongDual.toWeakDual (e.symm a), ?_, ?_⟩ + · change ‖e.symm a‖ ≤ C + simpa only [e.symm.norm_map] using ha + · change ContinuousLinearMapWOT.ofCLM + (normalGNSRepresentation e (e (e.symm a))) = _ + rw [e.apply_symm_apply] + +/-- Norm balls of the represented algebra are weak-operator compact. -/ +theorem normalGNSWeak_ball_isCompact (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (C : ℝ) : + IsCompact {A : NormalGNS e →WOT[ℂ] NormalGNS e | ∃ a : M, ‖a‖ ≤ C ∧ + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e a) = A} := by + rw [← normalGNSWeak_image_ball] + have heq : {F : WeakDual ℂ X | ‖WeakDual.toStrongDual F‖ ≤ C} = + WeakDual.toStrongDual ⁻¹' Metric.closedBall (0 : StrongDual ℂ X) C := by + ext F + simp only [Set.mem_ofPred_eq, Set.mem_preimage, Metric.mem_closedBall, dist_zero_right] + rw [heq] + exact (WeakDual.isCompact_closedBall (0 : StrongDual ℂ X) C).image (normalGNSWeak_continuous e) + +/-- A bounded weak-operator limit in this representation still belongs to the +original algebra with the same bound. -/ +theorem normalGNSWeak_ball_isClosed (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (C : ℝ) : + IsClosed {A : NormalGNS e →WOT[ℂ] NormalGNS e | ∃ a : M, ‖a‖ ≤ C ∧ + ContinuousLinearMapWOT.ofCLM (normalGNSRepresentation e a) = A} := + (normalGNSWeak_ball_isCompact e C).isClosed + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalInfiniteAverages.lean b/lean/OAI/Analysis/BoundedHochschild/NormalInfiniteAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..6972c15234ae919f5fc54e1c499551dfe89261cb --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalInfiniteAverages.lean @@ -0,0 +1,56 @@ +import OAI.Analysis.BoundedHochschild.InfiniteRepresentedAverages +import OAI.Analysis.BoundedHochschild.NormalFactorCandidates +import OAI.Analysis.BoundedHochschild.NormalGNSConvergence + +namespace OAI + +/-! Infinite normalized right averages remain valued in the original algebra. +The proof realizes their lifted strong limits through the closed represented +algebra balls, without a normality assumption on the auxiliary representation. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + {I K : Type*} [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma normalGNS_row_limit (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (m : I → M) + (hlim : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, m i * star (m i)) atTop 1) + (ξ : NormalGNS e) : + Tendsto (fun s : Finset I => inner ℂ ξ + (normalGNSRepresentation e (∑ i ∈ s, m i * star (m i)) ξ)) + atTop (𝓝 (inner ℂ ξ ξ)) := by + simpa only [map_one, one_apply_eq_self] using normalGNS_predual_tendsto e hlim ξ ξ + +theorem normal_infinite_average_realize (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (L W : NormalGNS e →L[ℂ] K) + (T : M →L[ℂ] M) + (hT : ∀ a, normalGNSRepresentation e (T a) = L.adjoint.comp ((π a).comp W)) + (m : I → M) (hm : ∀ s : Finset I, ∑ i ∈ s, m i * star (m i) ≤ 1) + (hlim : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, m i * star (m i)) atTop 1) : + ∃ S : M →L[ℂ] M, ‖S‖ ≤ ‖L‖ * ‖W‖ ∧ ∀ a, + normalGNSRepresentation e (S a) = L.adjoint.comp ((π a).comp + (infiniteRepresentedRightAverage π (normalGNSRepresentation e) m hm W)) := by + let W₀ := ContinuousLinearMapWOT.ofCLM W + have hW₀ : W₀ ∈ factorCandidates (normalGNSRepresentation e) π L ‖W‖ := by + apply mem_factorCandidates_of_range _ (normalGNSRepresentation_injective e) π L le_rfl + exact fun a => ⟨T a, hT a⟩ + have hmem := infiniteRepresentedRightAverage_mem_closed_orbit π (normalGNSRepresentation e) + m hm (normalGNS_row_limit e m hlim) W₀ + have hW₁ := closedRepresentedAveragingOrbit_subset_candidates (normalGNSRepresentation e) + (normalGNSRepresentation_injective e) (normalGNS_representation_ball_closed e) + π L (norm_nonneg W) hW₀ hmem + exact factorCandidates_realize (normalGNSRepresentation e) (normalGNSRepresentation_injective e) + π L (norm_nonneg W) hW₁ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalModulus.lean b/lean/OAI/Analysis/BoundedHochschild/NormalModulus.lean new file mode 100644 index 0000000000000000000000000000000000000000..fc92d19817f84a2197eb9f9055edaa845c69c652 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalModulus.lean @@ -0,0 +1,347 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PrimitiveAverages + +namespace OAI + +/-! Normal cochains, bounded-ball continuity and primitive construction. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildRigidity +variable {M X I : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +lemma preGNS_zero_of_predual_limit + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) {a : I → M} {l : Filter I} [l.NeBot] {b : M} + (ha : Tendsto (fun i => ‖τ.toPreGNS (a i)‖) l (𝓝 0)) + (hb : PredualTendsto e a l b) : ‖τ.toPreGNS b‖ = 0 := by + apply le_antisymm _ (norm_nonneg _) + apply le_of_forall_pos_le_add + intro ε hε + simpa only [zero_add] using preGNS_norm_le_of_predual_tendsto e τ hL hτ ε hε.le + (ha.eventually (ge_mem_nhds hε)) hb + + + +theorem predual_tendsto_of_preGNS + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + {a : I → M} {l : Filter I} (C : ℝ) (ha : ∀ i, ‖a i‖ ≤ C) {b : M} + (hb : Tendsto (fun i => ‖τ.toPreGNS (a i-b)‖) l (𝓝 0)) : + PredualTendsto e a l b := by + intro z + apply (tendsto_iff_ultrafilter _ _ _).mpr + intro u hu + obtain ⟨c,_hc,ht⟩ := exists_predual_ultralimit e u a C ha + have hzero := preGNS_zero_of_predual_limit e τ hL hτ (hb.mono_left hu) + (predual_tendsto_sub e ht (predual_tendsto_const e b (u : Filter I))) + have hcb : c=b := by + apply sub_eq_zero.mp + exact (preGNS_norm_eq_zero_iff τ hfaith (c-b)).mp hzero + simpa only [hcb] using ht z + + + +theorem exists_bounded_preGNS_limit + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) {a : ℕ → M} (C : ℝ) (ha : ∀ i, ‖a i‖ ≤ C) + (hc : CauchySeq (fun i => τ.toPreGNS (a i))) : + ∃ b : M, ‖b‖ ≤ C ∧ Tendsto (fun i => ‖τ.toPreGNS (a i-b)‖) atTop (𝓝 0) := by + let u : Ultrafilter ℕ := Ultrafilter.of atTop + have hu : (u : Filter ℕ) ≤ atTop := Ultrafilter.of_le _ + obtain ⟨b,hb,ht⟩ := exists_predual_ultralimit e u a C ha + refine ⟨b,hb,?_⟩ + apply Metric.tendsto_atTop.mpr + intro ε hε + obtain ⟨N,hN⟩ := Metric.cauchySeq_iff.mp hc (ε/2) (half_pos hε) + refine ⟨N,fun n hn => ?_⟩ + have hsmall : ∀ᶠ m in (u : Filter ℕ), ‖τ.toPreGNS (a n-a m)‖ ≤ ε/2 := by + apply hu + filter_upwards [eventually_ge_atTop N] with m hm + simpa only [map_sub,← dist_eq_norm] using (hN n hn m hm).le + have hbound := preGNS_norm_le_of_predual_tendsto e τ hL hτ (ε/2) (half_pos hε).le + hsmall (predual_tendsto_sub e (predual_tendsto_const e (a n) (u : Filter ℕ)) ht) + simpa only [Real.dist_eq,sub_zero,abs_norm] using hbound.trans_lt (half_lt_self hε) + +lemma preGNS_sq_le_trace (a : M) (ha : 0 ≤ a) (ha1 : a ≤ 1) : + ‖τ.toPreGNS a‖^2 ≤ (τ a).re := by + have hs := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS a)) + simp only [PositiveLinearMap.ofPreGNS_toPreGNS, + (IsSelfAdjoint.of_nonneg ha).star_eq,← Complex.ofReal_pow,Complex.ofReal_re] at hs + rw [hs] + apply Complex.re_le_re + apply τ.monotone + simpa only [pow_two,pow_one] using CStarAlgebra.pow_antitone ha1 ha (show 1 ≤ 2 by omega) + +lemma monotone_contractions_preGNS_cauchy (a : ℕ → M) (h0 : ∀ n, 0 ≤ a n) + (h1 : ∀ n, a n ≤ 1) (hm : Monotone a) : CauchySeq (fun n => τ.toPreGNS (a n)) := by + have hmono : Monotone (fun n => (τ (a n)).re) := fun n m hnm => + Complex.re_le_re (τ.monotone (hm hnm)) + have hbdd : BddAbove (Set.range (fun n => (τ (a n)).re)) := + ⟨(τ 1).re,fun _ ⟨n,hn⟩ => hn ▸ Complex.re_le_re (τ.monotone (h1 n))⟩ + have hc := (tendsto_atTop_ciSup hmono hbdd).cauchySeq + apply Metric.cauchySeq_iff'.mpr + intro ε hε + obtain ⟨N,hN⟩ := Metric.cauchySeq_iff'.mp hc (ε^2) (sq_pos_of_pos hε) + refine ⟨N,fun n hn => ?_⟩ + have hd0 : 0 ≤ a n-a N := sub_nonneg.mpr (hm hn) + have hd1 : a n-a N ≤ 1 := (sub_le_self _ (h0 N)).trans (h1 n) + have hsq := preGNS_sq_le_trace τ (a n-a N) hd0 hd1 + have hdiff := hN n hn + rw [Real.dist_eq,abs_of_nonneg (sub_nonneg.mpr (hmono hn))] at hdiff + simp only [map_sub,Complex.sub_re] at hsq + rw [dist_eq_norm] + nlinarith [norm_nonneg (τ.toPreGNS (a n)-τ.toPreGNS (a N))] + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildRigidity +variable {M I : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable (τ : M →ₚ[ℂ] ℂ) + +def GNSTendsto (a : I → M) (l : Filter I) (b : M) : Prop := + Tendsto (fun i => ‖τ.toPreGNS (a i-b)‖) l (𝓝 0) + +lemma GNSTendsto.const (b : M) (l : Filter I) : GNSTendsto τ (fun _ => b) l b := by + simp only [GNSTendsto,sub_self,map_zero,norm_zero] + exact tendsto_const_nhds + +lemma GNSTendsto.add {a c : I → M} {l : Filter I} {b d : M} + (ha : GNSTendsto τ a l b) (hc : GNSTendsto τ c l d) : + GNSTendsto τ (fun i => a i+c i) l (b+d) := by + apply squeeze_zero (fun _ => norm_nonneg _) (fun i => ?_) (by simpa only [add_zero] using Filter.Tendsto.add ha hc) + rw [show a i+c i-(b+d)=(a i-b)+(c i-d) by abel,map_add] + exact norm_add_le _ _ + +lemma GNSTendsto.neg {a : I → M} {l : Filter I} {b : M} (ha : GNSTendsto τ a l b) : + GNSTendsto τ (fun i => -a i) l (-b) := by + simpa only [GNSTendsto,neg_sub_neg,← neg_sub (a := b),map_neg,norm_neg] using ha + +lemma GNSTendsto.sub {a c : I → M} {l : Filter I} {b d : M} + (ha : GNSTendsto τ a l b) (hc : GNSTendsto τ c l d) : + GNSTendsto τ (fun i => a i-c i) l (b-d) := by + simpa only [sub_eq_add_neg] using ha.add τ (hc.neg τ) + +lemma GNSTendsto.star (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + {a : I → M} {l : Filter I} {b : M} (ha : GNSTendsto τ a l b) : + GNSTendsto τ (fun i => star (a i)) l (star b) := by + simpa only [GNSTendsto,← star_sub,preGNS_norm_star τ htr] using ha + +lemma GNSTendsto.mul (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + {a c : I → M} {l : Filter I} {b d : M} + (ha : GNSTendsto τ a l b) (hc : GNSTendsto τ c l d) + (C : ℝ) (hC : ∀ i, ‖a i‖ ≤ C) : + GNSTendsto τ (fun i => a i*c i) l (b*d) := by + have ht := (hc.const_mul C).add (ha.const_mul ‖d‖) + simp only [mul_zero,add_zero] at ht + apply squeeze_zero (fun _ => norm_nonneg _) (fun i => ?_) ht + rw [show a i*c i-b*d=a i*(c i-d)+(a i-b)*d by noncomm_ring,map_add] + exact (norm_add_le _ _).trans (add_le_add + ((preGNS_norm_mul_le τ _ _).trans (mul_le_mul_of_nonneg_right (hC i) (norm_nonneg _))) + (preGNS_norm_mul_right_le τ htr _ _)) + +lemma GNSTendsto.unique (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + {a : I → M} {l : Filter I} [l.NeBot] {b c : M} + (hb : GNSTendsto τ a l b) (hc : GNSTendsto τ a l c) : b=c := by + have h : GNSTendsto τ (fun _ : I => (0:M)) l (b-c) := by + simpa only [sub_self] using hb.sub τ hc + have hz : ‖τ.toPreGNS (b-c)‖=0 := by + have ht : Tendsto (fun _ : I => ‖τ.toPreGNS (b-c)‖) l (𝓝 0) := by + simpa only [GNSTendsto,zero_sub,map_neg,norm_neg] using h + exact tendsto_nhds_unique tendsto_const_nhds ht + exact sub_eq_zero.mp ((preGNS_norm_eq_zero_iff τ hfaith _).mp hz) + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +include hL hτ hfaith in +lemma GNSTendsto.predual {a : ℕ → M} {b : M} (C : ℝ) (ha : ∀ n, ‖a n‖ ≤ C) + (ht : GNSTendsto τ a atTop b) : PredualTendsto e a atTop b := + predual_tendsto_of_preGNS e τ hL hτ hfaith C ha ht + +lemma norm_pow_pos_contraction (b : M) (hb0 : 0 ≤ b) (hb1 : b ≤ 1) (n : ℕ) : + ‖b^n‖ ≤ 1 := by + apply (CStarAlgebra.norm_le_one_iff_of_nonneg _ (CStarAlgebra.pow_nonneg b n hb0)).mpr + simpa only [pow_zero] using CStarAlgebra.pow_antitone hb1 hb0 (Nat.zero_le n) + +include e hL hτ htr hfaith in + + +theorem exists_power_projection (b : M) (hb0 : 0 ≤ b) (hb1 : b ≤ 1) : + ∃ p : M, IsStarProjection p ∧ GNSTendsto τ (fun n : ℕ => b^n) atTop p ∧ + b*p=p ∧ ∀ x : M, b*x=x → p*x=x := by + let a : ℕ → M := fun n => 1-b^n + have ha0 : ∀ n, 0 ≤ a n := fun n => sub_nonneg.mpr (by + simpa only [pow_zero] using CStarAlgebra.pow_antitone hb1 hb0 (Nat.zero_le n)) + have ha1 : ∀ n, a n ≤ 1 := fun n => sub_le_self _ (CStarAlgebra.pow_nonneg b n hb0) + have ham : Monotone a := fun n m hnm => sub_le_sub_left + (CStarAlgebra.pow_antitone hb1 hb0 hnm) 1 + obtain ⟨c,_hc,ht⟩ := exists_bounded_preGNS_limit e τ hL hτ 1 + (fun n => (CStarAlgebra.norm_le_one_iff_of_nonneg _ (ha0 n)).mpr (ha1 n)) + (monotone_contractions_preGNS_cauchy τ a ha0 ha1 ham) + let p : M := 1-c + have hp : GNSTendsto τ (fun n : ℕ => b^n) atTop p := by + simpa only [a,sub_sub_cancel] using (GNSTendsto.const τ (1:M) (atTop : Filter ℕ)).sub τ ht + have hpstar : star p=p := by + apply GNSTendsto.unique τ hfaith (hp.star τ htr) + simpa only [star_pow,(IsSelfAdjoint.of_nonneg hb0).star_eq] using hp + have htimes : Tendsto (fun n : ℕ => 2*n) atTop atTop := + tendsto_atTop_mono (fun n => by dsimp; omega) tendsto_id + have hpp : p*p=p := by + apply GNSTendsto.unique τ hfaith (hp.mul τ htr hp 1 (norm_pow_pos_contraction b hb0 hb1)) + simpa only [GNSTendsto,Function.comp_def,two_mul,pow_add] using + (show Tendsto (fun n : ℕ => ‖τ.toPreGNS (b^(2*n)-p)‖) atTop (𝓝 0) from hp.comp htimes) + have hbp : b*p=p := by + apply GNSTendsto.unique τ hfaith + ((GNSTendsto.const τ b (atTop : Filter ℕ)).mul τ htr hp ‖b‖ (fun _ => le_rfl)) + simpa only [GNSTendsto,Function.comp_def,pow_succ'] using hp.comp (tendsto_add_atTop_nat 1) + refine ⟨p,⟨hpp,hpstar⟩,hp,hbp,?_⟩ + intro x hx + have hpow (n : ℕ) : b^n*x=x := by + induction n with + | zero => simp + | succ n ih => rw [pow_succ',mul_assoc,ih,hx] + apply GNSTendsto.unique τ hfaith + (hp.mul τ htr (GNSTendsto.const τ x atTop) 1 (norm_pow_pos_contraction b hb0 hb1)) + simpa only [hpow] using GNSTendsto.const τ x (atTop : Filter ℕ) + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + + + +structure IsSupportProjection (a p : M) : Prop where + proj : IsStarProjection p + left : p*a=a + right : a*p=a + annihilate : ∀ x : M, a*x=0 → p*x=0 + +include e hL hτ htr hfaith in +lemma exists_support_contraction (a : M) (ha0 : 0 ≤ a) (ha1 : a ≤ 1) : + ∃ p : M, IsSupportProjection a p ∧ + GNSTendsto τ (fun n : ℕ => 1-(1-a)^n) atTop p := by + obtain ⟨q,hq,ht,hbq,hqx⟩ := exists_power_projection e τ hL hτ htr hfaith (1-a) + (sub_nonneg.mpr ha1) (sub_le_self _ ha0) + have haq : a*q=0 := by + have hh := hbq + rw [sub_mul,one_mul] at hh + exact sub_eq_self.mp hh + have hqa : q*a=0 := by + simpa only [star_mul,hq.isSelfAdjoint.star_eq,(IsSelfAdjoint.of_nonneg ha0).star_eq,star_zero] + using congrArg Star.star haq + refine ⟨1-q,⟨hq.one_sub,?_,?_,?_⟩,?_⟩ + · simp only [sub_mul,one_mul,hqa,sub_zero] + · simp only [mul_sub,mul_one,haq,sub_zero] + · intro x hx + have hbx : (1-a)*x=x := by simp only [sub_mul,one_mul,hx,sub_zero] + simp only [sub_mul,one_mul,hqx x hbx,sub_self] + · exact (GNSTendsto.const τ 1 (atTop : Filter ℕ)).sub τ ht + +include e hL hτ htr hfaith in + + +theorem exists_support_projection (a : M) (ha : 0 ≤ a) : + ∃ p : M, IsSupportProjection a p := by + let r : ℝ := ‖a‖+1 + have hr : 0 < r := by dsimp [r]; positivity + have hi : 0 < r⁻¹ := inv_pos.mpr hr + have hn : ‖r⁻¹ • a‖ ≤ 1 := by + rw [norm_smul,Real.norm_eq_abs,abs_of_pos hi] + exact (inv_mul_le_one₀ hr).mpr (by dsimp [r]; linarith) + have hsa : 0 ≤ r⁻¹ • a := smul_nonneg hi.le ha + obtain ⟨p,hp,_⟩ := exists_support_contraction e τ hL hτ htr hfaith (r⁻¹ • a) hsa + ((CStarAlgebra.norm_le_one_iff_of_nonneg _ hsa).mp hn) + refine ⟨p,hp.proj,?_,?_,?_⟩ + · have hh := congrArg (fun z : M => r • z) hp.left + simpa only [mul_smul_comm,smul_smul,mul_inv_cancel₀ hr.ne',one_smul] using hh + · have hh := congrArg (fun z : M => r • z) hp.right + simpa only [smul_mul_assoc,smul_smul,mul_inv_cancel₀ hr.ne',one_smul] using hh + · intro x hx + apply hp.annihilate x + simp only [smul_mul_assoc,hx,smul_zero] + +lemma IsSupportProjection.le_of_support {a p q : M} (hp : IsSupportProjection a p) + (hq : IsStarProjection q) (haq : a*q=a) : p ≤ q := by + apply (hp.proj.le_iff_mul_eq_left hq).mpr + have hh := hp.annihilate (1-q) (by simp only [mul_sub,mul_one,haq,sub_self]) + simpa only [mul_sub,mul_one,sub_eq_zero,eq_comm] using hh + +lemma IsSupportProjection.unique {a p q : M} (hp : IsSupportProjection a p) + (hq : IsSupportProjection a q) : p=q := + le_antisymm (hp.le_of_support hq.proj hq.right) (hq.le_of_support hp.proj hp.right) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma IsSupportProjection.mul_eq_zero_iff {a p : M} (hp : IsSupportProjection a p) (x : M) : + p*x=0 ↔ a*x=0 := by + constructor + · intro hx + rw [← hp.right,mul_assoc,hx,mul_zero] + · exact hp.annihilate x + +omit [PartialOrder M] [StarOrderedRing M] in +lemma IsSupportProjection.commute {a p c : M} (hp : IsSupportProjection a p) + (ha : IsSelfAdjoint a) (hc : Commute a c) : Commute p c := by + have block (b : M) (hb : Commute a b) : p*b=p*b*p := by + have hk : a*(b*(1-p))=0 := by + rw [← mul_assoc,hb.eq,mul_assoc,mul_sub,mul_one,hp.right,sub_self,mul_zero] + have hh := hp.annihilate (b*(1-p)) hk + rw [← mul_assoc,mul_sub,mul_one,sub_eq_zero] at hh + exact hh + have hs : Commute a (star c) := by + rw [commute_iff_eq] + have hh := congrArg Star.star hc.eq + simpa only [star_mul,ha.star_eq] using hh.symm + have hh := congrArg Star.star (block (star c) hs) + simp only [star_mul,star_star,hp.proj.isSelfAdjoint.star_eq] at hh + rw [commute_iff_eq] + exact (block c hc).trans (by simpa only [mul_assoc] using hh.symm) + +end BoundedHochschild +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularClosure.lean b/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularClosure.lean new file mode 100644 index 0000000000000000000000000000000000000000..6fd47f6c34e201b434d1cd0f655c1828653bb692 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularClosure.lean @@ -0,0 +1,110 @@ +import OAI.Analysis.BoundedHochschild.CountableMatrixPrimitives +import OAI.Analysis.TracialCohomology.HilbertFactorization + +namespace OAI + +/-! Separate normality extends the adjacent-input module identities from +the algebraic matrix algebra to its weak-star closure. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma normal_maps_eq_on_linearClosure (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (A : StarSubalgebra ℂ M) (T U : M →L[ℂ] M) + (hT : HasPreadjoint e T) (hU : HasPreadjoint e U) + (h : ∀ a ∈ A, T a = U a) {a : M} + (ha : (WeakAlgebra.weakEquiv e).symm a ∈ WeakAlgebra.linearClosure e A) : T a = U a := by + have hclosed : IsClosed {F : WeakDual ℂ X | + (WeakAlgebra.weakEquiv e).symm (T (WeakAlgebra.weakEquiv e F)) = + (WeakAlgebra.weakEquiv e).symm (U (WeakAlgebra.weakEquiv e F))} := + isClosed_eq (WeakAlgebra.normal_continuous e T hT) (WeakAlgebra.normal_continuous e U hU) + have hs : (WeakAlgebra.linearClosure e A : Set (WeakDual ℂ X)) ⊆ + {F | (WeakAlgebra.weakEquiv e).symm (T (WeakAlgebra.weakEquiv e F)) = + (WeakAlgebra.weakEquiv e).symm (U (WeakAlgebra.weakEquiv e F))} := by + apply closure_minimal _ hclosed + rintro F ⟨b, hb, rfl⟩ + change (WeakAlgebra.weakEquiv e).symm + (T (WeakAlgebra.weakEquiv e ((WeakAlgebra.weakEquiv e).symm b))) = + (WeakAlgebra.weakEquiv e).symm + (U (WeakAlgebra.weakEquiv e ((WeakAlgebra.weakEquiv e).symm b))) + rw [LinearEquiv.apply_symm_apply, h b hb] + simpa only [LinearEquiv.apply_symm_apply] using (WeakAlgebra.weakEquiv e).symm.injective (hs ha) + +def updateSlice {n : ℕ} (f : Cochain M (n + 1)) (i : Fin (n + 1)) + (v : Fin (n + 1) → M) : M →L[ℂ] M := sliceAt f i (i.removeNth v) + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma updateSlice_apply {n : ℕ} (f : Cochain M (n + 1)) (i : Fin (n + 1)) + (v : Fin (n + 1) → M) (a : M) : updateSlice f i v a = f (Function.update v i a) := by + simp only [updateSlice, sliceAt_apply, Fin.insertNth_removeNth] + +omit [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] in +lemma updateSlice_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (f : Cochain M (n + 1)) (hn : SeparatelyNormal e f) (i : Fin (n + 1)) + (v : Fin (n + 1) → M) : HasPreadjoint e (updateSlice f i v) := by + intro z + obtain ⟨w, hw⟩ := hn i v z + exact ⟨w, fun a => by simpa only [updateSlice_apply] using hw a⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +theorem normal_multimodular_countable_closure (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : ℕ → HochschildComparison.PartialIso M) {n : ℕ} (f : Cochain M (n + 1)) + (hn : SeparatelyNormal e f) (hf : MultimodularOver (countableMatrixAlgebra c) f) : + MultimodularOver (countableMatrixClosure e c) f := by + have hL := (HochschildSakai.abstract_multiplication_normal e).1 + have hR := (HochschildSakai.abstract_multiplication_normal e).2 + constructor + · intro r hr x + have h := normal_maps_eq_on_linearClosure e (countableMatrixAlgebra c) + ((updateSlice f 0 x).comp ((ContinuousLinearMap.mul ℂ M).flip (x 0))) + ((ContinuousLinearMap.mul ℂ M).flip (f x)) + ((updateSlice_normal e f hn 0 x).comp e (hR (x 0))) (hR (f x)) + (fun a ha => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using hf.left a ha x) hr + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using h + · intro r hr x + have h := normal_maps_eq_on_linearClosure e (countableMatrixAlgebra c) + ((updateSlice f (Fin.last n) x).comp (ContinuousLinearMap.mul ℂ M (x (Fin.last n)))) + (ContinuousLinearMap.mul ℂ M (f x)) + ((updateSlice_normal e f hn (Fin.last n) x).comp e (hL (x (Fin.last n)))) (hL (f x)) + (fun a ha => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.mul_apply'] using hf.right a ha x) hr + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.mul_apply'] using h + · intro r hr x j + have h := normal_maps_eq_on_linearClosure e (countableMatrixAlgebra c) + ((updateSlice f j.castSucc x).comp (ContinuousLinearMap.mul ℂ M (x j.castSucc))) + ((updateSlice f j.succ x).comp ((ContinuousLinearMap.mul ℂ M).flip (x j.succ))) + ((updateSlice_normal e f hn j.castSucc x).comp e (hL (x j.castSucc))) + ((updateSlice_normal e f hn j.succ x).comp e (hR (x j.succ))) + (fun a ha => by simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using hf.balance a ha x j) hr + simpa only [ContinuousLinearMap.comp_apply, updateSlice_apply, + ContinuousLinearMap.flip_apply, ContinuousLinearMap.mul_apply'] using h + +theorem primitive_of_normal_matrix_multimodular [Nontrivial M] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (hno : NoFiniteCentralSummand M) + (c : ℕ → HochschildComparison.PartialIso M) (hi : ∀ i, (c i).initial = 1) + (ho : ∀ i j, i ≠ j → (c i).final * (c j).final = 0) + (ht : PredualTendsto e (fun s : Finset ℕ => ∑ i ∈ s, (c i).final) Filter.atTop 1) + {n : ℕ} (f : Cochain M (n + 1)) (hn : SeparatelyNormal e f) + (hf : MultimodularOver (countableMatrixAlgebra c) f) + (hcocycle : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := + primitive_of_countableMatrix_multimodular e hno c hi ho ht f + (normal_multimodular_countable_closure e c f hn hf) hcocycle + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularity.lean b/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularity.lean new file mode 100644 index 0000000000000000000000000000000000000000..c87ed5041e5524c94f95b934c12c847d465bb7ad --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalMultimodularity.lean @@ -0,0 +1,146 @@ +import OAI.Analysis.BoundedHochschild.NormalCochainTransport +import OAI.Analysis.BoundedHochschild.MultimodularGenerators + +namespace OAI + +/-! Input normalization respects the usual module identities. Only left +and right multiplication are needed for this naturality statement. -/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +private def multiplyBoth (a b : M) : M →L[ℂ] M := + ((ContinuousLinearMap.mul ℂ M).flip b).comp (ContinuousLinearMap.mul ℂ M a) + +private lemma multiplyBoth_apply (a b x : M) : multiplyBoth a b x = a * x * b := rfl + +private lemma multiplyBoth_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (a b : M) : + HasPreadjoint e (multiplyBoth a b) := + ((HochschildSakai.abstract_multiplication_normal e).2 b).comp e + ((HochschildSakai.abstract_multiplication_normal e).1 a) + +def cochainSandwich {n : ℕ} (a b : Fin n → M) (c d : M) (f : Cochain M n) : Cochain M n := + (multiplyBoth c d).compContinuousMultilinearMap + (f.compContinuousLinearMap (fun i => multiplyBoth (a i) (b i))) + +@[simp] lemma cochainSandwich_apply {n : ℕ} (a b : Fin n → M) (c d : M) + (f : Cochain M n) (x : Fin n → M) : + cochainSandwich a b c d f x = c * f (fun i => a i * x i * b i) * d := rfl + +private lemma sandwich_update {n : ℕ} (a b x : Fin (n + 1) → M) (i : Fin (n + 1)) (z : M) : + (fun j => a j * Function.update x i z j * b j) = + Function.update (fun j => a j * x j * b j) i (a i * z * b i) := by + ext j + by_cases hji : j = i <;> simp [hji] + +private lemma sandwich_slice {n : ℕ} (a b : Fin (n + 1) → M) (c d : M) + (f : Cochain M (n + 1)) (i : Fin (n + 1)) (x : Fin (n + 1) → M) : + updateSlice (cochainSandwich a b c d f) i x = + (multiplyBoth c d).comp + ((updateSlice f i (fun j => a j * x j * b j)).comp (multiplyBoth (a i) (b i))) := by + ext z + simp only [updateSlice_apply, cochainSandwich_apply, sandwich_update, + ContinuousLinearMap.comp_apply, multiplyBoth_apply] + +lemma normalAt_value (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (f : Cochain M (n + 1)) (i : Fin (n + 1)) (x : Fin (n + 1) → M) : + normalAt e f i x = HochschildNormalPart.operatorNormalPart e (updateSlice f i x) (x i) := by + calc + _ = normalAt e f i (i.insertNth (x i) (i.removeNth x)) := + congrArg (normalAt e f i) (Fin.insertNth_self_removeNth i x).symm + _ = _ := normalAt_insert e f i (i.removeNth x) (x i) + +lemma normalAt_cochainSandwich (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (a b : Fin (n + 1) → M) (c d : M) (f : Cochain M (n + 1)) (i : Fin (n + 1)) : + normalAt e (cochainSandwich a b c d f) i = cochainSandwich a b c d (normalAt e f i) := by + ext x + rw [normalAt_value, sandwich_slice, + HochschildNormalPart.operatorNormalPart_comp_normal e _ _ (multiplyBoth_normal e c d)] + have hin (T : M →L[ℂ] M) : + HochschildNormalPart.operatorNormalPart e (T.comp (multiplyBoth (a i) (b i))) = + (HochschildNormalPart.operatorNormalPart e T).comp (multiplyBoth (a i) (b i)) := by + unfold multiplyBoth + rw [← ContinuousLinearMap.comp_assoc, + HochschildNormalPart.operatorNormalPart_comp_left, + HochschildNormalPart.operatorNormalPart_comp_right, + ContinuousLinearMap.comp_assoc] + rw [hin] + simp only [cochainSandwich_apply, normalAt_value, + ContinuousLinearMap.comp_apply, multiplyBoth_apply] + +lemma cochainSandwich_leftInput {n : ℕ} (f : Cochain M (n + 1)) (k : Fin (n + 1)) + (r : M) (x : Fin (n + 1) → M) : + cochainSandwich (Function.update (fun _ => 1) k r) (fun _ => 1) 1 1 f x = + f (Function.update x k (r * x k)) := by + rw [cochainSandwich_apply, one_mul, mul_one] + congr 1 + ext j + by_cases hj : j = k <;> simp [hj] + +lemma cochainSandwich_rightInput {n : ℕ} (f : Cochain M (n + 1)) (k : Fin (n + 1)) + (r : M) (x : Fin (n + 1) → M) : + cochainSandwich (fun _ => 1) (Function.update (fun _ => 1) k r) 1 1 f x = + f (Function.update x k (x k * r)) := by + rw [cochainSandwich_apply, one_mul, mul_one] + congr 1 + ext j + by_cases hj : j = k <;> simp [hj] + +lemma cochainSandwich_leftOutput {n : ℕ} (f : Cochain M n) (r : M) (x : Fin n → M) : + cochainSandwich (fun _ => 1) (fun _ => 1) r 1 f x = r * f x := by + simp only [cochainSandwich_apply, one_mul, mul_one] + +lemma cochainSandwich_rightOutput {n : ℕ} (f : Cochain M n) (r : M) (x : Fin n → M) : + cochainSandwich (fun _ => 1) (fun _ => 1) 1 r f x = f x * r := by + simp only [cochainSandwich_apply, one_mul, mul_one] + +lemma normalAt_multimodularAt (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (f : Cochain M (n + 1)) (i : Fin (n + 1)) (r : M) (hf : MultimodularAt f r) : + MultimodularAt (normalAt e f i) r := by + constructor + · intro x + have h : cochainSandwich (Function.update (fun _ => 1) 0 r) (fun _ => 1) 1 1 f = + cochainSandwich (fun _ => 1) (fun _ => 1) r 1 f := by + ext y + simpa only [cochainSandwich_leftInput, cochainSandwich_leftOutput] using hf.left y + have hh := congrArg (fun F : Cochain M (n + 1) => normalAt e F i) h + simp only [normalAt_cochainSandwich] at hh + simpa only [cochainSandwich_leftInput, cochainSandwich_leftOutput] using + congrArg (fun F : Cochain M (n + 1) => F x) hh + · intro x + have h : cochainSandwich (fun _ => 1) (Function.update (fun _ => 1) (Fin.last n) r) 1 1 f = + cochainSandwich (fun _ => 1) (fun _ => 1) 1 r f := by + ext y + simpa only [cochainSandwich_rightInput, cochainSandwich_rightOutput] using hf.right y + have hh := congrArg (fun F : Cochain M (n + 1) => normalAt e F i) h + simp only [normalAt_cochainSandwich] at hh + simpa only [cochainSandwich_rightInput, cochainSandwich_rightOutput] using + congrArg (fun F : Cochain M (n + 1) => F x) hh + · intro x j + have h : cochainSandwich (fun _ => 1) (Function.update (fun _ => 1) j.castSucc r) 1 1 f = + cochainSandwich (Function.update (fun _ => 1) j.succ r) (fun _ => 1) 1 1 f := by + ext y + simpa only [cochainSandwich_rightInput, cochainSandwich_leftInput] using hf.balance y j + have hh := congrArg (fun F : Cochain M (n + 1) => normalAt e F i) h + simp only [normalAt_cochainSandwich] at hh + simpa only [cochainSandwich_rightInput, cochainSandwich_leftInput] using + congrArg (fun F : Cochain M (n + 1) => F x) hh + +lemma normalAt_multimodularOver (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) {n : ℕ} + (R : StarSubalgebra ℂ M) (f : Cochain M (n + 1)) (i : Fin (n + 1)) + (hf : MultimodularOver R f) : MultimodularOver R (normalAt e f i) := by + have h (r : M) (hr : r ∈ R) := normalAt_multimodularAt e f i r + ⟨hf.left r hr, hf.right r hr, hf.balance r hr⟩ + exact ⟨fun r hr => (h r hr).left, fun r hr => (h r hr).right, + fun r hr => (h r hr).balance⟩ + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalMultiplication.lean b/lean/OAI/Analysis/BoundedHochschild/NormalMultiplication.lean new file mode 100644 index 0000000000000000000000000000000000000000..0246af51396cbe92d80616979ffc0e0134d01949 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalMultiplication.lean @@ -0,0 +1,206 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.SpectralProjections + +namespace OAI + +/-! Preadjoints for left and right multiplication. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open Filter Topology +namespace HochschildSakai +open BoundedHochschild +variable {M X I : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + +def leftMatrixFunctional (z : X) (b : M) : StrongDual ℂ (StrongDual ℂ X) := + let L : StrongDual ℂ X →ₗ[ℂ] ℂ := + { toFun := fun f => e.symm (star b*e f) z + map_add' := by intro f g; simp [mul_add] + map_smul' := by intro r f; simp [map_smulₛₗ] } + L.mkContinuous (‖b‖*‖z‖) (by + intro f + change ‖e.symm (star b*e f) z‖ ≤ _ + calc + _ ≤ ‖e.symm (star b*e f)‖*‖z‖ := (e.symm (star b*e f)).le_opNorm z + _ = ‖star b*e f‖*‖z‖ := by rw [e.symm.norm_map] + _ ≤ (‖star b‖*‖e f‖)*‖z‖ := by gcongr; exact norm_mul_le _ _ + _ = (‖b‖*‖z‖)*‖f‖ := by rw [norm_star,e.norm_map]; ring) + +lemma leftMatrixFunctional_apply (z : X) (b : M) (f : StrongDual ℂ X) : + leftMatrixFunctional e z b f=e.symm (star b*e f) z := rfl + +lemma leftMatrixFunctional_norm (z : X) (b : M) : + ‖leftMatrixFunctional e z b‖ ≤ ‖z‖*‖b‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg (norm_nonneg z) (norm_nonneg b)) + intro f + rw [leftMatrixFunctional_apply] + calc + _ ≤ ‖e.symm (star b*e f)‖*‖z‖ := (e.symm (star b*e f)).le_opNorm z + _ = ‖star b*e f‖*‖z‖ := by rw [e.symm.norm_map] + _ ≤ (‖star b‖*‖e f‖)*‖z‖ := by gcongr; exact norm_mul_le _ _ + _ = (‖z‖*‖b‖)*‖f‖ := by rw [norm_star,e.norm_map]; ring + +def starLeftMatrixMap (z : X) : M →L[ℂ] StrongDual ℂ (StrongDual ℂ X) := by + let : NormedAddCommGroup (StrongDual ℂ X) := inferInstance + let : NormedSpace ℂ (StrongDual ℂ X) := inferInstance + let : NormedAddCommGroup (StrongDual ℂ (StrongDual ℂ X)) := inferInstance + let : NormedSpace ℂ (StrongDual ℂ (StrongDual ℂ X)) := inferInstance + let K : M →ₗ[ℂ] StrongDual ℂ (StrongDual ℂ X) := + { toFun := leftMatrixFunctional e z + map_add' := by + intro b c + ext f + simp only [leftMatrixFunctional_apply,star_add,add_mul,map_add, + add_apply] + map_smul' := by + intro r b + ext f + simp only [leftMatrixFunctional_apply,star_smul,smul_mul_assoc,map_smulₛₗ, + smul_apply,RingHom.id_apply,starRingEnd_apply, + star_star] } + exact K.mkContinuous ‖z‖ (leftMatrixFunctional_norm e z) + +lemma starLeftMatrixMap_apply (z : X) (b : M) (f : StrongDual ℂ X) : + starLeftMatrixMap e z b f=e.symm (star b*e f) z := rfl + +variable [PartialOrder M] [StarOrderedRing M] [CompleteSpace X] + + + +theorem mul_hasPreadjoint (a : M) : HasPreadjoint e (ContinuousLinearMap.mul ℂ M a) := by + intro z + let : NormedAddCommGroup (StrongDual ℂ X) := inferInstance + let : NormedSpace ℂ (StrongDual ℂ X) := inferInstance + let : NormedAddCommGroup (StrongDual ℂ (StrongDual ℂ X)) := inferInstance + let : NormedSpace ℂ (StrongDual ℂ (StrongDual ℂ X)) := inferInstance + let K := starLeftMatrixMap e z + let J := NormedSpace.inclusionInDoubleDual ℂ X + let S := (LinearMap.range J.toLinearMap).comap K.toLinearMap + have hc : IsClosed (S : Set M) := by + change IsClosed (K ⁻¹' Set.range J) + apply IsClosed.preimage (f := K) K.continuous + exact (NormedSpace.inclusionInDoubleDualLi ℂ (E := X)).isometry.isClosedEmbedding.isClosed_range + have hspan : Submodule.span ℂ {p : M | IsStarProjection p} ≤ S := by + apply Submodule.span_le.mpr + intro p hp + obtain ⟨w,hw⟩ := projection_mul_hasPreadjoint e p hp z + refine ⟨w,?_⟩ + ext f + change f w=e.symm (star p*e f) z + rw [hp.isSelfAdjoint.star_eq] + simpa using (hw (e f)).symm + have htop : (⊤ : Submodule ℂ M) ≤ S := by + rw [← projection_span_dense e] + exact Submodule.topologicalClosure_minimal _ hspan hc + obtain ⟨w,hw⟩ := htop (show star a ∈ (⊤ : Submodule ℂ M) from Submodule.mem_top) + refine ⟨w,fun b => ?_⟩ + have hh := congrArg (fun G : StrongDual ℂ (StrongDual ℂ X) => G (e.symm b)) hw + change e.symm b w=e.symm (star (star a)*e (e.symm b)) z at hh + simpa using hh.symm + + +theorem predual_tendsto_mul_left (a : M) {b : I → M} {l : Filter I} {c : M} + (hb : PredualTendsto e b l c) : + PredualTendsto e (fun i => a*b i) l (a*c) := + HasPreadjoint.tendsto e (mul_hasPreadjoint e a) hb + + +theorem mul_right_hasPreadjoint (a : M) : + HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip a) := by + intro z + obtain ⟨w,hw⟩ := exists_star_predual_vector e z + obtain ⟨v,hv⟩ := mul_hasPreadjoint e (star a) w + obtain ⟨u,hu⟩ := exists_star_predual_vector e v + refine ⟨u,fun b => ?_⟩ + have hh := hw (star a*star b) + simp only [star_mul,star_star] at hh + have hvb : e.symm (star a*star b) w=e.symm (star b) v := by + simpa using hv (star b) + rw [hvb,hu b,star_star] at hh + simpa using hh + + +theorem predual_tendsto_mul_right (a : M) {b : I → M} {l : Filter I} {c : M} + (hb : PredualTendsto e b l c) : + PredualTendsto e (fun i => b i*a) l (c*a) := + HasPreadjoint.tendsto e (mul_right_hasPreadjoint e a) hb + +end HochschildSakai + + + +open Filter Topology +namespace HochschildSakai +open BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + +theorem exists_abstract_star_preadjoint : + ∃ P : X →L⋆[ℂ] X, ‖P‖ ≤ 1 ∧ + ∀ a z, e.symm (star a) z=star (e.symm a (P z)) := by + classical + choose P hP using exists_star_predual_vector e + have heq {x y : X} (h : ∀ a : M, e.symm a x=e.symm a y) : x=y := by + apply (SeparatingDual.eq_iff_forall_dual_eq (R := ℂ)).mpr + intro f + simpa only [e.symm_apply_apply] using h (e f) + have hPa (x y : X) : P (x+y)=P x+P y := by + apply heq + intro a + apply star_injective + rw [← hP (x+y) a,map_add,map_add,star_add,← hP x a,← hP y a] + have hPs (r : ℂ) (x : X) : P (r • x)=star r • P x := by + apply heq + intro a + apply star_injective + rw [← hP (r • x) a,map_smul,map_smul,star_smul,star_star,← hP x a] + let L : X →ₗ⋆[ℂ] X := + { toFun := P + map_add' := hPa + map_smul' := hPs } + have hb (z : X) : ‖L z‖ ≤ 1*‖z‖ := by + rw [one_mul] + apply NormedSpace.norm_le_dual_bound ℂ _ (norm_nonneg _) + intro f + have hn := congrArg norm (hP z (e f)) + simp only [norm_star,e.symm_apply_apply] at hn + change ‖f (P z)‖ ≤ ‖z‖*‖f‖ + rw [mul_comm ‖z‖] + rw [← hn] + simpa only [e.symm.norm_map,norm_star,e.norm_map] using + (e.symm (star (e f))).le_opNorm z + refine ⟨L.mkContinuous 1 hb,?_,fun a z => hP z a⟩ + exact LinearMap.mkContinuous_norm_le _ zero_le_one hb + + + +theorem abstract_multiplication_normal : + (∀ a : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M a)) ∧ + (∀ a : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip a)) := by + let : PartialOrder M := CStarAlgebra.spectralOrder M + let : StarOrderedRing M := CStarAlgebra.spectralOrderedRing M + exact ⟨mul_hasPreadjoint e,mul_right_hasPreadjoint e⟩ + +end HochschildSakai +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalOperators.lean b/lean/OAI/Analysis/BoundedHochschild/NormalOperators.lean new file mode 100644 index 0000000000000000000000000000000000000000..6ce68027c2e8cf3bf85c5b91744f6e1189dd0932 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalOperators.lean @@ -0,0 +1,371 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.NormalVectors +import OAI.Analysis.BoundedHochschild.PositiveDecomposition + +namespace OAI + +/-! Normal parts of scalar functionals and bounded operators. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +namespace HochschildNormalPart +universe u +variable {M : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + + +def positiveVector (ψ : M →ₚ[ℂ] ℂ) : ψ.GNS := (ψ.toPreGNS 1 : ψ.PreGNS) + +lemma positiveVector_coefficient (ψ : M →ₚ[ℂ] ℂ) (a : M) : + coefficient ψ.gnsStarAlgHom (positiveVector ψ) (positiveVector ψ) a=ψ a := by + change ⟪(ψ.toPreGNS 1 : ψ.GNS),ψ.gnsNonUnitalStarAlgHom a (ψ.toPreGNS 1)⟫_ℂ=ψ a + rw [PositiveLinearMap.gnsNonUnitalStarAlgHom_apply_coe,UniformSpace.Completion.inner_coe] + simp [PositiveLinearMap.preGNS_inner_def] + +lemma positiveVector_norm_sq (ψ : M →ₚ[ℂ] ℂ) : ‖positiveVector ψ‖^2=‖ψ 1‖ := by + have hv := positiveVector_coefficient ψ (1:M) + simp only [coefficient_apply,map_one] at hv + change ⟪positiveVector ψ,positiveVector ψ⟫_ℂ=ψ 1 at hv + rw [inner_self_eq_norm_sq_to_K] at hv + rw [← hv,norm_pow] + simp + +abbrev FourHilbert (ψ : Fin 4 → M →ₚ[ℂ] ℂ) := + WithLp 2 ((WithLp 2 ((ψ 0).GNS × (ψ 1).GNS)) × + (WithLp 2 ((ψ 2).GNS × (ψ 3).GNS))) + +def fourRepresentation (ψ : Fin 4 → M →ₚ[ℂ] ℂ) : + M →⋆ₐ[ℂ] (FourHilbert ψ →L[ℂ] FourHilbert ψ) := + sumRepresentation (sumRepresentation (ψ 0).gnsStarAlgHom (ψ 1).gnsStarAlgHom) + (sumRepresentation (ψ 2).gnsStarAlgHom (ψ 3).gnsStarAlgHom) + +def fourLeft (ψ : Fin 4 → M →ₚ[ℂ] ℂ) : FourHilbert ψ := + WithLp.toLp 2 (WithLp.toLp 2 (positiveVector (ψ 0),-positiveVector (ψ 1)), + WithLp.toLp 2 (-Complex.I • positiveVector (ψ 2),Complex.I • positiveVector (ψ 3))) + +def fourRight (ψ : Fin 4 → M →ₚ[ℂ] ℂ) : FourHilbert ψ := + WithLp.toLp 2 (WithLp.toLp 2 (positiveVector (ψ 0),positiveVector (ψ 1)), + WithLp.toLp 2 (positiveVector (ψ 2),positiveVector (ψ 3))) + +lemma four_coefficient (ψ : Fin 4 → M →ₚ[ℂ] ℂ) (a : M) : + coefficient (fourRepresentation ψ) (fourLeft ψ) (fourRight ψ) a= + ψ 0 a-ψ 1 a+Complex.I*(ψ 2 a-ψ 3 a) := by + rw [fourRepresentation,coefficient_sum,add_apply] + simp only [fourLeft,fourRight,WithLp.toLp_fst,WithLp.toLp_snd,coefficient_sum, + add_apply,coefficient_apply,inner_neg_left,inner_smul_left] + simp only [← coefficient_apply,positiveVector_coefficient,map_neg,Complex.conj_I] + ring + +lemma four_norm_bound (φ : StrongDual ℂ M) (ψ : Fin 4 → M →ₚ[ℂ] ℂ) + (hψ : ∀ i,‖ψ i 1‖≤‖φ‖) : ‖fourLeft ψ‖*‖fourRight ψ‖≤4*‖φ‖ := by + have hr : ‖fourRight ψ‖^2=‖ψ 0 1‖+‖ψ 1 1‖+(‖ψ 2 1‖+‖ψ 3 1‖) := by + simp only [fourRight,WithLp.prod_norm_sq_eq_of_L2,WithLp.toLp_fst,WithLp.toLp_snd, + positiveVector_norm_sq] + have hl : ‖fourLeft ψ‖^2=‖fourRight ψ‖^2 := by + rw [hr] + simp only [fourLeft,WithLp.prod_norm_sq_eq_of_L2,WithLp.toLp_fst,WithLp.toLp_snd, + norm_neg,norm_smul,Complex.norm_I,one_mul,positiveVector_norm_sq] + have he : ‖fourLeft ψ‖=‖fourRight ψ‖ := by nlinarith [norm_nonneg (fourLeft ψ),norm_nonneg (fourRight ψ)] + rw [he,← sq,hr] + linarith [hψ 0,hψ 1,hψ 2,hψ 3] + + +structure FunctionalModel (φ : StrongDual ℂ M) where + H : Type u + [normed : NormedAddCommGroup H] + [innerSpace : InnerProductSpace ℂ H] + [complete : CompleteSpace H] + representation : M →⋆ₐ[ℂ] (H →L[ℂ] H) + leftVector : H + rightVector : H + realizes : coefficient representation leftVector rightVector=φ + bound : ‖leftVector‖*‖rightVector‖≤4*‖φ‖ +attribute [instance] FunctionalModel.normed FunctionalModel.innerSpace FunctionalModel.complete + +lemma functionalModel_nonempty (φ : StrongDual ℂ M) : Nonempty (FunctionalModel φ) := by + obtain ⟨ψ,hψ,hφ⟩ := HochschildPositiveDecomposition.exists_four_positive φ + refine ⟨{ H := FourHilbert ψ + representation := fourRepresentation ψ + leftVector := fourLeft ψ + rightVector := fourRight ψ + realizes := ?_ + bound := four_norm_bound φ ψ hψ }⟩ + ext a + exact (four_coefficient ψ a).trans (hφ a).symm + +end HochschildNormalPart + + + +namespace HochschildNormalPart +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +def functionalModel (φ : StrongDual ℂ M) : FunctionalModel φ := by + let : PartialOrder M := CStarAlgebra.spectralOrder M + let : StarOrderedRing M := CStarAlgebra.spectralOrderedRing M + exact Classical.choice (functionalModel_nonempty φ) + + +def normalPartRaw (φ : StrongDual ℂ M) : StrongDual ℂ M := + coefficient (functionalModel φ).representation (functionalModel φ).leftVector + (normalProjection e (functionalModel φ).representation (functionalModel φ).rightVector) + +variable {H : Type v} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +lemma normalPartRaw_coefficient (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (η ξ : H) : + normalPartRaw e (coefficient π η ξ)=coefficient π η (normalProjection e π ξ) := by + exact coefficient_normal_eq_of_eq e _ π _ _ η ξ (functionalModel _).realizes + +lemma normalPartRaw_add (φ ψ : StrongDual ℂ M) : + normalPartRaw e (φ+ψ)=normalPartRaw e φ+normalPartRaw e ψ := by + let m := functionalModel φ + let n := functionalModel ψ + let π := sumRepresentation m.representation n.representation + let η : WithLp 2 (m.H×n.H) := WithLp.toLp 2 (m.leftVector,n.leftVector) + let ξ : WithLp 2 (m.H×n.H) := WithLp.toLp 2 (m.rightVector,n.rightVector) + have hc : coefficient π η ξ=φ+ψ := by + rw [coefficient_sum] + change coefficient m.representation m.leftVector m.rightVector+ + coefficient n.representation n.leftVector n.rightVector=φ+ψ + rw [m.realizes,n.realizes] + rw [← hc,normalPartRaw_coefficient,normalProjection_sum,coefficient_sum] + rfl + +lemma normalPartRaw_smul (r : ℂ) (φ : StrongDual ℂ M) : + normalPartRaw e (r • φ)=r • normalPartRaw e φ := by + let m := functionalModel φ + have hc : coefficient m.representation m.leftVector (r • m.rightVector)=r • φ := by + rw [map_smul,m.realizes] + rw [← hc,normalPartRaw_coefficient,map_smul,map_smul] + rfl + +lemma normalPartRaw_norm (φ : StrongDual ℂ M) : ‖normalPartRaw e φ‖≤4*‖φ‖ := by + let m := functionalModel φ + exact (coefficient_norm _ _ _).trans + ((mul_le_mul_of_nonneg_left ((normalVectors e m.representation).norm_starProjection_apply_le _) + (norm_nonneg m.leftVector)).trans m.bound) + + + +def scalarNormalPart : StrongDual ℂ M →L[ℂ] StrongDual ℂ M := + LinearMap.mkContinuous + { toFun := normalPartRaw e + map_add' := normalPartRaw_add e + map_smul' := normalPartRaw_smul e } 4 (normalPartRaw_norm e) + +@[simp] lemma scalarNormalPart_coefficient (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (η ξ : H) : + scalarNormalPart e (coefficient π η ξ)=coefficient π η (normalProjection e π ξ) := + normalPartRaw_coefficient e π η ξ + +lemma scalarNormalPart_norm : ‖scalarNormalPart e‖≤4 := + LinearMap.mkContinuous_norm_le _ (by norm_num) (normalPartRaw_norm e) + +lemma scalarNormalPart_mem (φ : StrongDual ℂ M) : scalarNormalPart e φ ∈ normalDual e := by + apply (mem_normalVectors e (functionalModel φ).representation _).mp + simp [normalProjection] + +lemma scalarNormalPart_fixes {φ : StrongDual ℂ M} (hφ : φ ∈ normalDual e) : + scalarNormalPart e φ=φ := by + let m := functionalModel φ + change coefficient m.representation m.leftVector (normalProjection e m.representation m.rightVector)=φ + rw [normalProjection_fixes_normal e _ _ _ (m.realizes.symm ▸ hφ),m.realizes] + +lemma scalarNormalPart_comp_left (φ : StrongDual ℂ M) (b : M) : + scalarNormalPart e (φ.comp (ContinuousLinearMap.mul ℂ M b))= + (scalarNormalPart e φ).comp (ContinuousLinearMap.mul ℂ M b) := by + let m := functionalModel φ + have hc (ξ : m.H) : (coefficient m.representation m.leftVector ξ).comp + (ContinuousLinearMap.mul ℂ M b)=coefficient m.representation (m.representation (star b) m.leftVector) ξ := by + ext a + simp only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.mul_apply',coefficient_apply, + map_mul,mul_apply_eq_comp,map_star,ContinuousLinearMap.star_eq_adjoint, + ContinuousLinearMap.adjoint_inner_left] + rw [← m.realizes,hc,scalarNormalPart_coefficient,scalarNormalPart_coefficient,hc] + +lemma scalarNormalPart_comp_right (φ : StrongDual ℂ M) (b : M) : + scalarNormalPart e (φ.comp ((ContinuousLinearMap.mul ℂ M).flip b))= + (scalarNormalPart e φ).comp ((ContinuousLinearMap.mul ℂ M).flip b) := by + let m := functionalModel φ + have hc (ξ : m.H) : (coefficient m.representation m.leftVector ξ).comp + ((ContinuousLinearMap.mul ℂ M).flip b)=coefficient m.representation m.leftVector (m.representation b ξ) := by + ext a + simp [map_mul] + rw [← m.realizes,hc,scalarNormalPart_coefficient,scalarNormalPart_coefficient,hc] + exact congrArg (coefficient m.representation m.leftVector) + (congrArg (fun T : m.H →L[ℂ] m.H => T m.rightVector) (normalProjection_mul e m.representation b)) + +end HochschildNormalPart + + + +namespace HochschildNormalPart +universe u +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +omit [CompleteSpace X] in +lemma predual_separates {a b : M} + (h : ∀ z,predualEmbedding e z a=predualEmbedding e z b) : a=b := by + apply e.symm.injective + ext z + exact star_injective (h z) + +def normalPredualVector (T : M →L[ℂ] M) (z : X) : X := + Classical.choose ((mem_normalDual e _).mp (scalarNormalPart_mem e ((predualEmbedding e z).comp T))) + +lemma normalPredualVector_spec (T : M →L[ℂ] M) (z : X) : + predualEmbedding e (normalPredualVector e T z)= + scalarNormalPart e ((predualEmbedding e z).comp T) := by + ext a + exact (Classical.choose_spec ((mem_normalDual e _).mp + (scalarNormalPart_mem e ((predualEmbedding e z).comp T))) a).symm + +lemma normalPredualVector_add (T : M →L[ℂ] M) (z w : X) : + normalPredualVector e T (z+w)=normalPredualVector e T z+normalPredualVector e T w := by + apply (predualEmbedding e).injective + simp only [normalPredualVector_spec,map_add,ContinuousLinearMap.add_comp] + +lemma normalPredualVector_smul (T : M →L[ℂ] M) (c : ℂ) (z : X) : + normalPredualVector e T (c • z)=c • normalPredualVector e T z := by + apply (predualEmbedding e).injective + simp only [normalPredualVector_spec,map_smulₛₗ,ContinuousLinearMap.smul_comp,RingHom.id_apply] + +lemma normalPredualVector_norm (T : M →L[ℂ] M) (z : X) : + ‖normalPredualVector e T z‖≤(4*‖T‖)*‖z‖ := by + rw [← (predualEmbedding e).norm_map,normalPredualVector_spec] + calc + _ ≤ 4*‖(predualEmbedding e z).comp T‖ := (scalarNormalPart e).le_of_opNorm_le (scalarNormalPart_norm e) _ + _ ≤ 4*(‖predualEmbedding e z‖*‖T‖) := by gcongr; exact ContinuousLinearMap.opNorm_comp_le _ _ + _ = (4*‖T‖)*‖z‖ := by rw [(predualEmbedding e).norm_map]; ring + +def normalPreadjoint (T : M →L[ℂ] M) : X →L[ℂ] X := + LinearMap.mkContinuous + { toFun := normalPredualVector e T + map_add' := normalPredualVector_add e T + map_smul' := normalPredualVector_smul e T } (4*‖T‖) (normalPredualVector_norm e T) + +def normalOperator (T : M →L[ℂ] M) : M →L[ℂ] M := + e.toContinuousLinearEquiv.toContinuousLinearMap.comp + (((ContinuousLinearMap.compL ℂ X X ℂ).flip (normalPreadjoint e T)).comp + e.symm.toContinuousLinearEquiv.toContinuousLinearMap) + +lemma normalOperator_pairing (T : M →L[ℂ] M) (a : M) (z : X) : + predualEmbedding e z (normalOperator e T a)= + scalarNormalPart e ((predualEmbedding e z).comp T) a := by + rw [← normalPredualVector_spec] + simp [normalOperator,normalPreadjoint,predualEmbedding_apply] + +lemma normalOperator_normal (T : M →L[ℂ] M) : BoundedHochschild.HasPreadjoint e (normalOperator e T) := by + intro z + refine ⟨normalPreadjoint e T z,?_⟩ + intro a + simp [normalOperator] + +lemma normalOperator_add (S T : M →L[ℂ] M) : normalOperator e (S+T)=normalOperator e S+normalOperator e T := by + ext a + apply predual_separates e + intro z + simp only [normalOperator_pairing,ContinuousLinearMap.comp_add,map_add,add_apply] + +lemma normalOperator_smul (c : ℂ) (T : M →L[ℂ] M) : normalOperator e (c • T)=c • normalOperator e T := by + ext a + apply predual_separates e + intro z + simp only [normalOperator_pairing,ContinuousLinearMap.comp_smul,map_smul,smul_apply] + +lemma normalOperator_norm (T : M →L[ℂ] M) : ‖normalOperator e T‖≤4*‖T‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro a + rw [← e.symm.norm_map] + change ‖e.symm (e ((e.symm a).comp (normalPreadjoint e T)))‖≤_ + rw [e.symm_apply_apply] + calc + _ ≤ ‖normalPreadjoint e T‖*‖e.symm a‖ := by + simpa only [mul_comm] using (ContinuousLinearMap.opNorm_comp_le (e.symm a) (normalPreadjoint e T)) + _ ≤ (4*‖T‖)*‖a‖ := by + rw [e.symm.norm_map] + gcongr + exact LinearMap.mkContinuous_norm_le _ (by positivity) (normalPredualVector_norm e T) + + +def operatorNormalPart : (M →L[ℂ] M) →L[ℂ] (M →L[ℂ] M) := + LinearMap.mkContinuous + { toFun := normalOperator e + map_add' := normalOperator_add e + map_smul' := normalOperator_smul e } 4 (normalOperator_norm e) + +lemma operatorNormalPart_pairing (T : M →L[ℂ] M) (a : M) (z : X) : + predualEmbedding e z (operatorNormalPart e T a)= + scalarNormalPart e ((predualEmbedding e z).comp T) a := normalOperator_pairing e T a z + +lemma operatorNormalPart_normal (T : M →L[ℂ] M) : + BoundedHochschild.HasPreadjoint e (operatorNormalPart e T) := normalOperator_normal e T + +lemma operatorNormalPart_fixes (T : M →L[ℂ] M) (hT : BoundedHochschild.HasPreadjoint e T) : + operatorNormalPart e T=T := by + ext a + apply predual_separates e + intro z + rw [operatorNormalPart_pairing] + have hn : (predualEmbedding e z).comp T ∈ normalDual e := + normalDual_comp e (φ := predualEmbedding e z) ⟨z,rfl⟩ T hT + exact congrArg (fun φ : StrongDual ℂ M => φ a) (scalarNormalPart_fixes e hn) + +lemma operatorNormalPart_comp_normal (T L : M →L[ℂ] M) + (hL : BoundedHochschild.HasPreadjoint e L) : + operatorNormalPart e (L.comp T)=L.comp (operatorNormalPart e T) := by + ext a + apply predual_separates e + intro z + obtain ⟨w,hw⟩ := hL z + have he : (predualEmbedding e z).comp L=predualEmbedding e w := by + ext b + simp only [ContinuousLinearMap.comp_apply,predualEmbedding_apply,hw] + rw [operatorNormalPart_pairing,← ContinuousLinearMap.comp_assoc,he] + change _=predualEmbedding e z (L (operatorNormalPart e T a)) + rw [← ContinuousLinearMap.comp_apply (predualEmbedding e z) L,he,operatorNormalPart_pairing] + +lemma operatorNormalPart_comp_left (T : M →L[ℂ] M) (b : M) : + operatorNormalPart e (T.comp (ContinuousLinearMap.mul ℂ M b))= + (operatorNormalPart e T).comp (ContinuousLinearMap.mul ℂ M b) := by + ext a + apply predual_separates e + intro z + rw [operatorNormalPart_pairing,← ContinuousLinearMap.comp_assoc,scalarNormalPart_comp_left] + exact (operatorNormalPart_pairing e T (b*a) z).symm + +lemma operatorNormalPart_comp_right (T : M →L[ℂ] M) (b : M) : + operatorNormalPart e (T.comp ((ContinuousLinearMap.mul ℂ M).flip b))= + (operatorNormalPart e T).comp ((ContinuousLinearMap.mul ℂ M).flip b) := by + ext a + apply predual_separates e + intro z + rw [operatorNormalPart_pairing,← ContinuousLinearMap.comp_assoc,scalarNormalPart_comp_right] + exact (operatorNormalPart_pairing e T (a*b) z).symm + +end HochschildNormalPart +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalOrbitHull.lean b/lean/OAI/Analysis/BoundedHochschild/NormalOrbitHull.lean new file mode 100644 index 0000000000000000000000000000000000000000..771e4c1727c436fa58cd4627347f27ca1c885872 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalOrbitHull.lean @@ -0,0 +1,122 @@ +import OAI.Analysis.BoundedHochschild.FiniteNormalOrbit + +namespace OAI + +/-! +# The norm-closed convex orbit of a normal positive functional + +This family remains normal and positive, preserves values on the center, +and satisfies the uniform orthogonal-projection decay in Ringrose Lemma 5.2. +-/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The bounded functional underlying a positive functional. -/ +def positiveFunctionalCLM (ψ : M →ₚ[ℂ] ℂ) : StrongDual ℂ M := + ⟨ψ.toLinearMap, map_continuous ψ⟩ + +/-- Pull a functional back along conjugation by a unitary. -/ +def unitaryPullback (F : StrongDual ℂ M) (u : unitary M) : StrongDual ℂ M := + (F.comp ((ContinuousLinearMap.mul ℂ M).flip (star (u : M)))).comp + (ContinuousLinearMap.mul ℂ M (u : M)) + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma unitaryPullback_apply (F : StrongDual ℂ M) (u : unitary M) (a : M) : + unitaryPullback F u a = F ((u : M) * a * star (u : M)) := rfl + +/-- The closed convex orbit used in the fixed-point construction of a trace. -/ +def unitaryOrbitHull (F : StrongDual ℂ M) : Set (StrongDual ℂ M) := + closure (convexHull ℝ (Set.range (unitaryPullback F))) + +lemma unitaryOrbitHull_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {F : StrongDual ℂ M} (hF : F ∈ normalDual e) : + unitaryOrbitHull F ⊆ normalDual e := by + apply closure_minimal _ (normalDual_closed e) + apply convexHull_min _ ((normalDual e).restrictScalars ℝ).convex + rintro _ ⟨u, rfl⟩ + apply normalDual_comp e _ _ (HochschildSakai.mul_hasPreadjoint e (u : M)) + exact normalDual_comp e hF _ ((HochschildSakai.abstract_multiplication_normal e).2 (star (u : M))) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma unitaryOrbitHull_eval_bound (F : StrongDual ℂ M) (a : M) (C : ℝ) + (hbound : ∀ u : unitary M, ‖unitaryPullback F u a‖ ≤ C) : + ∀ G ∈ unitaryOrbitHull F, ‖G a‖ ≤ C := by + let E := (ContinuousLinearMap.apply ℂ ℂ a : StrongDual ℂ M →L[ℂ] ℂ) + have hc : convexHull ℝ (Set.range (unitaryPullback F)) ⊆ + E ⁻¹' Metric.closedBall 0 C := by + apply convexHull_min + · rintro _ ⟨u, rfl⟩ + simpa only [Set.mem_preimage, Metric.mem_closedBall, dist_zero_right, E, ContinuousLinearMap.apply_apply] using hbound u + · exact (convex_closedBall (0 : ℂ) C).linear_preimage (E.restrictScalars ℝ).toLinearMap + have hh := closure_minimal hc (Metric.isClosed_closedBall.preimage E.continuous) + intro G hG + simpa only [Set.mem_preimage, Metric.mem_closedBall, dist_zero_right, E, ContinuousLinearMap.apply_apply] using hh hG + +omit [PartialOrder M] [StarOrderedRing M] in +lemma unitaryOrbitHull_eval_eq (F : StrongDual ℂ M) (a : M) (c : ℂ) + (hbound : ∀ u : unitary M, unitaryPullback F u a = c) : + ∀ G ∈ unitaryOrbitHull F, G a = c := by + let E := (ContinuousLinearMap.apply ℂ ℂ a : StrongDual ℂ M →L[ℂ] ℂ) + have hc : convexHull ℝ (Set.range (unitaryPullback F)) ⊆ {G | E G = c} := by + apply convexHull_min + · rintro _ ⟨u, rfl⟩ + exact hbound u + · intro G hG H hH r t _hr _ht hrt + change r • E G + t • E H = c + rw [hG, hH, ← add_smul, hrt, one_smul] + exact closure_minimal hc (isClosed_eq E.continuous continuous_const) + +lemma unitaryOrbitHull_positive (ψ : M →ₚ[ℂ] ℂ) : + ∀ G ∈ unitaryOrbitHull (positiveFunctionalCLM ψ), ∀ a : M, 0 ≤ a → 0 ≤ G a := by + intro G hG a ha + let E := (ContinuousLinearMap.apply ℂ ℂ a : StrongDual ℂ M →L[ℂ] ℂ) + have hc : convexHull ℝ (Set.range (unitaryPullback (positiveFunctionalCLM ψ))) ⊆ + E ⁻¹' Set.Ici 0 := by + apply convexHull_min + · rintro _ ⟨u, rfl⟩ + exact ψ.map_nonneg (star_right_conjugate_nonneg ha (u : M)) + · intro F hF H hH r t hr ht _ + change 0 ≤ r • E F + t • E H + exact add_nonneg (smul_nonneg hr hF) (smul_nonneg ht hH) + exact (closure_minimal hc (isClosed_Ici.preimage E.continuous)) hG + +omit [PartialOrder M] [StarOrderedRing M] in +lemma unitaryOrbitHull_central (F : StrongDual ℂ M) {a : M} + (hc : ∀ b : M, a * b = b * a) : + ∀ G ∈ unitaryOrbitHull F, G a = F a := by + apply unitaryOrbitHull_eval_eq F a (F a) + intro u + rw [unitaryPullback_apply, ← hc (u : M), mul_assoc, + (Unitary.mem_iff.mp u.property).2, mul_one] + +/-- Uniform decay survives both convex averaging and norm closure. -/ +theorem normal_positive_uniform_orbit_hull (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) + (q : ℕ → M) (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) (ε : ℝ) (hε : 0 < ε) : + ∀ᶠ n in atTop, ∀ G ∈ unitaryOrbitHull (positiveFunctionalCLM ψ), ‖G (q n)‖ < ε := by + have heps : 0 < ε / 2 := half_pos hε + filter_upwards [normal_positive_uniform_unitary_orbit e hfinite ψ hψ q hq horth + (ε / 2) heps] with n hn G hG + exact (unitaryOrbitHull_eval_bound (positiveFunctionalCLM ψ) (q n) (ε / 2) + (fun u => (hn u).le) G hG).trans_lt (half_lt_self hε) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalOrbitInvariance.lean b/lean/OAI/Analysis/BoundedHochschild/NormalOrbitInvariance.lean new file mode 100644 index 0000000000000000000000000000000000000000..6938689b160f916a2330859ab05ea47018eec88d --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalOrbitInvariance.lean @@ -0,0 +1,131 @@ +import OAI.Analysis.BoundedHochschild.UnitaryPredualAction +import OAI.Analysis.BoundedHochschild.IsometricFixedPoint + +namespace OAI + +/-! Convexity and invariance of the compact normal-state orbit. -/ + +noncomputable section + +open Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u + +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Unitary pullback is weak-star continuous. -/ +def weakUnitaryPullback (u : unitary M) : WeakDual ℂ M →L[ℂ] WeakDual ℂ M where + toFun F := StrongDual.toWeakDual (unitaryPullback (WeakDual.toStrongDual F) u) + map_add' F G := by apply WeakDual.toStrongDual.injective; ext a; rfl + map_smul' c F := by apply WeakDual.toStrongDual.injective; ext a; rfl + cont := WeakDual.continuous_of_continuous_eval (fun a => + WeakDual.eval_continuous ((u : M) * a * star (u : M))) + +lemma unitaryOrbitHull_invariant (F : StrongDual ℂ M) (u : unitary M) + {H : StrongDual ℂ M} (hH : H ∈ unitaryOrbitHull F) : + unitaryPullback H u ∈ unitaryOrbitHull F := by + have hconv : Convex ℝ (unitaryOrbitHull F) := (convex_convexHull ℝ _).closure + have hclosed : IsClosed (unitaryOrbitHull F) := isClosed_closure + apply closure_minimal (t := (unitaryDualEquiv u) ⁻¹' unitaryOrbitHull F) _ + (hclosed.preimage (unitaryDualEquiv u).continuous) hH + apply convexHull_min _ + (hconv.linear_preimage ((unitaryDualEquiv u).toLinearEquiv.restrictScalars ℝ).toLinearMap) + rintro _ ⟨v, rfl⟩ + change unitaryPullback (unitaryPullback F v) u ∈ unitaryOrbitHull F + rw [unitaryPullback_mul] + exact subset_closure (subset_convexHull ℝ _ (Set.mem_range_self (v * u))) + +lemma weakOrbitClosure_invariant (F : StrongDual ℂ M) (u : unitary M) + {H : WeakDual ℂ M} (hH : H ∈ weakFunctionalClosure (unitaryOrbitHull F)) : + weakUnitaryPullback u H ∈ weakFunctionalClosure (unitaryOrbitHull F) := by + apply closure_minimal (t := (weakUnitaryPullback u) ⁻¹' + weakFunctionalClosure (unitaryOrbitHull F)) _ + (isClosed_closure.preimage (weakUnitaryPullback u).continuous) hH + rintro _ ⟨G, hG, rfl⟩ + exact subset_closure ⟨unitaryPullback G u, unitaryOrbitHull_invariant F u hG, rfl⟩ + +lemma weakOrbitClosure_convex (F : StrongDual ℂ M) : + Convex ℝ (weakFunctionalClosure (unitaryOrbitHull F)) := by + have hsmul : ContinuousConstSMul ℝ (WeakDual ℂ M) := + ⟨fun r => WeakDual.continuous_of_continuous_eval (fun a => + (WeakDual.eval_continuous a).const_smul r)⟩ + have hHull : Convex ℝ (unitaryOrbitHull F) := + (convex_convexHull ℝ (Set.range (unitaryPullback F))).closure + let L : StrongDual ℂ M →ₗ[ℝ] WeakDual ℂ M := + { toFun := StrongDual.toWeakDual + map_add' := fun _ _ => rfl + map_smul' := fun _ _ => rfl } + have hImage : Convex ℝ (L '' unitaryOrbitHull F) := hHull.linear_image L + have hClosed : Convex ℝ (closure (L '' unitaryOrbitHull F)) := + @Convex.closure ℝ (WeakDual ℂ M) _ _ _ _ _ _ hsmul _ hImage + exact hClosed + +/-- The weak predual embedding is real-linear. -/ +def weakPredualRealMap (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + WeakSpace ℂ X →ₗ[ℝ] WeakDual ℂ M where + toFun := weakPredualMap e + map_add' x y := by + apply WeakDual.toStrongDual.injective + ext a + change star (e.symm a ((toWeakSpace ℂ X).symm (x + y))) = _ + simp only [map_add, star_add] + rfl + map_smul' r x := by + apply WeakDual.toStrongDual.injective + ext a + change star (e.symm a ((r : ℂ) • (toWeakSpace ℂ X).symm x)) = + (r : ℂ) • star (e.symm a ((toWeakSpace ℂ X).symm x)) + rw [map_smul, star_smul] + simp only [Complex.star_def, Complex.conj_ofReal] + +variable [PartialOrder M] [StarOrderedRing M] + +omit [CompleteSpace X] [PartialOrder M] [StarOrderedRing M] in +lemma weakPredualOrbit_convex (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (F : StrongDual ℂ M) : + Convex ℝ ((weakPredualMap e) ⁻¹' weakFunctionalClosure (unitaryOrbitHull F)) := by + intro x hx y hy a b ha hb hab + have heq : weakPredualMap e (a • x + b • y) = + a • weakPredualMap e x + b • weakPredualMap e y := by + exact (weakPredualRealMap e).map_add (a • x) (b • y) |>.trans + (congrArg₂ (· + ·) ((weakPredualRealMap e).map_smul a x) + ((weakPredualRealMap e).map_smul b y)) + change weakPredualMap e (a • x + b • y) ∈ weakFunctionalClosure (unitaryOrbitHull F) + rw [heq] + exact (weakOrbitClosure_convex F) hx hy ha hb hab + +lemma weakPredualOrbit_invariant (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (F : StrongDual ℂ M) + (u : unitary M) : + Set.MapsTo (weakIsometry (unitaryPredualAction e u)) + ((weakPredualMap e) ⁻¹' weakFunctionalClosure (unitaryOrbitHull F)) + ((weakPredualMap e) ⁻¹' weakFunctionalClosure (unitaryOrbitHull F)) := by + intro x hx + have heq : weakPredualMap e (weakIsometry (unitaryPredualAction e u) x) = + weakUnitaryPullback (star u) (weakPredualMap e x) := by + apply WeakDual.toStrongDual.injective + exact predualEmbedding_unitaryAction e u ((toWeakSpace ℂ X).symm x) + change weakPredualMap e (weakIsometry (unitaryPredualAction e u) x) ∈ + weakFunctionalClosure (unitaryOrbitHull F) + rw [heq] + exact weakOrbitClosure_invariant F (star u) hx + +omit [PartialOrder M] [StarOrderedRing M] in +lemma weakFunctionalClosure_eval_eq (K : Set (StrongDual ℂ M)) (a : M) (c : ℂ) + (h : ∀ G ∈ K, G a = c) {F : WeakDual ℂ M} (hF : F ∈ weakFunctionalClosure K) : + F a = c := by + apply closure_minimal (t := {G : WeakDual ℂ M | G a = c}) _ + (isClosed_eq (WeakDual.eval_continuous a) continuous_const) hF + rintro _ ⟨G, hG, rfl⟩ + exact h G hG + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalOrderIntervals.lean b/lean/OAI/Analysis/BoundedHochschild/NormalOrderIntervals.lean new file mode 100644 index 0000000000000000000000000000000000000000..95fa4d908b2db9286b5f29eca88d441a562e4cdd --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalOrderIntervals.lean @@ -0,0 +1,85 @@ +import OAI.Analysis.BoundedHochschild.PositiveNormalParts + +namespace OAI + +/-! Compact order intervals of normal positive functionals. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildNormalPart + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The positive order interval below a fixed positive functional, represented +in the weak dual of the algebra. -/ +def weakPositiveOrderInterval (ψ : M →ₚ[ℂ] ℂ) : Set (WeakDual ℂ M) := + {F | ∀ a : M, 0 ≤ a → 0 ≤ F a ∧ F a ≤ ψ a} + +lemma weakPositiveOrderInterval_norm_bound (ψ : M →ₚ[ℂ] ℂ) + {F : WeakDual ℂ M} (hF : F ∈ weakPositiveOrderInterval ψ) : + ‖WeakDual.toStrongDual F‖ ≤ 4 * ‖ψ 1‖ := by + let G := WeakDual.toStrongDual F + have hpos (a : M) (ha : 0 ≤ a) : ‖G a‖ ≤ ‖ψ 1‖ * ‖a‖ := by + exact (CStarAlgebra.norm_le_norm_of_le_of_nonneg (hF a ha).2 (hF a ha).1).trans + (PositiveLinearMap.norm_apply_le_of_nonneg ψ a ha) + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro a + obtain ⟨x, hx, hxn, ha⟩ := CStarAlgebra.exists_sum_four_nonneg a + calc + ‖G a‖ = ‖∑ i : Fin 4, Complex.I ^ (i : ℕ) • G (x i)‖ := by rw [ha, map_sum]; simp + _ ≤ ∑ i : Fin 4, ‖Complex.I ^ (i : ℕ) • G (x i)‖ := norm_sum_le _ _ + _ = ∑ i : Fin 4, ‖G (x i)‖ := by simp only [norm_smul, norm_pow, Complex.norm_I, + one_pow, one_mul] + _ ≤ ∑ _i : Fin 4, ‖ψ 1‖ * ‖a‖ := by + apply Finset.sum_le_sum + intro i _ + exact (hpos (x i) (hx i)).trans (mul_le_mul_of_nonneg_left (hxn i) (norm_nonneg _)) + _ = (4 * ‖ψ 1‖) * ‖a‖ := by simp; ring + +omit [StarOrderedRing M] in +lemma weakPositiveOrderInterval_closed (ψ : M →ₚ[ℂ] ℂ) : + IsClosed (weakPositiveOrderInterval ψ) := by + change IsClosed {F : WeakDual ℂ M | ∀ a : M, 0 ≤ a → 0 ≤ F a ∧ F a ≤ ψ a} + simp only [Set.ofPred_forall] + apply isClosed_iInter + intro a + apply isClosed_iInter + intro _ha + exact (isClosed_le continuous_const (WeakDual.eval_continuous a)).inter + (isClosed_le (WeakDual.eval_continuous a) continuous_const) + +/-- Positive order intervals are weak-star compact by Banach--Alaoglu. -/ +theorem weakPositiveOrderInterval_compact (ψ : M →ₚ[ℂ] ℂ) : + IsCompact (weakPositiveOrderInterval ψ) := by + apply (WeakDual.isCompact_closedBall (0 : StrongDual ℂ M) (4 * ‖ψ 1‖)).of_isClosed_subset + (weakPositiveOrderInterval_closed ψ) + intro F hF + simpa only [Set.mem_preimage, Metric.mem_closedBall, dist_zero_right] using + weakPositiveOrderInterval_norm_bound ψ hF + +/-- If the upper endpoint is normal, every functional in the compact order +interval is normal as well. -/ +theorem weakPositiveOrderInterval_normal (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (ψ : M →ₚ[ℂ] ℂ) (hψ : TraceInPredual e ψ) {F : WeakDual ℂ M} + (hF : F ∈ weakPositiveOrderInterval ψ) : WeakDual.toStrongDual F ∈ normalDual e := by + let G := WeakDual.toStrongDual F + let χ : M →ₚ[ℂ] ℂ := + { toLinearMap := G.toLinearMap + monotone' := (monotone_iff_map_nonneg G.toLinearMap).mpr (fun a ha => (hF a ha).1) } + exact (mem_normalDual e _).mpr + (positive_normal_of_dominated e χ ψ hψ (fun a ha => (hF a ha).2)) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalStatePartitions.lean b/lean/OAI/Analysis/BoundedHochschild/NormalStatePartitions.lean new file mode 100644 index 0000000000000000000000000000000000000000..78d02acda7e0bc52be7dc016f07c3367b0f9a005 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalStatePartitions.lean @@ -0,0 +1,37 @@ +import OAI.Analysis.BoundedHochschild.CentralProjectionPartitions +import OAI.Analysis.BoundedHochschild.FiniteTraceCover + +namespace OAI + +/-! Central partitions into pieces with normal states faithful on their centers. -/ + +noncomputable section + +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- Every von Neumann algebra has a central partition into pieces detected +faithfully on their centers by normal states. No traciality is asserted. -/ +theorem exists_central_normal_state_partition (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) : + ∃ D : MaximalCentralPartition M (HasCentralFaithfulNormalState e), + D.complement = 0 := by + obtain ⟨D⟩ := exists_maximal_central_partition e (HasCentralFaithfulNormalState e) + refine ⟨D, ?_⟩ + by_contra hzero + obtain ⟨p, hp, hpc, hple, hp0, hstate⟩ := exists_central_normal_state_subprojection e + D.complement_isProjection D.complement_central hzero + exact hp0 (D.maximal p hp hpc hple hstate) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalTraceFaithfulness.lean b/lean/OAI/Analysis/BoundedHochschild/NormalTraceFaithfulness.lean new file mode 100644 index 0000000000000000000000000000000000000000..a656a9085a0aacdf7a4d795842b23d356b1c4d18 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalTraceFaithfulness.lean @@ -0,0 +1,122 @@ +import OAI.Analysis.BoundedHochschild.FiniteNormalTrace +import OAI.Analysis.BoundedHochschild.FiniteNormalState + +namespace OAI + +/-! A normal trace faithful on the center is faithful on the whole algebra. -/ + +noncomputable section + +open Filter Topology +open scoped ComplexOrder + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma normal_tracial_null_projection_join (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a * b) = τ (b * a)) + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (htp : τ p = 0) (htq : τ q = 0) : + ∃ r : M, IsStarProjection r ∧ p ≤ r ∧ q ≤ r ∧ τ r = 0 := by + obtain ⟨v, hvq, _, hr, hpr, hqr, _⟩ := exists_trace_free_projection_join e p q hp hq + have hvi : τ v.initial = 0 := le_antisymm ((τ.monotone hvq).trans_eq htq) + (τ.map_nonneg v.initial_proj.nonneg) + have hvf : τ v.final = 0 := (htr v.val (star v.val)).trans hvi + exact ⟨p + v.final, hr, hpr, hqr, by rw [map_add, htp, hvf, add_zero]⟩ + +/-- The largest projection annihilated by a normal trace is central. -/ +theorem normal_trace_largest_null_projection (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (τ : M →ₚ[ℂ] ℂ) (hτ : TraceInPredual e τ) + (htr : ∀ a b : M, τ (a * b) = τ (b * a)) : + ∃ p : M, IsStarProjection p ∧ (∀ a : M, p * a = a * p) ∧ τ p = 0 ∧ + ∀ q : M, IsStarProjection q → τ q = 0 → q ≤ p := by + classical + let S : Set M := {p | IsStarProjection p ∧ τ p = 0} + obtain ⟨p, _, hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain a ha => by + obtain ⟨p, hp, hu, _, _, U, _, ht⟩ := + exists_projection_chain_supremum_with_limit e c ⟨a, ha⟩ hchain + (fun q hq => (hc hq).1) + refine ⟨p, ⟨hp, ?_⟩, hu⟩ + have heq : (fun q : c => τ (q : M)) = (fun _ : c => (0 : ℂ)) := + funext (fun q => (hc q.property).2) + have hlim := trace_predual_tendsto e τ hτ ht + rw [heq] at hlim + exact tendsto_nhds_unique hlim tendsto_const_nhds) 0 + (show (0 : M) ∈ S from ⟨IsStarProjection.zero M, map_zero τ⟩) + have hp := hmax.1.1 + have hnull := hmax.1.2 + have hgreat (q : M) (hq : IsStarProjection q) (htq : τ q = 0) : q ≤ p := by + obtain ⟨r, hr, hpr, hqr, htr0⟩ := normal_tracial_null_projection_join e τ htr hp hq hnull htq + exact hqr.trans (hmax.2 ⟨hr, htr0⟩ hpr) + have hconj (u : unitary M) : (u : M) * p * star (u : M) ≤ p := by + apply hgreat + · constructor + · change ((u : M) * p * star (u : M)) * ((u : M) * p * star (u : M)) = + (u : M) * p * star (u : M) + calc + _ = (u : M) * (p * ((star (u : M) * (u : M)) * p)) * star (u : M) := by + noncomm_ring + _ = _ := by rw [Unitary.star_mul_self_of_mem u.property, one_mul, hp.isIdempotentElem.eq] + · change star ((u : M) * p * star (u : M)) = (u : M) * p * star (u : M) + simp only [star_mul, star_star, hp.isSelfAdjoint.star_eq, mul_assoc] + · rw [htr, ← mul_assoc, Unitary.star_mul_self_of_mem u.property, one_mul, hnull] + have hfix (u : unitary M) : (u : M) * p * star (u : M) = p := by + apply le_antisymm (hconj u) + have h := star_right_conjugate_le_conjugate (hconj (star u)) (u : M) + simp only [Unitary.coe_star, star_star, mul_assoc, + Unitary.mul_star_self_of_mem u.property, mul_one] at h + have huus : (u : M) * (star (u : M) * p) = p := by + rw [← mul_assoc, Unitary.mul_star_self_of_mem u.property, one_mul] + rw [huus] at h + simpa only [mul_assoc] using h + have hcomm (u : unitary M) : p * (u : M) = (u : M) * p := by + have h := congrArg (fun a : M => a * (u : M)) (hfix u) + simpa only [mul_assoc, Unitary.star_mul_self_of_mem u.property, mul_one] using h.symm + refine ⟨p, hp, ?_, hnull, hgreat⟩ + intro a + obtain ⟨u, c, rfl, _⟩ := CStarAlgebra.exists_sum_four_unitary a + rw [Finset.mul_sum, Finset.sum_mul] + apply Finset.sum_congr rfl + intro i _ + rw [mul_smul_comm, smul_mul_assoc, hcomm] + +/-- Faithfulness on central projections suffices for a normal trace. -/ +theorem normal_trace_faithful_of_center (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (τ : M →ₚ[ℂ] ℂ) (hτ : TraceInPredual e τ) + (htr : ∀ a b : M, τ (a * b) = τ (b * a)) + (hcenter : ∀ p : M, IsStarProjection p → (∀ a : M, p * a = a * p) → + τ p = 0 → p = 0) : ∀ a : M, τ (star a * a) = 0 → a = 0 := by + obtain ⟨p, hp, hpc, hnull, hgreat⟩ := normal_trace_largest_null_projection e τ hτ htr + have hp0 : p = 0 := hcenter p hp hpc hnull + intro a ha + let t : ℝ := ‖star a * a‖ + 1 + have ht : 0 < t := by dsimp [t]; positivity + let c : M := t⁻¹ • (star a * a) + have hc0 : 0 ≤ c := smul_nonneg (inv_nonneg.mpr ht.le) (star_mul_self_nonneg a) + have hcn : ‖c‖ ≤ 1 := by + rw [show c = t⁻¹ • (star a * a) from rfl, norm_smul, Real.norm_eq_abs, + abs_of_pos (inv_pos.mpr ht)] + exact (inv_mul_le_one₀ ht).mpr (by dsimp [t]; linarith) + have hc1 : c ≤ 1 := (CStarAlgebra.norm_le_one_iff_of_nonneg c hc0).mp hcn + have hτc : τ c = 0 := by + rw [show c = t⁻¹ • (star a * a) from rfl, τ.map_smul_of_tower, ha, smul_zero] + obtain ⟨q, hq, hτq⟩ := exists_null_support_projection e τ hτ hc0 hc1 hτc + have hq0 : q = 0 := le_antisymm (hp0 ▸ hgreat q hq.proj hτq) hq.proj.nonneg + have hc : c = 0 := by simpa only [hq0, zero_mul] using hq.left.symm + have haa : star a * a = 0 := (smul_eq_zero.mp hc).resolve_left (inv_ne_zero ht.ne') + apply norm_eq_zero.mp + have hn := congrArg norm haa + rw [CStarRing.norm_star_mul_self, norm_zero] at hn + nlinarith [norm_nonneg a] + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/NormalVectors.lean b/lean/OAI/Analysis/BoundedHochschild/NormalVectors.lean new file mode 100644 index 0000000000000000000000000000000000000000..768e95dcef07e2666cf78cd624d23c7b71ef4043 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/NormalVectors.lean @@ -0,0 +1,416 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.NormalMultiplication + +namespace OAI + +/-! Normal vectors and projections for Hilbert-space representations. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +namespace HochschildNormalPart +universe u v +variable {M X : Type u} [CStarAlgebra M] + [NormedAddCommGroup X] [NormedSpace ℂ X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + + + +def predualEmbedding : X →ₗᵢ⋆[ℂ] StrongDual ℂ M where + toFun z := (starL ℂ).toContinuousLinearMap.comp (((ContinuousLinearMap.apply ℂ ℂ) z).comp + e.symm.toContinuousLinearEquiv.toContinuousLinearMap) + map_add' z w := by ext a; simp + map_smul' r z := by ext a; simp + norm_map' z := by + apply le_antisymm + · apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg _) + intro a + change ‖star (e.symm a z)‖ ≤ ‖z‖*‖a‖ + simpa only [norm_star,e.symm.norm_map,mul_comm] using (e.symm a).le_opNorm z + · apply NormedSpace.norm_le_dual_bound ℂ z (norm_nonneg _) + intro f + have := ((starL ℂ).toContinuousLinearMap.comp (((ContinuousLinearMap.apply ℂ ℂ) z).comp + e.symm.toContinuousLinearEquiv.toContinuousLinearMap)).le_opNorm (e f) + change ‖f z‖ ≤ ‖(starL ℂ).toContinuousLinearMap.comp + (((ContinuousLinearMap.apply ℂ ℂ) z).comp + e.symm.toContinuousLinearEquiv.toContinuousLinearMap)‖ * ‖f‖ + simpa only [ContinuousLinearMap.comp_apply,ContinuousLinearMap.apply_apply, + ContinuousLinearEquiv.coe_coe,LinearIsometryEquiv.coe_toContinuousLinearEquiv, + starL_apply,e.symm_apply_apply,norm_star,e.norm_map] using this + +@[simp] lemma predualEmbedding_apply (z : X) (a : M) : + predualEmbedding e z a=star (e.symm a z) := rfl + + +def normalDual : Submodule ℂ (StrongDual ℂ M) := (predualEmbedding e).toLinearMap.range + +lemma mem_normalDual (φ : StrongDual ℂ M) : + φ ∈ normalDual e ↔ ∃ z : X, ∀ a : M, φ a=star (e.symm a z) := by + constructor + · rintro ⟨z,rfl⟩; exact ⟨z,fun _ => rfl⟩ + · rintro ⟨z,hz⟩; exact ⟨z,ContinuousLinearMap.ext (fun a => (hz a).symm)⟩ + +variable [CompleteSpace X] + +lemma normalDual_closed : IsClosed (normalDual e : Set (StrongDual ℂ M)) := + (predualEmbedding e).isometry.isClosedEmbedding.isClosed_range + +omit [CompleteSpace X] in +lemma normalDual_comp {φ : StrongDual ℂ M} (hφ : φ ∈ normalDual e) + (L : M →L[ℂ] M) (hL : BoundedHochschild.HasPreadjoint e L) : + φ.comp L ∈ normalDual e := by + obtain ⟨z,hz⟩ := (mem_normalDual e φ).mp hφ + obtain ⟨w,hw⟩ := hL z + exact (mem_normalDual e _).mpr ⟨w,fun a => by simp only [ContinuousLinearMap.comp_apply,hz,hw]⟩ + +variable {H : Type v} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + + +def coefficient (η : H) : H →L[ℂ] StrongDual ℂ M := by + let L : H →ₗ[ℂ] StrongDual ℂ M := + { toFun := fun ξ => (innerSL ℂ η).comp + (((ContinuousLinearMap.apply ℂ H) ξ).comp (π.toAlgHom.toLinearMap.mkContinuous 1 (fun a => by simpa using NonUnitalStarAlgHom.norm_apply_le π a))) + map_add' := by intro ξ ζ; ext a; simp + map_smul' := by intro r ξ; ext a; simp } + exact L.mkContinuous ‖η‖ (by + intro ξ + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg (norm_nonneg _) (norm_nonneg _)) + intro a + change ‖⟪η,π a ξ⟫_ℂ‖ ≤ (‖η‖*‖ξ‖)*‖a‖ + calc + _ ≤ ‖η‖*‖π a ξ‖ := norm_inner_le_norm _ _ + _ ≤ ‖η‖*(‖π a‖*‖ξ‖) := mul_le_mul_of_nonneg_left ((π a).le_opNorm ξ) (norm_nonneg _) + _ ≤ ‖η‖*(‖a‖*‖ξ‖) := by gcongr; exact NonUnitalStarAlgHom.norm_apply_le π a + _ = _ := by ring) + +@[simp] lemma coefficient_apply (η ξ : H) (a : M) : + coefficient π η ξ a=⟪η,π a ξ⟫_ℂ := rfl + +lemma coefficient_norm (η ξ : H) : ‖coefficient π η ξ‖ ≤ ‖η‖*‖ξ‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (mul_nonneg (norm_nonneg _) (norm_nonneg _)) + intro a + calc + _ ≤ ‖η‖*‖π a ξ‖ := norm_inner_le_norm _ _ + _ ≤ ‖η‖*(‖π a‖*‖ξ‖) := by gcongr; exact (π a).le_opNorm ξ + _ ≤ ‖η‖*(‖a‖*‖ξ‖) := by gcongr; exact NonUnitalStarAlgHom.norm_apply_le π a + _ = _ := by ring + + +def normalVectors : Submodule ℂ H := ⨅ η : H, (normalDual e).comap (coefficient π η).toLinearMap + +omit [CompleteSpace X] in +lemma mem_normalVectors (ξ : H) : + ξ ∈ normalVectors e π ↔ ∀ η, coefficient π η ξ ∈ normalDual e := by + simp only [normalVectors,Submodule.mem_iInf,Submodule.mem_comap,ContinuousLinearMap.coe_coe] + +lemma normalVectors_closed : IsClosed (normalVectors e π : Set H) := by + have hs : (normalVectors e π : Set H)=⋂ η : H, (coefficient π η) ⁻¹' (normalDual e : Set (StrongDual ℂ M)) := by + ext ξ; simp only [Set.mem_iInter,Set.mem_preimage,SetLike.mem_coe,mem_normalVectors] + rw [hs] + exact isClosed_iInter fun η => (normalDual_closed e).preimage (coefficient π η).continuous + +instance normalVectors_complete : CompleteSpace (normalVectors e π) := + (normalVectors_closed e π).completeSpace_coe + +lemma normalVectors_mul {ξ : H} (hξ : ξ ∈ normalVectors e π) (b : M) : + π b ξ ∈ normalVectors e π := by + rw [mem_normalVectors] at hξ ⊢ + intro η + have hc : coefficient π η (π b ξ) = + (coefficient π η ξ).comp ((ContinuousLinearMap.mul ℂ M).flip b) := by + ext a; simp [map_mul] + rw [hc] + exact normalDual_comp e (hξ η) _ ((HochschildSakai.abstract_multiplication_normal e).2 b) + +omit [CompleteSpace X] in +lemma normalVectors_commutant {ξ : H} (hξ : ξ ∈ normalVectors e π) + (T : H →L[ℂ] H) (hT : ∀ a : M, T * π a=π a*T) : + T ξ ∈ normalVectors e π := by + rw [mem_normalVectors] at hξ ⊢ + intro η + have hc : coefficient π η (T ξ)=coefficient π (star T η) ξ := by + ext a + change ⟪η,π a (T ξ)⟫_ℂ=⟪T.adjoint η,π a ξ⟫_ℂ + rw [ContinuousLinearMap.adjoint_inner_left] + exact congrArg (inner ℂ η) (congrArg (fun S : H →L[ℂ] H => S ξ) (hT a).symm) + rw [hc] + exact hξ _ + + + +lemma projection_commutes (K : Submodule ℂ H) [K.HasOrthogonalProjection] + (T : H →L[ℂ] H) + (hT : ∀ ξ ∈ K, T ξ ∈ K) (hTstar : ∀ ξ ∈ K, star T ξ ∈ K) : + K.starProjection*T=T*K.starProjection := by + ext ξ + change K.starProjection (T ξ)=T (K.starProjection ξ) + apply Submodule.eq_starProjection_of_mem_orthogonal (hT _ (by simp)) + intro η hη + change ⟪η,T ξ-T (K.starProjection ξ)⟫_ℂ=0 + rw [← map_sub] + rw [← ContinuousLinearMap.adjoint_inner_left] + exact K.sub_starProjection_mem_orthogonal ξ _ (hTstar η hη) + + +def normalProjection : H →L[ℂ] H := (normalVectors e π).starProjection + +lemma normalProjection_mul (a : M) : + normalProjection e π*π a=π a*normalProjection e π := by + apply projection_commutes + · intro ξ hξ; exact normalVectors_mul e π hξ a + · intro ξ hξ + rw [← map_star] + exact normalVectors_mul e π hξ (star a) + +lemma normalProjection_commutant (T : H →L[ℂ] H) + (hT : ∀ a : M, T*π a=π a*T) : + normalProjection e π*T=T*normalProjection e π := by + apply projection_commutes + · intro ξ hξ; exact normalVectors_commutant e π hξ T hT + · intro ξ hξ + apply normalVectors_commutant e π hξ + intro a + have h := congrArg star (hT (star a)) + simpa only [star_mul,← map_star,star_star] using h.symm + + +def coefficientLeft (ξ : H) : H →L⋆[ℂ] StrongDual ℂ M := by + let L : H →ₗ⋆[ℂ] StrongDual ℂ M := + { toFun := fun η => coefficient π η ξ + map_add' := by intro η ζ; ext a; simp + map_smul' := by intro r η; ext a; simp [mul_comm] } + exact L.mkContinuous ‖ξ‖ (fun η => by + change ‖coefficient π η ξ‖ ≤ ‖ξ‖*‖η‖ + simpa only [mul_comm] using coefficient_norm π η ξ) + +@[simp] lemma coefficientLeft_apply (ξ η : H) : + coefficientLeft π ξ η=coefficient π η ξ := rfl + + +def cyclicSpace (ξ : H) : Submodule ℂ H := + (Submodule.span ℂ (Set.range fun a : M => π a ξ)).topologicalClosure + +lemma cyclicSpace_closed (ξ : H) : IsClosed (cyclicSpace π ξ : Set H) := + Submodule.isClosed_topologicalClosure _ + +instance cyclicSpace_complete (ξ : H) : CompleteSpace (cyclicSpace π ξ) := + (cyclicSpace_closed π ξ).completeSpace_coe + +lemma cyclicSpace_mem (ξ : H) : ξ ∈ cyclicSpace π ξ := by + apply Submodule.le_topologicalClosure + apply Submodule.subset_span + exact ⟨1,by simp⟩ + +lemma cyclicSpace_mul (ξ : H) (b : M) {ζ : H} (hζ : ζ ∈ cyclicSpace π ξ) : + π b ζ ∈ cyclicSpace π ξ := by + let S := cyclicSpace π ξ + have hle : (Submodule.span ℂ (Set.range fun a : M => π a ξ)).topologicalClosure ≤ + S.comap (π b).toLinearMap := by + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro _ ⟨a,rfl⟩ + change π b (π a ξ) ∈ S + change π b (π a ξ) ∈ (Submodule.span ℂ (Set.range fun a : M => π a ξ)).topologicalClosure + apply Submodule.le_topologicalClosure + rw [← mul_apply_eq_comp,← map_mul] + exact Submodule.subset_span (Set.mem_range_self (b*a)) + · exact (cyclicSpace_closed π ξ).preimage (π b).continuous + exact hle hζ + +lemma cyclicProjection_mul (ξ : H) (a : M) : + (cyclicSpace π ξ).starProjection*π a=π a*(cyclicSpace π ξ).starProjection := by + apply projection_commutes + · intro ζ hζ; exact cyclicSpace_mul π ξ a hζ + · intro ζ hζ + rw [← map_star] + exact cyclicSpace_mul π ξ (star a) hζ + + + +lemma cyclic_coefficients_normal (η ξ : H) + (h : coefficient π η ξ ∈ normalDual e) {ζ : H} (hζ : ζ ∈ cyclicSpace π η) : + coefficient π ζ ξ ∈ normalDual e := by + let S := (normalDual e).comap (coefficientLeft π ξ).toLinearMap + have hle : cyclicSpace π η ≤ S := by + apply Submodule.topologicalClosure_minimal + · apply Submodule.span_le.mpr + rintro _ ⟨b,rfl⟩ + change coefficient π (π b η) ξ ∈ normalDual e + have hc : coefficient π (π b η) ξ=(coefficient π η ξ).comp + (ContinuousLinearMap.mul ℂ M (star b)) := by + ext a + change ⟪π b η,π a ξ⟫_ℂ=⟪η,π (star b*a) ξ⟫_ℂ + rw [map_mul,mul_apply_eq_comp,map_star] + exact (ContinuousLinearMap.adjoint_inner_right (π b) η (π a ξ)).symm + rw [hc] + exact normalDual_comp e h _ ((HochschildSakai.abstract_multiplication_normal e).1 _) + · exact (normalDual_closed e).preimage (coefficientLeft π ξ).continuous + exact hle hζ + + + +lemma normalProjection_fixes_normal (η ξ : H) + (h : coefficient π η ξ ∈ normalDual e) : + coefficient π η (normalProjection e π ξ)=coefficient π η ξ := by + let K := cyclicSpace π η + let Q := K.starProjection + have hQ : ∀ a : M, Q*π a=π a*Q := cyclicProjection_mul π η + have hcoef (ζ : H) : coefficient π ζ (Q ξ)=coefficient π (Q ζ) ξ := by + ext a + change ⟪ζ,π a (Q ξ)⟫_ℂ=⟪Q ζ,π a ξ⟫_ℂ + have hc := congrArg (fun T : H →L[ℂ] H => T ξ) (hQ a) + change Q (π a ξ)=π a (Q ξ) at hc + rw [← hc] + exact (K.inner_starProjection_left_eq_right ζ (π a ξ)).symm + have hn : Q ξ ∈ normalVectors e π := by + rw [mem_normalVectors] + intro ζ + rw [hcoef] + exact cyclic_coefficients_normal e π η ξ h (by simp [Q,K]) + have hP : normalProjection e π (Q ξ)=Q ξ := + Submodule.starProjection_eq_self_iff.mpr hn + have hcomm := congrArg (fun T : H →L[ℂ] H => T ξ) (normalProjection_commutant e π Q hQ) + change normalProjection e π (Q ξ)=Q (normalProjection e π ξ) at hcomm + have hη : Q η=η := Submodule.starProjection_eq_self_iff.mpr (cyclicSpace_mem π η) + calc + coefficient π η (normalProjection e π ξ) = coefficient π (Q η) (normalProjection e π ξ) := by rw [hη] + _ = coefficient π η (Q (normalProjection e π ξ)) := by + ext a + change ⟪Q η,π a (normalProjection e π ξ)⟫_ℂ=⟪η,π a (Q (normalProjection e π ξ))⟫_ℂ + rw [K.inner_starProjection_left_eq_right] + exact congrArg (inner ℂ η) (congrArg (fun T : H →L[ℂ] H => T (normalProjection e π ξ)) (hQ a)) + _ = coefficient π η (Q ξ) := by rw [← hcomm,hP] + _ = coefficient π (Q η) ξ := hcoef η + _ = coefficient π η ξ := by rw [hη] + +end HochschildNormalPart + + + +open scoped InnerProductSpace +namespace HochschildNormalPart +universe u v w +variable {M : Type u} [CStarAlgebra M] +variable {H : Type v} {K : Type w} + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + + +def sumOperator (T : H →L[ℂ] H) (S : K →L[ℂ] K) : + WithLp 2 (H × K) →L[ℂ] WithLp 2 (H × K) := + (WithLp.prodContinuousLinearEquiv 2 ℂ H K).symm.toContinuousLinearMap.comp + ((T.prodMap S).comp (WithLp.prodContinuousLinearEquiv 2 ℂ H K).toContinuousLinearMap) + +omit [CompleteSpace H] [CompleteSpace K] in +@[simp] lemma sumOperator_apply (T : H →L[ℂ] H) (S : K →L[ℂ] K) (x : WithLp 2 (H×K)) : + sumOperator T S x=WithLp.toLp 2 (T x.fst,S x.snd) := rfl + + +def sumRepresentation (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) : + M →⋆ₐ[ℂ] (WithLp 2 (H×K) →L[ℂ] WithLp 2 (H×K)) where + toFun a := sumOperator (π a) (ρ a) + map_zero' := by ext x; simp + map_one' := by ext x; simp; rfl + map_add' a b := by ext x; simp; rfl + map_mul' a b := by ext x; simp [map_mul,mul_apply_eq_comp] + commutes' c := by ext x; simp [Algebra.algebraMap_eq_smul_one]; rfl + map_star' a := by + apply (ContinuousLinearMap.eq_adjoint_iff _ _).mpr + intro x y + simp only [sumOperator_apply,WithLp.prod_inner_apply, + map_star,ContinuousLinearMap.star_eq_adjoint] + simp only [ContinuousLinearMap.adjoint_inner_left] + rfl + +@[simp] lemma sumRepresentation_apply (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) + (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) (a : M) (x : WithLp 2 (H×K)) : + sumRepresentation π ρ a x=WithLp.toLp 2 (π a x.fst,ρ a x.snd) := rfl + +lemma coefficient_sum (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + (η ξ : WithLp 2 (H×K)) : + coefficient (sumRepresentation π ρ) η ξ= + coefficient π η.fst ξ.fst+coefficient ρ η.snd ξ.snd := by + ext a; rfl + +variable {X : Type u} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (π : M →⋆ₐ[ℂ] (H →L[ℂ] H)) (ρ : M →⋆ₐ[ℂ] (K →L[ℂ] K)) + +omit [CompleteSpace X] in +lemma mem_normalVectors_sum (ξ : WithLp 2 (H×K)) : + ξ ∈ normalVectors e (sumRepresentation π ρ) ↔ + ξ.fst ∈ normalVectors e π ∧ ξ.snd ∈ normalVectors e ρ := by + simp only [mem_normalVectors,coefficient_sum] + constructor + · intro h + constructor + · intro η + have h' := h (WithLp.toLp 2 (η,0)) + change coefficient π η ξ.fst+coefficient ρ 0 ξ.snd ∈ normalDual e at h' + have hz : coefficient ρ 0 ξ.snd=0 := by ext a; simp + simpa only [hz,add_zero] using h' + · intro η + have h' := h (WithLp.toLp 2 (0,η)) + change coefficient π 0 ξ.fst+coefficient ρ η ξ.snd ∈ normalDual e at h' + have hz : coefficient π 0 ξ.fst=0 := by ext a; simp + simpa only [hz,zero_add] using h' + · rintro ⟨hπ,hρ⟩ η + exact (normalDual e).add_mem (hπ η.fst) (hρ η.snd) + + +lemma normalProjection_sum (ξ : WithLp 2 (H×K)) : + normalProjection e (sumRepresentation π ρ) ξ= + WithLp.toLp 2 (normalProjection e π ξ.fst,normalProjection e ρ ξ.snd) := by + apply Submodule.eq_starProjection_of_mem_orthogonal + · rw [mem_normalVectors_sum] + change normalProjection e π ξ.fst ∈ normalVectors e π ∧ + normalProjection e ρ ξ.snd ∈ normalVectors e ρ + exact ⟨by simp [normalProjection],by simp [normalProjection]⟩ + · intro η hη + obtain ⟨hη₁,hη₂⟩ := (mem_normalVectors_sum e π ρ η).mp hη + change ⟪η,ξ-WithLp.toLp 2 (normalProjection e π ξ.fst,normalProjection e ρ ξ.snd)⟫_ℂ=0 + change ⟪η.fst,ξ.fst-normalProjection e π ξ.fst⟫_ℂ+ + ⟪η.snd,ξ.snd-normalProjection e ρ ξ.snd⟫_ℂ=0 + unfold normalProjection + rw [(normalVectors e π).sub_starProjection_mem_orthogonal ξ.fst η.fst hη₁, + (normalVectors e ρ).sub_starProjection_mem_orthogonal ξ.snd η.snd hη₂,add_zero] + + + +lemma coefficient_normal_eq_of_eq + (η ξ : H) (ζ ω : K) (h : coefficient π η ξ=coefficient ρ ζ ω) : + coefficient π η (normalProjection e π ξ)=coefficient ρ ζ (normalProjection e ρ ω) := by + let A : WithLp 2 (H×K) := WithLp.toLp 2 (η,ζ) + let B : WithLp 2 (H×K) := WithLp.toLp 2 (ξ,-ω) + have hz : coefficient (sumRepresentation π ρ) A B=0 := by + rw [coefficient_sum] + change coefficient π η ξ+coefficient ρ ζ (-ω)=0 + rw [map_neg,h,add_neg_cancel] + have hn : coefficient (sumRepresentation π ρ) A B ∈ normalDual e := hz ▸ (normalDual e).zero_mem + have hp := normalProjection_fixes_normal e (sumRepresentation π ρ) A B hn + rw [hz,normalProjection_sum,coefficient_sum] at hp + change coefficient π η (normalProjection e π ξ)+coefficient ρ ζ (normalProjection e ρ (-ω))=0 at hp + rw [map_neg,map_neg] at hp + exact eq_of_sub_eq_zero (by simpa only [sub_eq_add_neg] using hp) + +end HochschildNormalPart +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorPrimitives.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorPrimitives.lean new file mode 100644 index 0000000000000000000000000000000000000000..300ddc4f5214ec80b7d736f69c7336ee046ed60c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorPrimitives.lean @@ -0,0 +1,219 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.NormalMultiplication + +namespace OAI + +/-! Primitives on operator algebras and polar partial isometries. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +namespace BoundedHochschild +variable {E : Type*} [NormedAddCommGroup E] [NormedSpace ℂ E] + + +def rankOneColumn (φ : StrongDual ℂ E) : E →L[ℂ] (E →L[ℂ] E) := + ContinuousLinearMap.smulRightL ℂ E E φ + +@[simp] lemma rankOneColumn_apply (φ : StrongDual ℂ E) (x y : E) : + rankOneColumn φ x y = φ y • x := rfl + +lemma mul_rankOneColumn (φ : StrongDual ℂ E) (a : E →L[ℂ] E) (y : E) : + a * rankOneColumn φ y = rankOneColumn φ (a y) := by + ext z + simp + + + +def columnEvaluate (φ : StrongDual ℂ E) (x : E) : + ((E →L[ℂ] E) →L[ℂ] (E →L[ℂ] E)) →L[ℂ] (E →L[ℂ] E) := + (ContinuousLinearMap.compL ℂ E (E →L[ℂ] E) E ((ContinuousLinearMap.apply ℂ E) x)).comp + ((ContinuousLinearMap.compL ℂ E (E →L[ℂ] E) (E →L[ℂ] E)).flip (rankOneColumn φ)) + +@[simp] lemma columnEvaluate_apply (φ : StrongDual ℂ E) (x y : E) + (F : (E →L[ℂ] E) →L[ℂ] (E →L[ℂ] E)) : + columnEvaluate φ x F y = F (rankOneColumn φ y) x := rfl + + +def operatorHomotopy (φ : StrongDual ℂ E) (x : E) {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) : Cochain (E →L[ℂ] E) n := + (columnEvaluate φ x).compContinuousMultilinearMap f.curryRight + +@[simp] lemma operatorHomotopy_apply (φ : StrongDual ℂ E) (x y : E) {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) (v : Fin n → (E →L[ℂ] E)) : + operatorHomotopy φ x f v y = f (Fin.snoc v (rankOneColumn φ y)) x := rfl + +lemma operatorHomotopy_cocycle (φ : StrongDual ℂ E) (x : E) (hφ : φ x=1) {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) + (hf : ∀ v, differentialValue f v=0) (v : Fin (n+1) → (E →L[ℂ] E)) : + differentialValue (operatorHomotopy φ x f) v = ((-1:ℂ)^(n+1)) • f v := by + have hzero : differentialValue (operatorHomotopy φ x f) v + + ((-1:ℂ)^(n+2)) • f v=0 := by + ext y + have h := congrArg (fun a : E →L[ℂ] E => a x) (hf (Fin.snoc v (rankOneColumn φ y))) + rw [differentialValue_snoc] at h + simpa only [differentialValue, add_apply, + sum_apply, smul_apply, + zero_apply, mul_apply_eq_comp, operatorHomotopy_apply, + mul_rankOneColumn, rankOneColumn_apply, hφ, one_smul] using h + have hp : (-1:ℂ)^(n+2) = -((-1:ℂ)^(n+1)) := by + rw [show n+2=(n+1)+1 by omega, pow_succ] + ring + rw [hp,neg_smul] at hzero + exact sub_eq_zero.mp (by simpa only [sub_eq_add_neg] using hzero) + +lemma operatorHomotopy_norm (φ : StrongDual ℂ E) (x : E) {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) : + ‖operatorHomotopy φ x f‖ ≤ ‖f‖ * ‖φ‖ * ‖x‖ := by + apply ContinuousMultilinearMap.opNorm_le_bound (by positivity) + intro v + apply ContinuousLinearMap.opNorm_le_bound _ (by positivity) + intro y + calc + ‖operatorHomotopy φ x f v y‖ ≤ ‖f (Fin.snoc v (rankOneColumn φ y))‖ * ‖x‖ := + (f (Fin.snoc v (rankOneColumn φ y))).le_opNorm x + _ ≤ (‖f‖ * (∏ i, ‖v i‖) * ‖rankOneColumn φ y‖) * ‖x‖ := + mul_le_mul_of_nonneg_right (f.norm_map_snoc_le v (rankOneColumn φ y)) (norm_nonneg _) + _ = ((‖f‖ * ‖φ‖ * ‖x‖) * ∏ i, ‖v i‖) * ‖y‖ := by + change (‖f‖ * (∏ i, ‖v i‖) * ‖φ.smulRight y‖) * ‖x‖ = _ + rw [ContinuousLinearMap.norm_smulRight_apply] + ring + + + +theorem primitive_on_operators_of_dual_pair + (φ : StrongDual ℂ E) (x : E) (hφ : φ x=1) {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) (hf : ∀ v, differentialValue f v=0) : + ∃ g : Cochain (E →L[ℂ] E) n, ‖g‖ ≤ ‖f‖ * ‖φ‖ * ‖x‖ ∧ + ∀ v, differentialValue g v=f v := by + refine ⟨((-1:ℂ)^(n+1)) • operatorHomotopy φ x f, ?_, ?_⟩ + · simpa only [norm_smul,norm_pow,norm_neg,norm_one,one_pow,one_mul] + using operatorHomotopy_norm φ x f + · intro v + rw [differentialValue_smul, operatorHomotopy_cocycle φ x hφ f hf v, smul_smul] + have hp : (-1:ℂ)^(n+1)*(-1:ℂ)^(n+1)=1 := by + rw [← mul_pow] + simp + rw [hp,one_smul] + + + +theorem primitive_on_operators {n : ℕ} + (f : Cochain (E →L[ℂ] E) (n+1)) (hf : ∀ v, differentialValue f v=0) : + ∃ g : Cochain (E →L[ℂ] E) n, ‖g‖ ≤ ‖f‖ ∧ ∀ v, differentialValue g v=f v := by + classical + by_cases hE : Nontrivial E + · let := hE + let : NormedSpace ℝ E := NormedSpace.restrictScalars ℝ ℂ E + obtain ⟨x,hx⟩ := exists_norm_eq E (show (0:ℝ) ≤ 1 by norm_num) + obtain ⟨φ,hφn,hφ⟩ := exists_dual_vector ℂ x (by rw [hx]; norm_num) + obtain ⟨g,hgn,hg⟩ := primitive_on_operators_of_dual_pair φ x + (by simpa [hx] using hφ) f hf + exact ⟨g,by simpa only [hx,hφn,mul_one] using hgn,hg⟩ + · let : Subsingleton E := not_nontrivial_iff_subsingleton.mp hE + exact ⟨0,by simp,fun _ => Subsingleton.elim _ _⟩ + +end BoundedHochschild + + + +open Filter Topology +namespace HochschildPolar +open BoundedHochschild HochschildSakai +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + +include e in + + +theorem exists_polar_contraction (b : M) : + ∃ v : M, ‖v‖ ≤ 1 ∧ b=v*CFC.abs b ∧ CFC.abs b=star v*b := by + classical + have hpos (n : ℕ) : 0 < (1:ℝ)/((n:ℝ)+1) := by positivity + choose v hv hleft hright using + fun n : ℕ => HochschildTraceNorm.exists_approx_polar b _ (hpos n) + let U : Ultrafilter ℕ := Ultrafilter.of atTop + have hU : (U : Filter ℕ) ≤ atTop := Ultrafilter.of_le _ + obtain ⟨w,hw,ht⟩ := exists_predual_ultralimit e U v 1 hv + have hε : Tendsto (fun n : ℕ => (1:ℝ)/((n:ℝ)+1)) atTop (𝓝 0) := + tendsto_one_div_add_atTop_nhds_zero_nat + have hl : Tendsto (fun n => v n*CFC.abs b) atTop (𝓝 b) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + apply squeeze_zero (fun n => norm_nonneg _) _ hε + intro n + rw [norm_sub_rev] + exact hleft n + have hr : Tendsto (fun n => star (v n)*b) atTop (𝓝 (CFC.abs b)) := by + rw [tendsto_iff_norm_sub_tendsto_zero] + apply squeeze_zero (fun n => norm_nonneg _) _ hε + intro n + rw [norm_sub_rev] + exact hright n + exact ⟨w,hw, + predual_tendsto_unique e (predual_tendsto_of_norm e (hl.mono_left hU)) + (predual_tendsto_mul_right e _ ht), + predual_tendsto_unique e (predual_tendsto_of_norm e (hr.mono_left hU)) + (predual_tendsto_mul_right e _ (predual_tendsto_star e ht))⟩ + +omit [PartialOrder M] [StarOrderedRing M] in +lemma support_right_annihilate {a p : M} (hp : IsSupportProjection a p) + (ha : IsSelfAdjoint a) {x : M} (hx : x*a=0) : x*p=0 := by + have hh := hp.annihilate (star x) (by + simpa only [star_mul,ha.star_eq,star_zero] using congrArg star hx) + simpa only [star_mul,star_star,hp.proj.isSelfAdjoint.star_eq,star_zero] + using congrArg star hh + +include e in + + +theorem exists_polar_partial_isometry (b : M) : + ∃ v p q : M, IsSupportProjection (CFC.abs b) p ∧ + star v*v=p ∧ v*star v=q ∧ IsStarProjection q ∧ b=v*CFC.abs b ∧ + v*p=v ∧ q*b=b := by + obtain ⟨w,hw,hb,ha⟩ := exists_polar_contraction e b + obtain ⟨p,hp⟩ := HochschildSakai.exists_support_projection e (CFC.abs b) (CFC.abs_nonneg b) + let v := w*p + have hvp : v*p=v := by + dsimp [v] + rw [mul_assoc,hp.proj.isIdempotentElem.eq] + have hvb : v*CFC.abs b=b := by + dsimp [v] + rw [mul_assoc,hp.left,← hb] + have hv : star v*b=CFC.abs b := by + dsimp [v] + rw [star_mul,hp.proj.isSelfAdjoint.star_eq,mul_assoc,← ha,hp.left] + have hinit : star v*v=p := by + have hz : (star v*v-p)*CFC.abs b=0 := by + rw [sub_mul,mul_assoc,hvb,hv,hp.left,sub_self] + have hh := support_right_annihilate hp (IsSelfAdjoint.of_nonneg (CFC.abs_nonneg b)) hz + rw [sub_mul,mul_assoc,hvp,hp.proj.isIdempotentElem.eq,sub_eq_zero] at hh + exact hh + have hfinal : IsStarProjection (v*star v) := by + constructor + · change (v*star v)*(v*star v)=v*star v + calc + _ = v*(star v*v)*star v := by simp only [mul_assoc] + _ = v*star v := by rw [hinit,hvp] + · exact IsSelfAdjoint.mul_star_self v + refine ⟨v,p,v*star v,hp,hinit,rfl,hfinal,hvb.symm,hvp,?_⟩ + rw [mul_assoc,hv,hvb] + +end HochschildPolar +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorRowAverages.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorRowAverages.lean new file mode 100644 index 0000000000000000000000000000000000000000..22c01948000830af2c34f1590316756110c2d84f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorRowAverages.lean @@ -0,0 +1,94 @@ +import OAI.Analysis.BoundedHochschild.CompletelyBoundedFactorization + +namespace OAI + +/-! The operator in a factorization remains bounded under normalized row +averaging. Both represented rows are allowed to act on different Hilbert spaces. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {I H K : Type*} [Fintype I] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +lemma sum_norm_adjoint_sq (a : I → (H →L[ℂ] H)) + (ha : ∑ i, a i * star (a i) = 1) (ξ : H) : + ∑ i, ‖(a i).adjoint ξ‖ ^ 2 = ‖ξ‖ ^ 2 := by + have he : (∑ i, inner ℂ ((a i).adjoint ξ) ((a i).adjoint ξ)) = inner ℂ ξ ξ := by + calc + _ = ∑ i, inner ℂ ξ ((a i) ((a i).adjoint ξ)) := by + apply Finset.sum_congr rfl + intro i _ + exact (ContinuousLinearMap.adjoint_inner_left (a i) ((a i).adjoint ξ) ξ) + _ = inner ℂ ξ ((∑ i, a i * star (a i)) ξ) := by + simp only [sum_apply, inner_sum, ContinuousLinearMap.star_eq_adjoint] + rfl + _ = inner ℂ ξ ξ := by rw [ha]; rfl + have hr := congrArg Complex.re he + change Complex.re (∑ i, inner ℂ ((a i).adjoint ξ) ((a i).adjoint ξ)) = + RCLike.re (inner ℂ ξ ξ) at hr + simp only [Complex.re_sum] at hr + change (∑ i, RCLike.re (inner ℂ ((a i).adjoint ξ) ((a i).adjoint ξ))) = + RCLike.re (inner ℂ ξ ξ) at hr + simpa only [inner_self_eq_norm_sq] using hr + +omit [CompleteSpace K] in +lemma norm_sum_inner_sq_le (x y : I → K) : + ‖∑ i, inner ℂ (x i) (y i)‖ ^ 2 ≤ + (∑ i, ‖x i‖ ^ 2) * ∑ i, ‖y i‖ ^ 2 := by + have h : ‖∑ i, inner ℂ (x i) (y i)‖ ≤ ∑ i, ‖x i‖ * ‖y i‖ := + (norm_sum_le _ _).trans (Finset.sum_le_sum fun i _ => norm_inner_le_norm (x i) (y i)) + exact (pow_le_pow_left₀ (norm_nonneg _) h 2).trans + (Finset.sum_mul_sq_le_sq_mul_sq _ _ _) + +def operatorRowAverage (a : I → (K →L[ℂ] K)) (b : I → (H →L[ℂ] H)) + (W : H →L[ℂ] K) : H →L[ℂ] K := + ∑ i, (a i).comp (W.comp (b i).adjoint) + +omit [CompleteSpace K] in +@[simp] lemma operatorRowAverage_apply (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) (W : H →L[ℂ] K) (ξ : H) : + operatorRowAverage a b W ξ = ∑ i, a i (W ((b i).adjoint ξ)) := by + simp only [operatorRowAverage, sum_apply, ContinuousLinearMap.comp_apply] + +theorem operatorRowAverage_norm_le (a : I → (K →L[ℂ] K)) + (b : I → (H →L[ℂ] H)) (ha : ∑ i, a i * star (a i) = 1) + (hb : ∑ i, b i * star (b i) = 1) (W : H →L[ℂ] K) : + ‖operatorRowAverage a b W‖ ≤ ‖W‖ := by + apply ContinuousLinearMap.opNorm_le_bound _ (norm_nonneg W) + intro ξ + let ζ := operatorRowAverage a b W ξ + have he : inner ℂ ζ ζ = ∑ i, inner ℂ ((a i).adjoint ζ) (W ((b i).adjoint ξ)) := by + conv_lhs => rhs; rw [show ζ = operatorRowAverage a b W ξ from rfl, + operatorRowAverage_apply] + rw [inner_sum] + apply Finset.sum_congr rfl + intro i _ + exact (ContinuousLinearMap.adjoint_inner_left (a i) (W ((b i).adjoint ξ)) ζ).symm + have hs : ∑ i, ‖W ((b i).adjoint ξ)‖ ^ 2 ≤ ‖W‖ ^ 2 * ‖ξ‖ ^ 2 := by + calc + _ ≤ ∑ i, (‖W‖ * ‖(b i).adjoint ξ‖) ^ 2 := by + apply Finset.sum_le_sum + intro i _ + exact pow_le_pow_left₀ (norm_nonneg _) (W.le_opNorm _) 2 + _ = ‖W‖ ^ 2 * ∑ i, ‖(b i).adjoint ξ‖ ^ 2 := by + simp only [mul_pow, Finset.mul_sum] + _ = _ := by rw [sum_norm_adjoint_sq b hb ξ] + have hi := norm_sum_inner_sq_le (fun i => (a i).adjoint ζ) + (fun i => W ((b i).adjoint ξ)) + rw [← he, inner_self_eq_norm_sq_to_K, norm_pow, RCLike.norm_ofReal, + abs_of_nonneg (norm_nonneg ζ), sum_norm_adjoint_sq a ha ζ] at hi + have hf : (‖ζ‖ ^ 2) ^ 2 ≤ ‖ζ‖ ^ 2 * (‖W‖ ^ 2 * ‖ξ‖ ^ 2) := + hi.trans (mul_le_mul_of_nonneg_left hs (sq_nonneg _)) + have hsq : ‖ζ‖ ^ 2 ≤ (‖W‖ * ‖ξ‖) ^ 2 := by nlinarith [sq_nonneg (‖ζ‖ ^ 2 - ‖W‖ ^ 2 * ‖ξ‖ ^ 2)] + exact (sq_le_sq₀ (norm_nonneg ζ) (mul_nonneg (norm_nonneg W) (norm_nonneg ξ))).mp hsq + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorSystemCompression.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemCompression.lean new file mode 100644 index 0000000000000000000000000000000000000000..321b515c559bd49815e065695d9e27b0bc6c9170 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemCompression.lean @@ -0,0 +1,50 @@ +import OAI.Analysis.BoundedHochschild.OperatorSystemMatrices +import OAI.Analysis.BoundedHochschild.CompletelyPositiveCompression + +namespace OAI + +/-! Compression of positive matrix levels on a unital linear subspace. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H K : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + [NormedAddCommGroup K] [InnerProductSpace ℂ K] [CompleteSpace K] + +def compressOperatorSystem (S : Submodule ℂ A) (φ : S →ₗ[ℂ] (H →L[ℂ] H)) + (V : K →L[ℂ] H) : S →ₗ[ℂ] (K →L[ℂ] K) where + toFun a := V.adjoint.comp ((φ a).comp V) + map_add' a b := by ext ξ; simp + map_smul' z a := by ext ξ; simp + +omit [PartialOrder A] [StarOrderedRing A] in +lemma compressOperatorSystem_positive (S : Submodule ℂ A) + (φ : S →ₗ[ℂ] (H →L[ℂ] H)) (V : K →L[ℂ] H) {n : ℕ} + (X : operatorSystemMatrices S n) (hX : 0 ≤ operatorSystemAmplification S φ n X) : + 0 ≤ operatorSystemAmplification S (compressOperatorSystem S φ V) n X := by + apply operatorMatrix_nonneg_of_quadratic + intro ξ + change 0 ≤ ∑ i, ∑ j, inner ℂ (ξ i) + (V.adjoint (φ ⟨X.val i j, X.property i j⟩ (V (ξ j)))) + simp only [ContinuousLinearMap.adjoint_inner_right] + exact operatorMatrix_quadratic_nonneg (operatorSystemAmplification S φ n X) hX + (fun i => V (ξ i)) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma compressOperatorSystem_one (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (φ : S →ₗ[ℂ] (H →L[ℂ] H)) (hφ : φ ⟨1, h1⟩ = 1) (V : K →ₗᵢ[ℂ] H) : + compressOperatorSystem S φ V.toContinuousLinearMap ⟨1, h1⟩ = 1 := by + change V.toContinuousLinearMap.adjoint.comp ((φ ⟨1, h1⟩).comp V.toContinuousLinearMap) = 1 + rw [hφ] + change V.toContinuousLinearMap.adjoint.comp V.toContinuousLinearMap = 1 + exact V.adjoint_comp_self + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorSystemExtension.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemExtension.lean new file mode 100644 index 0000000000000000000000000000000000000000..22a9cff5cbcc35f6340f89ef40698f1e2a842d34 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemExtension.lean @@ -0,0 +1,78 @@ +import OAI.Analysis.BoundedHochschild.OperatorSystemFunctionals + +namespace OAI + +/-! Positive scalar extension from an operator system. No multiplicative +closure or closedness of the subspace is required. -/ + +noncomputable section + +open scoped ComplexOrder ComplexStarModule + +namespace BoundedHochschild.KadisonRingrose + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +theorem exists_positive_operatorSystem_extension + (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (hstar : ∀ a ∈ S, star a ∈ S) (f : S →ₗ[ℂ] ℂ) + (hf : ∀ a : S, 0 ≤ (a : A) → 0 ≤ f a) : + ∃ F : A →ₚ[ℂ] ℂ, ∀ a : S, F (a : A) = f a := by + let c := (f ⟨1, h1⟩).re + have hc : 0 ≤ c := (hf ⟨1, h1⟩ zero_le_one).1 + let g := operatorSystemRealFunctional S h1 f hf + have hg : ‖g‖ ≤ c := by + apply g.opNorm_le_bound hc + intro a + exact positive_subspace_real_bound S h1 f hf (operatorSystemRealInclusion S a) + a.property.2 + obtain ⟨G₀, hG₀, hnG₀⟩ := exists_extension_norm_eq (operatorSystemRealPart S) g + let sa : selfAdjoint A →L[ℝ] A := + ((selfAdjoint.submodule ℝ A).subtype).mkContinuous 1 (fun a => by simp) + let G := G₀.comp sa + have hGn : ‖G‖ ≤ c := by + apply G.opNorm_le_bound hc + intro a + exact (G₀.le_opNorm (sa a)).trans + (mul_le_mul_of_nonneg_right (hnG₀.trans_le hg) (norm_nonneg a)) + have hG1 : G 1 = c := by + exact hG₀ ⟨1, h1, IsSelfAdjoint.one A⟩ + let F : A →ₚ[ℂ] ℂ := + PositiveLinearMap.mk₀ (NaimarkZFC.selfAdjointComplexify G.toLinearMap) (fun a ha => by + let x : selfAdjoint A := ⟨a, ha.isSelfAdjoint⟩ + change 0 ≤ NaimarkZFC.selfAdjointComplexify G.toLinearMap (x : A) + rw [NaimarkZFC.selfAdjointComplexify_coe] + exact ⟨selfAdjoint_nonneg_of_norm_le G c hGn hG1 x ha, by simp⟩) + have hsa (a : S) (ha : IsSelfAdjoint (a : A)) : F (a : A) = f a := by + let b : operatorSystemRealPart S := ⟨a, a.property, ha⟩ + let x : selfAdjoint A := ⟨a, ha⟩ + change NaimarkZFC.selfAdjointComplexify G.toLinearMap (x : A) = f a + rw [NaimarkZFC.selfAdjointComplexify_coe] + change (G₀ b : ℂ) = f a + rw [hG₀ b] + change ((f a).re : ℂ) = f a + apply Complex.ext + · simp + · simpa using (positive_subspace_selfAdjoint_im S h1 f hf a ha).symm + refine ⟨F, fun a => ?_⟩ + have hr : (realPart (a : A) : A) ∈ S := by + rw [realPart_apply_coe, ← Complex.coe_smul] + exact S.smul_mem _ (S.add_mem a.property (hstar a a.property)) + have hi : (imaginaryPart (a : A) : A) ∈ S := by + rw [imaginaryPart_apply_coe, ← Complex.coe_smul] + exact S.smul_mem _ (S.smul_mem _ (S.sub_mem a.property (hstar a a.property))) + let ar : S := ⟨realPart (a : A), hr⟩ + let ai : S := ⟨imaginaryPart (a : A), hi⟩ + have ha : a = ar + Complex.I • ai := by + apply Subtype.ext + exact (realPart_add_I_smul_imaginaryPart (a : A)).symm + rw [ha] + change F ((ar : A) + Complex.I • (ai : A)) = f (ar + Complex.I • ai) + simp only [map_add, map_smul] + rw [hsa ar (realPart (a : A)).property, hsa ai (imaginaryPart (a : A)).property] + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorSystemFunctionals.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemFunctionals.lean new file mode 100644 index 0000000000000000000000000000000000000000..f87b3981e3d709d69cb56bd83d5f3057bfd07e5c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemFunctionals.lean @@ -0,0 +1,101 @@ +import OAI.Analysis.Naimark.States + +namespace OAI + +/-! Positive scalar functionals on unital self-adjoint linear subspaces. +The extension uses real Hahn–Banach on the self-adjoint part. -/ + +noncomputable section + +open scoped ComplexOrder ComplexStarModule + +namespace BoundedHochschild.KadisonRingrose + +variable {A : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + +def operatorSystemRealPart (S : Submodule ℂ A) : Submodule ℝ A := + S.restrictScalars ℝ ⊓ selfAdjoint.submodule ℝ A + +def operatorSystemRealInclusion (S : Submodule ℂ A) : + operatorSystemRealPart S →ₗ[ℝ] S where + toFun x := ⟨x.val, x.property.1⟩ + map_add' _ _ := rfl + map_smul' _ _ := rfl + +lemma positive_subspace_selfAdjoint_im (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : S →ₗ[ℂ] ℂ) (hf : ∀ a : S, 0 ≤ (a : A) → 0 ≤ f a) + (a : S) (ha : IsSelfAdjoint (a : A)) : (f a).im = 0 := by + let e : S := ⟨1, h1⟩ + have he : (f e).im = 0 := (hf e zero_le_one).2.symm + have hb : 0 ≤ ‖a‖ • (1 : A) + (a : A) := by + change 0 ≤ ‖(a : A)‖ • (1 : A) + (a : A) + have h := ha.neg_algebraMap_norm_le_self + simpa only [Algebra.algebraMap_eq_smul_one, neg_le_iff_add_nonneg, add_comm] using h + have h := (hf ((‖a‖ : ℂ) • e + a) (by + change 0 ≤ (‖a‖ : ℂ) • (1 : A) + (a : A) + rw [Complex.coe_smul] + exact hb)).2 + simpa only [map_add, map_smul, smul_eq_mul, Complex.add_im, Complex.mul_im, + Complex.ofReal_re, Complex.ofReal_im, he, mul_zero, zero_mul, zero_add, + Complex.zero_im] using h.symm + +lemma positive_subspace_real_bound (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : S →ₗ[ℂ] ℂ) (hf : ∀ a : S, 0 ≤ (a : A) → 0 ≤ f a) + (a : S) (ha : IsSelfAdjoint (a : A)) : + |(f a).re| ≤ (f ⟨1, h1⟩).re * ‖a‖ := by + let e : S := ⟨1, h1⟩ + have hup : 0 ≤ ‖a‖ • (1 : A) - (a : A) := by + apply sub_nonneg.mpr + change (a : A) ≤ ‖(a : A)‖ • (1 : A) + simpa only [Algebra.algebraMap_eq_smul_one] using ha.le_algebraMap_norm_self + have hlo : 0 ≤ ‖a‖ • (1 : A) + (a : A) := by + change 0 ≤ ‖(a : A)‖ • (1 : A) + (a : A) + simpa only [Algebra.algebraMap_eq_smul_one, neg_le_iff_add_nonneg, add_comm] + using ha.neg_algebraMap_norm_le_self + have hp := (hf ((‖a‖ : ℂ) • e - a) (by + change 0 ≤ (‖a‖ : ℂ) • (1 : A) - (a : A) + rw [Complex.coe_smul] + exact hup)).1 + have hm := (hf ((‖a‖ : ℂ) • e + a) (by + change 0 ≤ (‖a‖ : ℂ) • (1 : A) + (a : A) + rw [Complex.coe_smul] + exact hlo)).1 + simp only [map_sub, map_add, map_smul, smul_eq_mul, Complex.sub_re, Complex.add_re, + Complex.mul_re, Complex.ofReal_re, Complex.ofReal_im, zero_mul, sub_zero, + Complex.zero_re] at hp hm + change 0 ≤ ‖a‖ * (f ⟨1, h1⟩).re - (f a).re at hp + change 0 ≤ ‖a‖ * (f ⟨1, h1⟩).re + (f a).re at hm + exact abs_le.mpr ⟨by nlinarith, by nlinarith⟩ + +def operatorSystemRealFunctional (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) + (f : S →ₗ[ℂ] ℂ) (hf : ∀ a : S, 0 ≤ (a : A) → 0 ≤ f a) : + operatorSystemRealPart S →L[ℝ] ℝ := + LinearMap.mkContinuous + (Complex.reLm.comp ((f.restrictScalars ℝ).comp (operatorSystemRealInclusion S))) + (f ⟨1, h1⟩).re (fun a => + positive_subspace_real_bound S h1 f hf (operatorSystemRealInclusion S a) a.property.2) + +lemma selfAdjoint_nonneg_of_norm_le (g : selfAdjoint A →L[ℝ] ℝ) (c : ℝ) + (hg : ‖g‖ ≤ c) (h1 : g 1 = c) (a : selfAdjoint A) (ha : 0 ≤ (a : A)) : + 0 ≤ g a := by + have hau : (a : A) ≤ ‖a‖ • (1 : A) := by + change (a : A) ≤ ‖(a : A)‖ • (1 : A) + simpa only [Algebra.algebraMap_eq_smul_one] using + (CStarAlgebra.norm_le_iff_le_algebraMap (a : A) (norm_nonneg _) ha).mp le_rfl + have hpos : 0 ≤ ‖a‖ • (1 : A) - (a : A) := sub_nonneg.mpr hau + have hn : ‖‖a‖ • (1 : selfAdjoint A) - a‖ ≤ ‖a‖ := by + change ‖‖a‖ • (1 : A) - (a : A)‖ ≤ ‖a‖ + apply (CStarAlgebra.norm_le_iff_le_algebraMap _ (norm_nonneg _) hpos).mpr + simpa only [Algebra.algebraMap_eq_smul_one] using sub_le_self (‖a‖ • (1 : A)) ha + have hc : ‖g (‖a‖ • (1 : selfAdjoint A) - a)‖ ≤ c * ‖a‖ := + (g.le_opNorm _).trans ((mul_le_mul_of_nonneg_right hg (norm_nonneg _)).trans + (mul_le_mul_of_nonneg_left hn ((norm_nonneg g).trans hg))) + rw [map_sub, map_smul, h1, smul_eq_mul, Real.norm_eq_abs] at hc + have h := (le_abs_self _).trans hc + nlinarith + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorSystemMatrices.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemMatrices.lean new file mode 100644 index 0000000000000000000000000000000000000000..6989f448af985e34c317482771e561f53feca21f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorSystemMatrices.lean @@ -0,0 +1,69 @@ +import OAI.Analysis.BoundedHochschild.OperatorSystemExtension +import OAI.Analysis.BoundedHochschild.StinespringBounds + +namespace OAI + +/-! The scalar matrix functional used in finite-dimensional positive extension. -/ + +noncomputable section + +open scoped ComplexOrder InnerProductSpace + +namespace BoundedHochschild.KadisonRingrose + +variable {A H : Type*} [CStarAlgebra A] [PartialOrder A] [StarOrderedRing A] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +def operatorSystemMatrices (S : Submodule ℂ A) (n : ℕ) : + Submodule ℂ (CStarMatrix (Fin n) (Fin n) A) where + carrier := {X | ∀ i j, X i j ∈ S} + zero_mem' := fun _ _ => S.zero_mem + add_mem' hX hY := fun i j => S.add_mem (hX i j) (hY i j) + smul_mem' z _X hX := fun i j => S.smul_mem z (hX i j) + +omit [PartialOrder A] [StarOrderedRing A] in +lemma operatorSystemMatrices_one (S : Submodule ℂ A) (h1 : (1 : A) ∈ S) (n : ℕ) : + (1 : CStarMatrix (Fin n) (Fin n) A) ∈ operatorSystemMatrices S n := by + intro i j + change (if i = j then (1 : A) else 0) ∈ S + split_ifs + · exact h1 + · exact S.zero_mem + +omit [PartialOrder A] [StarOrderedRing A] in +lemma operatorSystemMatrices_star (S : Submodule ℂ A) + (hs : ∀ a ∈ S, star a ∈ S) (n : ℕ) + (X : CStarMatrix (Fin n) (Fin n) A) (hX : X ∈ operatorSystemMatrices S n) : + star X ∈ operatorSystemMatrices S n := fun i j => hs _ (hX j i) + +def operatorSystemAmplification {B : Type*} [CStarAlgebra B] + (S : Submodule ℂ A) (φ : S →ₗ[ℂ] B) (n : ℕ) : + operatorSystemMatrices S n →ₗ[ℂ] CStarMatrix (Fin n) (Fin n) B where + toFun X := CStarMatrix.ofMatrix (fun i j => φ ⟨X.val i j, X.property i j⟩) + map_add' X Y := by + apply CStarMatrix.ext + intro i j + exact map_add φ ⟨X.val i j, X.property i j⟩ ⟨Y.val i j, Y.property i j⟩ + map_smul' z X := by + apply CStarMatrix.ext + intro i j + exact map_smul φ z ⟨X.val i j, X.property i j⟩ + +def operatorSystemMatrixFunctional (S : Submodule ℂ A) (φ : S →ₗ[ℂ] (H →L[ℂ] H)) + {n : ℕ} (ξ : Fin n → H) : operatorSystemMatrices S n →ₗ[ℂ] ℂ := + (operatorMatrixVectorFunctional ξ).toLinearMap.comp (operatorSystemAmplification S φ n) + +lemma operatorSystemMatrixFunctional_nonneg + (S : Submodule ℂ A) (φ : S →ₗ[ℂ] (H →L[ℂ] H)) {n : ℕ} (ξ : Fin n → H) + (hφ : ∀ X : operatorSystemMatrices S n, + 0 ≤ (X : CStarMatrix (Fin n) (Fin n) A) → + 0 ≤ operatorSystemAmplification S φ n X) + (X : operatorSystemMatrices S n) (hX : 0 ≤ (X : CStarMatrix (Fin n) (Fin n) A)) : + 0 ≤ operatorSystemMatrixFunctional S φ ξ X := + (operatorMatrixVectorFunctional ξ).map_nonneg (hφ X hX) + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorTransport.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorTransport.lean new file mode 100644 index 0000000000000000000000000000000000000000..8353e2942d992f444e422dd16ebe4819e88cc806 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorTransport.lean @@ -0,0 +1,90 @@ +import OAI.Analysis.BoundedHochschild.CentralPrimitives +import OAI.Analysis.BoundedHochschild.OperatorPrimitives + +namespace OAI + +/-! +# The classical input for algebras represented as full operator algebras + +Kadison--Ringrose, *Cohomology of operator algebras I* (1971), Theorem 4.4, +includes the type I vanishing result. Here its full-operator-algebra case is +proved using the explicit rank-one homotopy in `OperatorPrimitives`, and is +transported across an actual star algebra equivalence. No cohomological +vanishing hypothesis is assumed. +-/ + +noncomputable section + +namespace BoundedHochschild + +section Transport +variable {M N : Type*} [CStarAlgebra M] [CStarAlgebra N] + +/-- An algebra equivalence gives mutually inverse contractive expectation maps. -/ +def expectedEmbeddingOfStarAlgEquiv (φ : N ≃⋆ₐ[ℂ] M) : ExpectedEmbedding N M where + includeMap := φ.toAlgEquiv.toLinearMap.mkContinuous 1 (fun a => by + change ‖φ a‖ ≤ 1 * ‖a‖ + rw [one_mul, StarAlgEquiv.norm_map]) + expectMap := φ.symm.toAlgEquiv.toLinearMap.mkContinuous 1 (fun a => by + change ‖φ.symm a‖ ≤ 1 * ‖a‖ + rw [one_mul, StarAlgEquiv.norm_map]) + include_mul := fun a b => map_mul φ a b + include_one := map_one φ + include_star := fun a => map_star φ a + include_norm := StarAlgEquiv.norm_map φ + expect_norm := fun a => (StarAlgEquiv.norm_map φ.symm a).le + retract := φ.symm_apply_apply + left_module := fun a x => by + change φ.symm (φ a * x) = a * φ.symm x + rw [map_mul, φ.symm_apply_apply] + right_module := fun x a => by + change φ.symm (x * φ a) = φ.symm x * a + rw [map_mul, φ.symm_apply_apply] + +lemma expectedEmbeddingOfStarAlgEquiv_surjective (φ : N ≃⋆ₐ[ℂ] M) : + Function.Surjective (expectedEmbeddingOfStarAlgEquiv φ).includeMap := + φ.surjective + +namespace ExpectedEmbedding + +/-- For a surjective inclusion the finite exactness identity holds at every tuple. -/ +lemma extend_primitive_of_surjective (E : ExpectedEmbedding N M) + (hE : Function.Surjective E.includeMap) {n : ℕ} + (f : Cochain M (n + 1)) (g : Cochain N n) + (hg : ∀ x, differentialValue g x = E.restrict f x) : + ∀ x, differentialValue (E.extend g) x = f x := by + intro x + exact E.finite_exactness f g hg Set.univ (fun a _ => hE a) + (fun x _ => hE (f x)) x (fun _ => Set.mem_univ _) + +end ExpectedEmbedding + +/-- A norm-controlled primitive is preserved by a star algebra equivalence. -/ +theorem primitive_of_starAlgEquiv (φ : N ≃⋆ₐ[ℂ] M) {n : ℕ} + (f : Cochain M (n + 1)) + (hN : ∀ F : Cochain N (n + 1), (∀ x, differentialValue F x = 0) → + ∃ g : Cochain N n, ‖g‖ ≤ ‖F‖ ∧ ∀ x, differentialValue g x = F x) + (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := by + let E := expectedEmbeddingOfStarAlgEquiv φ + obtain ⟨g, hgn, hg⟩ := hN (E.restrict f) (E.restrict_cocycle f hf) + exact ⟨E.extend g, (E.extend_norm g).trans (hgn.trans (E.restrict_norm f)), + E.extend_primitive_of_surjective (expectedEmbeddingOfStarAlgEquiv_surjective φ) f g hg⟩ + +end Transport + +/-- The non-II₁ classical input is discharged for any actual presentation as `B(H)`. +The rank-one homotopy also provides the norm-one primitive bound. -/ +theorem primitive_of_full_operator_equiv + {M H : Type*} [CStarAlgebra M] + [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + (φ : (H →L[ℂ] H) ≃⋆ₐ[ℂ] M) {n : ℕ} + (f : Cochain M (n + 1)) (hf : ∀ x, differentialValue f x = 0) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x = f x := + primitive_of_starAlgEquiv φ f (fun F hF => primitive_on_operators F hF) hf + +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OperatorTypeI.lean b/lean/OAI/Analysis/BoundedHochschild/OperatorTypeI.lean new file mode 100644 index 0000000000000000000000000000000000000000..5c188861fd04b1d91b34a1022b28ba1644250672 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OperatorTypeI.lean @@ -0,0 +1,191 @@ +import OAI.Analysis.BoundedHochschild.TracialDecomposition + +namespace OAI + +/-! +# Type I structure of full operator algebras + +Every nonzero operator projection dominates a nonzero abelian rank-one +projection. This verifies the type-I condition used in the classical +vanishing input. In particular a full operator algebra has no type II₁ +central summand. No trace or cohomological vanishing is assumed. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildCorners +open scoped ComplexOrder + +universe u +variable {H : Type u} [NormedAddCommGroup H] [InnerProductSpace ℂ H] [CompleteSpace H] + +omit [CompleteSpace H] in +/-- A nonzero operator has a vector on which it is nonzero. -/ +lemma exists_apply_ne_zero {T : H →L[ℂ] H} (hT : T ≠ 0) : ∃ x : H, T x ≠ 0 := by + by_contra h + push Not at h + apply hT + ext x + exact h x + +/-- A nonzero projection fixes a unit vector. -/ +lemma projection_fixes_unit_vector {p : H →L[ℂ] H} (hp : IsStarProjection p) + (hp0 : p ≠ 0) : ∃ x : H, ‖x‖ = 1 ∧ p x = x := by + obtain ⟨y, hy⟩ := exists_apply_ne_zero hp0 + have hpy : p (p y) = p y := congrArg (fun T : H →L[ℂ] H => T y) hp.isIdempotentElem.eq + refine ⟨(‖p y‖⁻¹ : ℂ) • p y, norm_smul_inv_norm hy, ?_⟩ + rw [map_smul, hpy] + +/-- A rank-one orthogonal projection has an abelian corner. -/ +lemma rankOne_abelian (x : H) (hx : ‖x‖ = 1) : + ∃ hq : IsStarProjection (InnerProductSpace.rankOne ℂ x x), + PopaTypeII.AbelianProjection hq := by + let q := InnerProductSpace.rankOne ℂ x x + have hq : IsStarProjection q := by + constructor + · exact InnerProductSpace.isIdempotentElem_rankOne_self hx + · change star q = q + simp only [q, ContinuousLinearMap.star_eq_adjoint, InnerProductSpace.adjoint_rankOne] + refine ⟨hq, ?_⟩ + have hscalar (A : PopaCorner.algebra hq) : + (A : H →L[ℂ] H) = (inner ℂ x ((A : H →L[ℂ] H) x)) • q := by + ext y + have hleft := congrArg (fun T : H →L[ℂ] H => T y) A.property.1 + have hright := congrArg (fun T : H →L[ℂ] H => T y) A.property.2 + change q ((A : H →L[ℂ] H) y) = (A : H →L[ℂ] H) y at hleft + change (A : H →L[ℂ] H) (q y) = (A : H →L[ℂ] H) y at hright + calc + (A : H →L[ℂ] H) y = q ((A : H →L[ℂ] H) y) := hleft.symm + _ = q ((A : H →L[ℂ] H) (q y)) := by rw [hright] + _ = (inner ℂ x ((A : H →L[ℂ] H) x)) • q y := by + simp only [q, InnerProductSpace.rankOne_apply, map_smul, + smul_smul, mul_comm] + intro A B + apply Subtype.ext + change (A : H →L[ℂ] H) * (B : H →L[ℂ] H) = + (B : H →L[ℂ] H) * (A : H →L[ℂ] H) + rw [hscalar A, hscalar B, smul_mul_smul_comm, smul_mul_smul_comm, mul_comm] + +/-- Every nonzero operator projection contains a rank-one abelian projection. -/ +theorem operator_projection_has_abelian_subprojection {p : H →L[ℂ] H} + (hp : IsStarProjection p) (hp0 : p ≠ 0) : + ∃ q : H →L[ℂ] H, ∃ hq : IsStarProjection q, + q ≤ p ∧ q ≠ 0 ∧ PopaTypeII.AbelianProjection hq := by + obtain ⟨x, hx, hpx⟩ := projection_fixes_unit_vector hp hp0 + let q := InnerProductSpace.rankOne ℂ x x + obtain ⟨hq, hqa⟩ := rankOne_abelian x hx + have hqle : q ≤ p := by + apply (hq.le_iff_mul_eq_right hp).mpr + ext y + change p (q y) = q y + simp only [q, InnerProductSpace.rankOne_apply, map_smul, hpx] + have hqx : q x = x := by + norm_num [q, InnerProductSpace.rankOne_apply, inner_self_eq_norm_sq_to_K, hx] + have hq0 : q ≠ 0 := by + intro hzero + have hzero' : x = 0 := by simpa only [hzero, zero_apply] using hqx.symm + have h01 : (0 : ℝ) = 1 := by simpa only [hzero', norm_zero] using hx + exact zero_ne_one h01 + exact ⟨q, hq, hqle, hq0, hqa⟩ + +section Equivalence +variable {N : Type u} [CStarAlgebra N] [PartialOrder N] [StarOrderedRing N] + +lemma map_starProjection (φ : N ≃⋆ₐ[ℂ] (H →L[ℂ] H)) {p : N} + (hp : IsStarProjection p) : IsStarProjection (φ p) := by + constructor + · change φ p * φ p = φ p + rw [← map_mul, hp.isIdempotentElem.eq] + · change star (φ p) = φ p + rw [← map_star, hp.isSelfAdjoint.star_eq] + +lemma abelianProjection_of_map (φ : N ≃⋆ₐ[ℂ] (H →L[ℂ] H)) {p : N} + (hp : IsStarProjection p) (hpa : PopaTypeII.AbelianProjection (map_starProjection φ hp)) : + PopaTypeII.AbelianProjection hp := by + let push (a : PopaCorner.algebra hp) : PopaCorner.algebra (map_starProjection φ hp) := + ⟨φ (a : N), by + constructor + · change φ p * φ (a : N) = φ (a : N) + rw [← map_mul, a.property.1] + · change φ (a : N) * φ p = φ (a : N) + rw [← map_mul, a.property.2]⟩ + intro a b + apply Subtype.ext + apply φ.injective + change φ ((a : N) * (b : N)) = φ ((b : N) * (a : N)) + have hh := congrArg (fun c : PopaCorner.algebra (map_starProjection φ hp) => + (c : H →L[ℂ] H)) (hpa (push a) (push b)).eq + change φ (a : N) * φ (b : N) = φ (b : N) * φ (a : N) at hh + simpa only [map_mul] using hh + +/-- An actual full-operator-algebra presentation satisfies the type I condition. -/ +theorem typeICorner_one_of_operator_equiv (φ : N ≃⋆ₐ[ℂ] (H →L[ℂ] H)) : + PopaTypeII.TypeICorner (IsStarProjection.one N) := by + intro p hp _ hp0 + have hφp := map_starProjection φ hp + have hφp0 : φ p ≠ 0 := by + intro hzero + apply hp0 + apply φ.injective + change φ p = φ 0 + simpa only [map_zero] using hzero + obtain ⟨q, hq, hqp, hq0, hqa⟩ := operator_projection_has_abelian_subprojection hφp hφp0 + let r := φ.symm q + have hr : IsStarProjection r := by + constructor + · change φ.symm q * φ.symm q = φ.symm q + rw [← map_mul, hq.isIdempotentElem.eq] + · change star (φ.symm q) = φ.symm q + rw [← map_star, hq.isSelfAdjoint.star_eq] + have hrp : r ≤ p := by + apply (hr.le_iff_mul_eq_left hp).mpr + apply φ.injective + change φ (r * p) = φ r + rw [map_mul] + change φ (φ.symm q) * φ p = φ (φ.symm q) + rw [φ.apply_symm_apply] + exact (hq.le_iff_mul_eq_left hφp).mp hqp + have hr0 : r ≠ 0 := by + intro hr0 + apply hq0 + have h := congrArg φ hr0 + simpa only [r, φ.apply_symm_apply, map_zero] using h + refine ⟨r, hr, hrp, hr0, abelianProjection_of_map φ hr ?_⟩ + simpa only [r, φ.apply_symm_apply] using hqa + +end Equivalence + +/-- A central operator projection is either zero or the identity. -/ +theorem central_operator_projection_eq_one {z : H →L[ℂ] H} (hz : IsStarProjection z) + (hc : ∀ T : H →L[ℂ] H, z * T = T * z) (hz0 : z ≠ 0) : z = 1 := by + obtain ⟨x, hx, hzx⟩ := projection_fixes_unit_vector hz hz0 + obtain ⟨φ, _hφn, hφx⟩ := exists_dual_vector ℂ x (by rw [hx]; norm_num) + have hφ : φ x = 1 := by simpa [hx] using hφx + ext y + have h := congrArg (fun T : H →L[ℂ] H => T x) (hc (rankOneColumn φ y)) + change z ((rankOneColumn φ y) x) = (rankOneColumn φ y) (z x) at h + simpa only [rankOneColumn_apply, hzx, hφ, one_smul, one_apply_eq_self] using h + +/-- Full operator algebras have no type II₁ central summand. -/ +theorem operators_noTypeII1Summand : NoTypeII1Summand (H →L[ℂ] H) := by + intro z hz hc _hfinite hnoI + by_contra hz0 + have hz1 := central_operator_projection_eq_one hz hc hz0 + subst z + let N := Corner (1 : H →L[ℂ] H) hz + have hN1 : (1 : N) ≠ 0 := by + intro hzero + apply hz0 + exact congrArg (fun a : N => (a : H →L[ℂ] H)) hzero + exact hnoI 1 (IsStarProjection.one N) (fun _ => Commute.one_left _) hN1 + (typeICorner_one_of_operator_equiv unitCornerEquiv) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OrthogonalPartialIsoSums.lean b/lean/OAI/Analysis/BoundedHochschild/OrthogonalPartialIsoSums.lean new file mode 100644 index 0000000000000000000000000000000000000000..97fedd56660b6819c2fd7cec318bc4ab812e5f65 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OrthogonalPartialIsoSums.lean @@ -0,0 +1,141 @@ +import OAI.Analysis.BoundedHochschild.PartialIsometryChains +import OAI.Analysis.BoundedHochschild.OrthogonalProjectionSums + +namespace OAI + +/-! +# Countable orthogonal sums of partial isometries + +These sums supply the actual shift operators used in the properly infinite +case. Both initial and final projections are identified by their least-upper- +bound properties; no trace is used. +-/ + +noncomputable section + +namespace BoundedHochschild.KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable {I : Type*} + +omit [PartialOrder M] [StarOrderedRing M] in +lemma partialIso_finset_sum_data (v : I → PartialIso M) + (hi : ∀ i j, i ≠ j → (v i).initial * (v j).initial = 0) + (hf : ∀ i j, i ≠ j → (v i).final * (v j).final = 0) (s : Finset I) : + ∃ w : PartialIso M, (w : M) = ∑ i ∈ s, (v i : M) ∧ + w.initial = ∑ i ∈ s, (v i).initial ∧ w.final = ∑ i ∈ s, (v i).final := by + classical + induction s using Finset.induction_on with + | empty => exact ⟨0, by simp, by simp, by simp⟩ + | @insert i s his ih => + obtain ⟨w, hw, hwi, hwf⟩ := ih + have hI : (v i).initial * w.initial = 0 := by + rw [hwi, Finset.mul_sum] + exact Finset.sum_eq_zero (fun j hj => hi i j (fun h => his (h ▸ hj))) + have hF : (v i).final * w.final = 0 := by + rw [hwf, Finset.mul_sum] + exact Finset.sum_eq_zero (fun j hj => hf i j (fun h => his (h ▸ hj))) + refine ⟨(v i).orthogonalSum w hI hF, ?_, ?_, ?_⟩ + · change (v i : M) + (w : M) = _ + rw [hw, Finset.sum_insert his] + · rw [PartialIso.orthogonalSum_initial, hwi, Finset.sum_insert his] + · rw [PartialIso.orthogonalSum_final, hwf, Finset.sum_insert his] + +def partialIsoFinsetSum (v : I → PartialIso M) + (hi : ∀ i j, i ≠ j → (v i).initial * (v j).initial = 0) + (hf : ∀ i j, i ≠ j → (v i).final * (v j).final = 0) (s : Finset I) : PartialIso M := + (partialIso_finset_sum_data v hi hf s).choose + +omit [PartialOrder M] [StarOrderedRing M] in +lemma partialIsoFinsetSum_coe (v : I → PartialIso M) (hi hf) (s : Finset I) : + (partialIsoFinsetSum v hi hf s : M) = ∑ i ∈ s, (v i : M) := + (partialIso_finset_sum_data v hi hf s).choose_spec.1 + +omit [PartialOrder M] [StarOrderedRing M] in +lemma partialIsoFinsetSum_initial (v : I → PartialIso M) (hi hf) (s : Finset I) : + (partialIsoFinsetSum v hi hf s).initial = ∑ i ∈ s, (v i).initial := + (partialIso_finset_sum_data v hi hf s).choose_spec.2.1 + +omit [PartialOrder M] [StarOrderedRing M] in +lemma partialIsoFinsetSum_final (v : I → PartialIso M) (hi hf) (s : Finset I) : + (partialIsoFinsetSum v hi hf s).final = ∑ i ∈ s, (v i).final := + (partialIso_finset_sum_data v hi hf s).choose_spec.2.2 + +lemma partialIsoFinsetSum_mono (v : I → PartialIso M) (hi hf) + {s t : Finset I} (hst : s ⊆ t) : + partialIsoFinsetSum v hi hf s ≤ partialIsoFinsetSum v hi hf t := by + classical + constructor + · rw [partialIsoFinsetSum_initial, partialIsoFinsetSum_initial] + exact Finset.sum_le_sum_of_subset_of_nonneg hst (fun i _ _ => (v i).initial_proj.nonneg) + · rw [partialIsoFinsetSum_coe, partialIsoFinsetSum_initial, Finset.mul_sum, + partialIsoFinsetSum_coe] + apply Finset.sum_congr rfl + intro i his + rw [Finset.sum_mul] + calc + _ = (v i : M) * (v i).initial := Finset.sum_eq_single i (fun j _ hji => ?_) + (fun hit => (hit (hst his)).elim) + _ = (v i : M) := (v i).mul_initial + calc + (v j : M) * (v i).initial = ((v j : M) * (v j).initial) * (v i).initial := by + rw [(v j).mul_initial] + _ = 0 := by rw [mul_assoc, hi j i hji, mul_zero] + +variable {X : Type*} [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A countable family with mutually orthogonal initial and final projections +has a sum whose initial and final projections are the respective suprema. -/ +theorem exists_countable_partialIso_sum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (v : ℕ → PartialIso M) + (hi : ∀ i j, i ≠ j → (v i).initial * (v j).initial = 0) + (hf : ∀ i j, i ≠ j → (v i).final * (v j).final = 0) : + ∃ w : PartialIso M, (∀ i, (v i).initial ≤ w.initial) ∧ + (∀ i, (v i).final ≤ w.final) ∧ + (∀ p : M, IsStarProjection p → (∀ i, (v i).initial ≤ p) → w.initial ≤ p) ∧ + (∀ p : M, IsStarProjection p → (∀ i, (v i).final ≤ p) → w.final ≤ p) := by + classical + let V (n : ℕ) := partialIsoFinsetSum v hi hf (Finset.range n) + have hm : Monotone V := fun _ _ h => partialIsoFinsetSum_mono v hi hf (Finset.range_mono h) + have hc : IsChain (· ≤ ·) (Set.range V) := by + rintro _ ⟨i, rfl⟩ _ ⟨j, rfl⟩ _ + exact (le_total i j).imp (fun h => hm h) (fun h => hm h) + obtain ⟨w, hw, _, hwi, hwf⟩ := exists_partialIso_chain_supremum e (Set.range V) hc + ⟨V 0, Set.mem_range_self 0⟩ + have hsumI (p : M) (hp : IsStarProjection p) (h : ∀ i, (v i).initial ≤ p) (n : ℕ) : + (V n).initial ≤ p := by + apply ((V n).initial_proj.le_iff_mul_eq_right hp).mpr + rw [partialIsoFinsetSum_initial, Finset.mul_sum] + exact Finset.sum_congr rfl (fun i _ => ((v i).initial_proj.le_iff_mul_eq_right hp).mp (h i)) + have hsumF (p : M) (hp : IsStarProjection p) (h : ∀ i, (v i).final ≤ p) (n : ℕ) : + (V n).final ≤ p := by + apply ((V n).final_proj.le_iff_mul_eq_right hp).mpr + rw [partialIsoFinsetSum_final, Finset.mul_sum] + exact Finset.sum_congr rfl (fun i _ => ((v i).final_proj.le_iff_mul_eq_right hp).mp (h i)) + refine ⟨w, ?_, ?_, ?_, ?_⟩ + · intro i + apply le_trans _ (hw (V (i + 1)) (Set.mem_range_self _)).1 + rw [partialIsoFinsetSum_initial] + exact Finset.single_le_sum (fun j _ => (v j).initial_proj.nonneg) + (Finset.mem_range.mpr (Nat.lt_succ_self i)) + · intro i + apply le_trans _ (PartialIso.final_mono (hw (V (i + 1)) (Set.mem_range_self _))) + rw [partialIsoFinsetSum_final] + exact Finset.single_le_sum (fun j _ => (v j).final_proj.nonneg) + (Finset.mem_range.mpr (Nat.lt_succ_self i)) + · intro p hp h + apply hwi p hp + rintro _ ⟨n, rfl⟩ + exact hsumI p hp h n + · intro p hp h + apply hwf p hp + rintro _ ⟨n, rfl⟩ + exact hsumF p hp h n + +end BoundedHochschild.KadisonRingrose + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionSums.lean b/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionSums.lean new file mode 100644 index 0000000000000000000000000000000000000000..dfd017c0bafdd6a4ca66e3191d881c18253382be --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionSums.lean @@ -0,0 +1,105 @@ +import OAI.Analysis.BoundedHochschild.ProjectionSequenceLimits +import OAI.Analysis.BoundedHochschild.ProjectionJoinComparison + +namespace OAI + +/-! Arbitrary orthogonal projection sums and their weak-star convergence. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u v + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] +variable {I : Type v} + +omit [PartialOrder M] [StarOrderedRing M] in +lemma orthogonal_projection_finset_sum (p : I → M) + (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i * p j = 0) (s : Finset I) : + IsStarProjection (∑ i ∈ s, p i) := by + classical + induction s using Finset.induction_on with + | empty => simp + | @insert i s his ih => + rw [Finset.sum_insert his] + apply (hp i).add ih + rw [Finset.mul_sum] + apply Finset.sum_eq_zero + intro j hj + exact horth i j (fun hij => his (hij ▸ hj)) + +/-- The net of finite partial sums of any orthogonal family converges +weak-star to its projection supremum. -/ +theorem exists_orthogonal_projection_sum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (p : I → M) (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i * p j = 0) : + ∃ P : M, IsStarProjection P ∧ (∀ i, p i ≤ P) ∧ + (∀ r : M, IsStarProjection r → (∀ i, p i ≤ r) → P ≤ r) ∧ + PredualTendsto e (fun s : Finset I => ∑ i ∈ s, p i) atTop P := by + classical + let f (s : Finset I) : M := ∑ i ∈ s, p i + have hf (s : Finset I) : IsStarProjection (f s) := orthogonal_projection_finset_sum p hp horth s + have hfm : Monotone f := by + intro s t hst + exact Finset.sum_le_sum_of_subset_of_nonneg hst (fun i _ _ => (hp i).nonneg) + obtain ⟨P, _, hlub, ht⟩ := HochschildSakai.exists_monotone_predual_limit e f hfm + 1 zero_le_one (fun s => (hf s).norm_le _) + have hfixed (s : Finset I) : f s * P = f s := by + have hm := HochschildSakai.predual_tendsto_mul_left e (f s) ht + have heq : (fun t => f s * f t) =ᶠ[atTop] (fun _ => f s) := by + filter_upwards [eventually_ge_atTop s] with t hst + exact ((hf s).le_iff_mul_eq_left (hf t)).mp (hfm hst) + apply predual_tendsto_unique e hm + intro x + exact tendsto_const_nhds.congr' (heq.mono fun _ h => + congrArg (fun a : M => e.symm a x) h.symm) + have hP : IsStarProjection P := by + constructor + · have hm := HochschildSakai.predual_tendsto_mul_right e P ht + have heq : (fun s => f s * P) = f := funext hfixed + rw [heq] at hm + exact predual_tendsto_unique e hm ht + · have hm := HochschildSakai.predual_tendsto_star e ht + have heq : (fun s => star (f s)) = f := funext fun s => (hf s).isSelfAdjoint.star_eq + rw [heq] at hm + exact predual_tendsto_unique e hm ht + refine ⟨P, hP, ?_, ?_, ht⟩ + · intro i + have h := hlub.1 (Set.mem_range_self ({i} : Finset I)) + simpa only [f, Finset.sum_singleton] using h + · intro r hr hpr + apply hlub.2 + rintro _ ⟨s, rfl⟩ + apply ((hf s).le_iff_mul_eq_right hr).mpr + change r * (∑ i ∈ s, p i) = ∑ i ∈ s, p i + rw [Finset.mul_sum] + apply Finset.sum_congr rfl + intro i _ + exact ((hp i).le_iff_mul_eq_right hr).mp (hpr i) + +/-- Common right annihilators are retained by the full orthogonal sum. -/ +lemma orthogonal_projection_sum_annihilator (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (p : I → M) (a P : M) + (ht : PredualTendsto e (fun s : Finset I => ∑ i ∈ s, p i) atTop P) + (hpa : ∀ i, p i * a = 0) : P * a = 0 := by + classical + have hm := HochschildSakai.predual_tendsto_mul_right e a ht + have heq : (fun s : Finset I => (∑ i ∈ s, p i) * a) = fun _ => (0 : M) := by + funext s + rw [Finset.sum_mul] + simp only [hpa, Finset.sum_const_zero] + rw [heq] at hm + exact predual_tendsto_unique e hm (predual_tendsto_const e 0 atTop) + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionTails.lean b/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionTails.lean new file mode 100644 index 0000000000000000000000000000000000000000..e9fc5784a35aea783fbd1e1ed21b3d472218828c --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/OrthogonalProjectionTails.lean @@ -0,0 +1,63 @@ +import OAI.Analysis.BoundedHochschild.FiniteCountableComparison + +namespace OAI + +/-! Weak-star null tails of a sequence of orthogonal projections. -/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- The tails of an orthogonal projection sum are projections converging +weak-star to zero, and each tail dominates all of its summands. -/ +theorem exists_orthogonal_projection_tails (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (q : ℕ → M) (hq : ∀ n, IsStarProjection (q n)) + (horth : ∀ i j, i ≠ j → q i * q j = 0) : + ∃ T : ℕ → M, (∀ n, IsStarProjection (T n)) ∧ Antitone T ∧ + (∀ n i, n ≤ i → q i ≤ T n) ∧ PredualTendsto e T atTop 0 := by + let s (n : ℕ) : M := ∑ i ∈ Finset.range n, q i + have hs (n : ℕ) : IsStarProjection (s n) := orthogonal_projection_sum_range q hq horth n + have hsm : Monotone s := monotone_nat_of_le_succ fun n => by + dsimp [s] + rw [Finset.sum_range_succ] + exact le_add_of_nonneg_right (hq n).nonneg + obtain ⟨Q, hQ, hlub, ht⟩ := exists_increasing_projection_limit e s hs hsm + have hsQ (n : ℕ) : s n ≤ Q := hlub.1 ⟨n, rfl⟩ + have hqQ (i : ℕ) : q i ≤ Q := by + apply le_trans _ (hsQ (i + 1)) + dsimp [s] + rw [Finset.sum_range_succ] + exact le_add_of_nonneg_left (Finset.sum_nonneg fun j _ => (hq j).nonneg) + refine ⟨fun n => Q - s n, ?_, ?_, ?_, ?_⟩ + · intro n + exact ((hs n).le_iff_sub hQ).mp (hsQ n) + · intro i j hij + exact sub_le_sub_left (hsm hij) Q + · intro n i hni + have hTail : IsStarProjection (Q - s n) := ((hs n).le_iff_sub hQ).mp (hsQ n) + apply ((hq i).le_iff_mul_eq_right hTail).mpr + rw [sub_mul, ((hq i).le_iff_mul_eq_right hQ).mp (hqQ i)] + have hzero : s n * q i = 0 := by + dsimp [s] + rw [Finset.sum_mul] + apply Finset.sum_eq_zero + intro j hj + exact horth j i (Nat.ne_of_lt ((Finset.mem_range.mp hj).trans_le hni)) + rw [hzero, sub_zero] + · simpa only [sub_self] using + predual_tendsto_sub e (predual_tendsto_const e Q atTop) ht + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PartialIsoCornerEquivalence.lean b/lean/OAI/Analysis/BoundedHochschild/PartialIsoCornerEquivalence.lean new file mode 100644 index 0000000000000000000000000000000000000000..e1682cfa02f3152e72a3902f2cfbf461e6cb5595 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PartialIsoCornerEquivalence.lean @@ -0,0 +1,115 @@ +import OAI.Analysis.BoundedHochschild.CornerEquivalences + +namespace OAI + +/-! +# Equivalence of corners joined by a partial isometry + +Conjugation by a partial isometry identifies its initial and final corners as +actual star algebras. In particular abelianness passes between these corners +and to smaller projections. +-/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +/-- Conjugation identifies the initial and final corners of a partial isometry. -/ +def partialIsoCornerEquiv (v : PartialIso M) : + PopaCorner.algebra v.initial_proj ≃⋆ₐ[ℂ] PopaCorner.algebra v.final_proj where + toFun a := ⟨(v : M) * (a : M) * star (v : M), by + constructor + · rw [← mul_assoc, ← mul_assoc, v.final_mul] + · have hs : star (v : M) * v.final = star (v : M) := by + simpa only [star_mul, star_star, v.final_proj.isSelfAdjoint.star_eq] using + congrArg star v.final_mul + change ((v : M) * (a : M) * star (v : M)) * v.final = _ + rw [mul_assoc, hs]⟩ + invFun b := ⟨star (v : M) * (b : M) * (v : M), by + constructor + · have hs : v.initial * star (v : M) = star (v : M) := by + simpa only [star_mul, star_star, v.initial_proj.isSelfAdjoint.star_eq] using + congrArg star v.mul_initial + change v.initial * (star (v : M) * (b : M) * (v : M)) = _ + rw [← mul_assoc, ← mul_assoc, hs] + · rw [mul_assoc, v.mul_initial]⟩ + left_inv a := by + apply Subtype.ext + change star (v : M) * ((v : M) * (a : M) * star (v : M)) * (v : M) = (a : M) + calc + _ = v.initial * (a : M) * v.initial := by simp only [PartialIso.initial, mul_assoc] + _ = (a : M) := by rw [a.property.1, a.property.2] + right_inv b := by + apply Subtype.ext + change (v : M) * (star (v : M) * (b : M) * (v : M)) * star (v : M) = (b : M) + calc + _ = v.final * (b : M) * v.final := by simp only [PartialIso.final, mul_assoc] + _ = (b : M) := by rw [b.property.1, b.property.2] + map_add' a b := by + apply Subtype.ext + change (v : M) * ((a : M) + (b : M)) * star (v : M) = + (v : M) * (a : M) * star (v : M) + (v : M) * (b : M) * star (v : M) + simp only [mul_add, add_mul] + map_mul' a b := by + apply Subtype.ext + change (v : M) * ((a : M) * (b : M)) * star (v : M) = + ((v : M) * (a : M) * star (v : M)) * ((v : M) * (b : M) * star (v : M)) + symm + calc + _ = (v : M) * ((a : M) * v.initial * (b : M)) * star (v : M) := by + simp only [PartialIso.initial, mul_assoc] + _ = _ := by rw [a.property.2] + map_smul' c a := by + apply Subtype.ext + change (v : M) * (c • (a : M)) * star (v : M) = + c • ((v : M) * (a : M) * star (v : M)) + simp only [mul_smul_comm, smul_mul_assoc] + map_star' a := by + apply Subtype.ext + change (v : M) * star (a : M) * star (v : M) = + star ((v : M) * (a : M) * star (v : M)) + simp only [star_mul, star_star, mul_assoc] + +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma partialIsoCornerEquiv_apply (v : PartialIso M) + (a : PopaCorner.algebra v.initial_proj) : + (partialIsoCornerEquiv v a : M) = (v : M) * (a : M) * star (v : M) := rfl + +omit [PartialOrder M] [StarOrderedRing M] in +/-- Equivalent projections have simultaneously abelian corners. -/ +lemma abelianProjection_partialIso (v : PartialIso M) + (hab : PopaTypeII.AbelianProjection v.initial_proj) : + PopaTypeII.AbelianProjection v.final_proj := by + let E := partialIsoCornerEquiv v + intro a b + simpa only [E.apply_symm_apply] using (hab (E.symm a) (E.symm b)).map E + +/-- A subprojection of an abelian projection is abelian. -/ +lemma abelian_projection_mono {p q : M} (hp : IsStarProjection p) + (hq : IsStarProjection q) (hqp : q ≤ p) + (hab : PopaTypeII.AbelianProjection hp) : PopaTypeII.AbelianProjection hq := by + let lift (a : PopaCorner.algebra hq) : PopaCorner.algebra hp := ⟨(a : M), by + constructor + · calc + p * (a : M) = p * (q * (a : M)) := by rw [a.property.1] + _ = (a : M) := by rw [← mul_assoc, (hq.le_iff_mul_eq_right hp).mp hqp, + a.property.1] + · calc + (a : M) * p = ((a : M) * q) * p := by rw [a.property.2] + _ = (a : M) := by rw [mul_assoc, (hq.le_iff_mul_eq_left hp).mp hqp, + a.property.2]⟩ + intro a b + apply Subtype.ext + exact congrArg (fun c : PopaCorner.algebra hp => (c : M)) (hab (lift a) (lift b)).eq + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PartialIsoProducts.lean b/lean/OAI/Analysis/BoundedHochschild/PartialIsoProducts.lean new file mode 100644 index 0000000000000000000000000000000000000000..39f670813988c22dddced1afd4e07b147a4f14b5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PartialIsoProducts.lean @@ -0,0 +1,82 @@ +import OAI.Analysis.BoundedHochschild.FiniteProjectionExtension + +namespace OAI + +/-! Products of composable partial isometries and comparison of complements. -/ + +noncomputable section + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +universe u + +variable {M X : Type u} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +lemma partialIso_product_initial (v w : PartialIso M) (h : w.final ≤ v.initial) : + star ((v : M) * w) * ((v : M) * w) = w.initial := by + calc + _ = star (w : M) * (v.initial * (w : M)) := by + simp only [star_mul, PartialIso.initial, mul_assoc] + _ = w.initial := by rw [partialIso_left_support v.initial_proj w h]; rfl + +/-- Compose two partial isometries when the final support of the second lies +in the initial support of the first. -/ +def composePartialIso (v w : PartialIso M) (h : w.final ≤ v.initial) : PartialIso M := + ⟨(v : M) * w, by + rw [mul_assoc, partialIso_product_initial v w h, mul_assoc, w.mul_initial]⟩ + +@[simp] lemma composePartialIso_initial (v w : PartialIso M) (h : w.final ≤ v.initial) : + (composePartialIso v w h).initial = w.initial := partialIso_product_initial v w h + +lemma composePartialIso_final_le (v w : PartialIso M) (h : w.final ≤ v.initial) : + (composePartialIso v w h).final ≤ v.final := by + apply ((composePartialIso v w h).final_proj.le_iff_mul_eq_right v.final_proj).mpr + change v.final * (((v : M) * w) * star ((v : M) * w)) = _ + rw [← mul_assoc, ← mul_assoc, v.final_mul] + rfl + +/-- Finiteness reverses subequivalence on complementary projections. -/ +theorem finite_complement_subequivalence (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (hfinite : FiniteAlgebra M) {p q : M} (hp : IsStarProjection p) + (hq : IsStarProjection q) (v : PartialIso M) + (hi : v.initial = p) (hf : v.final ≤ q) : + ∃ w : PartialIso M, w.initial = 1 - q ∧ w.final ≤ 1 - p := by + obtain ⟨u, hu⟩ := finite_partialIso_extends_unitary e hfinite v + rw [hi] at hu + have huunit : star (u : M) * u = 1 ∧ (u : M) * star (u : M) = 1 := + Unitary.mem_iff.mp u.property + have hvq : q * (v : M) = v := partialIso_left_support hq v hf + have hzero : (1 - q) * (u : M) * p = 0 := by + rw [mul_assoc, hu, sub_mul, one_mul, hvq, sub_self] + have hzero' : p * star (u : M) * (1 - q) = 0 := by + simpa only [star_mul, star_sub, star_one, star_star, hp.isSelfAdjoint.star_eq, + hq.isSelfAdjoint.star_eq, star_zero, mul_assoc] using congrArg star hzero + let a := star (u : M) * (1 - q) + have hai : star a * a = 1 - q := by + dsimp [a] + rw [star_mul, star_sub, star_one, hq.isSelfAdjoint.star_eq, star_star] + calc + _ = (1 - q) * ((u : M) * star (u : M)) * (1 - q) := by simp only [mul_assoc] + _ = 1 - q := by rw [huunit.2, mul_one, hq.one_sub.isIdempotentElem.eq] + have hap : a * (1 - q) = a := by + dsimp [a] + rw [mul_assoc, hq.one_sub.isIdempotentElem.eq] + let w : PartialIso M := ⟨a, by rw [mul_assoc, hai, hap]⟩ + refine ⟨w, hai, ?_⟩ + have hpa : (1 - p) * a = a := by + change (1 - p) * (star (u : M) * (1 - q)) = _ + rw [sub_mul, one_mul, ← mul_assoc, hzero', sub_zero] + apply (w.final_proj.le_iff_mul_eq_right hp.one_sub).mpr + change (1 - p) * (a * star a) = a * star a + rw [← mul_assoc, hpa] + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PartialIsometries.lean b/lean/OAI/Analysis/BoundedHochschild/PartialIsometries.lean new file mode 100644 index 0000000000000000000000000000000000000000..e275ae058ba32836c43da9cd7b5637540bfbb375 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PartialIsometries.lean @@ -0,0 +1,502 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.DiffuseProjections +import OAI.Analysis.BoundedHochschild.OperatorPrimitives + +namespace OAI + +/-! Partial isometries and comparison of equal-trace projections. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open scoped ComplexOrder +namespace HochschildComparison +variable {M : Type*} [CStarAlgebra M] + +structure PartialIso (M : Type*) [CStarAlgebra M] where + val : M + mul_star_mul : val * star val * val = val + +namespace PartialIso +instance : Coe (PartialIso M) M := ⟨val⟩ +@[ext] lemma ext {v w : PartialIso M} (h : (v : M) = w) : v = w := by + cases v; cases w; congr + +def initial (v : PartialIso M) : M := star (v : M) * v +def final (v : PartialIso M) : M := (v : M) * star (v : M) +lemma mul_initial (v : PartialIso M) : (v : M) * v.initial = v := by + simpa only [initial, ← mul_assoc] using v.mul_star_mul +lemma final_mul (v : PartialIso M) : v.final * (v : M) = v := v.mul_star_mul +lemma initial_proj (v : PartialIso M) : IsStarProjection v.initial := by + refine ⟨?_, IsSelfAdjoint.star_mul_self _⟩ + change (star (v : M) * v) * (star (v : M) * v) = star (v : M) * v + calc + _ = star (v : M) * ((v : M) * star (v : M) * v) := by simp only [mul_assoc] + _ = _ := by rw [v.mul_star_mul] +lemma final_proj (v : PartialIso M) : IsStarProjection v.final := by + refine ⟨?_, IsSelfAdjoint.mul_star_self _⟩ + change ((v : M) * star (v : M)) * ((v : M) * star (v : M)) = (v : M) * star (v : M) + calc + _ = ((v : M) * star (v : M) * v) * star (v : M) := by simp only [mul_assoc] + _ = _ := by rw [v.mul_star_mul] +lemma norm_le_one (v : PartialIso M) : ‖(v : M)‖ ≤ 1 := by + have hi := v.initial_proj.norm_le _ + have he : ‖(v : M)‖ * ‖(v : M)‖ = ‖v.initial‖ := by + exact CStarRing.norm_star_mul_self.symm + nlinarith [norm_nonneg (v : M)] + +variable [PartialOrder M] + +instance : LE (PartialIso M) := ⟨fun v w => v.initial ≤ w.initial ∧ (w : M) * v.initial = v⟩ +lemma le_def {v w : PartialIso M} : v ≤ w ↔ + v.initial ≤ w.initial ∧ (w : M) * v.initial = v := Iff.rfl +variable [StarOrderedRing M] + +instance : PartialOrder (PartialIso M) where + le_refl v := ⟨le_rfl, v.mul_initial⟩ + le_trans v w z hvw hwz := by + refine ⟨hvw.1.trans hwz.1, ?_⟩ + calc + (z : M) * v.initial = (z : M) * (w.initial * v.initial) := by + rw [(v.initial_proj.le_iff_mul_eq_right w.initial_proj).mp hvw.1] + _ = (w : M) * v.initial := by rw [← mul_assoc,hwz.2] + _ = v := hvw.2 + le_antisymm v w hvw hwv := by + apply ext + have he := le_antisymm hvw.1 hwv.1 + have hh := hvw.2 + rw [he, w.mul_initial] at hh + exact hh.symm + +omit [StarOrderedRing M] in +lemma initial_mono {v w : PartialIso M} (h : v ≤ w) : v.initial ≤ w.initial := h.1 +omit [StarOrderedRing M] in +lemma mul_initial_of_le {v w : PartialIso M} (h : v ≤ w) : (w : M) * v.initial = v := h.2 +lemma star_mul_of_le {v w : PartialIso M} (h : v ≤ w) : star (v : M) * w = v.initial := by + have hv := congrArg star h.2 + simp only [star_mul, v.initial_proj.isSelfAdjoint.star_eq] at hv + calc + star (v : M) * w = (v.initial * star (w : M)) * w := by rw [hv] + _ = v.initial * w.initial := by simp only [initial,mul_assoc] + _ = v.initial := (v.initial_proj.le_iff_mul_eq_left w.initial_proj).mp h.1 +lemma star_mul_of_ge {v w : PartialIso M} (h : v ≤ w) : star (w : M) * v = v.initial := by + simpa only [star_mul,star_star,v.initial_proj.isSelfAdjoint.star_eq] + using congrArg star (star_mul_of_le h) +lemma final_mono {v w : PartialIso M} (h : v ≤ w) : v.final ≤ w.final := by + apply (v.final_proj.le_iff_mul_eq_right w.final_proj).mpr + calc + w.final * v.final = (w : M) * (star (w : M) * v) * star (v : M) := by + simp only [final,mul_assoc] + _ = (w : M) * v.initial * star (v : M) := by rw [star_mul_of_ge h] + _ = v.final := by rw [h.2]; rfl +lemma diff_square {v w : PartialIso M} (h : v ≤ w) : + star ((w : M) - v) * ((w : M) - v) = w.initial - v.initial := by + simp only [star_sub, sub_mul, mul_sub, star_mul_of_le h, star_mul_of_ge h, + ] + simp only [initial] + abel + +instance : Zero (PartialIso M) := ⟨⟨0, by simp⟩⟩ +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma coe_zero : ((0 : PartialIso M) : M) = 0 := rfl +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma initial_zero : (0 : PartialIso M).initial = 0 := by simp [initial] +omit [PartialOrder M] [StarOrderedRing M] in +@[simp] lemma final_zero : (0 : PartialIso M).final = 0 := by simp [final] +lemma zero_le (v : PartialIso M) : 0 ≤ v := by + exact ⟨by simpa using v.initial_proj.nonneg, by simp⟩ + +section +omit [PartialOrder M] [StarOrderedRing M] + +lemma star_mul_eq_zero_of_final_orthogonal {v w : PartialIso M} + (h : v.final*w.final=0) : star (v : M)*w=0 := by + have hv : star (v : M)*v.final=star (v : M) := by + simpa only [star_mul,star_star,v.final_proj.isSelfAdjoint.star_eq] + using congrArg star v.final_mul + calc + star (v : M)*w = (star (v : M)*v.final)*(w.final*(w : M)) := by + rw [hv,w.final_mul] + _ = star (v : M)*(v.final*w.final)*(w : M) := by simp only [mul_assoc] + _ = 0 := by rw [h,mul_zero,zero_mul] + +lemma mul_star_eq_zero_of_initial_orthogonal {v w : PartialIso M} + (h : v.initial*w.initial=0) : (v : M)*star (w : M)=0 := by + have hw : w.initial*star (w : M)=star (w : M) := by + simpa only [star_mul,star_star,w.initial_proj.isSelfAdjoint.star_eq] + using congrArg star w.mul_initial + calc + (v : M)*star (w : M) = ((v : M)*v.initial)*(w.initial*star (w : M)) := by + rw [v.mul_initial,hw] + _ = (v : M)*(v.initial*w.initial)*star (w : M) := by simp only [mul_assoc] + _ = 0 := by rw [h,mul_zero,zero_mul] + +lemma orthogonal_initial_symm {v w : PartialIso M} (h : v.initial*w.initial=0) : + w.initial*v.initial=0 := by + simpa only [star_mul,v.initial_proj.isSelfAdjoint.star_eq, + w.initial_proj.isSelfAdjoint.star_eq,star_zero] using congrArg star h +lemma orthogonal_final_symm {v w : PartialIso M} (h : v.final*w.final=0) : + w.final*v.final=0 := by + simpa only [star_mul,v.final_proj.isSelfAdjoint.star_eq, + w.final_proj.isSelfAdjoint.star_eq,star_zero] using congrArg star h + +def orthogonalSum (v w : PartialIso M) (hi : v.initial*w.initial=0) + (hf : v.final*w.final=0) : PartialIso M where + val := (v : M)+w + mul_star_mul := by + have hab := mul_star_eq_zero_of_initial_orthogonal hi + have hba := mul_star_eq_zero_of_initial_orthogonal (orthogonal_initial_symm hi) + have hab' := star_mul_eq_zero_of_final_orthogonal hf + have hba' := star_mul_eq_zero_of_final_orthogonal (orthogonal_final_symm hf) + simp only [star_add,mul_add,add_mul,hab,hba,zero_add,add_zero] + rw [v.mul_star_mul,w.mul_star_mul,mul_assoc,mul_assoc,hab',hba',mul_zero,mul_zero] + abel + +lemma orthogonalSum_initial (v w : PartialIso M) (hi : v.initial*w.initial=0) + (hf : v.final*w.final=0) : (orthogonalSum v w hi hf).initial=v.initial+w.initial := by + change star ((v : M)+w)*((v : M)+w)=_ + simp only [star_add,mul_add,add_mul,star_mul_eq_zero_of_final_orthogonal hf, + star_mul_eq_zero_of_final_orthogonal (orthogonal_final_symm hf),zero_add,add_zero,initial] +lemma orthogonalSum_final (v w : PartialIso M) (hi : v.initial*w.initial=0) + (hf : v.final*w.final=0) : (orthogonalSum v w hi hf).final=v.final+w.final := by + change ((v : M)+w)*star ((v : M)+w)=_ + simp only [star_add,mul_add,add_mul,mul_star_eq_zero_of_initial_orthogonal hi, + mul_star_eq_zero_of_initial_orthogonal (orthogonal_initial_symm hi),zero_add,add_zero,final] +end + +lemma le_orthogonalSum (v w : PartialIso M) (hi : v.initial*w.initial=0) + (hf : v.final*w.final=0) : v ≤ orthogonalSum v w hi hf := by + constructor + · rw [orthogonalSum_initial] + exact le_add_of_nonneg_right w.initial_proj.nonneg + · change ((v : M)+w)*v.initial=v + rw [add_mul,v.mul_initial] + have hh : (w : M)*v.initial=0 := by + calc + (w : M)*v.initial = ((w : M)*w.initial)*v.initial := by rw [w.mul_initial] + _ = 0 := by rw [mul_assoc,orthogonal_initial_symm hi,mul_zero] + rw [hh,add_zero] + +end PartialIso +end HochschildComparison + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildComparison +open BoundedHochschild HochschildRigidity HochschildDixmier +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + +namespace PartialIso +omit [StarOrderedRing M] in +lemma eq_of_le_of_initial_eq {v w : PartialIso M} (h : v ≤ w) + (hi : v.initial=w.initial) : v=w := by + apply ext + have hh := h.2 + rw [hi,w.mul_initial] at hh + exact hh.symm + +include hfaith in +lemma le_of_comparable_trace_le {v w : PartialIso M} (hc : v ≤ w ∨ w ≤ v) + (ht : (τ v.initial).re ≤ (τ w.initial).re) : v ≤ w := by + rcases hc with h|h + · exact h + · have hr := HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith + v.initial_proj w.initial_proj (Or.inr h.1) ht + have he := eq_of_le_of_initial_eq h (le_antisymm h.1 hr) + exact le_of_eq he.symm + +lemma diff_gns_sq {v w : PartialIso M} (h : v ≤ w) : + ‖τ.toPreGNS ((w : M)-v)‖^2 = (τ w.initial).re-(τ v.initial).re := by + have ht := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS ((w : M)-v))) + simpa only [PositiveLinearMap.ofPreGNS_toPreGNS, ← Complex.ofReal_pow, + Complex.ofReal_re,diff_square h,map_sub,Complex.sub_re] using ht + +lemma monotone_gns_cauchy (v : ℕ → PartialIso M) (hv : Monotone v) : + CauchySeq (fun n => τ.toPreGNS (v n : M)) := by + have hm : Monotone (fun n => (τ (v n).initial).re) := fun i j hij => + Complex.re_le_re (τ.monotone (hv hij).1) + have hb : BddAbove (Set.range (fun n => (τ (v n).initial).re)) := + ⟨(τ 1).re, fun _ ⟨n,hn⟩ => hn ▸ Complex.re_le_re (τ.monotone (v n).initial_proj.le_one)⟩ + have hc := (tendsto_atTop_ciSup hm hb).cauchySeq + apply Metric.cauchySeq_iff'.mpr + intro ε hε + obtain ⟨N,hN⟩ := Metric.cauchySeq_iff'.mp hc (ε^2) (sq_pos_of_pos hε) + refine ⟨N,fun n hn => ?_⟩ + have he := diff_gns_sq τ (hv hn) + have hdiff := hN n hn + rw [Real.dist_eq,abs_of_nonneg (sub_nonneg.mpr (hm hn))] at hdiff + rw [dist_eq_norm,← map_sub] + nlinarith [norm_nonneg (τ.toPreGNS ((v n : M)-v N))] + +include e hL hτ htr hfaith in +lemma exists_monotone_limit (v : ℕ → PartialIso M) (hv : Monotone v) : + ∃ w : PartialIso M, GNSTendsto τ (fun n => (v n : M)) atTop (w : M) ∧ + (∀ n, v n ≤ w) ∧ ∀ z : PartialIso M, (∀ n, v n ≤ z) → w ≤ z := by + obtain ⟨w,hw,ht⟩ := exists_bounded_preGNS_limit e τ hL hτ 1 + (fun n => (v n).norm_le_one) (monotone_gns_cauchy τ v hv) + change GNSTendsto τ (fun n => (v n : M)) atTop w at ht + have hstar := ht.star τ htr + have hin := hstar.mul τ htr ht 1 (fun n => by simpa only [norm_star] using (v n).norm_le_one) + have hfin := ht.mul τ htr hstar 1 (fun n => (v n).norm_le_one) + have hww : w*star w*w=w := by + apply GNSTendsto.unique τ hfaith (hfin.mul τ htr ht 1 (fun n => (v n).final_proj.norm_le _)) + simpa only [(v _).mul_star_mul] using ht + let s : PartialIso M := ⟨w,hww⟩ + change GNSTendsto τ (fun n => (v n).initial) atTop s.initial at hin + refine ⟨s,ht,?_,?_⟩ + · intro n + have him : (v n).initial ≤ s.initial := by + apply ((v n).initial_proj.le_iff_mul_eq_left s.initial_proj).mpr + apply GNSTendsto.unique τ hfaith + ((GNSTendsto.const τ (v n).initial atTop).mul τ htr hin 1 + (fun _ => (v n).initial_proj.norm_le _)) + change Tendsto (fun m => ‖τ.toPreGNS ((v n).initial*(v m).initial-(v n).initial)‖) atTop (𝓝 0) + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop n] with m hm + simp only [((v n).initial_proj.le_iff_mul_eq_left (v m).initial_proj).mp + (hv hm).1,sub_self,map_zero,norm_zero] + refine ⟨him,?_⟩ + apply GNSTendsto.unique τ hfaith (ht.mul τ htr (GNSTendsto.const τ (v n).initial atTop) + 1 (fun m => (v m).norm_le_one)) + change Tendsto (fun m => ‖τ.toPreGNS ((v m : M)*(v n).initial-(v n : M))‖) atTop (𝓝 0) + apply tendsto_const_nhds.congr' + filter_upwards [eventually_ge_atTop n] with m hm + simp only [(hv hm).2,sub_self,map_zero,norm_zero] + · intro z hz + have him : s.initial ≤ z.initial := by + apply (s.initial_proj.le_iff_mul_eq_left z.initial_proj).mpr + apply GNSTendsto.unique τ hfaith (hin.mul τ htr (GNSTendsto.const τ z.initial atTop) + 1 (fun m => (v m).initial_proj.norm_le _)) + simpa only [((v _).initial_proj.le_iff_mul_eq_left z.initial_proj).mp (hz _).1] + using hin + refine ⟨him,?_⟩ + apply GNSTendsto.unique τ hfaith + ((GNSTendsto.const τ (z : M) atTop).mul τ htr hin 1 (fun _ => z.norm_le_one)) + simpa only [(hz _).2] using ht + +include e hL hτ htr hfaith in +lemma chain_upper {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (c : Set (PartialIso M)) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) + (hs : ∀ v ∈ c, v.initial ≤ p ∧ v.final ≤ q) : + ∃ s : PartialIso M, s.initial ≤ p ∧ s.final ≤ q ∧ ∀ v ∈ c, v ≤ s := by + classical + let T : Set ℝ := (fun v : PartialIso M => (τ v.initial).re) '' c + have hTne : T.Nonempty := Set.Nonempty.image _ hne + have hTbd : BddAbove T := ⟨(τ p).re,by + rintro _ ⟨v,hv,rfl⟩ + exact Complex.re_le_re (τ.monotone (hs v hv).1)⟩ + obtain ⟨b,hbm,_hbub,hbt,hb⟩ := (isLUB_csSup hTne hTbd).exists_seq_monotone_tendsto hTne + choose a ha hab using hb + change ∀ n, (τ (a n).initial).re=b n at hab + have ham : Monotone a := by + intro m n hmn + apply le_of_comparable_trace_le τ hfaith (hc.total (ha m) (ha n)) + rw [hab,hab] + exact hbm hmn + obtain ⟨s,ht,has,hsleast⟩ := exists_monotone_limit e τ hL hτ htr hfaith a ham + have hi := (ht.star τ htr).mul τ htr ht 1 + (fun n => by simpa only [norm_star] using (a n).norm_le_one) + have hf := ht.mul τ htr (ht.star τ htr) 1 (fun n => (a n).norm_le_one) + change GNSTendsto τ (fun n => (a n).initial) atTop s.initial at hi + change GNSTendsto τ (fun n => (a n).final) atTop s.final at hf + have htrace : (τ s.initial).re=sSup T := by + have hz := trace_predual_tendsto e τ hτ + (predual_tendsto_of_preGNS e τ hL hτ hfaith 1 + (fun n => (a n).initial_proj.norm_le _) hi) + apply tendsto_nhds_unique (Complex.continuous_re.tendsto _ |>.comp hz) + simpa only [Function.comp_def,hab] using hbt + refine ⟨s,?_,?_,?_⟩ + · apply (s.initial_proj.le_iff_mul_eq_left hp).mpr + apply GNSTendsto.unique τ hfaith + (hi.mul τ htr (GNSTendsto.const τ p atTop) 1 (fun n => (a n).initial_proj.norm_le _)) + simpa only [((a _).initial_proj.le_iff_mul_eq_left hp).mp (hs _ (ha _)).1] using hi + · apply (s.final_proj.le_iff_mul_eq_left hq).mpr + apply GNSTendsto.unique τ hfaith + (hf.mul τ htr (GNSTendsto.const τ q atTop) 1 (fun n => (a n).final_proj.norm_le _)) + simpa only [((a _).final_proj.le_iff_mul_eq_left hq).mp (hs _ (ha _)).2] using hf + · intro z hz + by_cases hex : ∃ n, z ≤ a n + · obtain ⟨n,hn⟩ := hex + exact hn.trans (has n) + · have haz : ∀ n, a n ≤ z := fun n => + (hc.total (ha n) hz).resolve_right (fun h => hex ⟨n,h⟩) + apply le_of_comparable_trace_le τ hfaith (Or.inr (hsleast z haz)) + rw [htrace] + exact le_csSup hTbd ⟨z,hz,rfl⟩ +end PartialIso + +include e hL hτ htr hfaith in +lemma exists_nonzero_corner (h1 : τ 1=1) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (hp0 : p ≠ 0) (hq0 : q ≠ 0) : ∃ a : M, p*a*q ≠ 0 := by + classical + by_contra hex + push Not at hex + have hh := scalar_mem_orbit_closure e τ hL hτ h1 htr hfaith hfactor q + obtain ⟨b,hb,hbt⟩ := mem_closure_iff_seq_limit.mp hh + choose a ha hab using hb + have han : ∀ n, p*a n=0 := by + have hk : convexHull ℝ (Set.range (fun u : unitary M => conjugate u q)) ⊆ + {a : M | p*a=0} := by + apply convexHull_min + · rintro _ ⟨u,rfl⟩ + change p*((u : M)*q*star (u : M))=0 + rw [← mul_assoc,← mul_assoc,hex (u : M),zero_mul] + · intro x hx y hy r t _hr _ht _hrt + change p*x=0 at hx + change p*y=0 at hy + change p*(r • x+t • y)=0 + simp only [mul_add,mul_smul_comm,hx,hy,smul_zero,add_zero] + exact fun n => hk (ha n) + have ht : GNSTendsto τ a atTop ((τ q) • (1 : M)) := by + have hz := tendsto_iff_norm_sub_tendsto_zero.mp hbt + simpa only [GNSTendsto,← hab,← map_sub,gnsVector_norm] using hz + have hpq : p*((τ q) • (1 : M))=0 := by + apply GNSTendsto.unique τ hfaith + ((GNSTendsto.const τ p atTop).mul τ htr ht 1 (fun _ => hp.norm_le _)) + simpa only [han] using (GNSTendsto.const τ (0 : M) (atTop : Filter ℕ)) + have htq : τ q ≠ 0 := by + intro hzero + apply hq0 + apply hfaith q + simpa only [hq.isSelfAdjoint.star_eq,hq.isIdempotentElem.eq] using hzero + rw [mul_smul_comm,mul_one,smul_eq_zero] at hpq + exact hpq.elim htq hp0 + +include e in +lemma partialIso_of_nonzero_corner [CompleteSpace X] + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (b : M) (hb : b ≠ 0) (hpb : p*b=b) (hbq : b*q=b) : + ∃ v : PartialIso M, (v : M) ≠ 0 ∧ v.initial ≤ q ∧ v.final ≤ p := by + obtain ⟨v,r,s,hr,hvr,hvs,hs,hbabs,hvrv,_hsb⟩ := + HochschildPolar.exists_polar_partial_isometry e b + have hva : star v*b=CFC.abs b := by + calc + star v*b = star v*(v*CFC.abs b) := congrArg (star v * ·) hbabs + _ = CFC.abs b := by rw [← mul_assoc,hvr,hr.left] + have hvp : p*v=v := by + have hz : ((1-p)*v)*CFC.abs b=0 := by + rw [mul_assoc,← hbabs,sub_mul,one_mul,hpb,sub_self] + have hz' := HochschildPolar.support_right_annihilate hr + (IsSelfAdjoint.of_nonneg (CFC.abs_nonneg b)) hz + rw [mul_assoc,hvrv,sub_mul,one_mul,sub_eq_zero] at hz' + exact hz'.symm + have hrq : r*q=r := by + have ha : CFC.abs b*(1-q)=0 := by + rw [← hva,mul_assoc,mul_sub,mul_one,hbq,sub_self,mul_zero] + have hz := hr.annihilate (1-q) ha + simpa only [mul_sub,mul_one,sub_eq_zero,eq_comm] using hz + have hvpartial : v*star v*v=v := by rw [mul_assoc,hvr,hvrv] + let w : PartialIso M := ⟨v,hvpartial⟩ + refine ⟨w,?_,?_,?_⟩ + · intro hv0 + change v=0 at hv0 + apply hb + simpa only [hv0,zero_mul] using hbabs + · change star v*v ≤ q + rw [hvr] + exact (hr.proj.le_iff_mul_eq_left hq).mpr hrq + · apply (w.final_proj.le_iff_mul_eq_right hp).mpr + change p*(v*star v)=v*star v + rw [← mul_assoc,hvp] + +private lemma projection_orthogonal_of_le_sub {p r t : M} + (hp : IsStarProjection p) (hr : IsStarProjection r) (ht : IsStarProjection t) + (hrp : r ≤ p) (htr : t ≤ p-r) : r*t=0 := by + have hpr := (hr.le_iff_sub hp).mp hrp + have hh := (ht.le_iff_mul_eq_right hpr).mp htr + calc + r*t = r*((p-r)*t) := by rw [hh] + _ = (r*p-r*r)*t := by noncomm_ring + _ = 0 := by rw [(hr.le_iff_mul_eq_left hp).mp hrp,hr.isIdempotentElem.eq,sub_self,zero_mul] + +include e hτ htr hfaith in + + +theorem exists_partialIso_of_equal_trace [CompleteSpace X] (h1 : τ 1=1) + (hfactor : ∀ b : M, (∀ x : M, Commute b x) → ∃ c : ℂ, b=c • (1 : M)) + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) (ht : τ p=τ q) : + ∃ v : M, star v*v=p ∧ v*star v=q := by + classical + let L := HochschildSakai.mul_hasPreadjoint e + let S : Set (PartialIso M) := {v | v.initial ≤ p ∧ v.final ≤ q} + have hzero : (0 : PartialIso M) ∈ S := by + exact ⟨by simpa using hp.nonneg,by simpa using hq.nonneg⟩ + obtain ⟨v,_hzero,hmax⟩ := zorn_le_nonempty₀ S (fun c hc hchain y hy => by + obtain ⟨s,hsp,hsq,hsup⟩ := PartialIso.chain_upper e τ L hτ htr hfaith hp hq + c hchain ⟨y,hy⟩ (fun z hz => hc hz) + exact ⟨s,⟨hsp,hsq⟩,hsup⟩) 0 hzero + have hvp : v.initial ≤ p := hmax.1.1 + have hvq : v.final ≤ q := hmax.1.2 + have hfull : v.initial=p ∨ v.final=q := by + by_contra hnot + push Not at hnot + have hp' := (v.initial_proj.le_iff_sub hp).mp hvp + have hq' := (v.final_proj.le_iff_sub hq).mp hvq + obtain ⟨a,ha⟩ := exists_nonzero_corner e τ L hτ htr hfaith h1 hfactor + hq' hp' (sub_ne_zero.mpr hnot.2.symm) (sub_ne_zero.mpr hnot.1.symm) + obtain ⟨w,hw0,hwp,hwq⟩ := partialIso_of_nonzero_corner e hq' hp' + ((q-v.final)*a*(p-v.initial)) ha + (by rw [← mul_assoc,← mul_assoc,hq'.isIdempotentElem.eq]) + (by rw [mul_assoc,hp'.isIdempotentElem.eq]) + have hi := projection_orthogonal_of_le_sub hp v.initial_proj w.initial_proj hvp hwp + have hf := projection_orthogonal_of_le_sub hq v.final_proj w.final_proj hvq hwq + have hs : v.orthogonalSum w hi hf ∈ S := by + constructor + · rw [PartialIso.orthogonalSum_initial] + calc + v.initial+w.initial ≤ v.initial+(p-v.initial) := add_le_add_right hwp _ + _ = p := by abel + · rw [PartialIso.orthogonalSum_final] + calc + v.final+w.final ≤ v.final+(q-v.final) := add_le_add_right hwq _ + _ = q := by abel + have hle := v.le_orthogonalSum w hi hf + have he := le_antisymm (hmax.2 hs hle) hle + have hvw : (v : M)+w=v := congrArg (fun z : PartialIso M => (z : M)) he + exact hw0 (add_eq_left.mp hvw) + have he : τ v.initial=τ v.final := htr _ _ + rcases hfull with hi|hf + · have hback : q ≤ v.final := by + apply HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith hq v.final_proj + (Or.inr hvq) + rw [← he,hi,ht] + exact ⟨v,hi,le_antisymm hvq hback⟩ + · have hback : p ≤ v.initial := by + apply HochschildDiffuse.projection_le_of_comparable_trace_le τ hfaith hp v.initial_proj + (Or.inr hvp) + rw [he,hf,ht] + exact ⟨v,le_antisymm hvp hback,hf⟩ + +end HochschildComparison +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PartialIsometryChains.lean b/lean/OAI/Analysis/BoundedHochschild/PartialIsometryChains.lean new file mode 100644 index 0000000000000000000000000000000000000000..7bff8e3974ec568c3c5d4f056d40c4e9f3ea729f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PartialIsometryChains.lean @@ -0,0 +1,172 @@ +import OAI.Analysis.BoundedHochschild.ProjectionChainSuprema +import OAI.Analysis.BoundedHochschild.PartialIsometries + +namespace OAI + +/-! +# Suprema of chains of partial isometries + +The initial projections have a supremum. A weak-star cluster point of the +partial isometries agrees with each member on its initial projection. The +common-annihilator property of the supremum then identifies its initial +projection, without a trace or multiplication of two varying weak-star nets. +-/ + +noncomputable section + +open Filter Topology + +namespace BoundedHochschild +namespace KadisonRingrose + +open HochschildComparison + +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] [CompleteSpace X] + +/-- A nonempty chain of partial isometries has a least upper bound, whose +initial and final projections respect every projection bound on the chain. -/ +theorem exists_partialIso_chain_supremum (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + (c : Set (PartialIso M)) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) : + ∃ w : PartialIso M, (∀ v ∈ c, v ≤ w) ∧ + (∀ z : PartialIso M, (∀ v ∈ c, v ≤ z) → w ≤ z) ∧ + (∀ r : M, IsStarProjection r → (∀ v ∈ c, v.initial ≤ r) → w.initial ≤ r) ∧ + (∀ r : M, IsStarProjection r → (∀ v ∈ c, v.final ≤ r) → w.final ≤ r) := by + classical + let S : Set M := PartialIso.initial '' c + have hSne : S.Nonempty := hne.image _ + have hSchain : IsChain (· ≤ ·) S := by + rintro _ ⟨v, hv, rfl⟩ _ ⟨w, hw, rfl⟩ _ + exact (hc.total hv hw).imp PartialIso.initial_mono PartialIso.initial_mono + have hSproj : ∀ r ∈ S, IsStarProjection r := by + rintro _ ⟨v, _, rfl⟩ + exact v.initial_proj + obtain ⟨p, hp, hupper, hleast, hann, _⟩ := + exists_projection_chain_supremum_with_limit e S hSne hSchain hSproj + let : Nonempty c := hne.to_subtype + let : IsDirectedOrder c := ⟨fun a b => by + rcases hc.total a.property b.property with hab | hba + · exact ⟨b, hab, le_rfl⟩ + · exact ⟨a, le_rfl, hba⟩⟩ + let U : Ultrafilter c := Ultrafilter.of atTop + have hU : (U : Filter c) ≤ atTop := Ultrafilter.of_le atTop + obtain ⟨V, _, ht⟩ := exists_predual_ultralimit e U + (fun v : c => ((v : PartialIso M) : M)) 1 (fun v => v.val.norm_le_one) + have hVi (v : c) : V * v.val.initial = (v.val : M) := by + have hm := HochschildSakai.predual_tendsto_mul_right e v.val.initial ht + have heq : (fun w : c => (w.val : M) * v.val.initial) =ᶠ[U] + (fun _ => (v.val : M)) := by + apply hU + filter_upwards [eventually_ge_atTop v] with w hvw + exact hvw.2 + apply predual_tendsto_unique e hm + intro x + exact tendsto_const_nhds.congr' + (heq.mono fun _ h => congrArg (fun a : M => e.symm a x) h.symm) + have hstarVi (v : c) : star V * (v.val : M) = v.val.initial := by + have hm := HochschildSakai.predual_tendsto_mul_right e (v.val : M) + (HochschildSakai.predual_tendsto_star e ht) + have heq : (fun w : c => star (w.val : M) * (v.val : M)) =ᶠ[U] + (fun _ => v.val.initial) := by + apply hU + filter_upwards [eventually_ge_atTop v] with w hvw + exact PartialIso.star_mul_of_ge hvw + apply predual_tendsto_unique e hm + intro x + exact tendsto_const_nhds.congr' + (heq.mono fun _ h => congrArg (fun a : M => e.symm a x) h.symm) + have hVp : V * p = V := by + have hm := HochschildSakai.predual_tendsto_mul_right e p ht + have heq : (fun v : c => (v.val : M) * p) = + (fun v : c => (v.val : M)) := by + funext v + calc + (v.val : M) * p = ((v.val : M) * v.val.initial) * p := by + rw [v.val.mul_initial] + _ = (v.val : M) := by + rw [mul_assoc, (v.val.initial_proj.le_iff_mul_eq_left hp).mp + (hupper _ ⟨v.val, v.property, rfl⟩), v.val.mul_initial] + rw [heq] at hm + exact predual_tendsto_unique e hm ht + have hpstar : p * star V = star V := by + simpa only [star_mul, hp.isSelfAdjoint.star_eq] using congrArg star hVp + have hVV : star V * V = p := by + have hann' : p * (star V * V - p) = 0 := by + apply hann + rintro _ ⟨v, hv, rfl⟩ + have hfixed : v.initial * (star V * V) = v.initial := by + have hs : v.initial * star V = star (v : M) := by + simpa only [star_mul, v.initial_proj.isSelfAdjoint.star_eq] using + congrArg star (hVi ⟨v, hv⟩) + calc + v.initial * (star V * V) = star (v : M) * V := by rw [← mul_assoc, hs] + _ = v.initial := by + simpa only [star_mul, star_star, v.initial_proj.isSelfAdjoint.star_eq] + using congrArg star (hstarVi ⟨v, hv⟩) + rw [mul_sub, hfixed, (v.initial_proj.le_iff_mul_eq_left hp).mp + (hupper _ ⟨v, hv, rfl⟩), sub_self] + rw [mul_sub, ← mul_assoc, hpstar, hp.isIdempotentElem.eq] at hann' + exact sub_eq_zero.mp hann' + let w : PartialIso M := ⟨V, by rw [mul_assoc, hVV, hVp]⟩ + have hwi : w.initial = p := hVV + have hwupper : ∀ v ∈ c, v ≤ w := by + intro v hv + exact ⟨by rw [hwi]; exact hupper _ ⟨v, hv, rfl⟩, hVi ⟨v, hv⟩⟩ + refine ⟨w, hwupper, ?_, ?_, ?_⟩ + · intro z hz + have hpz : p ≤ z.initial := by + apply hleast z.initial z.initial_proj + rintro _ ⟨v, hv, rfl⟩ + exact (hz v hv).1 + have hzp : (z : M) * p = V := by + have ha : p * star ((z : M) - V) = 0 := by + apply hann + rintro _ ⟨v, hv, rfl⟩ + have heq : ((z : M) - V) * v.initial = 0 := by + rw [sub_mul, (hz v hv).2, hVi ⟨v, hv⟩, sub_self] + simpa only [star_mul, v.initial_proj.isSelfAdjoint.star_eq, star_zero] + using congrArg star heq + have ha' : ((z : M) - V) * p = 0 := by + simpa only [star_mul, star_star, hp.isSelfAdjoint.star_eq, star_zero] + using congrArg star ha + rwa [sub_mul, hVp, sub_eq_zero] at ha' + exact ⟨by rw [hwi]; exact hpz, by change (z : M) * w.initial = V; rw [hwi, hzp]⟩ + · intro r hr hb + rw [hwi] + apply hleast r hr + rintro _ ⟨v, hv, rfl⟩ + exact hb v hv + · intro r hr hb + have hrV : r * V = V := by + have hm := HochschildSakai.predual_tendsto_mul_left e r ht + have heq : (fun v : c => r * (v.val : M)) = + (fun v : c => (v.val : M)) := by + funext v + calc + r * (v.val : M) = r * (v.val.final * (v.val : M)) := by rw [v.val.final_mul] + _ = (v.val : M) := by + rw [← mul_assoc, (v.val.final_proj.le_iff_mul_eq_right hr).mp + (hb v.val v.property), v.val.final_mul] + rw [heq] at hm + exact predual_tendsto_unique e hm ht + apply (w.final_proj.le_iff_mul_eq_right hr).mpr + change r * (V * star V) = V * star V + rw [← mul_assoc, hrV] + +/-- Projection bounds are retained by an upper bound of a chain of partial +isometries, without a tracial state. -/ +theorem partialIso_chain_upper (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) + {p q : M} (hp : IsStarProjection p) (hq : IsStarProjection q) + (c : Set (PartialIso M)) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) + (hs : ∀ v ∈ c, v.initial ≤ p ∧ v.final ≤ q) : + ∃ w : PartialIso M, w.initial ≤ p ∧ w.final ≤ q ∧ ∀ v ∈ c, v ≤ w := by + obtain ⟨w, hupper, _, hi, hf⟩ := exists_partialIso_chain_supremum e c hc hne + exact ⟨w, hi p hp (fun v hv => (hs v hv).1), + hf q hq (fun v hv => (hs v hv).2), hupper⟩ + +end KadisonRingrose +end BoundedHochschild + +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PartialUnitaries.lean b/lean/OAI/Analysis/BoundedHochschild/PartialUnitaries.lean new file mode 100644 index 0000000000000000000000000000000000000000..cc1c12c6d7036eaa9c478b601098c97f7962454f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PartialUnitaries.lean @@ -0,0 +1,317 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.PartialIsometries + +namespace OAI + +/-! Partial unitaries, ordered limits and trace estimates. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +open scoped ComplexOrder BoundedContinuousFunction CStarAlgebra +open scoped ComplexOrder CStarAlgebra +open scoped BigOperators +open scoped InnerProductSpace +open scoped ComplexStarModule +open scoped InnerProductSpace ComplexOrder +open Filter Topology +open scoped ComplexOrder +namespace HochschildComparison +open BoundedHochschild +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + +abbrev PartialUnitary (M : Type*) [CStarAlgebra M] := + {v : PartialIso M // v.final = v.initial} +namespace PartialUnitary +instance : Coe (PartialUnitary M) M := ⟨fun v => v.val.val⟩ +instance : PartialOrder (PartialUnitary M) := inferInstanceAs (PartialOrder {v : PartialIso M // v.final=v.initial}) +section +omit [PartialOrder M] [StarOrderedRing M] + +@[ext] lemma ext {v w : PartialUnitary M} (h : (v : M)=w) : v=w := + Subtype.ext (PartialIso.ext h) +abbrev support (v : PartialUnitary M) : M := v.val.initial +lemma support_proj (v : PartialUnitary M) : IsStarProjection v.support := v.val.initial_proj +lemma norm_le_one (v : PartialUnitary M) : ‖(v : M)‖≤1 := v.val.norm_le_one +lemma star_mul_self_eq_support (v : PartialUnitary M) : star (v : M)*v=v.support := rfl +lemma mul_star_self_eq_support (v : PartialUnitary M) : (v : M)*star (v : M)=v.support := v.property +lemma mul_support (v : PartialUnitary M) : (v : M)*v.support=v := v.val.mul_initial +lemma support_mul (v : PartialUnitary M) : v.support*(v : M)=v := by + change v.val.initial*(v : M)=v + rw [← v.property]; exact v.val.final_mul +lemma star_support (v : PartialUnitary M) : star (v : M)*v.support=star (v : M) := by + simpa only [star_mul,star_star,v.support_proj.isSelfAdjoint.star_eq] using congrArg star v.support_mul +lemma support_star (v : PartialUnitary M) : v.support*star (v : M)=star (v : M) := by + simpa only [star_mul,star_star,v.support_proj.isSelfAdjoint.star_eq] using congrArg star v.mul_support +instance : Zero (PartialUnitary M) := ⟨⟨0,by simp [PartialIso.final,PartialIso.initial]⟩⟩ +@[simp] lemma coe_zero : ((0 : PartialUnitary M) : M)=0 := rfl +@[simp] lemma support_zero : (0 : PartialUnitary M).support=0 := by simp [support,PartialIso.initial] +end + +lemma zero_le (v : PartialUnitary M) : 0≤v := by + constructor + · change star (0 : M)*0≤v.support + simpa only [star_zero,zero_mul] using v.support_proj.nonneg + · simp [PartialIso.initial] +section +omit [PartialOrder M] [StarOrderedRing M] + +lemma orthogonal_symm {v w : PartialUnitary M} (h : v.support*w.support=0) : w.support*v.support=0 := + PartialIso.orthogonal_initial_symm h +lemma mul_eq_zero {v w : PartialUnitary M} (h : v.support*w.support=0) : (v : M)*w=0 := by + calc + _ = ((v : M)*v.support)*(w.support*(w : M)) := by rw [mul_support,support_mul] + _ = (v : M)*(v.support*w.support)*w := by simp only [mul_assoc] + _ = 0 := by rw [h,mul_zero,zero_mul] + +def orthogonalSum (v w : PartialUnitary M) (h : v.support*w.support=0) : PartialUnitary M := + ⟨PartialIso.orthogonalSum v.val w.val h (by simpa only [v.property,w.property] using h), by + rw [PartialIso.orthogonalSum_final,PartialIso.orthogonalSum_initial,v.property,w.property]⟩ +@[simp] lemma coe_orthogonalSum (v w : PartialUnitary M) (h : v.support*w.support=0) : + ((v.orthogonalSum w h : PartialUnitary M) : M)=(v : M)+w := rfl +lemma support_orthogonalSum (v w : PartialUnitary M) (h : v.support*w.support=0) : + (v.orthogonalSum w h).support=v.support+w.support := + PartialIso.orthogonalSum_initial v.val w.val h (by simpa only [v.property,w.property] using h) +end + +lemma le_orthogonalSum (v w : PartialUnitary M) (h : v.support*w.support=0) : v≤v.orthogonalSum w h := + PartialIso.le_orthogonalSum v.val w.val h (by simpa only [v.property,w.property] using h) + + + +section +omit [PartialOrder M] [StarOrderedRing M] + +def power (v : PartialUnitary M) (k : Bool × ℕ) : M := + (if k.1 then star (v : M) else (v : M))^(k.2+1) +lemma norm_power_le_one (v : PartialUnitary M) (k : Bool × ℕ) : ‖v.power k‖≤1 := by + apply (norm_pow_le' _ (Nat.succ_pos _)).trans + apply pow_le_one₀ (norm_nonneg _) + split <;> simpa only [norm_star] using v.norm_le_one +lemma support_power (v : PartialUnitary M) (k : Bool × ℕ) : v.support*v.power k=v.power k := by + have h : v.support*(if k.1 then star (v : M) else (v : M)) = + (if k.1 then star (v : M) else (v : M)) := by split <;> first | exact v.support_star | exact v.support_mul + dsimp only [power] + rw [pow_succ',← mul_assoc,h] +lemma power_support (v : PartialUnitary M) (k : Bool × ℕ) : v.power k*v.support=v.power k := by + have h : (if k.1 then star (v : M) else (v : M))*v.support = + (if k.1 then star (v : M) else (v : M)) := by split <;> first | exact v.star_support | exact v.mul_support + dsimp only [power] + rw [pow_succ,mul_assoc,h] + +lemma add_pow_succ_of_orthogonal {a b : M} (hab : a*b=0) (hba : b*a=0) (n : ℕ) : + (a+b)^(n+1)=a^(n+1)+b^(n+1) := by + induction n with + | zero => simp + | succ n ih => + rw [pow_succ,ih,add_mul,mul_add,mul_add,← pow_succ,← pow_succ] + have h₁ : a^(n+1)*b=0 := by rw [pow_succ,mul_assoc,hab,mul_zero] + have h₂ : b^(n+1)*a=0 := by rw [pow_succ,mul_assoc,hba,mul_zero] + rw [h₁,h₂,add_zero,zero_add] +lemma power_orthogonalSum (v w : PartialUnitary M) (h : v.support*w.support=0) (k : Bool × ℕ) : + (v.orthogonalSum w h).power k=v.power k+w.power k := by + have hab := mul_eq_zero h + have hba := mul_eq_zero (orthogonal_symm h) + dsimp only [power] + rw [coe_orthogonalSum] + split + · rw [star_add] + exact add_pow_succ_of_orthogonal (by simpa only [star_mul,star_zero] using congrArg star hba) + (by simpa only [star_mul,star_zero] using congrArg star hab) _ + · exact add_pow_succ_of_orthogonal hab hba _ +end + +variable (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) +include htr in +lemma power_tendsto {I : Type*} {l : Filter I} {v : I → PartialUnitary M} {w : PartialUnitary M} + (h : GNSTendsto τ (fun i => (v i : M)) l (w : M)) (k : Bool × ℕ) : + GNSTendsto τ (fun i => (v i).power k) l (w.power k) := by + have hbase : GNSTendsto τ (fun i => if k.1 then star (v i : M) else (v i : M)) l + (if k.1 then star (w : M) else (w : M)) := by split <;> first | exact h.star τ htr | exact h + have hn : ∀ i, ‖if k.1 then star (v i : M) else (v i : M)‖≤1 := by + intro i; split <;> simpa only [norm_star] using (v i).norm_le_one + have hp (n : ℕ) : GNSTendsto τ (fun i => (if k.1 then star (v i : M) else (v i : M))^n) l + ((if k.1 then star (w : M) else (w : M))^n) := by + induction n with + | zero => simpa only [pow_zero] using GNSTendsto.const τ (1 : M) l + | succ n ih => + simpa only [pow_succ'] using hbase.mul τ htr ih 1 hn + exact hp _ +end PartialUnitary +end HochschildComparison + + + + + +open Filter Topology +open scoped ComplexOrder +namespace HochschildComparison +open BoundedHochschild HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) +namespace PartialUnitary +include e hL hτ htr hfaith in +lemma exists_monotone_limit (v : ℕ → PartialUnitary M) (hv : Monotone v) : + ∃ w : PartialUnitary M, GNSTendsto τ (fun n => (v n : M)) atTop (w : M) ∧ + (∀ n, v n ≤ w) ∧ ∀ z : PartialUnitary M, (∀ n, v n ≤ z) → w ≤ z := by + obtain ⟨w,ht,hvw,hwleast⟩ := PartialIso.exists_monotone_limit e τ hL hτ htr hfaith + (fun n => (v n).val) hv + have hf := ht.mul τ htr (ht.star τ htr) 1 (fun n => (v n).norm_le_one) + have hi := (ht.star τ htr).mul τ htr ht 1 (fun n => by simpa only [norm_star] using (v n).norm_le_one) + have he : w.final=w.initial := by + apply GNSTendsto.unique τ hfaith hf + change GNSTendsto τ (fun n => (v n).val.final) atTop w.initial + simpa only [(v _).property,PartialIso.initial] using hi + exact ⟨⟨w,he⟩,ht,hvw,fun z hz => hwleast z.val hz⟩ + + + +include e hL hτ htr hfaith in +lemma chain_limit (c : Set (PartialUnitary M)) (hc : IsChain (· ≤ ·) c) (hne : c.Nonempty) : + ∃ a : ℕ → PartialUnitary M, (∀ n, a n ∈ c) ∧ Monotone a ∧ + ∃ s : PartialUnitary M, GNSTendsto τ (fun n => (a n : M)) atTop (s : M) ∧ + (∀ v ∈ c, v ≤ s) ∧ ∀ z : PartialUnitary M, (∀ v ∈ c, v ≤ z) → s ≤ z := by + classical + let T : Set ℝ := (fun v : PartialUnitary M => (τ v.support).re) '' c + have hTne : T.Nonempty := Set.Nonempty.image _ hne + have hTbd : BddAbove T := ⟨(τ 1).re,by + rintro _ ⟨v,hv,rfl⟩ + exact Complex.re_le_re (τ.monotone v.support_proj.le_one)⟩ + obtain ⟨b,hbm,_hbub,hbt,hb⟩ := (isLUB_csSup hTne hTbd).exists_seq_monotone_tendsto hTne + choose a ha hab using hb + change ∀ n, (τ (a n).support).re=b n at hab + have ham : Monotone a := by + intro m n hmn + apply PartialIso.le_of_comparable_trace_le τ hfaith (hc.total (ha m) (ha n)) + rw [hab,hab] + exact hbm hmn + obtain ⟨s,ht,has,hsleast⟩ := exists_monotone_limit e τ hL hτ htr hfaith a ham + have hi := (ht.star τ htr).mul τ htr ht 1 + (fun n => by simpa only [norm_star] using (a n).norm_le_one) + change GNSTendsto τ (fun n => (a n).support) atTop s.support at hi + have htrace : (τ s.support).re=sSup T := by + have hz := trace_predual_tendsto e τ hτ + (predual_tendsto_of_preGNS e τ hL hτ hfaith 1 + (fun n => (a n).support_proj.norm_le _) hi) + apply tendsto_nhds_unique (Complex.continuous_re.tendsto _ |>.comp hz) + simpa only [Function.comp_def,hab] using hbt + refine ⟨a,ha,ham,s,ht,?_,fun z hz => hsleast z (fun n => hz _ (ha n))⟩ + intro z hz + by_cases hex : ∃ n, z ≤ a n + · obtain ⟨n,hn⟩ := hex + exact hn.trans (has n) + · have haz : ∀ n, a n ≤ z := fun n => + (hc.total (ha n) hz).resolve_right (fun h => hex ⟨n,h⟩) + apply PartialIso.le_of_comparable_trace_le τ hfaith (Or.inr (hsleast z haz)) + rw [htrace] + exact le_csSup hTbd ⟨z,hz,rfl⟩ + +include e hL hτ htr hfaith in +lemma maximal_of_sequentially_closed (P : PartialUnitary M → Prop) (h0 : P 0) + (hclosed : ∀ (a : ℕ → PartialUnitary M) (s : PartialUnitary M), + Monotone a → (∀ n, P (a n)) → + GNSTendsto τ (fun n => (a n : M)) atTop (s : M) → P s) : + ∃ v : PartialUnitary M, Maximal P v := by + apply zorn_le₀ + intro c hc hchain + by_cases hne : c.Nonempty + · obtain ⟨a,ha,ham,s,ht,hs,_⟩ := chain_limit e τ hL hτ htr hfaith c hchain hne + exact ⟨s,hclosed a s ham (fun n => hc (ha n)) ht,hs⟩ + · exact ⟨0,h0,fun v hv => (hne ⟨v,hv⟩).elim⟩ +end PartialUnitary +end HochschildComparison + + + + + + + +open scoped ComplexOrder +namespace HochschildPatching +open BoundedHochschild HochschildRigidity +variable {M : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] +variable (τ : M →ₚ[ℂ] ℂ) (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + +include htr in +lemma norm_trace_mul_le_gns (a b : M) : + ‖τ (a*b)‖ ≤ ‖τ.toPreGNS a‖*‖τ.toPreGNS b‖ := by + have hi : inner ℂ (τ.toPreGNS (star a)) (τ.toPreGNS b)=τ (a*b) := by + simp only [PositiveLinearMap.preGNS_inner_def,PositiveLinearMap.ofPreGNS_toPreGNS,star_star] + rw [← hi] + simpa only [preGNS_norm_star τ htr] using norm_inner_le_norm (𝕜 := ℂ) (τ.toPreGNS (star a)) (τ.toPreGNS b) + +lemma projection_gns_sq {q : M} (hq : IsStarProjection q) : ‖τ.toPreGNS q‖^2=(τ q).re := by + have ht := congrArg Complex.re (τ.preGNS_norm_sq (τ.toPreGNS q)) + simpa only [← Complex.ofReal_pow,Complex.ofReal_re,PositiveLinearMap.ofPreGNS_toPreGNS, + hq.isSelfAdjoint.star_eq,hq.isIdempotentElem.eq] using ht + +include htr in +lemma small_compression_trace_bound {q : M} (hq : IsStarProjection q) + (A x z y B : M) (c : ℂ) (ε : ℝ) + (hA : ‖A‖ ≤ 1) (hx : ‖x‖ ≤ 1) (hy : ‖y‖ ≤ 1) (hB : ‖B‖ ≤ 1) + (hxq : x*q=x) (hqy : q*y=y) + (hsmall : ‖τ.toPreGNS (q*z*q-c • q)‖ ≤ ε*‖τ.toPreGNS q‖) : + ‖τ (A*x*z*y*B)‖ ≤ (ε+‖c‖)*(τ q).re := by + let D : M := q*z*q-c • q + let G : M := y*B*A*x + have hG : ‖G‖ ≤ 1 := by + dsimp [G] + simpa only [one_mul] using norm_mul_le_of_le (norm_mul_le_of_le (norm_mul_le_of_le hy hB) hA) hx + have hGq : G*q=G := by dsimp [G]; simp only [mul_assoc,hxq] + have hqG : q*G=G := by dsimp [G]; rw [← mul_assoc,← mul_assoc,← mul_assoc,hqy] + have hGgns : ‖τ.toPreGNS G‖ ≤ ‖τ.toPreGNS q‖ := by + calc + _ = ‖τ.toPreGNS (G*q)‖ := congrArg (fun t => ‖τ.toPreGNS t‖) hGq.symm + _ ≤ ‖G‖*‖τ.toPreGNS q‖ := preGNS_norm_mul_le τ G q + _ ≤ _ := by simpa only [one_mul] using mul_le_mul_of_nonneg_right hG (norm_nonneg _) + have hrotate : τ (A*x*z*y*B)=τ (z*G) := by + calc + _ = τ ((A*x)*(z*y*B)) := by congr 1; simp only [mul_assoc] + _ = τ ((z*y*B)*(A*x)) := htr _ _ + _ = _ := by congr 1; simp only [G,mul_assoc] + have hinsert : τ (q*z*q*G)=τ (z*G) := by + calc + _ = τ (q*(z*G)) := by congr 1; simp only [mul_assoc,hqG] + _ = τ ((z*G)*q) := htr _ _ + _ = _ := by rw [mul_assoc,hGq] + have htrace : τ (A*x*z*y*B)=τ (D*G)+c*τ (q*G) := by + calc + _ = τ (q*z*q*G) := hrotate.trans hinsert.symm + _ = τ (D*G+c • (q*G)) := by + congr 1 + simp only [D,sub_mul,smul_mul_assoc,sub_add_cancel] + _ = _ := by rw [map_add,map_smul,smul_eq_mul] + have hscalar : ‖τ (q*G)‖ ≤ (τ q).re := by + exact (HochschildTraceNorm.positive_weight_trace_bound τ htr q G hq.nonneg).trans + (by simpa only [mul_one] using mul_le_mul_of_nonneg_left hG (τ.map_nonneg hq.nonneg).1) + have herror : ‖τ (D*G)‖ ≤ ε*(τ q).re := by + apply (norm_trace_mul_le_gns τ htr D G).trans + calc + _ ≤ (ε*‖τ.toPreGNS q‖)*‖τ.toPreGNS q‖ := mul_le_mul hsmall hGgns (norm_nonneg _) (hsmall.trans' (norm_nonneg _)) + _ = _ := by rw [← projection_gns_sq τ hq]; ring + rw [htrace] + apply (norm_add_le _ _).trans + rw [norm_mul,add_mul] + exact add_le_add herror (mul_le_mul_of_nonneg_left hscalar (norm_nonneg c)) +end HochschildPatching +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PathStages.lean b/lean/OAI/Analysis/BoundedHochschild/PathStages.lean new file mode 100644 index 0000000000000000000000000000000000000000..82b19fe9f302519294fd44e01472a88282b49b2f --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PathStages.lean @@ -0,0 +1,477 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.FiniteConstraints +import OAI.Analysis.BoundedHochschild.WalkLabels + +namespace OAI + +/-! Finite path stages, labelled walks and distinguished fresh letters. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) +variable (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (Star.star a*a)=0 → a=0) + +include e hL hτ htr hfaith in + + +theorem exists_projection_tails (a : ℕ → M) (ha : ∀ n, IsStarProjection (a n)) + (hat : ∀ n, (τ (a n)).re ≤ (1/2:ℝ)^n) : + ∃ p : ℕ → M, (∀ n, IsStarProjection (p n)) ∧ Antitone p ∧ + (∀ n m, n ≤ m → a m ≤ p n) ∧ GNSTendsto τ p atTop 0 := by + have hsum (n k : ℕ) : (∑ i ∈ Finset.range k, (τ (a (n+i))).re) ≤ 2*(1/2:ℝ)^n := by + calc + _ ≤ ∑ i ∈ Finset.range k, (1/2:ℝ)^(n+i) := Finset.sum_le_sum (fun i _ => hat (n+i)) + _ = (1/2:ℝ)^n * ∑ i ∈ Finset.range k, (1/2:ℝ)^i := by simp only [pow_add,Finset.mul_sum] + _ ≤ (1/2:ℝ)^n * 2 := mul_le_mul_of_nonneg_left (sum_geometric_two_le k) (by positivity) + _ = _ := mul_comm _ _ + choose p hp hpa hpl hpt using fun n => + exists_projection_countable_join e τ hL hτ htr hfaith (fun i => a (n+i)) + (fun i => ha (n+i)) (2*(1/2:ℝ)^n) (hsum n) + have hdom (n m : ℕ) (hnm : n ≤ m) : a m ≤ p n := by + simpa only [Nat.add_sub_of_le hnm] using hpa n (m-n) + refine ⟨p,hp,?_,hdom,?_⟩ + · intro n m hnm + exact hpl m (p n) (hp n) (fun i => hdom n (m+i) (by omega)) + · have ht : Tendsto (fun n : ℕ => 2*(1/2:ℝ)^n) atTop (𝓝 0) := by + simpa only [mul_zero] using (tendsto_pow_atTop_nhds_zero_of_lt_one (by norm_num : (0:ℝ) ≤ 1/2) + (by norm_num : (1/2:ℝ)<1)).const_mul 2 + have hs : Tendsto (fun n => Real.sqrt (2*(1/2:ℝ)^n)) atTop (𝓝 0) := by + simpa only [Real.sqrt_zero,Function.comp_def] using (Real.continuous_sqrt.tendsto 0).comp ht + change Tendsto (fun n => ‖τ.toPreGNS (p n-0)‖) atTop (𝓝 0) + simp only [sub_zero] + apply squeeze_zero (fun _ => norm_nonneg _) (fun n => ?_) hs + exact (Real.le_sqrt (norm_nonneg _) (by positivity)).mpr + ((preGNS_sq_le_trace τ (p n) (hp n).nonneg (hp n).le_one).trans (hpt n)) + +end BoundedHochschild + + + +open scoped NNReal +namespace BoundedHochschild +variable {M I : Type*} [CStarAlgebra M] + +lemma mul_eq_zero_of_supports (x y p q : M) (hxp : x*p=x) (hqy : q*y=y) (hpq : p*q=0) : + x*y=0 := by + calc + x*y=(x*p)*(q*y) := by rw [hxp,hqy] + _=x*(p*q)*y := by simp only [mul_assoc] + _=0 := by rw [hpq,mul_zero,zero_mul] + +lemma orthogonal_blocks_norm_sum_le (t : I → M) + (hleft : ∀ i j, i ≠ j → star (t i)*t j=0) + (hright : ∀ i j, i ≠ j → t i*star (t j)=0) + (s : Finset I) (R : ℝ) (hR : 0 ≤ R) (ht : ∀ i ∈ s, ‖t i‖ ≤ R) : + ‖∑ i ∈ s, t i‖ ≤ R := by + classical + have hdiag : star (∑ i ∈ s, t i)*(∑ i ∈ s, t i) = ∑ i ∈ s, star (t i)*t i := by + simp only [star_sum,Finset.sum_mul,Finset.mul_sum] + apply Finset.sum_congr rfl + intro i hi + exact Finset.sum_eq_single i (fun j _hj hji => hleft j i hji) (fun h => (h hi).elim) + have horth : Pairwise (fun i j => (star (t i)*t i)*(star (t j)*t j)=0) := by + intro i j hij + calc + (star (t i)*t i)*(star (t j)*t j) = star (t i)*(t i*star (t j))*t j := by simp only [mul_assoc] + _ = 0 := by rw [hright i j hij,mul_zero,zero_mul] + have hs := IsSelfAdjoint.nnnorm_sum_eq_sup s (fun i _hi => IsSelfAdjoint.star_mul_self (t i)) horth + have hbound : ‖∑ i ∈ s, star (t i)*t i‖₊ ≤ (⟨R^2,sq_nonneg R⟩ : ℝ≥0) := by + rw [hs] + apply Finset.sup_le + intro i hi + change ‖star (t i)*t i‖ ≤ R^2 + rw [CStarRing.norm_star_mul_self] + nlinarith [ht i hi,norm_nonneg (t i)] + change ‖∑ i ∈ s, star (t i)*t i‖ ≤ R^2 at hbound + rw [← hdiag,CStarRing.norm_star_mul_self] at hbound + nlinarith [norm_nonneg (∑ i ∈ s, t i)] + +lemma supported_sum_norm_le (p t : I → M) (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i*p j=0) + (hpt : ∀ i, p i*t i=t i) (htp : ∀ i, t i*p i=t i) + (s : Finset I) (R : ℝ) (hR : 0 ≤ R) (ht : ∀ i ∈ s, ‖t i‖ ≤ R) : + ‖∑ i ∈ s, t i‖ ≤ R := by + apply orthogonal_blocks_norm_sum_le t _ _ s R hR ht + · intro i j hij + apply mul_eq_zero_of_supports _ _ (p i) (p j) _ (hpt j) (horth i j hij) + simpa only [star_mul,(hp i).isSelfAdjoint.star_eq] using congrArg Star.star (hpt i) + · intro i j hij + apply mul_eq_zero_of_supports _ _ (p i) (p j) (htp i) _ (horth i j hij) + simpa only [star_mul,(hp j).isSelfAdjoint.star_eq] using congrArg Star.star (htp j) + +lemma supported_smul_sum_norm_le (p t : I → M) (hp : ∀ i, IsStarProjection (p i)) + (horth : ∀ i j, i ≠ j → p i*p j=0) + (hpt : ∀ i, p i*t i=t i) (htp : ∀ i, t i*p i=t i) + (c : I → ℂ) (hc : ∀ i, ‖c i‖ ≤ 1) + (s : Finset I) (R : ℝ) (hR : 0 ≤ R) (ht : ∀ i ∈ s, ‖t i‖ ≤ R) : + ‖∑ i ∈ s, c i • t i‖ ≤ R := by + apply supported_sum_norm_le p (fun i => c i • t i) hp horth + (fun i => by rw [mul_smul_comm,hpt i]) (fun i => by rw [smul_mul_assoc,htp i]) s R hR + intro i hi + rw [norm_smul] + exact (mul_le_mul_of_nonneg_right (hc i) (norm_nonneg _)).trans (by simpa using ht i hi) + +end BoundedHochschild + + + +namespace BoundedHochschild +variable {H : Type*} [SeminormedAddCommGroup H] [InnerProductSpace ℂ H] + + + +lemma exists_signs_energy (n : ℕ) (v : Fin n → H) : + ∃ c : Fin n → ℂ, (∀ i, c i=1 ∨ c i= -1) ∧ + (∑ i : Fin n, ‖v i‖^2) ≤ ‖∑ i : Fin n, c i • v i‖^2 := by + induction n with + | zero => exact ⟨fun _ => 1,fun _ => Or.inl rfl,by simp⟩ + | succ n ih => + obtain ⟨c,hc,he⟩ := ih (fun i => v i.succ) + let w := ∑ i : Fin n, c i • v i.succ + have hpara := parallelogram_law_with_norm ℂ (v 0) w + by_cases hplus : ‖v 0‖^2+‖w‖^2 ≤ ‖v 0+w‖^2 + · refine ⟨Fin.cons 1 c,?_,?_⟩ + · intro i + refine Fin.cases (Or.inl (by simp)) (fun j => ?_) i + simpa only [Fin.cons_succ] using hc j + · rw [Fin.sum_univ_succ,Fin.sum_univ_succ] + simp only [Fin.cons_zero,Fin.cons_succ,one_smul] + exact (add_le_add le_rfl he).trans hplus + · have hminus : ‖v 0‖^2+‖w‖^2 ≤ ‖v 0-w‖^2 := by linarith + refine ⟨Fin.cons (-1) c,?_,?_⟩ + · intro i + refine Fin.cases (Or.inr (by simp)) (fun j => ?_) i + simpa only [Fin.cons_succ] using hc j + · rw [Fin.sum_univ_succ,Fin.sum_univ_succ] + simp only [Fin.cons_zero,Fin.cons_succ,neg_one_smul] + have hn : ‖-v 0+w‖=‖v 0-w‖ := by rw [neg_add_eq_sub,norm_sub_rev] + change ‖v 0‖^2+(∑ i : Fin n, ‖v i.succ‖^2) ≤ ‖-v 0+w‖^2 + rw [hn] + exact (add_le_add le_rfl he).trans hminus + +lemma sign_bounded_energy (n : ℕ) (v : Fin n → H) (C : ℝ) (_hC : 0 ≤ C) + (hbound : ∀ c : Fin n → ℂ, (∀ i, c i=1 ∨ c i= -1) → + ‖∑ i : Fin n, c i • v i‖ ≤ C) : + (∑ i : Fin n, ‖v i‖^2) ≤ C^2 := by + obtain ⟨c,hc,he⟩ := exists_signs_energy n v + exact he.trans (pow_le_pow_left₀ (norm_nonneg _) (hbound c hc) 2) + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma norm_compression_le (p x : M) (C R : ℝ) (hC : 0 ≤ C) + (hp : ‖p‖ ≤ C) (hx : ‖x‖ ≤ R) : ‖p*x*p‖ ≤ C*R*C := by + exact (norm_mul_le _ _).trans ((mul_le_mul_of_nonneg_right + ((norm_mul_le _ _).trans (mul_le_mul hp hx (norm_nonneg _) hC)) (norm_nonneg _)).trans + (mul_le_mul_of_nonneg_left hp (mul_nonneg hC ((norm_nonneg _).trans hx)))) + + + +theorem no_normal_small_support_sequence + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (B : M →L[ℂ] M) (hB : HasPreadjoint e B) + (p y : ℕ → M) (hp : ∀ n, IsStarProjection (p n)) + (hpm : Antitone p) (hpt : GNSTendsto τ p atTop 0) + (hpy : ∀ n, p n*y n=y n) (hyp : ∀ n, y n*p n=y n) + (R η : ℝ) (hR : 0 ≤ R) (hη : 0 < η) + (hy : ∀ n, ‖y n‖ ≤ R) (hyB : ∀ n, η ≤ ‖τ.toPreGNS (B (y n))‖) : False := by + let v (j h : ℕ) := (p j-p h)*y j*(p j-p h) + have hdn (j h : ℕ) : ‖p j-p h‖ ≤ 2 := by + exact (norm_sub_le _ _).trans (by linarith [(hp j).norm_le (p j),(hp h).norm_le (p h)]) + have hvn (j h : ℕ) : ‖v j h‖ ≤ 4*R := by + have hh := norm_compression_le (p j-p h) (y j) 2 R (by norm_num) (hdn j h) (hy j) + dsimp [v] + nlinarith + have hvt (j : ℕ) : GNSTendsto τ (v j) atTop (y j) := by + have hd : GNSTendsto τ (fun h => p j-p h) atTop (p j) := by + simpa only [sub_zero] using (GNSTendsto.const τ (p j) atTop).sub τ hpt + have hdy := hd.mul τ htr (GNSTendsto.const τ (y j) atTop) 2 (hdn j) + have hh := hdy.mul τ htr hd (2*R) (fun h => + (norm_mul_le _ _).trans (mul_le_mul (hdn j h) (hy j) (norm_nonneg _) (by norm_num))) + simpa only [v,hpy j,hyp j] using hh + have hnext (j : ℕ) : ∃ h : ℕ, j next k) + have hsuc (n : ℕ) : s (n+1)=next (s n) := rfl + have hs : StrictMono s := strictMono_nat_of_lt_succ (fun n => by rw [hsuc]; exact hn (s n)) + let q (n : ℕ) := p (s n)-p (s (n+1)) + let t (n : ℕ) := q n*y (s n)*q n + have hprod (i j : ℕ) (hij : i ≤ j) : p (s i)*p (s j)=p (s j) := + ((hp (s j)).le_iff_mul_eq_right (hp (s i))).mp (hpm (hs.monotone hij)) + have hq (n : ℕ) : IsStarProjection (q n) := + (hp (s (n+1))).sub_of_mul_eq_right (hp (s n)) (hprod n (n+1) (by omega)) + have hqorth_lt (i j : ℕ) (hij : i q i) (fun i : Fin N => t i) + (fun i => hq i) (fun i j hij => hqorth i j (fun h => hij (Fin.ext h))) + (fun i => hqt i) (fun i => htq i) c _ Finset.univ R hR (fun i _ => htn i) + intro i + rcases hc i with h|h <;> simp only [h,norm_one,norm_neg,le_refl] + have heq : (∑ i : Fin N, c i • w i) = τ.toPreGNS (B (∑ i : Fin N, c i • t i)) := by + simp only [map_sum,map_smul,w] + rw [heq] + exact (preGNS_norm_le τ h1 _).trans ((B.le_opNorm _).trans + (mul_le_mul_of_nonneg_left hnorm (norm_nonneg _))) + have hle : (N:ℝ)*(η/2)^2 ≤ ∑ i : Fin N, ‖w i‖^2 := by + have hh := Finset.sum_le_sum (s := (Finset.univ : Finset (Fin N))) + (fun i _ => pow_le_pow_left₀ (half_pos hη).le (htB i) 2) + simpa only [Finset.sum_const,Finset.card_univ,Fintype.card_fin,nsmul_eq_mul] using hh + exact hle.trans hsum + obtain ⟨N,hN⟩ := exists_nat_gt ((‖B‖*R)^2 / (η/2)^2) + have hh : (‖B‖*R)^2 < (N:ℝ)*(η/2)^2 := (div_lt_iff₀ (sq_pos_of_pos (half_pos hη))).mp hN + exact (not_lt_of_ge (henergy N)) hh + +end BoundedHochschild + + + +open Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildRigidity +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + + + +theorem normal_two_norm_modulus + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hτ : TraceInPredual e τ) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) (h1 : τ 1=1) + (B : M →L[ℂ] M) (hB : HasPreadjoint e B) (R ε : ℝ) (hε : 0 < ε) : + ∃ δ > 0, ∀ x : M, ‖x‖ ≤ R → ‖τ.toPreGNS x‖ < δ → ‖τ.toPreGNS (B x)‖ < ε := by + by_contra hh + push Not at hh + let α : ℝ := ε/(2*(‖B‖+1)) + have hα : 0 < α := div_pos hε (by positivity) + have hBα : ‖B‖*α ≤ ε/2 := by + have heq : α*(2*(‖B‖+1))=ε := div_mul_cancel₀ ε (by positivity) + nlinarith [norm_nonneg B] + have hxex (n : ℕ) : ∃ x : M, ‖x‖ ≤ R ∧ + ‖τ.toPreGNS x‖ < (α/2)*(1/2:ℝ)^n ∧ ε ≤ ‖τ.toPreGNS (B x)‖ := + hh ((α/2)*(1/2:ℝ)^n) (by positivity) + choose x hx hxs hxB using hxex + have hR : 0 ≤ R := (norm_nonneg _).trans (hx 0) + choose y a ha hay hya hyn hxy hat using fun n => + exists_small_two_sided_support e τ hL hτ htr hfaith (x n) α hα + have hat' (n : ℕ) : (τ (a n)).re ≤ (1/2:ℝ)^n := by + apply (hat n).trans + have hr : 0 < (1/2:ℝ)^n := by positivity + have hr1 : (1/2:ℝ)^n ≤ 1 := pow_le_one₀ (by norm_num) (by norm_num) + have hx2 : ‖τ.toPreGNS (x n)‖^2 ≤ ((α/2)*(1/2:ℝ)^n)^2 := + pow_le_pow_left₀ (norm_nonneg _) (hxs n).le 2 + have hrr : ((1/2:ℝ)^n)^2 ≤ (1/2:ℝ)^n := by nlinarith + have hh' : ‖τ.toPreGNS (x n)‖^2 ≤ α^2/4*(1/2:ℝ)^n := by + nlinarith [mul_nonneg (sq_nonneg α) (sub_nonneg.mpr hrr)] + rw [← mul_div_assoc,div_le_iff₀ (sq_pos_of_pos hα)] + nlinarith [mul_pos (sq_pos_of_pos hα) hr] + obtain ⟨p,hp,hpm,hpa,hpt⟩ := exists_projection_tails e τ hL hτ htr hfaith a ha hat' + have hpy (n : ℕ) : p n*y n=y n := by + calc + p n*y n = p n*(a n*y n) := by rw [hay n] + _ = y n := by rw [← mul_assoc,((ha n).le_iff_mul_eq_right (hp n)).mp (hpa n n le_rfl),hay n] + have hyp (n : ℕ) : y n*p n=y n := by + calc + y n*p n = (y n*a n)*p n := by rw [hya n] + _ = y n := by rw [mul_assoc,((ha n).le_iff_mul_eq_left (hp n)).mp (hpa n n le_rfl),hya n] + have hyB (n : ℕ) : ε/2 ≤ ‖τ.toPreGNS (B (y n))‖ := by + have hdiff : ‖τ.toPreGNS (B (x n-y n))‖ ≤ ε/2 := + (preGNS_norm_le τ h1 _).trans ((B.le_opNorm _).trans + ((mul_le_mul_of_nonneg_left (hxy n) (norm_nonneg _)).trans hBα)) + have hh' := norm_sub_le (τ.toPreGNS (B (x n))) (τ.toPreGNS (B (x n-y n))) + have heq : τ.toPreGNS (B (x n))-τ.toPreGNS (B (x n-y n))=τ.toPreGNS (B (y n)) := by + simp only [map_sub,sub_sub_cancel] + rw [heq] at hh' + have htri := norm_add_le (τ.toPreGNS (B (y n))) (τ.toPreGNS (B (x n-y n))) + have heq' : τ.toPreGNS (B (y n))+τ.toPreGNS (B (x n-y n))=τ.toPreGNS (B (x n)) := by + simp only [map_sub]; abel + rw [heq'] at htri + linarith [hxB n] + exact no_normal_small_support_sequence e τ hL hτ htr hfaith h1 B hB p y hp hpm hpt hpy hyp + R (ε/2) hR (half_pos hε) (fun n => (hyn n).trans (hx n)) hyB + +end BoundedHochschild + + + +open MeasureTheory Filter Topology +open scoped ComplexOrder +namespace BoundedHochschild +open HochschildWalk HochschildLiouville TracialUltrapower HochschildRare +variable {M X : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + [NormedAddCommGroup X] [NormedSpace ℂ X] +variable (e : StrongDual ℂ X ≃ₗᵢ⋆[ℂ] M) (τ : M →ₚ[ℂ] ℂ) + + + +theorem primitive_of_normal_finite_tests + (h1 : τ 1=1) (htr : ∀ x y : M, τ (x*y)=τ (y*x)) + (hfaith : ∀ a : M, τ (star a*a)=0 → a=0) + (hL : ∀ b : M, HasPreadjoint e (ContinuousLinearMap.mul ℂ M b)) + (hR : ∀ b : M, HasPreadjoint e ((ContinuousLinearMap.mul ℂ M).flip b)) + (hτ : TraceInPredual e τ) + (label : Label → unitary M) + (htests : StageTests (fun g => ‖τ (FreeGroup.lift label g : M)‖)) + (hdense : ∀ u : unitary M, ∃ j : ℕ → ℕ, + Tendsto (fun k => ‖τ.toPreGNS ((label (Sum.inl (j k)):M)-(u:M))‖) atTop (𝓝 0)) + {n : ℕ} (f : Cochain M (n+1)) + (hf : ∀ x : Fin (n+2) → M, differentialValue f x=0) + (hnormal : ∀ a : Fin n → M, HasPreadjoint e (f.curryRight a)) : + ∃ g : Cochain M n, ‖g‖ ≤ ‖f‖ ∧ ∀ x, differentialValue g x=f x := by + refine primitive_of_walk_and_last_modulus e τ h1 htr hfaith hL hR hτ + (FreeGroup.lift label) walkWeights walkEnum walkWeights_nonneg walkWeights_sum + ?_ time stages_time_atTop ?_ ?_ f hf ?_ + · rw [walkLaw_eq_atomic] + exact walkLaw_symmetric + · rw [walkLaw_eq_atomic] + exact finite_tests_freeMoments _ htests + · intro u + obtain ⟨j,hj⟩ := hdense u + refine ⟨fun k => FreeGroup.of (Sum.inl (j k)),?_,?_⟩ + · intro k + rw [walkLaw_eq_atomic] + exact (base_atom_pos (j k)).ne' + · simpa only [FreeGroup.lift_apply_of] using hj + · intro a R ε hε + exact normal_two_norm_modulus e τ hL hτ htr hfaith h1 (f.curryRight a) (hnormal a) R ε hε + +end BoundedHochschild + + + +open MeasureTheory Filter Topology +namespace HochschildRare +open HochschildWalk + + +abbrev StageAlphabet (k : ℕ) := Fin (baseCut k) ⊕ ((j : Fin (k+1)) × Fin (labels j.val)) + +def stageEmbedding (k : ℕ) : StageAlphabet k → Label + | .inl j => .inl j.val + | .inr a => .inr ⟨a.1.val,a.2⟩ + +lemma goodPath_label_in_range {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) (i : Fin r × Fin (time k)) : + (w i).1 ∈ Set.range (stageEmbedding k) := by + classical + have htail : ¬ ∃ i, (w i).1 ∈ tailSet k := fun h => hw (Or.inl h) + have hbase : ¬ ∃ i, (w i).1 ∈ baseTail (baseCut k) := fun h => hw (Or.inr (Or.inl h)) + rcases hwi : (w i).1 with j | ⟨s,j⟩ + · have hj : j < baseCut k := by + by_contra hh + exact hbase ⟨i,j,by omega,hwi⟩ + exact ⟨Sum.inl ⟨j,hj⟩,by simp [stageEmbedding]⟩ + · have hs : s < k+1 := by + by_contra hh + exact htail ⟨i,s,by omega,j,hwi⟩ + exact ⟨Sum.inr ⟨⟨s,hs⟩,j⟩,by simp [stageEmbedding]⟩ + + + +theorem goodPath_distinguished {k r : ℕ} (w : Fin r × Fin (time k) → Increment) + (hw : w ∉ stageBad k r) : + ∃ (s : Fin r → Fin (time k)) (a : Fin r → Fin (labels k)), + (∀ i, (w (i,s i)).1 = Sum.inr ⟨k,a i⟩) ∧ + (∀ i z, (w z).1 = Sum.inr ⟨k,a i⟩ → z=(i,s i)) ∧ Function.Injective a := by + classical + have hmiss : ¬ ∃ i, ∀ j, (w (i,j)).1 ∉ stageSet k := fun h => hw (Or.inr (Or.inr (Or.inr h))) + have hhit : ∀ i : Fin r, ∃ j : Fin (time k), ∃ a : Fin (labels k), + (w (i,j)).1=Sum.inr ⟨k,a⟩ := by + intro i + by_contra hh + push Not at hh + exact hmiss ⟨i,fun j ⟨a,ha⟩ => hh j a ha⟩ + choose s a ha using hhit + have huniq : ∀ i z, (w z).1=Sum.inr ⟨k,a i⟩ → z=(i,s i) := by + intro i z hz + by_contra hne + exact hw (Or.inr (Or.inr (Or.inl ⟨z,(i,s i),hne,a i,hz,ha i⟩))) + refine ⟨s,a,ha,huniq,?_⟩ + intro i j hij + have hh := huniq i (j,s j) (by rw [ha j,hij]) + exact (Prod.mk.inj hh).1.symm + +lemma goodPaths_finite (k r : ℕ) : + {w : Fin r × Fin (time k) → Increment | w ∉ stageBad k r}.Finite := by + classical + let E : StageAlphabet k × Bool → Increment := fun a => (stageEmbedding k a.1,a.2) + have hf : (Set.pi Set.univ (fun _ : Fin r × Fin (time k) => Set.range E)).Finite := + Set.Finite.pi (fun _ => Set.finite_range E) + apply hf.subset + intro w hw i _ + obtain ⟨a,ha⟩ := goodPath_label_in_range w hw i + exact ⟨(a,(w i).2),Prod.ext ha rfl⟩ + +lemma boundedWords_finite (r N : ℕ) : + {q : FreeGroup (Fin r) | q ≠ 1 ∧ q.toWord.length ≤ N}.Finite := by + classical + apply ((List.finite_length_le (Fin r × Bool) N).preimage FreeGroup.toWord_injective.injOn).subset + intro q hq + exact hq.2 + +end HochschildRare +end + +end OAI diff --git a/lean/OAI/Analysis/BoundedHochschild/PathWords.lean b/lean/OAI/Analysis/BoundedHochschild/PathWords.lean new file mode 100644 index 0000000000000000000000000000000000000000..767c75e5ca3133931cdbde06d15d078402f9bfe5 --- /dev/null +++ b/lean/OAI/Analysis/BoundedHochschild/PathWords.lean @@ -0,0 +1,374 @@ +import Mathlib +import OAI.Analysis.BoundedHochschild.FinitePaths +import OAI.Analysis.BoundedHochschild.FreeCoefficients + +namespace OAI + +/-! Formal path words, free-group retractions and simultaneous path moments. -/ + +noncomputable section + +open scoped ComplexOrder +open Filter Topology +open Filter Topology Metric +open Filter Topology MeasureTheory +open scoped RealInnerProductSpace ENNReal +open MeasureTheory ProbabilityTheory Filter Topology +open scoped ENNReal +open MeasureTheory ProbabilityTheory +open MeasureTheory Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +open MeasureTheory Filter Topology TopologicalSpace +open scoped ENNReal Function +open scoped NNReal +namespace HochschildPaths +variable {C D : Type*} {r n : ℕ} + +def signed {G : Type*} [Group G] (g : G) (b : Bool) : G := if b then g else g⁻¹ + +@[simp] lemma signed_signed {G : Type*} [Group G] (g : G) (b : Bool) : + signed (signed g b) b=g := by cases b <;> simp [signed] + +@[simp] lemma signed_one {G : Type*} [Group G] (b : Bool) : signed (1:G) b=1 := by + cases b <;> simp [signed] + +lemma map_signed {G H : Type*} [Group G] [Group H] (f : G →* H) (g : G) (b : Bool) : + f (signed g b)=signed (f g) b := by cases b <;> simp [signed] + +lemma prod_ofFn_single {G : Type*} [Monoid G] {n : ℕ} (f : Fin n → G) (j : Fin n) + (hf : ∀ i, i ≠ j → f i=1) : (List.ofFn f).prod=f j := by + induction n with + | zero => exact j.elim0 + | succ n ih => + rw [List.ofFn_succ,List.prod_cons] + induction j using Fin.cases with + | zero => + have h : (List.ofFn fun i : Fin n => f i.succ).prod=1 := by + apply List.prod_eq_one + intro a ha + obtain ⟨i,rfl⟩ := List.mem_ofFn.mp ha + exact hf i.succ (Fin.succ_ne_zero i) + rw [h,mul_one] + | succ j => + rw [hf 0 (Ne.symm (Fin.succ_ne_zero j)),one_mul] + apply ih + intro i hi + exact hf i.succ (fun h => hi (Fin.succ_injective _ h)) + +variable (w : Fin r × Fin n → (C ⊕ D) × Bool) + (s : Fin r → Fin n) (a : Fin r → D) + (hpos : ∀ i, (w (i,s i)).1=Sum.inr (a i)) + (huniq : ∀ i z, (w z).1=Sum.inr (a i) → z=(i,s i)) + +include hpos huniq in +lemma distinguished_injective : Function.Injective a := by + intro i j hij + have h := huniq i (j,s j) ((hpos j).trans (congrArg Sum.inr hij.symm)) + exact (congrArg Prod.fst h).symm + + + +def retractLetter (x : C ⊕ D) : FreeGroup (Fin r) := by + classical + exact if h : ∃ i, x=Sum.inr (a i) then + signed (FreeGroup.of h.choose) (w (h.choose,s h.choose)).2 + else 1 + +include hpos huniq in +lemma retractLetter_distinguished (i : Fin r) : + retractLetter w s a (Sum.inr (a i))=signed (FreeGroup.of i) (w (i,s i)).2 := by + classical + unfold retractLetter + split_ifs with h + · have hi : h.choose=i := distinguished_injective w s a hpos huniq + (Sum.inr.inj h.choose_spec).symm + simp only [hi] + · exact False.elim (h ⟨i,rfl⟩) + +include huniq in +lemma retractLetter_away (i : Fin r) (j : Fin n) (hj : j ≠ s i) : + retractLetter w s a (w (i,j)).1=1 := by + classical + unfold retractLetter + split_ifs with h + · have hz := huniq h.choose (i,j) h.choose_spec + have hi : i=h.choose := congrArg Prod.fst hz + have hs : j=s i := (congrArg Prod.snd hz).trans (congrArg s hi.symm) + exact False.elim (hj hs) + · rfl + +def formalPath (i : Fin r) : FreeGroup (C ⊕ D) := + (List.ofFn fun j => signed (FreeGroup.of (w (i,j)).1) (w (i,j)).2).prod + +def pathHom : FreeGroup (Fin r) →* FreeGroup (C ⊕ D) := + FreeGroup.lift (formalPath w) + +def retractHom : FreeGroup (C ⊕ D) →* FreeGroup (Fin r) := + FreeGroup.lift (retractLetter w s a) + +include hpos huniq in +lemma retract_formalPath (i : Fin r) : + retractHom w s a (formalPath w i)=FreeGroup.of i := by + classical + simp only [formalPath,map_list_prod,List.map_ofFn,retractHom] + rw [prod_ofFn_single _ (s i)] + · simp only [Function.comp_apply,map_signed,FreeGroup.lift_apply_of] + rw [hpos,retractLetter_distinguished w s a hpos huniq,signed_signed] + · intro j hj + simp only [Function.comp_apply,map_signed,FreeGroup.lift_apply_of] + rw [retractLetter_away w s a huniq i j hj,signed_one] + +include hpos huniq in + + +theorem retract_pathHom (q : FreeGroup (Fin r)) : + retractHom w s a (pathHom w q)=q := by + have h : (retractHom w s a).comp (pathHom w)=MonoidHom.id _ := by + apply FreeGroup.ext_hom + intro i + simp only [MonoidHom.comp_apply,pathHom,FreeGroup.lift_apply_of,MonoidHom.id_apply] + exact retract_formalPath w s a hpos huniq i + exact congrArg (fun f : FreeGroup (Fin r) →* FreeGroup (Fin r) => f q) h + +include hpos huniq in +theorem pathHom_injective : Function.Injective (pathHom w) := by + intro q t h + have hh := congrArg (retractHom w s a) h + simpa only [retract_pathHom w s a hpos huniq] using hh + +include hpos huniq in +theorem pathHom_ne_one (q : FreeGroup (Fin r)) (hq : q ≠ 1) : pathHom w q ≠ 1 := by + intro h + apply hq + apply pathHom_injective w s a hpos huniq + simpa using h + + +def freshProjection : FreeGroup (C ⊕ D) →* FreeGroup D := + FreeGroup.lift (Sum.elim (fun _ : C => 1) FreeGroup.of) + +lemma retract_factors : + (FreeGroup.lift (fun d : D => retractLetter w s a (Sum.inr d))).comp + (freshProjection (C := C) (D := D)) = retractHom w s a := by + classical + apply FreeGroup.ext_hom + intro z + cases z with + | inl c => + simp [freshProjection,retractHom,retractLetter] + | inr d => + simp only [MonoidHom.comp_apply,freshProjection,FreeGroup.lift_apply_of, + Sum.elim_inr,retractHom] + +include hpos huniq in + + +theorem freshProjection_pathHom_ne_one (q : FreeGroup (Fin r)) (hq : q ≠ 1) : + freshProjection (pathHom w q) ≠ 1 := by + intro h + have hh := congrArg (FreeGroup.lift (fun d : D => retractLetter w s a (Sum.inr d))) h + change ((FreeGroup.lift (fun d : D => retractLetter w s a (Sum.inr d))).comp + freshProjection) (pathHom w q)=_ at hh + rw [retract_factors,retract_pathHom w s a hpos huniq,map_one] at hh + exact hq hh + +end HochschildPaths + + + + +namespace HochschildPaths +variable {M C D : Type*} [Ring M] [Algebra ℂ M] + (B : Subalgebra ℂ M) (v : C → Bˣ) (u : D → Mˣ) + +def unitaryEvaluation : FreeGroup (C ⊕ D) →* Mˣ := + FreeGroup.lift (Sum.elim (fun c => Units.map B.val.toMonoidHom (v c)) u) + +def freshEvaluation : FreeGroup D →* M := + (Units.coeHom M).comp (FreeGroup.lift u) + +def encodeLetter : (C ⊕ D) × Bool → HochschildFreeMoments.Letter B (G := FreeGroup D) + | (.inl c,b) => .inl (signed (v c) b : Bˣ) + | (.inr d,b) => .inr (signed (FreeGroup.of d) b) + +lemma value_encode (x : (C ⊕ D) × Bool) : + HochschildFreeMoments.value B (freshEvaluation u) (encodeLetter B v x)= + ((signed ((Sum.elim (fun c => Units.map B.val.toMonoidHom (v c)) u) x.1) x.2 : Mˣ) : M) := by + rcases x with ⟨c|d,b⟩ <;> cases b <;> + simp [encodeLetter,HochschildFreeMoments.value,freshEvaluation,signed] + +lemma degree_encode (x : (C ⊕ D) × Bool) : + HochschildFreeMoments.degreeLetter B (encodeLetter B v x)= + signed ((Sum.elim (fun _ : C => 1) FreeGroup.of) x.1) x.2 := by + rcases x with ⟨c|d,b⟩ <;> cases b <;> + simp [encodeLetter,HochschildFreeMoments.degreeLetter,signed] + +lemma evaluate_encode (l : List ((C ⊕ D) × Bool)) : + HochschildFreeMoments.evaluate B (freshEvaluation u) (l.map (encodeLetter B v))= + ((unitaryEvaluation B v u (FreeGroup.mk l) : Mˣ) : M) := by + simp only [HochschildFreeMoments.evaluate,List.map_map,unitaryEvaluation,FreeGroup.lift_mk] + change _ = (Units.coeHom M) ((l.map _).prod) + rw [map_list_prod,List.map_map] + congr 2 + funext x + rw [Function.comp_apply,value_encode] + rcases x with ⟨z,b⟩ + cases b <;> rfl + +lemma degree_encode_list (l : List ((C ⊕ D) × Bool)) : + HochschildFreeMoments.degree B (l.map (encodeLetter B v))= + freshProjection (FreeGroup.mk l) := by + simp only [HochschildFreeMoments.degree,List.map_map,freshProjection,FreeGroup.lift_mk] + congr 2 + funext x + rw [Function.comp_apply,degree_encode] + rcases x with ⟨z,b⟩ + cases b <;> rfl + + + +theorem moment_eq_zero_of_fresh_ne_one (τ : M →ₗ[ℂ] ℂ) + (h1 : τ 1=1) (hu : ∀ g : FreeGroup D, g ≠ 1 → τ (freshEvaluation u g)=0) + (hfree : HochschildFreeMoments.FreeCoefficients B (freshEvaluation u) τ) + (g : FreeGroup (C ⊕ D)) (hg : freshProjection g ≠ 1) : + τ (unitaryEvaluation B v u g : M)=0 := by + induction g using Quot.inductionOn with + | h l => + have h := HochschildFreeMoments.moment_eq_zero_of_degree_ne_one B + (freshEvaluation u) τ h1 hu hfree (l.map (encodeLetter B v)) + (by rwa [degree_encode_list]) + rwa [evaluate_encode] at h + + + +theorem distinguished_paths_moment (τ : M →ₗ[ℂ] ℂ) + (h1 : τ 1=1) (hu : ∀ g : FreeGroup D, g ≠ 1 → τ (freshEvaluation u g)=0) + (hfree : HochschildFreeMoments.FreeCoefficients B (freshEvaluation u) τ) + {r n : ℕ} (w : Fin r × Fin n → (C ⊕ D) × Bool) + (s : Fin r → Fin n) (a : Fin r → D) + (hpos : ∀ i, (w (i,s i)).1=Sum.inr (a i)) + (huniq : ∀ i z, (w z).1=Sum.inr (a i) → z=(i,s i)) + (q : FreeGroup (Fin r)) (hq : q ≠ 1) : + τ (unitaryEvaluation B v u (pathHom w q) : M)=0 := + moment_eq_zero_of_fresh_ne_one B v u τ h1 hu hfree _ + (freshProjection_pathHom_ne_one w s a hpos huniq q hq) + +end HochschildPaths + + + +open Filter Topology +open scoped ComplexOrder BoundedContinuousFunction +namespace HochschildPaths +open HochschildUltrapower HochschildRare +variable {M C D : Type*} [CStarAlgebra M] [PartialOrder M] [StarOrderedRing M] + (τ : M →ₚ[ℂ] ℂ) (h1 : τ 1=1) (ω : Ultrafilter ℕ) + (htr : ∀ a b : M, τ (a*b)=τ (b*a)) + +omit [PartialOrder M] [StarOrderedRing M] in +lemma lift_pathValue_formal {r n : ℕ} (v : C ⊕ D → unitary M) + (w : Fin r × Fin n → (C ⊕ D) × Bool) (q : FreeGroup (Fin r)) : + FreeGroup.lift (pathValue v w) q = FreeGroup.lift v (pathHom w q) := by + have h : FreeGroup.lift (pathValue v w)=(FreeGroup.lift v).comp (pathHom w) := by + apply FreeGroup.ext_hom + intro i + simp only [FreeGroup.lift_apply_of,MonoidHom.comp_apply,pathHom,formalPath, + map_list_prod,List.map_ofFn,pathValue,HochschildWalk.word] + congr 2 + funext j + change signedValue v (w (i,j))=FreeGroup.lift v (signed (FreeGroup.of (w (i,j)).1) (w (i,j)).2) + rw [map_signed,FreeGroup.lift_apply_of] + rfl + exact congrArg (fun f : FreeGroup (Fin r) →* unitary M => f q) h + + + +def mixedFamily (v : C → unitary M) (u : ℕ → D → unitary M) : + FreeGroup (C ⊕ D) →* Ultrapower τ h1 ω htr := + quotientFamily τ h1 ω htr (fun j => FreeGroup.lift (Sum.elim v (u j))) + +def freshUnits (u : ℕ → D → unitary M) (d : D) : (Ultrapower τ h1 ω htr)ˣ := + (quotientFamily τ h1 ω htr (fun j => FreeGroup.lift (u j))).toHomUnits (FreeGroup.of d) + +lemma mixedFamily_of_inl (v : C → unitary M) (u : ℕ → D → unitary M) (c : C) : + mixedFamily τ h1 ω htr v u (FreeGroup.of (Sum.inl c)) = + constant τ h1 ω htr (v c : M) := by + apply congrArg (quotientHom τ h1 ω htr) + ext j + simp only [boundedHom_apply,FreeGroup.lift_apply_of,Sum.elim_inl] + rfl + +lemma mixedFamily_of_inr (v : C → unitary M) (u : ℕ → D → unitary M) (d : D) : + mixedFamily τ h1 ω htr v u (FreeGroup.of (Sum.inr d)) = + (freshUnits τ h1 ω htr u d : Ultrapower τ h1 ω htr) := by + apply congrArg (quotientHom τ h1 ω htr) + ext j + simp only [boundedHom_apply,FreeGroup.lift_apply_of,Sum.elim_inr] + +lemma mixedFamily_eq_eval (v : C → unitary M) (u : ℕ → D → unitary M) + (B : Subalgebra ℂ (Ultrapower τ h1 ω htr)) (b : C → Bˣ) + (hb : ∀ c, ((b c : B) : Ultrapower τ h1 ω htr)=constant τ h1 ω htr (v c : M)) + (g : FreeGroup (C ⊕ D)) : + mixedFamily τ h1 ω htr v u g= + (unitaryEvaluation B b (freshUnits τ h1 ω htr u) g : Ultrapower τ h1 ω htr) := by + have h : mixedFamily τ h1 ω htr v u = + (Units.coeHom _).comp (unitaryEvaluation B b (freshUnits τ h1 ω htr u)) := by + apply FreeGroup.ext_hom + intro z + cases z with + | inl c => + simp only [MonoidHom.comp_apply,unitaryEvaluation,FreeGroup.lift_apply_of,Sum.elim_inl] + exact (mixedFamily_of_inl τ h1 ω htr v u c).trans (hb c).symm + | inr d => + simp only [MonoidHom.comp_apply,unitaryEvaluation,FreeGroup.lift_apply_of,Sum.elim_inr] + exact mixedFamily_of_inr τ h1 ω htr v u d + exact congrArg (fun f : FreeGroup (C ⊕ D) →* Ultrapower τ h1 ω htr => f g) h + + + +theorem simultaneous_paths_of_free_lifts + (v : C → unitary M) (u : ℕ → D → unitary M) + (B : Subalgebra ℂ (Ultrapower τ h1 ω htr)) (b : C → Bˣ) + (hb : ∀ c, ((b c : B) : Ultrapower τ h1 ω htr)=constant τ h1 ω htr (v c : M)) + (hu : ∀ g : FreeGroup D, g ≠ 1 → + quotientTrace τ h1 ω htr (freshEvaluation (freshUnits τ h1 ω htr u) g)=0) + (hfree : HochschildFreeMoments.FreeCoefficients B + (freshEvaluation (freshUnits τ h1 ω htr u)) (quotientTrace τ h1 ω htr).toLinearMap) + {T : Type*} [Finite T] (r n : T → ℕ) + (w : ∀ t, Fin (r t) × Fin (n t) → (C ⊕ D) × Bool) + (q : ∀ t, FreeGroup (Fin (r t))) (hq : ∀ t, q t ≠ 1) + (hletters : ∀ t, ∃ (s : Fin (r t) → Fin (n t)) (a : Fin (r t) → D), + (∀ i, (w t (i,s i)).1=Sum.inr (a i)) ∧ + (∀ i z, (w t z).1=Sum.inr (a i) → z=(i,s i))) + (ε : ℝ) (hε : 0 < ε) : + ∃ j : ℕ, ∀ t, + ‖τ (FreeGroup.lift (pathValue (Sum.elim v (u j)) (w t)) (q t) : M)‖ < ε := by + have ht (t : T) : Tendsto + (fun j => τ (FreeGroup.lift (pathValue (Sum.elim v (u j)) (w t)) (q t) : M)) + (ω : Filter ℕ) (nhds 0) := by + obtain ⟨s,a,hpos,huniq⟩ := hletters t + have hz := distinguished_paths_moment B b (freshUnits τ h1 ω htr u) + (quotientTrace τ h1 ω htr).toLinearMap (quotientTrace_one τ h1 ω htr) + hu hfree (w t) s a hpos huniq (q t) (hq t) + rw [← mixedFamily_eq_eval τ h1 ω htr v u B b hb] at hz + have hc := tendsto_sequenceTrace τ h1 ω + (boundedHom (fun j => FreeGroup.lift (Sum.elim v (u j))) (pathHom (w t) (q t))) + change Tendsto (fun j => τ (FreeGroup.lift (Sum.elim v (u j)) (pathHom (w t) (q t)) : M)) + (ω : Filter ℕ) (nhds (quotientTrace τ h1 ω htr + (mixedFamily τ h1 ω htr v u (pathHom (w t) (q t))))) at hc + change quotientTrace τ h1 ω htr + (mixedFamily τ h1 ω htr v u (pathHom (w t) (q t)))=0 at hz + rw [hz] at hc + simpa only [lift_pathValue_formal] using hc + have he : ∀ᶠ j in (ω : Filter ℕ), ∀ t, + ‖τ (FreeGroup.lift (pathValue (Sum.elim v (u j)) (w t)) (q t) : M)‖ < ε := by + apply eventually_all.mpr + intro t + have he := (ht t).eventually (Metric.ball_mem_nhds (0:ℂ) hε) + simpa only [Metric.mem_ball,dist_zero_right] using he + exact he.exists + +end HochschildPaths +end + +end OAI